/* ============================================================
   BAHM — Balthazard Health Monitor
   Shared stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Archivo:wght@600;700;800&family=Source+Sans+3:wght@400;500;600;700&display=swap');

:root {
  /* Core palette, drawn from the BAHM app */
  --ink:        #2A2438;   /* near-black text on light panels */
  --panel:      #362C52;   /* deep purple-navy — app chrome */
  --panel-2:    #473A66;   /* lighter purple — cards on dark */
  --gold:       #D9A727;   /* primary accent / CTA */
  --gold-dark:  #B58A1E;
  --teal:       #4A7C96;   /* secondary action */
  --maroon:     #5C2430;   /* tertiary / destructive-adjacent accent */
  --paper:      #F4F2F8;   /* page background */
  --paper-2:    #FFFFFF;   /* card background */
  --line:       #DAD5E6;   /* hairline borders on light */
  --cream:      #F5F1E8;   /* light text on dark panels */
  --muted:      #6B6480;   /* secondary text on light */

  --radius: 6px;
  --max: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Source Sans 3', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  line-height: 1.1;
  margin: 0 0 0.5em 0;
  color: var(--ink);
}

h1 { font-size: clamp(2.1rem, 4vw, 3.1rem); letter-spacing: -0.01em; }
h2 { font-size: clamp(1.5rem, 2.6vw, 2rem); letter-spacing: -0.005em; }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1em 0; max-width: 62ch; }

a { color: var(--teal); }

.container {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- Header / nav ---------- */

.site-header {
  background: var(--panel);
  border-bottom: 3px solid var(--gold);
}

.site-header .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding-top: 26px;
  padding-bottom: 22px;
}

