/* ==========================================================================
   MaktabCMS Flagship Theme - Modern Public School Portal (Flagship)
   World-Class UI/UX with Vazirmatn Typography & Dark/Light Mode
   ========================================================================== */

/* --------------------------------------------------------------------------
   0. FONTS & TYPOGRAPHY (@font-face)
   -------------------------------------------------------------------------- */
@font-face {
    font-family: 'Vazirmatn';
    src: url('/assets/fonts/vazir/Vazir-Regular.woff2') format('woff2'),
         url('/assets/fonts/vazir/Vazir-Regular.woff') format('woff'),
         url('/assets/fonts/vazir/Vazir-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('/assets/fonts/vazir/Vazir-Medium.woff2') format('woff2'),
         url('/assets/fonts/vazir/Vazir-Medium.woff') format('woff'),
         url('/assets/fonts/vazir/Vazir-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('/assets/fonts/vazir/Vazir-Bold.woff2') format('woff2'),
         url('/assets/fonts/vazir/Vazir-Bold.woff') format('woff'),
         url('/assets/fonts/vazir/Vazir-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Vazirmatn';
    src: url('/assets/fonts/vazir/Vazir-Black.woff2') format('woff2'),
         url('/assets/fonts/vazir/Vazir-Black.woff') format('woff'),
         url('/assets/fonts/vazir/Vazir-Black.ttf') format('truetype');
    font-weight: 900;
    font-style: normal;
    font-display: swap;
}

/* Also map Vazir alias */
@font-face {
    font-family: 'Vazir';
    src: url('/assets/fonts/vazir/Vazir-Regular.woff2') format('woff2');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}
@font-face {
    font-family: 'Vazir';
    src: url('/assets/fonts/vazir/Vazir-Bold.woff2') format('woff2');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

/* --------------------------------------------------------------------------
   1. DESIGN TOKENS & CSS VARIABLES
   -------------------------------------------------------------------------- */
:root {
    /* Color Palette - Light Mode */
    --theme-primary: #1d4ed8;
    --theme-primary-hover: #1e40af;
    --theme-primary-light: #eff6ff;
    --theme-primary-glow: rgba(29, 78, 216, 0.22);
    
    --theme-secondary: #0284c7;
    --theme-secondary-hover: #0369a1;
    --theme-secondary-light: #f0f9ff;
    
    --theme-accent: #f59e0b;
    --theme-accent-hover: #d97706;
    --theme-accent-light: #fffbeb;
    
    --theme-success: #10b981;
    --theme-success-light: #ecfdf5;
    --theme-danger: #ef4444;
    --theme-info: #06b6d4;
    
    /* Backgrounds & Surfaces */
    --theme-bg: #f8fafc;
    --theme-surface: #ffffff;
    --theme-surface-subtle: #f1f5f9;
    --theme-surface-elevated: #ffffff;
    --theme-card-bg: #ffffff;
    --theme-card-border: #e2e8f0;
    
    /* Typography */
    --theme-text: #0f172a;
    --theme-text-heading: #0f172a;
    --theme-text-secondary: #334155;
    --theme-text-muted: #64748b;
    
    /* Inputs & Borders */
    --theme-border: #e2e8f0;
    --theme-border-subtle: #f1f5f9;
    --theme-input-bg: #ffffff;
    --theme-input-border: #cbd5e1;
    --theme-input-focus-border: #3b82f6;
    
    /* Navigation & Utility */
    --theme-topbar-bg: #0b1329;
    --theme-topbar-text: #cbd5e1;
    --theme-navbar-bg: rgba(255, 255, 255, 0.95);
    --theme-navbar-border: #e2e8f0;
    --theme-footer-bg: #080e1e;
    --theme-footer-text: #94a3b8;
    --theme-dropdown-bg: #ffffff;
    --theme-dropdown-hover: #f1f5f9;
    
    /* Shadows & Radii */
    --theme-shadow-xs: 0 1px 3px rgba(15, 23, 42, 0.05);
    --theme-shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.05);
    --theme-shadow-md: 0 10px 25px -5px rgba(15, 23, 42, 0.06), 0 8px 10px -6px rgba(15, 23, 42, 0.04);
    --theme-shadow-lg: 0 20px 30px -10px rgba(15, 23, 42, 0.1);
    --theme-shadow-card: 0 4px 24px rgba(15, 23, 42, 0.05);
    --theme-shadow-card-hover: 0 16px 36px rgba(15, 23, 42, 0.12);
    
    --theme-radius-sm: 10px;
    --theme-radius: 16px;
    --theme-radius-lg: 24px;
    --theme-radius-full: 9999px;

    --theme-transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);

    /* Text on a primary-colored fill, and the background of page banners */
    --theme-on-primary: #ffffff;
    --theme-hero-bg: linear-gradient(135deg, #1e3a8a 0%, #0f172a 100%);

    /* The Bootstrap build (MDB) brings its own palette: blue primary and PURPLE secondary, so
       .text-secondary labels turned purple and .bg-primary ignored the theme. Each theme sets
       these to its own colors (the -rgb values must match the hex ones). */
    --mdb-primary: #1d4ed8;
    --mdb-primary-rgb: 29, 78, 216;
    --mdb-secondary: #64748b;
    --mdb-secondary-rgb: 100, 116, 139;
    --mdb-success: #10b981;
    --mdb-success-rgb: 16, 185, 129;
    --mdb-info: #06b6d4;
    --mdb-info-rgb: 6, 182, 212;
    --mdb-danger: #ef4444;
    --mdb-danger-rgb: 239, 68, 68;
    /* .font-monospace on Persian fields and placeholders fell back to Courier; keep the site font */
    --mdb-font-monospace: 'Vazirmatn', 'Vazir', Tahoma, sans-serif;
}

/* Dark Mode Tokens */
[data-theme="dark"] {
    --mdb-primary: #3b82f6;
    --mdb-primary-rgb: 59, 130, 246;
    --mdb-secondary: #94a3b8;
    --mdb-secondary-rgb: 148, 163, 184;
    --mdb-success: #34d399;
    --mdb-success-rgb: 52, 211, 153;
    --mdb-info: #22d3ee;
    --mdb-info-rgb: 34, 211, 238;
    --mdb-danger: #f87171;
    --mdb-danger-rgb: 248, 113, 113;

    --theme-primary: #3b82f6;
    --theme-primary-hover: #60a5fa;
    --theme-primary-light: rgba(59, 130, 246, 0.16);
    --theme-primary-glow: rgba(59, 130, 246, 0.4);
    
    --theme-secondary: #38bdf8;
    --theme-secondary-hover: #7dd3fc;
    --theme-secondary-light: rgba(56, 189, 248, 0.15);
    
    --theme-accent: #fbbf24;
    --theme-accent-hover: #f59e0b;
    --theme-accent-light: rgba(251, 191, 36, 0.15);
    
    --theme-success: #34d399;
    --theme-success-light: rgba(52, 211, 153, 0.15);
    --theme-danger: #f87171;
    --theme-info: #22d3ee;
    
    /* Dark Backgrounds */
    --theme-bg: #090d16;
    --theme-surface: #111827;
    --theme-surface-subtle: #172133;
    --theme-surface-elevated: #1e293b;
    --theme-card-bg: #111a2d;
    --theme-card-border: #1e2d45;
    
    /* Dark Typography */
    --theme-text: #e2e8f0;
    --theme-text-heading: #f8fafc;
    --theme-text-secondary: #94a3b8;
    --theme-text-muted: #64748b;
    
    /* Dark Inputs & Borders */
    --theme-border: #1e2d45;
    --theme-border-subtle: #172133;
    --theme-input-bg: #0c1322;
    --theme-input-border: #293852;
    --theme-input-focus-border: #3b82f6;
    
    /* Dark Navigation & Utility */
    --theme-topbar-bg: #050811;
    --theme-topbar-text: #94a3b8;
    --theme-navbar-bg: rgba(13, 20, 35, 0.94);
    --theme-navbar-border: #1a273e;
    --theme-footer-bg: #04070e;
    --theme-footer-text: #7b8fa7;
    --theme-dropdown-bg: #131c30;
    --theme-dropdown-hover: #1c2842;
    
    /* Dark Shadows */
    --theme-shadow-xs: 0 1px 3px rgba(0, 0, 0, 0.4);
    --theme-shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.5);
    --theme-shadow-md: 0 10px 25px -5px rgba(0, 0, 0, 0.6);
    --theme-shadow-lg: 0 20px 35px -10px rgba(0, 0, 0, 0.7);
    --theme-shadow-card: 0 4px 24px rgba(0, 0, 0, 0.5);
    --theme-shadow-card-hover: 0 16px 36px rgba(0, 0, 0, 0.7);
}

/* --------------------------------------------------------------------------
   2. GLOBAL RESETS & MODERN TYPOGRAPHY
   -------------------------------------------------------------------------- */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Vazirmatn', 'Vazir', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
    background-color: var(--theme-bg);
    color: var(--theme-text);
    direction: rtl;
    text-align: right;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    line-height: 1.75;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
    font-family: 'Vazirmatn', 'Vazir', sans-serif !important;
    font-weight: 800;
    color: var(--theme-text-heading);
}

a {
    color: var(--theme-secondary);
    text-decoration: none;
    transition: var(--theme-transition);
}

a:hover {
    color: var(--theme-primary);
}

button, input, select, textarea {
    font-family: inherit;
}

/* MDB repeats some color utilities later with fixed values; send them back to the theme tokens
   (keeping --mdb-bg-opacity, so ".bg-primary bg-opacity-10" stays a light tint) */
.bg-primary { background-color: rgba(var(--mdb-primary-rgb), var(--mdb-bg-opacity, 1)) !important; }
.bg-secondary { background-color: rgba(var(--mdb-secondary-rgb), var(--mdb-bg-opacity, 1)) !important; }
.bg-success { background-color: rgba(var(--mdb-success-rgb), var(--mdb-bg-opacity, 1)) !important; }
.bg-info { background-color: rgba(var(--mdb-info-rgb), var(--mdb-bg-opacity, 1)) !important; }
.bg-danger { background-color: rgba(var(--mdb-danger-rgb), var(--mdb-bg-opacity, 1)) !important; }
.bg-primary:not([class*="bg-opacity"]).text-white,
.bg-primary:not([class*="bg-opacity"]) .text-white { color: var(--theme-on-primary) !important; }

.btn-primary,
.btn-primary:focus {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
    color: var(--theme-on-primary);
}
.btn-primary:hover,
.btn-primary:active,
.btn-primary.active {
    background-color: var(--theme-primary-hover) !important;
    border-color: var(--theme-primary-hover) !important;
    color: var(--theme-on-primary) !important;
}
.btn-outline-primary {
    color: var(--theme-primary);
    border-color: var(--theme-primary);
}
.btn-outline-primary:hover,
.btn-outline-primary.active {
    background-color: var(--theme-primary);
    border-color: var(--theme-primary);
    color: var(--theme-on-primary);
}

/* success buttons and info/success alerts follow the theme's palette too (Masir sets its own tokens) */
.btn-success,
.btn-success:focus {
    background-color: rgba(var(--mdb-success-rgb), 1);
    border-color: rgba(var(--mdb-success-rgb), 1);
    color: #fff;
}
.btn-success:hover,
.btn-success:active,
.btn-success.active {
    background-color: rgba(var(--mdb-success-rgb), 0.88) !important;
    border-color: rgba(var(--mdb-success-rgb), 0.88) !important;
    color: #fff !important;
}
.btn-outline-success {
    color: rgba(var(--mdb-success-rgb), 1);
    border-color: rgba(var(--mdb-success-rgb), 1);
}
.btn-outline-success:hover,
.btn-outline-success.active {
    background-color: rgba(var(--mdb-success-rgb), 1);
    border-color: rgba(var(--mdb-success-rgb), 1);
    color: #fff;
}
.alert-info {
    background-color: rgba(var(--mdb-info-rgb), 0.12);
    border-color: rgba(var(--mdb-info-rgb), 0.3);
    color: var(--theme-text, inherit);
}
.alert-success {
    background-color: rgba(var(--mdb-success-rgb), 0.12);
    border-color: rgba(var(--mdb-success-rgb), 0.3);
    color: var(--theme-text, inherit);
}

/* Persian placeholders in the site font, never in a code font */
.font-monospace { font-variant-numeric: tabular-nums; letter-spacing: normal; }
input::placeholder,
textarea::placeholder {
    font-family: 'Vazirmatn', 'Vazir', Tahoma, sans-serif;
    letter-spacing: normal;
    color: var(--theme-text-muted);
    opacity: 0.75;
}
/* trust seals (e-Namad, Samandehi) of «اطلاعات مدرسه» in the site footer */
.school-trust-seals img {
    width: 92px;
    height: 92px;
    object-fit: contain;
    padding: 6px;
    border-radius: 14px;
    background: #fff;
}

/* an empty left-to-right field (mobile, national code) shows its Persian placeholder right-to-left */
input[dir="ltr"]:placeholder-shown,
textarea[dir="ltr"]:placeholder-shown { direction: rtl; }

/* Bootstrap Theme Adaptations */
[data-theme="dark"] .bg-white {
    background-color: var(--theme-card-bg) !important;
}

[data-theme="dark"] .bg-light {
    background-color: var(--theme-surface-subtle) !important;
}

[data-theme="dark"] .text-dark {
    color: var(--theme-text-heading) !important;
}

[data-theme="dark"] .text-secondary {
    color: var(--theme-text-secondary) !important;
}

[data-theme="dark"] .text-muted {
    color: var(--theme-text-muted) !important;
}

[data-theme="dark"] .border,
[data-theme="dark"] .border-top,
[data-theme="dark"] .border-bottom,
[data-theme="dark"] .border-start,
[data-theme="dark"] .border-end {
    border-color: var(--theme-border) !important;
}

[data-theme="dark"] .card {
    background-color: var(--theme-card-bg);
    border-color: var(--theme-card-border);
    color: var(--theme-text);
}

/* --------------------------------------------------------------------------
   3. THEME TOGGLE SWITCH COMPONENT
   -------------------------------------------------------------------------- */
.theme-switch-btn {
    width: 38px;
    height: 38px;
    border-radius: 12px;
    background: var(--theme-surface-subtle);
    border: 1.5px solid var(--theme-border);
    color: var(--theme-text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.25rem;
    transition: var(--theme-transition);
    box-shadow: var(--theme-shadow-xs);
}

.top-utility-bar .theme-switch-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #f8fafc;
    width: 30px;
    height: 30px;
    font-size: 1rem;
    border-radius: 8px;
}

.theme-switch-btn:hover {
    transform: translateY(-2px) scale(1.05);
    background: var(--theme-primary-light);
    color: var(--theme-primary);
    border-color: var(--theme-primary);
}

/* --------------------------------------------------------------------------
   4. TOP UTILITY BAR
   -------------------------------------------------------------------------- */
.top-utility-bar {
    background: var(--theme-topbar-bg);
    color: var(--theme-topbar-text);
    font-size: 0.82rem;
    padding: 7px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: background-color 0.3s ease;
}

.top-utility-bar a {
    color: var(--theme-topbar-text);
}

.top-utility-bar a:hover {
    color: #ffffff;
}

.discreet-admin-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    padding: 2px 9px;
    border-radius: 6px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.65) !important;
    text-decoration: none !important;
    transition: var(--theme-transition);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.discreet-admin-link:hover {
    background: rgba(255, 255, 255, 0.18);
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.25);
    transform: translateY(-1px);
}

