/* ============================================================
   Responsive fixes — Agent 1
   Scope: Home page + About/Guiding-Spirit pages, Header/Footer/
   ScrollToTop, and the section components used on those pages.
   Only rules for genuine mobile breakage — everything already
   handled by responsive.css is left untouched.
   ============================================================ */

/* Robotics.jsx (Home page "Robotics & AI/ML Classes" section)
   .rb-grid is a fixed 2-column grid (50fr 50fr) with no mobile
   override anywhere (the author's own commented-out attempt at
   "grid-template-columns: 1fr" in responsive.css confirms this was
   meant to collapse to one column — .rb-right already gets a
   stacked-layout padding-top at 992px, but the grid itself never
   changed, so rb-left/rb-right get crushed into ~45% width each).
   .rb-benefits is a fixed 4-column grid with the same problem —
   at mobile widths each benefit item has no room for its icon +
   text and wraps/overlaps badly. .rb-ai-badge is an absolutely
   positioned circle hanging off the image's top-right corner;
   its 992px override (130px, right:-19px) is still too large once
   rb-grid is stacked to full width on narrow phones and can push
   past the container edge. */
@media (max-width: 992px) {
    .rb-grid {
        grid-template-columns: 1fr;
    }
    .rb-benefits {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    .rb-benefit {
        align-items: center;
    }
}

@media (max-width: 576px) {
    .rb-ai-badge {
        top: -18px;
        right: -10px;
        width: 92px;
        height: 92px;
        padding: 4px;
        border-width: 2px;
    }
    .rb-ai-badge-text {
        font-size: 9px;
    }
}

/* Achievements.jsx (Home page "Our Achievements" section)
   .ach-olympiad-grid is a fixed 4-column grid with no responsive
   override at all, so each Olympiad group (title + list of
   name/class rows) is squeezed into ~1/4 of the screen width on
   phones, wrapping every name onto several lines and making the
   panel unreadable. */
@media (max-width: 768px) {
    .ach-olympiad-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .ach-olympiad-grid {
        grid-template-columns: 1fr;
    }
    .ach-olympiad-panel {
        padding: 22px 18px 18px;
    }
}

/* OurStory.jsx ("Our History & Legacy" then/now images + "Our Four
   Houses" / "Legacy & Impact" value cards)
   .os-history-img / .os-history-collage are fixed at height:460px
   while their two columns are plain Bootstrap `col-6` (they never
   stack to one column at any width), so on phones each "Then"/"Now"
   photo renders in a ~150px-wide column at a fixed 460px tall —
   a very narrow, stretched sliver. .os-tc-avatar (Houses / Legacy
   Values cards, also 2-up via `row-cols-2` below the `sm` and `lg`
   breakpoints) has the same fixed-height problem at 312px. */
@media (max-width: 768px) {
    .os-history-img,
    .os-history-collage {
        height: 320px;
    }
    .os-tc-avatar {
        height: 220px;
    }
}

@media (max-width: 480px) {
    .os-history-img,
    .os-history-collage {
        height: 220px;
    }
    .os-tc-avatar {
        height: 360px;
    }
}

/* PrincipalsDesk.jsx
   .principal-stack-brand-name is a fixed 94px font-size and
   .principal-stack-brand-logo is a fixed 165x159px image — together
   in a centered flex row with no responsive override anywhere, this
   causes severe horizontal overflow on every phone width (a single
   line of "S. J. Public School" at 94px is far wider than a 375px
   viewport). .principal-stack-img is a fixed height:550px; the
   existing 575px rule only caps its wrapper's max-width (78%), not
   the height, so the photo becomes a very narrow, tall strip on
   phones. */
@media (max-width: 768px) {
    .principal-stack-brand {
        flex-wrap: wrap;
        gap: 8px;
        padding: 10px;
    }
    .principal-stack-brand-logo {
        width: 64px;
        height: 62px;
    }
    .principal-stack-brand-name {
        font-size: 26px;
    }
}

@media (max-width: 575px) {
    .principal-stack-brand-logo {
        width: 48px;
        height: 46px;
    }
    .principal-stack-brand-name {
        font-size: 19px;
    }
    .principal-stack-img {
        height: 300px;
    }
}

/* PrincipalsDesk.jsx / ArchitectsOfExcellence.jsx / PrincipalMessage.jsx
   .principal-right's own 991.98px rule shrinks its padding to
   "28px 22px", but .principal-pull-quote-icon is absolutely
   positioned at left:-50px (sized for the desktop 60px inline-start
   padding). With only 22px of padding left, the quote icon sits at
   -28px and gets cut off by .principal-body's overflow:hidden on
   every phone/tablet width. Restoring a little more left padding
   and pulling the icon in keeps it fully visible. */
@media (max-width: 991.98px) {
    /* .principal-right {
        padding-inline-start: 46px;
    } */
    .principal-pull-quote-icon {
        left: -30px;
    }
}

/* WhyChooseUs.jsx ("Our Promise, Your Child's Future" sub-images)
   .wcu-promise-sub-imgs is a fixed 3-column grid; its images are
   already shortened to 180px tall at 991.98px, but at phone widths
   each of the 3 columns is only ~100-120px wide, so a 180px-tall
   image renders as a very narrow, stretched strip. */
@media (max-width: 480px) {
    .wcu-promise-sub-img {
        height: 110px;
    }
    .wcu-promise-sub-label {
        font-size: 9px;
        padding: 5px 4px;
    }
}
