/* ════════════════════════════════════════════════════════════
   Maria Piano Studio — Shared service-page stylesheet
   Editorial redesign matching index.html (Fraunces + Inter,
   bone background, cobalt accent, squared cards, dark sections).
   Targets the existing service-page class names so no markup
   changes are required.
   ════════════════════════════════════════════════════════════ */

:root {
  /* ─── New design tokens ─── */
  --bone: #F5F2ED;
  --bone-dark: #EDE9E2;
  --black: #0A0A09;
  --black-soft: #1A1A18;
  --cobalt: #C8102E;
  --cobalt-dark: #9A0B23;
  --cobalt-light: #E23A4A;
  --mid: #6B6860;
  --rule: rgba(10, 10, 9, 0.12);
  --ff-display: 'Fraunces', Georgia, serif;
  --ff-body: 'Inter', system-ui, sans-serif;

  /* ─── Backward-compat aliases (keep inline var(--terracotta)/var(--white) refs resolving) ─── */
  --cream: #F5F2ED;
  --charcoal: #0A0A09;
  --terracotta: #C8102E;
  --warm-gray: #6B6860;
  --light-gray: #EDE9E2;
  --white: #fff;
  --sage: #C8102E;
  --font-display: 'Fraunces', Georgia, serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --transition: 0.3s ease;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--ff-body);
  background: var(--bone);
  color: var(--black);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }

/* ═══════════════════════════════
   HEADER / NAV  (bone sticky nav, cobalt CTA)
═══════════════════════════════ */
header[role="banner"] {
  position: sticky;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  /* Full-width bone bar, but content constrained + centered to match the
     homepage's max-width 1320px container (logo gets the same left inset). */
  padding-block: 0;
  padding-inline: max(clamp(20px, 5vw, 80px), calc((100% - 1320px) / 2 + clamp(20px, 5vw, 80px)));
  height: 64px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  background: var(--bone);
  border-bottom: 1px solid var(--rule);
  backdrop-filter: blur(8px);
}

header.menu-open { z-index: 10000; }

.logo {
  font-family: var(--ff-display);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  color: var(--black);
  text-decoration: none;
  flex-shrink: 0;
}

.logo span { display: block; font-weight: 700; color: var(--cobalt); }

nav ul {
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: clamp(12px, 1.6vw, 28px);
  list-style: none;
}

nav a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--black-soft);
  text-decoration: none;
  position: relative;
  white-space: nowrap;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1.5px;
  background: var(--cobalt);
  transition: width 0.3s cubic-bezier(.16, 1, .3, 1);
}

nav a:hover { color: var(--cobalt); }
nav a:hover::after { width: 100%; }

.nav-cta {
  display: inline-flex;
  align-items: center;
  padding: 10px 22px;
  background: var(--cobalt);
  color: #fff !important;
  font-family: var(--ff-body);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border-radius: 0;
  border: none;
  box-shadow: none;
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.25s, transform 0.2s;
}

.nav-cta:hover {
  background: var(--cobalt-dark);
  transform: translateY(-1px);
  box-shadow: none;
}

/* Group nav links + CTA to the right, matching the homepage nav */
header[role="banner"] nav[role="navigation"] { margin-left: auto; }

/* hamburger */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
  z-index: 10000;
  position: relative;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--black);
  transition: transform 0.3s, opacity 0.3s;
}

.menu-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ═══════════════════════════════
   HERO  (dark editorial hero)
═══════════════════════════════ */
.service-hero {
  background: var(--black);
  color: var(--bone);
  padding: clamp(60px, 9vw, 110px) clamp(20px, 5vw, 80px) clamp(56px, 8vw, 96px);
  text-align: center;
  border-bottom: 1px solid rgba(245, 242, 237, 0.1);
  overflow: hidden;
}

.service-hero .breadcrumb {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(245, 242, 237, 0.55);
  margin-bottom: 24px;
}

.service-hero .breadcrumb a {
  color: rgba(245, 242, 237, 0.55);
  text-decoration: none;
  transition: color 0.2s;
}

.service-hero .breadcrumb a:hover { color: var(--cobalt-light); }

.service-hero h1 {
  font-family: var(--ff-display);
  font-size: clamp(38px, 6vw, 84px);
  font-weight: 900;
  line-height: 0.96;
  letter-spacing: -0.03em;
  margin-bottom: 24px;
  font-optical-sizing: auto;
  max-width: 16ch;
  margin-inline: auto;
}

.service-hero h1 em { font-style: italic; color: var(--cobalt-light); }