.top-bar-social {
    display: flex;
    align-items: center;
    gap: 8px;
}

.social-icon-btn {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 0.88rem;
    transition: var(--theme-transition);
}

.social-icon-btn:hover {
    background: var(--theme-primary);
    color: #fff;
    transform: translateY(-2px);
}

/* --------------------------------------------------------------------------
   5. MAIN PUBLIC NAVBAR (GLASSMORPHISM & COMPACT)
   -------------------------------------------------------------------------- */
.public-navbar {
    background: var(--theme-navbar-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--theme-navbar-border);
    padding: 6px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    z-index: 1030;
    transition: background-color 0.3s ease, border-color 0.3s ease;
}

.school-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--theme-text);
}

.school-logo-img {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    object-fit: cover;
    background: var(--theme-surface);
    padding: 2px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    border: 1px solid var(--theme-border);
}

.school-name-text {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    margin: 0;
    line-height: 1.25;
    letter-spacing: -0.2px;
}

.school-doreh-text {
    font-size: 0.74rem;
    color: var(--theme-text-muted);
    display: block;
}

.public-nav-link {
    font-size: 0.84rem;
    font-weight: 600;
    color: var(--theme-text-secondary);
    padding: 6px 11px;
    border-radius: 9px;
    text-decoration: none;
    transition: var(--theme-transition);
    display: inline-flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
}

