/*
* Underdog Design
* Responsive Styling
*
*/

@import url('https://fonts.googleapis.com/css2?family=Montserrat:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400;1,500&display=swap');

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

:root {
  --bg-top: #cfe0ec;
  --bg-bottom: #dde9f0;
  --bg-page: #e4edf3;
  --navy: #1e3a4f;
  --teal: #2e7d9e;
  --teal-light: #3d91b5;
  --white: #ffffff;
  --text-body: #2b2b2b;
  --text-muted: #3d3d3d;
  --card-bg: rgba(255,255,255,0.88);
  --card-radius: 14px;
  --btn-bg: #1e3a4f;
  --btn-hover: #2a4f6a;
  --font-display: 'Montserrat', sans-serif;
  --font-body: 'Montserrat', sans-serif;
}

html {
  font-family: var(--font-body);
  color: var(--text-body);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background: linear-gradient(180deg, var(--bg-top) 0%, var(--bg-bottom) 55%, var(--bg-page) 100%);
  background-attachment: fixed;
}

/* ---- LOGO ---- */
.logo-wrap {
  display: flex;
  justify-content: center;
  padding: 28px 20px 30px;
}

.logo-box {
  border: 1.5px solid #999;
  padding: 10px 32px;
  font-weight: 600;
  font-size: 15px;
  color: #333;
  background: #fff;
  letter-spacing: 0.02em;
}

/* ---- PROJECT NAME (replaces logo) ---- */
.site-name {
  text-align: center;
  padding: 4px 0;
}

.site-name-acronym {
  display: block;
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--navy);
  line-height: 1.2;
}

.site-name-full {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Highlight the letters that spell FITNESS */
.site-name-full .hl {
  color: var(--teal);
  font-weight: 700;
}

/* ---- PAGE CONTAINER ---- */
.page {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

.page-wide {
  max-width: 1060px;
  margin: 0 auto;
  padding: 0 32px 80px;
}

/* ---- HEADINGS ---- */
.page-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 300;
  color: var(--navy);
  text-align: center;
  line-height: 1.25;
  margin: 48px auto 36px;
  max-width: 680px;
}

/* ---- ACCORDION CARDS ---- */
.accordion {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-bottom: 20px;
}

.accordion-item {
  background: var(--card-bg);
  border-radius: var(--card-radius);
  overflow: hidden;
  box-shadow: 0 2px 12px rgba(30,58,79,0.07);
}

.accordion-trigger {
  width: 100%;
  background: none;
  border: none;
  padding: 22px 24px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  cursor: pointer;
  text-align: left;
  gap: 16px;
}

.accordion-trigger:focus-visible {
  outline: 2px solid var(--teal);
  outline-offset: -2px;
}

.accordion-title {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 500;
  color: var(--teal);
  line-height: 1.4;
}

.accordion-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1.5px solid var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
  transition: transform 0.25s ease;
  color: var(--teal);
}

.accordion-icon svg {
  width: 12px;
  height: 12px;
  transition: transform 0.25s ease;
}

.accordion-item.open .accordion-icon svg {
  transform: rotate(180deg);
}

.accordion-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.25s ease;
  padding: 0 24px;
}

.accordion-item.open .accordion-body {
  max-height: 600px;
  padding: 0 24px 22px;
}

.accordion-body p {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-body);
  margin-bottom: 10px;
}

.accordion-body p:last-child {
  margin-bottom: 0;
}

.accordion-body ul {
  margin: 0;
  padding-left: 0;
  list-style: none;
}

.accordion-body ul li {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-body);
  padding-left: 14px;
  position: relative;
  margin-bottom: 6px;
}

.accordion-body ul li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--teal);
}

.accordion-body a {
  color: var(--teal);
  font-weight: 500;
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--btn-bg);
  color: #fff;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  padding: 14px 24px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s ease, transform 0.15s ease;
  letter-spacing: 0.01em;
}

.btn:hover {
  background: var(--btn-hover);
  transform: translateY(-1px);
}

.btn svg {
  width: 16px;
  height: 16px;
}

.btn-center {
  display: flex;
  justify-content: center;
  margin: 36px 0;
}

/* ---- BACK BUTTON (bottom, centred) ---- */
.back-wrap {
  display: flex;
  justify-content: center;
  margin: 8px 0 64px;
}

/* ---- IMAGES ---- */
.illustration {
	max-width: 400px;
	margin: auto;
}

/* ---- LINKS ---- */
a { color: var(--teal); }