.service-hero p {
  font-size: clamp(15px, 1.7vw, 19px);
  line-height: 1.6;
  color: rgba(245, 242, 237, 0.75);
  max-width: 60ch;
  margin: 0 auto clamp(32px, 4vw, 44px);
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--cobalt);
  color: #fff;
  padding: 18px 44px;
  border-radius: 0;
  font-family: var(--ff-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  border: none;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.25s, transform 0.2s;
}

.hero-cta:hover {
  background: var(--cobalt-dark);
  transform: translateY(-2px);
  box-shadow: none;
}

.hero-cta svg { width: 18px; height: 18px; }

/* ═══════════════════════════════
   CONTENT SECTIONS
═══════════════════════════════ */
.content-section {
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(56px, 8vw, 110px) clamp(20px, 5vw, 40px);
  border-bottom: 1px solid var(--rule);
}

.content-section h2 {
  font-family: var(--ff-display);
  font-size: clamp(30px, 4.4vw, 56px);
  font-weight: 900;
  line-height: 0.98;
  letter-spacing: -0.03em;
  margin-bottom: 28px;
  color: var(--black);
  font-optical-sizing: auto;
}

.content-section h2 em { font-style: italic; color: var(--cobalt); }

.content-section h3 {
  font-family: var(--ff-display);
  letter-spacing: -0.02em;
}

.content-section p {
  color: var(--black-soft);
  margin-bottom: 22px;
  font-size: clamp(14px, 1.5vw, 17px);
  line-height: 1.75;
}

.content-section p strong { color: var(--black); font-weight: 600; }

/* full-bleed inner-wrapped variant (children page uses inline bg --white) keeps content readable */

/* ═══════════════════════════════
   CARD GRIDS — bordered editorial look
   (age / reason / step / who)
═══════════════════════════════ */
.age-grid,
.reason-grid,
.step-grid,
.who-grid {
  display: grid;
  gap: 2px;
  background: var(--rule);
  border: 1px solid var(--rule);
  margin: clamp(28px, 4vw, 48px) 0;
}

.age-grid { grid-template-columns: repeat(3, 1fr); }
.reason-grid { grid-template-columns: repeat(2, 1fr); }
.step-grid { grid-template-columns: repeat(3, 1fr); }
.who-grid { grid-template-columns: repeat(2, 1fr); }

.age-card,
.reason-card,
.step-card,
.who-card {
  background: var(--bone);
  border-radius: 0;
  box-shadow: none;
  padding: clamp(28px, 3.2vw, 44px) clamp(24px, 2.6vw, 36px);
  transition: background 0.25s, transform 0.3s cubic-bezier(.16, 1, .3, 1), box-shadow 0.3s;
}

.age-card { text-align: center; }
.step-card { text-align: center; position: relative; }

.age-card:hover,
.reason-card:hover,
.step-card:hover,
.who-card:hover {
  background: var(--bone-dark);
  transform: translateY(-4px);
  box-shadow: 0 12px 40px rgba(10, 10, 9, 0.07);
  z-index: 1;
  position: relative;
}

