﻿/* ============================================================
   ABHINAV MAHAVIDYALAYA — layout.css
   Header + Footer component styles (design.md is the reference)
   ------------------------------------------------------------
   • Every rule is scoped under unique ".abm-*" classes.
   • NO global selectors (no body / html / * / bare tags).
   • Resets use :where() = zero specificity — this file can
     never override your site's own CSS or Tailwind utilities.
   ============================================================ */

/* ---- scoped mini-reset (only inside .abm-root) ----
       Every rule is wrapped in :where() so it has ZERO specificity:
       it can never override a utility class or your site's own CSS. */
:where(.abm-root), :where(.abm-root *), :where(.abm-root *)::before, :where(.abm-root *)::after {
    box-sizing: border-box;
}

:where(.abm-root ul), :where(.abm-root ol) {
    list-style: none;
    margin: 0;
    padding: 0;
}

:where(.abm-root h1, .abm-root h2, .abm-root h3, .abm-root h4, .abm-root h5, .abm-root p) {
    margin: 0;
}

:where(.abm-root a) {
    text-decoration: none;
    color: inherit;
}

:where(.abm-root button) {
    background: none;
    border: 0;
    cursor: pointer;
    font: inherit;
    color: inherit;
    padding: 0;
}

:where(.abm-root img) {
    max-width: 100%;
    border: 0;
}

:where(.abm-root input, .abm-root select, .abm-root textarea) {
    font: inherit;
    border: 0;
}

:where(.abm-root address) {
    font-style: normal;
}

/* ---- preloader ---- */
.abm-loader-word {
    position: relative;
    font-weight: 800;
    letter-spacing: .35em;
    color: rgba(255,255,255,.18);
}

    .abm-loader-word .abm-loading-fill {
        position: absolute;
        inset: 0;
        color: #FA971E;
        overflow: hidden;
        width: 0%;
        white-space: nowrap;
        animation: abmLoadingFill 2s linear infinite;
    }

@keyframes abmLoadingFill {
    0% {
        width: 0%
    }

    100% {
        width: 100%
    }
}

.abm-preloader-logo {
    animation: abmPreloaderPulse 1.6s ease-in-out infinite;
}

@keyframes abmPreloaderPulse {
    0%,100% {
        transform: scale(1)
    }

    50% {
        transform: scale(1.08)
    }
}

/* ---- sticky header slide-down (Stadum .sticky) ---- */
.abm-sticky-active {
    position: fixed !important;
    top: 0;
    left: 0;
    right: 0;
    z-index: 60;
    box-shadow: 0 10px 30px rgba(1, 23, 54,.12);
    animation: abmStickySlide .45s cubic-bezier(.4,0,.2,1) both;
}

@keyframes abmStickySlide {
    from {
        transform: translateY(-100%)
    }

    to {
        transform: translateY(0)
    }
}

@media (min-width: 1280px) {
    .abm-sticky-active .abm-tier-2 {
        display: none;
    }

    .abm-sticky-active .abm-tier-3 {
        background: #fff;
    }
}

/* ══════════════════════════════════════════════════════════
       DROPDOWNS + MEGA MENU — EXACT Stadum animation:
       scaleY(0) → scaleY(1), transform-origin: top center,
       transition: all 0.4s ease   (from theme style.css)
       ══════════════════════════════════════════════════════════ */
.abm-menu-item {
    position: relative;
}

    .abm-menu-item > .abm-sub-menu {
        position: absolute;
        top: 100%;
        left: -14px;
        min-width: 230px;
        width: max-content;
        z-index: -1;
        text-align: left;
        background-color: #fff;
        padding: 18px 20px 18px 18px;
        border-top: 3px solid #FA971E;
        border-radius: 0;
        box-shadow: 0 4px 15px rgba(1, 23, 54,.06);
        visibility: hidden;
        opacity: 0;
        transform: scaleY(0);
        transform-origin: top center;
        transition: all 0.4s ease 0s;
    }

    .abm-menu-item:hover > .abm-sub-menu {
        visibility: visible;
        opacity: 1;
        transform: scaleY(1);
        z-index: 9;
    }

