/* ===================================================
   Zangi Parwarda Private High School - Official Theme
   Aesthetic: Midnight Royal Navy & Imperial Metallic Gold
   Inspired by the Official Circular School Medallion (Est. 2013)
   =================================================== */

:root {
    /* Brand Midnight Royal Navy Palette */
    --navy-950: #050b14;
    --navy-900: #0a1426;
    --navy-850: #0d1b33;
    --navy-800: #122342;
    --navy-700: #18335f;
    --navy-600: #204178;
    --navy-500: #2b5499;
    --navy-light-bg: #f2f5fa;
    --navy-subtle-border: rgba(18, 35, 66, 0.12);

    /* Imperial Metallic Gold & Champagne Palette */
    --gold-100: #fbf7eb;
    --gold-200: #f5e8be;
    --gold-300: #ebd188;
    --gold-400: #deb752;
    --gold-500: #c99c2e; /* Medallion primary gold */
    --gold-600: #a87d1a;
    --gold-700: #845e0d;
    --gold-800: #5c4006;
    
    /* Legacy variable mappings for safety */
    --primary-blue: #0d1b33;
    --primary-dark: #070e1c;
    --primary-light: #18335f;
    --light-blue-bg: #f4f6fa;
    --ice-blue: #fbf7eb;
    --ice-blue-border: #e8e2d4;
    --soft-border: #e9e4d8;
    --card-bg: #ffffff;
    --card-bg-warm: #fcfbfa;

    /* Gradients */
    --gold-gradient: linear-gradient(135deg, #f0d78a 0%, #c99c2e 50%, #9e7515 100%);
    --gold-gradient-hover: linear-gradient(135deg, #fae29c 0%, #d8ac3b 50%, #ad821b 100%);
    --gold-gradient-soft: linear-gradient(135deg, rgba(201, 156, 46, 0.14) 0%, rgba(201, 156, 46, 0.04) 100%);
    --navy-gradient: linear-gradient(135deg, #0d1b33 0%, #152a4e 50%, #1c3664 100%);
    --navy-gradient-dark: linear-gradient(135deg, #070e1c 0%, #0d1b33 100%);
    --hero-bg: radial-gradient(ellipse at 50% 20%, #1a3766 0%, #0d1b33 55%, #050c18 100%);
    
    /* Surfaces & Borders */
    --page-bg: #f9f8f4;
    --gold-border: rgba(201, 156, 46, 0.38);
    --gold-border-soft: rgba(201, 156, 46, 0.2);

    /* Typography */
    --text-main: #0a1426;
    --text-muted: #516075;
    --text-light: #7c8ba1;
    --text-gold: #c99c2e;
    --text-gold-light: #fae39e;

    /* Shadows & Glows */
    --shadow-sm: 0 2px 8px rgba(10, 20, 38, 0.05);
    --shadow: 0 6px 20px rgba(10, 20, 38, 0.07);
    --shadow-hover: 0 12px 28px rgba(10, 20, 38, 0.12), 0 0 18px rgba(201, 156, 46, 0.16);
    --shadow-gold: 0 6px 20px rgba(201, 156, 46, 0.28);
    --gold-glow: 0 0 25px rgba(201, 156, 46, 0.35);

    /* Layout & Radii */
    --radius-sm: 8px;
    --radius: 14px;
    --radius-lg: 20px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Vazirmatn', 'Segoe UI', Tahoma, -apple-system, sans-serif;
}

body {
    background: linear-gradient(180deg, #f8f6f0 0%, #f4efe6 25%, #faf9f6 100%);
    color: var(--text-main);
    min-height: 100vh;
    direction: rtl;
    text-align: right;
    overflow-x: hidden;
    width: 100%;
    -webkit-tap-highlight-color: transparent;
}

/* Overall Layout */
.app-layout {
    display: flex;
    min-height: 100vh;
    position: relative;
    width: 100%;
}

/* ===================================================
   1. Right Sidebar (Hidden/Closed by Default)
   =================================================== */

/* Backdrop Overlay */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(5, 11, 20, 0.65);
    backdrop-filter: blur(4px);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.32s ease, visibility 0.32s ease;
}

.sidebar-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Sidebar Drawer */
.sidebar {
    width: 300px;
    background: #ffffff;
    border-left: 2px solid var(--gold-border-soft);
    padding: 24px 18px;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    box-shadow: -8px 0 32px rgba(5, 11, 20, 0.28);
    z-index: 999;
    overflow-x: hidden;
    transform: translateX(100%);
    transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar.open {
    transform: translateX(0);
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding-bottom: 18px;
    border-bottom: 1.5px solid var(--gold-border-soft);
    margin-bottom: 18px;
}

.sidebar-logo {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 2px solid var(--gold-500);
    padding: 2px;
    background: var(--navy-850);
    box-shadow: 0 3px 10px rgba(201, 156, 46, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    overflow: hidden;
}

.sidebar-logo-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.sidebar-title-box {
    flex: 1;
    min-width: 0;
}

.sidebar-header h2 {
    font-size: 1.1rem;
    color: var(--navy-900);
    font-weight: 800;
    line-height: 1.3;
}

.sidebar-tag {
    font-size: 0.72rem;
    background: var(--gold-100);
    color: var(--gold-700);
    border: 1px solid var(--gold-border-soft);
    padding: 2px 8px;
    border-radius: 6px;
    font-weight: 700;
    display: inline-block;
    margin-top: 3px;
}

.sidebar-close-btn {
    background: var(--navy-light-bg);
    border: 1px solid var(--soft-border);
    color: var(--navy-900);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.sidebar-close-btn:hover {
    background: #fee2e2;
    color: #ef4444;
    border-color: #fca5a5;
    transform: rotate(90deg);
}

.sidebar-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    font-weight: 700;
    margin-bottom: 12px;
    padding-right: 6px;
    letter-spacing: 0.3px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    background: transparent;
    color: var(--text-main);
    border: 1px solid transparent;
    border-right: 3px solid transparent;
    padding: 12px 14px;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--radius-sm);
    cursor: pointer;
    text-align: right;
    font-family: inherit;
    transition: all 0.22s ease;
}

.nav-btn .btn-icon {
    font-size: 1.15rem;
}

.nav-btn:hover {
    background: var(--gold-100);
    color: var(--navy-900);
    border-color: var(--gold-border-soft);
    transform: translateX(-3px);
}

.nav-btn.active {
    background: var(--navy-gradient);
    color: #ffffff;
    border-right: 4px solid var(--gold-400);
    box-shadow: 0 4px 16px rgba(10, 20, 38, 0.25);
    font-weight: 700;
}

.nav-btn.active .btn-icon {
    filter: drop-shadow(0 0 4px rgba(235, 209, 136, 0.6));
}

.sidebar-footer {
    padding-top: 16px;
    border-top: 1px solid var(--soft-border);
    font-size: 0.8rem;
    color: var(--text-muted);
    text-align: center;
}


/* ===================================================
   2. Main Wrapper & Hero Banner
   =================================================== */
.main-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    width: 100%;
}

/* Top School Definition Banner (Hero Section) */
.school-top-banner {
    position: relative;
    background: var(--hero-bg);
    color: #ffffff;
    padding: 20px 24px 44px 24px;
    text-align: center;
    border-bottom: 3.5px solid var(--gold-500);
    box-shadow: 0 10px 32px rgba(5, 11, 20, 0.35);
    overflow: hidden;
}

/* Ambient Radial Glow */
.banner-ambient-glow {
    position: absolute;
    top: 25%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 520px;
    height: 520px;
    background: radial-gradient(circle, rgba(201, 156, 46, 0.14) 0%, rgba(24, 51, 95, 0.1) 50%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

/* Top Row Action Bar (Menu right, Badge center, Logo left) */
.banner-top-bar {
    position: relative;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 100%;
    margin: 0 0 26px 0;
    padding: 0 12px;
}

/* Top Right: Sidebar Toggle Button (Only 3 lines, no text) */
.sidebar-toggle-btn {
    position: static;
    width: 50px;
    height: 50px;
    padding: 0;
    background: rgba(10, 20, 38, 0.72);
    backdrop-filter: blur(10px);
    border: 1.5px solid var(--gold-border);
    color: #ffffff;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.24s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.3);
    flex-shrink: 0;
}

.sidebar-toggle-btn:hover {
    background: rgba(20, 38, 70, 0.9);
    border-color: var(--gold-400);
    transform: translateY(-2px) scale(1.06);
    box-shadow: 0 6px 20px rgba(201, 156, 46, 0.35);
    color: var(--gold-200);
}

.sidebar-toggle-btn .toggle-icon {
    font-size: 1.45rem;
    line-height: 1;
    color: var(--gold-400);
}

/* Top Center: Founding Badge */
.banner-badge {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(201, 156, 46, 0.16);
    border: 1.5px solid rgba(240, 215, 138, 0.5);
    backdrop-filter: blur(8px);
    color: var(--gold-200);
    font-size: 0.88rem;
    font-weight: 700;
    padding: 7px 18px;
    border-radius: 25px;
    box-shadow: 0 3px 12px rgba(0, 0, 0, 0.2);
    white-space: nowrap;
    margin: 0;
    z-index: 2;
}

/* Top Left: School Logo (Enlarged & positioned more to the left) */
.banner-top-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    cursor: pointer;
    margin-right: auto; /* Push completely to the left in RTL */
}

.top-logo-img {
    width: 82px;
    height: 82px;
    border-radius: 50%;
    border: 3px solid var(--gold-400);
    outline: 4px solid rgba(240, 215, 138, 0.28);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.55), 0 0 20px rgba(201, 156, 46, 0.38);
    object-fit: cover;
    background: var(--navy-850);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease;
    display: block;
}

.top-logo-img:hover {
    transform: scale(1.08) rotate(2deg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7), 0 0 26px rgba(201, 156, 46, 0.6);
    border-color: var(--gold-300);
}

.banner-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
}

.badge-star {
    color: var(--gold-400);
    font-size: 0.85rem;
}

/* Banner Titles */
.school-main-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 4px;
    letter-spacing: -0.5px;
    color: #ffffff;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
}

.school-latin-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--gold-300);
    letter-spacing: 3.5px;
    margin-bottom: 14px;
    text-transform: uppercase;
    font-family: 'Segoe UI', Tahoma, sans-serif;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.3);
}

