/* ==========================================================================
   NOR / HIRA ACADEMY — Master Production Stylesheet
   100% Flawless Responsiveness Across All Mobile Screens (320px - 4K)
   ========================================================================== */

:root {
    --bg-primary: #0a0c10;
    --bg-secondary: #11151f;
    --bg-card: #161b26;
    --bg-card-hover: #1e2535;
    
    --border-color: rgba(255, 255, 255, 0.09);
    --border-hover: rgba(212, 175, 55, 0.4);

    /* Vertical divider between sample-plan columns (hover-narrow gutters) */
    --col-divider-color: rgba(255, 255, 255, 0.26);
    --col-divider-glow: rgba(255, 255, 255, 0.12);
    
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    
    --accent: #d4af37; /* Luxury Gold */
    --accent-glow: rgba(212, 175, 55, 0.15);
    --accent-hover: #e5c04e;
    
    --radius-xs: 6px;
    --radius-sm: 10px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-full: 9999px;
    
    --font-main: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --shadow-soft: 0 10px 30px rgba(0, 0, 0, 0.35);
    --transition: all 0.22s ease;
    --site-bg-image: linear-gradient(rgba(10, 12, 16, 0.42), rgba(10, 12, 16, 0.88)), url('assets/images/site-bg-dark.webp');
}

.light-theme {
    --bg-primary: #efe8da;
    --bg-secondary: #f6f1e6;
    --bg-card: #faf6ed;
    --bg-card-hover: #efe8d8;
    
    --border-color: rgba(120, 90, 30, 0.14);
    --border-hover: rgba(180, 140, 30, 0.45);
    
    --text-primary: #241d10;
    --text-secondary: #4a4234;
    --text-muted: #7a7060;
    
    --accent: #a67a10;
    --accent-glow: rgba(180, 133, 24, 0.12);
    --accent-hover: #8c660c;
    
    --shadow-soft: 0 10px 30px rgba(90, 70, 30, 0.10);
    --site-bg-image: linear-gradient(rgba(239, 232, 218, 0.55), rgba(239, 232, 218, 0.92)), url('assets/images/site-bg-light.webp');

    /* Vertical divider between sample-plan columns */
    --col-divider-color: rgba(140, 105, 35, 0.38);
    --col-divider-glow: rgba(140, 105, 35, 0.18);
}

/* Base & Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    overflow-wrap: break-word;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font-main);
    background-color: var(--bg-primary);
    background-image: var(--site-bg-image);
    background-size: cover;
    background-position: top center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--text-primary);
    line-height: 1.8;
    overflow-x: hidden;
    width: 100%;
    position: relative;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.top-glow {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100%;
    max-width: 900px;
    height: 350px;
    background: radial-gradient(ellipse at top, var(--accent-glow) 0%, transparent 70%);
    pointer-events: none;
    z-index: 0;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 800;
    line-height: 1.35;
    color: var(--text-primary);
}

p {
    color: var(--text-secondary);
    font-size: 1.02rem;
    line-height: 1.85;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

.text-center { text-align: center; }
.text-gradient { color: var(--accent); }

.text-crimson {
    color: #f87171;
    font-weight: 600;
}
.light-theme .text-crimson {
    color: #f87171;
    font-weight: 600;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    font-size: 0.98rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    cursor: pointer;
    border: none;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
    text-align: center;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.88rem;
    border-radius: var(--radius-xs);
}

.btn-md {
    padding: 11px 22px;
    font-size: 0.94rem;
}

.btn-lg {
    padding: 13px 28px;
    font-size: 1.02rem;
}

.btn-block {
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent) 0%, #b8860b 100%);
    color: #0b0d13;
    box-shadow: 0 4px 16px var(--accent-glow);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 22px rgba(212, 175, 55, 0.4);
}

.btn-outline {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--bg-card-hover);
    transform: translateY(-2px);
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: rgba(10, 12, 16, 0.92);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}
.light-theme .site-header {
    background: rgba(239, 232, 218, 0.92);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 68px;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.brand-badge-img {
    height: 40px;
    width: 40px;
    object-fit: contain;
    border-radius: 6px;
    flex-shrink: 0;
}

/* Dark theme: use the light (white+gold) logo variant */
.dark-theme .brand-badge-img {
    content: url("assets/images/logo_light.png");
}

.brand-text {
    display: flex;
    flex-direction: column;
    text-align: right;
}

.brand-name {
    font-weight: 900;
    font-size: 1.45rem;
    letter-spacing: 1.5px;
    color: var(--text-primary);
    line-height: 1.1;
    font-family: 'Vazirmatn', -apple-system, sans-serif;
}

.brand-sub {
    font-size: 0.78rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-top: 1px;
}

.nav-menu {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 20px;
}

.nav-link {
    font-size: 0.92rem;
    font-weight: 500;
    color: var(--text-secondary);
}

.nav-link:hover {
    color: var(--accent);
}

.menu-cta-mobile {
    display: none;
    width: 100%;
    margin-top: 12px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.theme-btn {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    width: 38px;
    height: 38px;
    border-radius: var(--radius-xs);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: var(--transition);
}

.theme-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.sun-icon { display: block; color: var(--accent); }
.moon-icon { display: none; }
.light-theme .sun-icon { display: none; }
.light-theme .moon-icon { display: block; color: var(--accent); }

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 6px;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text-primary);
    transition: var(--transition);
}

