/* ============================================================
   DermaSci — style.css
   Exact recreation from screenshots + video
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;1,300;1,400;1,500&family=DM+Sans:wght@300;400;500&display=swap');

/* ── Reset ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; scroll-behavior: smooth; }

/* ── Design tokens ──────────────────────────────────────────── */
:root {
  --bg:           #111214;      /* main dark background */
  --bg-mid:       #161719;      /* slightly lighter panels */
  --bg-card:      #1a1c1e;      /* essay cards */
  --ivory:        #edeae4;      /* light section bg */
  --ivory-mid:    #e5e1db;      /* input bg, borders */

  --teal:         #3d7e90;      /* primary teal — "Derma" in logo */
  --teal-btn:     #2f6c7d;      /* darker teal for buttons */
  --teal-hover:   #265c6b;
  --gold:         #c49a6c;      /* "Sci" in logo, accent text */
  --gold-link:    #c49a6c;

  --text-white:   #ffffff;
  --text-primary: #e8e4de;      /* main body text on dark */
  --text-muted:   #7a7a85;      /* secondary text on dark */
  --text-dim:     #4a4a55;      /* very dim, step numbers */
  --text-dark:    #1a1a1e;      /* text on light bg */
  --text-dark-mid:#4a4855;      /* secondary text on light */
  --text-dark-dim:#9a9599;      /* dimmed on light bg, step nums */

  --border-dark:  rgba(255,255,255,0.08);
  --border-light: #d5d0c9;

  --serif:  'Cormorant Garamond', Georgia, serif;
  --sans:   'DM Sans', system-ui, -apple-system, sans-serif;

  --max-w:  1280px;
  --pad-x:  80px;
  --nav-h:  64px;
}

/* ── Base ───────────────────────────────────────────────────── */
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img, video { display: block; max-width: 100%; }
button { font-family: var(--sans); cursor: pointer; }

/* ── Top accent stripe ──────────────────────────────────────── */
.top-stripe {
  height: 3px;
  background: linear-gradient(90deg, #3d7e90 0%, #c49a6c 50%, #7b5ea7 100%);
  position: relative;
  z-index: 200;
}

/* ── Nav ────────────────────────────────────────────────────── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: var(--bg);
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--border-dark);
}

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

/* Logo: image-based, sized correctly */
.nav-logo img {
  height: 28px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 40px;
  list-style: none;
}

.nav-links a {
  font-size: 0.88rem;
  font-weight: 400;
  color: rgba(255,255,255,0.65);
  transition: color 0.18s;
  letter-spacing: 0.01em;
}

.nav-links a:hover { color: #fff; }

.nav-btn-waitlist {
  display: inline-block;
  padding: 8px 20px;
  border: 1.5px solid var(--gold);
  color: var(--gold) !important;
  font-size: 0.85rem;
  font-weight: 400;
  border-radius: 2px;
  transition: background 0.18s, color 0.18s;
  background: transparent;
}
.nav-btn-waitlist:hover {
  background: var(--gold);
  color: var(--bg) !important;
}

/* Mobile burger */
.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  padding: 4px;
  cursor: pointer;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: rgba(255,255,255,0.7);
  transition: all 0.2s;
}

/* ── HERO — video background ────────────────────────────────── */
.hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero-video-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-video-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* Dark gradient overlay — heavier on left for text legibility */
.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(13, 14, 16, 0.78) 0%,
    rgba(13, 14, 16, 0.65) 45%,
    rgba(13, 14, 16, 0.20) 100%
  );
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 100px var(--pad-x) 96px;
  width: 100%;
}

.hero-eyebrow {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 24px;
}

.hero-headline {
  font-family: var(--serif);
  font-size: clamp(3rem, 6vw, 5.5rem);
  font-weight: 400;
  line-height: 1.08;
  color: #fff;
  margin-bottom: 24px;
  max-width: 700px;
}

.hero-headline em {
  font-style: italic;
  font-weight: 300;
}

.hero-body {
  font-size: 0.96rem;
  line-height: 1.7;
  color: rgba(255,255,255,0.72);
  max-width: 460px;
  margin-bottom: 36px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-block;
  padding: 14px 28px;
  background: var(--teal-btn);
  color: #fff;
  font-size: 0.88rem;
  font-weight: 500;
  border: none;
  border-radius: 3px;
  transition: background 0.18s;
  letter-spacing: 0.01em;
}
.btn-primary:hover { background: var(--teal-hover); }

