/* ================================================
   JOSLYN AUBIN — ACADEMIC COACHING & TUTORING
   Main Stylesheet
   ================================================ */

/* === CSS Custom Properties === */
:root {
  --navy:        #1d3557;
  --navy-deep:   #132438;
  --navy-mid:    #2e527a;
  --slate:       #4d6e8a;
  --slate-light: #8ba5bc;
  --slate-pale:  #ccd9e4;
  --text:        #1a2535;
  --text-mid:    #475569;
  --text-light:  #6b7d90;
  --bg:          #ffffff;
  --bg-soft:     #f5f7fa;
  --bg-warm:     #faf9f7;
  --border:      #dde5ee;
  --radius:      3px;
  --shadow-sm:   0 1px 4px rgba(29,53,87,0.07);
  --shadow-md:   0 4px 20px rgba(29,53,87,0.10);
  --max-w:       1080px;
  --content-w:   740px;
  --nav-h:       72px;
  --ease:        200ms ease;
}

/* === Reset === */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 1.0625rem;
  line-height: 1.75;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
ul, ol { list-style: none; }

/* === Typography === */

h1, h2, h3 {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--navy);
  letter-spacing: -0.015em;
}

h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.55rem, 3.5vw, 2.25rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.375rem); }

p {
  color: var(--text-mid);
  margin-bottom: 1.25rem;
}
p:last-child { margin-bottom: 0; }

a {
  color: var(--navy-mid);
  text-decoration: underline;
  text-decoration-color: var(--slate-pale);
  text-underline-offset: 3px;
  transition: color var(--ease), text-decoration-color var(--ease);
}
a:hover {
  color: var(--navy);
  text-decoration-color: var(--navy);
}

strong { font-weight: 600; color: var(--text); }

/* === Layout Utilities === */

.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.75rem;
}

.content-narrow {
  max-width: var(--content-w);
  margin: 0 auto;
}

section { padding: 5.5rem 0; }


/* ===================================================
   NAVIGATION
   =================================================== */

.nav {
  position: sticky;
  top: 0;
  z-index: 200;
  height: var(--nav-h);
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.75rem;
}

.nav-brand {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--navy);
  text-decoration: none;
  letter-spacing: -0.01em;
  flex-shrink: 0;
}
.nav-brand:hover { color: var(--navy-mid); text-decoration: none; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 2.25rem;
}

.nav-links a {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-mid);
  text-decoration: none;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  transition: color var(--ease);
  position: relative;
  padding-bottom: 2px;
}
.nav-links a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0; right: 0;
  height: 2px;
  background: var(--navy);
  border-radius: 1px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--ease);
}
.nav-links a:hover,
.nav-links a.active { color: var(--navy); }
.nav-links a:hover::after,
.nav-links a.active::after { transform: scaleX(1); }

/* Hamburger button */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: transform var(--ease), opacity var(--ease);
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.nav-mobile {
  display: none;
  position: fixed;
  top: var(--nav-h);
  left: 0; right: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  z-index: 199;
  box-shadow: var(--shadow-md);
}
.nav-mobile.open { display: block; }

.nav-mobile a {
  display: block;
  padding: 1rem 1.75rem;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid var(--border);
  transition: background var(--ease), color var(--ease);
}
.nav-mobile a:last-child { border-bottom: none; }
.nav-mobile a:hover { background: var(--bg-soft); color: var(--navy); }
.nav-mobile a.active { color: var(--navy); font-weight: 600; }


/* ===================================================
   HERO — HOME PAGE
   =================================================== */

.hero {
  background: var(--bg-warm);
  padding: 7rem 0 6rem;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

/* subtle decorative line */
.hero::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, var(--navy) 0%, transparent 100%);
}

.hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 1.5rem;
}

.hero h1 { margin-bottom: 0.5rem; }

.hero-subtitle {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(1.2rem, 3vw, 1.65rem);
  font-weight: 400;
  font-style: italic;
  color: var(--slate);
  margin-bottom: 1.75rem;
}

