/* --- 1. Design System & Variables --- */
:root {
    --primary-color: #0d3b66; /* Deep, professional blue */
    --secondary-color: #faf0ca; /* Soft, complementary yellow */
    --accent-color: #f95738;   /* Bright, attention-grabbing orange */
    --text-dark: #222222;
    --text-light: #f8f9fa;
    --background-light: #f8f9fa;
    --shadow: 0 4px 15px rgba(0,0,0,0.1);
    --hero-max: 1000px;
}

/* --- 2. General Setup & Body --- */
html {
    scroll-behavior: smooth;
}

[data-aos] {
overflow-x: clip; /* modern browsers, better than hidden */
will-change: transform;
max-width: 100%;
}

body {
    font-family: 'Lato', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #fff;
    color: var(--text-dark);
    line-height: 1.7;
}

/* --- 3. Reusable Components --- */
.container {
    max-width: 1100px;
    margin: auto;
    padding: 0 20px;
    overflow: visible;
}

section {
    padding: 80px 0;
}

section h2 {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.5rem;
    text-align: center;
    color: var(--primary-color);
    margin-top: 0;
    margin-bottom: 50px;
}

.cta-button {
    display: inline-block;
    background-color: var(--accent-color);
    color: #fff;
    padding: 15px 35px;
    text-decoration: none;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1.1rem;
    font-family: 'Montserrat', sans-serif;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 4px 10px rgba(249, 87, 56, 0.4);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(249, 87, 56, 0.5);
}

/* --- 4. Navigation Bar --- */
.navbar {
    background: #fff;
    padding: 15px 0;
    position: sticky;
    top: 0;
    width: 100%;
    z-index: 1000;

}
.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.navbar .logo {
    font-family: 'Montserrat', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}
.nav-links {
    list-style: none;
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
    gap: 30px; /* Modern way to space items */
}
.nav-links a {
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 700;
    transition: color 0.3s ease;
}
.nav-links a:hover {
    color: var(--accent-color);
}
.nav-button {
    padding: 8px 20px;
    font-size: 0.9rem;
    box-shadow: 0 2px 5px rgba(249, 87, 56, 0.4);
    color: #fff !important;
}
.nav-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(249, 87, 56, 0.5);
    color: #fff !important;
}

/* --- Hamburger Menu --- */
.menu-toggle {
    display: none; /* Hidden on desktop */
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
}
.menu-toggle .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px 0;
    background: var(--primary-color);
    transition: all 0.3s ease-in-out;
}

/* Animate hamburger to 'X' when active */
.navbar.active .menu-toggle .bar:nth-child(2) {
    opacity: 0;
}
.navbar.active .menu-toggle .bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}
.navbar.active .menu-toggle .bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* --- 5. Hero Section --- */
.hero {
  position: relative;
  padding: clamp(3.5rem, 8vw, 8rem) 0;

  /* make positions relative to the CONTAINER, not the viewport */
  /* side gap = leftover space either side of your centered container */
  --side-gap: max((100vw - var(--hero-max)) / 2, 24px);

  background-image:
    url("/img/hero-book.svg"),
    url("/img/hero-microscope.svg"),
    url("/img/hero-atom.svg"),
    url("/img/hero-flask.svg");
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat;

  /* hug the container edges */
  background-position:
    /* left sticker, just outside the container */
    calc(var(--side-gap) - 40px) 14%,
    /* right sticker, just outside the container */
    calc(100% - var(--side-gap) + 30px) 18%,
    /* bottom-left */
    calc(var(--side-gap) - 32px) 86%,
    /* bottom-right */
    calc(100% - var(--side-gap) + 24px) 88%;

  background-size:
    clamp(52px, 9vw, 110px),
    clamp(64px, 10vw, 130px),
    clamp(56px, 9vw, 120px),
    clamp(48px, 8vw, 100px);
}

.hero .container {
  max-width: var(--hero-max);
  margin: 0 auto;
  padding: 0 24px;
  text-align: center;
  position: relative;
  z-index: 1; /* text always above any backgrounds */
}

/* tighten on tablets */
@media (max-width: 900px) {
  .hero {
    background-position:
      calc(var(--side-gap) - 50px) 12%,
      calc(100% - var(--side-gap) + 40px) 20%,
      calc(var(--side-gap) - 44px) 88%,
      calc(100% - var(--side-gap) + 36px) 90%;
    background-size: 60px, 70px, 60px, 56px;
  }
}

/* keep mobile clean: smaller type and fewer stickers */
@media (max-width: 600px) {
  .hero {
    background-image:
      url("/img/hero-book.svg"),
      url("/img/hero-flask.svg"); /* keep two accents only */
    background-position:
      calc(var(--side-gap) - 56px) 10%,
      calc(100% - var(--side-gap) + 48px) 92%;
    background-size: 56px, 56px;
  }
}

/* responsive type so the headline doesn’t overcrowd */
.hero h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(2rem, 6vw, 3.5rem);
  color: var(--primary-color);
  margin: 0 auto 15px auto;
  max-width: 800px;
}

.hero p {
  font-size: clamp(1rem, 2.2vw, 1.3rem);
  max-width: 700px;
  margin: 0 auto 30px auto;
}