.btn-ghost {
  display: inline-block;
  padding: 13px 28px;
  background: transparent;
  color: rgba(255,255,255,0.85);
  font-size: 0.88rem;
  font-weight: 400;
  border: 1.5px solid rgba(255,255,255,0.4);
  border-radius: 3px;
  transition: border-color 0.18s, color 0.18s;
}
.btn-ghost:hover {
  border-color: rgba(255,255,255,0.75);
  color: #fff;
}

/* ── MANIFESTO — dark section with quote ────────────────────── */
.manifesto {
  background: var(--bg);
  padding: 120px var(--pad-x);
}

.manifesto-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 260px;
  align-items: center;
  gap: 80px;
}

.manifesto-quote {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 300;
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  line-height: 1.35;
  color: rgba(255,255,255,0.9);
  letter-spacing: -0.005em;
}

.manifesto-aside {
  border-left: 1px solid rgba(255,255,255,0.18);
  padding-left: 28px;
}

.manifesto-aside p {
  font-family: var(--sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.35);
  line-height: 1.6;
}

/* ── HOW IT WORKS — ivory section ───────────────────────────── */
.how-it-works {
  background: var(--ivory);
  padding: 96px var(--pad-x);
}

.how-inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

.section-label {
  display: block;
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 18px;
}

.how-it-works h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  color: var(--text-dark);
  line-height: 1.15;
  margin-bottom: 64px;
  max-width: 600px;
}

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

.step {
  padding-top: 28px;
  padding-right: 56px;
  border-top: 1px solid var(--border-light);
}
.step:last-child { padding-right: 0; }

.step-num {
  font-family: var(--serif);
  font-size: 2.8rem;
  font-weight: 300;
  color: var(--text-dark-dim);
  line-height: 1;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.step h3 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.3rem;
  color: var(--text-dark);
  margin-bottom: 12px;
  line-height: 1.25;
}

.step p {
  font-size: 0.88rem;
  line-height: 1.75;
  color: var(--text-dark-mid);
}

/* ── FOR PATIENTS / FOR CLINICS — 50/50 split ───────────────── */
.split-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 520px;
}

.split-panel {
  padding: 80px 64px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.split-panel.panel-light { background: var(--ivory); }
.split-panel.panel-dark  { background: #111416; }

.panel-num {
  font-family: var(--serif);
  font-size: 2.4rem;
  font-weight: 300;
  line-height: 1;
  margin-bottom: 14px;
  color: var(--text-dark-dim);
}
.panel-dark .panel-num { color: rgba(255,255,255,0.1); }

.panel-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.2rem, 3.5vw, 3rem);
  line-height: 1.1;
  margin-bottom: 18px;
  color: var(--text-dark);
}
.panel-dark .panel-title { color: rgba(255,255,255,0.9); }

.panel-body {
  font-size: 0.9rem;
  line-height: 1.75;
  color: var(--text-dark-mid);
  margin-bottom: 20px;
  max-width: 380px;
}
.panel-dark .panel-body { color: rgba(255,255,255,0.55); }

.panel-survey-link {
  display: block;
  font-size: 0.88rem;
  color: var(--gold-link);
  margin-bottom: 28px;
  line-height: 1.5;
  transition: opacity 0.15s;
}
.panel-survey-link:hover { opacity: 0.8; }

/* Ghost btn on light bg */
.btn-outline-dark {
  display: inline-block;
  padding: 13px 26px;
  border: 1.5px solid var(--text-dark);
  color: var(--text-dark);
  font-size: 0.85rem;
  font-weight: 400;
  border-radius: 3px;
  width: fit-content;
  transition: background 0.18s, color 0.18s;
}
.btn-outline-dark:hover {
  background: var(--text-dark);
  color: #fff;
}

/* Gold outline btn on dark bg */
.btn-outline-gold {
  display: inline-block;
  padding: 13px 26px;
  border: 1.5px solid var(--gold);
  color: var(--gold);
  font-size: 0.85rem;
  font-weight: 400;
  border-radius: 3px;
  width: fit-content;
  transition: background 0.18s, color 0.18s;
}
.btn-outline-gold:hover {
  background: var(--gold);
  color: var(--bg);
}

/* ── PROBLEM + STATS — teal section ─────────────────────────── */
.problem-section {
  background: var(--teal-btn);
  padding: 96px var(--pad-x);
}

.problem-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}

.problem-text h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  color: #fff;
  line-height: 1.2;
  margin-bottom: 20px;
}