/* Hero Section */
.hero-section {
    padding: 64px 0 50px;
    text-align: center;
}

.hero-centered {
    max-width: 860px;
    margin: 0 auto;
}

.badge-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 16px;
    background: var(--accent-glow);
    border: 1px solid rgba(212, 175, 55, 0.35);
    border-radius: var(--radius-full);
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--accent);
    margin-bottom: 20px;
}

.badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 8px var(--accent);
    flex-shrink: 0;
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    margin-bottom: 18px;
    line-height: 1.35;
}

.hero-desc {
    font-size: clamp(0.96rem, 2.3vw, 1.12rem);
    font-weight: 400;
    line-height: 1.95;
    max-width: 740px;
    margin: 0 auto 30px;
    color: var(--text-secondary);
}

.light-theme .hero-desc {
    color: #334155;
}

.hero-cta-group {
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
    margin-bottom: 36px;
}

/* Hero 3-Item Stats Cards */
.hero-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    max-width: 820px;
    margin: 0 auto;
    text-align: center;
}

.stat-box-card {
    background: var(--bg-card);
    border: 1px solid rgba(212, 175, 55, 0.25);
    border-radius: var(--radius-sm);
    padding: 16px 12px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
}

.stat-box-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--accent-glow);
}

.stat-title {
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--accent);
    margin-bottom: 4px;
    display: block;
}

.stat-subtitle {
    font-size: 0.82rem;
    color: var(--text-secondary);
    font-weight: 500;
    line-height: 1.4;
    display: block;
}

/* Sections Base */
.section {
    padding: 64px 0;
}

.section-dark {
    background: var(--bg-secondary);
}

.section-head {
    margin-bottom: 40px;
}

.section-tag {
    display: inline-block;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

.section-title {
    font-size: clamp(1.5rem, 4vw, 2.1rem);
    margin-bottom: 8px;
}

.section-subtitle {
    font-size: 0.98rem;
    max-width: 600px;
    margin: 0 auto;
}

/* Cards */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    transition: var(--transition);
}

.card:hover {
    border-color: var(--border-hover);
}

/* Manifesto Section */
.manifesto-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
    align-items: stretch;
}

.manifesto-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 30px;
}

.highlight-card {
    border-color: rgba(212, 175, 55, 0.35);
    background: linear-gradient(145deg, var(--bg-card) 0%, rgba(212, 175, 55, 0.05) 100%);
}

.quote-badge {
    display: inline-block;
    align-self: flex-start;
    padding: 4px 12px;
    background: var(--accent-glow);
    color: var(--accent);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 14px;
}

.manifesto-text p {
    font-size: 0.98rem;
    line-height: 1.9;
    margin-bottom: 14px;
}

.manifesto-sub-quote {
    color: var(--text-muted);
    font-style: italic;
    font-size: 0.92rem !important;
}

.author-sign {
    color: var(--accent);
    font-size: 0.92rem;
    font-weight: 700;
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
}

.features-subgrid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.sub-card {
    padding: 18px;
}

.sub-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}

.sub-icon {
    color: var(--accent);
    margin-bottom: 8px;
}

.sub-card h4 {
    font-size: 1rem;
    margin-bottom: 4px;
}

.sub-card p {
    font-size: 0.86rem;
    line-height: 1.65;
}

/* Sample Plans Section */
.sample-plan-main-card {
    padding: 24px;
    background: var(--bg-card);
    border: 1px solid rgba(212, 175, 55, 0.3);
    border-radius: var(--radius-md);
    margin-bottom: 22px;
    max-width: 960px;
    margin-left: auto;
    margin-right: auto;
}

.sample-plan-grid {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 22px;
    align-items: center;
}

.sample-img-frame {
    position: relative;
    border-radius: var(--radius-sm);
    overflow: hidden;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    background: #0f1219;
    max-height: 200px;
}

.sample-plan-image {
    width: 100%;
    height: 100%;
    max-height: 200px;
    object-fit: cover;
    object-position: top;
    display: block;
}

.plan-img-badge {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(10, 12, 16, 0.9);
    border: 1px solid var(--accent);
    color: var(--accent);
    padding: 3px 8px;
    border-radius: var(--radius-full);
    font-size: 0.72rem;
    font-weight: 700;
    backdrop-filter: blur(6px);
}

.sample-plan-details h3 {
    font-size: 1.15rem;
    margin-bottom: 10px;
}

.plan-points {
    list-style: none;
}

.plan-points li {
    font-size: 0.88rem;
    color: var(--text-body);
    margin-bottom: 8px;
    line-height: 1.65;
}

.plan-points strong {
    color: var(--accent);
}

.plan-section-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 22px auto 18px;
    max-width: 960px;
}

.divider-line {
    flex-grow: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--border-color), transparent);
}

.divider-icon {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--accent);
    white-space: nowrap;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 3px 12px;
    border-radius: var(--radius-full);
}

.sample-plans-3col-card {
    padding: 24px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    max-width: 960px;
    margin: 0 auto;
}

/* Sample-plan grid: 6 columns = 3 + 3 (two clean rows of 3 with vertical dividers).
   The per-column ::before below gives every column a line on its LEFT edge.
   A plain 3-col grid has 2 gutters per row, so the middle column needs a line on
   BOTH sides; the ::before alone can only cover the left one. The extra ::after
   rule for the middle column (nth-child(3n+2)) paints the right-hand line. */