/* ---- RESPONSIVE ---- */
@media (max-width: 600px) {
  .page, .page-wide {
    padding: 0 16px 60px;
  }
  .page-title {
    font-size: 24px;
    margin: 32px auto 28px;
  }
}

.reveal-section {
  display: none;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.reveal-section.visible {
  display: block;
  opacity: 1;
}

/* Steps section shown directly (single-page concerns) */
.reveal-section.always-visible {
  display: block;
  opacity: 1;
}

.accordion-static .accordion-item {
  margin-bottom: 8px;
}

.accordion-static .accordion-trigger {
  cursor: default;
}

.accordion-static .accordion-icon {
  display: none;
}

.accordion-static .accordion-body {
  display: block !important;
  max-height: none !important;
  height: auto !important;
  overflow: visible !important;
  opacity: 1 !important;
  visibility: visible !important;
  padding: 12px 24px 20px !important;
}

body.page-home {
  background: linear-gradient(180deg, #c8dcea 0%, #d6e7f0 40%, #dce9f0 70%, #e0ebf2 100%);
  background-attachment: fixed;
}

.hero {
  text-align: center;
  padding: 60px 24px 48px;
  max-width: 860px;
  margin: 0 auto;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(30px, 5vw, 52px);
  color: var(--navy);
  line-height: 1.2;
  font-weight: 300;
  margin-bottom: 0;
}

.hero-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  margin-bottom: 32px;
}

.hero-top .illustration {
  order: -1;
}

@media (min-width: 769px) {
  .hero {
    max-width: 1040px;
  }
  .hero-top {
    flex-direction: row-reverse;
    justify-content: center;
    gap: 48px;
    text-align: left;
  }
  .hero-top .illustration {
    order: 0;
    flex: 0 1 380px;
  }
  .hero-top .hero-title {
    flex: 1 1 55%;
    text-align: left;
  }
}

/* Emphasised opening paragraph (larger + bold for contrast) */
.hero-body {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.55;
  color: var(--text-body);
  max-width: 820px;
  margin: 0 auto 20px;
}

/* Study description (smaller supporting text) */
.study-blurb {
  font-size: 13px;
  font-weight: 400;
  line-height: 1.65;
  color: var(--text-muted);
  max-width: 900px;
  margin: 0 auto 44px;
}

.cta-grid {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 64px;
  margin-top: 42px;
}

.cta-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: var(--navy);
  color: #fff;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  padding: 16px 22px;
  border-radius: 6px;
  text-decoration: none;
  max-width: 260px;
  text-align: left;
  line-height: 1.4;
  transition: background 0.2s ease, transform 0.15s ease;
  cursor: pointer;
  border: none;
}

.cta-btn:hover {
  background: var(--btn-hover);
  transform: translateY(-2px);
}

.cta-btn svg {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
}

.hero-illustration {
  display: flex;
  justify-content: center;
}

.hero-illustration svg {
  max-width: 340px;
  width: 100%;
}

@media (max-width: 560px) {
  .cta-grid {
    flex-direction: column;
    align-items: center;
  }
  .cta-btn { max-width: 100%; }
}

.kit-image {
  width: 100%;
  border-radius: 10px;
  margin: 18px 0;
  display: block;
}

.kit-placeholder svg {
  width: 48px;
  height: 48px;
  opacity: 0.5;
}

.order-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
}

.order-list li {
  font-size: 14px;
  line-height: 1.7;
  color: var(--text-body);
  padding-left: 0;
}

.order-list li::before { content: none; }

.concerns-illustration svg {
  max-width: 300px;
  width: 100%;
}

/* ---- PAGE HEADER (title + image) ---- */
/* Widened to match the index hero width */
.page-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  max-width: 1040px;
  margin: 0 auto 32px;
  padding: 0 24px;
}

.page-header .illustration {
  order: -1;
}

.page-header .page-title {
  margin: 0;
}

@media (min-width: 769px) {
  .page-header {
    flex-direction: row-reverse;
    justify-content: center;
    gap: 48px;
    text-align: left;
  }
  .page-header .illustration {
    order: 0;
    flex: 0 1 380px;
  }
  .page-header .page-title {
    flex: 1 1 55%;
    text-align: left;
    max-width: none;
  }
}

.steps-intro {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px;
}

.steps-intro .page-title {
  margin-top: 40px;
}

.steps-layout {
  max-width: 860px;
  margin: 0 auto;
  padding: 0 24px 80px;
}