.school-motto {
    font-size: 1.22rem;
    color: var(--gold-200);
    margin-bottom: 22px;
    font-weight: 600;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.school-description-box {
    max-width: 820px;
    margin: 0 auto;
    background: rgba(10, 20, 38, 0.6);
    backdrop-filter: blur(12px);
    border: 1.5px solid var(--gold-border);
    border-radius: var(--radius);
    padding: 20px 28px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25);
}

.school-description-box p {
    font-size: 1.02rem;
    line-height: 1.85;
    color: #f1f5f9;
}


/* ===================================================
   3. Middle Action Buttons (5 Sections)
   =================================================== */
.middle-buttons-section {
    padding: 36px 24px 24px 24px;
    max-width: 1120px;
    margin: 0 auto;
    width: 100%;
}

.section-title-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    margin-bottom: 22px;
}

.title-decor-line {
    display: inline-block;
    height: 2px;
    width: 60px;
    background: linear-gradient(90deg, transparent, var(--gold-500));
}

.title-decor-line:last-child {
    background: linear-gradient(90deg, var(--gold-500), transparent);
}

.middle-heading {
    text-align: center;
    font-size: 1.4rem;
    color: var(--navy-900);
    font-weight: 800;
}

.middle-buttons-grid {
    direction: ltr;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 16px;
}