/* --- 6. New About Me Section --- */
.about-me-layout {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 50px;
    align-items: center;
}
.about-me-image img {
    width: 100%;
    max-width: 300px;
    border-radius: 50%;
    box-shadow: var(--shadow);
    border: 5px solid var(--secondary-color);
}
.about-me-text h3 {
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-color);
    font-size: 2rem;
    margin-top: 0;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    text-align: center;
}

.feature-card {
    background: #fff;
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.feature-card .icon {
    height: 50px;
    width: 50px;
    margin-bottom: 20px;
    fill: var(--accent-color);
}

.feature-card h3 {
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-color);
    font-size: 1.4rem;
}

/* Courses */

.course-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.course-card {
    background: var(--background-light);
    border: 1px solid #eee;
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    overflow: clip;
}

.course-card h3 {
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-color);
    margin-top: 0;
    margin-bottom: 15px;
}

.course-description {
    flex-grow: 1; /* This makes the cards equal height */
    margin-bottom: 20px;
}

.course-info {
    font-weight: bold;
    color: var(--text-dark);
}

.course-card .price {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
    margin: 20px 0 0 0;
    font-family: 'Montserrat', sans-serif;
}
.course-card .price span {
    font-size: 1rem;
    font-weight: 400;
}

.waiting-list-link {
    display: block;
    margin-top: 25px;
    padding: 10px;
    text-align: center;
    background: #e9ecef;
    color: var(--primary-color);
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    transition: background-color 0.3s;
}
.waiting-list-link:hover {
    background-color: var(--secondary-color);
}

.course-card.featured {
    background: var(--secondary-color);
    border: 2px solid var(--primary-color);
    position: relative;
    overflow: hidden;
}

.featured-badge {
    position: absolute;
    top: 45px;
    right: 20px;
    background: var(--accent-color);
    color: white;
    padding: 5px 40px;
    transform: translate(35%, -35%) rotate(45deg);
    font-size: 0.8rem;
    font-weight: bold;
}

.course-includes {
    text-align: center;
    margin-top: 60px;
    background: var(--background-light);
    padding: 30px;
    border-radius: 10px;
}

.course-includes h4 {
    font-family: 'Montserrat', sans-serif;
    margin-top: 0;
    color: var(--primary-color);
}

.course-includes ul {
    list-style: none;
    padding: 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
}

.course-includes li {
    font-size: 1rem;
    font-weight: bold;
}

/* --- 9. Contact Section --- */
#contact {
    text-align: center;
    background: var(--secondary-color);
}

#contact p {
    max-width: 600px;
    margin: 0 auto 30px auto;
}

#plan {
    background-color: var(--background-light);
}

/* --- 10. Footer --- */
footer {
    background: var(--text-dark);
    color: var(--text-light);
    text-align: center;
    padding: 30px 0;
}

/* --- 11. Mobile Responsiveness --- */
@media (max-width: 768px) {
    h1 { font-size: 2.5rem; }
    h2 { font-size: 2rem; }
    
    .navbar .container { flex-direction: column; }
    .navbar .logo { margin-bottom: 15px; }
    .navbar .nav-links li { margin: 0 10px; }
    .hero h1 { font-size: 2.5rem; }
    .hero p { font-size: 1rem; }

    .features-grid { grid-template-columns: 1fr; }

    .about-me-layout {
        grid-template-columns: 1fr;
        text-align: center;
    }
    .about-me-image {
        margin-bottom: 30px;
    }
}

.section-intro {
    text-align: center;
    max-width: 700px;
    margin: -30px auto 50px auto;
    font-size: 1.1rem;
}

/* --- 12. Hamburger Menu Styles --- */
.menu-toggle {
    display: none; /* Hidden on desktop */
    flex-direction: column;
    cursor: pointer;
}
.menu-toggle .bar {
    height: 3px;
    width: 25px;
    background-color: var(--primary-color);
    margin: 4px 0;
}

/* --- FAQ Section Styles --- */
.faq-accordion {
    max-width: 800px;
    margin: 0 auto;
    border-top: 1px solid #ddd;
}
.faq-item {
    border-bottom: 1px solid #ddd;
}
.faq-question {
    width: 100%;
    background: none;
    border: none;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    font-size: 1.2rem;
    font-family: 'Montserrat', sans-serif;
    color: var(--primary-color);
    text-align: left;
}
.faq-icon {
    font-size: 1.8rem;
    font-weight: 300;
    transition: transform 0.3s ease;
}
.faq-question.active .faq-icon {
    transform: rotate(45deg);
}
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
}
.faq-answer p {
    padding: 0 20px 20px 20px;
    margin: 0;
    line-height: 1.8;
}

/* Mobile behaviour */
@media (max-width: 768px) {
    .menu-toggle { display: inline-flex; }
    .nav-links {
        position: absolute;
        left: 0;
        top: 100%;
        width: 100%;
        background: #fff;
        list-style: none;
        flex-direction: column;
        align-items: stretch;
        border-top: 1px solid rgba(0,0,0,.08);

        /* hidden by default */
        max-height: 0;
        overflow: hidden;
        opacity: 0;
        pointer-events: none;
        transition: max-height .3s ease, opacity .2s ease;
    }
    .nav-links li { padding: 12px 20px; }

    /* show when nav is active */
    .navbar.active .nav-links {
        max-height: 60vh;
        opacity: 1;
        pointer-events: auto;
    }
}
