/* Recursos digitales */
:root { --plum: #6b3f7d; }
main [hidden] { display: none !important; }

/* Portada */
.rc-grupo { margin-bottom: 56px; }
.rc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; }
.rc-card { display: flex; flex-direction: column; gap: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 22px; text-decoration: none; color: var(--ink); transition: transform .2s, box-shadow .2s, border-color .2s; }
a.rc-card:hover { transform: translateY(-3px); box-shadow: 0 16px 34px -24px rgba(31, 26, 20, .5); border-color: #d9c9b2; }
.rc-card h3 { font-size: 1.25rem; line-height: 1.2; margin-top: 6px; }
.rc-card p { color: var(--muted); font-size: 0.94rem; flex: 1; }
.rc-go { font-weight: 700; font-size: 0.9rem; color: var(--terra); }
.rc-card.soon { background: transparent; border-style: dashed; }
.rc-card.soon .rc-ico { background: var(--sand); color: var(--muted); }
.rc-card.soon .rc-go { color: var(--muted); font-weight: 600; }
.rc-ico { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: #f8ebe2; color: var(--terra-dark); flex: none; }
.rc-ico.big { width: 64px; height: 64px; border-radius: 18px; }

/* Encabezado de cada herramienta */
.rc-head { display: flex; gap: 20px; align-items: flex-start; padding: 26px 0 28px; }
.rc-head .eyebrow { color: var(--olive); margin-bottom: 8px; }
.rc-head h1 { font-size: clamp(2rem, 5vw, 3rem); letter-spacing: -0.02em; line-height: 1.08; }
.rc-head p { color: var(--muted); font-size: 1.1rem; margin-top: 10px; max-width: 62ch; }

/* Bloques de herramienta */
.tool { background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 26px; margin-bottom: 20px; }
.tool.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: start; }
.tool-h { font-size: 1.35rem; margin-bottom: 14px; }
.tool-intro { color: var(--muted); margin-bottom: 16px; font-size: 0.97rem; }
.tool-nota { color: var(--muted); font-size: 0.85rem; margin-top: 12px; }
.inputs { display: grid; gap: 14px; align-content: start; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; }
.fld { display: flex; flex-direction: column; gap: 6px; font-size: 0.88rem; font-weight: 600; }
.fld small { font-weight: 400; color: var(--muted); font-size: 0.78rem; }
.fld input:not([type=range]), .fld select { font: inherit; font-weight: 500; font-size: 1rem; border: 1px solid var(--line); border-radius: 12px; padding: 11px 13px; background: #fdfbf7; width: 100%; color: var(--ink); }
.fld input:focus, .fld select:focus { outline: none; border-color: var(--terra); box-shadow: 0 0 0 3px rgba(180, 83, 42, .14); }
.fld input[type=range] { accent-color: var(--terra); }
.range-val { font-weight: 700; color: var(--terra-dark); }
.chk-line { display: flex; gap: 8px; align-items: center; font-size: 0.92rem; }
.chk-line input { accent-color: var(--terra); width: 18px; height: 18px; }
.lbl { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.seg { justify-self: start; display: inline-flex; flex-wrap: wrap; gap: 4px; background: var(--sand); padding: 4px; border-radius: 999px; }
.seg button { border: 0; background: transparent; font: inherit; font-weight: 600; font-size: 0.9rem; padding: 8px 16px; border-radius: 999px; cursor: pointer; color: var(--muted); }
.seg button[aria-pressed=true] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.12); }

.tabs-tool { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.tabs-tool button { font: inherit; font-weight: 600; font-size: 0.95rem; padding: 10px 18px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--muted); cursor: pointer; }
.tabs-tool button[aria-selected=true] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* Resultados */
.results { background: #faf6ef; border-radius: 18px; padding: 22px; display: grid; gap: 16px; align-content: start; position: sticky; top: 190px; }
.kv { display: grid; gap: 0; }
.kv div { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px dashed #e2d7c6; font-size: 0.95rem; }
.kv div:last-child { border-bottom: 0; }
.kv dt { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.kv dd { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.kv dd small { color: var(--muted); font-weight: 500; margin-left: 4px; }
.kv .big dt { color: var(--ink); font-weight: 600; }
.kv .big dd { font-size: 1.2rem; color: var(--olive); }
.kv .neg dd { color: var(--terra-dark); }
.res-note { font-size: 0.9rem; color: var(--muted); }
.res-note b { color: var(--ink); }
.res-alert { background: #fbeee6; color: var(--terra-dark); border-radius: 12px; padding: 14px 16px; font-weight: 600; }
.res-hero { display: flex; flex-direction: column; gap: 2px; }
.res-hero small { font-size: 0.78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.res-hero b { font-family: "Fraunces", serif; font-size: clamp(2rem, 5vw, 2.8rem); line-height: 1.1; color: var(--olive); }
.res-hero.neg b { color: var(--terra-dark); }
.res-hero span { color: var(--muted); font-size: 0.9rem; }
.stack { display: flex; height: 14px; border-radius: 999px; overflow: hidden; background: #ece3d5; }
.stack span { min-width: 2px; }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.c1 { background: #8a7a66; } .c2 { background: #c8922a; } .c3 { background: #3d87ab; } .c4 { background: #b5577a; } .c5 { background: #4f6b3a; } .cneg { background: #b3261e; }

/* Comparación de ofertas */
.cmp { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cmp-col { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px; position: relative; }
.cmp-col h3 { font-size: 1.15rem; margin-bottom: 6px; }
.cmp-col.win { border-color: #c4d6b4; box-shadow: 0 0 0 3px #e3eedb; }
.cmp-col .kv div { flex-direction: column; gap: 2px; padding: 7px 0; }
.cmp-col .kv dd { text-align: left; }
.win-badge { position: absolute; top: -10px; right: 12px; background: var(--olive); color: #fff; font-size: 0.7rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.ofertas { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ofertas fieldset { border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px 14px; display: grid; gap: 10px; }
.ofertas legend { font-family: "Fraunces", serif; font-weight: 600; padding: 0 6px; }

/* Conversor */
.cv-row { display: grid; grid-template-columns: 1.3fr 1fr auto 1fr; gap: 14px; align-items: end; }
.cv-swap { width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); font-size: 1.2rem; cursor: pointer; }
.cv-swap:hover { border-color: var(--terra); color: var(--terra); }
.cv-ars { margin-top: 18px; }
.cv-out { display: block; margin-top: 22px; padding: 22px; background: #faf6ef; border-radius: 18px; }
.cv-out .from { display: block; color: var(--muted); font-size: 1rem; }
.cv-out b { font-family: "Fraunces", serif; font-size: clamp(2rem, 6vw, 3.2rem); line-height: 1.1; color: var(--olive); }
.cv-meta { color: var(--muted); font-size: 0.88rem; margin-top: 10px; }
.cv-fuentes { font-size: 0.82rem; color: var(--muted); margin: -4px 0 20px; }
.rc-two { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* Tablas */
.tbl-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; }
.tbl { width: 100%; border-collapse: collapse; font-size: 0.93rem; font-variant-numeric: tabular-nums; }
.tbl th, .tbl td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
.tbl th { font-size: 0.72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: #faf6ef; white-space: nowrap; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl.hl tbody tr:hover td { background: #fdf7f1; }
.tbl tr.on td { background: #e9f2e2 !important; font-weight: 700; }
.tbl td small { display: block; color: var(--muted); font-size: 0.78rem; font-weight: 400; }
.tbl.res { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface); }
.tbl.res td { position: relative; }
.tbl.res .bar { display: block; height: 4px; border-radius: 4px; background: var(--terra); opacity: .5; margin-top: 6px; }

/* Talles */
.sizes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.sizes div { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 12px; text-align: center; }
.sizes small { display: block; font-size: 0.72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.sizes b { font-family: "Fraunces", serif; font-size: 1.9rem; color: var(--olive); }

/* Pie de herramienta */
.rc-aviso { font-size: 0.85rem; color: var(--muted); font-style: italic; margin: 4px 0 40px; }
.rc-bottom { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 40px; padding-bottom: 88px; }
.rc-faq h2 { font-size: 1.6rem; margin-bottom: 14px; }
.rc-faq details { border-bottom: 1px solid var(--line); padding: 14px 0; }
.rc-faq summary { font-weight: 600; cursor: pointer; font-size: 1.02rem; }
.rc-faq details p { color: var(--muted); margin-top: 8px; }
.rc-side { display: grid; gap: 18px; align-content: start; }
.rc-minis { display: grid; gap: 4px; }
.rc-mini { display: flex; gap: 12px; align-items: flex-start; text-decoration: none; padding: 8px 0; color: var(--ink); }
.rc-mini .rc-ico { width: 36px; height: 36px; border-radius: 10px; }
.rc-mini b { display: block; font-size: 0.93rem; }
.rc-mini small { display: block; color: var(--muted); font-size: 0.8rem; line-height: 1.35; }
.rc-mini:hover b { text-decoration: underline; }

@media (max-width: 920px) {
  .tool.split { grid-template-columns: 1fr; }
  .results { position: static; }
  .rc-two, .rc-bottom { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .tool { padding: 18px; border-radius: 18px; }
  .grid2, .grid3, .ofertas, .cmp { grid-template-columns: 1fr; }
  .grid3 { grid-template-columns: 1fr 1fr 1fr; }
  .cv-row { grid-template-columns: 1fr auto 1fr; }
  .cv-row .grow { grid-column: 1 / -1; }
  .sizes { grid-template-columns: 1fr 1fr; }
  .rc-head { flex-direction: column; gap: 12px; }
}

/* ---------- Portada compacta ---------- */
.pres-banner.pb-sm { min-height: 190px; }
.pres-banner.pb-sm .pb-txt h1 { font-size: clamp(2rem, 4vw, 2.8rem); }
.rc-filtros { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 26px; }
.rc-filtros button { font: inherit; font-weight: 600; font-size: 0.88rem; padding: 8px 15px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.rc-filtros button small { color: var(--muted); font-weight: 600; margin-left: 2px; }
.rc-filtros button[aria-pressed=true] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.rc-filtros button[aria-pressed=true] small { color: #cfc4b3; }
.rc-grupo { margin-bottom: 30px; }
.rc-ghead { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 14px; margin-bottom: 12px; padding-bottom: 8px; border-bottom: 1px solid var(--line); }
.rc-ghead h2 { font-size: 1.35rem; }
.rc-ghead p { color: var(--muted); font-size: 0.88rem; }
.rc-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.rc-card { display: grid; grid-template-columns: auto 1fr; grid-template-rows: 1fr auto; gap: 4px 12px; padding: 13px 14px; border-radius: 14px; align-items: start; }
.rc-card .rc-ico { width: 38px; height: 38px; border-radius: 11px; grid-row: span 2; }
.rc-t b { display: block; font-size: 0.95rem; line-height: 1.25; }
.rc-t small { display: block; color: var(--muted); font-size: 0.8rem; line-height: 1.35; margin-top: 3px; }
.rc-card .rc-go { font-size: 0.8rem; grid-column: 2; }
a.rc-card:hover { transform: translateY(-2px); }
.rc-card.ext .rc-ico { background: #dff2f1; color: #0f6e6a; }
.rc-card.ext .rc-go { color: #0f6e6a; }
@media (max-width: 1000px) { .rc-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .rc-grid { grid-template-columns: 1fr; } }

/* ---------- Nomenclatura dental ---------- */
.dn-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 14px; }
.dn-buscar { display: flex; gap: 10px; align-items: end; flex-wrap: wrap; }
.dn-buscar .fld { width: 170px; }
.dn-go { font: inherit; font-weight: 700; border: 0; background: var(--terra); color: #fff; border-radius: 12px; padding: 12px 18px; cursor: pointer; }
.dn-wrap { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 22px; align-items: start; margin-top: 10px; }
.odonto { background: #fdfbf7; border: 1px solid var(--line); border-radius: 18px; padding: 16px 14px 10px; display: grid; gap: 10px; }
.od-fila { display: flex; flex-direction: column; gap: 4px; }
.od-lbl { font-size: 0.7rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.od-dientes { display: flex; justify-content: center; gap: 3px; }
.od-medio { width: 2px; background: #d8ccb9; margin: 0 6px; border-radius: 2px; }
.od-d { flex: 1; max-width: 40px; display: flex; flex-direction: column; align-items: center; gap: 3px; border: 1px solid transparent; background: transparent; border-radius: 10px; padding: 4px 1px; cursor: pointer; font: inherit; }
.od-fila.inf .od-d { flex-direction: column-reverse; }
.od-d i { display: block; width: 78%; background: #fff; border: 2px solid #cdbfa8; border-radius: 40% 40% 30% 30%; }
.od-d.inc i { height: 30px; width: 58%; border-radius: 30% 30% 45% 45%; }
.od-d.can i { height: 34px; width: 62%; border-radius: 50% 50% 40% 40%; }
.od-d.pre i { height: 28px; }
.od-d.mol i { height: 26px; width: 92%; border-radius: 35%; }
.od-d span { font-size: 0.72rem; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.od-d:hover i { border-color: var(--terra); }
.od-d.on { background: #f8ebe2; border-color: #ecd1c0; }
.od-d.on i { border-color: var(--terra); background: #fbe3d6; }
.od-d.on span { color: var(--terra-dark); }
.od-lados { display: flex; justify-content: space-between; font-size: 0.72rem; color: var(--muted); padding: 0 4px; }
.dn-cods { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.dn-cods div { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px; text-align: center; }
.dn-cods small { display: block; font-size: 0.7rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.dn-cods b { font-family: "Fraunces", serif; font-size: 1.6rem; color: var(--olive); }
@media (max-width: 860px) { .dn-wrap { grid-template-columns: 1fr; } .od-dientes { gap: 1px; } .od-medio { margin: 0 2px; } .od-d span { font-size: 0.62rem; } }
.od-d { height: 58px; justify-content: space-between; }
.od-fila.sup .od-d i { margin-top: auto; }
.od-fila.sup .od-d span { order: 2; }
.od-fila.inf .od-d i { margin-bottom: auto; }
.hz-row { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; align-items: start; }
.hz-row .cv-swap { margin-top: 28px; }
.hz-reloj { margin-top: 12px; background: #faf6ef; border-radius: 16px; padding: 18px; display: grid; gap: 2px; }
.hz-reloj b { font-family: "Fraunces", serif; font-size: clamp(2.4rem, 6vw, 3.4rem); line-height: 1; color: var(--olive); font-variant-numeric: tabular-nums; }
.hz-reloj span { display: block; } .hz-reloj span::first-letter { text-transform: uppercase; }
.hz-reloj small { color: var(--muted); }
.hz-dif { margin-top: 16px; background: #eef5ef; border-radius: 14px; padding: 14px 18px; display: grid; gap: 2px; }
.hz-dif b { font-size: 1.15rem; }
.hz-dif span { color: var(--muted); font-size: 0.92rem; }
@media (max-width: 700px) { .hz-row { grid-template-columns: 1fr; } .hz-row .cv-swap { margin: 0 auto; transform: rotate(90deg); } }
.un-tipos { flex-wrap: wrap; }
.en-out { margin-top: 18px; display: grid; gap: 14px; }
.en-cmp { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.en-pais { background: #faf6ef; border-radius: 16px; padding: 16px 18px; display: grid; gap: 4px; }
.en-pais small { font-size: 0.75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.en-pais b { font-family: "Fraunces", serif; font-size: 1.6rem; color: var(--olive); }
.en-tipos { display: flex; flex-wrap: wrap; gap: 6px; }
.en-tipos span { font-weight: 700; font-size: 0.85rem; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 3px 10px; cursor: help; }
.en-res { list-style: none; display: grid; gap: 10px; }
.en-res li { border-radius: 14px; padding: 12px 16px; display: grid; gap: 2px; }
.en-res li.si { background: #fbeee6; }
.en-res li.si b { color: var(--terra-dark); }
.en-res li.no { background: #eef5ef; }
.en-res li.no b { color: var(--olive); }
.en-res span { color: var(--muted); font-size: 0.92rem; }
@media (max-width: 700px) { .en-cmp { grid-template-columns: 1fr; } }
