/* ============================================
   MODERN EDUCATIONAL WEBSITE DESIGN
   Bold, Visual, Inspiring
   ============================================ */

:root {
    /* Blue and White Palette */
    /* Dark Blue - Header/Footer/Hero */
    --primary-blue: #0A192F;
    --secondary-blue: #112240;
    --accent-blue: #172A45;

    /* Light/Electric Blue - Accents */
    --light-blue: #64FFDA;
    /* Keep a high-tech accent */
    --link-blue: #00A3FF;

    /* Whites */
    --white: #ffffff;
    --off-white: #f8fafc;
    --text-white: #e2e8f0;

    /* Grays (Still needed for subtext) */
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;

    /* Base Colors */
    --bg-light: #ffffff;
    --text-dark: #1e293b;
    --text-muted: #64748b;

    /* Gradients */
    --gradient-blue: linear-gradient(135deg, #0A192F 0%, #172A45 100%);
    --gradient-hero: linear-gradient(rgba(10, 25, 47, 0.7), rgba(10, 25, 47, 0.7));

    /* Shadows - REMOVED per user request */
    --shadow-sm: none;
    --shadow-md: none;
    --shadow-lg: none;
    --shadow-xl: none;
    --shadow-2xl: none;

    /* Transitions */
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    border: none !important;
    /* Forces invisible borders per user request */
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--white);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ============================================
   TYPOGRAPHY
   ============================================ */

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    line-height: 1.2;
    color: var(--text-dark);
}

h1 {
    font-size: 3.5rem;
    letter-spacing: -0.02em;
}

h2 {
    font-size: 2.5rem;
    letter-spacing: -0.01em;
}

h3 {
    font-size: 2rem;
}

h4 {
    font-size: 1.5rem;
}

h5 {
    font-size: 1.25rem;
}

h6 {
    font-size: 1rem;
}

p {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--text-gray);
}

a {
    color: var(--primary-color);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--primary-dark);
}

/* ============================================
   HEADER & NAVIGATION
   ============================================ */

.main-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--primary-blue);
    transition: var(--transition);
}

.header-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-placeholder {
    width: 60px;
    height: 60px;
    background: white;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.school-name h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--white);
    margin: 0;
}

.school-name p {
    font-size: 0.9rem;
    color: var(--gray-400);
    margin: 0;
}

.main-nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin: 0;
}

.nav-links a {
    color: var(--text-white);
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 0;
    position: relative;
    transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--white);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--link-blue);
    transition: var(--transition);
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.cta-button {
    background: var(--link-blue);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    font-weight: 600;
    transition: var(--transition);
}

.cta-button:hover {
    background: #0082cc;
    color: white;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 0.5rem;
    background: var(--primary-blue); /* match theme */
    border-radius: 4px;
}

.menu-toggle span {
    width: 28px;
    height: 3px;
    background: var(--link-blue); /* accent color */
    border-radius: 2px;
    transition: var(--transition);
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero-section {
    position: relative;
    min-height: 90vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
    overflow: hidden;
    margin-top: 80px;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23ffffff" fill-opacity="0.1" d="M0,96L48,112C96,128,192,160,288,160C384,160,480,128,576,122.7C672,117,768,139,864,138.7C960,139,1056,117,1152,101.3C1248,85,1344,75,1392,69.3L1440,64L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
    background-size: cover;
    opacity: 0.3;
}

.hero-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-content h1 {
    font-size: 4rem;
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    font-weight: 800;
}

.hero-content h1 span {
    background: linear-gradient(135deg, #e5e5e5, #a3a3a3);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-content p {
    font-size: 1.375rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    gap: 1.25rem;
    flex-wrap: wrap;
}

.btn-primary {
    background: white;
    color: black;
    padding: 1.125rem 2.5rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.125rem;
    box-shadow: var(--shadow-xl);
    transition: var(--transition);
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-2xl);
    background: var(--gray-100);
    color: black;
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    color: white;
    padding: 1.125rem 2.5rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.125rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: var(--transition);
    cursor: pointer;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-3px);
}

.hero-image {
    position: relative;
}

.hero-image img {
    width: 100%;
    height: auto;
    border-radius: 24px;
    box-shadow: var(--shadow-2xl);
}

/* ============================================
   SECTIONS
   ============================================ */

.section {
    padding: 8rem 2rem;
    background: var(--bg-light);
}

.section.alt-bg {
    background: var(--primary-blue);
    color: var(--white);
}

.section-container {
    max-width: 1300px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-header h2 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: inherit;
    margin-bottom: 1.5rem;
    font-weight: 800;
    letter-spacing: -1px;
}

