/* ========================
   CSS Variables & Root Styles
   ======================== */
:root {
    /* Primary Color Palette */
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #8b5cf6;
    
    /* Secondary Color Palette */
    --secondary-color: #f59e0b;
    --secondary-dark: #d97706;
    --secondary-light: #fbbf24;
    
    /* Complementary Colors */
    --accent-color: #10b981;
    --accent-dark: #059669;
    --accent-light: #34d399;
    
    /* Neutral Colors */
    --dark-color: #1f2937;
    --light-color: #f9fafb;
    --text-primary: #111827;
    --text-secondary: #6b7280;
    --text-muted: #9ca3af;
    --white: #ffffff;
    --black: #000000;
    
    /* Background Colors */
    --bg-primary: #ffffff;
    --bg-secondary: #f8fafc;
    --bg-dark: #1e293b;
    --bg-overlay: rgba(0, 0, 0, 0.5);
    
    /* Gradient Backgrounds */
    --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--primary-light));
    --gradient-secondary: linear-gradient(135deg, var(--secondary-color), var(--secondary-light));
    --gradient-accent: linear-gradient(135deg, var(--accent-color), var(--accent-light));
    --gradient-hero: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    --gradient-dark: linear-gradient(135deg, var(--dark-color), var(--primary-dark));
    
    /* Typography */
    --font-primary: 'Poppins', sans-serif;
    --font-secondary: 'Work Sans', sans-serif;
    
    /* Spacing */
    --section-padding: 80px 0;
    --container-padding: 0 15px;
    --card-padding: 30px;
    --element-spacing: 20px;
    
    /* Border Radius */
    --border-radius: 12px;
    --border-radius-sm: 8px;
    --border-radius-lg: 20px;
    
    /* Shadows */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.2);
    --shadow-colored: 0 8px 32px rgba(99, 102, 241, 0.3);
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Z-Index */
    --z-fixed: 1000;
    --z-modal: 1050;
    --z-dropdown: 1020;
    --z-tooltip: 1070;
}

/* ========================
   Base & Reset Styles
   ======================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-secondary);
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    overflow-x: hidden;
}

/* ========================
   Typography
   ======================== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

h1 {
    font-size: 3.5rem;
    font-weight: 700;
}

h2 {
    font-size: 2.5rem;
    font-weight: 600;
}

h3 {
    font-size: 2rem;
    font-weight: 600;
}

h4 {
    font-size: 1.5rem;
    font-weight: 600;
}

h5 {
    font-size: 1.25rem;
    font-weight: 600;
}

h6 {
    font-size: 1rem;
    font-weight: 600;
}

p {
    margin-bottom: 1rem;
    font-size: 1.1rem;
    line-height: 1.7;
}

.section-title {
    color: var(--text-primary);
    margin-bottom: 1rem;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.section-subtitle {
    color: var(--text-secondary);
    font-size: 1.2rem;
    text-align: center;
    margin-bottom: 2rem;
}

/* ========================
   Button Styles
   ======================== */
.btn {
    display: inline-block;
    padding: 12px 30px;
    font-size: 1rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: var(--border-radius);
    transition: all var(--transition-normal);
    border: 2px solid transparent;
    cursor: pointer;
    text-align: center;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn::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 var(--transition-slow);
    z-index: -1;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: var(--gradient-primary);
    color: var(--white);
    box-shadow: var(--shadow-colored);
}

.btn-primary:hover {
    background: var(--gradient-primary);
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.4);
    color: var(--white);
}

.btn-secondary {
    background: var(--gradient-secondary);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.btn-secondary:hover {
    background: var(--gradient-secondary);
    transform: translateY(-2px);
    box-shadow: 0 12px 40px rgba(245, 158, 11, 0.4);
    color: var(--white);
}

.btn-outline-primary {
    background: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    color: var(--white);
    transform: translateY(-2px);
}

.btn-outline-light {
    background: transparent;
    color: var(--white);
    border-color: var(--white);
}

.btn-outline-light:hover {
    background: var(--white);
    color: var(--primary-color);
    transform: translateY(-2px);
}

.btn-lg {
    padding: 16px 40px;
    font-size: 1.1rem;
}

.btn-sm {
    padding: 8px 20px;
    font-size: 0.9rem;
}

/* ========================
   Header & Navigation
   ======================== */
.header-section {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: var(--z-fixed);
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
}

.navbar {
    padding: 1rem 0;
    background: transparent;
}

.navbar-brand img {
    height: 50px;
    width: auto;
}

.navbar-nav {
    align-items: center;
}

.nav-link {
    color: var(--text-primary);
    font-weight: 500;
    padding: 0.5rem 1rem;
    transition: all var(--transition-normal);
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: all var(--transition-normal);
    transform: translateX(-50%);
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-link:hover::after {
    width: 80%;
}

.navbar-toggler {
    border: none;
    padding: 0.25rem 0.5rem;
}

.navbar-toggler:focus {
    box-shadow: none;
}

/* ========================
   Hero Section
   ======================== */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.8), rgba(245, 158, 11, 0.6));
    z-index: 1;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    color: var(--white) !important;
}