.hero-subheadline {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(1.2rem, 2.5vw, 1.6rem);
  font-weight: 700;
  color: var(--navy);
  line-height: 1.3;
  margin-bottom: 1.25rem;
}

.hero-intro {
  font-size: 1.0625rem;
  color: var(--text-mid);
  max-width: 640px;
  margin-bottom: 2.5rem;
  line-height: 1.8;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--navy);
  color: #fff;
  text-decoration: none;
  padding: 0.875rem 2.125rem;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.9375rem;
  letter-spacing: 0.02em;
  transition: background var(--ease), transform var(--ease), box-shadow var(--ease);
  box-shadow: 0 2px 8px rgba(29,53,87,0.2);
}
.btn-primary:hover {
  background: var(--navy-deep);
  color: #fff;
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(29,53,87,0.25);
}
.btn-primary svg { flex-shrink: 0; }


/* ===================================================
   SECTION LABEL / EYEBROW
   =================================================== */

.section-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 0.75rem;
}


/* ===================================================
   SERVICES SECTION
   =================================================== */

.services { background: var(--bg); }

.services-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: end;
  margin-bottom: 3.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border);
}

.services-header h2 { margin: 0; }

.services-intro {
  font-size: 1rem;
  margin: 0;
  color: var(--text-mid);
}

.service-list { display: flex; flex-direction: column; }

.service-item {
  padding: 2.75rem 0;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 3rem;
  align-items: start;
}
.service-item:last-child { border-bottom: 1px solid var(--border); }

.service-item h3 { margin: 0; }
.service-item p { margin: 0; font-size: 1rem; }


/* ===================================================
   WHO IS THIS FOR
   =================================================== */

.for-whom { background: var(--bg-soft); }

.for-whom-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5rem;
  align-items: start;
}

.for-whom-text h2 { margin-bottom: 1rem; }
.for-whom-text p { margin: 0; }

.for-whom-list { padding-top: 0.5rem; }
.for-whom-list li {
  padding: 0.85rem 0 0.85rem 1.5rem;
  position: relative;
  color: var(--text-mid);
  border-bottom: 1px solid var(--border);
  font-size: 1rem;
  line-height: 1.5;
}
.for-whom-list li:first-child { border-top: 1px solid var(--border); }
.for-whom-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--slate-light);
  font-size: 0.9em;
}

.free-call-note {
  margin-top: 2.5rem;
  padding: 1.5rem 2rem;
  background: var(--bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
}
.free-call-note p {
  margin: 0;
  font-size: 0.9625rem;
  color: var(--text-mid);
}
.free-call-note strong { color: var(--navy); }


/* ===================================================
   CTA BLOCK (NAVY)
   =================================================== */

.cta-block {
  background: var(--navy);
  padding: 5.5rem 0;
  text-align: center;
}

.cta-block h2 {
  color: #fff;
  margin-bottom: 1rem;
}

.cta-block .cta-sub {
  color: rgba(255,255,255,0.75);
  font-size: 1.0625rem;
  max-width: 520px;
  margin: 0 auto 2.5rem;
}

.cta-contact {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.cta-contact a {
  color: #fff;
  font-weight: 600;
  font-size: 1.1rem;
  text-decoration: none;
  transition: opacity var(--ease);
}
.cta-contact a:hover { opacity: 0.8; text-decoration: none; }

.cta-divider {
  color: rgba(255,255,255,0.3);
  font-size: 1rem;
  user-select: none;
}

/* ── Inline contact form ── */
.cta-form-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 2.25rem auto 1.75rem;
  max-width: 480px;
  color: rgba(255,255,255,0.35);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.cta-form-divider::before,
.cta-form-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: rgba(255,255,255,0.15);
}

.cta-form {
  max-width: 480px;
  margin: 0 auto;
  text-align: left;
}

.cta-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.625rem;
  margin-bottom: 0.625rem;
}