.public-nav-link i {
    font-size: 1.1rem;
}

.nav-arrow {
    font-size: 0.72rem;
    margin-right: 2px;
}

.public-nav-link:hover,
.public-nav-link.active {
    color: var(--theme-primary);
    background: var(--theme-primary-light);
}

.public-nav-link.nav-link-highlight {
    color: var(--theme-primary);
    background: var(--theme-primary-light);
    border: 1px solid rgba(37, 99, 235, 0.2);
}

.nav-item-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: var(--theme-dropdown-bg);
    border: 1px solid var(--theme-border);
    border-radius: 14px;
    box-shadow: var(--theme-shadow-lg);
    padding: 8px 0;
    min-width: 230px;
    display: none;
    z-index: 1050;
    backdrop-filter: blur(12px);
}

.nav-item-dropdown:hover .nav-dropdown-menu {
    display: block;
    animation: fadeInMenu 0.22s ease forwards;
}

@keyframes fadeInMenu {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 18px;
    font-size: 0.88rem;
    color: var(--theme-text-secondary);
    font-weight: 600;
    transition: var(--theme-transition);
}

.nav-dropdown-item:hover {
    background: var(--theme-dropdown-hover);
    color: var(--theme-primary);
    padding-right: 22px;
}

.btn-portal-login {
    background: linear-gradient(135deg, #1d4ed8 0%, #0284c7 100%);
    color: #fff !important;
    font-weight: 700;
    font-size: 0.86rem;
    padding: 8px 18px;
    border-radius: 12px;
    text-decoration: none;
    transition: var(--theme-transition);
    box-shadow: 0 4px 14px rgba(2, 132, 199, 0.3);
    display: inline-flex;
    align-items: center;
    gap: 7px;
    border: none;
    white-space: nowrap;
}

.btn-portal-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(2, 132, 199, 0.45);
    color: #fff !important;
}

/* ---------------------------------------------------------
   6. BREAKING NEWS TICKER
   --------------------------------------------------------- */
.ticker-bar-wrapper {
    background: var(--theme-surface);
    border-bottom: 1px solid var(--theme-border);
    padding: 8px 0;
    box-shadow: var(--theme-shadow-xs);
    transition: background-color 0.3s ease;
}