.sample-plans-3col-grid {
    --dp-gutter: 24px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    column-gap: var(--dp-gutter);
    row-gap: 20px;
    align-items: stretch;
}

/* 5/6 mentor columns: 3 per row, then 2, then 1 */
@media (max-width: 1280px) {
    .sample-plans-3col-grid {
        column-gap: 16px;
    }

    .sample-plans-3col-grid .sample-col:not(:first-child)::before {
        left: -9.5px;   /* half of 16px gap, minus half line width */
    }
}

@media (max-width: 992px) {
    .sample-plans-3col-grid {
        --dp-gutter: 16px;
        grid-template-columns: 1fr 1fr;
        column-gap: 16px;
    }

    /* 2-col layout: the first column of each row must NOT show its left divider
       (that gap is the card's outer edge), and the middle-column ::after rule
       from the 3-col layout no longer applies. */
    .sample-plans-3col-grid .sample-col:nth-child(odd)::before {
        display: none;
    }

    .sample-plans-3col-grid .sample-col:nth-child(3n+2)::after {
        display: none;
    }

    .sample-plans-3col-grid .sample-col:not(:first-child)::before {
        left: -9.5px;   /* half of 16px gap, minus half line width */
    }
}

@media (max-width: 768px) {
    .sample-plans-3col-grid {
        grid-template-columns: 1fr;
    }

    .sample-plans-3col-grid .sample-col::before,
    .sample-plans-3col-grid .sample-col::after {
        display: none;
    }
}

.col-divider {
    width: 1px;
    background: var(--border-color);
    align-self: stretch;
    /* sit in the gutter between rows, not as a grid track */
    margin-inline: -12px;
}

/* Vertical separator between the sample-plan columns (no extra DOM elements).
   RTL-safe: physical `left`/`right` offsets (logical `inset-inline-*` flip the
   measured edge in RTL and put the line inside the column instead of the gutter). */
.sample-plans-3col-grid .sample-col:not(:first-child)::before {
    content: "";
    position: absolute;
    top: 6px;
    bottom: 6px;
    /* LEFT edge of the column faces the gap toward its neighbour */
    left: -13.5px;               /* -12 (half gap) - 1.5 (half line width) */
    width: 3px;
    border-radius: 3px;
    background: linear-gradient(to bottom,
        transparent 0%,
        var(--col-divider-color) 14%,
        var(--col-divider-color) 86%,
        transparent 100%);
    box-shadow: 0 0 8px var(--col-divider-glow);
    pointer-events: none;
}

/* .sample-col inherits the .card class, which paints a rotating glow ring via
   .card::after. Sample-plan columns must NOT have that ring — they use ::after
   themselves for the right-hand divider line (rule above). */
.sample-plans-3col-grid .sample-col::after {
    content: none;
}

/* ...except the middle column of each 3-col row, which keeps its right-hand
   divider. The doubled .sample-col raises specificity above the rule above. */
.sample-plans-3col-grid .sample-col.sample-col:nth-child(3n+2)::after {
    content: "";
    position: absolute;
    top: 6px;
    bottom: 6px;
    /* RIGHT edge of the column faces the other gap */
    right: -13.5px;
    width: 3px;
    border-radius: 3px;
    background: linear-gradient(to bottom,
        transparent 0%,
        var(--col-divider-color) 14%,
        var(--col-divider-color) 86%,
        transparent 100%);
    box-shadow: 0 0 8px var(--col-divider-glow);
    opacity: 1;
    animation: none;
    pointer-events: none;
    z-index: 1;
}

.col-divider-h {
    grid-column: 1 / -1;
    height: 1px;
    background: var(--border-color);
}

.sample-col {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.sample-col-header {
    margin-bottom: 10px;
}

.col-pill {
    display: inline-block;
    padding: 2px 8px;
    background: var(--accent-glow);
    color: var(--accent);
    border-radius: var(--radius-xs);
    font-size: 0.74rem;
    font-weight: 700;
}

.sample-col-img-wrap {
    border-radius: var(--radius-xs);
    overflow: hidden;
    border: 1px solid var(--border-color);
    margin-bottom: 12px;
    background: #0f1219;
    height: 120px;
}

.sample-col-img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: top;
    transition: var(--transition);
}

.sample-col-img-wrap:hover .sample-col-img {
    transform: scale(1.04);
}

.col-features {
    list-style: none;
    margin-bottom: 14px;
    flex-grow: 1;
}

.col-features li {
    font-size: 0.8rem;
    color: var(--text-body);
    margin-bottom: 5px;
    line-height: 1.55;
}

.col-footer {
    padding-top: 10px;
    border-top: 1px solid var(--border-color);
}

/* Pillars / Services Grid */
.pillars-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.pillar-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 22px;
}

.pillar-card:hover {
    border-color: rgba(212, 175, 55, 0.4);
    transform: translateY(-2px);
}

.pillar-num {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--accent);
    opacity: 0.7;
    margin-bottom: 8px;
    display: block;
}

.pillar-card h3 {
    font-size: 1.1rem;
    margin-bottom: 8px;
}

.pillar-card p {
    font-size: 0.9rem;
    line-height: 1.75;
}