.middle-nav-btn {
    direction: rtl;
    background: #ffffff;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius);
    padding: 20px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.24s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.middle-nav-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: transparent;
    transition: background 0.24s;
}

.middle-nav-btn .m-icon {
    font-size: 2.3rem;
    margin-bottom: 10px;
    transition: transform 0.24s ease;
}

.middle-nav-btn .m-title {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--navy-900);
    margin-bottom: 4px;
    transition: color 0.2s;
}

.middle-nav-btn .m-sub {
    font-size: 0.8rem;
    color: var(--text-muted);
    line-height: 1.4;
    transition: color 0.2s;
}

.middle-nav-btn:hover {
    transform: translateY(-4px);
    border-color: var(--gold-500);
    background: #ffffff;
    box-shadow: var(--shadow-hover);
}

.middle-nav-btn:hover .m-icon {
    transform: scale(1.1);
}

.middle-nav-btn.active {
    background: var(--navy-gradient);
    border-color: var(--gold-500);
    box-shadow: 0 8px 22px rgba(10, 20, 38, 0.3), 0 0 14px rgba(201, 156, 46, 0.28);
}

.middle-nav-btn.active::after {
    background: var(--gold-gradient);
}

.middle-nav-btn.active .m-title {
    color: #ffffff;
}

.middle-nav-btn.active .m-sub {
    color: var(--gold-200);
}

.middle-nav-btn.active .m-icon {
    filter: drop-shadow(0 2px 8px rgba(201, 156, 46, 0.5));
}


/* ===================================================
   4. Tabbed Content Container
   =================================================== */
.content-container {
    max-width: 1120px;
    width: 92%;
    margin: 10px auto 50px auto;
    flex: 1;
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease-in-out;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.section-header {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
}

.section-header h2 {
    color: var(--navy-900);
    font-size: 2rem;
    margin-bottom: 8px;
    font-weight: 800;
}

.section-header p {
    color: var(--text-muted);
    font-size: 1.02rem;
}


/* ===================================================
   5. About School Cards
   =================================================== */
.about-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 22px;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    padding: 26px;
    box-shadow: var(--shadow);
    transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
    position: relative;
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--gold-400), transparent);
    opacity: 0.8;
}

.card:hover {
    transform: translateY(-4px);
    border-color: var(--gold-500);
    box-shadow: var(--shadow-hover);
}

.card-wide {
    grid-column: 1 / -1;
}

.card-icon {
    font-size: 2.2rem;
    margin-bottom: 12px;
}

.card h3 {
    color: var(--navy-900);
    font-size: 1.35rem;
    margin-bottom: 10px;
    font-weight: 800;
}

.highlight-text {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--navy-800);
    margin-bottom: 10px;
}

.feature-list {
    list-style: none;
}

.feature-list li {
    padding: 7px 0;
    color: var(--text-muted);
    font-weight: 500;
    display: flex;
    align-items: center;
}

.feature-list li::before {
    content: "✓";
    color: var(--gold-600);
    background: var(--gold-100);
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.75rem;
    margin-left: 10px;
    flex-shrink: 0;
    border: 1px solid var(--gold-border-soft);
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
    margin-top: 18px;
}

.gallery-item {
    background: linear-gradient(135deg, #fdfbf7 0%, #f4eee1 100%);
    border: 1.5px dashed var(--gold-400);
    border-radius: var(--radius-sm);
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--navy-900);
    transition: all 0.22s ease;
}

.gallery-item:hover {
    background: var(--gold-100);
    border-color: var(--gold-600);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}


/* ===================================================
   6. Teachers & Profiles
   =================================================== */

