/* ── CSS Variables ─────────────────────────────────────────────────────── */
:root {
    --primary: #0a1636;
    --secondary: #3f80ff;
    --accent: #3db558;
    --light: #eff4ff;
    --success: #27ae60;
    --text: #0d1b3a;
    --text-light: #55627b;
}

/* ── Reset & Base ──────────────────────────────────────────────────────── */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    color: var(--text);
    line-height: 1.6;
    background-color: #f9f9f9;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ── Header ────────────────────────────────────────────────────────────── */
header {
    background-color: var(--primary);
    color: white;
    padding: 20px 0;
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    color: white;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo span {
    color: var(--secondary);
}

.logo-mark {
    width: 44px;
    height: 44px;
    border-radius: 10px;
    object-fit: contain;
    background: rgba(255, 255, 255, 0.04);
}

nav ul {
    display: flex;
    list-style: none;
}

nav ul li {
    margin-left: 30px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

nav ul li a:hover,
nav ul li a.active {
    color: var(--secondary);
}

.mobile-menu {
    display: none;
    font-size: 24px;
    cursor: pointer;
    color: white;
    z-index: 1001;
}

/* ── Hero Section ──────────────────────────────────────────────────────── */
.hero {
    background: linear-gradient(rgba(10, 22, 54, 0.88), rgba(10, 22, 54, 0.92)),
                url('https://images.unsplash.com/photo-1522071820081-009f0129c71c?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    padding: 180px 0 100px;
    text-align: center;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero p {
    font-size: 20px;
    max-width: 800px;
    margin: 0 auto 40px;
}

/* ── Buttons ───────────────────────────────────────────────────────────── */
.btn {
    display: inline-block;
    background-color: var(--secondary);
    color: white;
    padding: 12px 30px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background-color: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.btn-accent {
    background-color: var(--accent);
    margin-left: 15px;
}

.btn-accent:hover {
    background-color: #2d9e49;
}

/* ── Sections ──────────────────────────────────────────────────────────── */
.section {
    padding: 100px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 60px;
}

.section-title h2 {
    font-size: 36px;
    color: var(--primary);
    position: relative;
    display: inline-block;
    padding-bottom: 15px;
}

.section-title h2::after {
    content: '';
    position: absolute;
    width: 70px;
    height: 3px;
    background-color: var(--secondary);
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

/* ── About Section ─────────────────────────────────────────────────────── */
.about-content {
    display: flex;
    align-items: center;
    gap: 50px;
}

.about-text {
    flex: 1;
}

.about-text h3 {
    font-size: 28px;
    margin-bottom: 20px;
    color: var(--primary);
}

.about-image {
    flex: 1;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.about-image img {
    width: 100%;
    height: auto;
    display: block;
}

/* ── Programs Section ──────────────────────────────────────────────────── */
.programs {
    background-color: var(--light);
}

.programs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.program-card {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    transition: transform 0.3s, box-shadow 0.3s;
}

.program-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.program-image {
    height: 200px;
    overflow: hidden;
}

.program-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.program-card:hover .program-image img {
    transform: scale(1.1);
}

.program-content {
    padding: 25px;
}

.program-content h3 {
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--primary);
}

.program-content p {
    color: var(--text-light);
    margin-bottom: 20px;
}

/* ── Stats Section ─────────────────────────────────────────────────────── */
.stats {
    background: linear-gradient(rgba(10, 22, 54, 0.86), rgba(63, 128, 255, 0.78)),
                url('https://images.unsplash.com/photo-1454165804606-c3d57bc86b40?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    background-size: cover;
    background-position: center;
    color: white;
    text-align: center;
    padding: 80px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.stat-item h3 {
    font-size: 50px;
    font-weight: 700;
    margin-bottom: 10px;
}

.stat-item p {
    font-size: 18px;
    opacity: 0.9;
}

/* ── Team Section ──────────────────────────────────────────────────────── */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 30px;
}

.team-member {
    background-color: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

.team-member:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.team-image {
    height: 250px;
    overflow: hidden;
}

.team-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-info {
    padding: 25px;
}

.team-info h3 {
    font-size: 22px;
    margin-bottom: 5px;
    color: var(--primary);
}

.team-info p {
    color: var(--secondary);
    font-weight: 500;
    margin-bottom: 15px;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.social-links a {
    color: var(--text-light);
    font-size: 18px;
    transition: color 0.3s;
}

.social-links a:hover {
    color: var(--secondary);
}

/* ── Contact Section ───────────────────────────────────────────────────── */
.contact {
    background-color: var(--light);
}

.contact-container {
    display: flex;
    gap: 50px;
}

.contact-info {
    flex: 1;
}

.contact-info h3 {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--primary);
}

.contact-details {
    margin-bottom: 30px;
}

.contact-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 20px;
}

.contact-icon {
    font-size: 20px;
    color: var(--secondary);
    margin-right: 15px;
    margin-top: 5px;
}

.contact-text h4 {
    font-size: 18px;
    margin-bottom: 5px;
}

.contact-text p,
.contact-text a {
    color: var(--text-light);
    text-decoration: none;
}

.contact-text a:hover {
    color: var(--secondary);
}

.contact-form {
    flex: 1;
    background-color: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.form-status {
    margin-top: 15px;
    padding: 10px;
    border-radius: 5px;
    display: none;
}

.success {
    background-color: #d4edda;
    color: #155724;
    display: block;
}

.error {
    background-color: #f8d7da;
    color: #721c24;
    display: block;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-control:focus {
    outline: none;
    border-color: var(--secondary);
}

textarea.form-control {
    min-height: 150px;
    resize: vertical;
}

/* ── Footer ────────────────────────────────────────────────────────────── */
footer {
    background-color: var(--primary);
    color: white;
    padding: 60px 0 20px;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-col h3 {
    font-size: 20px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 2px;
    background-color: var(--secondary);
    bottom: 0;
    left: 0;
}

.footer-col p {
    margin-bottom: 15px;
    opacity: 0.8;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: white;
    opacity: 0.8;
    text-decoration: none;
    transition: opacity 0.3s;
}

.footer-links a:hover {
    opacity: 1;
    color: var(--secondary);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
}

.footer-bottom p {
    opacity: 0.7;
    font-size: 14px;
}

/* ── Footer Social Icons ───────────────────────────────────────────────── */
.footer-social {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 8px;
}

.footer-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255,255,255,0.1);
    color: white;
    border-radius: 50%;
    font-size: 15px;
    text-decoration: none;
    transition: background-color 0.3s, transform 0.2s;
}

.footer-social-link:hover {
    background-color: var(--secondary);
    transform: translateY(-3px);
}

/* ── Scroll-Reveal Animation ───────────────────────────────────────────── */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ── Back-to-Top Button ────────────────────────────────────────────────── */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: var(--secondary);
    color: white;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s, background-color 0.3s;
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: #2980b9;
}

/* ── Skip to Content ───────────────────────────────────────────────────── */
.skip-link {
    position: absolute;
    top: -50px;
    left: 0;
    background: var(--secondary);
    color: white;
    padding: 8px 15px;
    z-index: 9999;
    transition: top 0.2s;
    text-decoration: none;
    border-radius: 0 0 5px 0;
}

.skip-link:focus {
    top: 0;
}

/* ── Preloader ─────────────────────────────────────────────────────────── */
#preloader {
    position: fixed;
    inset: 0;
    background-color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

#preloader.loaded {
    opacity: 0;
    visibility: hidden;
}

.preloader-inner {
    position: relative;
    width: 80px;
    height: 80px;
}

.preloader-ring {
    position: absolute;
    inset: 0;
    border: 4px solid rgba(255,255,255,0.15);
    border-top-color: var(--secondary);
    border-radius: 50%;
    animation: spin 0.85s linear infinite;
}

.preloader-logo {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -1px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ── Hero Badge & Typing Animation ────────────────────────────────────── */
.hero-badge {
    display: inline-block;
    background-color: rgba(52, 152, 219, 0.2);
    color: #7ec8e3;
    border: 1px solid rgba(52, 152, 219, 0.5);
    padding: 6px 18px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    margin-bottom: 22px;
}

.typed-word {
    color: var(--secondary);
}

.typed-cursor {
    display: inline-block;
    width: 3px;
    background-color: var(--secondary);
    animation: blink 0.75s step-end infinite;
    vertical-align: text-bottom;
    margin-left: 2px;
    height: 0.8em;
}

@keyframes blink { 50% { opacity: 0; } }

/* ── Program Badges ────────────────────────────────────────────────────── */
.badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 20px;
    margin-bottom: 10px;
}

.badge-flagship { background-color: #fde8e8; color: #9b1c1c; }
.badge-popular  { background-color: #dbeafe; color: #1e40af; }
.badge-open     { background-color: #def7ec; color: #03543f; }

/* ── Values Section ────────────────────────────────────────────────────── */
.values {
    background-color: white;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 28px;
}

.value-card {
    background-color: #f8fafc;
    border-radius: 12px;
    padding: 35px 28px;
    text-align: center;
    border: 1px solid #e8ecf0;
    transition: transform 0.3s, box-shadow 0.3s, border-color 0.3s;
}

.value-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.08);
    border-color: var(--secondary);
}

.value-icon {
    width: 68px;
    height: 68px;
    background-color: rgba(52, 152, 219, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 26px;
    color: var(--secondary);
    transition: background-color 0.3s, color 0.3s;
}

.value-card:hover .value-icon {
    background-color: var(--secondary);
    color: white;
}

.value-card h3 {
    font-size: 19px;
    color: var(--primary);
    margin-bottom: 12px;
}

.value-card p {
    color: var(--text-light);
    font-size: 15px;
    line-height: 1.7;
}

/* ── Newsletter Section ────────────────────────────────────────────────── */
.newsletter {
    background: linear-gradient(135deg, #0a1636 0%, #152b64 100%);
    padding: 80px 0;
    color: white;
    text-align: center;
}

.newsletter-content h2 {
    font-size: 34px;
    margin-bottom: 14px;
}

.newsletter-content > p {
    font-size: 17px;
    opacity: 0.8;
    max-width: 580px;
    margin: 0 auto 32px;
}

.newsletter-form {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    max-width: 520px;
    margin: 0 auto;
}

.newsletter-input {
    flex: 1;
    min-width: 210px;
    padding: 13px 18px;
    border: none;
    border-radius: 5px;
    font-size: 15px;
    outline: none;
    background-color: rgba(255,255,255,0.95);
    color: var(--text);
}

.newsletter-input:focus {
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.5);
}

.newsletter-status {
    margin-top: 14px;
    font-size: 14px;
    min-height: 20px;
    opacity: 0.9;
}

.cta-link-group {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 14px;
}

.cta-link-group.center {
    justify-content: center;
}

.capsule-btn {
    padding: 12px 22px;
    border-radius: 999px;
}

/* ── Curriculum Access Integrity Section ─────────────────────────────── */
.access {
    background: linear-gradient(180deg, #f7faff 0%, #eef3ff 100%);
}

.access-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.access-card {
    background-color: white;
    border: 1px solid #dfe7fb;
    border-radius: 12px;
    padding: 28px 24px;
    box-shadow: 0 12px 24px rgba(10, 22, 54, 0.06);
}

.access-card h3 {
    font-size: 20px;
    margin-bottom: 12px;
    color: var(--primary);
}

.access-card h3 i {
    color: var(--accent);
    margin-right: 8px;
}

.access-card p {
    margin-bottom: 12px;
    color: var(--text-light);
}

.access-card ul {
    padding-left: 20px;
    color: var(--text);
}

.access-request {
    margin-top: 40px;
    background-color: white;
    border-radius: 12px;
    border: 1px solid #dfe7fb;
    padding: 30px;
    box-shadow: 0 12px 24px rgba(10, 22, 54, 0.05);
}

.access-request h3 {
    color: var(--primary);
    margin-bottom: 8px;
}

.access-request p {
    color: var(--text-light);
    margin-bottom: 16px;
}

.access-request-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    align-items: end;
}

.access-request-form .btn {
    height: 49px;
    align-self: end;
}

.access-request-form .newsletter-status {
    grid-column: 1 / -1;
    margin-top: 0;
}

.footer-logo {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    margin-bottom: 10px;
    object-fit: contain;
}

/* ── Responsive Styles ─────────────────────────────────────────────────── */
@media (max-width: 992px) {
    .about-content {
        flex-direction: column;
    }

    .contact-container {
        flex-direction: column;
    }

    .section {
        padding: 70px 0;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 60px 0;
    }

    .section-title {
        margin-bottom: 40px;
    }

    .hero {
        padding: 130px 0 70px;
    }

    .hero h1 {
        font-size: 34px;
    }

    .hero p {
        font-size: 17px;
    }

    .section-title h2 {
        font-size: 28px;
    }

    .about-text h3 {
        font-size: 22px;
    }

    .stat-item h3 {
        font-size: 38px;
    }

    .stat-item p {
        font-size: 16px;
    }

    .contact-form {
        padding: 25px;
    }

    .newsletter-content h2 {
        font-size: 28px;
    }

    .newsletter-content > p {
        font-size: 16px;
    }

    .mobile-menu {
        display: block;
    }

    nav {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        background-color: var(--primary);
        padding: 20px 0;
        transition: all 0.5s ease;
        box-shadow: 0 10px 15px rgba(0,0,0,0.1);
    }

    nav.active {
        left: 0;
    }

    nav ul {
        flex-direction: column;
        align-items: center;
    }

    nav ul li {
        margin: 15px 0;
    }

    .btn {
        display: block;
        width: max-content;
        margin: 0 auto 15px;
    }

    .btn-accent {
        margin-left: auto;
        margin-right: auto;
    }

    .programs-grid {
        grid-template-columns: 1fr;
    }

    .values-grid {
        grid-template-columns: 1fr 1fr;
    }

    .access-request {
        padding: 24px;
    }
}

@media (max-width: 480px) {
    .section {
        padding: 50px 0;
    }

    .hero {
        padding: 110px 0 55px;
    }

    .hero h1 {
        font-size: 26px;
    }

    .hero p {
        font-size: 15px;
    }

    .team-grid,
    .values-grid {
        grid-template-columns: 1fr;
    }

    .stat-item h3 {
        font-size: 32px;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 20px;
    }

    .contact-form {
        padding: 20px 15px;
    }

    .footer-container {
        grid-template-columns: 1fr 1fr;
    }

    .back-to-top {
        bottom: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .newsletter-form {
        flex-direction: column;
        align-items: stretch;
    }

    .newsletter-input {
        min-width: unset;
    }
}
