/* /imc/ — calculadora pública de IMC (clave preop-imc). Sin escalas de color ni rangos. */

/* ---------- Héroe ---------- */
.imc-hero { padding-block: clamp(36px, 6vw, 84px) clamp(28px, 4vw, 52px); }
.imc-hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(24px, 5vw, 64px); align-items: center; }
.imc-hero h1 { font-size: var(--fs-3xl); max-width: none; }
.imc-hero h1 .imc-line { display: inline-block; opacity: 0; transform: translateY(18px); animation: imc-rise .9s var(--ease) forwards; }
.imc-hero h1 .imc-line + br + .imc-line { animation-delay: .16s; }
.imc-hero h1 em { font-style: italic; color: var(--green); }
@keyframes imc-rise { to { opacity: 1; transform: none; } }
html.reduce-motion .imc-hero h1 .imc-line { opacity: 1; transform: none; }
.imc-hero .lead { max-width: 50ch; }
.imc-benefits { list-style: none; padding: 0; margin: 24px 0 0; display: flex; flex-wrap: wrap; gap: 10px 14px; }
.imc-benefits li { margin: 0; display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px 8px 12px; border-radius: 999px; background: rgba(255, 255, 255, .85); border: 1px solid var(--line); font-weight: 650; font-size: var(--fs-sm); color: var(--ink-2); }
.imc-benefits svg { width: 20px; height: 20px; color: var(--green); flex-shrink: 0; }
.imc-clock { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.imc-hero-graphic { position: relative; width: min(100%, 380px); aspect-ratio: 1; margin-inline: auto; }
.imc-orbit { position: absolute; border-radius: 50%; border: 1.5px dashed rgba(70, 135, 119, .35); }
.imc-orbit--one { inset: 0; animation: imc-spin 80s linear infinite; }
.imc-orbit--two { inset: 14%; border-style: solid; border-color: rgba(36, 105, 137, .18); animation: imc-spin 60s linear infinite reverse; }
.imc-orbit--one::after, .imc-orbit--two::after { content: ""; position: absolute; width: 12px; height: 12px; border-radius: 50%; top: 12%; left: 12%; background: var(--green-3); box-shadow: 0 0 0 6px rgba(111, 163, 146, .18); }
.imc-orbit--two::after { top: auto; left: auto; bottom: 6%; right: 18%; width: 10px; height: 10px; background: var(--sky-ink); box-shadow: 0 0 0 6px rgba(36, 105, 137, .14); }
@keyframes imc-spin { to { transform: rotate(360deg); } }
.imc-disc { position: absolute; inset: 27%; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 35% 30%, #fff 0%, var(--sage) 70%); box-shadow: var(--shadow-3); color: var(--green); }
.imc-disc svg { width: 72%; height: 72%; fill: none; stroke: currentColor; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.imc-disc svg circle { fill: currentColor; stroke: none; }
.imc-leaf { position: absolute; width: 58px; height: 58px; border-radius: 0 70% 0 70%; animation: imc-sway 9s ease-in-out infinite; }
.imc-leaf--one { left: 6%; bottom: 18%; background: var(--mint-2); }
.imc-leaf--two { right: 8%; top: 10%; width: 44px; height: 44px; background: var(--sky-2); animation-delay: -4.5s; transform: rotate(90deg); }
@keyframes imc-sway { 0%, 100% { transform: rotate(0deg) translateY(0); } 50% { transform: rotate(8deg) translateY(-8px); } }
.imc-chip { position: absolute; right: -4px; bottom: 14%; display: inline-flex; align-items: center; gap: 10px; padding: 12px 18px; border-radius: 16px; background: rgba(255, 255, 255, .92); box-shadow: var(--shadow-2); font-family: var(--font-display); font-style: italic; font-size: var(--fs-lg); color: var(--deep); animation: imc-bob 7s ease-in-out infinite; }
.imc-chip-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green-3); }
@keyframes imc-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-9px); } }

/* ---------- Calculadora ---------- */
.imc-calc { padding-top: clamp(8px, 2vw, 24px); }
.imc-calc-grid { display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: clamp(16px, 2.6vw, 28px); align-items: stretch; }
.imc-input-card { padding: clamp(22px, 3.4vw, 40px); box-shadow: var(--shadow-2); }
.imc-card-top { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; }
.imc-card-top h2 { font-size: var(--fs-xl); margin-bottom: .3em; }
.imc-card-symbol { width: 54px; height: 54px; border-radius: 18px; display: grid; place-items: center; background: var(--mint); color: var(--deep); flex-shrink: 0; }
.imc-card-symbol svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.imc-intro { color: var(--ink-2); margin-bottom: 22px; }