.hero-subtitle {
    font-size: 1.5rem;
    margin-bottom: 2rem;
    color: var(--white) !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 3rem;
    color: var(--white) !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    justify-content: center;
}

/* ========================
   Vision Section
   ======================== */
.vision-section {
    padding: var(--section-padding);
    background: var(--bg-secondary);
}

.vision-content {
    padding: 2rem;
}

.vision-image img {
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
    transition: transform var(--transition-slow);
}

.vision-image img:hover {
    transform: scale(1.05);
}

.features-list {
    margin-top: 2rem;
}

.feature-item {
    padding: 1.5rem;
    background: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-normal);
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.feature-item h5 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

/* ========================
   Courses Section
   ======================== */
.courses-section {
    padding: var(--section-padding);
}

.course-card {
    border: none;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-normal);
    background: var(--white);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.course-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.course-card .card-image {
    position: relative;
    overflow: hidden;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.course-card .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.course-card:hover .card-image img {
    transform: scale(1.1);
}

.course-card .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: var(--card-padding);
    text-align: center;
}

.course-card .card-title {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1.25rem;
}

.course-card .card-text {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    flex: 1;
}

.price-tag {
    text-align: center;
    margin-bottom: 1.5rem;
}

.price-tag .price {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ========================
   Awards Section
   ======================== */
.awards-section {
    padding: var(--section-padding);
    background: var(--bg-secondary);
}

.award-card {
    border: none;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-normal);
    background: var(--white);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.award-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.award-card .card-image {
    padding: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-secondary), var(--white));
    height: 150px;
}

.award-card .card-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.award-card .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
}

.award-card h5 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* ========================
   History Section
   ======================== */
.history-section {
    padding: var(--section-padding);
}

.history-content {
    padding: 2rem;
}

.history-timeline {
    position: relative;
    padding-left: 2rem;
}

.history-timeline::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--gradient-primary);
}

.timeline-item {
    position: relative;
    padding-left: 3rem;
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 0;
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    transform: translateX(-50%);
}

.timeline-year {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.timeline-content h5 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.timeline-content p {
    color: var(--text-secondary);
    margin-bottom: 0;
}

/* ========================
   Resources Section
   ======================== */
.resources-section {
    padding: var(--section-padding);
    background: var(--bg-secondary);
}

.resource-card {
    border: none;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-md);
    transition: all var(--transition-normal);
    background: var(--white);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.resource-card .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
}

.resource-card h5 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* ========================
   FAQ Section
   ======================== */
.faq-section {
    padding: var(--section-padding);
}

.faq-accordion .accordion-item {
    border: none;
    margin-bottom: 1rem;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.faq-accordion .accordion-button {
    background: var(--white);
    border: none;
    padding: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    box-shadow: none;
}

.faq-accordion .accordion-button:not(.collapsed) {
    background: var(--gradient-primary);
    color: var(--white);
}

.faq-accordion .accordion-button:focus {
    box-shadow: none;
}

.faq-accordion .accordion-body {
    padding: 1.5rem;
    background: var(--bg-secondary);
    color: var(--text-secondary);
}

/* ========================
   Media Section
   ======================== */
.media-section {
    padding: var(--section-padding);
    background: var(--bg-secondary);
}

.media-card {
    border: none;
    border-radius: var(--border-radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: all var(--transition-normal);
    background: var(--white);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.media-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.media-card .card-image {
    position: relative;
    overflow: hidden;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.media-card .card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-slow);
}

.media-card:hover .card-image img {
    transform: scale(1.1);
}

.media-card .card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
}

.media-card h5 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.media-card .text-muted {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

/* ========================
   Contact Section
   ======================== */
.contact-section {
    padding: var(--section-padding);
}

.contact-form-container {
    background: var(--white);
    padding: 3rem;
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-lg);
}

.contact-form .form-label {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.contact-form .form-control,
.contact-form .form-select {
    border: 2px solid #e5e7eb;
    border-radius: var(--border-radius);
    padding: 12px 16px;
    font-size: 1rem;
    transition: all var(--transition-normal);
    background: var(--white);
}

.contact-form .form-control:focus,
.contact-form .form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.25);
    outline: none;
}