/* Department Filter Tabs */
.dept-filter-container {
    display: flex;
    gap: 12px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.dept-filter-btn {
    background: #ffffff;
    border: 1.5px solid var(--card-border);
    color: var(--navy-900);
    padding: 10px 22px;
    border-radius: 30px;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: var(--shadow-sm);
    transition: all 0.22s ease;
}

.dept-filter-btn:hover {
    border-color: var(--gold-500);
    background: var(--gold-100);
    transform: translateY(-2px);
}

.dept-filter-btn.active {
    background: var(--navy-gradient);
    border-color: var(--gold-500);
    color: #ffffff;
    box-shadow: 0 4px 16px rgba(10, 20, 38, 0.22), 0 0 12px rgba(201, 156, 46, 0.25);
}

.dept-filter-btn.active .filter-icon {
    filter: drop-shadow(0 0 4px rgba(240, 215, 138, 0.6));
}

.dept-filter-btn .filter-icon {
    font-size: 1.1rem;
}

/* Department Section Groups */
.department-group {
    background: #ffffff;
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    padding: 26px 26px 30px 26px;
    margin-bottom: 34px;
    box-shadow: var(--shadow-sm);
    animation: fadeIn 0.3s ease;
    position: relative;
}

.department-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1.5px solid var(--soft-border);
    padding-bottom: 18px;
    margin-bottom: 24px;
    gap: 16px;
    flex-wrap: wrap;
}

.dept-title-wrap {
    display: flex;
    align-items: center;
    gap: 14px;
}

.dept-icon-box {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.dept-icon-box.scientific {
    background: var(--navy-light-bg);
    border: 1px solid var(--navy-subtle-border);
}

.dept-icon-box.literary {
    background: var(--gold-100);
    border: 1px solid var(--gold-border-soft);
}

.dept-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--navy-900);
    margin-bottom: 2px;
}

.dept-desc {
    font-size: 0.92rem;
    color: var(--text-muted);
}

.dept-badge {
    font-size: 0.84rem;
    font-weight: 700;
    padding: 6px 16px;
    border-radius: 20px;
    white-space: nowrap;
}

.scientific-badge {
    background: var(--navy-light-bg);
    color: var(--navy-800);
    border: 1px solid var(--navy-subtle-border);
}

.literary-badge {
    background: var(--gold-100);
    color: var(--gold-800);
    border: 1px solid var(--gold-border-soft);
}

.dept-pill-small {
    display: inline-block;
    font-size: 0.78rem;
    font-weight: 700;
    padding: 3px 10px;
    border-radius: 12px;
    margin-bottom: 6px;
}

.badge-literary {
    background-color: var(--gold-100);
    color: var(--gold-800);
    border: 1px solid var(--gold-border-soft);
}

/* Teachers Grid & Cards */
.teachers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(235px, 1fr));
    gap: 22px;
}

.teacher-card {
    background: var(--card-bg);
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius);
    padding: 24px 20px;
    text-align: center;
    cursor: pointer;
    box-shadow: var(--shadow-sm);
    transition: all 0.24s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.teacher-card:hover {
    transform: translateY(-5px);
    border-color: var(--gold-500);
    box-shadow: var(--shadow-hover);
}

.teacher-avatar {
    font-size: 3.5rem;
    margin-bottom: 10px;
}

.teacher-card h3 {
    font-size: 1.25rem;
    margin-bottom: 6px;
    color: var(--navy-900);
    font-weight: 700;
}

.badge {
    display: inline-block;
    background-color: var(--gold-100);
    color: var(--gold-800);
    border: 1px solid var(--gold-border-soft);
    font-size: 0.85rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    margin-bottom: 10px;
}

.teacher-card p {
    color: var(--text-muted);
    font-size: 0.92rem;
    margin-bottom: 16px;
    line-height: 1.5;
}

.btn-secondary {
    background: #ffffff;
    color: var(--navy-800);
    border: 1.5px solid var(--navy-800);
    padding: 8px 18px;
    font-size: 0.92rem;
    font-weight: 700;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.22s ease;
    font-family: inherit;
}

.teacher-card:hover .btn-secondary {
    background: var(--navy-gradient);
    color: #ffffff;
    border-color: var(--gold-500);
    box-shadow: 0 4px 12px rgba(10, 20, 38, 0.2);
}

/* Individual Teacher Profile View */
.teacher-profile-container {
    background: var(--card-bg);
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius);
    padding: 34px;
    box-shadow: var(--shadow);
}

.btn-back {
    background: var(--gold-100);
    border: 1px solid var(--gold-border);
    color: var(--navy-900);
    font-size: 0.95rem;
    font-weight: 700;
    cursor: pointer;
    padding: 9px 20px;
    border-radius: var(--radius-sm);
    margin-bottom: 26px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s ease;
    font-family: inherit;
}