.abm-sub-menu .abm-sub-link {
    position: relative;
    display: block;
    padding: 6px 9px;
    font-size: 16px;
    line-height: 30px;
    color: #374151;
    text-transform: capitalize;
    transition: 0.3s ease-in-out;
}

    .abm-sub-menu .abm-sub-link::before {
        content: '❯';
        position: absolute;
        top: 6px;
        left: 10px;
        font-size: 14px;
        line-height: 30px;
        color: #FA971E;
        font-weight: 700;
        opacity: 0;
        transition: 0.3s ease-in-out;
    }

    .abm-sub-menu .abm-sub-link:hover {
        padding-left: 32px;
        color: #012555;
    }

        .abm-sub-menu .abm-sub-link:hover::before {
            opacity: 1;
        }

/* mega menu — same scaleY curtain animation, full-row panel */
.abm-menu-item.abm-has-mega {
    position: static;
}

.abm-mega-panel {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: -1;
    text-align: left;
    background-color: #fff;
    padding: 0;
    border-top: 3px solid #FA971E;
    border-radius: 0 0 .75rem .75rem;
    box-shadow: 0 30px 60px rgba(1, 23, 54,.22);
    visibility: hidden;
    opacity: 0;
    transform: scaleY(0);
    transform-origin: top center;
    transition: all 0.4s ease 0s;
}

.abm-menu-item.abm-has-mega:hover .abm-mega-panel {
    visibility: visible;
    opacity: 1;
    transform: scaleY(1);
    z-index: 9;
}

.abm-mega-title {
    font-family: "Plus Jakarta Sans", system-ui, sans-serif;
    font-weight: 700;
    font-size: 1.25rem;
    color: #012555;
    position: relative;
    padding-bottom: 14px;
    margin-bottom: 14px;
    letter-spacing: 1px;
}

    .abm-mega-title::before {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        width: 30px;
        height: 2px;
        background-color: #FA971E; color: #fff;
    }

.abm-mega-link {
    position: relative;
    display: block;
    padding: 5px 0;
    font-size: 16px;
    line-height: 30px;
    font-weight: 500;
    color: #4B5563;
    text-transform: capitalize;
    transition: 0.3s ease-in-out;
}

    .abm-mega-link::before {
        content: '❯';
        position: absolute;
        top: 5px;
        left: 0;
        font-size: 14px;
        line-height: 30px;
        color: #FA971E;
        font-weight: 700;
        opacity: 0;
        transition: 0.3s ease-in-out;
    }

    .abm-mega-link:hover {
        padding-left: 23px;
        color: #012555;
    }

        .abm-mega-link:hover::before {
            opacity: 1;
        }

.abm-mega-overlay-active {
    opacity: 1 !important;
}

/* nav link underline grow */
.abm-nav-link {
    position: relative;
}

    .abm-nav-link::after {
        content: '';
        position: absolute;
        left: 10px;
        bottom: 12px;
        height: 2px;
        width: 0;
        background: #FA971E;
        transition: width .35s cubic-bezier(.4,0,.2,1); color: #fff;
    }

    .abm-menu-item:hover .abm-nav-link::after, .abm-nav-link:hover::after {
        width: calc(100% - 20px);
    }

/* ══════════════════════════════════════════════════════════
       BUTTON — EXACT Stadum .th-btn animation:
       ::before layer grows width 0 → 100% from left, 0.7s,
       button itself transitions 0.5s, border-color on hover
       ══════════════════════════════════════════════════════════ */
