/* =========================================
   HERO CAROUSEL SECTION
   ========================================= */
.hero-carousel {
    background-color: var(--white);
    padding: 24px var(--page-gutter) 48px;
}

.hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    align-items: center;
    gap: 48px;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.hero-title {
    color: var(--primary-blue);
    /* Max 56px keeps the three lines intact in the 1200px container */
    font-size: clamp(35px, 3.4vw, 56px);
    font-weight: bold;
    line-height: 1.12;
    letter-spacing: -0.5px;
    margin-bottom: 20px;
}

.hero-subtext {
    color: var(--text-gray);
    font-size: clamp(16px, 0.95vw, 18px);
    line-height: 1.5;
    margin-bottom: 32px;
}

.hero-cta {
    padding: 14px 20px;
}

.hero-cta svg {
    margin-left: 8px;
    flex-shrink: 0;
}

.hero-media {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 3;
    border-radius: 20px;
    overflow: hidden;
    background-color: var(--text-dark);
}

.carousel-track-container {
    height: 100%;
    overflow: hidden;
}

.carousel-track {
    padding: 0;
    margin: 0;
    list-style: none;
    height: 100%;
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.carousel-slide {
    flex: 0 0 100%;
    height: 100%;
}

.slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 62% center;
    display: block;
}

.carousel-nav {
    position: absolute;
    bottom: 16px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    z-index: 10;
}

.carousel-arrow {
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    transition: transform 0.2s;
}

.carousel-arrow:hover {
    transform: scale(1.1);
}

.carousel-dots {
    display: flex;
    gap: 8px;
    align-items: center;
}

.carousel-dot {
    border: 1px solid var(--white);
    background: transparent;
    border-radius: 999px;
    width: 8px;
    height: 8px;
    padding: 0;
    cursor: pointer;
    transition: background-color 0.2s, width 0.2s;
}

.carousel-dot.current-dot {
    background-color: var(--white);
}

/* =========================================
   COMMON SECTION STYLES
   ========================================= */
section {
    padding: 64px var(--page-gutter);
}

/* =========================================
   HOW MOBIL HELPS SECTION
   ========================================= */
.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 32px;
}

.card {
    border: 1px solid var(--border-light);
    border-radius: 8px;
    overflow: hidden; 
    background: var(--white);
    transition: transform 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
}

.card-content {
    padding: 24px;
}

.tag-red {
    color: var(--red-tag);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    display: block;
    margin-bottom: 13px;
    letter-spacing: 0.5px;
}

.card-content h3 {
    color: var(--primary-blue);
    margin-bottom: 8px;
    font-size: 21px;
}

.card-content p {
    color: var(--text-gray);
    font-size: 15px;
}

/* =========================================
   FIND RIGHT PROTECTION SECTION
   ========================================= */
.find-protection {
    background-color: var(--primary-blue);
    color: var(--white);
    display: flex;
    align-items: center;
    gap: 64px;
}

.find-protection h2 {
    color: var(--white);
}

.find-protection p {
    color: #d0d0d0;
    margin-bottom: 32px;
}

.find-protection .content-left {
    flex: 1;
}

.find-protection .image-right {
    flex: 1;
}

.find-protection .image-right img {
    width: 100%;
    border-radius: 12px;
    object-fit: cover;
    height: 350px;
}

/* =========================================
   EXPLORE PRODUCTS SECTION
   ========================================= */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
}

.product-card {
    display: flex;
    flex-direction: column;
}

.product-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 16px;
}

.product-card h3 {
    font-size: 16px;
    color: var(--primary-blue);
}

/* Product line tiles link to their products accordion section */
a.product-card img {
    transition: opacity 0.2s;
}

a.product-card:hover img {
    opacity: 0.85;
}

a.product-card:hover h3 {
    text-decoration: underline;
}

/* =========================================
   BUY WITH CONFIDENCE SECTION
   ========================================= */
.buy-confidence {
    background-color: var(--light-bg);
}
.explore-products{
    font-weight: 600;
    font-size: 40px;
}

.buy-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.buy-card {
    background: var(--white);
    padding: 32px;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
}

.buy-card img {
    height: 40px;
    object-fit: contain;
}

.buy-card a {
    color: var(--primary-blue);
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* =========================================
   RESPONSIVE DESIGN (MEDIA QUERIES)
   ========================================= */
@media (max-width: 1024px) {
    .grid-4, .buy-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Hero mobile: image on top, text below */
    .hero-carousel {
        padding: 12px 20px 48px;
    }
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 0;
    }
    .hero-content {
        gap: 28px;
    }
    .hero-media {
        order: -1;
        overflow: visible;
        aspect-ratio: auto;
        border-radius: 0;
        background: none;
    }
    .carousel-track-container {
        aspect-ratio: 350 / 260;
        border-radius: 20px;
    }
    .carousel-nav {
        position: static;
        justify-content: center;
        margin: 12px 0 28px;
    }
    .carousel-arrow {
        display: none;
    }
    .carousel-dot {
        border: none;
        background-color: #B5B5B5;
    }
    .carousel-dot.current-dot {
        width: 20px;
        background-color: var(--primary-blue);
    }
    .hero-title {
        font-size: 34px;
        line-height: 38px;
        font-weight: 600;
        margin-bottom: 0;
    }
    .hero-subtext {
        font-size: 16px;
        line-height: 24px;
        margin-bottom: 0;
    }
    .hero-actions {
        width: 100%;
    }
    .hero-cta {
        width: 100%;
        min-height: 56px;
        justify-content: center;
        padding: 0 20px;
    }

    h2 {
        font-size: 26px;
    }

    /* Card Horizontal Scroll Slider for Mobile */
    .grid-3 {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 16px;
        padding-bottom: 16px;
        margin-right: -5%; 
        padding-right: 5%;
        -webkit-overflow-scrolling: touch;
    }
    
    .grid-3::-webkit-scrollbar {
        display: none;
    }
    
    .grid-3 .card {
        min-width: 85%;
        flex-shrink: 0;
        scroll-snap-align: start;
    }

    .grid-4, .buy-grid {
        grid-template-columns: 1fr;
    }

    .find-protection {
        flex-direction: column;
    }

}