:root {
    --primary: #1e3a8a;
    --primary-dark: #0f172a;
    --primary-light: #3b82f6;
    --accent: #dc2626;
    --accent-hover: #b91c1c;
    --gold: #d97706;
    --bg-light: #f8fafc;
    --surface: #ffffff;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -2px rgba(0, 0, 0, 0.04);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-light);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

.container-narrow {
    max-width: 860px;
}

.section-padding {
    padding: 60px 0;
}

/* Header Nav */
.top-nav {
    background: var(--primary-dark);
    color: white;
    padding: 16px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

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

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

.inba-official-logo {
    height: 48px;
    width: 48px;
    object-fit: contain;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    background: #ffffff;
    padding: 2px;
    transition: transform 0.3s ease;
}

.inba-official-logo:hover {
    transform: scale(1.08) rotate(3deg);
}

.badge-insignia {
    background: linear-gradient(135deg, var(--accent), #991b1b);
    color: white;
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.1rem;
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    letter-spacing: 1px;
    box-shadow: 0 2px 6px rgba(220, 38, 38, 0.4);
}

.school-title {
    display: block;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.15rem;
    line-height: 1.2;
}

.school-subtitle {
    display: block;
    font-size: 0.8rem;
    color: #94a3b8;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-tag {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    color: #cbd5e1;
}

.btn-sitio-inba {
    background: linear-gradient(135deg, var(--accent), #b91c1c);
    color: white;
    text-decoration: none;
    font-weight: 700;
    font-size: 0.85rem;
    padding: 8px 18px;
    border-radius: 50px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.35);
    transition: all 0.3s ease;
}

.btn-sitio-inba:hover {
    background: linear-gradient(135deg, #ef4444, var(--accent));
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(220, 38, 38, 0.5);
    color: white;
}

/* Video Gallery Section */
.video-gallery-section {
    background: #0f172a;
    color: white;
}

.video-gallery-section .section-header h2 {
    color: white;
}

.video-gallery-section .section-header p {
    color: #94a3b8;
}

.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 28px;
    margin-top: 30px;
}

.video-card {
    background: #1e293b;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(255, 255, 255, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.4);
    border-color: rgba(59, 130, 246, 0.4);
}

.video-wrapper {
    position: relative;
    width: 100%;
    background: #000;
    aspect-ratio: 16 / 9;
}

.video-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.video-info {
    padding: 20px;
}

.video-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(220, 38, 38, 0.2);
    color: #fca5a5;
    border: 1px solid rgba(220, 38, 38, 0.3);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 50px;
    margin-bottom: 10px;
}

.video-info h3 {
    font-family: var(--font-heading);
    font-size: 1.15rem;
    font-weight: 700;
    color: white;
    margin-bottom: 6px;
    line-height: 1.3;
}

.video-info p {
    font-size: 0.88rem;
    color: #94a3b8;
    line-height: 1.5;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%);
    color: white;
    padding: 70px 0 90px;
    position: relative;
    overflow: hidden;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
}

.pill-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(217, 119, 6, 0.2);
    color: #fef08a;
    border: 1px solid rgba(217, 119, 6, 0.4);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.hero-text h1 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
    background: linear-gradient(to right, #ffffff, #e2e8f0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.lead-paragraph {
    font-size: 1.15rem;
    color: #cbd5e1;
    line-height: 1.7;
    margin-bottom: 28px;
}

.hero-meta {
    display: flex;
    gap: 20px;
    font-size: 0.85rem;
    color: #94a3b8;
}

.hero-meta span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.image-wrapper {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    border: 4px solid rgba(255, 255, 255, 0.1);
}

.image-wrapper img {
    width: 100%;
    height: 380px;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.image-wrapper:hover img {
    transform: scale(1.03);
}

.media-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(8px);
    padding: 10px 16px;
    font-size: 0.8rem;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Article Content */
.feature-box {
    background: white;
    border-left: 5px solid var(--accent);
    border-radius: var(--radius-sm);
    padding: 30px;
    box-shadow: var(--shadow-md);
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
    align-items: flex-start;
}

.feature-icon {
    width: 50px;
    height: 50px;
    background: #fef2f2;
    color: var(--accent);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}

.feature-text h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--primary-dark);
    margin-bottom: 8px;
}