.age-card h3,
.reason-card h3,
.step-card h3,
.who-card h3 {
  font-family: var(--ff-display);
  font-size: clamp(20px, 2.1vw, 26px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
  color: var(--black);
  font-optical-sizing: auto;
}

.who-card h3 { font-size: clamp(18px, 1.9vw, 23px); }

.age-card p,
.reason-card p,
.step-card p,
.who-card p {
  font-size: 14px;
  color: var(--mid);
  line-height: 1.7;
  margin-bottom: 0;
}

.age-card .age-emoji,
.reason-card .reason-icon {
  font-size: 2.2rem;
  line-height: 1;
  margin-bottom: 16px;
}

.age-card .age-duration {
  font-size: 10px;
  color: var(--cobalt);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.step-card .step-num {
  font-family: var(--ff-display);
  width: auto;
  height: auto;
  background: none;
  color: var(--cobalt);
  border-radius: 0;
  display: block;
  font-weight: 900;
  font-size: clamp(48px, 6vw, 72px);
  line-height: 0.8;
  letter-spacing: -0.04em;
  margin: 0 auto 16px;
  font-optical-sizing: auto;
}

/* ═══════════════════════════════
   FEATURES / EQUIP LISTS
═══════════════════════════════ */
.features-list,
.equip-list {
  list-style: none;
  padding: 0;
  margin: clamp(24px, 3vw, 36px) 0;
}

.features-list li {
  padding: 16px 0 16px 2rem;
  border-bottom: 1px solid var(--rule);
  font-size: clamp(14px, 1.4vw, 16px);
  color: var(--mid);
  line-height: 1.7;
  position: relative;
}

.features-list li:last-child { border-bottom: none; }

.features-list .check {
  color: var(--cobalt);
  font-weight: bold;
  font-size: 1.1rem;
  position: absolute;
  left: 0;
  top: 16px;
}

.features-list li strong { color: var(--black); font-weight: 600; }

.equip-list li {
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  padding: 16px 0;
  border-bottom: 1px solid var(--rule);
  font-size: clamp(14px, 1.4vw, 16px);
  color: var(--mid);
  line-height: 1.7;
}

.equip-list li:last-child { border-bottom: none; }

.equip-list li strong { color: var(--black); font-weight: 600; }

.equip-list .check {
  color: var(--cobalt);
  font-weight: bold;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* ═══════════════════════════════
   QUOTES (parent / student)
═══════════════════════════════ */
.parent-quote,
.student-quote {
  background: var(--bone-dark);
  padding: clamp(28px, 3.5vw, 44px);
  border-radius: 0;
  margin: clamp(28px, 4vw, 48px) 0;
  border-left: 3px solid var(--cobalt);
}

.parent-quote p,
.student-quote p {
  font-family: var(--ff-display);
  font-style: italic;
  font-size: clamp(17px, 1.9vw, 22px);
  line-height: 1.5;
  color: var(--black);
  margin-bottom: 12px;
  font-optical-sizing: auto;
}

.parent-quote cite,
.student-quote cite {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--cobalt);
  font-style: normal;
}

/* ═══════════════════════════════
   FAQ  (thin rules, +/× toggle)
═══════════════════════════════ */
.faq-section {
  background: var(--bone-dark);
  padding: clamp(56px, 8vw, 110px) clamp(20px, 5vw, 80px);
  border-bottom: 1px solid var(--rule);
}

.faq-section h2 {
  font-family: var(--ff-display);
  font-size: clamp(34px, 4.8vw, 60px);
  font-weight: 900;
  line-height: 0.95;
  letter-spacing: -0.03em;
  text-align: center;
  margin-bottom: clamp(32px, 4vw, 52px);
  color: var(--black);
  font-optical-sizing: auto;
}

.faq-section h2 em { font-style: italic; color: var(--cobalt); }

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

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

.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  padding: 22px 0;
  font-size: clamp(14px, 1.6vw, 16px);
  font-weight: 500;
  cursor: pointer;
  color: var(--black);
  line-height: 1.45;
  transition: color 0.2s;
}

.faq-question:hover { color: var(--cobalt); }

.faq-question::after {
  content: '+';
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border: 1.5px solid var(--rule);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  line-height: 1;
  color: var(--cobalt);
  transition: transform 0.3s, background 0.2s, color 0.2s, border-color 0.2s;
  margin-top: 1px;
}

.faq-item.active .faq-question::after {
  content: '+';
  transform: rotate(45deg);
  background: var(--cobalt);
  color: #fff;
  border-color: var(--cobalt);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease;
}

.faq-item.active .faq-answer { max-height: 460px; }

.faq-answer p {
  padding: 0 0 24px;
  font-size: 14px;
  color: var(--mid);
  line-height: 1.75;
}

.faq-answer p a {
  color: var(--cobalt);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ═══════════════════════════════
   CTA BANNER  (dark)
═══════════════════════════════ */
.cta-banner {
  background: var(--black);
  color: var(--bone);
  padding: clamp(70px, 9vw, 130px) clamp(20px, 5vw, 80px);
  text-align: center;
  overflow: hidden;
}

.cta-banner h2 {
  font-family: var(--ff-display);
  font-size: clamp(34px, 5vw, 72px);
  font-weight: 900;
  line-height: 0.96;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  color: var(--bone);
  font-optical-sizing: auto;
}

.cta-banner h2 em { font-style: italic; color: var(--cobalt-light); }

.cta-banner p {
  color: rgba(245, 242, 237, 0.7);
  max-width: 560px;
  margin: 0 auto clamp(28px, 4vw, 40px);
  font-size: clamp(14px, 1.6vw, 17px);
  line-height: 1.7;
}

/* the banner reuses .hero-cta for its button — keep cobalt on dark */

/* ═══════════════════════════════
   FOOTER  (dark)
═══════════════════════════════ */
.page-footer {
  background: var(--black);
  color: var(--bone);
  padding: clamp(48px, 6vw, 72px) clamp(20px, 5vw, 80px) 36px;
  text-align: center;
  border-top: 1px solid rgba(245, 242, 237, 0.1);
}

.page-footer .footer-brand {
  font-family: var(--ff-display);
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  color: var(--bone);
  font-optical-sizing: auto;
}

.page-footer p {
  font-size: 12px;
  color: rgba(245, 242, 237, 0.4);
}

.page-footer a { color: rgba(245, 242, 237, 0.6); }

.footer-links {
  margin-bottom: 20px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(245, 242, 237, 0.1);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}

.footer-links a {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: rgba(245, 242, 237, 0.6);
  text-decoration: none;
  margin: 0 0.5rem;
  padding: 0.6rem 0.5rem;
  display: inline-block;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--bone); }

/* ═══════════════════════════════
   RESPONSIVE
═══════════════════════════════ */
@media (max-width: 900px) {
  .age-grid,
  .step-grid { grid-template-columns: 1fr 1fr; }
}

/* Collapse to burger at 980px, matching the homepage nav breakpoint */
@media (max-width: 980px) {
  .nav-cta { display: none; }

  nav ul {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--bone);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 2rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
    z-index: 9999;
  }

  nav ul.active { opacity: 1; visibility: visible; }

  nav a { font-size: 14px; }

  .menu-toggle { display: flex; }
}