.abm-btn {
    position: relative;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-align: center;
    overflow: hidden;
    line-height: 1;
    border: 1px solid transparent;
    transition: 0.5s;
}

    .abm-btn::before {
        content: '';
        position: absolute;
        width: 0;
        height: 100%;
        top: 0;
        left: 0;
        z-index: -1;
        background: #012555;
        transition: 0.7s;
    }

    .abm-btn:hover {
        color: #fff;
        border-color: #012555;
    }

        .abm-btn:hover::before {
            width: 100%;
        }

    .abm-btn .abm-btn-icon {
        transition: 0.4s;
    }

    .abm-btn:hover .abm-btn-icon {
        transform: translateX(6px);
    }
    /* variant: navy button fills gold on hover */
    .abm-btn.abm-btn-navy::before {
        background: #FA971E; color: #fff;
    }

    .abm-btn.abm-btn-navy:hover {
        color: #fff;
        border-color: #FA971E;
    }

    /* header "Admission Now": pinned so page stylesheets that restyle
       .abm-btn (About Us, B.A., RTI, Staff…) can't break the fill animation */
    .abm-tier-3 .abm-btn.abm-btn-navy {
        margin: 0;
        padding: 15px 1.25rem;
        gap: .75rem;
        font-size: 15.5px;
        font-weight: 600;
        line-height: 1;
        text-decoration: none;
        background: #012555;
        color: #fff;
        border: 1px solid transparent;
        border-radius: 0;
        box-shadow: none;
        transform: none;
        transition: color .5s, border-color .5s;
    }

        .abm-tier-3 .abm-btn.abm-btn-navy::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            z-index: -1;
            width: 0;
            height: 100%;
            background: #FA971E;
            transition: width .7s;
        }

        .abm-tier-3 .abm-btn.abm-btn-navy:hover {
            background: #012555;
            color: #fff !important;
            border-color: #FA971E;
            box-shadow: none;
            transform: none;
        }

            .abm-tier-3 .abm-btn.abm-btn-navy:hover::before {
                width: 100%;
            }

    @media (min-width: 1536px) {
        .abm-tier-3 .abm-btn.abm-btn-navy {
            padding: 15px 2rem;
            gap: 1.25rem;
            font-size: 17px;
        }
    }

/* ---- scroll reveal cues ---- */
.abm-root [data-abm-cue] {
    opacity: 0;
    transition: opacity .8s cubic-bezier(.4,0,.2,1), transform .8s cubic-bezier(.4,0,.2,1);
    will-change: transform, opacity;
}

.abm-root [data-abm-cue="slideInLeft"] {
    transform: translateX(-70px);
}

.abm-root [data-abm-cue="slideInRight"] {
    transform: translateX(70px);
}

.abm-root [data-abm-cue="fadeUp"] {
    transform: translateY(50px);
}

.abm-root [data-abm-cue].abm-cue-show {
    opacity: 1;
    transform: none;
}

/* ---- scroll-top circular progress (Stadum .scroll-top) ---- */
.abm-scroll-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 80;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    cursor: pointer;
    display: block;
    background: #FA971E;
    box-shadow: 0 8px 24px rgba(1, 23, 54,.28);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all .4s; color: #fff;
}

    .abm-scroll-top.abm-st-active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }

    .abm-scroll-top svg path {
        fill: none;
        stroke: #fff;
        stroke-width: 5;
        transition: stroke-dashoffset 10ms linear;
    }

    .abm-scroll-top::after {
        content: '«';
        position: absolute;
        inset: 0;
        display: flex;
        align-items: center;
        justify-content: center;
        transform: rotate(90deg);
        font-size: 24px;
        font-weight: 800;
        color: #fff;
        transition: all .3s;
    }

    .abm-scroll-top:hover::after {
        transform: rotate(90deg) translateX(-3px);
    }

/* ---- offcanvas panels & popups ---- */
.abm-overlay-anim {
    transition: opacity .4s;
}

