/* =========================================================
   New Heights Aquatics — Shared Stylesheet
   Primary palette: blue + orange
   ========================================================= */

:root {
  --navy: #0a3d6b;
  --ocean: #1e6baa;
  --sky: #4da5d9;
  --pool: #e8f4fc;
  --orange: #f58220;
  --orange-light: #ffb547;
  --orange-deep: #d96a0d;
  --ink: #1f2d3d;
  --slate: #4a5b6e;
  --mute: #7c8a99;
  --line: #dfe7ef;
  --bg: #ffffff;
  --bg-soft: #f5f9fc;
  --radius: 14px;
  --radius-sm: 8px;
  --shadow-sm: 0 2px 8px rgba(10, 61, 107, 0.06);
  --shadow: 0 8px 28px rgba(10, 61, 107, 0.12);
  --shadow-lg: 0 18px 48px rgba(10, 61, 107, 0.18);
  --font-head: "Poppins", "Segoe UI", Tahoma, sans-serif;
  --font-body: "Inter", "Segoe UI", Tahoma, sans-serif;
}

/* ---------- Reset ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--ocean);
  text-decoration: none;
}

a:hover {
  color: var(--orange);
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--navy);
  line-height: 1.2;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.1rem, 4vw, 3.4rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.7rem, 2.8vw, 2.4rem); letter-spacing: -0.01em; }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1rem; color: var(--slate); }

.container {
  width: min(1180px, 92%);
  margin: 0 auto;
}

.section {
  padding: 80px 0;
}

.section-sm {
  padding: 48px 0;
}

.eyebrow {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--orange);
  margin-bottom: 12px;
}

.lead {
  font-size: 1.15rem;
  color: var(--slate);
  max-width: 640px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.98rem;
  border: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--orange), var(--orange-deep));
  color: #fff;
  box-shadow: 0 10px 20px rgba(245, 130, 32, 0.28);
}

.btn-primary:hover {
  transform: translateY(-2px);
  color: #fff;
  box-shadow: 0 14px 28px rgba(245, 130, 32, 0.38);
}

.btn-secondary {
  background: var(--navy);
  color: #fff;
}

.btn-secondary:hover {
  background: var(--ocean);
  color: #fff;
  transform: translateY(-2px);
}

.btn-ghost {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--navy);
}

.btn-ghost:hover {
  background: var(--navy);
  color: #fff;
}

.btn-block { width: 100%; }

/* ---------- Navbar ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,0.92);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}

.brand {
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  line-height: 1;
  text-decoration: none;
  color: var(--navy);
  padding: 2px 0;
}

.brand:hover { color: var(--navy); }

.logo-nh {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--orange);
  font-size: 2.1rem;
  letter-spacing: -0.01em;
  line-height: 0.95;
  text-shadow: 0 1px 0 rgba(245,130,32,0.08);
}

/* Footer version sits on a navy background — keep NHA orange, lightened */
.footer .brand { color: #fff; }
.footer .logo-nh { color: var(--orange-light); }

.nav-links {
  display: flex;
  gap: 28px;
  align-items: center;
  list-style: none;
  padding: 0;
  margin: 0;
}

.nav-links a {
  color: var(--ink);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 8px 2px;
  border-bottom: 2px solid transparent;
}

.nav-links a.active,
.nav-links a:hover {
  color: var(--ocean);
  border-bottom-color: var(--orange);
}

.nav-cta {
  padding: 10px 20px;
  font-size: 0.9rem;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--navy);
  font-size: 1.6rem;
}