@media (max-width: 768px) {
  .age-grid,
  .reason-grid,
  .step-grid,
  .who-grid { grid-template-columns: 1fr; }

  .features-list li { padding-left: 1.75rem; }
}

/* ═══════════════════════════════
   STICKY BOOK-NOW  (mobile)
═══════════════════════════════ */
.sticky-book-now {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 1001;
  padding: 14px;
  background: transparent;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: none;
  justify-content: center;
  align-items: center;
}

.sticky-book-now .sticky-cta {
  background: var(--cobalt);
  color: #fff;
  padding: 15px 20px;
  border-radius: 0;
  font-family: var(--ff-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  border: none;
  transition: background 0.25s, transform 0.25s;
  width: 100%;
  max-width: 360px;
  text-decoration: none;
  text-align: center;
  box-shadow: 0 12px 32px -8px rgba(10, 10, 9, 0.5);
}

.sticky-book-now .sticky-cta:hover {
  background: var(--cobalt-dark);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px -8px rgba(10, 10, 9, 0.5);
}

@keyframes slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@media (max-width: 768px) {
  .sticky-book-now.visible {
    display: flex;
    animation: slideUp 0.4s ease-out;
  }
}

/* ═══════════════════════════════
   BOOKING MODAL
═══════════════════════════════ */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(10, 10, 9, 0.7);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.modal-overlay.active { opacity: 1; visibility: visible; }

.modal {
  background: var(--bone);
  border-radius: 0;
  border-top: 4px solid var(--cobalt);
  padding: clamp(32px, 5vw, 48px);
  width: min(100%, 440px);
  position: relative;
  box-shadow: 0 40px 90px -30px rgba(10, 10, 9, 0.6);
  transform: scale(0.94) translateY(16px);
  transition: transform 0.3s ease;
}

.modal-overlay.active .modal { transform: scale(1) translateY(0); }

.modal-header { text-align: left; margin-bottom: 24px; }

.modal-header h3 {
  font-family: var(--ff-display);
  font-size: clamp(26px, 3.5vw, 36px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--black);
  margin-bottom: 10px;
  font-optical-sizing: auto;
}

.modal-header p { color: var(--mid); font-size: 14px; }

.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border: 1px solid var(--rule);
  background: none;
  border-radius: 0;
  color: var(--black);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.modal-close:hover { background: var(--cobalt); color: #fff; border-color: var(--cobalt); }

.form-group { margin-bottom: 18px; }

.form-group label {
  display: block;
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--black-soft);
  margin-bottom: 8px;
}

.form-group input {
  width: 100%;
  padding: 14px 16px;
  background: transparent;
  border: 1.5px solid rgba(10, 10, 9, 0.2);
  border-radius: 0;
  font-size: 14px;
  font-family: var(--ff-body);
  color: var(--black);
  outline: none;
  transition: border-color 0.2s;
}

.form-group input:focus { border-color: var(--cobalt); box-shadow: none; }
.form-group input::placeholder { color: var(--mid); }

.modal-submit {
  width: 100%;
  padding: 16px;
  background: var(--cobalt);
  color: #fff;
  border: none;
  border-radius: 0;
  font-family: var(--ff-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s;
  margin-top: 6px;
}

.modal-submit:hover { background: var(--cobalt-dark); transform: none; }
.modal-submit:disabled { opacity: 0.6; background: var(--cobalt); cursor: default; transform: none; }

.form-success { text-align: center; padding: 20px 0; }

.form-success .success-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--cobalt);
  color: #fff;
  border-radius: 50%;
  font-size: 28px;
}

.form-success h4 {
  font-family: var(--ff-display);
  font-size: 28px;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--black);
  margin-bottom: 8px;
  font-optical-sizing: auto;
}

.form-success p { color: var(--mid); font-size: 14px; line-height: 1.6; }

/* ═══════════════════════════════
   REDUCED MOTION
═══════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  .age-card, .reason-card, .step-card, .who-card { transition: background 0.2s; }
  .sticky-book-now.visible { animation: none; }
}