.cta-form input[type="text"],
.cta-form input[type="email"],
.cta-form textarea {
  width: 100%;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  color: #fff;
  font-family: 'Inter', sans-serif;
  font-size: 0.9375rem;
  line-height: 1.5;
  outline: none;
  transition: border-color var(--ease), background var(--ease);
  -webkit-appearance: none;
}
.cta-form input::placeholder,
.cta-form textarea::placeholder {
  color: rgba(255,255,255,0.38);
}
.cta-form input:focus,
.cta-form textarea:focus {
  border-color: rgba(255,255,255,0.45);
  background: rgba(255,255,255,0.15);
}

.cta-form textarea {
  display: block;
  min-height: 96px;
  resize: vertical;
  margin-bottom: 0.625rem;
}

.cta-form-submit {
  width: 100%;
  background: #fff;
  color: var(--navy);
  border: none;
  border-radius: var(--radius);
  padding: 0.875rem 2rem;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: opacity var(--ease), transform var(--ease);
  letter-spacing: 0.01em;
}
.cta-form-submit:hover {
  opacity: 0.92;
  transform: translateY(-1px);
}

.cta-form-success {
  text-align: center;
  color: rgba(255,255,255,0.9);
  font-family: 'Playfair Display', Georgia, serif;
  font-style: italic;
  font-size: 1.15rem;
  padding: 1.5rem 0 0.5rem;
  margin: 0;
}

@media (max-width: 480px) {
  .cta-form-row {
    grid-template-columns: 1fr;
  }
}


/* ===================================================
   PAGE HEADER (inner pages)
   =================================================== */

.page-header {
  background: var(--bg-warm);
  padding: 5.5rem 0 4.5rem;
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.page-header::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, var(--navy) 0%, transparent 100%);
}

.page-header h1 { margin-bottom: 1rem; }

.page-header .subhead {
  font-size: clamp(1.05rem, 2.5vw, 1.3rem);
  color: var(--text-mid);
  font-weight: 400;
  max-width: 620px;
  line-height: 1.6;
  margin: 0;
}


/* ===================================================
   ABOUT PAGE
   =================================================== */

.about-body { padding: 5.5rem 0; }

/* Photo + intro two-column layout */
.about-intro {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 4.5rem;
  align-items: start;
  margin-bottom: 2rem;
}

.about-photo {
  position: sticky;
  top: calc(var(--nav-h) + 2rem);
}

.about-photo img {
  width: 100%;
  height: auto;
  border-radius: 3px;
  display: block;
  box-shadow: var(--shadow-md);
}

.about-photo-caption {
  margin-top: 0.75rem;
  font-size: 0.8rem;
  color: var(--text-light);
  text-align: center;
  font-style: italic;
}

.about-body p { margin-bottom: 1.5rem; line-height: 1.85; }
.about-body p:last-child { margin-bottom: 0; }

.about-lead {
  font-size: 1.125rem;
  color: var(--text);
  font-style: italic;
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 400;
  line-height: 1.7;
  margin-bottom: 2rem;
}

.credentials-block {
  background: var(--bg-soft);
  border-left: 3px solid var(--navy);
  padding: 2rem 2.5rem;
  margin: 2.75rem 0;
  border-radius: 0 var(--radius) var(--radius) 0;
}

.credentials-block h3 {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--slate);
  margin-bottom: 1rem;
}

.credentials-block li {
  padding: 0.35rem 0 0.35rem 1.25rem;
  position: relative;
  color: var(--text-mid);
  font-size: 0.975rem;
}
.credentials-block li::before {
  content: '·';
  position: absolute;
  left: 0;
  color: var(--navy);
  font-size: 1.3em;
  line-height: 1.2;
}


/* ===================================================
   AI & LEARNING PAGE
   =================================================== */

.ai-body { padding: 5.5rem 0; }
.ai-body p { margin-bottom: 1.5rem; line-height: 1.85; }

.research-callout {
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-left: 4px solid var(--slate);
  padding: 2.25rem 2.5rem;
  margin: 3rem 0;
  border-radius: 0 var(--radius) var(--radius) 0;
}