.btn-back:hover {
    background: var(--gold-200);
    border-color: var(--gold-500);
    transform: translateX(3px);
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 24px;
    border-bottom: 1.5px solid var(--soft-border);
    padding-bottom: 24px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.profile-img-box {
    width: 96px;
    height: 96px;
    background: var(--gold-100);
    border: 2px solid var(--gold-400);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 14px rgba(201, 156, 46, 0.25);
}

.avatar-large {
    font-size: 3.2rem;
}

.profile-intro h2 {
    font-size: 1.85rem;
    color: var(--navy-900);
    margin-bottom: 4px;
    font-weight: 800;
}

.role-title {
    font-size: 1.08rem;
    color: var(--gold-700);
    font-weight: 700;
    margin-bottom: 8px;
}

.course-link {
    color: var(--navy-700);
    font-size: 0.98rem;
    font-weight: 700;
    text-decoration: none;
    border-bottom: 1.5px solid var(--gold-500);
    padding-bottom: 2px;
    transition: color 0.2s;
}

.course-link:hover {
    color: var(--gold-600);
}

.profile-section {
    margin-bottom: 24px;
}

.profile-section h3 {
    color: var(--navy-900);
    font-size: 1.3rem;
    margin-bottom: 10px;
    font-weight: 800;
}

.profile-section p {
    color: var(--text-muted);
    line-height: 1.85;
    margin-bottom: 8px;
}


/* ===================================================
   7. Collapsible Top Students Accordion
   =================================================== */
.accordion-item {
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    margin-top: 22px;
}

.accordion-header {
    width: 100%;
    background: #fdfcf9;
    border: none;
    padding: 15px 22px;
    text-align: right;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--navy-900);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s, color 0.2s;
    font-family: inherit;
}

.accordion-header:hover {
    background: var(--gold-100);
    color: var(--gold-800);
}

.accordion-header.active {
    background: var(--gold-100);
    color: var(--navy-900);
    border-bottom: 1.5px solid var(--gold-border);
}

.arrow-icon {
    font-size: 0.85rem;
    color: var(--gold-600);
    transition: transform 0.3s ease;
}

.accordion-header.active .arrow-icon {
    transform: rotate(180deg);
}

.accordion-content {
    display: none;
    padding: 18px;
    background: #ffffff;
    border-top: 1px solid var(--card-border);
}

.accordion-content.show {
    display: block;
}

/* Data Table (RTL) */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
}

.data-table th,
.data-table td {
    padding: 13px 16px;
    text-align: right;
    border-bottom: 1px solid #f1ece1;
}

.data-table th {
    background-color: var(--navy-850);
    color: var(--gold-200);
    font-size: 0.92rem;
    letter-spacing: 0.5px;
    font-weight: 700;
}

.data-table th:first-child {
    border-top-right-radius: 8px;
}

.data-table th:last-child {
    border-top-left-radius: 8px;
}

.data-table tbody tr:hover {
    background-color: #fdfbf7;
}

.score-pill {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    font-weight: 700;
    padding: 4px 14px;
    border-radius: 20px;
    font-size: 0.9rem;
    display: inline-block;
}


/* ===================================================
   8. Tabs 3, 4, 5 Components (Stats, Grades, Schedule, Form)
   =================================================== */

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 18px;
    margin-bottom: 30px;
}

.stat-card {
    background: #ffffff;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius);
    padding: 22px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: transform 0.22s, box-shadow 0.22s, border-color 0.22s;
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gold-gradient);
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: var(--gold-500);
}

.stat-icon {
    font-size: 2.2rem;
    display: block;
    margin-bottom: 8px;
}

.stat-num {
    font-size: 1.9rem;
    font-weight: 800;
    color: var(--navy-900);
    display: block;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 600;
}

/* Grade Search Box */
.grade-search-box {
    background: linear-gradient(135deg, #ffffff 0%, #fdfbf7 100%);
    border: 1.5px solid var(--gold-border);
    border-radius: var(--radius);
    padding: 28px 26px;
    margin-bottom: 32px;
    box-shadow: var(--shadow-sm);
    position: relative;
}

.grade-search-box h3 {
    font-size: 1.3rem;
    color: var(--navy-900);
    margin-bottom: 6px;
    font-weight: 800;
}

.grade-search-box p {
    font-size: 0.94rem;
    color: var(--text-muted);
    margin-bottom: 18px;
}

.search-input-group {
    display: flex;
    gap: 10px;
    max-width: 620px;
}

.search-input-group input {
    flex: 1;
    padding: 12px 18px;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius-sm);
    font-size: 0.96rem;
    font-family: inherit;
    background: #ffffff;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.search-input-group input:focus {
    border-color: var(--gold-500);
    box-shadow: 0 0 0 3.5px rgba(201, 156, 46, 0.2);
}

.btn-primary {
    background: var(--navy-gradient);
    color: #ffffff;
    border: 1.5px solid var(--gold-500);
    padding: 12px 26px;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: inherit;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.22s ease;
    box-shadow: 0 4px 14px rgba(10, 20, 38, 0.2);
}

.btn-primary:hover {
    background: var(--navy-gradient-dark);
    border-color: var(--gold-400);
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(201, 156, 46, 0.3);
    color: var(--gold-200);
}

/* Timing Cards */
.timing-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 18px;
    margin-bottom: 30px;
}

.timing-card {
    background: #ffffff;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius);
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
}

.timing-card:hover {
    transform: translateY(-3px);
    border-color: var(--gold-500);
    box-shadow: var(--shadow-hover);
}

