/* ==========================================================================
   Arte Dental · sistema de diseño
   Estética de la app de demo (2026-09-25): fotos grandes con esquinas
   redondeadas, botones en píldora, una sola familia (Instrument Sans) y un
   solo color de marca. Sin tarjetas con sombra, sin iconos decorativos, sin
   etiquetas en mayúsculas encima de los títulos.
   Los tokens --bg-soft, --brand, --ink, --ink-2, --ink-3 y --line los usa
   también css/notas.css: no renombrarlos.
   ========================================================================== */

:root {
  --bg: #ffffff;
  --bg-soft: #f4f3f0;
  --ink: #15181c;
  --ink-2: #4a5057;
  --ink-3: #7b8189;
  --line: #e6e4df;
  --brand: #1d3b4f;
  --brand-dark: #142a39;
  --accent: #6f8a9c;
  --photo: #dedbd5;

  --r-photo: 28px;
  --r-md: 18px;
  --r-pill: 999px;
  --wrap: 1180px;
  --gutter: 24px;
  --font: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 500; letter-spacing: -0.02em; line-height: 1.08; }
h1 { font-size: clamp(2.5rem, 5.6vw, 4.4rem); }
h2 { font-size: clamp(2rem, 3.8vw, 3rem); }
h3 { font-size: 1.3rem; line-height: 1.25; letter-spacing: -0.01em; }
p { margin: 0; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 3px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--ink-2); }
.small { font-size: 0.92rem; color: var(--ink-2); }
.lead { font-size: 1.12rem; color: var(--ink-2); max-width: 34em; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; z-index: 100; background: #fff; padding: 8px 12px; border-radius: 8px; }

/* ---------- Botones y enlaces ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 52px; padding: 0 28px; border-radius: var(--r-pill);
  font: 500 1rem/1 var(--font); text-decoration: none; cursor: pointer;
  border: 1px solid transparent; transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.btn-brand { background: var(--brand); color: #fff; }
.btn-brand:hover { background: var(--brand-dark); }
.btn-line { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-line:hover { border-color: var(--ink-3); }
.btn-white { background: #fff; color: var(--brand-dark); }
.btn-white:hover { background: var(--bg-soft); }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.link { color: var(--brand); font-weight: 500; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.link:hover { color: var(--brand-dark); }
.arrow::after { content: " →"; }

/* ---------- Cabecera ---------- */
.header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-in { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: 76px; }
.logo { display: flex; flex-direction: column; text-decoration: none; line-height: 1.1; }
.logo b { font-size: 1.5rem; font-weight: 500; letter-spacing: -0.02em; }
.logo span { font-size: 0.8rem; color: var(--ink-3); }
.nav { display: flex; gap: 28px; }
.nav a { text-decoration: none; font-size: 0.95rem; color: var(--ink-2); }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }
.header-cta { display: flex; align-items: center; gap: 16px; }
.header-tel { text-decoration: none; font-weight: 500; font-size: 0.95rem; white-space: nowrap; }
.header-cta .btn { height: 44px; padding: 0 20px; font-size: 0.95rem; }
.burger {
  display: none; height: 44px; padding: 0 18px; border-radius: var(--r-pill);
  border: 1px solid var(--line); background: #fff; font: 500 0.95rem var(--font); color: var(--ink); cursor: pointer;
}
.menu { display: none; }
.menu.open {
  display: flex; flex-direction: column; padding: 8px var(--gutter) 24px;
  border-top: 1px solid var(--line); background: #fff;
}
.menu a { padding: 14px 0; border-bottom: 1px solid var(--line); text-decoration: none; font-size: 1.1rem; }

/* ---------- Portada ---------- */
.hero {
  display: grid; grid-template-columns: 1.05fr 1fr; gap: 56px; align-items: center;
  max-width: var(--wrap); margin: 0 auto; padding: 48px var(--gutter) 88px;
}
.hero-place { font-size: 0.95rem; color: var(--ink-3); margin-bottom: 20px; }
.hero h1 { margin-bottom: 24px; }
.hero .lead { margin-bottom: 36px; }
.hero .small { margin-top: 20px; }
.hero .photo { aspect-ratio: 4 / 5; }