.research-callout .stat {
  display: block;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 2.75rem;
  font-weight: 700;
  color: var(--navy);
  line-height: 1;
  margin-bottom: 0.75rem;
}

.research-callout p {
  margin: 0;
  font-size: 0.975rem;
  font-style: italic;
  color: var(--text-mid);
}

.ai-distinction {
  background: var(--navy);
  color: rgba(255,255,255,0.9);
  padding: 2.5rem 3rem;
  margin: 3rem 0;
  border-radius: var(--radius);
}

.ai-distinction p {
  color: rgba(255,255,255,0.85);
  font-size: 1rem;
  margin-bottom: 1.25rem;
}
.ai-distinction p:last-child { margin-bottom: 0; }

.ai-distinction h3 {
  color: #fff;
  margin-bottom: 1rem;
  font-size: 1.125rem;
}


/* ===================================================
   FAQ PAGE
   =================================================== */

.faq-body { padding: 5.5rem 0; }

.faq-list {
  max-width: 760px;
  margin: 0 auto;
}

.faq-item { border-top: 1px solid var(--border); }
.faq-item:last-child { border-bottom: 1px solid var(--border); }

.faq-question {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  padding: 1.625rem 0;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--navy);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem;
  transition: color var(--ease);
  line-height: 1.3;
}
.faq-question:hover { color: var(--navy-mid); }

.faq-icon {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 1.5px solid var(--slate-pale);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--slate);
  font-size: 1.125rem;
  line-height: 1;
  transition: transform var(--ease), background var(--ease), border-color var(--ease), color var(--ease);
  margin-top: 2px;
}

.faq-item.open .faq-icon {
  transform: rotate(45deg);
  background: var(--navy);
  border-color: var(--navy);
  color: #fff;
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 300ms ease, padding 300ms ease;
}
.faq-answer.open {
  max-height: 600px;
  padding-bottom: 1.75rem;
}
.faq-answer p {
  margin: 0;
  font-size: 1rem;
  line-height: 1.8;
}


/* ===================================================
   FOOTER
   =================================================== */

.footer {
  background: var(--navy-deep);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 3rem;
  margin-bottom: 3rem;
  align-items: start;
}

.footer-brand-name {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.375rem;
}

.footer-tagline {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.45);
  margin-bottom: 1.25rem;
}

.footer-contact-links {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.footer-contact-links a {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.65);
  text-decoration: none;
  transition: color var(--ease);
}
.footer-contact-links a:hover { color: #fff; }

.footer-nav {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.6rem;
}
.footer-nav a {
  font-size: 0.825rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.5);
  text-decoration: none;
  transition: color var(--ease);
}
.footer-nav a:hover { color: rgba(255,255,255,0.9); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1.5rem;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.3);
}


/* ===================================================
   RESPONSIVE — TABLET & MOBILE
   =================================================== */

@media (max-width: 900px) {
  .service-item {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .services-header {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
}

@media (max-width: 768px) {
  :root { --nav-h: 64px; }

  section { padding: 3.75rem 0; }
  .hero { padding: 4rem 0 3.5rem; }
  .page-header { padding: 3.5rem 0 3rem; }
  .cta-block { padding: 4rem 0; }
  .faq-body,
  .about-body,
  .ai-body { padding: 3.75rem 0; }

  /* Nav */
  .nav-links { display: none; }
  .nav-toggle { display: flex; }

  /* About photo */
  .about-intro {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .about-photo {
    position: static;
    max-width: 280px;
  }

  /* For whom */
  .for-whom-inner {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .footer-nav {
    align-items: flex-start;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.5rem 1.25rem;
  }

  /* Credentials */
  .credentials-block { padding: 1.5rem 1.75rem; }

  /* Research callout */
  .research-callout { padding: 1.75rem; }

  /* AI distinction */
  .ai-distinction { padding: 2rem; }
}

@media (min-width: 769px) {
  .nav-mobile { display: none !important; }
}
