/* Senda landing — "papel y tinta" system, mirrored from the app's brand guide:
   one single accent (ink green) for progress/active/success, primary actions in
   ink, 1px hairline borders, elevation 0, locked radius scale (8/10/12/16),
   Literata for headlines and Plus Jakarta Sans for UI. No gradients, no
   shadows, no pills. */

@font-face {
  font-family: 'Literata';
  src: url('fonts/literata-var.woff2') format('woff2');
  font-weight: 400 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Plus Jakarta Sans';
  src: url('fonts/plus-jakarta-sans-var.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --canvas: #F9F7F3;
  --card: #FFFFFF;
  --surface: #F3F0EA;
  --border: #E9E5DD;
  --disabled-fill: #EFECE6;
  --ink: #1F1D1A;
  --ink-2: #7A756C;
  --ink-3: #B4AEA3;
  --accent: #3E6B50;
  --accent-deep: #2E523C;
  --accent-wash: #EAF1EA;
  --on-accent-wash: #346538;
  --highlight-wash: #F6F0DC;
  --on-highlight-wash: #8A6116;
  --danger: #A63D3D;
  --r-chip: 8px;
  --r-btn: 10px;
  --r-card: 12px;
  --r-sheet: 16px;
  --serif: 'Literata', Georgia, 'Times New Roman', serif;
  --sans: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ease-out-cubic: cubic-bezier(0.215, 0.61, 0.355, 1);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  background: var(--canvas);
  color: var(--ink);
  line-height: 1.6;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

/* ---------- Type ---------- */

h1, h2 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

h1 { font-size: clamp(2.5rem, 5.5vw, 3.75rem); }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.5rem); }

.kicker {
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}

/* ---------- Nav ---------- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1120px;
  width: 100%;
  margin-inline: auto;
  padding: 20px 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.25rem;
  letter-spacing: -0.01em;
}

.brand-mark { width: 30px; height: 30px; }

.nav-hub {
  color: var(--ink-2);
  text-decoration: none;
  font-size: 0.875rem;
}
.nav-hub:hover { color: var(--ink); }

/* ---------- Layout ---------- */

main {
  flex: 1;
  width: 100%;
}

.hero,
.feature,
.quiet,
.newsletter {
  width: 100%;
  max-width: 1120px;
  margin-inline: auto;
  padding-inline: 24px;
}

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

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 48px;
  padding-block: 72px 56px;
}

.hero-lead {
  margin-top: 20px;
  max-width: 52ch;
  font-size: 1.1875rem;
  color: var(--ink-2);
}

.hero-actions { margin-top: 32px; }

.hero-note {
  margin-top: 14px;
  font-size: 0.875rem;
  color: var(--ink-2);
}

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

.hero-mark {
  width: clamp(240px, 30vw, 400px);
  height: auto;
  color: var(--ink);
}

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 26px;
  border: none;
  border-radius: var(--r-btn);
  background: var(--ink);
  color: var(--canvas);
  font-family: var(--sans);
  font-size: 0.9375rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 150ms ease-out, opacity 150ms ease-out;
}
.btn:hover { opacity: 0.92; }
.btn:active { transform: scale(0.98); opacity: 0.92; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- Trail divider ---------- */

.trail-divider {
  width: 0;
  height: 56px;
  margin-inline: auto;
  border: none;
  border-left: 2px dotted var(--ink-3);
}

/* ---------- Feature sections ---------- */

.feature {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: 64px;
  padding-block: 88px;
}

.feature-flip .feature-copy { order: 2; }
.feature-flip .feature-media { order: 1; }

/* Band sections sit on a quiet surface panel (card-like, elevation 0). */
.band {
  width: calc(100% - 32px);
  border: 1px solid var(--border);
  border-radius: var(--r-sheet);
  background: var(--surface);
  padding: 64px 56px;
  margin-block: 24px;
}

.feature-lead {
  margin-top: 18px;
  max-width: 50ch;
  font-size: 1.0625rem;
  color: var(--ink-2);
}

.feature-tip {
  display: inline-block;
  margin-top: 22px;
  padding: 10px 14px;
  border-radius: var(--r-chip);
  background: var(--accent-wash);
  color: var(--on-accent-wash);
  font-size: 0.875rem;
  max-width: 44ch;
}

.band .feature-tip { background: var(--accent-wash); }

.feature-media { display: flex; justify-content: center; }

/* ---------- Phone mockups ---------- */

.phone {
  width: 300px;
  border: 10px solid var(--ink);
  border-radius: 36px;
  background: var(--canvas);
  overflow: hidden;
}

.phone-screen {
  padding: 22px 18px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 540px;
}

.icon { width: 1em; height: 1em; flex-shrink: 0; }

.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 4px;
}

.app-bar-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}

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

.hud-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 9px;
  border-radius: var(--r-chip);
  background: var(--ink);
  color: var(--canvas);
  font-family: var(--serif);
  font-weight: 600;
  font-size: 0.75rem;
}

.hud-chip .icon-flame { color: var(--accent-wash); }

.screen-badge {
  padding: 3px 9px;
  border-radius: var(--r-chip);
  background: var(--accent-wash);
  color: var(--on-accent-wash);
  font-size: 0.6875rem;
  font-weight: 600;
}

.screen-subtitle {
  font-size: 0.75rem;
  color: var(--ink-2);
}

.app-btn {
  margin-top: auto;
  padding: 12px;
  border-radius: var(--r-btn);
  background: var(--ink);
  color: var(--canvas);
  font-size: 0.8125rem;
  font-weight: 600;
  text-align: center;
}

/* Camino screen */

.phase-label {
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}