.problem-text p {
  font-size: 0.9rem;
  line-height: 1.75;
  color: rgba(255,255,255,0.68);
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.stat-cell {
  padding: 28px 32px;
  border-top: 1px solid rgba(255,255,255,0.18);
  border-left: 1px solid rgba(255,255,255,0.18);
}
.stat-cell:nth-child(1),
.stat-cell:nth-child(2) { border-top: none; }
.stat-cell:nth-child(1),
.stat-cell:nth-child(3) { border-left: none; }

.stat-num {
  font-family: var(--serif);
  font-weight: 300;
  font-size: 3rem;
  color: var(--gold);
  line-height: 1;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.stat-label {
  font-size: 0.8rem;
  line-height: 1.5;
  color: rgba(255,255,255,0.5);
}

/* ── WAITLIST — ivory section ───────────────────────────────── */
.waitlist-section {
  background: var(--ivory);
  padding: 100px var(--pad-x);
  text-align: center;
}

.waitlist-section h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  color: var(--text-dark);
  line-height: 1.15;
  margin-bottom: 44px;
}

.waitlist-form-wrap {
  position: relative;
  max-width: 600px;
  margin: 0 auto 16px;
}

.waitlist-form {
  display: flex;
  gap: 0;
}

.waitlist-form input[type="email"] {
  flex: 1;
  padding: 15px 20px;
  border: 1px solid var(--border-light);
  background: #fff;
  font-family: var(--sans);
  font-size: 0.9rem;
  color: var(--text-dark);
  outline: none;
  border-radius: 3px 0 0 3px;
  transition: border-color 0.18s;
}
.waitlist-form input[type="email"]::placeholder { color: #b0aca6; }
.waitlist-form input[type="email"]:focus { border-color: var(--teal); }

.waitlist-form button {
  padding: 15px 28px;
  background: var(--teal-btn);
  border: none;
  color: #fff;
  font-family: var(--sans);
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: 0 3px 3px 0;
  transition: background 0.18s;
  white-space: nowrap;
}
.waitlist-form button:hover { background: var(--teal-hover); }

.waitlist-note {
  font-size: 0.82rem;
  color: var(--gold);
  font-weight: 500;
  margin-top: 14px;
}

/* Honeypot — visually hidden */
.ohnohoney {
  position: absolute;
  left: -9999px;
  opacity: 0;
  height: 0;
  overflow: hidden;
  pointer-events: none;
}

/* ── GET IN TOUCH — ivory / contact ──────────────────────────── */
.contact-section {
  background: var(--ivory);
  padding: 0 var(--pad-x) 96px;
}

.contact-inner {
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
}

.contact-inner h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2rem, 3.5vw, 2.8rem);
  color: var(--text-dark);
  margin-bottom: 8px;
}

.contact-sub {
  font-size: 0.9rem;
  color: var(--text-dark-mid);
  margin-bottom: 40px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 0;
  text-align: left;
}

.form-field {
  display: flex;
  flex-direction: column;
  margin-bottom: 0;
}

.form-field label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-dark-mid);
  padding: 12px 0 6px;
  letter-spacing: 0.02em;
}