.section-header p {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

/* ============================================
   CARDS (Border-less & Shadow-less)
   ============================================ */

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.card {
    background: transparent;
    overflow: hidden;
    transition: var(--transition);
    border: none !important;
}

.card:hover {
    transform: translateY(-5px);
}

.card-image {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 8px;
}

.card-content {
    padding: 1.5rem 0;
}

.card-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: inherit;
    margin-bottom: 0.75rem;
}

.card-text {
    color: var(--text-muted);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.card-link {
    color: var(--link-blue);
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

/* ============================================
   STATS
   ============================================ */

.stat-item {
    text-align: center;
    padding: 2rem;
    border: none !important;
}

.stat-number {
    font-size: 4rem;
    font-weight: 800;
    color: var(--link-blue);
    margin-bottom: 0.5rem;
    line-height: 1;
}

.stat-label {
    font-size: 1.1rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Footer overrides */
.main-footer {
    background: var(--primary-blue);
    padding: 6rem 2rem 3rem;
}

.footer-section h3 {
    font-size: 1.1rem;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 2rem;
}

/* Base sections logic for home.php */
.section[style*="black"] {
    background: var(--primary-blue) !important;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-section h3 {
    color: white;
    margin-bottom: 1.5rem;
    font-size: 1.25rem;
    font-weight: 700;
}

.footer-section p,
.footer-section a {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 0.75rem;
    display: block;
    transition: var(--transition);
}

.footer-section a:hover {
    color: white;
    transform: translateX(5px);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
    text-align: center;
    color: rgba(255, 255, 255, 0.6);
}

/* ============================================
   GEOMETRIC SLANTS
   ============================================ */

.slant-container {
    position: relative;
    padding: 10rem 0;
    margin-top: -5rem;
    overflow: hidden;
}

.slant-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    clip-path: polygon(0 15%, 100% 0, 100% 85%, 0 100%);
}

.slant-bg.white {
    background: var(--white);
}

.slant-bg.blue {
    background: var(--primary-blue);
}

.slant-content {
    position: relative;
    z-index: 1;
}

/* ============================================
   SURPRISE HERO & PREMIUM UTILITIES
   ============================================ */

.split-hero {
    display: grid;
    grid-template-columns: 0.8fr 1.2fr;
    min-height: 100vh;
    background: var(--primary-blue);
    position: relative;
    overflow: hidden;
}

.hero-visual {
    position: relative;
    height: 100%;
    width: 100%;
}

.hero-visual img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: blur(2px) brightness(0.4);
    clip-path: polygon(15% 0, 100% 0, 100% 100%, 0% 100%);
}

.glass-card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 12px;
    padding: 1.5rem;
}

.text-outline {
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.3);
    color: transparent;
}

/* --- Hero 2.0: Cinematic Surprise (Preserves legacy blocks) --- */
.hero-cinematic {
    position: relative;
    width: 100%;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-blue);
    overflow: hidden;
    padding: 2rem;
}

.hero-bg-wrapper {
    position: absolute;
    top: -5%;
    left: -5%;
    width: 110%;
    height: 110%;
    z-index: 0;
}

.hero-bg-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.4) blur(4px);
}

.hero-glass-card {
    position: relative;
    z-index: 10;
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    padding: 4rem;
    max-width: 900px;
    width: 100%;
    text-align: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.hero-badge-pill {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: rgba(0, 163, 255, 0.15);
    color: var(--link-blue);
    border-radius: 50px;
    font-weight: 800;
    font-size: 0.9rem;
    letter-spacing: 1px;
    margin-bottom: 2rem;
    border: 1px solid rgba(0, 163, 255, 0.2);
}

.ambient-glow {
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(0, 163, 255, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    z-index: 1;
    pointer-events: none;
    filter: blur(80px);
}

.glow-1 {
    top: -10%;
    left: -10%;
    animation: glowMove 20s infinite alternate;
}

.glow-2 {
    bottom: -10%;
    right: -10%;
    animation: glowMove 15s infinite alternate-reverse;
}

@keyframes glowMove {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(10%, 10%) scale(1.2);
    }
}

/* --- Hero 3.0: Architectural Professionalism --- */
.hero-architectural {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background: #ffffff;
    display: flex;
    align-items: stretch;
    overflow: hidden;
}

.hero-arch-left {
    flex: 1.2;
    background: #001a33;
    /* Deep Professional Navy */
    padding: 10% 8% 5% 15%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    z-index: 2;
}

.hero-arch-right {
    flex: 0.8;
    position: relative;
    z-index: 1;
}

.hero-arch-title {
    font-size: clamp(4rem, 10vw, 7rem);
    line-height: 0.8;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: -4px;
    text-transform: uppercase;
    margin-bottom: 2rem;
}

.hero-arch-title span.outline {
    -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.4);
    color: transparent;
}