.content-block h2 {
    font-family: var(--font-heading);
    color: var(--primary-dark);
    font-size: 1.8rem;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.content-block p {
    font-size: 1.05rem;
    color: #475569;
    margin-bottom: 16px;
}

/* Catalog Section */
.catalog-section {
    background: #f1f5f9;
}

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

.text-center {
    text-align: center;
}

.section-subtitle {
    color: var(--accent);
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.section-header h2 {
    font-family: var(--font-heading);
    font-size: 2.2rem;
    color: var(--primary-dark);
    margin: 6px 0;
}

.section-header p {
    color: var(--text-muted);
}

.catalog-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 35px;
    flex-wrap: wrap;
}

.level-tabs {
    display: flex;
    background: white;
    padding: 6px;
    border-radius: 50px;
    box-shadow: var(--shadow-sm);
}

.tab-btn {
    border: none;
    background: transparent;
    padding: 10px 22px;
    border-radius: 50px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.95rem;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.25s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tab-btn.active {
    background: var(--primary);
    color: white;
    box-shadow: 0 4px 10px rgba(30, 58, 138, 0.3);
}

.search-box {
    position: relative;
    flex-grow: 1;
    max-width: 380px;
}

.search-box i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.search-box input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border-radius: 50px;
    border: 1px solid var(--border-color);
    outline: none;
    font-size: 0.95rem;
    background: white;
    box-shadow: var(--shadow-sm);
    transition: border-color 0.2s ease;
}

.search-box input:focus {
    border-color: var(--primary-light);
}

.electives-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

.elective-card {
    background: white;
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.elective-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(30, 58, 138, 0.2);
}

.card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.dept-badge {
    padding: 4px 12px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dept-lengua { background: #eff6ff; color: #1d4ed8; }
.dept-filosofia { background: #fdf4ff; color: #a21caf; }
.dept-historia { background: #fff7ed; color: #c2410c; }
.dept-matematica { background: #f0fdf4; color: #15803d; }
.dept-biologia { background: #ecfdf5; color: #047857; }
.dept-quimica { background: #f0f9ff; color: #0369a1; }
.dept-fisica { background: #fae8ff; color: #86198f; }
.dept-edf { background: #fefce8; color: #a16207; }
.dept-artes { background: #fff1f2; color: #be123c; }
.dept-musica { background: #f5f3ff; color: #6d28d9; }

.grade-tag {
    background: #e2e8f0;
    color: #334155;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
}

.card-icon {
    font-size: 1.8rem;
    margin-bottom: 12px;
}

.elective-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-dark);
    margin-bottom: 8px;
    line-height: 1.3;
}

.card-footer {
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1fr solid #f1f5f9;
    font-size: 0.85rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* CTA Section */
.cta-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 50px 40px;
    box-shadow: var(--shadow-lg);
    text-align: center;
    border: 1px solid var(--border-color);
}

.cta-badge {
    display: inline-block;
    background: #fef2f2;
    color: var(--accent);
    font-weight: 700;
    padding: 6px 18px;
    border-radius: 50px;
    font-size: 0.85rem;
    margin-bottom: 16px;
}

.cta-card h2 {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--primary-dark);
    margin-bottom: 16px;
}

.cta-card p {
    font-size: 1.05rem;
    color: #475569;
    margin-bottom: 30px;
}

.inba-callout {
    background: #f8fafc;
    border-radius: var(--radius-md);
    padding: 24px 30px;
    margin: 30px 0;
    position: relative;
    border: 1px solid #e2e8f0;
}

.inba-callout i {
    font-size: 1.8rem;
    color: var(--primary-light);
    margin-bottom: 10px;
    display: block;
}

.inba-callout blockquote {
    font-style: italic;
    color: var(--primary-dark);
    font-weight: 600;
    font-size: 1.05rem;
    line-height: 1.7;
}

.final-motto {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.3rem;
    color: var(--accent);
    margin-top: 20px;
}

/* Footer */
.footer {
    background: var(--primary-dark);
    color: #94a3b8;
    padding: 30px 0;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-grid {
        grid-template-columns: 1fr;
    }
    .hero-text h1 {
        font-size: 1.9rem;
    }
    .catalog-controls {
        flex-direction: column;
        align-items: stretch;
    }
    .search-box {
        max-width: 100%;
    }
    .cta-card {
        padding: 30px 20px;
    }
}
