/* Responsive breakpoints (mobile-first) */

/* Bootstrap .row has negative left/right margins that bleed past .container on mobile,
   creating a tiny horizontal scrollbar. Zero out the gutter at all viewport sizes —
   this page doesn't use Bootstrap's gutter system meaningfully. */
.row {
    --bs-gutter-x: 0;
    margin-left: 0;
    margin-right: 0;
}

/* Defense-in-depth: prevent any other rogue overflow from creating horizontal scroll */
html, body {
    overflow-x: hidden;
}

/* Large devices (desktops, <=1199.98px) */
@media (max-width: 1199.98px) {}

@media (max-width: 1024px) {
    h2 {
        font-size: 26px;
        margin: 0 0 1rem;
    }

    .section {
        padding: 2rem 0;
    }

    .container {
        padding: 0 .7rem;
    }

    .section-7 ul li {
        flex: 1 0 100%;
        max-height: 89px;
        padding: 1.5rem;
    }

    .hero-section h1 {
        font-size: 1.7rem;
    }

    .section-4 ul li.active {
        flex: 1 0 100%;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        padding: 1rem;
    }

    .section-6 ul li.active {
        flex: 1 0 100%;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        padding: 1rem;
    }

    .section-7 ul li.active {
        flex: 1 0 100%;
        display: flex;
        flex-wrap: wrap;
        align-items: center;
        padding: 1rem;
        max-height: 400px;
    }

    .section-6 ul li.active {
        max-height: 400px;
    }

    .section-4 ul li.active {
        max-height: 400px;
    }

    .products-grid:first-of-type {
        margin-top: 3rem;
        padding: 1rem;
    }

    .section .products-grid .products-grid__cta a {
        padding: 1rem 1.75rem;
        font-size: 18px;
    }

    /* Override desktop min-width: 300px on Viscera-3 SHOP NOW button — was a likely overflow culprit on small phones */
    .section .products-grid:first-of-type .products-grid__cta a:not(.amazon) {
        min-width: 0;
    }

    .section .products-grid__loader {
        font-size: 11px;
        padding: 1rem;
    }

    .section .products-grid__grade h1 {
        font-size: 30px;
        width: auto;
        font-weight: 900;
        display: inline-block;
        margin: 0;
        line-height: 1;
    }

    .section .products-grid__grade h3 {
        position: static;
        flex: 0 0 auto !important;
        margin: 0 0 0 8px;
        font-size: 12px;
    }

    .section .products-grid__loader h3 {
        font-size: 12px;
    }

    .supplement-box-inner .product-container {
        padding: 5px;
        -webkit-box-orient: vertical;
        -webkit-box-direction: normal;
        -ms-flex-direction: column;
        flex-direction: column;
    }

    .supplement-box-inner .product-container .img {
        margin-bottom: 15px;
    }

    .supplement-box-inner .product-container .text .icons {
        align-items: flex-start;
        margin: 0;
    }

    .supplement-box-inner .product-container .text .icons .icon {
        flex: 0 0 32%;
    }

    .supplement-box-inner .product-container .text .icons .icon img {
        margin: 0 auto 12px;
        height: 29px;
        object-fit: contain;
        width: 100%;
    }

    .supplement-box-inner .product-container .text {
        width: 100%;
    }

    .supplement-box-inner .product-container .button a {
        margin: 15px auto;
    }

    .final__box {
        padding: 2rem 1rem;
    }

    .section .products-grid__grade {
        padding: 1rem;
    }

    .reminder-popup {
        margin: 0;
        max-width: 100%;
        border-radius: 0;
        width: 100%;
        padding: .75rem 1rem;
    }
}

/* Medium to large devices (small desktops, <=991.98px) */
@media (max-width: 991.98px) {}

/* Small to medium devices (tablets, <=767.98px) */
@media (max-width: 767.98px) {
	span.mobile-hide {
		display: none;
	}

	.section-6 ul li p {
		text-align: left;
	}

	.section-7 ul li p {
		text-align: left;
	}

    .section .products-grid {
        grid-template-columns: minmax(0, 1fr) calc(50% - 2rem);
        grid-template-areas:
            "heading heading heading heading"
            "image image loader loader"
            "grade grade grade grade"
            "pros-cons pros-cons pros-cons pros-cons"
            "bottom-line bottom-line bottom-line bottom-line"
            "ticket ticket ticket ticket"
            "cta cta cta cta";
        gap: 1rem;
        padding: 2.5rem 1rem 1.5rem !important;
    }

    /* Slot 1 (Viscera-3) keeps the floating badge above the card — it's the winner */
    .section .products-grid:first-of-type .products-grid__badge {
        width: 70px;
    }

    /* Slots 2-5: anchor the number badge to the top-right of the card itself,
       small and tucked against the edge, instead of floating disconnected above */
    .section .products-grid:not(:first-of-type) .products-grid__badge {
        top: 0.5rem;
        right: 0.5rem;
        width: 60px;
        height: auto;
    }

    /* Make sure the heading text doesn't run under the badge */
    .section .products-grid:not(:first-of-type) .products-grid__heading {
        padding-right: 70px;
    }

    .footer ul {
        flex: 1 0 100%;
        gap: 0.5rem;
    }

    .footer ul li {
        flex: 1 0 100%;
        text-align: center;
    }

    .footer ul li a {
        font-size: 12px;
    }
	
	p {
		line-height: 1.5;
	}

	.hero-section p {
		line-height: 1.3;
		margin-bottom: 10px;
	}

	.hero-section {padding-top: 20px;padding-bottom: 10px;}

	body {
		--bs-body-font-size: 17px;
	}

	.section-5 ul {
		margin-top: 20px;
	}
	.section-6 p {
		text-align: center;
	}
}

/* Extra small devices (phones, <=575.98px) */
@media (max-width: 575.98px) {}
