/* RentToMillions: sistema compartido para /, /curso y /hoteles.
   Cada página fija su acento con .theme-curso o .theme-hoteles en <body>.
   La página principal es neutra y solo usa los acentos dentro de sus tarjetas. */

:root {
  /* Neutros */
  --bg: #f5f6f8;
  --surface: #fcfcfd;
  --ink: #141a24;
  --muted: #586273;
  --line: #e0e4ea;
  --line-strong: #c9d0da;
  --focus: #1f6feb;
  --error: #b42318;

  /* Acento neutro (página principal) */
  --accent: #141a24;
  --accent-ink: #fcfcfd;

  /* Producto: curso (tinta azul marino + coral) */
  --curso-bg: #fce9e2;
  --curso-ink: #16233b;
  --curso-muted: #4a4f63;
  --curso-label: #a8360f;
  --curso-accent: #e4572e;
  --curso-accent-ink: #16233b;

  /* Producto: hoteles (azul petróleo + verde azulado) */
  --hotel-bg: #0f2a33;
  --hotel-ink: #eaf1f6;
  --hotel-muted: #b3c4cf;
  --hotel-label: #6fd3c8;
  --hotel-accent: #3fc1b5;
  --hotel-accent-ink: #062421;

  /* Tipografía */
  --font-d: "Bricolage Grotesque", system-ui, sans-serif;
  --font-b: "Instrument Sans", system-ui, sans-serif;

  /* Movimiento */
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --press: 100ms;

  /* Forma: botones en píldora, tarjetas 20px, campos 12px */
  --r-card: 20px;
  --r-field: 12px;

  /* Medidas */
  --gutter: 1rem;
  --maxw: 72rem;
  --nav-h: 4rem;

  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d1117;
    --surface: #151b24;
    --ink: #eceff4;
    --muted: #a3adbd;
    --line: #252d39;
    --line-strong: #364152;
    --focus: #79b8ff;
    --error: #ff8a80;
    --accent: #eceff4;
    --accent-ink: #0d1117;
    --curso-bg: #2a1a16;
    --curso-ink: #f6ede9;
    --curso-muted: #d2bfb8;
    --curso-label: #ff9a76;
    --curso-accent: #ff7348;
    --curso-accent-ink: #1a0f0b;
    --hotel-bg: #0f2a30;
    --hotel-ink: #eaf1f6;
    --hotel-muted: #a9bdc8;
    --hotel-label: #6fd3c8;
    --hotel-accent: #3fc1b5;
    --hotel-accent-ink: #062421;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0d1117;
  --surface: #151b24;
  --ink: #eceff4;
  --muted: #a3adbd;
  --line: #252d39;
  --line-strong: #364152;
  --focus: #79b8ff;
  --error: #ff8a80;
  --accent: #eceff4;
  --accent-ink: #0d1117;
  --curso-bg: #2a1a16;
  --curso-ink: #f6ede9;
  --curso-muted: #d2bfb8;
  --curso-label: #ff9a76;
  --curso-accent: #ff7348;
  --curso-accent-ink: #1a0f0b;
  --hotel-bg: #0f2a30;
  --hotel-ink: #eaf1f6;
  --hotel-muted: #a9bdc8;
  --hotel-label: #6fd3c8;
  --hotel-accent: #3fc1b5;
  --hotel-accent-ink: #062421;
  color-scheme: dark;
}

/* Base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--nav-h) + 1rem); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--font-b);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: var(--font-d); margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2.25rem, 5.2vw, 3.75rem); font-weight: 800; line-height: 1.05; letter-spacing: -0.025em; }
h2 { font-size: clamp(1.75rem, 3.6vw, 2.5rem); font-weight: 800; line-height: 1.1; letter-spacing: -0.02em; }
h3 { font-size: 1.125rem; font-weight: 700; line-height: 1.3; letter-spacing: -0.005em; }
p { margin: 0; text-wrap: pretty; }
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
@media (min-width: 768px) { :root { --gutter: 2rem; } }

.skip {
  position: absolute; left: var(--gutter); top: -4rem; z-index: 30;
  background: var(--ink); color: var(--bg); padding: .75rem 1rem; border-radius: var(--r-field);
  text-decoration: none; font-weight: 600;
}
.skip:focus { top: .75rem; }

.lede { font-size: 1.1875rem; line-height: 1.55; color: var(--muted); max-width: 38rem; }
.muted { color: var(--muted); }
.num { font-variant-numeric: tabular-nums; }

/* Marcadores de contenido pendiente: visibles a propósito */
.placeholder {
  display: grid; place-items: center; text-align: center;
  border: 2px dashed var(--line-strong); border-radius: var(--r-card);
  color: var(--muted); padding: 1.25rem;
  font: 500 .875rem/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: repeating-linear-gradient(135deg, transparent 0 12px, color-mix(in srgb, var(--line) 45%, transparent) 12px 13px);
}