.hero-arch-subtitle {
    font-size: 1.25rem;
    color: #a0aec0;
    max-width: 500px;
    line-height: 1.7;
    margin-bottom: 3.5rem;
    border-left: 3px solid var(--link-blue);
    padding-left: 2rem;
}

.arch-magazine-frame {
    position: absolute;
    top: 50%;
    left: -15%;
    transform: translateY(-50%);
    width: 130%;
    height: 80vh;
    border: 15px solid #ffffff;
    box-shadow: 30px 30px 80px rgba(0, 0, 0, 0.15);
    border-radius: 4px;
    overflow: hidden;
}

.arch-magazine-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-arch-btns {
    display: flex;
    gap: 2rem;
}

.hero-arch-btns .btn-primary {
    background: var(--link-blue);
    color: #ffffff;
    padding: 1.25rem 3rem;
    font-weight: 900;
    letter-spacing: 1px;
    text-decoration: none;
    border-radius: 2px;
}

.hero-arch-btns .btn-secondary {
    border: 2px solid #ffffff !important;
    color: #ffffff;
    padding: 1.25rem 3rem;
    font-weight: 900;
    letter-spacing: 1px;
    text-decoration: none;
    border-radius: 2px;
}

/* --- Hero 4.0: Institutional Bento Grid --- */
.hero-bento {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 45vh);
    gap: 1.5rem;
    padding: 2rem;
    background: #f8fafc;
    width: 100%;
    min-height: 100vh;
}

.bento-tile {
    position: relative;
    border-radius: 24px;
    overflow: hidden;
    background: #ffffff;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.tile-main-image {
    grid-column: span 2;
    grid-row: span 2;
}

.tile-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tile-title {
    grid-column: span 2;
    background: #001a33;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem;
}

.tile-title h1 {
    font-size: clamp(3rem, 6vw, 4.5rem);
    line-height: 0.85;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: -3px;
    text-transform: uppercase;
}

.tile-title h1 span.highlight {
    color: var(--link-blue);
}

.tile-badge {
    grid-column: span 1;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    text-align: center;
}

.tile-badge .badge-content {
    background: rgba(0, 163, 255, 0.05);
    padding: 2rem;
    border-radius: 20px;
    border: 1px solid rgba(0, 163, 255, 0.1);
}

.tile-badge h4 {
    font-size: 0.9rem;
    color: var(--link-blue);
    font-weight: 800;
    letter-spacing: 2px;
}

.tile-action {
    grid-column: span 1;
    background: var(--link-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.tile-action .btn-bento {
    background: #ffffff;
    color: var(--link-blue);
    padding: 1.5rem 2.5rem;
    border-radius: 50px;
    font-weight: 900;
    text-decoration: none;
    font-size: 1.1rem;
    transition: transform 0.2s ease;
}

.tile-action .btn-bento:hover {
    transform: scale(1.05);
}

/* Responsive adjustment */
@media (max-width: 1024px) {
    .hero-bento {
        grid-template-columns: repeat(2, 1fr);
        grid-template-rows: auto;
    }

    .tile-main-image {
        grid-column: span 2;
        grid-row: span 1;
        height: 50vh;
    }

    .tile-title {
        grid-column: span 2;
        padding: 2.5rem;
    }

    .tile-badge {
        grid-column: span 1;
    }

    .tile-action {
        grid-column: span 1;
    }
}

/* --- Hero 5.0: Alkifah Inspiration (Classic Corporate) --- */
.hero-alkifah {
    position: relative;
    width: 100%;
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    background: url('/Shkolla/LutfiBRR.jpg') no-repeat center center/cover;
    overflow: hidden;
}

.hero-alkifah::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 51, 153, 0.9) 0%, rgba(0, 51, 153, 0.7) 100%);
    z-index: 1;
}

.hero-alkifah-content {
    position: relative;
    z-index: 2;
    padding: 6rem 2rem 2rem 2rem;
    /* Added top padding to offset header */
    max-width: 900px;
}

.hero-alkifah-title {
    font-size: clamp(3rem, 7vw, 5rem);
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1.5rem;
}

.hero-alkifah-text {
    font-size: 1.25rem;
    color: #ffffff;
    margin-bottom: 3rem;
    line-height: 1.6;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.9;
}

