/* INGE & TECHNIK · Partes de trabajo
   Identidad: marco azul marino y panel lavanda del logotipo. */
:root {
  --navy: #012E7F;
  --navy-deep: #00225F;
  --lav: #CCCDE1;
  --lav-soft: #EEEFF6;
  --paper: #FFFFFF;
  --ground: #F6F6FA;
  --ink: #1C1F2E;
  --muted: #5E6378;
  --line: #D9DAE8;
  --ok: #1E7A4C;   --ok-bg: #E5F3EC;
  --def: #B42318;  --def-bg: #FBEAE8;
  --warn: #B54708; --warn-bg: #FEF0E2;
  --na: #5E6378;   --na-bg: #ECEDF2;
  --frame: 3px;
  --r: 4px;
  --font: "Barlow", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-head: "Barlow Semi Condensed", "Barlow", system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
}
*, *::before, *::after { box-sizing: inherit; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--ground); color: var(--ink);
  font: 400 16px/1.5 var(--font);
  padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px));
}
@media (min-width: 900px) { body { padding-bottom: 0; } }
img { max-width: 100%; }
a { color: var(--navy); }
h1, h2, h3 { font-family: var(--font-head); color: var(--navy); line-height: 1.15; margin: 0 0 .5em; font-weight: 600; }
h1 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.1rem); font-weight: 700; }
h2 { font-size: 1.3rem; }
h3 { font-size: 1.1rem; }
p { margin: 0 0 1em; max-width: 72ch; }
small, .muted { color: var(--muted); }
:focus-visible { outline: 3px solid #4C6FD0; outline-offset: 2px; }

/* ---------- Barra superior ---------- */
.topbar {
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 1.25rem;
  background: var(--paper); border-bottom: var(--frame) solid var(--navy);
  padding: .5rem 1rem;
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); background: var(--paper); z-index: 31; }
.brand img { display: block; height: 44px; width: auto; }
.mainnav { display: none; gap: .25rem; }
.mainnav a {
  font-family: var(--font-head); font-weight: 600; font-size: 1.02rem;
  color: var(--ink); text-decoration: none; padding: .45rem .75rem; border-radius: var(--r);
}
.mainnav a:hover { background: var(--lav-soft); }
.mainnav a[aria-current="page"] { background: var(--lav); color: var(--navy); }
.userbox { margin-left: auto; display: none; align-items: center; gap: .75rem; }
.username { text-decoration: none; color: var(--ink); text-align: right; line-height: 1.2; font-weight: 500; }
.username small { display: block; font-size: .78rem; }
.topbar .btn-new { display: none; }
@media (min-width: 900px) {
  .mainnav, .userbox { display: flex; }
  .topbar .btn-new { display: inline-flex; }
}