.ticker-badge {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 8px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.ticker-content {
    overflow: hidden;
    white-space: nowrap;
    position: relative;
    font-size: 0.88rem;
    color: var(--theme-text-secondary);
    font-weight: 500;
}

.ticker-content a {
    color: var(--theme-text-heading);
}

.ticker-content a:hover {
    color: var(--theme-primary);
}

/* ---------------------------------------------------------
   7. HERO BANNER & SHOWCASE
   --------------------------------------------------------- */
.school-hero-public {
    background: radial-gradient(circle at 85% 20%, rgba(29, 78, 216, 0.9) 0%, #0f172a 75%), linear-gradient(135deg, #090d16 0%, #1e293b 100%);
    color: #fff;
    border-radius: var(--theme-radius-lg);
    padding: 56px 44px;
    margin: 20px 0 36px 0;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.school-hero-public::before {
    content: '';
    position: absolute;
    top: -80px;
    left: -80px;
    width: 340px;
    height: 340px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.3) 0%, rgba(0,0,0,0) 70%);
    pointer-events: none;
}

.hero-pill-badge {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: #93c5fd;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 6px 16px;
    border-radius: var(--theme-radius-full);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    backdrop-filter: blur(8px);
}

.hero-title {
    font-size: 2.2rem;
    font-weight: 900;
    line-height: 1.4;
    letter-spacing: -0.5px;
    color: #ffffff;
}

.hero-lead {
    font-size: 1.05rem;
    color: #cbd5e1;
    line-height: 1.85;
}

.hero-feature-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.hero-feature-pill {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    padding: 6px 14px;
    font-size: 0.82rem;
    color: #e2e8f0;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    backdrop-filter: blur(6px);
}

/* ---------------------------------------------------------
   8. ANDROID APP & UNIFIED LOGIN SHOWCASE SECTION
   --------------------------------------------------------- */
.app-login-showcase {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: var(--theme-radius-lg);
    padding: 42px 36px;
    margin: 40px 0;
    box-shadow: var(--theme-shadow-card);
    position: relative;
    overflow: hidden;
    transition: var(--theme-transition);
}

.app-login-showcase::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 320px;
    height: 320px;
    background: radial-gradient(circle, var(--theme-primary-light) 0%, transparent 70%);
    pointer-events: none;
    opacity: 0.7;
}

/* Phone Mockup 3D Presentation */
.phone-mockup-wrapper {
    position: relative;
    display: inline-block;
    padding: 18px;
}

.phone-mockup-frame {
    width: 270px;
    height: 520px;
    background: #0f172a;
    border-radius: 42px;
    border: 6px solid #334155;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45), 0 0 40px var(--theme-primary-glow);
    padding: 12px 10px;
    position: relative;
    margin: 0 auto;
    overflow: hidden;
}

.phone-notch {
    width: 110px;
    height: 20px;
    background: #0f172a;
    border-radius: 0 0 14px 14px;
    margin: 0 auto 10px auto;
    position: relative;
    z-index: 5;
}

.phone-screen-content {
    background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
    border-radius: 30px;
    height: 465px;
    padding: 16px 12px;
    color: #fff;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.phone-app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.phone-app-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.8rem;
    font-weight: 700;
}

.phone-widget-card {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 10px;
    font-size: 0.74rem;
}

/* Floating Notification Pills */
.floating-notif-pill {
    position: absolute;
    background: var(--theme-surface);
    color: var(--theme-text);
    border: 1px solid var(--theme-border);
    padding: 8px 14px;
    border-radius: var(--theme-radius-full);
    box-shadow: var(--theme-shadow-md);
    font-size: 0.76rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    z-index: 10;
    animation: floatAnim 3.5s ease-in-out infinite alternate;
}

.floating-notif-pill.pill-top-right {
    top: 25px;
    right: -20px;
    animation-delay: 0.2s;
}

.floating-notif-pill.pill-bottom-left {
    bottom: 45px;
    left: -25px;
    animation-delay: 1.5s;
}

@keyframes floatAnim {
    0% { transform: translateY(0); }
    100% { transform: translateY(-8px); }
}

/* App Features Grid */
.app-feature-card {
    background: var(--theme-surface-subtle);
    border: 1px solid var(--theme-border);
    border-radius: 14px;
    padding: 14px 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    transition: var(--theme-transition);
}

.app-feature-card:hover {
    transform: translateY(-3px);
    border-color: var(--theme-primary);
    box-shadow: var(--theme-shadow-sm);
}

.app-feature-icon {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--theme-primary-light);
    color: var(--theme-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.app-feature-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--theme-text-heading);
    margin-bottom: 2px;
}

.app-feature-desc {
    font-size: 0.76rem;
    color: var(--theme-text-muted);
    line-height: 1.5;
    margin: 0;
}

/* Download Badges */
.app-download-btn {
    background: var(--theme-surface-subtle);
    border: 1.5px solid var(--theme-border);
    border-radius: 14px;
    padding: 10px 18px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: var(--theme-text-heading);
    text-decoration: none;
    font-weight: 700;
    transition: var(--theme-transition);
}

.app-download-btn:hover {
    background: var(--theme-primary);
    color: #fff !important;
    border-color: var(--theme-primary);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px var(--theme-primary-glow);
}

.app-download-btn i {
    font-size: 1.6rem;
}

/* Portal Login Hub Box */
.portal-login-box {
    background: linear-gradient(135deg, rgba(29, 78, 216, 0.04) 0%, rgba(2, 132, 199, 0.07) 100%);
    border: 1.5px solid var(--theme-border);
    border-radius: var(--theme-radius);
    padding: 24px;
}

.role-login-card {
    background: var(--theme-surface);
    border: 1px solid var(--theme-border);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-decoration: none;
    color: var(--theme-text);
    transition: var(--theme-transition);
}

.role-login-card:hover {
    border-color: var(--theme-primary);
    transform: translateY(-2px);
    box-shadow: var(--theme-shadow-sm);
    color: var(--theme-text);
}

.role-login-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

/* ---------------------------------------------------------
   9. ELECTRONIC SERVICES HUB (BENTO CARDS)
   --------------------------------------------------------- */
.services-section-title {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    display: flex;
    align-items: center;
    gap: 10px;
}