.imc-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.imc-field { display: grid; gap: 6px; align-content: start; }
.imc-field label { font-weight: 650; font-size: var(--fs-md); color: var(--deep); }
.imc-input-unit { position: relative; }
.imc-input-unit input {
  width: 100%; min-height: 60px; padding: 12px 58px 12px 18px; border-radius: var(--r-md); border: 1.5px solid var(--line-2); background: var(--paper);
  color: var(--deep); font-size: 1.375rem; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .01em;
  transition: border-color var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
}
.imc-input-unit input::placeholder { color: var(--muted); opacity: 1; font-weight: 500; font-size: 1.125rem; }
.imc-input-unit input:hover { border-color: var(--green-3); }
.imc-input-unit input:focus { outline: none; background: #fff; border-color: var(--green-2); box-shadow: 0 0 0 4px rgba(70, 135, 119, .2); }
.imc-input-unit input[aria-invalid="true"] { border-color: var(--rose-ink); background: #fffaf8; }
.imc-input-unit input[aria-invalid="true"]:focus { box-shadow: 0 0 0 4px rgba(151, 58, 44, .16); }
.imc-input-unit span { position: absolute; right: 18px; top: 50%; transform: translateY(-50%); font-weight: 650; color: var(--muted); pointer-events: none; }
.imc-hint { margin: 0; font-size: var(--fs-sm); color: var(--muted); line-height: 1.45; }
.imc-error { margin: 0; font-size: var(--fs-sm); line-height: 1.45; color: var(--rose-ink); font-weight: 600; }
.imc-error:empty { display: none; }
.imc-error:not(:empty) { animation: bp-fade-up var(--t-med) var(--ease); }

.imc-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.imc-calc-btn { min-height: 54px; padding-inline: 26px; font-size: var(--fs-md); }
.imc-calc-btn:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; background: var(--green); }
.imc-actions .btn--ghost { min-height: 54px; }
.imc-noscript { margin: 16px 0 0; padding: 12px 16px; border-radius: var(--r-sm); background: var(--sand); color: var(--sand-ink); font-weight: 600; }
.imc-privacy { display: flex; align-items: center; gap: 12px; margin: 22px 0 0; padding: 12px 16px; border-radius: var(--r-md); background: var(--sage); color: var(--ink-2); font-size: var(--fs-sm); font-weight: 600; line-height: 1.45; }
.imc-privacy svg { width: 22px; height: 22px; flex-shrink: 0; fill: none; stroke: var(--green); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* Resultado: un número, sin colores por rango */
.imc-result-card {
  position: relative; overflow: hidden; display: flex; flex-direction: column;
  padding: clamp(22px, 3.4vw, 40px); border-radius: var(--r-lg);
  background: linear-gradient(170deg, #fff 0%, var(--sky) 100%); border: 1.5px solid var(--sky-2);
  box-shadow: var(--shadow-1); transition: border-color var(--t-med) var(--ease), box-shadow var(--t-med) var(--ease);
}
.imc-result-card > * { position: relative; z-index: 1; }
.imc-result-card.has-result { border-color: var(--green-3); box-shadow: var(--shadow-2); }
.imc-result-card.is-new { animation: imc-glow 1.4s var(--ease) 1; }
@keyframes imc-glow { 0% { box-shadow: 0 0 0 0 rgba(70, 135, 119, .32), var(--shadow-2); } 100% { box-shadow: 0 0 0 18px rgba(70, 135, 119, 0), var(--shadow-2); } }
.imc-result-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.imc-result-heading .eyebrow { margin: 0; color: var(--sky-ink); }
.imc-result-heading svg { width: 26px; height: 26px; color: var(--sky-ink); flex-shrink: 0; }
.imc-result-number { z-index: 0; display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 12px; margin: clamp(18px, 3vw, 30px) 0 6px; min-height: 1.1em; }
.imc-result-number output {
  position: relative; z-index: 1; font-family: var(--font-display); font-weight: 500; line-height: 1;
  font-size: clamp(3.6rem, 2.8rem + 3.2vw, 5.4rem); color: var(--deep); font-variant-numeric: tabular-nums; letter-spacing: -.02em;
}
.imc-unit { position: relative; z-index: 1; font-size: var(--fs-lg); font-weight: 650; color: var(--muted); }
.imc-bloom { position: absolute; left: -30px; top: 50%; width: 220px; height: 220px; margin-top: -110px; border-radius: 50%; background: radial-gradient(circle, rgba(220, 236, 227, .95) 0%, rgba(220, 236, 227, 0) 70%); transform: scale(.4); opacity: 0; transition: transform var(--t-slow) var(--ease), opacity var(--t-slow) var(--ease); pointer-events: none; }
.has-result .imc-bloom { transform: scale(1); opacity: 1; }
.imc-status { color: var(--ink-2); font-weight: 600; margin-bottom: 20px; }
.imc-context { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; padding-top: 18px; border-top: 1px solid var(--sky-2); margin-top: auto; }
.imc-context p { margin: 0; color: var(--ink-2); }
.imc-context-icon { width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; background: #fff; color: var(--sky-ink); }
.imc-context-icon svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.imc-adult { display: flex; gap: 10px; align-items: flex-start; margin: 16px 0 0; font-size: var(--fs-sm); color: var(--ink-2); line-height: 1.5; }
.imc-adult svg { width: 20px; height: 20px; flex-shrink: 0; margin-top: 1px; color: var(--sky-ink); }

/* ---------- Contacto ---------- */
.imc-contact {
  display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(18px, 4vw, 44px); align-items: start;
  padding: clamp(22px, 4vw, 52px); border-radius: var(--r-xl);
  background: linear-gradient(135deg, var(--sand) 0%, var(--cream) 60%, var(--sage) 100%); border: 1px solid #ece0cc;
  max-width: 980px; margin-inline: auto;
}
.imc-contact-illustration { width: 112px; height: 112px; border-radius: 32px; display: grid; place-items: center; background: #fff; color: var(--sand-ink); box-shadow: var(--shadow-1); }
.imc-contact-illustration svg { width: 70px; height: 70px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.imc-contact-main .eyebrow { color: var(--sand-ink); }
.imc-contact-main h2 { font-size: var(--fs-2xl); max-width: 20ch; }
.imc-contact-main > p { color: var(--ink-2); max-width: 60ch; }
.imc-care { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px; margin: 6px 0 20px; border-radius: 999px; background: #fff; border: 1px solid var(--line); width: fit-content; max-width: 100%; }
.imc-care button { border: 0; background: transparent; min-height: 48px; padding: 10px 20px; border-radius: 999px; font-weight: 650; font-size: var(--fs-sm); color: var(--ink-2); transition: background var(--t-fast), color var(--t-fast); }
.imc-care button:hover { background: var(--sage); color: var(--deep); }
.imc-care button[aria-pressed="true"] { background: var(--deep); color: #fff; }
.imc-appointment { min-height: 56px; padding-inline: 24px; font-size: var(--fs-md); text-align: left; }
.imc-out { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.imc-confirmation { margin: 14px 0 0; font-size: var(--fs-sm); color: var(--muted); max-width: 62ch; }
.imc-contact-main.is-swapping #contact-title,
.imc-contact-main.is-swapping #contact-description,
.imc-contact-main.is-swapping .imc-appointment,
.imc-contact-main.is-swapping .imc-confirmation { animation: imc-swap var(--t-med) var(--ease); }
@keyframes imc-swap { from { opacity: .15; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- Metodología ---------- */
.imc-method-section { padding-top: 0; }
.imc-method summary { font-size: var(--fs-md); }
.imc-method .acc-body strong { color: var(--deep); white-space: nowrap; }

/* ---------- Adaptación ---------- */
@media (max-width: 960px) {
  .imc-hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 260px); }
  .imc-calc-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .imc-hero-grid { grid-template-columns: 1fr; }
  .imc-hero-graphic { display: none; }
  .imc-contact { grid-template-columns: 1fr; }
  .imc-contact-illustration { width: 80px; height: 80px; border-radius: 24px; }
  .imc-contact-illustration svg { width: 50px; height: 50px; }
}
@media (max-width: 560px) {
  .imc-result-heading svg, .imc-card-symbol { display: none; }
  .imc-fields { grid-template-columns: 1fr; }
  .imc-actions .btn { flex: 1 1 auto; }
  .imc-care { border-radius: var(--r-md); width: 100%; }
  .imc-care button { flex: 1 1 auto; }
  .imc-appointment { width: 100%; justify-content: flex-start; }
}
/* ---------- Ajustes de componentes comunes (mientras no se corrija bp.css; ver propuestas, sección e) ----------
   1. «Contacto» del menú: .nav a (0,1,1) pisaba el blanco de .btn y dejaba #3a525b sobre verde (1,35:1).
   2. «Pausar movimiento» y «Escríbenos 24/7»: área táctil de 44 px sin cambiar el alto visible de la barra. */
.nav a.btn { color: #fff; }
.nav a.btn:hover { background: var(--deep); color: #fff; }
.site-top .motion-toggle, .site-top a { position: relative; }
.site-top .motion-toggle::after, .site-top a::after { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 44px; margin-top: -22px; }

@media print {
  .imc-hero-graphic, .aurora, .imc-care, .imc-actions { display: none !important; }
}