.t-icon {
    font-size: 2.3rem;
    display: block;
    margin-bottom: 8px;
}

.timing-card h4 {
    font-size: 1.15rem;
    color: var(--navy-900);
    font-weight: 800;
    margin-bottom: 6px;
}

.t-highlight {
    font-size: 1.35rem;
    font-weight: 800;
    color: var(--gold-700);
    margin-bottom: 4px;
}

.timing-card span {
    font-size: 0.84rem;
    color: var(--text-muted);
}

/* Table Responsive Container */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: var(--radius-sm);
    border: 1px solid var(--card-border);
}

/* Admission & Contact Layout */
.admission-grid {
    display: grid;
    grid-template-columns: 1fr;
    max-width: 840px;
    margin: 0 auto;
    gap: 26px;
}

.form-card,
.contact-info-card {
    background: #ffffff;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius);
    padding: 30px 26px;
    box-shadow: var(--shadow-sm);
    position: relative;
    overflow: hidden;
}

.form-card::before,
.contact-info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gold-gradient);
}

.form-card h3,
.contact-info-card h3 {
    color: var(--navy-900);
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.form-card p {
    font-size: 0.94rem;
    color: var(--text-muted);
    margin-bottom: 22px;
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--navy-900);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 16px;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius-sm);
    font-size: 0.94rem;
    font-family: inherit;
    outline: none;
    background: #ffffff;
    color: var(--text-main);
    transition: border-color 0.2s, box-shadow 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--gold-500);
    box-shadow: 0 0 0 3px rgba(201, 156, 46, 0.2);
}

.form-alert-success {
    background: #ecfdf5;
    border: 1.5px solid #a7f3d0;
    color: #065f46;
    padding: 14px 18px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 0.95rem;
    text-align: center;
    margin-top: 12px;
    animation: fadeIn 0.3s ease;
}

/* Contact List */
.contact-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin: 22px 0;
}

.contact-list li {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.c-icon {
    font-size: 1.5rem;
    background: var(--gold-100);
    border: 1px solid var(--gold-border-soft);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    flex-shrink: 0;
}

.contact-list strong {
    color: var(--navy-900);
    font-size: 0.98rem;
    display: block;
    margin-bottom: 2px;
    font-weight: 700;
}

.contact-list p {
    color: var(--text-muted);
    font-size: 0.92rem;
    line-height: 1.6;
}

.admission-requirements-box {
    background: var(--gold-100);
    border: 1.5px dashed var(--gold-400);
    border-radius: var(--radius-sm);
    padding: 18px 20px;
    margin-top: 14px;
}

.admission-requirements-box h4 {
    font-size: 1rem;
    color: var(--navy-900);
    font-weight: 800;
    margin-bottom: 10px;
}

@media (max-width: 800px) {
    .admission-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .search-input-group {
        flex-direction: column;
    }
}

/* Footer with Crest */
.footer {
    background: var(--navy-900);
    border-top: 3px solid var(--gold-500);
    text-align: center;
    padding: 34px 20px;
    color: #e2e8f0;
    font-size: 0.95rem;
    margin-top: auto;
    position: relative;
}

.footer-crest-mini {
    margin-bottom: 12px;
}

.footer-logo-img {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: 2px solid var(--gold-400);
    padding: 1px;
    background: #0d1b33;
    display: inline-block;
}

.footer-copy {
    color: #ffffff;
    font-weight: 700;
    margin-bottom: 4px;
}

.social-links {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 10px 0 18px;
}

.social-link {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.28);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.14);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    text-decoration: none;
}

.social-link:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.2);
    background: rgba(255, 255, 255, 0.18);
}

.social-link svg {
    width: 20px;
    height: 20px;
    fill: #ffffff;
}

.social-link.whatsapp,
.social-link.facebook,
.social-link.instagram {
    background: rgba(255, 255, 255, 0.08);
}

.footer-sub {
    font-size: 0.8rem;
    color: var(--gold-300);
    letter-spacing: 1px;
    display: block;
}


/* ===================================================
   9. Responsive Design & Clean Mobile Layout
   =================================================== */

/* Tablet Optimization (Max width 900px) */
@media (max-width: 900px) {
    .school-top-banner {
        padding: 20px 20px 38px 20px;
    }

    .top-logo-img {
        width: 72px;
        height: 72px;
    }

    .school-main-title {
        font-size: 2.1rem;
    }

    .middle-buttons-grid {
        grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
        gap: 12px;
    }

    .about-grid {
        grid-template-columns: 1fr;
    }
}