/* Navegación: translúcida, con desvanecido en lugar de línea dura */
.nav {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--bg) 72%, transparent);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
}
.nav::after {
  content: ""; position: absolute; inset: 100% 0 auto; height: 1.25rem; pointer-events: none;
  background: linear-gradient(to bottom, color-mix(in srgb, var(--bg) 60%, transparent), transparent);
}
.nav .wrap { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: var(--nav-h); }
.logo {
  font: 800 1.1875rem/1 var(--font-d); letter-spacing: -0.02em; text-decoration: none;
  display: inline-flex; align-items: center; min-height: 44px;
}
/* Mismo formato del logo actual: "Rent" grande + "TO MILLIONS" pequeño en mayúsculas espaciadas */
.logo { gap: .3125rem; align-items: baseline; padding-top: .625rem; }
/* Fuente del logo: Hanken Grotesk, la versión actual de HK Grotesk que usa el sitio original */
.logo-rent { font: 700 1.5rem/1 "Hanken Grotesk", var(--font-d); letter-spacing: -0.02em; }
.logo-tm { font: 700 .75rem/1 "Hanken Grotesk", var(--font-b); letter-spacing: .22em; text-transform: uppercase; }
.nav-links { display: flex; align-items: center; gap: .25rem; margin: 0; padding: 0; list-style: none; }
.nav-links a {
  display: inline-flex; align-items: center; min-height: 44px; padding-inline: .875rem;
  border-radius: 999px; text-decoration: none; font-weight: 500; font-size: .9375rem; color: var(--muted);
  transition: color 150ms ease, background-color 150ms ease;
}
.nav-links a[aria-current="page"] { color: var(--ink); }
@media (hover: hover) and (pointer: fine) {
  .nav-links a:hover { color: var(--ink); background: color-mix(in srgb, var(--ink) 6%, transparent); }
}

/* Botones */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 3rem; padding: .75rem 1.5rem; border: 0; border-radius: 999px;
  background: var(--accent); color: var(--accent-ink);
  font: 700 1rem/1.2 var(--font-d); letter-spacing: -0.005em; white-space: nowrap;
  text-decoration: none; cursor: pointer;
  transition: transform var(--press) var(--ease-out), opacity 150ms ease;
}
.btn:active { transform: scale(0.97); }
.btn[disabled] { opacity: .6; cursor: progress; }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { opacity: .9; }
}

/* Formularios */
.field { display: grid; gap: .375rem; min-width: 0; }
.field label { font-weight: 600; font-size: .9375rem; }
.field .hint { font-size: .875rem; color: var(--muted); }
.field input[type="email"], .field input[type="text"] {
  font: inherit; color: var(--ink); background: var(--bg);
  border: 1.5px solid var(--line-strong); border-radius: var(--r-field);
  padding: .8125rem 1rem; width: 100%; min-height: 3rem;
  font-size: 1rem; /* 16px evita el zoom en iOS */
  transition: border-color 150ms ease;
}
.field input::placeholder { color: color-mix(in srgb, var(--muted) 85%, transparent); }
.field input:focus-visible { outline: 3px solid color-mix(in srgb, var(--focus) 40%, transparent); outline-offset: 0; border-color: var(--focus); }
.field [aria-invalid="true"] { border-color: var(--error); }
.field .error { font-size: .875rem; color: var(--error); min-height: 0; }
.field .error:empty { display: none; }
.check { display: flex; gap: .75rem; align-items: flex-start; font-size: .9375rem; color: var(--muted); cursor: pointer; }
.check input { width: 1.25rem; height: 1.25rem; margin: .125rem 0 0; flex: none; accent-color: var(--ink); }
.check a { color: var(--ink); }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

/* Pie de página */
.footer { border-top: 1px solid var(--line); padding-block: 2.5rem 3rem; color: var(--muted); font-size: .875rem; }
.footer .wrap { display: grid; gap: 1.25rem; }
.footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem 2rem; align-items: center; }
.footer-links { display: flex; flex-wrap: wrap; gap: .25rem 1.5rem; margin: 0; padding: 0; list-style: none; }
.footer-links a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; }
.footer-links a, .footer a { color: var(--muted); }
@media (hover: hover) and (pointer: fine) { .footer a:hover { color: var(--ink); } }
.footer .legal { max-width: 52rem; line-height: 1.55; }

/* Accesibilidad */
@media (prefers-reduced-transparency: reduce) {
  .nav { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@media (prefers-contrast: more) {
  :root { --line: var(--muted); --line-strong: var(--ink); }
  .nav { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; border-bottom: 1px solid var(--ink); }
  .nav::after { display: none; }
}
/* Movimiento reducido: sin desplazamientos ni escalas; los fundidos cortos se mantienen */
@media (prefers-reduced-motion: reduce) {
  .btn:active { transform: none; }
  html { scroll-behavior: auto; }
}
