.page-home .content-area {
    background: #f3f5f8;
}


/* =====================================================
   Top Banner
===================================================== */

.top-banner {
    width: 100%;
    margin: 0;
    padding: 0;
}

.top-banner-layout {
    display: grid;
    grid-template-columns: minmax(380px, 1.1fr) minmax(0, 1.9fr);
    grid-template-areas:
            "content media"
            "testimonial media";
    min-height: 600px;
    overflow: hidden;
}


/* =====================================================
   Left Content Panel (Heading, Buttons, Quote)
===================================================== */

.top-banner-content-panel {
    grid-area: content;
    display: flex;
    align-items: center;
    padding: 20px 34px 16px;
    background: #f3f5f8;
}

.top-banner-content {
    width: 100%;
    max-width: 540px;
}

.top-banner-content h1 {
    margin: 0 0 22px;
    font-size: 45px;
    line-height: 1.08;
    font-weight: 750;
    letter-spacing: 0.2px;
    color: #1a1a1a;
}

.top-banner-content > p {
    margin: 0;
    font-size: 18px;
    line-height: 1.75;
    color: #30343a;
}

.top-banner-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 28px;
}


/* =====================================================
   Testimonial Wrap
===================================================== */

.top-banner-testimonial-wrap {
    grid-area: testimonial;
    padding: 8px 34px 36px;
    background: #f3f5f8;
}

.top-banner-testimonial {
    margin-top: 0;
    padding: 24px 24px 20px;
    background: #fdfdfd;
    border-left: 4px solid #c6212e;
    border-radius: 18px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.06);
}

.top-banner-testimonial .testimonial-quote {
    margin: 0;
    font-size: 18px;
    line-height: 1.7;
    font-weight: 500;
    color: #1f2933;
}

.top-banner-testimonial .testimonial-author {
    margin: 14px 0 0;
    font-size: 15px;
    line-height: 1.5;
    font-weight: 650;
    color: #1a3f74;
}


/* =====================================================
   Right Media Panel
===================================================== */

.top-banner-media-panel {
    grid-area: media;
    position: relative;
    min-width: 0;
}

/* Slideshow Container */
.top-banner-slideshow {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Slides */
.top-banner-slide {
    display: none;
    position: absolute;
    inset: 0;
}

.top-banner-slide.is-active {
    display: block;
}

.top-banner-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}


/* =====================================================
   Slideshow Arrows
===================================================== */

.top-banner-prev,
.top-banner-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 3;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 0;
    border-radius: 50%;
    cursor: pointer;
    font-size: 28px;
    line-height: 1;
    color: #fff;
    background: rgba(17, 17, 17, 0.35);
    transition: background 0.2s ease, transform 0.2s ease;
}

.top-banner-prev {
    left: 18px;
}

.top-banner-next {
    right: 18px;
}


/* =====================================================
   Fade Animation
===================================================== */

.fade {
    animation: topBannerFade 0.45s ease;
}

@keyframes topBannerFade {
    from {
        opacity: 0.6;
    }
    to {
        opacity: 1;
    }
}


/* =====================================================
   Two Panel Section (Call Form, Products)
===================================================== */

.home-panels {
    display: grid;
    grid-template-columns: 1fr;
}

.home-panel {
    min-height: auto;
}

.home-panel h2 {
    margin: 0;
    font-size: 45px;
    font-weight: 750;
}

.home-panel-left {
    background: #eeeeee;
    padding: 50px 60px;
    box-sizing: border-box;
}

.home-panel-right {
    padding: 0;
    background: #1a3f74;
}

.panel-header,
.products-header {
    margin: 0 0 30px 0;
}

.panel-header h2,
.products-header h2 {
    margin: 0 0 8px 0;
}

.panel-header p,
.products-header p {
    margin: 0;
    font-size: 20px;
    color: #555;
}


/* =====================================================
   Schedule Call/Contact Form
===================================================== */