.phase-label-locked { color: var(--ink-3); margin-top: 10px; }

.path-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.path-row-shift { padding-left: 28px; }

.path-node {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  font-size: 1.05rem;
  flex-shrink: 0;
}

.node-done { background: var(--accent); color: #FFFFFF; }
.node-current { background: var(--card); border: 2px solid var(--accent); }
.node-available { background: var(--card); border: 1px solid var(--border); }
.node-locked { background: var(--surface); border: 1px solid var(--border); color: var(--ink-3); }

.path-connector {
  height: 16px;
  margin-left: 20px;
  border-left: 2px dotted var(--ink-3);
}

.path-connector-shift { margin-left: 34px; }

.path-book { display: flex; flex-direction: column; line-height: 1.35; }
.path-book strong { font-size: 0.8125rem; font-weight: 600; }
.path-book small { font-size: 0.6875rem; color: var(--ink-2); }
.path-book-locked strong { color: var(--ink-3); }
.path-book-locked small { color: var(--ink-3); }

/* Nota screen */

.note-field {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-btn);
  background: var(--card);
}

.note-label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 2px;
}

.note-field p { font-size: 0.8125rem; line-height: 1.45; }

/* Práctica screen */

.practice-card {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  background: var(--card);
}

.practice-source {
  font-size: 0.6875rem;
  color: var(--ink-2);
  margin-bottom: 6px;
}

.practice-question {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 0.9375rem;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

.practice-answer {
  padding: 12px;
  border-radius: var(--r-btn);
  background: var(--surface);
}

.practice-answer p { font-size: 0.8125rem; line-height: 1.45; }

.grade-row { display: flex; gap: 6px; }

.grade-chip {
  flex: 1;
  padding: 8px 4px;
  border: 1px solid var(--border);
  border-radius: var(--r-chip);
  background: var(--card);
  font-size: 0.6875rem;
  font-weight: 600;
  text-align: center;
  color: var(--ink-2);
}

.grade-chip-selected {
  background: var(--accent-wash);
  border-color: var(--accent-deep);
  color: var(--on-accent-wash);
}

/* Asistente screen */

.chat-bubble {
  max-width: 85%;
  padding: 10px 12px;
  border-radius: var(--r-card);
}

.chat-bubble p { font-size: 0.8125rem; line-height: 1.45; }

.chat-assistant {
  align-self: flex-start;
  background: var(--card);
  border: 1px solid var(--border);
}

.chat-user {
  align-self: flex-end;
  background: var(--accent-wash);
  color: var(--on-accent-wash);
}

.chat-input {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 8px 8px 14px;
  border-radius: var(--r-btn);
  background: var(--surface);
  font-size: 0.75rem;
  color: var(--ink-3);
}

.chat-send {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--canvas);
  font-size: 0.875rem;
}

/* ---------- Quiet grid ---------- */

.quiet {
  padding-block: 96px 64px;
  text-align: center;
}

.quiet-grid {
  margin-top: 48px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
  text-align: left;
}

.quiet-card {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: var(--r-card);
  background: var(--card);
}

.quiet-card h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
}

.quiet-card p {
  margin-top: 8px;
  font-size: 0.9375rem;
  color: var(--ink-2);
}

/* ---------- Newsletter ---------- */

.newsletter {
  width: calc(100% - 32px);
  max-width: 720px;
  margin-block: 24px 104px;
  padding: 48px;
  border: 1px solid var(--border);
  border-radius: var(--r-sheet);
  background: var(--card);
  scroll-margin-top: 40px;
}

.newsletter > p {
  margin-top: 12px;
  color: var(--ink-2);
  font-size: 1rem;
  max-width: 52ch;
}

.notice {
  margin-top: 16px;
  padding: 12px 16px;
  border-radius: var(--r-chip);
  font-size: 0.9375rem;
}
.notice-ok { background: var(--accent-wash); color: var(--on-accent-wash); }
.notice-error { background: #F5E4E4; color: var(--danger); }

form { margin-top: 28px; }

form label {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--ink-2);
  margin-bottom: 8px;
}

.form-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

input[type="email"] {
  flex: 1;
  min-width: 220px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--r-btn);
  background: var(--canvas);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1rem;
}
input[type="email"]:focus-visible { outline-offset: 0; }

.legal {
  margin-top: 14px;
  font-size: 0.8125rem;
  color: var(--ink-3);
}

/* Honeypot: off-screen for humans, visible to bots */
.honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

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

.footer {
  border-top: 1px solid var(--border);
  padding: 24px;
  text-align: center;
  font-size: 0.8125rem;
  color: var(--ink-2);
}
.footer a { color: inherit; }

/* ---------- Motion ---------- */
/* Entrances follow the app's FadeSlideIn: fade + 12px up, 450ms easeOutCubic,
   staggered ≤60ms by landing.js. Everything is finite; the .js guard keeps
   content visible when JavaScript is unavailable. */

.js .reveal {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 450ms var(--ease-out-cubic), transform 450ms var(--ease-out-cubic);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

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

@media (max-width: 920px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 40px;
    padding-block: 48px 40px;
  }
  .hero-media { order: -1; }
  .hero-mark { width: clamp(150px, 32vw, 220px); }

  .feature {
    grid-template-columns: 1fr;
    gap: 40px;
    padding-block: 64px;
  }
  .feature-flip .feature-copy { order: 1; }
  .feature-flip .feature-media { order: 2; }
  .band { padding: 48px 32px; }

  .quiet { padding-block: 64px 40px; }
}

@media (max-width: 560px) {
  .newsletter { padding: 32px 24px; }
  .phone { width: 272px; }
}
