/* ================================
   Ad Astra Tuition - Apple-Style CSS
   Brand: Deep Navy, Gold, Off-White
   Typography: Playfair Display, Source Sans Pro
   ================================ */

/* ===== CSS VARIABLES ===== */
:root {
    /* Brand Colors */
    --deep-navy: #0F1E3A;
    --gold: #C9A44C;
    --off-white: #F7F7F5;
    --slate-grey: #4A4A4A;
    --white: #FFFFFF;
    --light-grey: #E5E5E5;
    
    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Source Sans Pro', sans-serif;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;
    
    /* Transitions */
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.2s ease;
}

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--slate-grey);
    background-color: var(--white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

/* ===== CONTAINER ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

/* ===== NAVIGATION ===== */
.nav-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid rgba(15, 30, 58, 0.1);
    transition: var(--transition-fast);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--spacing-sm) 0;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--deep-navy);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: var(--spacing-md);
}

.nav-links a {
    color: var(--slate-grey);
    font-weight: 400;
    font-size: 0.95rem;
    letter-spacing: 0.3px;
}

.nav-links a:hover {
    color: var(--deep-navy);
}

/* ===== BUTTONS ===== */
.btn-primary,
.btn-primary-large {
    display: inline-block;
    background: var(--gold);
    color: var(--deep-navy);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.95rem;
    border: none;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.btn-primary-large {
    padding: 1rem 2.5rem;
    font-size: 1.05rem;
    border-radius: 12px;
}

.btn-primary:hover,
.btn-primary-large:hover {
    background: #b89440;
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(201, 164, 76, 0.3);
}

.btn-secondary-large {
    display: inline-block;
    background: transparent;
    color: var(--white);
    padding: 1rem 2.5rem;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.05rem;
    border: 2px solid var(--white);
    transition: var(--transition-smooth);
}

.btn-secondary-large:hover {
    background: var(--white);
    color: var(--deep-navy);
    transform: translateY(-2px);
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--white);
    overflow: hidden;
    margin-top: 60px;
}

.hero-image-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(15, 30, 58, 0.5) 0%,
        rgba(15, 30, 58, 0.7) 100%
    );
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    padding: var(--spacing-lg) var(--spacing-md);
}

.hero-title {
    font-family: var(--font-heading);
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: var(--spacing-md);
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    font-weight: 300;
    margin-bottom: var(--spacing-lg);
    opacity: 0.95;
}

.hero-cta {
    display: flex;
    gap: var(--spacing-md);
    justify-content: center;
    flex-wrap: wrap;
}

/* Animation Classes */
.fade-in {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.fade-in-delay {
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.2s forwards;
}

.fade-in-delay-2 {
    opacity: 0;
    animation: fadeInUp 0.8s ease 0.4s forwards;
}

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

/* ===== SECTION STYLING ===== */
section {
    padding: var(--spacing-xl) 0;
}

.section-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.section-title {
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: var(--deep-navy);
    margin-bottom: var(--spacing-sm);
}

.section-subtitle {
    font-size: 1.1rem;
    color: var(--slate-grey);
    font-weight: 300;
}

/* ===== COURSES SECTION ===== */
.courses-section {
    background: var(--off-white);
}

.courses-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.course-card {
    background: var(--white);
    border-radius: 16px;
    overflow: hidden;
    transition: var(--transition-smooth);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.course-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

.course-card.featured {
    border: 2px solid var(--gold);
}

.course-image-container {
    position: relative;
    width: 100%;
    height: 240px;
    overflow: hidden;
}

.course-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: var(--transition-smooth);
}

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

.course-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(15, 30, 58, 0) 0%,
        rgba(15, 30, 58, 0.3) 100%
    );
    opacity: 0.6;
    transition: var(--transition-fast);
}

.course-card:hover .course-overlay {
    opacity: 0.4;
}

.featured-badge {
    position: absolute;
    top: var(--spacing-sm);
    right: var(--spacing-sm);
    background: var(--gold);
    color: var(--white);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    z-index: 10;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.course-content {
    padding: var(--spacing-md);
}

.course-title {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--deep-navy);
    margin-bottom: var(--spacing-xs);
}

.course-description {
    color: var(--slate-grey);
    font-size: 1rem;
    margin-bottom: var(--spacing-md);
}

.course-meta {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
    margin-bottom: var(--spacing-md);
}

.course-badge {
    background: var(--light-grey);
    color: var(--slate-grey);
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
}

.course-badge.gold {
    background: rgba(201, 164, 76, 0.15);
    color: #9e7d2e;
}

.course-link {
    color: var(--deep-navy);
    font-weight: 600;
    font-size: 1rem;
    transition: var(--transition-fast);
}

.course-link:hover {
    color: var(--gold);
}

/* ===== ABOUT SECTION ===== */
.about-section {
    background: var(--white);
}

.about-content {
    max-width: 900px;
    margin: 0 auto;
}

.about-text {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--slate-grey);
    margin-bottom: var(--spacing-md);
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.value-item {
    padding: var(--spacing-md);
    background: var(--off-white);
    border-radius: 12px;
    transition: var(--transition-fast);
}

.value-item:hover {
    background: var(--light-grey);
    transform: translateY(-4px);
}

.value-item h4 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--deep-navy);
    margin-bottom: var(--spacing-xs);
}

.value-item p {
    color: var(--slate-grey);
    font-size: 0.95rem;
}

/* ===== CONTACT SECTION ===== */
.contact-section {
    background: var(--off-white);
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-lg);
    margin-top: var(--spacing-lg);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.contact-item h4 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--deep-navy);
    margin-bottom: var(--spacing-xs);
}

.contact-item a {
    color: var(--slate-grey);
    font-size: 1.05rem;
}

.contact-item a:hover {
    color: var(--gold);
}

/* ===== FORMS ===== */
.contact-form {
    background: var(--white);
    padding: var(--spacing-md);
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--deep-navy);
    margin-bottom: var(--spacing-xs);
    font-size: 0.95rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid var(--light-grey);
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--deep-navy);
    box-shadow: 0 0 0 3px rgba(15, 30, 58, 0.1);
}

/* ===== FOOTER ===== */
.footer {
    background: var(--deep-navy);
    color: var(--off-white);
    padding: var(--spacing-lg) 0 var(--spacing-md);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-lg);
}

.footer-col h4 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    margin-bottom: var(--spacing-sm);
    color: var(--gold);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: var(--spacing-xs);
    opacity: 0.9;
}

.footer-col a:hover {
    color: var(--gold);
}

.footer-tagline {
    color: var(--gold);
    font-style: italic;
    margin-top: var(--spacing-xs);
}

.footer-bottom {
    border-top: 1px solid rgba(247, 247, 245, 0.2);
    padding-top: var(--spacing-md);
    text-align: center;
    opacity: 0.8;
    font-size: 0.9rem;
}

.footer-disclaimer {
    margin-top: var(--spacing-xs);
    font-size: 0.85rem;
}

/* ===== RESPONSIVE IMAGES ===== */
@media (max-width: 768px) {
    .hero-image-container {
        height: 100vh;
    }
    
    .course-image-container {
        height: 200px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-cta {
        flex-direction: column;
        align-items: center;
    }
    
    .btn-primary-large,
    .btn-secondary-large {
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 480px) {
    .course-image-container {
        height: 180px;
    }
    
    .courses-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-links {
        display: none;
    }
}

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

/* Focus visible for keyboard navigation */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 3px solid var(--gold);
    outline-offset: 2px;
}