.schedule-call-form {
    width: 100%;
    padding: 40px;
    background: #fdfdfd;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    box-sizing: border-box;
}

.schedule-call-form::before {
    content: "";
    display: block;
    height: 4px;
    background: #a51b25;
    margin: -40px -40px 30px -40px;
    border-radius: 8px 8px 0 0;
}

.form-row {
    margin-bottom: 22px;
}

.form-row.two-col {
    display: flex;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.form-group label {
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 18px;
}

.form-group textarea {
    resize: none;
    height: 175px;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 18px;
}

.form-submit {
    display: flex;
    justify-content: center;
    margin-top: 25px;
    gap: 30px;
}

.schedule-call-form .btn-primary {
    padding: 12px 32px;
    background-color: #1a3f74;
    color: #fff;
    border: none;
    border-radius: 999px;
    font-size: 15px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}


/* =====================================================
   Popular Products Panel
===================================================== */

.products-wrap {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px;
    box-sizing: border-box;
}

.products-card {
    padding: 20px;
    background: #fdfdfd;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    box-sizing: border-box;
    overflow: hidden;
}

.products-header {
    text-align: center;
    margin: 0 0 35px 0;
}

.products-header h2 {
    margin: 0 0 2px 0;
    color: #1a3f74;
}

.products-header p {
    margin: 0;
    font-size: 20px;
    line-height: 1.5;
    color: #555;
}

.products-grid {
    display: grid;
    gap: 24px;
}


/* =====================================================
   Clickable Product Item Cards
===================================================== */

.product-item {
    display: block;
    box-sizing: border-box;

    padding: 10px 14px;
    border-radius: 14px;
    border: 1px solid rgba(26, 63, 116, 0.08);
    background: #f8f9fb;
    text-align: left;

    color: inherit;
    text-decoration: none;
    cursor: pointer;

    transition: transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}

/* Image */
.product-item img {
    display: block;
    width: 100%;
    height: 220px;
    margin: 0 0 8px 0;
    object-fit: contain;
    transition: transform 0.3s ease;
}

/* Product Title */
.product-item h3 {
    margin: 0 0 5px 0;
    font-size: 21px;
    font-weight: 700;
    line-height: 1.3;
    color: #1a3f74;
}

/* Description */
.product-item p {
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    color: #555;
}


/* =====================================================
   Resources Section
===================================================== */

.home-resources {
    padding: 20px 50px;
    background: #f3f5f8;
    text-align: center;
}

.home-resources-header h2 {
    font-size: 60px;
    font-weight: 750;
    margin: 0 0 10px 0;
}

.home-resources-header p {
    font-size: 20px;
    max-width: 1000px;
    margin: 0 auto 50px auto;
    color: #555;
}

.home-resources-grid {
    display: grid;
    grid-template-columns: repeat(1, 1fr);
    gap: 50px;
    margin: 0 auto;
}

.resource-item img {
    width: 125px;
    height: auto;
    margin: 0 auto 5px auto;
}

.resource-item h3 {
    font-size: 20px;
    font-weight: 700;
    margin: 0 0 10px 0;
}

.resource-item p {
    font-size: 16px;
    color: #666;
    margin: 0 0 12px 0;
}

.resource-link {
    font-weight: 700;
    color: #c6212e;
    text-decoration: underline;
}


/* =====================================================
   Media Queries
===================================================== */

/* Desktop grid specifications */
@media (min-width: 900px) {
    .home-panels {
        grid-template-columns: 1fr 1fr;
    }

    .products-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1100px) {
    .home-resources-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Mobile optimization */
@media (max-width: 899px) {

    /* Fixed mobile header height (see qdts_global.css for reference to 75px) */
    .content-area {
        padding-top: 75px;
    }

    /* ------ Top Banner Testimonials ------ */
    .top-banner-layout {
        grid-template-columns: 1fr;
        grid-template-areas:
        "media"
        "testimonial"
        "content";
    }

    .top-banner-media-panel {
        height: 260px;
    }

    .top-banner-testimonial-wrap {
        padding: 18px 18px 0;
        background: #f3f5f8;
    }

    .top-banner-content-panel {
        padding: 24px 18px 32px;
    }

    .top-banner-content {
        max-width: 100%;
    }

    .top-banner-content h1 {
        font-size: 32px;
        line-height: 1.15;
        margin-bottom: 18px;
        text-align: center;
    }

    .top-banner-content > p {
        font-size: 16px;
        line-height: 1.6;
    }

    .top-banner-buttons {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }

    .btn-primary {
        width: 100%;
        max-width: 320px;
        padding: 12px 16px;
    }

    .top-banner-testimonial {
        margin-top: 0;
        padding: 20px;
    }

    .top-banner-testimonial .testimonial-quote {
        font-size: 16px;
    }

    .top-banner-testimonial .testimonial-author {
        font-size: 14px;
    }

    /* ------ Two-Panel Section ------ */
    .home-panel-left {
        padding: 28px 18px;
    }

    .products-wrap {
        max-width: none;
        padding: 28px 18px;
    }

    .home-panel h2 {
        font-size: 32px;
        text-align: center;
    }

    .panel-header p,
    .products-header p {
        font-size: 16px;
    }

    /* ------ Schedule a Call Form ------ */
    .schedule-call-form {
        padding: 22px;
        border-radius: 12px;
    }

    .schedule-call-form::before {
        margin: -22px -22px 18px -22px;
    }

    .form-row {
        margin-bottom: 15px;
    }

    .form-row.two-col {
        flex-direction: column;  /* Override: First Name & Last Name now stacked */
        gap: 14px;
    }

    .form-group label {
        font-size: 16px;
    }

    .form-group input,
    .form-group select,
    .form-group textarea {
        font-size: 16px;
        padding: 12px;
    }

    .form-group textarea {
        height: 140px;
    }

    .form-submit {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }

    .schedule-call-form .btn-primary {
        display: block;
        width: 100%;
        max-width: none;
        box-sizing: border-box;
        padding: 12px 16px;
    }

    /* ------ Top Products Section ------ */
    .products-card {
        padding: 22px;
        border-radius: 12px;
    }

    .products-header {
        margin-bottom: 24px;
    }

    .products-grid {
        gap: 18px;
    }

    .product-item {
        padding: 12px 14px;
    }

    .product-item img {
        width: 100%;
        height: 170px;
        margin-bottom: 8px;
    }

    .product-item h3 {
        font-size: 19px;
    }

    .product-item p {
        font-size: 15px;
        line-height: 1.55;
    }

    /* ------ Resources Section ------ */
    .home-resources {
        padding: 28px 18px;
    }

    .home-resources-header h2 {
        font-size: 36px;
    }

    .home-resources-header p {
        font-size: 16px;
        margin-bottom: 28px;
    }

    .home-resources-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .resource-item img {
        width: 86px;
    }

    .resource-item h3 {
        font-size: 18px;
    }

    .resource-item p {
        font-size: 14px;
    }
}

/* Only apply hover effects on desktop (when hover is supported) */
@media (hover: hover) and (pointer: fine) {
    /* Testimonial nav arrows */
    .top-banner-prev:hover,
    .top-banner-next:hover {
        background: rgba(17, 17, 17, 0.55);
        transform: translateY(-50%) scale(1.04);
    }

    .schedule-call-form .btn-submit:hover {
        background-color: #28a745;
    }

    .schedule-call-form .btn-clear:hover {
        background-color: #a51b25;
    }

    /* ------ Product Cards ------ */
    .product-item:hover {
        transform: translateY(-3px);
        box-shadow: 0 12px 26px rgba(0, 0, 0, 0.10);
        border-color: rgba(26, 63, 116, 0.16);
    }

    .product-item:hover img {
        transform: scale(1.03);
    }

    .resource-link:hover {
        color: #a51b25;
    }
}
