/* Enhanced Unified CSS for NCERT Class 10 English - First Flight Collection */

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.7;
    color: #2c3e50;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Add smooth scrolling */
html {
    scroll-behavior: smooth;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Enhanced Header Styles */
header {
    background: rgba(255, 255, 255, 0.98);
    padding: 3rem 2rem;
    text-align: center;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    margin-bottom: 3rem;
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

header::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

header:hover::before {
    left: 100%;
}

h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    letter-spacing: -0.02em;
    position: relative;
    z-index: 1;
}

.subtitle {
    font-size: 1.3rem;
    color: #666;
    margin-bottom: 1rem;
}

.description {
    font-size: 1.1rem;
    color: #555;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
}

/* Navigation Styles */
.nav-tabs {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
    background: white;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.nav-tab {
    padding: 1rem 2rem;
    background: none;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1rem;
    font-weight: 500;
}

.nav-tab:hover {
    background-color: #f8f9fa;
}

.nav-tab.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

/* Enhanced Content Sections */
.content-section {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    display: none;
    border: 1px solid rgba(102, 126, 234, 0.1);
    transition: all 0.3s ease;
}

.content-section.active {
    display: block;
}

.content-section:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

/* Enhanced Theme Sections */
.theme-section {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(15px);
    margin-bottom: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.theme-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.theme-title {
    font-size: 2.2rem;
    color: #2c3e50;
    margin-bottom: 2rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 1rem;
    font-weight: 600;
    position: relative;
}

.theme-title::after {
    content: '';
    position: absolute;
    bottom: -3px;
    left: 0;
    width: 50px;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.theme-description {
    font-size: 1.2rem;
    color: #555;
    margin-bottom: 2rem;
    line-height: 1.8;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 1.5rem;
    border-radius: 12px;
    border-left: 4px solid #667eea;
}

/* Typography */
h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
    font-size: 1.8rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 0.5rem;
}

h3 {
    color: #34495e;
    margin: 1.5rem 0 1rem 0;
    font-size: 1.4rem;
}

h4 {
    color: #34495e;
    margin: 1rem 0 0.5rem 0;
    font-size: 1.2rem;
}

p {
    margin-bottom: 1rem;
    text-align: justify;
}

/* Story and Content Text */
.story-text, .chapter-story-text {
    margin-bottom: 2rem;
    font-size: 1.1rem;
    line-height: 1.8;
}

.chapter-p {
    margin-bottom: 1rem;
    text-align: justify;
}

/* Quotes */
.quote, .chapter-quote {
    background: #f8f9fa;
    border-left: 4px solid #667eea;
    padding: 1rem;
    margin: 1rem 0;
    font-style: italic;
    font-size: 1.1rem;
}

/* Character Boxes */
.character-box, .chapter-character-box {
    background: #e8f4fd;
    border: 1px solid #bee5eb;
    border-radius: 8px;
    padding: 1rem;
    margin: 1rem 0;
}

.character-name, .chapter-character-name {
    font-weight: bold;
    color: #0c5460;
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

/* Theme Boxes */
.theme-box, .chapter-theme-box {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    padding: 1rem;
    margin: 1rem 0;
}

.theme-title, .chapter-theme-title {
    font-weight: bold;
    color: #856404;
    margin-bottom: 0.5rem;
}

/* Summary Boxes */
.summary-box, .chapter-summary-box {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.summary-title, .chapter-summary-title {
    font-weight: bold;
    color: #0c5460;
    font-size: 1.2rem;
    margin-bottom: 1rem;
}

/* Vocabulary */
.vocabulary, .chapter-vocabulary {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1rem;
    margin: 1rem 0;
}

.vocab-word, .chapter-vocab-word {
    font-weight: bold;
    color: #495057;
    background: #e3f2fd;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    margin-right: 0.5rem;
}

.vocab-meaning, .chapter-vocab-meaning {
    color: #6c757d;
    font-style: italic;
}

/* Questions */
.comprehension-questions {
    background: #e2e3e5;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.question, .chapter-question {
    margin-bottom: 1rem;
    padding: 0.5rem;
    background: white;
    border-radius: 5px;
}

.question-number, .chapter-question-number {
    font-weight: bold;
    color: #495057;
    margin-bottom: 0.5rem;
}

/* Dialogue */
.dialogue {
    background-color: #f8f9fa;
    border-left: 4px solid #667eea;
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 0 8px 8px 0;
}

.speaker {
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.stage-direction {
    font-style: italic;
    color: #7f8c8d;
    margin: 0.5rem 0;
    padding-left: 1rem;
}

/* Connection Analysis Styles */
.connection-analysis {
    background: #e8f5e8;
    border: 1px solid #28a745;
    border-radius: 10px;
    padding: 1.5rem;
    margin-top: 1.5rem;
}

.connection-title {
    color: #155724;
    font-weight: 600;
    margin-bottom: 1rem;
}

.connection-text {
    color: #155724;
    line-height: 1.6;
}

/* Archetype Section */
.archetype-section {
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 10px;
    padding: 1.5rem;
    margin-top: 1.5rem;
}

.archetype-title {
    color: #856404;
    font-weight: 600;
    margin-bottom: 1rem;
}

.archetype-text {
    color: #856404;
    line-height: 1.6;
}

/* Grid Layouts */
.works-grid, .characters-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 1.5rem;
}

.poems-column, .prose-column {
    background: #f8f9fa;
    padding: 1.5rem;
    border-radius: 10px;
    border-left: 4px solid #667eea;
}

.column-title {
    font-size: 1.3rem;
    color: #2c3e50;
    margin-bottom: 1rem;
    font-weight: 600;
}

/* Enhanced Item Styles */
.work-item, .character-item {
    background: white;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 1px solid rgba(102, 126, 234, 0.1);
    position: relative;
    overflow: hidden;
}

.work-item::before, .character-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

.work-item:hover, .character-item:hover {
    transform: translateX(8px) translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-color: rgba(102, 126, 234, 0.3);
}

.work-item:hover::before, .character-item:hover::before {
    width: 8px;
}

/* Enhanced Example Styles */
.example-section {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 15px;
    padding: 2rem;
    margin: 2rem 0;
    border: 1px solid rgba(102, 126, 234, 0.2);
    position: relative;
}

.example-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px 15px 0 0;
}

.example-title {
    font-size: 1.5rem;
    color: #2c3e50;
    margin-bottom: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.example-title::before {
    content: '📚';
    font-size: 1.2rem;
}

.indian-examples {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border: 2px solid #ffc107;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1rem 0;
}

.indian-examples .example-title::before {
    content: '🇮🇳';
}

.global-examples {
    background: linear-gradient(135deg, #d1ecf1 0%, #bee5eb 100%);
    border: 2px solid #17a2b8;
    border-radius: 12px;
    padding: 1.5rem;
    margin: 1rem 0;
}

.global-examples .example-title::before {
    content: '🌍';
}

.example-item {
    background: white;
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    border-left: 4px solid #667eea;
    transition: all 0.3s ease;
}

.example-item:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.15);
}

.example-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.example-description {
    color: #555;
    line-height: 1.6;
    font-size: 0.95rem;
}

.work-title, .character-name {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 0.5rem;
}

.work-author, .character-work {
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.work-theme, .character-traits {
    color: #888;
    font-size: 0.9rem;
    line-height: 1.4;
    margin-bottom: 0.5rem;
}

.character-journey {
    color: #555;
    font-size: 0.9rem;
    line-height: 1.4;
    font-style: italic;
}

/* Main Content Grid */
.main-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

.section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
}

.section-title {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: center;
    color: #2c3e50;
    border-bottom: 3px solid #667eea;
    padding-bottom: 0.5rem;
}

/* Lists */
.poem-list, .prose-list {
    list-style: none;
}

.poem-item, .prose-item {
    margin-bottom: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 10px;
    border-left: 4px solid #667eea;
    transition: all 0.3s ease;
}

.poem-item:hover, .prose-item:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.poem-item a, .prose-item a {
    text-decoration: none;
    color: #2c3e50;
    font-weight: 500;
    font-size: 1.1rem;
}

.poem-item a:hover, .prose-item a:hover {
    color: #667eea;
}

.author {
    font-style: italic;
    color: #666;
    font-size: 0.9rem;
    margin-top: 0.3rem;
}

.theme {
    font-size: 0.85rem;
    color: #888;
    margin-top: 0.2rem;
}

/* Analysis Section */
.analysis-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    margin-bottom: 2rem;
}

.analysis-title {
    font-size: 2.5rem;
    text-align: center;
    color: #2c3e50;
    margin-bottom: 2rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.connection-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.connection-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.connection-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    border-color: #667eea;
}

.connection-card h3 {
    color: #2c3e50;
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.connection-card p {
    color: #666;
    margin-bottom: 1rem;
    line-height: 1.6;
}

.connection-card a {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.connection-card a:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Stats Section */
.stats-section {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    margin-bottom: 2rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.stat-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1rem;
    opacity: 0.9;
}

/* Links */
.back-link {
    display: inline-block;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    border-radius: 25px;
    font-weight: 500;
    margin-top: 1rem;
    transition: all 0.3s ease;
}

.back-link:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Footer */
footer {
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem;
    text-align: center;
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    margin-top: 2rem;
}

.footer-content {
    color: #666;
    line-height: 1.8;
}

/* Chapter Specific Styles */
.chapter-page {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.chapter-header {
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem;
    text-align: center;
    border-radius: 15px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
}

.chapter-subtitle {
    font-size: 1.2rem;
    color: #666;
    margin-bottom: 1rem;
}

.back-to-index {
    color: white;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.2);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.back-to-index:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.chapter-h2 {
    color: #2c3e50;
    margin-bottom: 1rem;
    font-size: 1.8rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 0.5rem;
}

.chapter-h3 {
    color: #34495e;
    margin: 1.5rem 0 1rem 0;
    font-size: 1.4rem;
}

.chapter-h4 {
    color: #34495e;
    margin: 1rem 0 0.5rem 0;
    font-size: 1.2rem;
}

.chapter-story-divider {
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 2rem 0;
    border-radius: 1px;
}

/* Lessons Boxes */
.lessons-box, .chapter-lessons-box {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1.5rem 0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.lessons-title, .chapter-lessons-title {
    font-size: 1.3rem;
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #667eea;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-tabs {
        flex-direction: column;
    }
    
    .nav-tab {
        border-bottom: 1px solid #dee2e6;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .container {
        padding: 10px;
    }
    
    .main-content {
        grid-template-columns: 1fr;
    }
    
    .works-grid, .characters-grid {
        grid-template-columns: 1fr;
    }
    
    .connection-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

@media (max-width: 480px) {
    .container {
        padding: 5px;
    }
    
    header, .section, .analysis-section, .stats-section {
        padding: 1rem;
    }
    
    h1 {
        font-size: 1.5rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .analysis-title {
        font-size: 2rem;
    }
}