/* Bank Test Grid */
.bank-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.subject-card {
    padding: 20px;
}

.subject-card:hover {
    border-color: var(--accent);
}

.subj-badge {
    display: inline-block;
    padding: 3px 8px;
    background: var(--accent-glow);
    color: var(--accent);
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.subject-card h4 {
    font-size: 1.05rem;
    margin-bottom: 6px;
}

.subject-card p {
    font-size: 0.86rem;
    line-height: 1.65;
}

/* Mentors Grid */
.mentors-poster-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    max-width: 900px;
    margin: 0 auto;
    align-items: start;  /* an expanded card may grow tall; its row sibling must NOT stretch with it */
}

.mentor-pro-card {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border-radius: var(--radius-md);
}

.mentor-pro-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-soft);
}

.poster-crop-container {
    position: relative;
    width: 100%;
    height: 260px;          /* collapsed: only the face band of the poster */
    background: #0f1219;
    overflow: hidden;
    cursor: zoom-in;
    transition: height 0.4s ease;
}

/* Collapsed state on card: show only the face area of the poster */
.mentor-poster-visual {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: 50% 28%;
    transition: var(--transition);
}

/* Expanded state (full poster view): .is-expanded on the poster-crop-container.
   The container animates open to the poster's full aspect ratio (≈1.5), so the
   whole poster becomes visible at full card width. `align-items:start` on the
   grid keeps the row sibling at its own size while this card grows. */
.poster-crop-container.is-expanded {
    height: auto;
    aspect-ratio: 1023 / 1537;
    cursor: zoom-out;
}
.poster-crop-container.is-expanded .mentor-poster-visual {
    animation: posterZoomIn 0.45s cubic-bezier(0.2, 0.7, 0.25, 1) both;
    object-fit: cover;
    object-position: 50% 28%;
}
.poster-crop-container.is-expanded .poster-expand-hint {
    opacity: 1;
    animation: posterHintPill 0.45s cubic-bezier(0.2, 0.7, 0.25, 1) both;
}
.poster-crop-container:not(.is-expanded) .mentor-poster-visual {
    animation: none;
}
@keyframes posterZoomIn {
    from { transform: scale(1.12); filter: brightness(1.35) saturate(1.25); }
    to   { transform: scale(1);    filter: brightness(1) saturate(1); }
}
@keyframes posterHintPill {
    from { transform: translateX(50%) translateY(8px); }
    to   { transform: translateX(50%) translateY(0); }
}

.poster-floating-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(10, 12, 16, 0.9);
    border: 1px solid var(--accent);
    color: var(--accent);
    padding: 3px 10px;
    border-radius: var(--radius-full);
    font-size: 0.76rem;
    font-weight: 700;
    backdrop-filter: blur(6px);
}

/* Hover hint: click to expand the full poster */
.poster-expand-hint {
    position: absolute;
    bottom: 12px;
    right: 50%;
    transform: translateX(50%);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(10, 12, 16, 0.78);
    backdrop-filter: blur(6px);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: var(--radius-full);
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    white-space: nowrap;
    z-index: 2;
}

.poster-crop-container.is-expanded .poster-expand-hint {
    opacity: 1;
}
@media (hover: hover) and (pointer: fine) {
    .poster-crop-container:hover .poster-expand-hint {
        opacity: 1;
    }
}

.mentor-content-box {
    padding: 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
}

.mentor-top-meta h3 {
    font-size: 1.25rem;
    margin-bottom: 2px;
}

.mentor-dept {
    font-size: 0.86rem;
    color: var(--accent);
    display: block;
    margin-bottom: 10px;
}

.mentor-score-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 14px;
}

.score-chip {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border-color);
    padding: 2px 8px;
    border-radius: var(--radius-xs);
    font-size: 0.76rem;
    color: var(--text-body);
}

.mentor-features-list {
    list-style: none;
    margin-bottom: 18px;
}

.mentor-features-list li {
    font-size: 0.86rem;
    color: var(--text-body);
    margin-bottom: 6px;
    line-height: 1.6;
}

.mentor-card-footer {
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.price-holder {
    display: flex;
    align-items: baseline;
    gap: 6px;
    justify-content: center;
}

.price-val {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-primary);
}

.price-unit {
    font-size: 0.82rem;
    color: var(--text-muted);
}

/* Guarantee Section */
.guarantee-card {
    background: linear-gradient(135deg, rgba(20, 38, 68, 0.9) 0%, rgba(14, 26, 48, 0.95) 100%);
    border: 1px solid rgba(56, 189, 248, 0.35);
    border-radius: var(--radius-lg);
    padding: 40px 28px;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    box-shadow: 0 10px 35px rgba(14, 165, 233, 0.08);
}

