/* AWS Marquee Integration within Skills Section */
.marquee-header {
    text-align: left;
    font-family: 'Inter', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--ink);
    margin-top: 28px;
    /* Consistent top spacing for rows */
    margin-bottom: 10px;
    opacity: 0.7;
}

.marquee-header:first-of-type {
    margin-top: 0;
    /* No top margin for the first row */
}

.marquee-container {
    position: relative;
    width: 100%;
    /* Subtle edge masks for softness, ensuring content remains highly visible */
    mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 5%, black 95%, transparent);
    padding: 30px 0;
}

.marquee-content {
    display: flex;
    gap: 10px;
    width: max-content;
    animation: scroll-left 60s linear infinite;
}

.marquee-container:hover .marquee-content {
    animation-play-state: paused;
}

.marquee-reverse {
    animation: scroll-right 60s linear infinite;
}

@keyframes scroll-left {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(calc(-50% - 5px));
    }
}

@keyframes scroll-right {
    0% {
        transform: translateX(calc(-50% - 5px));
    }

    100% {
        transform: translateX(0);
    }
}

.aws-card-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    width: 110px;
    /* More compact width */
    opacity: 0.85;
    /* Increased base opacity */
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.aws-icon-box {
    width: 44px;
    height: 44px;
    background: transparent;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}

.aws-icon-box img {
    display: block;
    width: 50px;
    /* Balanced, perfectly equal icons */
    height: 50px;
    object-fit: contain;
    border-radius: 5px;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 2;
}

.logo-color img {
    filter: none !important;
    /* Allow original colors */
    opacity: 1;
    /* Increased to full opacity */
}

/* Explicitly make the GitHub icon solid black */
.aws-icon-box.logo-color img.github-icon {
    filter: brightness(0) contrast(100%) !important;
    opacity: 1 !important;
}

.aws-card-item:hover .logo-color img {
    opacity: 1;
}

.aws-label {
    font-family: 'Inter', sans-serif;
    font-size: 0.65rem;
    font-weight: 500;
    color: var(--mid);
    text-align: center;
    transition: all 0.4s ease;
    letter-spacing: 0.01em;
    opacity: 0.8;
    margin-top: 5px;
}

/* Hover Effects */
.aws-card-item:hover {
    opacity: 1;
}

.aws-card-item:hover .aws-icon-box img {
    transform: translateY(-8px) scale(1.15);
    filter: drop-shadow(0 12px 20px rgba(112, 125, 255, 0.4));
}

.aws-card-item:hover .aws-icon-box::after {
    content: '';
    position: absolute;
    inset: -5px;
    background: radial-gradient(circle at center, rgba(112, 125, 255, 0.15) 0%, transparent 85%);
    border-radius: 50%;
    z-index: 1;
}

.aws-card-item:hover .aws-label {
    color: var(--accent);
    opacity: 1;
    font-weight: 600;
}

@media (max-width: 768px) {
    .marquee-content {
        gap: 12px;
        animation-duration: 45s;
    }

    .aws-card-item {
        width: 90px;
    }

    .aws-icon-box {
        width: 68px;
        height: 68px;
    }

    .aws-icon-box img {
        width: 34px;
        height: 34px;
    }
}

@media (max-width: 480px) {
    .marquee-content {
        gap: 6px;
    }

    .aws-card-item {
        width: 75px;
    }

    .aws-icon-box {
        width: 56px;
        height: 56px;
    }

    .aws-icon-box img {
        width: 36px;
        height: 36px;
    }

    .aws-label {
        font-size: 0.6rem;
        margin-top: 4px;
    }

    .marquee-container {
        padding: 15px 0;
        /* Reduced vertical gap between rows */
    }
}