/* ---------- Barra inferior (móvil) ---------- */
.tabbar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 30;
  display: grid; grid-template-columns: repeat(5, 1fr);
  background: var(--paper); border-top: var(--frame) solid var(--navy);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.tabbar a {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: .45rem 0 .5rem; font-size: .74rem; font-weight: 600; color: var(--muted); text-decoration: none;
}
.tabbar a[aria-current="page"] { color: var(--navy); }
.tabbar .tab-new { color: var(--paper); background: var(--navy); }
@media (min-width: 900px) { .tabbar { display: none; } }
.ico { width: 22px; height: 22px; background: currentColor; -webkit-mask: var(--m) center/contain no-repeat; mask: var(--m) center/contain no-repeat; }
.ico-home { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Cpath d='M3 11l9-7 9 7v9a1 1 0 0 1-1 1h-5v-6H9v6H4a1 1 0 0 1-1-1z'/%3E%3C/svg%3E"); }
.ico-list { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='4' y='3' width='16' height='18' rx='1'/%3E%3Cpath d='M8 8h8M8 12h8M8 16h5'/%3E%3C/svg%3E"); }
.ico-plus { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E"); }
.ico-building { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Cpath d='M4 21V4h10v17M14 9h6v12M2 21h20M7 8h3M7 12h3M7 16h3'/%3E%3C/svg%3E"); }
.ico-user { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Ccircle cx='12' cy='8' r='4'/%3E%3Cpath d='M4 21c1-4 4-6 8-6s7 2 8 6'/%3E%3C/svg%3E"); }
.ico-cam { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Cpath d='M4 7h3l2-3h6l2 3h3v13H4z'/%3E%3Ccircle cx='12' cy='13' r='4'/%3E%3C/svg%3E"); }

/* ---------- Página ---------- */
.page { max-width: 1120px; margin: 0 auto; padding: 1.25rem 1rem 2rem; }
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: .75rem 1rem; margin-bottom: 1.25rem; }
.page-head h1 { margin: 0; }
.page-head p { margin: .25rem 0 0; color: var(--muted); }

/* Panel con el marco del logotipo */
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); padding: 1.1rem 1.1rem 1.2rem; margin-bottom: 1rem; }
.panel-framed { border: var(--frame) solid var(--navy); }
.panel > h2:first-child { margin-top: 0; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .45rem;
  min-height: 44px; padding: .55rem 1.05rem; border-radius: var(--r);
  border: 2px solid var(--navy); background: var(--paper); color: var(--navy);
  font: 600 1rem/1.1 var(--font-head); text-decoration: none; cursor: pointer;
}
.btn:hover { background: var(--lav-soft); }
.btn-primary { background: var(--navy); color: #fff; }
.btn-primary:hover { background: var(--navy-deep); }
.btn-danger { border-color: var(--def); color: var(--def); }
.btn-danger:hover { background: var(--def-bg); }
.btn-sm { min-height: 36px; padding: .35rem .7rem; font-size: .92rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: progress; }
.btn-link { background: none; border: 0; color: var(--navy); font: inherit; font-weight: 600; cursor: pointer; padding: .25rem; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }

/* ---------- Formularios ---------- */
label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .3rem; }
.field { margin-bottom: .9rem; }
.field .help { font-size: .82rem; color: var(--muted); margin-top: .25rem; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=time], input[type=number], input[type=search], input[type=tel], select, textarea {
  width: 100%; min-height: 44px; padding: .55rem .7rem;
  border: 1.5px solid #B9BBD3; border-radius: var(--r); background: #fff; color: var(--ink);
  font: 400 1rem/1.3 var(--font);
}
textarea { min-height: 88px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--navy); outline: 2px solid rgba(1,46,127,.18); outline-offset: 0; }
.grid { display: grid; gap: 0 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid-2 { display: grid; gap: 0 1rem; grid-template-columns: 1fr; }
@media (min-width: 700px) { .grid-2 { grid-template-columns: 1fr 1fr; } }
.check { display: flex; gap: .5rem; align-items: center; font-weight: 500; }
.check input { width: 22px; height: 22px; accent-color: var(--navy); }

/* ---------- Avisos ---------- */
.alert { padding: .8rem 1rem; border-radius: var(--r); margin-bottom: 1rem; border-left: 5px solid; background: var(--paper); }
.alert-ok { border-color: var(--ok); background: var(--ok-bg); }
.alert-error { border-color: var(--def); background: var(--def-bg); }
.alert-warn { border-color: var(--warn); background: var(--warn-bg); }
.alert ul { margin: .35rem 0 0; padding-left: 1.2rem; }

/* ---------- Etiquetas ---------- */
.tag { display: inline-block; padding: .12rem .5rem; border-radius: 3px; font-size: .8rem; font-weight: 600; background: var(--lav-soft); color: var(--navy); white-space: nowrap; }
.tag-BT { background: #E3E8F7; color: #012E7F; }
.tag-CLIMA { background: #E1F0F4; color: #0D5466; }
.tag-PCI { background: #FBE7E4; color: #9B2216; }
.tag-borrador { background: var(--warn-bg); color: var(--warn); }
.tag-finalizado { background: var(--ok-bg); color: var(--ok); }
.res-FAVORABLE { color: var(--ok); font-weight: 600; }
.res-FAVORABLE_OBS { color: var(--warn); font-weight: 600; }
.res-DESFAVORABLE { color: var(--def); font-weight: 600; }

/* ---------- Listas de partes ---------- */
.list { list-style: none; margin: 0; padding: 0; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); }
.list li + li { border-top: 1px solid var(--line); }
.list a.row { display: grid; grid-template-columns: 1fr auto; gap: .2rem 1rem; padding: .8rem 1rem; text-decoration: none; color: var(--ink); }
.list a.row:hover { background: var(--lav-soft); }
.row-title { font-weight: 600; }
.row-code { font-family: var(--font-head); font-weight: 600; color: var(--navy); }
.row-meta { font-size: .88rem; color: var(--muted); grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: .25rem .9rem; }
.empty { padding: 1.5rem 1rem; text-align: center; color: var(--muted); background: var(--paper); border: 1px dashed var(--line); border-radius: var(--r); }

/* Indicadores de administración */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .75rem; margin-bottom: 1.25rem; }
.kpi { background: var(--paper); border: 1px solid var(--line); border-left: 5px solid var(--navy); padding: .7rem .9rem; border-radius: var(--r); }
.kpi b { display: block; font: 700 1.9rem/1 var(--font-head); color: var(--navy); }
.kpi span { font-size: .88rem; color: var(--muted); }
.kpi-alert { border-left-color: var(--def); }
.kpi-alert b { color: var(--def); }

/* Filtros */
.filters { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); align-items: end; margin-bottom: 1rem; }
.filters .field { margin: 0; }

/* Tabla simple */
.table-wrap { overflow-x: auto; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); }
table.simple { width: 100%; border-collapse: collapse; font-size: .95rem; }
table.simple th { text-align: left; font: 600 .85rem var(--font-head); color: var(--muted); padding: .6rem .8rem; border-bottom: 2px solid var(--lav); white-space: nowrap; }
table.simple td { padding: .6rem .8rem; border-top: 1px solid var(--line); vertical-align: top; }
.pager { display: flex; gap: .5rem; justify-content: center; margin-top: 1rem; }

/* ---------- Elección de especialidad (nuevo parte) ---------- */
.choice { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); margin-bottom: 1rem; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice label {
  margin: 0; cursor: pointer; padding: .9rem 1rem; border: 2px solid var(--line); border-radius: var(--r);
  background: var(--paper); font-weight: 500; display: block; height: 100%;
}
.choice label b { display: block; font: 700 1.2rem var(--font-head); color: var(--navy); }
.choice label small { display: block; margin-top: .15rem; }
.choice input:checked + label { border-color: var(--navy); box-shadow: inset 0 0 0 1px var(--navy); background: var(--lav-soft); }
.choice input:focus-visible + label { outline: 3px solid #4C6FD0; outline-offset: 2px; }

/* =========================================================
   EDITOR DE PARTE
   ========================================================= */
.parte-bar {
  position: sticky; top: 63px; z-index: 20;
  display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem;
  background: var(--navy); color: #fff; padding: .55rem 1rem; margin: -1.25rem -1rem 1rem;
}
@media (max-width: 899px) { .parte-bar { top: 63px; } }
.parte-bar .code { font: 700 1.1rem var(--font-head); }
.parte-bar .esp { opacity: .85; font-size: .9rem; }
.parte-bar .progress { margin-left: auto; display: flex; align-items: center; gap: .6rem; font-size: .88rem; }
.meter { width: 110px; height: 8px; background: rgba(255,255,255,.25); border-radius: 4px; overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--lav); width: 0; transition: width .25s; }
.save-state { font-size: .82rem; opacity: .9; min-width: 9ch; }
.save-state.err { color: #FFD3CD; font-weight: 600; opacity: 1; }

.sec { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 1rem; }
.sec-head { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1rem; padding: .8rem 1rem; border-bottom: 3px solid var(--lav); }
.sec-head h2 { margin: 0; font-size: 1.15rem; flex: 1 1 260px; }
.sec-head h2 .num { color: var(--muted); margin-right: .3rem; }
.sec-head .ref { display: block; font: 400 .8rem var(--font); color: var(--muted); margin-top: .15rem; }
.sec.off .sec-body { display: none; }
.sec.off { background: transparent; border-style: dashed; }
.sec.off .sec-head { border-bottom: 0; }
.sec-tools { display: flex; gap: .5rem; align-items: center; }

.item { display: grid; gap: .5rem .9rem; grid-template-columns: 1fr; padding: .85rem 1rem; border-top: 1px solid var(--line); }
.item:first-child { border-top: 0; }
@media (min-width: 900px) { .item { grid-template-columns: minmax(0, 1fr) auto; align-items: start; } }
.item-text { line-height: 1.4; }
.item-text .n { font-family: var(--font-head); font-weight: 700; color: var(--navy); margin-right: .35rem; }
.item-text .freq { display: inline-block; margin-left: .35rem; font-size: .76rem; color: var(--muted); border: 1px solid var(--line); border-radius: 3px; padding: 0 .35rem; white-space: nowrap; }
.item-text .iref { font-size: .8rem; color: var(--muted); }
.item.hidden { display: none; }
.item.is-DEF { background: var(--def-bg); }
.item-obs { grid-column: 1 / -1; display: none; gap: .5rem; align-items: center; }
.item.is-DEF .item-obs, .item.has-obs .item-obs, .item.show-obs .item-obs { display: flex; }
.item-obs input { flex: 1; }
.item.is-DEF .item-obs input:placeholder-shown { border-color: var(--def); }

/* Selector de resultado: el elemento protagonista, pensado para pulsar con guantes */
.seg { display: inline-grid; grid-template-columns: repeat(3, minmax(0, 1fr)); min-width: 0; border: 2px solid var(--navy); border-radius: var(--r); overflow: hidden; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg label { margin: 0; min-height: 46px; text-align: center; line-height: 1.1; display: flex; align-items: center; justify-content: center; padding: 0 .3rem; font: 600 .95rem var(--font-head); cursor: pointer; color: var(--navy); background: #fff; user-select: none; }
.seg label:not(:first-of-type) { border-left: 1px solid var(--lav); }
.seg input:focus-visible + label { outline: 3px solid #4C6FD0; outline-offset: -3px; }
.seg input[value=OK]:checked + label { background: var(--ok); color: #fff; }
.seg input[value=DEF]:checked + label { background: var(--def); color: #fff; }
.seg input[value=NA]:checked + label { background: var(--na); color: #fff; }
@media (max-width: 899px) { .seg { display: grid; width: 100%; } .item-actions { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; } }
@media (min-width: 900px) { .seg { width: 330px; } }
.item-actions { display: flex; gap: .4rem; align-items: center; }
.icon-btn { width: 46px; height: 46px; display: inline-flex; align-items: center; justify-content: center; border: 2px solid var(--lav); background: #fff; color: var(--navy); border-radius: var(--r); cursor: pointer; flex: none; }
.icon-btn:hover { border-color: var(--navy); }
.icon-btn .badge { position: relative; }
.icon-btn[data-count]:not([data-count="0"])::after { content: attr(data-count); font: 700 .7rem var(--font); background: var(--navy); color: #fff; border-radius: 9px; padding: 0 .3rem; margin-left: -6px; margin-top: -22px; }

/* Tablas de medidas e inventarios como fichas */
.dt { padding: .9rem 1rem 1rem; border-top: 1px solid var(--line); }
.dt h3 { margin-bottom: .6rem; }
.dt-row { position: relative; display: grid; gap: .5rem .7rem; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); padding: .7rem 3.2rem .7rem .7rem; background: var(--lav-soft); border-radius: var(--r); margin-bottom: .5rem; }
.dt-row label { font-size: .76rem; font-weight: 600; color: var(--muted); margin-bottom: .15rem; }
.dt-row input, .dt-row select { min-height: 40px; padding: .4rem .5rem; font-size: .95rem; }
.dt-row .wide { grid-column: span 2; }
.dt-del { position: absolute; right: .5rem; top: .5rem; width: 36px; height: 36px; border: 0; background: transparent; color: var(--def); font-size: 1.4rem; cursor: pointer; border-radius: var(--r); }
.dt-del:hover { background: var(--def-bg); }

/* Fotos */
.photos { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); margin-top: .75rem; }
.photo { background: var(--lav-soft); border-radius: var(--r); overflow: hidden; position: relative; }
.photo img { display: block; width: 100%; aspect-ratio: 4/3; object-fit: cover; background: var(--lav); }
.photo .meta { padding: .4rem; }
.photo .meta input { min-height: 36px; font-size: .88rem; padding: .3rem .45rem; }
.photo .ref { font-size: .74rem; color: var(--muted); padding: 0 .45rem .35rem; line-height: 1.25; }
.photo .del { position: absolute; top: .35rem; right: .35rem; width: 34px; height: 34px; border-radius: 50%; border: 0; background: rgba(28,31,46,.75); color: #fff; font-size: 1.1rem; cursor: pointer; }
.photo.uploading img { opacity: .45; }
.photo .bar { position: absolute; left: 0; bottom: 0; height: 4px; background: var(--navy); width: 0; }

/* Resultado global */
.result-choice { display: grid; gap: .5rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.result-choice input { position: absolute; opacity: 0; pointer-events: none; }
.result-choice label { margin: 0; min-height: 52px; display: flex; align-items: center; justify-content: center; text-align: center; border: 2px solid var(--line); border-radius: var(--r); font: 600 1.02rem var(--font-head); cursor: pointer; background: #fff; padding: .4rem; }
.result-choice input:focus-visible + label { outline: 3px solid #4C6FD0; outline-offset: 2px; }
.result-choice input[value=FAVORABLE]:checked + label { background: var(--ok); border-color: var(--ok); color: #fff; }
.result-choice input[value=FAVORABLE_OBS]:checked + label { background: var(--warn); border-color: var(--warn); color: #fff; }
.result-choice input[value=DESFAVORABLE]:checked + label { background: var(--def); border-color: var(--def); color: #fff; }

/* Firmas */
.sig { border: 2px dashed #B9BBD3; border-radius: var(--r); background: #fff; position: relative; touch-action: none; }
.sig canvas { display: block; width: 100%; height: 180px; cursor: crosshair; }
.sig .clear { position: absolute; right: .4rem; top: .4rem; }
.sig .hint { position: absolute; left: 0; right: 0; bottom: .5rem; text-align: center; color: #A3A6BD; font-size: .85rem; pointer-events: none; }
.sig.signed .hint { display: none; }
.sig.signed { border-style: solid; border-color: var(--navy); }

.finish { position: sticky; bottom: calc(68px + env(safe-area-inset-bottom, 0px)); z-index: 15; background: var(--paper); border: var(--frame) solid var(--navy); border-radius: var(--r); padding: .7rem; display: flex; gap: .6rem; flex-wrap: wrap; justify-content: flex-end; }
@media (min-width: 900px) { .finish { bottom: 1rem; } }

/* Vista de parte finalizado */
.kv { display: grid; grid-template-columns: max-content 1fr; gap: .3rem 1rem; margin: 0; }
.kv dt { color: var(--muted); font-size: .9rem; }
.kv dd { margin: 0; }
.res-pill { display: inline-block; padding: .2rem .6rem; border-radius: 3px; font-weight: 600; font-size: .85rem; }
.res-pill.r-OK { background: var(--ok-bg); color: var(--ok); }
.res-pill.r-DEF { background: var(--def-bg); color: var(--def); }
.res-pill.r-NA { background: var(--na-bg); color: var(--na); }

/* Modal */
dialog { border: var(--frame) solid var(--navy); border-radius: var(--r); padding: 1.25rem; max-width: 520px; width: calc(100% - 2rem); }
dialog::backdrop { background: rgba(0, 34, 95, .45); }

/* ---------- Acceso ---------- */
.login-wrap { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 1.5rem 1rem; background: var(--lav); }
.login-card { width: 100%; max-width: 420px; background: #fff; border: var(--frame) solid var(--navy); padding: 1.5rem; }
.login-card img { display: block; width: 100%; height: auto; margin-bottom: 1.25rem; }
.login-card h1 { font-size: 1.4rem; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }
@media print { .topbar, .tabbar, .finish, .parte-bar { display: none !important; } }
.tabbar-only { display: block; margin-top: 1rem; }
@media (min-width: 900px) { .tabbar-only { display: none; } }
.item.missing { box-shadow: inset 5px 0 0 var(--warn); background: var(--warn-bg); }
.photo.failed img { opacity: .35; }
.ico-cal { --m: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2'%3E%3Crect x='3' y='5' width='18' height='16' rx='1'/%3E%3Cpath d='M3 10h18M8 3v4M16 3v4'/%3E%3C/svg%3E"); }
.tag-sv-programado { background: #E3E8F7; color: var(--navy); }
.tag-sv-en_curso { background: var(--warn-bg); color: var(--warn); }
.tag-sv-realizado { background: var(--ok-bg); color: var(--ok); }
.tag-sv-cancelado { background: var(--na-bg); color: var(--na); text-decoration: line-through; }
.day-head { font-size: 1.05rem; margin: 0 0 .5rem; }
.tag-GEN { background: #EDE9F6; color: #4A3A8C; }
.choice-urg input#urg-1:checked + label { border-color: var(--def); box-shadow: inset 0 0 0 1px var(--def); background: var(--def-bg); }
.choice-urg input#urg-1:checked + label b { color: var(--def); }
.tag-urgente { background: var(--def); color: #fff; }