@media (max-width: 840px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 100%;
    right: 4%;
    left: 4%;
    flex-direction: column;
    background: #fff;
    padding: 18px;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--line);
    display: none;
    gap: 14px;
  }
  .nav-links.open { display: flex; }
  .nav-links .nav-cta { align-self: stretch; text-align: center; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 96px 0 120px;
  background:
    radial-gradient(1200px 500px at 80% -10%, rgba(245,130,32,0.18), transparent 60%),
    linear-gradient(160deg, var(--pool) 0%, #ffffff 70%);
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 -1px 0;
  height: 120px;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 120' preserveAspectRatio='none'><path d='M0 60 C 240 120 480 0 720 60 C 960 120 1200 0 1440 60 L1440 120 L0 120 Z' fill='%23ffffff'/></svg>") no-repeat center / cover;
}

.hero-grid {
  display: block;
  max-width: 760px;
}

.hero h1 span {
  background: linear-gradient(90deg, var(--ocean), var(--orange));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 24px;
  flex-wrap: wrap;
}

.hero-meta {
  margin-top: 28px;
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  color: var(--slate);
  font-size: 0.95rem;
}

.hero-meta span { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta svg { width: 18px; height: 18px; color: var(--orange); }

.hero-art {
  position: relative;
  aspect-ratio: 4/5;
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(10,61,107,0.2), rgba(30,107,170,0.85)),
    radial-gradient(circle at 30% 30%, rgba(255,255,255,0.4), transparent 50%),
    linear-gradient(135deg, var(--sky), var(--ocean));
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

.hero-art::before,
.hero-art::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  opacity: 0.35;
}

.hero-art::before {
  width: 220px; height: 220px;
  background: var(--orange);
  top: -60px; right: -40px;
  filter: blur(10px);
}

.hero-art::after {
  width: 160px; height: 160px;
  background: #fff;
  bottom: 40px; left: -30px;
  filter: blur(6px);
}

.hero-art .badge {
  position: absolute;
  left: 20px;
  bottom: 20px;
  background: #fff;
  color: var(--navy);
  padding: 14px 18px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  font-family: var(--font-head);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
}

.hero-art .badge strong { color: var(--orange); font-size: 1.3rem; display:block; }
.hero-art .badge span { display:block; font-size: 0.78rem; color: var(--slate); font-weight: 500; }

@media (max-width: 840px) {
  .hero { padding: 60px 0 90px; }
  .hero-grid { grid-template-columns: 1fr; gap: 36px; }
  .hero-art { max-width: 420px; margin: 0 auto; width: 100%; aspect-ratio: 5/4; }
}

/* ---------- Section headers ---------- */
.section-head {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 56px;
}

.section-head .lead { margin: 0 auto; }

/* ---------- Program cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
}

.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--sky);
}

.card-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--pool), #fff);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ocean);
  margin-bottom: 16px;
  border: 1px solid var(--line);
}

.card-icon.accent {
  background: linear-gradient(135deg, var(--orange-light), var(--orange));
  color: #fff;
  border-color: transparent;
}

.card h3 { margin-bottom: 8px; }
.card p { font-size: 0.96rem; }

.card ul {
  list-style: none;
  padding: 0;
  margin: 10px 0 20px;
}

.card ul li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 6px 0;
  color: var(--slate);
  font-size: 0.95rem;
}

.card ul li::before {
  content: "";
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--orange);
  margin-top: 8px; flex-shrink: 0;
}

.card .price {
  margin: 4px 0 16px;
  font-family: var(--font-head);
  color: var(--navy);
  font-size: 1.4rem;
  font-weight: 700;
}
.card .price small { color: var(--mute); font-size: 0.85rem; font-weight: 500; }

.card .card-cta { margin-top: auto; }

/* ---------- Stats strip ---------- */
.stats {
  background: linear-gradient(135deg, var(--navy), var(--ocean));
  color: #fff;
  border-radius: var(--radius);
  padding: 36px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  text-align: center;
  box-shadow: var(--shadow);
}

.stats .stat { }
.stats .stat strong {
  font-family: var(--font-head);
  font-size: 2rem;
  color: var(--orange-light);
  display: block;
}

.stats .stat span {
  font-size: 0.9rem;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.02em;
}

/* ---------- Feature grid ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.feature {
  display: flex;
  gap: 14px;
  padding: 6px;
}

.feature .dot {
  width: 42px; height: 42px; flex: none;
  border-radius: 12px;
  background: var(--pool);
  color: var(--ocean);
  display: inline-flex; align-items: center; justify-content: center;
}

.feature h4 { margin: 2px 0 4px; color: var(--navy); font-family: var(--font-head); }
.feature p { margin: 0; font-size: 0.95rem; }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--navy), var(--ocean) 55%, var(--sky));
  color: #fff;
  border-radius: var(--radius);
  padding: 56px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 32px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.cta-band::after {
  content: "";
  position: absolute;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: var(--orange);
  top: -120px; right: -80px;
  opacity: 0.35;
  filter: blur(2px);
  pointer-events: none;
  z-index: 0;
}

.cta-band h2 { color: #fff; margin-bottom: 4px; position: relative; z-index: 1; }
.cta-band p { color: rgba(255,255,255,0.9); margin: 0; position: relative; z-index: 1; }
.cta-band .btn { position: relative; z-index: 2; }

@media (max-width: 720px) {
  .cta-band { flex-direction: column; text-align: center; padding: 40px 24px; }
}

/* ---------- Page header ---------- */
.page-header {
  background: linear-gradient(160deg, var(--pool) 0%, #ffffff 80%);
  padding: 70px 0 40px;
  position: relative;
  overflow: hidden;
}

.page-header .crumbs {
  font-size: 0.85rem;
  color: var(--mute);
  margin-bottom: 12px;
}

.page-header .crumbs a { color: var(--mute); }
.page-header .crumbs a:hover { color: var(--orange); }

/* ---------- Program details / tabs ---------- */
.tabs {
  display: inline-flex;
  background: var(--pool);
  padding: 6px;
  border-radius: 999px;
  gap: 4px;
  margin-bottom: 28px;
}

.tab-btn {
  border: none;
  background: transparent;
  color: var(--navy);
  padding: 10px 20px;
  border-radius: 999px;
  cursor: pointer;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.95rem;
  transition: background 0.2s ease, color 0.2s ease;
}

.tab-btn.active {
  background: #fff;
  color: var(--ocean);
  box-shadow: var(--shadow-sm);
}

.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fade .25s ease; }

@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Booking layout ---------- */
.booking {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 32px;
  align-items: start;
}

@media (max-width: 920px) {
  .booking { grid-template-columns: 1fr; }
}

.panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow-sm);
}