.brand {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.brand-mark {
  width: 96px;
  height: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.brand-name {
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 1.4rem;
  color: var(--cream);
  letter-spacing: -0.005em;
}

.brand-tag {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--panel);
  background: var(--gold);
  padding: 4px 10px;
  border-radius: 999px;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 28px;
}

.main-nav a {
  color: var(--cream);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.96rem;
  opacity: 0.85;
  transition: opacity 0.15s ease;
}

.main-nav a:hover { opacity: 1; }

.main-nav a.current {
  opacity: 1;
  border-bottom: 2px solid var(--gold);
  padding-bottom: 4px;
}

/* ---------- Content logo (top-right of the page's main content) ---------- */

.content-logo {
  float: right;
  width: 90px;
  height: auto;
  margin: 0 0 20px 28px;
}

.clearfix { display: flow-root; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Source Sans 3', sans-serif;
  font-weight: 700;
  font-size: 0.96rem;
  text-decoration: none;
  padding: 12px 24px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

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

.btn-gold {
  background: var(--gold);
  color: var(--panel);
}
.btn-gold:hover { background: var(--gold-dark); }

.btn-teal {
  background: var(--teal);
  color: #fff;
}
.btn-teal:hover { background: #3E6A82; }

.btn-outline {
  background: transparent;
  color: var(--cream);
  border: 2px solid var(--cream);
  padding: 10px 22px;
}
.btn-outline:hover { background: rgba(245, 241, 232, 0.1); }

.btn-outline-dark {
  background: transparent;
  color: var(--panel);
  border: 2px solid var(--panel);
  padding: 10px 22px;
}
.btn-outline-dark:hover { background: rgba(54, 44, 82, 0.06); }

/* ---------- Hero ---------- */

.hero {
  background: var(--panel);
  color: var(--cream);
  padding: 76px 0 88px;
  position: relative;
  overflow: hidden;
}

.hero .container {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
}

.hero-eyebrow {
  color: var(--gold);
  font-weight: 700;
  font-size: 0.92rem;
  margin-bottom: 14px;
}

.hero h1 { color: var(--cream); }

.hero p.lede {
  color: #CFC9E0;
  font-size: 1.15rem;
  max-width: 46ch;
}

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

.hero-panel {
  background: var(--panel-2);
  border: 1px solid rgba(217, 167, 39, 0.35);
  border-radius: var(--radius);
  padding: 28px;
}

.hero-panel .stat-row {
  display: flex;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid rgba(245, 241, 232, 0.12);
}
.hero-panel .stat-row:last-child { border-bottom: none; }

.hero-panel .stat-label {
  color: #C7C1DA;
  font-size: 0.92rem;
}
.hero-panel .stat-value {
  color: var(--gold);
  font-weight: 700;
  font-family: 'Archivo', sans-serif;
}

/* ---------- Sections ---------- */

section { padding: 72px 0; }

.section-head {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin-bottom: 40px;
}

.bar {
  width: 5px;
  min-height: 34px;
  background: var(--gold);
  border-radius: 2px;
  flex-shrink: 0;
  margin-top: 4px;
}

.section-head p { color: var(--muted); margin-top: 6px; }

.on-dark { background: var(--panel); color: var(--cream); }
.on-dark h2, .on-dark h3 { color: var(--cream); }
.on-dark .section-head p { color: #C7C1DA; }
.on-dark .bar { background: var(--gold); }

/* ---------- Cards / grid ---------- */

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

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}

.card {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-left: 4px solid var(--gold);
  border-radius: 4px;
  padding: 26px;
}

.card h3 { margin-bottom: 10px; }
.card p { color: var(--muted); margin-bottom: 0; }

.card.on-dark-card {
  background: var(--panel-2);
  border-color: rgba(245, 241, 232, 0.1);
  border-left: 4px solid var(--gold);
}
.card.on-dark-card p { color: #C7C1DA; }

/* ---------- Step list ---------- */

.steps {
  counter-reset: step;
  display: grid;
  gap: 22px;
}

.step {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 18px;
}

.step-num {
  counter-increment: step;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--panel);
  color: var(--gold);
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-num::before { content: counter(step); }

.step h3 { margin-bottom: 4px; }
.step p { color: var(--muted); margin-bottom: 0; }

/* ---------- CTA band ---------- */

.cta-band {
  background: var(--gold);
  color: var(--panel);
  text-align: center;
  padding: 64px 0;
}
.cta-band h2 { color: var(--panel); }
.cta-band p { color: #4B3A16; margin: 0 auto 26px; }

/* ---------- Register placeholder page ---------- */

.register-block {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-top: 5px solid var(--gold);
  border-radius: 6px;
  padding: 56px 40px;
}

.register-block .status-pill {
  display: inline-block;
  background: rgba(74, 124, 150, 0.12);
  color: var(--teal);
  font-weight: 700;
  font-size: 0.82rem;
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 20px;
}

.register-block p { margin: 0 auto 30px; color: var(--muted); }

/* ---------- Contact ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
}

.info-row {
  display: flex;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.info-row:last-child { border-bottom: none; }
.info-row strong { display: block; font-family: 'Archivo', sans-serif; }
.info-row span { color: var(--muted); }

form.contact-form {
  display: grid;
  gap: 16px;
}

.contact-form label {
  display: block;
  font-weight: 600;
  font-size: 0.92rem;
  margin-bottom: 6px;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  font-family: inherit;
  font-size: 1rem;
  background: var(--paper-2);
  color: var(--ink);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid var(--teal);
  outline-offset: 1px;
}

/* ---------- Checklist ---------- */

.checklist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2px;
}

.checklist li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  font-weight: 600;
}

.checklist li::before {
  content: "";
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background: var(--gold);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none'%3E%3Cpath d='M3 8.5L6.2 11.5L13 4.5' stroke='%23362C52' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
}

/* ---------- Story figure ---------- */

figure.team-photo {
  margin: 52px auto 0;
  max-width: 900px;
}

figure.team-photo img {
  width: 100%;
  display: block;
  border-radius: 6px;
  border: 1px solid var(--line);
}

figure.team-photo figcaption {
  margin-top: 16px;
  text-align: center;
  font-family: 'Archivo', sans-serif;
  font-weight: 800;
  font-size: 1.2rem;
  color: var(--panel);
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--panel);
  color: #C7C1DA;
  padding: 44px 0 30px;
}

.footer-top {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(245, 241, 232, 0.12);
  margin-bottom: 20px;
}

.footer-nav {
  display: flex;
  justify-content: center;
  gap: 22px;
  flex-wrap: wrap;
}

.footer-nav a {
  color: #C7C1DA;
  text-decoration: none;
  font-size: 0.94rem;
}
.footer-nav a:hover { color: var(--gold); }

.footer-bottom {
  text-align: center;
  font-size: 0.85rem;
  color: #8F87A6;
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .hero .container { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }

  .main-nav { gap: 16px 22px; }
}


/* ---------- Accessibility ---------- */

a:focus-visible, button:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 2px;
}

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