.service-hub-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: var(--theme-radius);
    padding: 24px 20px;
    display: flex;
    align-items: flex-start;
    gap: 18px;
    text-decoration: none;
    color: var(--theme-text);
    box-shadow: var(--theme-shadow-card);
    transition: var(--theme-transition);
    height: 100%;
    position: relative;
    overflow: hidden;
}

.service-hub-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    height: 3.5px;
    background: transparent;
    transition: var(--theme-transition);
}

.service-hub-card:hover {
    transform: translateY(-5px);
    border-color: var(--theme-primary);
    box-shadow: var(--theme-shadow-card-hover);
    color: var(--theme-text);
}

.service-hub-card:hover::after {
    background: linear-gradient(90deg, var(--theme-primary) 0%, var(--theme-secondary) 100%);
}

.service-icon-box {
    width: 58px;
    height: 58px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    flex-shrink: 0;
    transition: var(--theme-transition);
}

.service-hub-card:hover .service-icon-box {
    transform: scale(1.08) rotate(3deg);
}

.icon-blue-grad { background: rgba(37, 99, 235, 0.12); color: #2563eb; }
.icon-green-grad { background: rgba(16, 185, 129, 0.12); color: #10b981; }
.icon-amber-grad { background: rgba(245, 158, 11, 0.12); color: #f59e0b; }
.icon-purple-grad { background: rgba(124, 58, 237, 0.12); color: #8b5cf6; }
.icon-rose-grad { background: rgba(225, 29, 72, 0.12); color: #f43f5e; }
.icon-cyan-grad { background: rgba(8, 145, 178, 0.12); color: #06b6d4; }

.service-card-title {
    font-size: 1.05rem;
    font-weight: 800;
    margin-bottom: 6px;
    color: var(--theme-text-heading);
}

.service-card-desc {
    font-size: 0.83rem;
    color: var(--theme-text-muted);
    line-height: 1.55;
    margin-bottom: 0;
}

/* ---------------------------------------------------------
   10. STATS COUNTER BAR
   --------------------------------------------------------- */
.stats-counter-banner {
    background: radial-gradient(circle at 10% 20%, rgba(29, 78, 216, 0.8) 0%, #0f172a 80%), linear-gradient(135deg, #090d16 0%, #1e293b 100%);
    border-radius: var(--theme-radius);
    padding: 36px 28px;
    color: #fff;
    margin: 40px 0;
    box-shadow: var(--theme-shadow-md);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-box {
    text-align: center;
    padding: 12px;
}

.stat-number {
    font-size: 2.3rem;
    font-weight: 900;
    color: #ffffff;
    line-height: 1;
    margin-bottom: 8px;
    font-feature-settings: "tnum";
}

.stat-number span {
    color: var(--theme-accent);
}

.stat-label {
    font-size: 0.9rem;
    color: #cbd5e1;
    font-weight: 600;
}

/* ---------------------------------------------------------
   11. PRINCIPAL'S SPEECH & MISSION
   --------------------------------------------------------- */
.principal-speech-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: var(--theme-radius);
    padding: 36px;
    box-shadow: var(--theme-shadow-card);
    position: relative;
    overflow: hidden;
    transition: var(--theme-transition);
}

.principal-speech-card::before {
    content: '“';
    position: absolute;
    top: -20px;
    left: 20px;
    font-size: 130px;
    color: rgba(29, 78, 216, 0.06);
    font-family: serif;
    line-height: 1;
    pointer-events: none;
}

.principal-avatar {
    width: 110px;
    height: 110px;
    border-radius: 24px;
    object-fit: cover;
    border: 3px solid var(--theme-border);
    box-shadow: var(--theme-shadow-sm);
}

.principal-name {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    margin-bottom: 4px;
}

.principal-title {
    font-size: 0.85rem;
    color: var(--theme-secondary);
    font-weight: 600;
}

.speech-text {
    font-size: 0.95rem;
    line-height: 1.85;
    color: var(--theme-text-secondary);
}

/* ---------------------------------------------------------
   12. NEWS & EVENTS CARDS
   --------------------------------------------------------- */
.news-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: 18px;
    overflow: hidden;
    box-shadow: var(--theme-shadow-card);
    transition: var(--theme-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--theme-shadow-card-hover);
    border-color: var(--theme-primary);
}

.news-card-img-wrap {
    position: relative;
    overflow: hidden;
    height: 200px;
    background: var(--theme-surface-subtle);
}

.news-card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.news-card:hover .news-card-img {
    transform: scale(1.06);
}

.news-date-badge {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: rgba(15, 23, 42, 0.85);
    color: #ffffff;
    font-size: 0.76rem;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 8px;
    backdrop-filter: blur(6px);
}

.news-card-body {
    padding: 22px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.news-card-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    line-height: 1.55;
    margin-bottom: 10px;
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card-title:hover {
    color: var(--theme-primary);
}

.news-card-summary {
    font-size: 0.86rem;
    color: var(--theme-text-muted);
    line-height: 1.65;
    margin-bottom: 16px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-meta {
    font-size: 0.8rem;
    color: var(--theme-text-muted);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 14px;
    border-top: 1px solid var(--theme-border);
}

/* ---------------------------------------------------------
   13. FACILITIES SHOWCASE
   --------------------------------------------------------- */
.facility-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: 18px;
    padding: 24px;
    height: 100%;
    transition: var(--theme-transition);
    box-shadow: var(--theme-shadow-card);
}

.facility-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--theme-shadow-card-hover);
    border-color: var(--theme-primary);
}

.facility-icon {
    width: 50px;
    height: 50px;
    border-radius: 14px;
    background: var(--theme-primary-light);
    color: var(--theme-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    margin-bottom: 16px;
}

.facility-title {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    margin-bottom: 8px;
}

.facility-desc {
    font-size: 0.85rem;
    color: var(--theme-text-muted);
    line-height: 1.65;
    margin-bottom: 0;
}

/* ---------------------------------------------------------
   14. TEACHERS & FACULTY CARDS
   --------------------------------------------------------- */
.teacher-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: 18px;
    padding: 24px 18px;
    text-align: center;
    box-shadow: var(--theme-shadow-card);
    transition: var(--theme-transition);
    height: 100%;
}

.teacher-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--theme-shadow-card-hover);
    border-color: var(--theme-primary);
}

.teacher-avatar {
    width: 86px;
    height: 86px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 14px auto;
    border: 3px solid var(--theme-primary-light);
    box-shadow: var(--theme-shadow-sm);
}

.teacher-name {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    margin-bottom: 4px;
}

.teacher-subject {
    font-size: 0.82rem;
    color: var(--theme-secondary);
    font-weight: 600;
    margin-bottom: 12px;
}

.teacher-badge {
    background: var(--theme-surface-subtle);
    color: var(--theme-text-secondary);
    font-size: 0.78rem;
    padding: 4px 12px;
    border-radius: var(--theme-radius-full);
    display: inline-block;
}

/* ---------------------------------------------------------
   15. PHOTO GALLERY & LIGHTBOX
   --------------------------------------------------------- */
.gallery-thumbnail-card {
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    height: 210px;
    box-shadow: var(--theme-shadow-card);
    cursor: pointer;
    background: var(--theme-surface-subtle);
}

.gallery-thumbnail-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.gallery-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(15, 23, 42, 0.85) 0%, rgba(15, 23, 42, 0) 65%);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 16px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.gallery-thumbnail-card:hover img {
    transform: scale(1.08);
}

.gallery-thumbnail-card:hover .gallery-overlay {
    opacity: 1;
}

.gallery-title-text {
    color: #ffffff;
    font-weight: 700;
    font-size: 0.88rem;
    margin: 0;
}

/* ---------------------------------------------------------
   16. HONOR ROLL & TESTIMONIALS
   --------------------------------------------------------- */
.honor-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: 18px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--theme-shadow-card);
    transition: var(--theme-transition);
}