.panel h3 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
}

.panel h3 .step {
  font-size: 0.75rem;
  font-family: var(--font-head);
  background: var(--orange);
  color: #fff;
  padding: 4px 10px;
  border-radius: 999px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ---------- Square Appointments embed container ---------- */
.panel.square-embed {
  max-width: 960px;
  margin: 0 auto;
  padding: 24px;
  min-height: 520px;
}

.panel.square-embed iframe {
  width: 100% !important;
  border: 0;
  border-radius: calc(var(--radius) - 6px);
  display: block;
}

/* ---------- Option pills (lesson type) ---------- */
.option-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.option-pill {
  border: 2px solid var(--line);
  background: #fff;
  color: var(--ink);
  padding: 10px 16px;
  border-radius: 999px;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.option-pill:hover { border-color: var(--sky); color: var(--ocean); }

.option-pill.active {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}

/* ---------- Calendar ---------- */
.calendar {
  user-select: none;
}

.cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
}

.cal-head .month {
  font-family: var(--font-head);
  color: var(--navy);
  font-weight: 600;
  font-size: 1.1rem;
}

.cal-nav {
  display: inline-flex;
  gap: 6px;
}

.cal-nav button {
  width: 34px; height: 34px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--navy);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  transition: border-color 0.2s, color 0.2s;
}

.cal-nav button:hover { border-color: var(--orange); color: var(--orange); }
.cal-nav button:disabled { opacity: 0.4; cursor: not-allowed; }

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.cal-dow {
  text-align: center;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--mute);
  padding: 8px 0;
  font-weight: 600;
}

.cal-cell {
  aspect-ratio: 1/1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--bg-soft);
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.cal-cell:hover:not(.disabled):not(.empty) {
  background: var(--pool);
  color: var(--ocean);
}

.cal-cell.today {
  border-color: var(--orange);
  color: var(--orange);
}