/* ========================
   Footer
   ======================== */
.footer-section {
    background: var(--bg-dark);
    color: var(--white);
    padding: 3rem 0 1rem;
}

.footer-brand img {
    margin-bottom: 1rem;
}

.footer-section h5 {
    color: var(--white);
    margin-bottom: 1rem;
    font-weight: 600;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-section ul li a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color var(--transition-normal);
}

.footer-section ul li a:hover {
    color: var(--white);
}

.footer-section hr {
    border-color: rgba(255, 255, 255, 0.2);
    margin: 2rem 0 1rem;
}

/* ========================
   Modal Styles
   ======================== */
.modal-content {
    border-radius: var(--border-radius-lg);
    border: none;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    background: var(--gradient-primary);
    color: var(--white);
    border-radius: var(--border-radius-lg) var(--border-radius-lg) 0 0;
    border-bottom: none;
}

.modal-header .btn-close {
    filter: invert(1);
}

.modal-body {
    padding: 2rem;
}

.modal-footer {
    border-top: none;
    padding: 1rem 2rem 2rem;
}

/* ========================
   Utility Classes
   ======================== */
.parallax-bg {
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.text-gradient {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient-primary {
    background: var(--gradient-primary);
}

.bg-gradient-secondary {
    background: var(--gradient-secondary);
}

.shadow-custom {
    box-shadow: var(--shadow-lg);
}

.rounded-custom {
    border-radius: var(--border-radius-lg);
}

/* ========================
   Page-specific Styles
   ======================== */
.page-header {
    padding-top: 120px;
    padding-bottom: 2rem;
    background: var(--bg-secondary);
}

.page-content {
    padding: 2rem 0;
}

.success-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--gradient-primary);
    color: var(--white);
}

.success-content {
    text-align: center;
    padding: 3rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-lg);
    backdrop-filter: blur(10px);
}

.privacy-page,
.terms-page {
    padding-top: 100px;
}

.privacy-page .container,
.terms-page .container {
    padding: 2rem 0;
}

/* ========================
   Responsive Design
   ======================== */
@media (max-width: 1200px) {
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.3rem;
    }
    
    .hero-description {
        font-size: 1.1rem;
    }
}

@media (max-width: 992px) {
    .navbar-collapse {
        background-color: #fff;
    }
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .hero-buttons .btn {
        margin-bottom: 1rem;
    }
    
    .timeline-item {
        padding-left: 2rem;
    }
    
    .timeline-item::before {
        left: -1.5rem;
    }
}

@media (max-width: 768px) {
    :root {
        --section-padding: 60px 0;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .contact-form-container {
        padding: 2rem;
    }
    
    .history-timeline {
        padding-left: 1rem;
    }
    
    .timeline-item {
        padding-left: 1.5rem;
    }
    
    .timeline-item::before {
        left: -1rem;
    }
}

@media (max-width: 576px) {
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-buttons .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .contact-form-container {
        padding: 1.5rem;
    }
    
    .award-card .card-image {
        padding: 1rem;
    }
    
    .footer-section {
        text-align: center;
    }
    
    .footer-section .row > div {
        margin-bottom: 2rem;
    }
}

/* ========================
   Animation & Transitions
   ======================== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease-out;
}

.animate-fadeInLeft {
    animation: fadeInLeft 0.6s ease-out;
}

.animate-fadeInRight {
    animation: fadeInRight 0.6s ease-out;
}

/* ========================
   Scroll Animations
   ======================== */
.scroll-animation {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s ease-out;
}

.scroll-animation.animate {
    opacity: 1;
    transform: translateY(0);
}

/* ========================
   Loading States
   ======================== */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--primary-color);
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ========================
   Accessibility
   ======================== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* ========================
   Print Styles
   ======================== */
@media print {
    .header-section,
    .footer-section,
    .btn {
        display: none !important;
    }
    
    .hero-section {
        background: none !important;
        color: var(--black) !important;
    }
    
    .hero-title,
    .hero-subtitle,
    .hero-description {
        color: var(--black) !important;
    }
}