/* Mobile Devices Optimization (Max width 640px) */
@media (max-width: 640px) {
    body {
        font-size: 0.92rem;
    }

    /* Top Banner */
    .school-top-banner {
        padding: 16px 12px 26px 12px;
    }

    .banner-top-bar {
        margin-bottom: 16px;
        padding: 0 4px;
    }

    .sidebar-toggle-btn {
        width: 42px;
        height: 42px;
    }

    .sidebar-toggle-btn .toggle-icon {
        font-size: 1.25rem;
    }

    .top-logo-img {
        width: 58px;
        height: 58px;
    }

    .banner-badge {
        font-size: 0.74rem;
        padding: 5px 12px;
        gap: 5px;
    }

    .school-main-title {
        font-size: 1.65rem;
        line-height: 1.35;
    }

    .school-latin-title {
        font-size: 0.78rem;
        letter-spacing: 2px;
    }

    .school-motto {
        font-size: 1.05rem;
        margin-bottom: 16px;
    }

    .school-description-box {
        padding: 16px 14px;
    }

    .school-description-box p {
        font-size: 0.92rem;
        line-height: 1.7;
    }

    /* Middle Navigation 2-Column Grid on Mobile */
    .middle-buttons-section {
        padding: 22px 14px;
    }

    .middle-buttons-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .middle-nav-btn {
        padding: 14px 8px;
    }

    .middle-nav-btn .m-icon {
        font-size: 1.8rem;
        margin-bottom: 6px;
    }

    .middle-nav-btn .m-title {
        font-size: 0.92rem;
    }

    .middle-nav-btn .m-sub {
        font-size: 0.72rem;
    }

    /* Tabbed Container */
    .content-container {
        width: 94%;
        margin: 6px auto 30px auto;
    }

    .section-header h2 {
        font-size: 1.5rem;
    }

    /* Horizontal Scrollable Department Filter Pills */
    .dept-filter-container {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 8px;
        gap: 8px;
        -webkit-overflow-scrolling: touch;
        justify-content: flex-start;
    }

    .dept-filter-btn {
        padding: 8px 14px;
        font-size: 0.84rem;
        white-space: nowrap;
        flex-shrink: 0;
    }

    /* Department Section Groups */
    .department-group {
        padding: 18px 14px 22px 14px;
        border-radius: var(--radius-sm);
        margin-bottom: 22px;
    }

    .department-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding-bottom: 12px;
        margin-bottom: 16px;
    }

    .dept-title-wrap {
        gap: 10px;
    }

    .dept-icon-box {
        width: 42px;
        height: 42px;
        font-size: 1.25rem;
        border-radius: 10px;
    }

    .dept-title {
        font-size: 1.2rem;
    }

    .dept-desc {
        font-size: 0.84rem;
        line-height: 1.5;
    }

    /* Single column cards on phone */
    .teachers-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .teacher-card {
        padding: 20px 14px;
        border-radius: var(--radius-sm);
    }

    .teacher-avatar {
        font-size: 2.8rem;
        margin-bottom: 6px;
    }

    .teacher-card h3 {
        font-size: 1.15rem;
    }

    .btn-secondary {
        width: 100%;
        padding: 9px;
        font-size: 0.88rem;
    }

    /* Teacher Profile Detail View */
    .teacher-profile-container {
        padding: 20px 14px;
        border-radius: var(--radius-sm);
    }

    .btn-back {
        width: 100%;
        justify-content: center;
        padding: 9px;
        font-size: 0.88rem;
        margin-bottom: 18px;
    }

    .profile-header {
        flex-direction: column;
        text-align: center;
        gap: 14px;
        align-items: center;
        padding-bottom: 16px;
        margin-bottom: 16px;
    }

    .profile-intro {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .profile-intro h2 {
        font-size: 1.4rem;
    }

    .role-title {
        font-size: 0.94rem;
    }

    .profile-img-box {
        width: 80px;
        height: 80px;
    }

    .avatar-large {
        font-size: 2.6rem;
    }

    .profile-section h3 {
        font-size: 1.15rem;
    }

    .profile-section p {
        font-size: 0.9rem;
        line-height: 1.7;
    }

    /* Data Table on Mobile */
    .accordion-header {
        padding: 13px 14px;
        font-size: 0.92rem;
    }

    .accordion-content {
        padding: 10px;
        overflow-x: auto;
    }

    .data-table {
        font-size: 0.86rem;
    }

    .data-table th,
    .data-table td {
        padding: 10px 8px;
    }

    .score-pill {
        padding: 3px 10px;
        font-size: 0.82rem;
    }

    /* Gallery & Cards on Phone */
    .card {
        padding: 18px 14px;
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .gallery-item {
        height: 90px;
        font-size: 0.82rem;
        padding: 6px;
        text-align: center;
    }

    /* Off-Canvas Sidebar on Phone */
    .sidebar {
        width: min(85vw, 300px);
        padding: 20px 14px;
    }

    .sidebar-header {
        padding-bottom: 14px;
        margin-bottom: 14px;
    }

    .nav-btn {
        padding: 11px 12px;
        font-size: 0.9rem;
    }
}

/* Extra Small Phones (Max width 380px) */
@media (max-width: 380px) {
    .middle-buttons-grid {
        grid-template-columns: 1fr;
    }

    .school-main-title {
        font-size: 1.4rem;
    }

    .banner-badge {
        font-size: 0.66rem;
        padding: 4px 8px;
        gap: 3px;
    }

    .top-logo-img {
        width: 46px;
        height: 46px;
    }

    .sidebar-toggle-btn {
        width: 36px;
        height: 36px;
    }
}

/* =============================================
   Department Pill Badges (Grades Table)
   ============================================= */
.dept-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    white-space: nowrap;
}