.light-theme .guarantee-card {
    background: linear-gradient(135deg, #e0f2fe 0%, #f0f9ff 100%);
    border: 1px solid rgba(14, 165, 233, 0.3);
}

.guarantee-badge {
    display: inline-block;
    padding: 5px 14px;
    background: var(--accent);
    color: #0b0d13;
    font-weight: 800;
    font-size: 0.82rem;
    border-radius: var(--radius-full);
    margin-bottom: 14px;
}

.guarantee-card h2 {
    font-size: 1.9rem;
    color: #ffffff;
    margin-bottom: 10px;
}

.light-theme .guarantee-card h2 {
    color: #0f172a;
}

.guarantee-lead {
    font-size: 1.05rem;
    font-weight: 500;
    line-height: 1.8;
    color: #e2e8f0 !important;
    max-width: 600px;
    margin: 0 auto 28px;
}

.light-theme .guarantee-lead {
    color: #1e293b !important;
}

.guarantee-terms {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    text-align: right;
}

.term-box {
    background: rgba(10, 18, 34, 0.75);
    border: 1px solid rgba(56, 189, 248, 0.2);
    border-radius: var(--radius-sm);
    padding: 16px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.light-theme .term-box {
    background: #faf6ed;
    border: 1px solid rgba(14, 165, 233, 0.25);
}

.term-num {
    width: 28px;
    height: 28px;
    background: rgba(56, 189, 248, 0.15);
    color: #38bdf8;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.88rem;
    font-weight: 800;
    flex-shrink: 0;
}

.term-box p {
    font-size: 0.88rem;
    line-height: 1.65;
    color: #f1f5f9;
}

.light-theme .term-box p {
    color: #334155;
}

/* FAQ Section */
.faq-accordion {
    max-width: 760px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.faq-item {
    padding: 0;
    overflow: hidden;
}

.faq-trigger {
    width: 100%;
    padding: 18px 20px;
    background: none;
    border: none;
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-family: inherit;
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--text-primary);
    cursor: pointer;
    text-align: right;
}

.faq-icon {
    color: var(--accent);
    transition: transform 0.22s ease;
    flex-shrink: 0;
}

.faq-content {
    display: none;
    padding: 0 20px 16px;
}

.faq-item.active .faq-content {
    display: block !important;
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-content p {
    font-size: 0.92rem;
    line-height: 1.85;
}

/* Booking Section */
.booking-box {
    padding: 44px 24px;
    text-align: center;
    max-width: 780px;
    margin: 0 auto;
}

.booking-box h2 {
    font-size: 1.9rem;
    margin-bottom: 10px;
}

.booking-box p {
    font-size: 1.05rem;
    max-width: 540px;
    margin: 0 auto 28px;
}

.booking-actions {
    display: flex;
    justify-content: center;
    gap: 14px;
    flex-wrap: wrap;
}

/* Footer */
.site-footer {
    border-top: 1px solid var(--border-color);
    padding: 36px 0 20px;
    background: var(--bg-primary);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.footer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-logo-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 800;
    font-size: 1rem;
}

.footer-links {
    display: flex;
    gap: 20px;
    font-size: 0.9rem;
    color: var(--accent);
}

.footer-copy {
    text-align: center;
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
    font-size: 0.8rem;
    color: var(--text-muted);
}

/* ==========================================================================
   Header Dropdown Menus (Desktop hover / Mobile tap)
   ========================================================================== */
.nav-item {
    position: relative;
}

.dropdown-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: none;
    border: none;
    font-family: inherit;
    cursor: pointer;
    padding: 0;
    color: var(--text-secondary);
    font-size: 0.92rem;
    font-weight: 500;
    transition: color 0.22s ease;
}

.dropdown-toggle:hover {
    color: var(--accent);
}

.dd-caret {
    transition: transform 0.25s ease;
}

.has-dropdown.open .dd-caret {
    transform: rotate(180deg);
}

.dropdown-panel {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 250px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 8px;
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), 0 0 0 1px var(--accent-glow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s;
    z-index: 100001;
}

.dropdown-panel::before {
    content: '';
    position: absolute;
    top: -14px;
    left: 0;
    right: 0;
    height: 14px;
}

.dd-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: var(--radius-xs);
    font-size: 0.9rem;
    color: var(--text-secondary);
    transition: background 0.18s ease, color 0.18s ease, padding-right 0.18s ease;
}

.dd-group-label {
    padding: 8px 14px 4px;
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.dd-item .dd-num {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--accent);
    background: var(--accent-glow);
    padding: 2px 8px;
    border-radius: var(--radius-full);
    flex-shrink: 0;
}

.dd-item:hover {
    background: var(--bg-card-hover);
    color: var(--text-primary);
    padding-right: 18px;
}

/* Desktop: open on hover */
@media (hover: hover) and (pointer: fine) and (min-width: 769px) {
    .has-dropdown:hover .dropdown-panel,
    .has-dropdown.open .dropdown-panel {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
}

/* Fallback: .open (tap/click) always opens the panel on desktop widths */
@media (min-width: 769px) {
    .has-dropdown.open .dropdown-panel {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
}

/* Mobile (inside drawer): open on tap */
@media (max-width: 768px) {
    .dropdown-toggle {
        width: 100%;
        justify-content: space-between;
        padding: 4px 0;
    }

    .dropdown-panel {
        position: static;
        width: 100%;
        min-width: 0;
        max-height: 0;
        overflow: hidden;
        padding: 0;
        border: none;
        box-shadow: none;
        background: transparent;
        transform: none;
        opacity: 1;
        visibility: visible;
        transition: max-height 0.3s ease, padding 0.3s ease;
    }

    .has-dropdown.open .dropdown-panel {
        max-height: 420px;
        padding: 6px 0;
    }

    .dd-item {
        padding-right: 26px;
    }

    .dd-item:hover {
        padding-right: 32px;
    }
}

/* ==========================================================================
   Modern Card Hover: Lift + Rotating Gradient Border (conic-gradient)
   ========================================================================== */
.card,
.stat-box-card {
    position: relative;
    transition: transform 0.35s cubic-bezier(0.22, 0.68, 0, 1.2),
                box-shadow 0.35s ease;
    will-change: transform;
    z-index: 1;
}

/* rotating gradient ring layer */
.card::after,
.stat-box-card::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1.5px;
    background: conic-gradient(from var(--ring-angle, 0deg),
        rgba(212,175,55,0.9), rgba(255,0,128,0.7), rgba(0,200,255,0.7), rgba(212,175,55,0.9));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.35s ease;
    pointer-events: none;
}

@property --ring-angle {
    syntax: '<angle>';
    initial-value: 0deg;
    inherits: false;
}

@media (hover: hover) and (pointer: fine) {
    .card:hover,
    .stat-box-card:hover {
        transform: translateY(-6px) scale(1.01);
        box-shadow: 0 20px 45px rgba(0, 0, 0, 0.4);
        z-index: 2;
    }

    .card:hover::after,
    .stat-box-card:hover::after {
        opacity: 1;
        animation: ring-spin 3s linear infinite;
    }

    /* Sample-plans box holds 6 columns: lifting the whole box on hover looks broken.
       Each column gets its own lift instead (see .sample-col rules above). */
    .sample-plans-3col-card:hover {
        transform: none;
        box-shadow: none;
        z-index: auto;
    }

    .sample-plans-3col-card:hover::after {
        opacity: 0;
        animation: none;
    }

    @keyframes ring-spin {
        to { --ring-angle: 360deg; }
    }
}

/* Sample-plans box holds 6 columns: it must NEVER lift on hover — only its
   columns do (see the per-column rules below). These live outside the
   (hover: hover) media query on purpose. */
.sample-plans-3col-card {
    transition: border-color 0.25s ease;
}

.sample-plans-3col-card:hover,
.sample-plans-3col-card:focus-within {
    transform: none !important;
    box-shadow: none !important;
    z-index: auto;
}

.sample-plans-3col-card:hover::after,
.sample-plans-3col-card:focus-within::after {
    opacity: 0 !important;
    animation: none !important;
}

/* Per-column lift for the sample plans: ONLY the hovered plan rises, never the
   6-up wrapper box. Lives outside the hover media query so it also works on
   touch (as an active-tap state) and in environments that report hover:none. */
.sample-plans-3col-grid .sample-col {
    position: relative;
    border-radius: var(--radius-sm);
    transition: transform 0.25s ease, filter 0.25s ease;
}

.sample-plans-3col-grid .sample-col:hover,
.sample-plans-3col-grid .sample-col:focus-within {
    transform: translateY(-4px);
    filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.35));
}