.stepper {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin: 36px 0 56px;
}

.stepper-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  cursor: pointer;
  background: none;
  border: none;
  font-family: var(--font-body);
  padding: 0;
}

.stepper-label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--navy);
  line-height: 1.4;
  margin-bottom: 14px;
  min-height: 32px;
}

.stepper-track {
  position: relative;
  width: 100%;
  display: flex;
  align-items: center;
}

.stepper-line {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100%;
  height: 2px;
  background: #cdd9e0;
  transform: translateY(-50%);
  z-index: 0;
}

.stepper-item:last-child .stepper-line {
  display: none;
}

.stepper-item.line-active .stepper-line {
  background: var(--navy);
}

.stepper-dot {
  position: relative;
  z-index: 1;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid #cdd9e0;
  margin: 0 auto;
  transition: all 0.2s ease;
}

.stepper-item.completed .stepper-dot,
.stepper-item.active .stepper-dot {
  background: var(--navy);
  border-color: var(--navy);
}

.stepper-item.active .stepper-dot {
  width: 18px;
  height: 18px;
}

/* ---- Step panel ---- */
.step-panel {
  display: none;
}

.step-panel.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

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

.step-label {
  text-align: center;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal);
  margin-bottom: 10px;
}

.step-label::before, .step-label::after {
  content: '';
  display: inline-block;
  width: 40px;
  height: 1px;
  background: var(--teal);
  vertical-align: middle;
  margin: 0 10px;
  opacity: 0.4;
}

.step-instruction {
  font-family: var(--font-body);
  font-size: clamp(15px, 2.2vw, 18px);
  font-weight: 400;
  color: var(--teal);
  text-align: center;
  line-height: 1.5;
  margin-bottom: 24px;
  font-style: italic;
}

/* ---- Plain info box ---- */
.info-box {
  background: var(--card-bg);
  border-radius: var(--card-radius);
  box-shadow: 0 2px 12px rgba(30,58,79,0.07);
  padding: 22px 24px;
  margin-bottom: 16px;
}

.info-box-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--teal);
  line-height: 1.4;
  margin-bottom: 14px;
}

.info-box p {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-body);
  margin-bottom: 10px;
}

.info-box p:last-child { margin-bottom: 0; }

.info-box p.mt-sm {
  margin-top: 12px;
}

.info-box ul {
  margin: 0;
  padding-left: 0;
  list-style: none;
}

.info-box ul li {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-body);
  padding-left: 14px;
  position: relative;
  margin-bottom: 6px;
}

.info-box ul li::before {
  content: '•';
  position: absolute;
  left: 0;
  color: var(--teal);
}

.info-box ul li:last-child { margin-bottom: 0; }

.info-box a { color: var(--teal); font-weight: 500; }

.info-box .sub-list {
  margin-top: 6px;
  padding-left: 16px;
}

/* Step nav buttons */
.step-nav-btns {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 28px;
  gap: 12px;
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: none;
  border: 1.5px solid var(--navy);
  color: var(--navy);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.03em;
  padding: 10px 18px;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

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

.btn-ghost:disabled {
  opacity: 0.28;
  cursor: not-allowed;
}

.btn-ghost:disabled:hover {
  background: none;
  color: var(--navy);
}

.step-counter {
  font-size: 12px;
  color: #8ab0be;
  font-weight: 500;
}

@media (max-width: 640px) {
  .stepper-label {
    font-size: 9px;
    min-height: 26px;
  }
}

/* ---- DOWNLOAD BUTTON (step 2: conversation topics PDF) ---- */
.download-wrap {
  display: flex;
  justify-content: center;
  margin: 22px 0 4px;
}

.download-wrap .btn {
  text-align: left;
}

@media (max-width: 480px) {
  .download-wrap .btn {
    width: 100%;
    justify-content: center;
    padding: 14px 18px;
  }
}

/* ---- CONTROL VARIANT (#control) ----
   Hides the family/concerns pathway, and shows the screening content by default
   instead of behind the "Find out more" button.
   The class is set on <html> by the inline script in index.html. */

/* Hide both hero CTAs and the concerns button at the foot of the screening
   section. The "Find out more" CTA goes too, since its content is already open. */
html.control-mode .cta-grid,
html.control-mode .cta-btn-concerns,
html.control-mode .btn-center {
  display: none !important;
}

/* Screening section is expanded on load, with no reveal transition. */
html.control-mode .reveal-section#screening-section {
  display: block;
  opacity: 1;
  transition: none;
}