.abm-panel-left {
    transition: transform .45s cubic-bezier(.4,0,.2,1);
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.abm-panel-right {
    transition: transform .45s cubic-bezier(.4,0,.2,1);
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
}

.abm-search-popup {
    transition: opacity .35s, visibility .35s;
}

    .abm-search-popup.abm-search-open {
        opacity: 1 !important;
        visibility: visible !important;
        /* become visible at once (still fades in) so the input can take focus immediately */
        transition: opacity .35s, visibility 0s;
    }

    .abm-search-popup .abm-search-input {
        transform: scaleX(.6);
        opacity: 0;
        transition: all .4s .1s;
    }

    .abm-search-popup.abm-search-open .abm-search-input {
        transform: scaleX(1);
        opacity: 1;
    }

/* Live page suggestions under the search input */
.abm-search-results {
    list-style: none;
    margin: 18px 0 0;
    padding: 0;
    max-height: 55vh;
    overflow-y: auto;
}

    .abm-search-results a {
        display: flex;
        align-items: center;
        gap: 14px;
        padding: 14px 16px;
        border-radius: 10px;
        color: #fff;
        text-decoration: none;
        transition: background .2s, padding-left .2s;
    }

        .abm-search-results a:hover,
        .abm-search-results .abm-sr-active a {
            background: rgba(255, 255, 255, .08);
            padding-left: 22px;
        }

    .abm-search-results .abm-sr-title {
        flex: 1;
        font-size: 18px;
        font-weight: 600;
    }

    .abm-search-results mark {
        background: none;
        color: #FA971E;
    }

    .abm-search-results .abm-sr-section {
        font-size: 13px;
        color: rgba(255, 255, 255, .55);
        white-space: nowrap;
    }

    .abm-search-results .abm-sr-arrow {
        color: #FA971E;
        opacity: 0;
        transition: opacity .2s;
    }

    .abm-search-results a:hover .abm-sr-arrow,
    .abm-search-results .abm-sr-active .abm-sr-arrow {
        opacity: 1;
    }

    .abm-search-results .abm-search-empty {
        padding: 14px 16px;
        color: rgba(255, 255, 255, .6);
        font-size: 16px;
    }

@media (max-width: 575px) {
    .abm-search-results .abm-sr-title { font-size: 16px; }
    .abm-search-results .abm-sr-section { display: none; }
}

/* accessibility bar (font-size toggle) */
.abm-fs-btn {
    min-width: 28px;
    height: 28px;
    padding: 0 6px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    border: 1px solid rgba(255,255,255,.3);
    border-radius: 4px;
    transition: all .3s;
}

    .abm-fs-btn:hover {
        background: #FA971E;
        color: #fff;
        border-color: #FA971E;
    }

    .abm-fs-btn.abm-fs-active {
        background: #FA971E;
        color: #fff;
        border-color: #FA971E;
    }

/* ── zoom-aware responsive fallback ──────────────────────
       CSS `zoom` (used by the A−/A+ accessibility bar) shrinks the
       effective viewport, but media queries DON'T react to it.
       layout.js measures innerWidth ÷ zoom and sets these body
       classes so the header collapses exactly like the real
       breakpoints. All selectors stay inside the abm- namespace. */
.abm-z-lg .abm-topbar-links {
    display: none !important;
}

.abm-z-lg .abm-contact-blocks {
    display: none !important;
}

.abm-z-2xl .abm-contact-phone {
    display: none !important;
}

.abm-z-xl .abm-contact-email {
    display: none !important;
}

.abm-z-xl .abm-tier-3 {
    display: none !important;
}

.abm-z-xl .abm-mobile-actions {
    display: flex !important;
}

/* admission enquiry modal */
.abm-modal {
    transition: opacity .35s, visibility .35s;
}

    .abm-modal .abm-modal-card {
        transform: translateY(40px) scale(.96);
        opacity: 0;
        transition: all .45s cubic-bezier(.22,1,.36,1) .05s;
    }

    .abm-modal.abm-modal-open {
        opacity: 1 !important;
        visibility: visible !important;
    }

        .abm-modal.abm-modal-open .abm-modal-card {
            transform: translateY(0) scale(1);
            opacity: 1;
        }

.abm-field {
    width: 100%;
    background: #F5F7FB;
    border: 1px solid #E2E6F0;
    border-radius: .5rem;
    padding: 12px 16px;
    font-size: 15.5px;
    color: #012555;
    outline: none;
    transition: border-color .3s, box-shadow .3s;
}

    .abm-field:focus {
        border-color: #FA971E;
        box-shadow: 0 0 0 3px rgba(250,151,30,.18);
    }

/* accordions */
.abm-mdd-panel, .abm-facc-panel {
    transition: max-height .4s cubic-bezier(.4,0,.2,1);
}

.abm-chev {
    transition: transform .35s;
}

.abm-rot180 {
    transform: rotate(180deg);
}

/* footer link hover (Stadum shift style) */
.abm-flink {
    position: relative;
    display: inline-block;
    transition: all .3s;
    color: inherit;
}

    .abm-flink::before {
        content: '❯';
        color: #FA971E;
        margin-right: .55rem;
        font-size: .85em;
    }

    .abm-flink:hover {
        color: #FA971E;
        transform: translateX(6px);
    }

/* footer recent-news rows */
.abm-news-thumb {
    transition: transform .4s ease;
}

.abm-news-row:hover .abm-news-thumb {
    transform: scale(1.08);
}

.abm-news-row .abm-news-title {
    transition: color .3s;
}

.abm-news-row:hover .abm-news-title {
    color: #FA971E;
}
