/* © WatchJunk */
/* coded by nya & suzunay */

.categories-section {
        max-width: 1200px;
        margin: 0 auto;
        padding: 40px 20px;
        position: relative;
    }

    .grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 24px;
        position: relative;
    }

    .card {
        position: relative;
        height: 480px;
        overflow: hidden;
        border-radius: 16px;
        background: #0f172a;
        border: 1px solid rgba(59, 130, 246, 0.1);
        transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
        will-change: transform;
        contain: layout style;
    }

    .card:hover {
        transform: translateY(-8px);
        border-color: rgba(59, 130, 246, 0.4);
        box-shadow: 0 20px 14px rgba(0, 0, 0, 0.5);
    }

    .card a {
        text-decoration: none;
        color: inherit;
        display: block;
        height: 100%;
    }

    .card img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.4s ease;
        filter: brightness(0.75);
        will-change: transform;
    }

    .card:hover img {
        transform: scale(1.06);
    }

    .card-overlay {
        position: absolute;
        inset: 0;
        background: linear-gradient(to top, rgba(0,0,0,0.92) 0%, rgba(0,0,0,0.3) 50%, transparent 100%);
        display: flex;
        flex-direction: column;
        justify-content: flex-end;
        padding: 30px 24px;
        transition: background 0.4s ease;
    }

    .card:hover .card-overlay {
        background: linear-gradient(to top, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.2) 55%, transparent 100%);
    }

    .card-title {
        font-family: Poppins, sans-serif;
        font-size: 1.6rem;
        font-weight: 800;
        color: #ffffff;
        text-transform: uppercase;
        letter-spacing: 3px;
        text-shadow: 0 2px 8px rgba(0,0,0,0.6);
        margin-bottom: 8px;
        transition: color 0.3s ease;
    }

    .card:hover .card-title {
        color: #33b5ff;
    }

    .card-subtitle {
        font-family: Poppins, sans-serif;
        font-size: 0.85rem;
        font-weight: 400;
        color: rgba(255,255,255,0.6);
        letter-spacing: 0.5px;
        transition: color 0.3s ease;
    }

    .card:hover .card-subtitle {
        color: rgba(255,255,255,0.8);
    }

    .card-arrow {
        position: absolute;
        top: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        background: rgba(59, 130, 246, 0.15);
        border: 1px solid rgba(59, 130, 246, 0.3);
        display: flex;
        align-items: center;
        justify-content: center;
        color: #33b5ff;
        font-size: 16px;
        transition: background-color 0.3s ease, transform 0.3s ease;
        z-index: 2;
    }

    .card:hover .card-arrow {
        background: rgba(59, 130, 246, 0.3);
        transform: translateX(3px);
    }

    @media (max-width: 1200px) {
        .grid {
            grid-template-columns: repeat(2, 1fr);
        }
        .card {
            height: 400px;
        }
    }

    @media (max-width: 640px) {
        .categories-section {
            padding: 24px 16px;
        }
        .grid {
            grid-template-columns: 1fr;
            gap: 16px;
        }
        .card {
            height: 320px;
        }
        .card-title {
            font-size: 1.3rem;
        }
    }

    @media (min-width: 2560px) {
        .categories-section { max-width: 1600px; }
        .card { height: 580px; }
        .card-title { font-size: 2rem; }
    }

    @media (min-width: 3840px) {
        .categories-section { max-width: 2200px; }
        .card { height: 720px; }
        .card-title { font-size: 2.5rem; }
    }