.cal-cell.selected {
  background: var(--navy);
  color: #fff;
  border-color: var(--navy);
}

.cal-cell.disabled {
  color: var(--mute);
  cursor: not-allowed;
  background: transparent;
}

.cal-cell.empty {
  background: transparent;
  cursor: default;
}

/* ---------- Time slots ---------- */
.slots-label {
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--navy);
  margin: 22px 0 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.slots-label small {
  color: var(--mute);
  font-weight: 500;
  font-family: var(--font-body);
  font-size: 0.85rem;
}

.slots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(96px, 1fr));
  gap: 8px;
}

.slot {
  padding: 10px 4px;
  border-radius: 10px;
  background: #fff;
  border: 2px solid var(--line);
  color: var(--ink);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.slot:hover:not(:disabled) { border-color: var(--orange); color: var(--orange); }
.slot.selected {
  background: var(--orange);
  border-color: var(--orange);
  color: #fff;
}
.slot:disabled { opacity: 0.4; cursor: not-allowed; }

.slots-empty {
  color: var(--mute);
  font-size: 0.95rem;
  padding: 16px;
  text-align: center;
  border: 2px dashed var(--line);
  border-radius: 10px;
}

/* ---------- Form ---------- */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field.full { grid-column: 1 / -1; }

.field label {
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--navy);
  font-size: 0.9rem;
}

.field input,
.field select,
.field textarea {
  border: 1.5px solid var(--line);
  padding: 12px 14px;
  border-radius: 10px;
  font: inherit;
  color: var(--ink);
  background: #fff;
  transition: border-color 0.15s, box-shadow 0.15s;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--ocean);
  box-shadow: 0 0 0 4px rgba(77,165,217,0.2);
}

.field textarea { resize: vertical; min-height: 90px; }

.summary {
  background: var(--pool);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
  margin: 18px 0;
  border: 1px solid #d0e4f4;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
  font-size: 0.95rem;
}

.summary dt {
  color: var(--mute);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.summary dd {
  margin: 0;
  color: var(--navy);
  font-family: var(--font-head);
  font-weight: 600;
}

.pay-note {
  margin-top: 12px;
  font-size: 0.82rem;
  color: var(--mute);
  text-align: center;
}

.alert {
  padding: 14px 16px;
  border-radius: 10px;
  background: #eafaf0;
  border: 1px solid #bfe5cc;
  color: #1f6a3e;
  margin-top: 14px;
  display: none;
  font-size: 0.95rem;
}

.alert.show { display: block; animation: fade .3s ease; }

.alert.error {
  background: #fdecec;
  border-color: #f4c0c0;
  color: #b02929;
}

/* ---------- FAQ ---------- */
.faq {
  border-top: 1px solid var(--line);
}

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 18px 0;
}

.faq summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--font-head);
  font-weight: 600;
  color: var(--navy);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  color: var(--orange);
  font-size: 1.3rem;
  font-weight: 600;
}

.faq details[open] summary::after { content: "–"; }
.faq details p { margin-top: 10px; }

/* ---------- Footer ---------- */
.footer {
  background: var(--navy);
  color: rgba(255,255,255,0.85);
  padding: 60px 0 28px;
  margin-top: 40px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr repeat(3, 1fr);
  gap: 40px;
}

@media (max-width: 820px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer h4 {
  color: #fff;
  font-family: var(--font-head);
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 14px;
}

.footer a { color: rgba(255,255,255,0.78); }
.footer a:hover { color: var(--orange-light); }

.footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 0.95rem;
}

.footer .brand { color: #fff; }
.footer .brand small { color: var(--orange-light); }
.footer p { color: rgba(255,255,255,0.75); font-size: 0.95rem; }

.copyright {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 0.85rem;
  color: rgba(255,255,255,0.6);
  text-align: center;
}

/* ---------- Small helpers ---------- */
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; }
.spaced > * + * { margin-top: 1rem; }
.text-center { text-align: center; }

/* ---------- Accessibility ---------- */
:focus-visible {
  outline: 3px solid rgba(245,130,32,0.45);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}