.scientific-pill {
    background: var(--navy-light-bg);
    color: var(--navy-800);
    border: 1px solid var(--navy-subtle-border);
}

.literary-pill {
    background: var(--gold-100);
    color: var(--gold-800);
    border: 1px solid var(--gold-border-soft);
}

/* =============================================
   Grade Search Input
   ============================================= */
.grade-search-row {
    display: flex;
    gap: 10px;
    max-width: 580px;
}

.grade-search-input {
    flex: 1;
    padding: 12px 18px;
    border: 1.5px solid var(--card-border);
    border-radius: var(--radius-sm);
    font-size: 0.97rem;
    font-family: inherit;
    background: #ffffff;
    color: var(--text-main);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    text-align: right;
    direction: rtl;
}

.grade-search-input:focus {
    border-color: var(--gold-500);
    box-shadow: 0 0 0 3px rgba(201, 156, 46, 0.2);
}

/* =============================================
   Live Search Result Card
   ============================================= */
.student-result-card {
    display: flex;
    align-items: center;
    gap: 18px;
    background: #ffffff;
    border: 1.5px solid var(--gold-500);
    border-radius: var(--radius-sm);
    padding: 18px 22px;
    margin-top: 18px;
    animation: fadeIn 0.3s ease;
    box-shadow: 0 6px 20px rgba(201, 156, 46, 0.18);
}

.result-avatar {
    font-size: 2.6rem;
    flex-shrink: 0;
}

.result-info {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.result-name {
    font-size: 1.18rem;
    font-weight: 800;
    color: var(--navy-900);
}

.result-dept-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 12px;
    border-radius: 20px;
    font-size: 0.82rem;
    font-weight: 700;
    width: fit-content;
}

.result-gpa {
    font-size: 1.05rem;
    font-weight: 800;
    color: var(--gold-700);
}

.result-rank {
    font-size: 0.9rem;
    color: var(--text-muted);
    font-weight: 700;
}

/* =============================================
   Not-Found & Empty State Messages
   ============================================= */
.student-not-found {
    margin-top: 14px;
    padding: 14px 18px;
    background: #fff8eb;
    border: 1.5px solid var(--gold-300);
    border-radius: var(--radius-sm);
    color: #92400e;
    font-size: 0.92rem;
    font-weight: 600;
    animation: fadeIn 0.25s ease;
}

.grades-empty-state {
    text-align: center;
    padding: 34px 20px;
    color: var(--text-muted);
    font-size: 1rem;
    font-weight: 600;
}

/* =============================================
   Real Teacher Photo — Card Thumbnail
   ============================================= */
.teacher-avatar-photo {
    width: 74px;
    height: 74px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 12px;
    border: 3px solid var(--gold-400);
    box-shadow: 0 4px 14px rgba(201, 156, 46, 0.25);
    flex-shrink: 0;
}

.teacher-avatar-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

/* =============================================
   Real Teacher Photo — Profile View
   ============================================= */
.profile-img-real {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    overflow: hidden;
    border: 3.5px solid var(--gold-400);
    outline: 3px solid rgba(240, 215, 138, 0.3);
    box-shadow: 0 6px 22px rgba(201, 156, 46, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
}

.profile-img-real img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

/* =============================================
   Medallion Podium Ranks (1st, 2nd, 3rd)
   ============================================= */
.data-table tbody tr:nth-child(1) td:first-child strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #fae39e 0%, #c99c2e 100%);
    color: #4a3404;
    border: 1px solid #c99c2e;
    box-shadow: 0 2px 8px rgba(201, 156, 46, 0.4);
    font-weight: 800;
}

.data-table tbody tr:nth-child(2) td:first-child strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f8fafc 0%, #cbd5e1 100%);
    color: #334155;
    border: 1px solid #94a3b8;
    box-shadow: 0 2px 6px rgba(148, 163, 184, 0.3);
    font-weight: 800;
}

.data-table tbody tr:nth-child(3) td:first-child strong {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: linear-gradient(135deg, #fed7aa 0%, #d97706 100%);
    color: #451a03;
    border: 1px solid #d97706;
    box-shadow: 0 2px 6px rgba(217, 119, 6, 0.3);
    font-weight: 800;
}
.phone-link {
    color: var(--navy-900);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease, transform 0.2s ease, text-shadow 0.2s ease;
}

.phone-link:hover {
    color: var(--gold-600);
    text-decoration: none;
    transform: translateX(-2px);
    text-shadow: 0 0 10px rgba(201, 156, 46, 0.2);
}

.location-link {
    color: var(--navy-800);
    text-decoration: none;
    font-weight: 600;
    position: relative;
    display: inline-block;
    transition: color 0.2s ease, transform 0.2s ease, text-shadow 0.2s ease;
}

.location-link::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -2px;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--gold-500), var(--gold-400));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.25s ease;
    border-radius: 999px;
}

.location-link:hover {
    color: var(--gold-700);
    text-decoration: none;
    transform: translateX(-2px);
    text-shadow: 0 0 10px rgba(201, 156, 46, 0.15);
}

.location-link:hover::after {
    transform: scaleX(1);
}
