/* IB Biology Styles - External CSS File */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #334155;
    background: #f8fafc;
}

.bio-page-wrapper {
    min-height: 100vh;
}

/* ========================================
   THEME A - BLUE (DEFAULT)
   ======================================== */
[data-theme="theme-a"] .bio-hero {
    background: linear-gradient(135deg, #1e40af 0%, #3b82f6 50%, #06b6d4 100%);
}

/* ========================================
   THEME B - GREEN 
   ======================================== */
[data-theme="theme-b"] .bio-hero {
    background: linear-gradient(135deg, #059669 0%, #10b981 50%, #34d399 100%);
}

[data-theme="theme-b"] .nav-card {
    border-left: 6px solid #059669;
    box-shadow: 0 10px 30px rgba(5, 150, 105, 0.1);
}

[data-theme="theme-b"] .nav-card:hover {
    box-shadow: 0 15px 35px rgba(5, 150, 105, 0.2);
}

[data-theme="theme-b"] .nav-card h3 {
    color: #059669;
}

[data-theme="theme-b"] .section-header h3 {
    color: #059669;
}

[data-theme="theme-b"] .jump-links-section strong {
    color: #059669;
}

[data-theme="theme-b"] .jump-sub-link {
    background: rgba(5, 150, 105, 0.1);
    color: #059669;
    border: 1px solid rgba(5, 150, 105, 0.2);
}

[data-theme="theme-b"] .jump-sub-link:hover {
    background: #059669;
    color: white;
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.3);
}

[data-theme="theme-b"] .jump-link {
    background: linear-gradient(135deg, #059669, #10b981);
}

[data-theme="theme-b"] .jump-link:hover {
    box-shadow: 0 8px 25px rgba(5, 150, 105, 0.4);
}

[data-theme="theme-b"] .btn {
    background: linear-gradient(135deg, #059669, #10b981);
}

[data-theme="theme-b"] .btn:hover {
    box-shadow: 0 4px 15px rgba(5, 150, 105, 0.4);
}

[data-theme="theme-b"] .level-badge.sl {
    background: #d1fae5;
    color: #059669;
}

[data-theme="theme-b"] .level-badge.hl {
    background: #a7f3d0;
    color: #047857;
}

[data-theme="theme-b"] .level-badge.both {
    background: #6ee7b7;
    color: #065f46;
}

/* ========================================
   THEME C - ORANGE/RED
   ======================================== */
[data-theme="theme-c"] .bio-hero {
    background: linear-gradient(135deg, #ea580c 0%, #f59e0b 50%, #ef4444 100%);
}

[data-theme="theme-c"] .nav-card {
    border-left: 6px solid #ea580c;
    box-shadow: 0 10px 30px rgba(234, 88, 12, 0.1);
}

[data-theme="theme-c"] .nav-card:hover {
    box-shadow: 0 15px 35px rgba(234, 88, 12, 0.2);
}

[data-theme="theme-c"] .nav-card h3 {
    color: #ea580c;
}

[data-theme="theme-c"] .section-header h3 {
    color: #ea580c;
}

[data-theme="theme-c"] .jump-links-section strong {
    color: #ea580c;
}

[data-theme="theme-c"] .jump-sub-link {
    background: rgba(234, 88, 12, 0.1);
    color: #ea580c;
    border: 1px solid rgba(234, 88, 12, 0.2);
}

[data-theme="theme-c"] .jump-sub-link:hover {
    background: #ea580c;
    color: white;
    box-shadow: 0 4px 12px rgba(234, 88, 12, 0.3);
}

[data-theme="theme-c"] .jump-link {
    background: linear-gradient(135deg, #ea580c, #f59e0b);
}

[data-theme="theme-c"] .jump-link:hover {
    box-shadow: 0 8px 25px rgba(234, 88, 12, 0.4);
}

[data-theme="theme-c"] .btn {
    background: linear-gradient(135deg, #ea580c, #f59e0b);
}

[data-theme="theme-c"] .btn:hover {
    box-shadow: 0 4px 15px rgba(234, 88, 12, 0.4);
}

[data-theme="theme-c"] .level-badge.sl {
    background: #fed7aa;
    color: #ea580c;
}

[data-theme="theme-c"] .level-badge.hl {
    background: #fdba74;
    color: #c2410c;
}

[data-theme="theme-c"] .level-badge.both {
    background: #fb923c;
    color: #9a3412;
}

/* ========================================
   THEME D - PURPLE
   ======================================== */
[data-theme="theme-d"] .bio-hero {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 50%, #06b6d4 100%);
}

[data-theme="theme-d"] .nav-card {
    border-left: 6px solid #7c3aed;
    box-shadow: 0 10px 30px rgba(124, 58, 237, 0.1);
}

[data-theme="theme-d"] .nav-card:hover {
    box-shadow: 0 15px 35px rgba(124, 58, 237, 0.2);
}

[data-theme="theme-d"] .nav-card h3 {
    color: #7c3aed;
}

[data-theme="theme-d"] .section-header h3 {
    color: #7c3aed;
}

[data-theme="theme-d"] .jump-links-section strong {
    color: #7c3aed;
}

[data-theme="theme-d"] .jump-sub-link {
    background: rgba(124, 58, 237, 0.1);
    color: #7c3aed;
    border: 1px solid rgba(124, 58, 237, 0.2);
}

[data-theme="theme-d"] .jump-sub-link:hover {
    background: #7c3aed;
    color: white;
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.3);
}

[data-theme="theme-d"] .jump-link {
    background: linear-gradient(135deg, #7c3aed, #8b5cf6);
}

[data-theme="theme-d"] .jump-link:hover {
    box-shadow: 0 8px 25px rgba(124, 58, 237, 0.4);
}

[data-theme="theme-d"] .btn {
    background: linear-gradient(135deg, #7c3aed, #8b5cf6);
}

[data-theme="theme-d"] .btn:hover {
    box-shadow: 0 4px 15px rgba(124, 58, 237, 0.4);
}

[data-theme="theme-d"] .level-badge.sl {
    background: #e4d4f4;
    color: #7c3aed;
}

[data-theme="theme-d"] .level-badge.hl {
    background: #c4b5fd;
    color: #6d28d9;
}

[data-theme="theme-d"] .level-badge.both {
    background: #a78bfa;
    color: #581c87;
}

/* ========================================
   BASE STYLES (APPLY TO ALL THEMES)
   ======================================== */

/* Hero Section */
.bio-hero {
    color: white;
    padding: 120px 40px 80px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.bio-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grid" width="10" height="10" patternUnits="userSpaceOnUse"><path d="M 10 0 L 0 0 0 10" fill="none" stroke="rgba(255,255,255,0.1)" stroke-width="0.5"/></pattern></defs><rect width="100" height="100" fill="url(%23grid)"/></svg>');
    opacity: 0.3;
}

.bio-hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.bio-topic-code {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 25px;
    padding: 0.7rem 1.5rem;
    display: inline-block;
    font-weight: 400;
    margin-bottom: 2rem;
    font-size: 1rem;
    color: white;
    letter-spacing: 0.5px;
}

.bio-hero h1 {
    font-size: 4rem;
    font-weight: 300;
    margin-bottom: 20px;
    letter-spacing: -0.02em;
}

.bio-subtitle {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 30px;
    color: rgba(255, 255, 255, 0.9);
}

.bio-description {
    font-size: 1.2rem;
    line-height: 1.8;
    max-width: 600px;
    margin: 0 auto;
    color: rgba(255, 255, 255, 0.8);
}

/* Container */
.bio-overview-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 80px 40px;
}

/* Navigation Cards */
.nav-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 60px;
}

.nav-card {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
    border-radius: 20px;
    padding: 30px;
    border-left: 6px solid #06b6d4;
    transition: all 0.3s ease;
    position: relative;
    box-shadow: 0 10px 30px rgba(6, 182, 212, 0.1);
}

.nav-card:hover {
    transform: translateY(-5px);
}

.nav-card h3 {
    color: #1e40af;
    font-size: 1.5rem;
    margin-bottom: 15px;
}

.nav-card p {
    color: #475569;
    margin-bottom: 20px;
}

.jump-link {
    display: inline-block;
    background: linear-gradient(135deg, #1e40af, #06b6d4);
    color: white;
    padding: 12px 24px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.jump-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(30, 64, 175, 0.4);
    text-decoration: none;
    color: white;
}

.jump-links-section {
    margin-bottom: 1rem;
}

.jump-links-section strong {
    color: #1e40af;
    font-size: 0.9rem;
    display: block;
    margin-bottom: 0.5rem;
    margin-top: 1rem;
}

.jump-links-section strong:first-child {
    margin-top: 0;
}

.jump-sub-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.jump-sub-link {
    display: inline-block;
    background: rgba(30, 64, 175, 0.1);
    color: #1e40af;
    padding: 6px 12px;
    border-radius: 15px;
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid rgba(30, 64, 175, 0.2);
}

.jump-sub-link:hover {
    background: #1e40af;
    color: white;
    transform: translateY(-1px);
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.3);
}

/* Content Sections */
.content-section {
    margin-bottom: 3rem;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e0e0e0;
}

.section-header h3 {
    font-size: 1.8rem;
    color: #1e40af;
}

/* Material Cards */
.material-card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.material-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.material-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.material-title h4 {
    color: #333;
    font-size: 1.1rem;
}

.pdf-icon {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: bold;
    min-width: 40px;
    text-align: center;
}

.embed-container iframe {
    width: 100%;
    border: none;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.embed-note {
    text-align: center;
    color: #666;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.action-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.btn {
    background: linear-gradient(135deg, #1e40af, #06b6d4);
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(30, 64, 175, 0.4);
    text-decoration: none;
    color: white;
}

.item-number {
    background: #f0f0f0;
    color: #666;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

/* Level Badges */
.level-badge {
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.85rem;
    font-weight: 600;
    position: absolute;
    top: 20px;
    right: 20px;
}

.level-badge.sl {
    background: #e3f2fd;
    color: #1976d2;
}

.level-badge.hl {
    background: #fff3e0;
    color: #f57c00;
}

.level-badge.both {
    background: #f3e5f5;
    color: #7b1fa2;
}

/* Responsive */
@media (max-width: 768px) {
    .bio-hero {
        padding: 80px 20px 60px;
    }
    
    .bio-hero h1 {
        font-size: 2.5rem;
    }
    
    .bio-overview-container {
        padding: 40px 20px;
    }
    
    .nav-grid {
        grid-template-columns: 1fr;
    }
    
    .material-card {
        padding: 1rem;
    }
}