.hero-alkifah-btns {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
}

.btn-alkifah-blue {
    background: #003399;
    color: #ffffff;
    padding: 1rem 3rem;
    border-radius: 8px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-alkifah-blue:hover {
    background: #002673;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.btn-alkifah-outline {
    background: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
    padding: 1rem 3rem;
    border-radius: 8px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-alkifah-outline:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.floating-stats {
    position: absolute;
    bottom: 10%;
    left: -10%;
    z-index: 10;
    min-width: 300px;
}

/* Interactive Canvas Background */
.hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* =========================================
   Loading Overlay (Dark Blue Theme)
   ========================================= */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 25, 47, 0.95);
    /* Deep Dark Blue transparent */
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.loading-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.loader {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid var(--link-blue);
    /* Blue accent - fixed variable */
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1.5rem;
}

.loading-text {
    color: white;
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    animation: pulse 1.5s ease-in-out infinite;
}

.loading-subtext {
    color: var(--gray-400);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.8;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

/* =========================================
   Loading Overlay (Dark Blue Theme)
   ========================================= */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(10, 25, 47, 0.95);
    /* Deep Dark Blue transparent */
    backdrop-filter: blur(8px);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.loading-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.loader {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top: 4px solid var(--primary-org);
    /* Orange accent */
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 1.5rem;
}

.loading-text {
    color: white;
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    animation: pulse 1.5s ease-in-out infinite;
}

.loading-subtext {
    color: var(--gray-400);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes pulse {

    0%,
    100% {
        opacity: 0.8;
        transform: scale(1);
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

.orb {
    position: absolute;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0, 163, 255, 0.1) 0%, transparent 70%);
    border-radius: 50%;
    filter: blur(50px);
    z-index: 0;
    animation: orbFloat 15s ease-in-out infinite alternate;
}

@keyframes orbFloat {
    0% {
        transform: translate(-10%, -10%);
    }

    100% {
        transform: translate(10%, 10%);
    }
}

/* ============================================
   UTILITIES
   ============================================ */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

.text-center {
    text-align: center;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
    .hero-container {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .hero-content h1 {
        font-size: 3rem;
    }

    h2 {
        font-size: 2.25rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--primary-blue); /* themed background */
        flex-direction: column;
        padding: 2rem;
        box-shadow: var(--shadow-lg);
        display: none;
        gap: 0;
        z-index: 1001; /* ensure menu floats above other content */
    }

    .main-nav.active {
        display: flex !important; /* force visibility in case of specificity issues */
    }

    .nav-links {
        flex-direction: column;
        gap: 0;
        width: 100%;
    }

    .nav-links a {
        padding: 1rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        color: var(--text-white) !important;
    }

    .nav-links a:hover,
    .nav-links a.active {
        color: var(--light-blue) !important;
    }

    .cta-button {
        margin-top: 1rem;
        text-align: center;
        background: var(--link-blue);
        color: #fff;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-content p {
        font-size: 1.125rem;
    }

    .section {
        padding: 4rem 1.5rem;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .hero-section {
        min-height: auto;
        padding: 4rem 0;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .btn-primary,
    .btn-secondary {
        width: 100%;
        text-align: center;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Subpage Hero (Standardized) --- */
.subpage-hero {
    position: relative;
    width: 100%;
    height: 40vh;
    min-height: 300px;
    background: var(--primary-blue);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    text-align: center;
}

.subpage-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(0, 163, 255, 0.1) 0%, transparent 70%);
}

.subpage-hero-content {
    position: relative;
    z-index: 2;
    padding: 0 2rem;
}

.subpage-hero h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    color: var(--white);
    margin: 0;
    text-transform: uppercase;
    letter-spacing: -1px;
}

/* --- Slant & Layout Utilities --- */
.slant-container {
    position: relative;
    width: 100%;
    padding: 8rem 0;
    overflow: visible;
}

.slant-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.slant-bg.white {
    background: var(--white);
    clip-path: polygon(0 10%, 100% 0, 100% 100%, 0 90%);
}

.slant-bg.blue {
    background: var(--secondary-blue);
    clip-path: polygon(0 0, 100% 10%, 100% 90%, 0 100%);
}

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.slant-content {
    position: relative;
    z-index: 2;
}

.section-header {
    margin-bottom: 4rem;
    text-align: center;
}

.section-header h2 {
    font-size: 3rem;
    text-transform: uppercase;
    font-weight: 900;
    margin-bottom: 1rem;
}

/* Ensure cards work well within slants */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}