@media (hover: none) {
    .sample-plans-3col-grid .sample-col:active {
        transform: translateY(-4px) scale(0.995);
        filter: drop-shadow(0 8px 18px rgba(0, 0, 0, 0.35));
    }
}

/* Touch devices: no hover anim, but keep taps clean */
@media (hover: none) {
    .card:active,
    .stat-box-card:active {
        transform: scale(0.98);
    }
}

@media (prefers-reduced-motion: reduce) {
    .card, .stat-box-card { transition: none; }
    .card::after, .stat-box-card::after { display: none; }
    .card:hover, .stat-box-card:hover { transform: none; }
}

/* Wide Telegram CTA buttons — clean responsive design */
.tg-wide-btn {
    white-space: normal;
    flex-wrap: wrap;
    line-height: 1.6;
    gap: 10px;
    text-align: center;
    justify-content: center;
}

.tg-wide-btn span {
    white-space: normal;
    word-break: break-word;
}

@media (max-width: 768px) {
    .tg-wide-btn {
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px !important;
        padding: 14px 16px !important;
        font-size: 0.9rem !important;
        line-height: 1.6 !important;
        text-align: center !important;
        width: 100% !important;
        max-width: 100% !important;
        min-height: 52px !important;
        background: var(--accent) !important;
        color: #0b0d13 !important;
        border-radius: var(--radius-sm) !important;
        box-shadow: 0 4px 16px var(--accent-glow) !important;
    }
    .tg-wide-btn span {
        white-space: normal !important;
        word-break: break-word !important;
        display: inline !important;
        line-height: 1.6 !important;
        flex: 1 1 auto !important;
        min-width: 0 !important;
    }
    .tg-wide-btn svg {
        flex-shrink: 0 !important;
        width: 20px !important;
        height: 20px !important;
        color: #0b0d13 !important;
    }
}

/* ==========================================================================
   Master Responsive Breakpoints (Mobile First & Adaptive)
   ========================================================================== */
