﻿/* ==============================
   Feature Grid Section (No Bootstrap)
   ============================== */

.feature-section {
    width: 100%;
    padding: clamp(40px, 5vw, 90px) 0;
    background: #000;
    color: #fff;
    margin-top: 5%;
}

.feature-container {
    width: min(1200px, 92vw);
    margin: 0 auto;
}

/* Header */
.feature-head {
    text-align: center;
    margin-bottom: clamp(22px, 3vw, 50px);
}

.feature-title {
    font-size: clamp(24px, 2.5vw, 44px);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin: 0;
}

.feature-subtitle {
    margin: 12px auto 0;
    width: min(680px, 92vw);
    color: #ddd;
    font-size: clamp(14px, 1.1vw, 17px);
    line-height: 1.7;
}

/* Grid */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(16px, 2.2vw, 28px);
    padding: 40px;
}

/* Card */
.feature-card {
    position: relative;
    background: #fff;
    border: 3px solid rgba(0, 118, 134, 0.45);
    border-radius: 22px;
    padding: clamp(18px, 2vw, 28px);
    text-align: center;
    box-shadow: 0 18px 40px rgba(0,0,0,0.06);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color .18s ease;
}

    .feature-card:hover {
        transform: translateY(-4px);
        border-color: rgba(0, 118, 134, 0.75);
        box-shadow: 0 22px 50px rgba(0,0,0,0.10);
    }

/* Icon */
.feature-icon {
    width: 100%;
    height: clamp(90px, 9vw, 150px);
    display: grid;
    place-items: center;
    margin-bottom: 14px;
}

    .feature-icon img {
        width: clamp(70px, 10vw, 135px);
        height: auto;
        object-fit: contain;
    }

/* Text */
.feature-text {
    font-size: clamp(13px, 1vw, 16px);
    line-height: 1.7;
    color: #222;
    margin: 0;
}

/* Warranty */
.warranty-block {
    margin-top: clamp(40px, 4vw, 70px);
    text-align: center;
    padding-top: clamp(34px, 3.5vw, 55px);
    border-top: 1px solid #eee;
}

/*.warranty-badge {
    width: clamp(120px, 13vw, 170px);
    height: clamp(120px, 13vw, 170px);
    border-radius: 50%;
    margin: 0 auto 18px;
    background: radial-gradient(circle at 40% 30%, #fff 20%, #f7f7f7 70%);
    border: 9px solid #111;
    outline: 8px solid #ddd;
    display: grid;
    place-items: center;
    text-align: center;
}*/


.warranty-badge {
    width: clamp(120px, 13vw, 170px);
    height: clamp(120px, 13vw, 170px);
    border-radius: 50%;
    margin: 0 auto 18px;
    /* image + gradient overlay */
    background: url("../images/5yrs-warrenty.png");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 9px solid #111;
    outline: 8px solid #ddd;
    display: grid;
    place-items: center;
    text-align: center;
}


.warranty-years {
    font-size: clamp(34px, 4vw, 56px);
    font-weight: 900;
    line-height: 1;
}

.warranty-label {
    font-size: clamp(12px, 1.2vw, 16px);
    font-weight: 800;
    letter-spacing: 0.2em;
    margin-top: 2px;
    color: #222;
}

.warranty-title {
    font-size: clamp(22px, 2vw, 34px);
    font-weight: 900;
    margin: 10px 0 0;
}

.warranty-text {
    width: min(760px, 92vw);
    margin: 12px auto 0;
    color: #ddd;
    font-size: clamp(14px, 1.05vw, 17px);
    line-height: 1.8;
}

/* ✅ Mobile layout */
@media (max-width: 850px) {
    .feature-grid {
        grid-template-columns: 1fr;
    }
}


.feature-card,
.warranty-block {
    opacity: 0;
    transform: translateY(14px);
}

    .feature-card.reveal,
    .warranty-block.reveal {
        opacity: 1;
        transform: translateY(0);
        transition: opacity .6s ease, transform .6s ease;
    }




/* ✅ Responsive Slider Design */
.slider-container {
    width: min(100%, 900px); /* responsive + max width */
    margin: 0 auto;
    overflow: hidden;
    border-radius: 14px;
    position: relative;
    /* responsive height */
    aspect-ratio: 16 / 9; /* keeps height proportional */
    max-height: 420px;
}

/* fallback for older browsers */
@supports not (aspect-ratio: 16 / 9) {
    .slider-container {
        height: clamp(220px, 40vw, 420px);
    }
}

.slider {
    height: 100%;
    width: 100%;
    display: flex;
    animation: slider 18s infinite ease-in-out; /* smoother + slower */
}

.card {
    flex: 0 0 100%;
    height: 100%;
    width: 100%;
}

.card-img {
    height: 100%;
    width: 100%;
    object-fit: scale-down;
    display: block;
}

/* ✅ Animation stays same but smoother pacing */
@keyframes slider {
    0%, 10% {
        transform: translateX(0%);
    }

    20%, 30% {
        transform: translateX(-100%);
    }

    40%, 50% {
        transform: translateX(-200%);
    }

    60%, 70% {
        transform: translateX(-300%);
    }

    80%, 90% {
        transform: translateX(-400%);
    }

    100% {
        transform: translateX(0%);
    }
}

/* ✅ Pause slider animation on hover */
.slider-container:hover .slider {
    animation-play-state: paused;
}

.slider-container:active .slider {
    animation-play-state: paused;
}







/* =========================
   MOBILE FIX ONLY
   ========================= */
@media (max-width: 768px) {

    .feature-title {
        margin-top: 50px;
    }

    /* section spacing */
    .feature-section {
        padding: 38px 0;
        margin-top: 0;
    }

    .feature-container {
        width: min(100%, 92vw);
    }

    .feature-subtitle {
        width: 100%;
        padding: 0 6px;
    }

    /* ✅ Slider: better height + no overflow */
    .slider-container {
        width: 100%;
        max-width: 100%;
        border-radius: 14px;
        /* Mobile friendly height */
        aspect-ratio: auto;
        height: clamp(220px, 52vw, 360px);
        overflow: hidden;
        margin-bottom: 18px;
    }

    /* ✅ Image should fill nicely on mobile */
    .card-img {
        width: 100%;
        height: 100%;
        object-fit: cover; /* change from scale-down */
        display: block;
    }

    /* ✅ Grid padding was breaking layout */
    .feature-grid {
        grid-template-columns: 1fr; /* 1 column */
        padding: 14px 6px; /* reduced from 40px */
        gap: 16px;
    }

    /* ✅ Cards should take full width */
    .feature-card {
        width: 100%;
        border-radius: 18px;
        padding: 18px;
    }

    .feature-icon {
        height: 95px;
        margin-bottom: 10px;
    }

        .feature-icon img {
            width: 82px;
        }

    /* ✅ Warranty spacing */
    .warranty-block {
        padding-top: 30px;
        margin-top: 40px;
    }

    .warranty-text {
        width: 100%;
        padding: 0 6px;
    }
}

/* Extra small phones */
@media (max-width: 420px) {
    .slider-container {
        height: 240px;
    }

    .feature-card {
        padding: 16px;
    }
}