.honor-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--theme-shadow-card-hover);
    border-color: var(--theme-primary);
}

.honor-badge-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(245, 158, 11, 0.15);
    color: var(--theme-accent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.honor-student-name {
    font-weight: 800;
    font-size: 0.98rem;
    color: var(--theme-text-heading);
    margin-bottom: 2px;
}

.honor-achievement {
    font-size: 0.8rem;
    color: var(--theme-text-muted);
}

.testimonial-card {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: 18px;
    padding: 24px;
    box-shadow: var(--theme-shadow-card);
    height: 100%;
}

.testimonial-stars {
    color: var(--theme-accent);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.testimonial-text {
    font-size: 0.88rem;
    color: var(--theme-text-secondary);
    line-height: 1.75;
    margin-bottom: 16px;
    font-style: italic;
}

.testimonial-author {
    font-size: 0.84rem;
    font-weight: 700;
    color: var(--theme-text-heading);
}

/* ---------------------------------------------------------
   17. FORM CARDS & MODERN INPUTS
   --------------------------------------------------------- */
.form-card-public {
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: var(--theme-radius-lg);
    padding: 36px 32px;
    box-shadow: var(--theme-shadow-card);
    transition: var(--theme-transition);
}

.form-label {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--theme-text-heading);
    margin-bottom: 6px;
}

.form-control, .form-select {
    border-radius: 12px;
    border: 1.5px solid var(--theme-input-border);
    padding: 11px 16px;
    font-size: 0.92rem;
    transition: var(--theme-transition);
    background-color: var(--theme-input-bg);
    color: var(--theme-text);
}

.form-control:focus, .form-select:focus {
    border-color: var(--theme-input-focus-border);
    box-shadow: 0 0 0 4px var(--theme-primary-light);
    background-color: var(--theme-input-bg);
    color: var(--theme-text);
}

.input-group-text {
    background-color: var(--theme-surface-subtle);
    border-color: var(--theme-input-border);
    color: var(--theme-text-secondary);
    border-radius: 12px;
}

/* ---------------------------------------------------------
   18. OFFICIAL EXAM TICKET (PRINT-READY)
   --------------------------------------------------------- */
.exam-ticket-container {
    background: var(--theme-card-bg);
    border: 2px solid var(--theme-primary);
    border-radius: var(--theme-radius);
    padding: 28px;
    position: relative;
    box-shadow: var(--theme-shadow-md);
}

.ticket-header {
    border-bottom: 2px dashed var(--theme-border);
    padding-bottom: 18px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.ticket-seat-badge {
    background: var(--theme-primary);
    color: #fff;
    padding: 10px 22px;
    border-radius: 12px;
    text-align: center;
}

.ticket-seat-number {
    font-size: 1.8rem;
    font-weight: 900;
    line-height: 1;
    display: block;
}

.ticket-table {
    width: 100%;
    margin-bottom: 20px;
}

.ticket-table th, .ticket-table td {
    padding: 10px 12px;
    border-bottom: 1px solid var(--theme-border);
    font-size: 0.9rem;
}

.ticket-table th {
    color: var(--theme-text-muted);
    font-weight: 600;
    width: 25%;
}

.ticket-table td {
    color: var(--theme-text-heading);
    font-weight: 700;
}

.barcode-simulated {
    font-family: monospace;
    letter-spacing: 6px;
    font-size: 1.4rem;
    font-weight: 900;
    background: var(--theme-surface-subtle);
    border: 1px dashed var(--theme-border);
    padding: 8px 16px;
    border-radius: 8px;
    display: inline-block;
    text-align: center;
    color: var(--theme-text);
}

.ticket-rules-box {
    background: var(--theme-surface-subtle);
    border: 1px solid var(--theme-border);
    border-radius: 12px;
    padding: 16px;
    font-size: 0.8rem;
    color: var(--theme-text-secondary);
    line-height: 1.8;
}

/* ---------------------------------------------------------
   19. PREREGISTER & MODERN INTERACTIVE FORMS
   --------------------------------------------------------- */
/* Page Hero Banner */
.page-hero-banner {
    background: linear-gradient(135deg, rgba(29, 78, 216, 0.08) 0%, rgba(2, 132, 199, 0.04) 100%);
    border-bottom: 1px solid var(--theme-border);
    padding: 38px 0 28px 0;
    position: relative;
    overflow: hidden;
    margin-bottom: 30px;
}

[data-theme="dark"] .page-hero-banner {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.7) 0%, rgba(15, 23, 42, 0.9) 100%);
}