@media (max-width: 992px) {
    .manifesto-grid { grid-template-columns: 1fr; }
    .pillars-grid { grid-template-columns: 1fr 1fr; }
    .bank-grid { grid-template-columns: 1fr 1fr; }
    .mentors-poster-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    html {
        font-size: 14.5px;
    }

    .container {
        padding: 0 16px;
    }

    .site-header {
        height: 60px;
    }

    .nav-container {
        height: 60px;
    }

    .header-cta-desktop {
        display: none !important;
    }

    .brand-name {
        font-size: 1rem;
    }

    .brand-sub {
        display: none;
    }

    .nav-menu {
        position: fixed;
        top: 60px;
        right: 0;
        transform: translateX(100%);
        width: 80%;
        max-width: 320px;
        height: calc(100vh - 60px);
        background: var(--bg-secondary);
        border-left: 1px solid var(--border-color);
        padding: 24px 18px;
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        transition: transform 0.25s ease, visibility 0.25s ease;
        visibility: hidden;
        z-index: 999999;
    }

    .nav-menu.open {
        transform: translateX(0) !important;
        display: flex !important;
        visibility: visible !important;
    }

    .menu-cta-mobile {
        display: block;
    }

    .hamburger {
        display: flex;
    }

    .hero-section {
        padding: 36px 0 28px;
    }

    .badge-pill {
        font-size: 0.76rem;
        padding: 4px 12px;
        margin-bottom: 14px;
    }

    .hero-title {
        font-size: 1.85rem;
        line-height: 1.35;
        margin-bottom: 12px;
    }

    .hero-desc {
    font-size: clamp(0.96rem, 2.3vw, 1.12rem);
    font-weight: 400;
    line-height: 1.95;
    max-width: 740px;
    margin: 0 auto 30px;
    color: var(--text-secondary);
}

    .hero-cta-group {
        flex-direction: column;
        gap: 10px;
        margin-bottom: 24px;
    }

    .hero-cta-group .btn {
        width: 100%;
        padding: 12px;
        font-size: 0.92rem;
    }

    .hero-stats-grid {
        grid-template-columns: 1fr;
        gap: 8px;
        max-width: 100%;
    }

    .stat-box-card {
        padding: 12px 14px;
    }

    .stat-title {
        font-size: 1.05rem;
    }

    .stat-subtitle {
        font-size: 0.8rem;
    }

    .section {
        padding: 40px 0;
    }

    .section-head {
        margin-bottom: 24px;
    }

    .section-title {
        font-size: 1.55rem;
    }

    .section-subtitle {
        font-size: 0.9rem;
    }

    .manifesto-card {
        padding: 20px 16px;
    }

    .features-subgrid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .sub-card {
        padding: 16px;
    }

    .sample-plan-main-card {
        padding: 18px 14px;
    }

    .sample-plan-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .sample-img-frame {
        max-height: 180px;
    }

    .sample-plans-3col-card {
        padding: 18px 14px;
    }

    .sample-plans-3col-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .col-divider {
        width: 100%;
        height: 1px;
    }

    .sample-col-img-wrap {
        height: 110px;
    }

    .pillars-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .pillar-card {
        padding: 18px 16px;
    }

    .bank-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .mentors-poster-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .mentor-content-box {
        padding: 18px 16px;
    }

    .guarantee-card {
        padding: 24px 16px;
    }

    .guarantee-card h2 {
        font-size: 1.5rem;
    }

    .guarantee-terms {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .term-box {
        padding: 14px;
    }

    .faq-trigger {
        padding: 14px 16px;
        font-size: 0.92rem;
    }

    .faq-content {
        padding: 0 16px 14px;
    }

    .booking-box {
        padding: 28px 16px;
    }

    .booking-box h2 {
        font-size: 1.5rem;
    }

    .booking-actions {
        flex-direction: column;
    }

    .booking-actions .btn {
        width: 100%;
    }

    .footer-content {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}

@media (max-width: 360px) {
    html {
        font-size: 13.5px;
    }

    .badge-pill {
        font-size: 0.72rem;
    }

    .hero-title {
        font-size: 1.65rem;
    }
}


/* ==========================================================================
   Sample Plan Image Viewer (Click to Zoom Lightbox)
   ========================================================================== */
.sample-col-img-wrap {
    position: relative;
    cursor: zoom-in;
    border-radius: var(--radius-sm);
    overflow: hidden;
}

.sample-col-img-wrap:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
}

.sample-col-img-wrap .sample-col-img {
    transition: transform 0.4s ease;
    display: block;
    width: 100%;
}

@media (hover: hover) and (pointer: fine) {
    .sample-col-img-wrap:hover .sample-col-img {
        transform: scale(1.06);
    }
}

.img-zoom-hint {
    position: absolute;
    bottom: 10px;
    right: 50%;
    transform: translateX(50%);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: rgba(10, 12, 16, 0.75);
    backdrop-filter: blur(6px);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: var(--radius-full);
    opacity: 0;
    transition: opacity 0.25s ease;
    pointer-events: none;
    white-space: nowrap;
}

@media (hover: hover) and (pointer: fine) {
    .sample-col-img-wrap:hover .img-zoom-hint {
        opacity: 1;
    }
}

/* Lightbox overlay */
.plan-lightbox {
    position: fixed;
    inset: 0;
    z-index: 999999;
    background: rgba(5, 7, 10, 0.92);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.plan-lightbox.active {
    opacity: 1;
}

.plan-lightbox-inner {
    position: relative;
    max-width: min(900px, 94vw);
    max-height: 92vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    transform: scale(0.94);
    transition: transform 0.25s ease;
}

.plan-lightbox.active .plan-lightbox-inner {
    transform: scale(1);
}

.plan-lightbox-title {
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.plan-lightbox-title::after,
.plan-lightbox-title::before {
    content: '';
    width: 40px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.plan-lightbox-img {
    max-width: 100%;
    max-height: calc(92vh - 60px);
    border-radius: var(--radius-md);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px var(--border-color);
    object-fit: contain;
}

.plan-lightbox-close {
    position: absolute;
    top: -18px;
    left: -18px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-primary);
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.plan-lightbox-close:hover {
    background: var(--accent);
    color: #0a0c10;
    transform: rotate(90deg);
}

/* ==========================================================================
   Bank Test Download Tree (manual accordion, no <details>)
   ========================================================================== */
.bank-tree {
    margin-top: 56px;
    padding: 28px 22px;
    border-radius: var(--radius-lg, 16px);
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.04) 0%, rgba(168, 85, 247, 0.04) 100%);
    border: 1px solid var(--border-color, rgba(255,255,255,0.08));
}

.bank-tree-head {
    text-align: center;
    margin-bottom: 28px;
}

.bank-tree-title {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: clamp(1.1rem, 2.5vw, 1.35rem);
    font-weight: 800;
    color: var(--text-primary);
    margin: 0 0 8px;
}

.bank-tree-title svg {
    color: var(--accent, #d4af37);
    flex-shrink: 0;
}

.bank-tree-sub {
    color: var(--text-secondary, #94a3b8);
    font-size: 0.92rem;
    margin: 0;
}

.bank-tree-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-top: 8px;
    align-items: start; /* critical: rows don't stretch to match tallest */
}

@media (max-width: 720px) {
    .bank-tree-grid { grid-template-columns: 1fr; }
}

.bank-tree-branch {
    background: var(--bg-card, #14161c);
    border: 1px solid var(--border-color, rgba(255,255,255,0.08));
    border-radius: var(--radius-md, 12px);
    overflow: hidden;
    transition: border-color 0.25s ease, transform 0.25s ease;
    /* fixed collapsed height for layout stability */
}

.bank-tree-branch.is-open {
    border-color: rgba(212, 175, 55, 0.4);
}

@media (hover: hover) and (pointer: fine) {
    .bank-tree-branch:hover { transform: translateY(-2px); }
}

.bank-tree-branch > .branch-summary {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 18px;
    cursor: pointer;
    user-select: none;
    position: relative;
    transition: background 0.2s ease;
}

.bank-tree-branch > .branch-summary:hover {
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.10) 0%, rgba(168, 85, 247, 0.06) 100%);
}

.branch-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: color-mix(in srgb, var(--c) 18%, transparent);
    color: var(--c);
    flex-shrink: 0;
    border: 1px solid color-mix(in srgb, var(--c) 30%, transparent);
}

.branch-name {
    flex: 1;
    font-weight: 700;
    color: var(--text-primary);
    font-size: 1.05rem;
}

.branch-count {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary, #94a3b8);
    background: rgba(255, 255, 255, 0.04);
    padding: 3px 10px;
    border-radius: 999px;
    border: 1px solid var(--border-color, rgba(255,255,255,0.08));
}

.branch-chev {
    display: inline-flex;
    color: var(--text-secondary, #94a3b8);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.bank-tree-branch.is-open > .branch-summary .branch-chev {
    transform: rotate(180deg);
    color: var(--accent, #d4af37);
}

.bank-tree-files {
    list-style: none;
    margin: 0;
    padding: 0 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

.bank-tree-branch.is-open .bank-tree-files {
    max-height: 800px;
    opacity: 1;
    padding: 12px 14px 14px;
}

.bank-tree-files li { margin: 0; }

.bank-tree-files a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    min-width: 0;
}

@media (hover: hover) and (pointer: fine) {
    .bank-tree-files a:hover {
        background: rgba(212, 175, 55, 0.08);
        border-color: rgba(212, 175, 55, 0.3);
        transform: translateX(-4px);
    }
    .light-theme .bank-tree-files a:hover {
        background: rgba(212, 175, 55, 0.12);
    }
}

.bank-tree-files a:focus-visible {
    outline: 2px solid var(--accent, #d4af37);
    outline-offset: 2px;
}

.file-pdf {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 24px;
    padding: 0 8px;
    border-radius: 5px;
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: #fff;
    font-size: 0.7rem;
    font-weight: 800;
    letter-spacing: 0.5px;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(239, 68, 68, 0.3);
}

.file-name {
    flex: 1;
    font-weight: 600;
    font-size: 0.93rem;
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    min-width: 0;
}

.file-size {
    font-size: 0.78rem;
    color: var(--text-secondary, #94a3b8);
    flex-shrink: 0;
    font-variant-numeric: tabular-nums;
}

.file-go {
    font-size: 0.82rem;
    color: var(--accent, #d4af37);
    font-weight: 700;
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

@media (hover: hover) and (pointer: fine) {
    .bank-tree-files a:hover .file-go { transform: translateX(-4px); }
}

.bank-tree-foot {
    text-align: center;
    margin: 22px 0 0;
    color: var(--text-secondary, #94a3b8);
    font-size: 0.85rem;
    line-height: 1.7;
}

@media (max-width: 480px) {
    .bank-tree { padding: 22px 14px; margin-top: 38px; }
    .file-size { display: none; }
    .branch-count { font-size: 0.72rem; padding: 2px 8px; }
    .bank-tree-files a { padding: 9px 10px; gap: 8px; }
    .file-name { font-size: 0.88rem; }
}