.form-field input,
.form-field textarea {
  padding: 13px 16px;
  border: 1px solid var(--border-light);
  background: #fff;
  font-family: var(--sans);
  font-size: 0.9rem;
  color: var(--text-dark);
  border-radius: 3px;
  outline: none;
  transition: border-color 0.18s;
  width: 100%;
}
.form-field input::placeholder,
.form-field textarea::placeholder { color: #b8b4ae; }
.form-field input:focus,
.form-field textarea:focus { border-color: var(--teal); }

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

.btn-send {
  margin-top: 16px;
  width: 100%;
  padding: 15px;
  background: var(--teal-btn);
  border: none;
  color: #fff;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 3px;
  cursor: pointer;
  transition: background 0.18s;
  letter-spacing: 0.01em;
}
.btn-send:hover { background: var(--teal-hover); }

/* Form status message */
.form-msg {
  padding: 12px 16px;
  border-radius: 3px;
  font-size: 0.88rem;
  margin-bottom: 12px;
  display: none;
  text-align: center;
}
.form-msg.success { background: #d1fae5; color: #065f46; display: block; }
.form-msg.error   { background: #fee2e2; color: #991b1b; display: block; }

/* ── RESEARCH ESSAYS — dark section ─────────────────────────── */
.essays-section {
  background: var(--bg);
  padding: 100px var(--pad-x);
}

.essays-header {
  max-width: var(--max-w);
  margin: 0 auto 72px;
  text-align: center;
}

.essays-header .section-label {
  color: var(--gold);
  margin-bottom: 16px;
}

.essays-header h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(2.8rem, 5vw, 4.5rem);
  color: rgba(255,255,255,0.92);
  line-height: 1.1;
  margin-bottom: 20px;
}

.essays-header p {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 540px;
  margin: 0 auto;
}

.essays-list {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* Each essay card: image on top, text below, inside a border box */
.essay-card {
  border: 1px solid rgba(255,255,255,0.07);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 24px;
  background: var(--bg-card);
  transition: border-color 0.2s;
}
.essay-card:hover { border-color: rgba(255,255,255,0.15); }
.essay-card:last-child { margin-bottom: 0; }

.essay-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  object-position: center;
  display: block;
  filter: brightness(0.88);
  transition: filter 0.3s;
}
.essay-card:hover .essay-img { filter: brightness(0.95); }

.essay-body {
  padding: 32px 36px 40px;
}

.essay-title {
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1.7rem;
  color: rgba(255,255,255,0.9);
  line-height: 1.25;
  margin-bottom: 10px;
}

.essay-subtitle {
  font-family: var(--serif);
  font-style: italic;
  font-size: 0.98rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 16px;
}

.essay-excerpt {
  font-size: 0.88rem;
  line-height: 1.75;
  color: rgba(255,255,255,0.5);
  margin-bottom: 24px;
  max-width: 900px;
}

.essay-read-link {
  font-family: var(--sans);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.18s, opacity 0.18s;
}
.essay-read-link:hover { gap: 10px; opacity: 0.85; }

/* ── FOOTER ─────────────────────────────────────────────────── */
.site-footer {
  background: var(--bg);
  border-top: 1px solid var(--border-dark);
}

.footer-upper {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 52px var(--pad-x) 44px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 40px;
}

.footer-brand img {
  height: 26px;
  width: auto;
  margin-bottom: 10px;
}

.footer-tagline {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.01em;
}

.footer-nav {
  display: flex;
  gap: 32px;
  list-style: none;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.footer-nav a {
  font-size: 0.85rem;
  color: rgba(255,255,255,0.5);
  transition: color 0.18s;
}
.footer-nav a:hover { color: rgba(255,255,255,0.85); }

.footer-lower {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--pad-x) 36px;
  border-top: 1px solid var(--border-dark);
  padding-top: 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-social {
  display: flex;
  gap: 20px;
  align-items: center;
}

.footer-social a {
  color: rgba(255,255,255,0.35);
  transition: color 0.18s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.footer-social a:hover { color: rgba(255,255,255,0.75); }

.footer-copy {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.22);
}

.footer-launch {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.22);
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 1024px) {
  :root { --pad-x: 48px; }
}

@media (max-width: 860px) {
  :root { --pad-x: 32px; }

  .manifesto-inner        { grid-template-columns: 1fr; gap: 32px; }
  .manifesto-aside        { display: none; }
  .steps                  { grid-template-columns: 1fr; gap: 32px; }
  .step                   { padding-right: 0; }
  .split-section          { grid-template-columns: 1fr; }
  .problem-inner          { grid-template-columns: 1fr; gap: 48px; }
  .footer-upper           { flex-direction: column; gap: 24px; }
  .footer-nav             { justify-content: flex-start; }
  .footer-lower           { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 640px) {
  :root { --pad-x: 20px; }

  .nav-links              { display: none; }
  .nav-links.open         {
    display: flex;
    flex-direction: column;
    position: fixed;
    inset: calc(var(--nav-h) + 3px) 0 0;
    background: var(--bg);
    padding: 32px 20px;
    gap: 20px;
    z-index: 99;
    border-top: 1px solid var(--border-dark);
  }
  .nav-links.open a       { font-size: 1rem; color: rgba(255,255,255,0.8); }
  .nav-burger             { display: flex; }

  .hero                   { min-height: 500px; }
  .hero-content           { padding: 72px 20px 72px; }

  .split-panel            { padding: 56px 20px; }

  .stats-grid             { grid-template-columns: 1fr 1fr; }
  .stat-cell              { padding: 20px; }
  .stat-num               { font-size: 2.2rem; }

  .waitlist-form          { flex-direction: column; }
  .waitlist-form input[type="email"],
  .waitlist-form button   { border-radius: 3px; width: 100%; }

  .essay-img              { height: 200px; }
  .essay-body             { padding: 20px; }
  .essay-title            { font-size: 1.3rem; }
}