.page-hero-banner::before {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, var(--theme-primary-glow) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero-breadcrumb {
    font-size: 0.82rem;
    color: var(--theme-text-muted);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.hero-breadcrumb a {
    color: var(--theme-text-muted);
    text-decoration: none;
    transition: var(--theme-transition);
}

.hero-breadcrumb a:hover {
    color: var(--theme-primary);
}

.hero-title-main {
    font-size: 1.65rem;
    font-weight: 900;
    color: var(--theme-text-heading);
    letter-spacing: -0.4px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-subtitle-text {
    color: var(--theme-text-secondary);
    font-size: 0.92rem;
    margin-bottom: 0;
    line-height: 1.6;
}

/* Stepper Wizard Progress */
.prereg-stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
    padding: 16px 24px;
    background: var(--theme-card-bg);
    border: 1px solid var(--theme-card-border);
    border-radius: 18px;
    box-shadow: var(--theme-shadow-xs);
    gap: 12px;
    overflow-x: auto;
}

.stepper-step {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--theme-text-muted);
    font-size: 0.86rem;
    font-weight: 600;
    white-space: nowrap;
    padding: 6px 14px;
    border-radius: 10px;
    transition: var(--theme-transition);
}

.stepper-step.active {
    color: var(--theme-primary);
    background: var(--theme-primary-light);
    font-weight: 700;
}

.stepper-step.completed {
    color: var(--theme-success);
}

.stepper-num {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--theme-surface-subtle);
    border: 1.5px solid var(--theme-border);
    font-size: 0.82rem;
    font-weight: 800;
    transition: var(--theme-transition);
}

.stepper-step.active .stepper-num {
    background: var(--theme-primary);
    border-color: var(--theme-primary);
    color: #ffffff;
    box-shadow: 0 0 0 3px var(--theme-primary-light);
}

.stepper-step.completed .stepper-num {
    background: var(--theme-success);
    border-color: var(--theme-success);
    color: #ffffff;
}

.stepper-divider {
    flex: 1;
    max-width: 60px;
    height: 2px;
    background: var(--theme-border);
}

/* Modern Form Section Cards */
.prereg-card {
    background: var(--theme-card-bg);
    border: 1.5px solid var(--theme-card-border);
    border-radius: 20px;
    padding: 32px;
    margin-bottom: 24px;
    box-shadow: var(--theme-shadow-sm);
    position: relative;
    transition: var(--theme-transition);
}

.prereg-card:hover {
    border-color: rgba(59, 130, 246, 0.35);
    box-shadow: var(--theme-shadow-md);
}

.prereg-card-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
    padding-bottom: 18px;
    border-bottom: 1.5px solid var(--theme-border-subtle);
}

.prereg-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--theme-primary-light) 0%, rgba(2, 132, 199, 0.12) 100%);
    color: var(--theme-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
    box-shadow: 0 4px 12px var(--theme-primary-glow);
}

.prereg-card-title {
    font-size: 1.15rem;
    font-weight: 800;
    color: var(--theme-text-heading);
    margin: 0;
    line-height: 1.3;
}

.prereg-card-desc {
    font-size: 0.82rem;
    color: var(--theme-text-muted);
    margin: 3px 0 0 0;
}

/* Modern Input Groups */
.modern-group {
    margin-bottom: 20px;
}

.modern-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--theme-text-heading);
    margin-bottom: 8px;
}

.modern-label .badge-req {
    color: var(--theme-danger);
    font-size: 0.95rem;
    margin-right: 2px;
}

.modern-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.modern-input-icon {
    position: absolute;
    right: 15px;
    color: var(--theme-text-muted);
    font-size: 1.25rem;
    pointer-events: none;
    transition: var(--theme-transition);
    z-index: 2;
}

.modern-input,
.modern-select,
.modern-textarea {
    width: 100%;
    background: var(--theme-input-bg) !important;
    border: 1.5px solid var(--theme-input-border) !important;
    border-radius: 13px !important;
    padding: 12px 46px 12px 16px !important;
    font-size: 0.93rem !important;
    color: var(--theme-text) !important;
    font-family: inherit !important;
    outline: none !important;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1) !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.02) !important;
}

.modern-textarea {
    padding: 14px 16px !important;
    min-height: 105px !important;
    resize: vertical;
}

.modern-input:focus,
.modern-select:focus,
.modern-textarea:focus {
    border-color: var(--theme-primary) !important;
    box-shadow: 0 0 0 4px var(--theme-primary-light), 0 4px 12px rgba(0,0,0,0.04) !important;
    background: var(--theme-input-bg) !important;
}

.modern-input-wrapper:focus-within .modern-input-icon {
    color: var(--theme-primary);
    transform: scale(1.1);
}

.modern-input::placeholder,
.modern-textarea::placeholder {
    color: var(--theme-text-muted) !important;
    opacity: 0.7;
    font-size: 0.87rem;
}

.modern-hint {
    font-size: 0.77rem;
    color: var(--theme-text-muted);
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Security Notice & Action Bar */
.submit-action-card {
    background: var(--theme-card-bg);
    border: 1.5px solid var(--theme-card-border);
    border-radius: 20px;
    padding: 24px 30px;
    margin-top: 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    box-shadow: var(--theme-shadow-sm);
}

.btn-submit-modern {
    background: linear-gradient(135deg, #1d4ed8 0%, #0284c7 100%);
    color: #ffffff !important;
    border: none;
    border-radius: 14px;
    padding: 14px 36px;
    font-size: 1rem;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(2, 132, 199, 0.35);
    transition: var(--theme-transition);
    text-decoration: none;
}

.btn-submit-modern:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(2, 132, 199, 0.48);
    color: #ffffff !important;
}

.btn-submit-modern:active {
    transform: translateY(0);
}

/* Official Digital Receipt Certificate Layout */
.receipt-cert-card {
    background: var(--theme-card-bg);
    border: 2px solid var(--theme-card-border);
    border-radius: 24px;
    box-shadow: var(--theme-shadow-lg);
    overflow: hidden;
    position: relative;
}

.receipt-top-banner {
    background: linear-gradient(135deg, #059669 0%, #10b981 100%);
    color: #ffffff;
    padding: 24px 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
}

.receipt-hero-badge-box {
    background: var(--theme-surface-subtle);
    border: 1.5px dashed rgba(59, 130, 246, 0.4);
    border-radius: 18px;
    padding: 24px 28px;
    margin: 28px 30px 20px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
}

.peygiri-number-display {
    font-family: monospace, 'Vazirmatn';
    font-size: 2rem;
    font-weight: 900;
    color: #dc2626;
    letter-spacing: 2px;
}

.receipt-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    padding: 10px 30px 30px 30px;
}

@media (max-width: 768px) {
    .receipt-grid {
        grid-template-columns: 1fr;
    }
}

.receipt-tile {
    background: var(--theme-surface-subtle);
    border: 1.5px solid var(--theme-border);
    border-radius: 14px;
    padding: 14px 18px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    transition: var(--theme-transition);
}

.receipt-tile:hover {
    border-color: var(--theme-primary);
    background: var(--theme-card-bg);
}

.receipt-tile-full {
    grid-column: 1 / -1;
}

.receipt-tile-label {
    font-size: 0.78rem;
    color: var(--theme-text-muted);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
}

.receipt-tile-value {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--theme-text-heading);
    line-height: 1.5;
}