/* ---------- Fotos ---------- */
.photo {
  position: relative; overflow: hidden; border-radius: var(--r-photo);
  background: var(--photo);
}
.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photo > span { /* hueco sin foto todavía */
  position: absolute; left: 16px; bottom: 14px; font-size: 0.85rem; color: var(--ink-2);
}
.ratio-43 { aspect-ratio: 4 / 3; }
.ratio-32 { aspect-ratio: 3 / 2; }
.ratio-169 { aspect-ratio: 16 / 9; }
.ratio-45 { aspect-ratio: 4 / 5; }
.credit { font-size: 0.8rem; color: var(--ink-3); margin-top: 8px; }

/* ---------- Franja de datos ---------- */
.facts { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.facts .wrap { display: grid; grid-template-columns: repeat(3, 1fr); }
.fact { padding: 28px 28px 28px 0; font-size: 0.95rem; color: var(--ink-2); }
.fact + .fact { padding-left: 28px; border-left: 1px solid var(--line); }
.fact b { display: block; color: var(--ink); font-weight: 500; font-size: 1.05rem; margin-bottom: 4px; }
.fact a { color: var(--ink); text-decoration: none; font-weight: 500; }

/* ---------- Secciones ---------- */
.section { padding: 104px 0; }
.section + .section { border-top: 1px solid var(--line); }
.section.soft { background: var(--bg-soft); border-top: 0; }
.section.soft + .section { border-top: 0; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; margin-bottom: 48px; }
.section-head > div { max-width: 40em; }
.section-head p { margin-top: 14px; color: var(--ink-2); max-width: 36em; }
.crumbs { font-size: 0.88rem; color: var(--ink-3); margin-bottom: 24px; }
.crumbs a { color: var(--ink-3); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.crumbs span[aria-current] { color: var(--ink); }

/* ---------- Tratamientos ---------- */
.treatments { display: grid; grid-template-columns: repeat(3, 1fr); gap: 48px 32px; }
.treatment { text-decoration: none; display: block; }
.treatment .photo { aspect-ratio: 4 / 3; margin-bottom: 20px; transition: opacity 0.2s; }
.treatment:hover .photo { opacity: 0.92; }
.treatment h3 { margin-bottom: 8px; }
.treatment:hover h3 { color: var(--brand); }
.treatment p { color: var(--ink-2); font-size: 0.97rem; }
.treatment .more { display: inline-block; margin-top: 12px; color: var(--brand); font-weight: 500; font-size: 0.95rem; }
.also { display: grid; grid-template-columns: 1fr 2fr; gap: 32px; margin-top: 72px; padding-top: 32px; border-top: 1px solid var(--line); }
.also ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 12px 32px; }
.also li { padding-bottom: 12px; border-bottom: 1px solid var(--line); color: var(--ink-2); }

/* ---------- Bloque foto + texto ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; align-items: center; }
.split.flip > :first-child { order: 2; }
.split-text h2 { margin-bottom: 20px; }
.split-text p + p { margin-top: 16px; }
.split-text .lead { margin-bottom: 8px; }

/* ---------- Equipo ---------- */
.team { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px 32px; }
.person .portrait {
  aspect-ratio: 4 / 5; border-radius: var(--r-photo); background: var(--bg-soft);
  display: flex; align-items: flex-end; padding: 20px; margin-bottom: 18px;
  font-size: 3rem; font-weight: 500; letter-spacing: -0.03em; color: var(--brand);
}
.section.soft .person .portrait { background: #fff; }
.person h3 { margin-bottom: 4px; }
.person p { color: var(--ink-2); font-size: 0.95rem; }
.person .col { margin-top: 8px; font-size: 0.85rem; color: var(--ink-3); }
.staff { margin-top: 56px; padding-top: 28px; border-top: 1px solid var(--line); display: grid; grid-template-columns: 1fr 2fr; gap: 32px; }
.staff ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.staff li b { display: block; font-weight: 500; }
.staff li span { color: var(--ink-2); font-size: 0.93rem; }

/* ---------- Columnas de texto ---------- */
.cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.cols > div { border-top: 1px solid var(--ink); padding-top: 20px; }
.cols h3 { margin-bottom: 10px; }
.cols p { color: var(--ink-2); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; }
.list { list-style: none; margin: 16px 0 0; padding: 0; }
.list li { padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--ink-2); }
.list li:first-child { border-top: 1px solid var(--line); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; padding: 0; list-style: none; }
.chips li { padding: 6px 14px; border: 1px solid var(--line); border-radius: var(--r-pill); background: #fff; font-size: 0.93rem; }

/* ---------- Pasos ---------- */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px 32px; }
.steps.five { grid-template-columns: repeat(5, 1fr); }
.steps .n { display: block; font-size: 3.2rem; line-height: 1; font-weight: 400; color: var(--accent); margin-bottom: 18px; }
.steps h3 { margin-bottom: 8px; }
.steps p { color: var(--ink-2); font-size: 0.97rem; }

/* ---------- Clínicas ---------- */
.clinics { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.clinic .photo { aspect-ratio: 3 / 2; margin-bottom: 24px; }
.clinic h3 { font-size: 1.7rem; margin-bottom: 4px; }
.clinic .tag { color: var(--ink-3); font-size: 0.93rem; margin-bottom: 16px; }
.rows { margin: 16px 0 20px; }
.rows > div { display: grid; grid-template-columns: 130px 1fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.rows > div:first-child { border-top: 1px solid var(--line); }
.rows dt { color: var(--ink-3); font-size: 0.93rem; }
.rows dd { margin: 0; }
.rows a { text-decoration: none; font-weight: 500; }

/* ---------- Preguntas ---------- */
.faq-wrap { display: grid; grid-template-columns: 1fr 2fr; gap: 56px; align-items: start; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none; cursor: pointer; padding: 22px 40px 22px 0; position: relative;
  font-size: 1.15rem; font-weight: 500;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 4px; top: 50%; transform: translateY(-50%);
  font-size: 1.6rem; font-weight: 300; color: var(--ink-3); transition: transform 0.2s;
}
.faq details[open] summary::after { transform: translateY(-50%) rotate(45deg); }
.faq details > div { padding: 0 40px 24px 0; color: var(--ink-2); }

/* ---------- Contacto ---------- */
.contact { display: grid; grid-template-columns: 1fr 1.15fr; gap: 64px; align-items: start; }
.contact-info h2 { margin-bottom: 16px; }
.contact-info .rows dt { font-size: 0.9rem; }
.form {
  background: var(--bg-soft); border-radius: var(--r-photo); padding: 36px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 18px;
}
.section.soft .form { background: #fff; }
.form .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 0.9rem; font-weight: 500; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; font: 400 1rem var(--font); color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 13px 16px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px rgba(29, 59, 79, 0.1); }
.field .hint { font-size: 0.82rem; color: var(--ink-3); margin-top: 6px; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: 0.88rem; color: var(--ink-2); }
.check input { width: 20px; height: 20px; margin: 2px 0 0; flex-shrink: 0; accent-color: var(--brand); }
.hp { position: absolute; left: -9999px; }
.form-status { font-size: 0.95rem; }
.form-status.ok { color: #2f6b45; }
.form-status.err { color: #a2362e; }
.form button[disabled] { opacity: 0.6; cursor: wait; }

/* ---------- Franja final ---------- */
.band { padding: 0 var(--gutter) 104px; }
.section.soft + .band { padding-top: 104px; } /* si no, la franja queda pegada al fondo gris */
.band-in {
  max-width: var(--wrap); margin: 0 auto; background: var(--brand); color: #fff;
  border-radius: 32px; padding: 72px 48px; text-align: center;
}
.band-in h2 { margin-bottom: 14px; }
.band-in p { color: rgba(255, 255, 255, 0.78); max-width: 32em; margin: 0 auto 32px; }
.band-in .btn-row { justify-content: center; }
.band-in .btn-line { background: transparent; color: #fff; border-color: rgba(255, 255, 255, 0.4); }

/* ---------- Pie ---------- */
.footer { border-top: 1px solid var(--line); padding: 64px 0 32px; font-size: 0.93rem; color: var(--ink-2); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 32px; }
.footer b { display: block; color: var(--ink); font-weight: 500; margin-bottom: 8px; font-size: 1rem; }
.footer a { text-decoration: none; }
.footer a:hover { color: var(--ink); }
.footer ul { list-style: none; margin: 0; padding: 0; }
.footer li + li { margin-top: 4px; }
.footer-bottom { display: flex; justify-content: space-between; gap: 16px; margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 0.85rem; color: var(--ink-3); }

/* Barra fija en móvil: llamar y escribir siempre a mano */
.mobile-bar { display: none; }

/* ---------- Chip de dato pendiente ----------
   Marca todo dato que no está verificado. data-dato = su número en
   docs/REUNION-VIERNES.md §4. Se sustituye por el dato real, nunca por
   algo plausible. */
.todo {
  display: inline-block; padding: 1px 8px;
  border: 1px dashed #c99a2e; border-radius: 6px; background: #fff4d1; color: #6f5000;
  font-size: 0.78em; font-weight: 600; line-height: 1.6; letter-spacing: 0;
  vertical-align: 0.1em; white-space: normal;
}

/* Aviso de página que aún no existe (ver js/site.js) */
.toast {
  position: fixed; left: 50%; bottom: 96px; transform: translateX(-50%);
  background: var(--ink); color: #fff; padding: 12px 20px; border-radius: var(--r-pill);
  font-size: 0.93rem; z-index: 60; opacity: 0; pointer-events: none; transition: opacity 0.2s;
  max-width: calc(100vw - 32px);
}
.toast.show { opacity: 1; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav, .header-tel { display: none; }
  .burger { display: inline-flex; align-items: center; }
  .treatments, .team { grid-template-columns: 1fr 1fr; }
  .steps, .steps.five { grid-template-columns: 1fr 1fr; }
  .staff { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  :root { --gutter: 16px; --r-photo: 22px; }
  body { font-size: 16px; padding-bottom: 64px; }
  .header-in { height: 64px; }
  .header-cta .btn { display: none; }
  .hero { grid-template-columns: 1fr; gap: 32px; padding-top: 28px; padding-bottom: 56px; }
  .hero .photo { aspect-ratio: 4 / 3; }
  .hero .btn-row .btn { width: 100%; }
  .facts .wrap { grid-template-columns: 1fr; }
  .fact { padding: 20px 0; }
  .fact + .fact { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); }
  .section { padding: 64px 0; }
  .section-head { flex-direction: column; align-items: flex-start; margin-bottom: 32px; }
  .treatments, .team, .cols, .two, .clinics, .split, .faq-wrap, .contact, .also, .footer-grid { grid-template-columns: 1fr; }
  .split { gap: 32px; }
  .split.flip > :first-child { order: 0; }
  .also ul, .staff ul { grid-template-columns: 1fr; }
  .team { gap: 32px; }
  .steps, .steps.five { grid-template-columns: 1fr; gap: 28px; }
  .rows > div { grid-template-columns: 110px 1fr; }
  .form { grid-template-columns: 1fr; padding: 24px; }
  .band { padding-bottom: 64px; }
  .section.soft + .band { padding-top: 64px; }
  .band-in { padding: 48px 24px; border-radius: 24px; }
  .footer-bottom { flex-direction: column; }
  .mobile-bar {
    display: grid; grid-template-columns: 1fr 1fr; position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
    background: #fff; border-top: 1px solid var(--line);
  }
  .mobile-bar a { padding: 20px; text-align: center; text-decoration: none; font-weight: 500; }
  .mobile-bar a:first-child { background: var(--brand); color: #fff; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