/* Skeleton Loading Shimmer Animation */
.skeleton {
    background: linear-gradient(90deg, var(--theme-surface-subtle) 25%, var(--theme-border) 50%, var(--theme-surface-subtle) 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.5s infinite;
    border-radius: 10px;
}

.skeleton-text {
    height: 16px;
    margin-bottom: 8px;
    border-radius: 6px;
}

.skeleton-box {
    width: 100%;
    height: 48px;
    border-radius: 12px;
}

@keyframes skeletonShimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ---------------------------------------------------------
   20. PUBLIC FOOTER
   --------------------------------------------------------- */
.public-footer {
    background: var(--theme-footer-bg);
    color: var(--theme-footer-text);
    padding: 56px 0 24px 0;
    margin-top: auto;
    font-size: 0.88rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    transition: background-color 0.3s ease;
}

.footer-heading {
    color: #ffffff;
    font-weight: 800;
    font-size: 1.05rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 8px;
}

.footer-heading::after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 32px;
    height: 2.5px;
    background: var(--theme-secondary);
    border-radius: 2px;
}

.footer-links-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-links-list li {
    margin-bottom: 12px;
}

.footer-links-list a {
    color: var(--theme-footer-text);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: var(--theme-transition);
}

.footer-links-list a:hover {
    color: #ffffff;
    padding-right: 6px;
}

.trust-badge-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
}

.trust-badge-icon {
    font-size: 1.8rem;
    color: var(--theme-accent);
}

/* ---------------------------------------------------------
   21. LIGHTBOX MODAL
   --------------------------------------------------------- */
.custom-lightbox-modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.95);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.lightbox-content {
    max-width: 90vw;
    max-height: 85vh;
    border-radius: 14px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
    object-fit: contain;
}

.lightbox-close-btn {
    position: absolute;
    top: 24px;
    left: 24px;
    background: rgba(255, 255, 255, 0.15);
    border: none;
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    font-size: 1.4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--theme-transition);
}

.lightbox-close-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* ---------------------------------------------------------
   22. SKELETON LOADING, SMOOTH SCROLL & BACK TO TOP
   --------------------------------------------------------- */
html {
    scroll-behavior: smooth;
}

.skeleton {
    background: var(--theme-border);
    background: linear-gradient(90deg, var(--theme-border) 0%, var(--theme-surface-subtle) 50%, var(--theme-border) 100%);
    background-size: 200% 100%;
    animation: skeleton-shimmer 1.5s infinite linear;
    border-radius: 6px;
    display: inline-block;
}

@keyframes skeleton-shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.skeleton-text {
    height: 14px;
    margin-bottom: 8px;
    border-radius: 4px;
}

.skeleton-box {
    height: 42px;
    width: 100%;
    border-radius: 8px;
}

.skeleton-card {
    background: var(--theme-card-bg);
    border-radius: 16px;
    border: 1px solid var(--theme-border);
    padding: 24px;
    box-shadow: var(--theme-shadow-card);
}

.reveal-on-scroll {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-on-scroll.revealed {
    opacity: 1;
    transform: translateY(0);
}

.btn-back-to-top {
    position: fixed;
    bottom: 24px;
    left: 24px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background-color: var(--theme-primary);
    color: #fff;
    border: none;
    box-shadow: 0 4px 16px rgba(0,0,0,0.25);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--theme-transition);
    z-index: 1040;
}

.btn-back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.btn-back-to-top:hover {
    background-color: var(--theme-primary-hover);
    color: #fff;
    transform: translateY(-3px);
}

/* ---------------------------------------------------------
   23. RESPONSIVE BREAKPOINTS
   --------------------------------------------------------- */
@media (max-width: 991.98px) {
    .school-hero-public {
        padding: 36px 24px;
    }

    .hero-title {
        font-size: 1.7rem;
    }

    .top-utility-bar {
        font-size: 0.78rem;
    }
    
    .app-login-showcase {
        padding: 28px 20px;
    }
    
    .floating-notif-pill {
        display: none;
    }

    .prereg-container {
        padding: 24px 18px;
    }
}

@media (max-width: 575.98px) {
    .school-name-text {
        font-size: 1.02rem;
    }

    .hero-title {
        font-size: 1.4rem;
    }

    .service-hub-card {
        padding: 18px 16px;
    }

    .form-card-public {
        padding: 24px 18px;
    }

    .phone-mockup-frame {
        width: 240px;
        height: 480px;
    }
}

/* ---------------------------------------------------------
   24. PRINT STYLESHEET
   --------------------------------------------------------- */
@media print {
    .public-navbar,
    .top-utility-bar,
    .ticker-bar-wrapper,
    .public-footer,
    .btn-back-to-top,
    .app-login-showcase,
    .no-print,
    .noprint,
    .btn,
    form {
        display: none !important;
    }

    body {
        background: #ffffff !important;
        color: #000000 !important;
        padding: 0 !important;
        margin: 0 !important;
    }

    .container {
        width: 100% !important;
        max-width: 100% !important;
        padding: 0 !important;
    }

    .exam-ticket-container {
        border: 2px solid #000 !important;
        box-shadow: none !important;
        border-radius: 0 !important;
        page-break-inside: avoid;
        margin: 0 !important;
        padding: 20px !important;
    }

    .ticket-seat-badge {
        background: #000 !important;
        color: #fff !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .prereg-container,
    .receipt-cert-card {
        border: 1px solid #333 !important;
        box-shadow: none !important;
        margin: 0 !important;
        padding: 15px !important;
        width: 100% !important;
        max-width: 100% !important;
        background: #fff !important;
    }

    .receipt-top-banner {
        background: #10b981 !important;
        color: #fff !important;
        -webkit-print-color-adjust: exact;
        print-color-adjust: exact;
    }

    .receipt-tile,
    .receipt-value-box {
        background: #fff !important;
        border: 1px solid #999 !important;
        color: #000 !important;
    }

    .peygiri-number-display {
        color: #b91c1c !important;
        font-size: 1.6rem !important;
    }
}
