:root {
  --bg: #fbf6ec;
  --card: #ffffff;
  --ink: #2b2d42;
  --muted: #7a7d8c;
  --line: #ece4d4;
  --soft: #f4eee2;
  --primary: #f0642e;
  --ok: #2fae66;
  --ok-soft: #e3f6ea;
  --bad: #e5484d;
  --bad-soft: #fdecec;
  --warn: #ffe08a;
  --warn-ink: #6b4b00;
  --kid: #f5b82e;
  --kid-soft: #fff4d6;
  --radius: 22px;
  --pop: 0 4px 0 rgba(43, 45, 66, .18);
  --font-display: "Baloo 2", system-ui, sans-serif;
  --font: "Nunito", system-ui, sans-serif;
}
[data-kid="sol"]   { --kid: #f5b82e; --kid-soft: #fff4d6; }
[data-kid="mar"]   { --kid: #3d8bfd; --kid-soft: #e6f0ff; }
[data-kid="fresa"] { --kid: #f2558a; --kid-soft: #ffe8f0; }
[data-kid="lima"]  { --kid: #5cc25a; --kid-soft: #e8f8e6; }
[data-kid="uva"]   { --kid: #9b6bf2; --kid-soft: #f1eaff; }

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  -webkit-tap-highlight-color: transparent;
  -webkit-text-size-adjust: 100%;
}
h1, h2, h3 { font-family: var(--font-display); margin: 0; line-height: 1.1; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
input, select, textarea { font: inherit; color: inherit; }
img { display: block; }
.hidden { display: none !important; }

.wrap { max-width: 480px; margin: 0 auto; min-height: 100vh; min-height: 100dvh; padding: 0 0 calc(110px + env(safe-area-inset-bottom)); }
.pad { padding: 20px; }
.stack { display: grid; gap: 14px; }
.row { display: flex; align-items: center; gap: 10px; }
.grow { flex: 1; min-width: 0; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.center { text-align: center; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 52px; padding: 0 22px; border-radius: 16px;
  font-weight: 800; font-size: 17px;
  background: var(--soft); border: 2px solid var(--line);
  transition: transform .05s;
}
.btn:active { transform: translateY(2px); }
.btn.primary { background: var(--primary); color: #fff; border-color: transparent; box-shadow: var(--pop); }
.btn.ok { background: var(--ok); color: #fff; border-color: transparent; box-shadow: var(--pop); }
.btn.bad { background: var(--bad); color: #fff; border-color: transparent; box-shadow: var(--pop); }
.btn.kid { background: var(--kid); border-color: transparent; box-shadow: var(--pop); }
.btn.block { width: 100%; }
.btn.sm { height: 40px; padding: 0 14px; font-size: 15px; border-radius: 12px; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.link { font-weight: 800; color: var(--muted); text-decoration: underline; padding: 10px; }

/* ---------- elegir perfil ---------- */
.picker h1 { font-size: 40px; text-align: center; margin: 28px 0 24px; }
.profile {
  display: flex; align-items: center; gap: 16px; width: 100%;
  padding: 16px 18px; border-radius: 26px;
  background: var(--kid-soft); border: 4px solid var(--kid); box-shadow: var(--pop);
  text-align: left;
}
.profile:active { transform: translateY(2px); box-shadow: none; }
.avatar {
  flex: none; display: grid; place-items: center;
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--kid); font-size: 36px; line-height: 1;
}
.avatar.sm { width: 46px; height: 46px; font-size: 26px; }
.profile .name { font-family: var(--font-display); font-weight: 800; font-size: 30px; }
.profile.papa { background: var(--card); border-color: var(--line); padding: 12px 18px; }
.profile.papa .avatar { background: var(--soft); width: 48px; height: 48px; font-size: 26px; }
.profile.papa .name { font-size: 22px; }

/* ---------- PIN ---------- */
.overlay {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(43, 45, 66, .45);
  display: flex; align-items: flex-end; justify-content: center;
  animation: fade .15s;
}
.sheet {
  width: 100%; max-width: 480px; max-height: 92vh; overflow: auto;
  background: var(--card); border-radius: 28px 28px 0 0;
  padding: 22px 20px calc(22px + env(safe-area-inset-bottom));
  animation: up .2s ease-out;
}
@media (min-width: 560px) {
  .overlay { align-items: center; }
  .sheet { border-radius: 28px; }
}
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
.sheet-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.sheet-head h2 { flex: 1; font-size: 26px; }
.close { width: 44px; height: 44px; border-radius: 50%; background: var(--soft); font-size: 22px; font-weight: 800; }

.dots { display: flex; justify-content: center; gap: 16px; margin: 6px 0 20px; }
.dot { width: 20px; height: 20px; border-radius: 50%; border: 3px solid var(--kid); }
.dot.on { background: var(--kid); }
.dots.shake { animation: shake .35s; }
@keyframes shake { 20%, 60% { transform: translateX(-10px); } 40%, 80% { transform: translateX(10px); } }
.keypad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.key {
  height: 66px; border-radius: 18px; background: var(--soft);
  font-family: var(--font-display); font-size: 32px; font-weight: 700;
}
.key:active { background: var(--kid-soft); }
.pin-msg { min-height: 24px; text-align: center; font-weight: 800; color: var(--bad); margin-top: 12px; }

/* ---------- cabecera y menú inferior ---------- */
.topbar { display: flex; align-items: center; gap: 12px; padding: 14px 20px; background: var(--kid-soft); }
.topbar .title { flex: 1; font-family: var(--font-display); font-weight: 800; font-size: 24px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 40px; padding: 0 14px; border-radius: 999px;
  background: var(--card); font-weight: 800; font-size: 15px; box-shadow: 0 2px 0 var(--line);
}
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  max-width: 480px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px;
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  background: var(--card); border-top: 2px solid var(--line);
}
.tabbar a {
  display: flex; align-items: center; justify-content: center; gap: 8px; height: 56px;
  border-radius: 18px; font-family: var(--font-display); font-weight: 800; font-size: 19px;
  color: var(--ink); text-decoration: none;
}
.tabbar a.on { background: var(--kid); }

.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.seg button { height: 46px; border-radius: 14px; background: var(--soft); font-weight: 800; }
.seg button.on { background: var(--ink); color: #fff; }

/* ---------- resumen ---------- */
.score { background: var(--kid); border-radius: var(--radius); padding: 18px 20px; box-shadow: var(--pop); }
.score .big { font-family: var(--font-display); font-weight: 800; font-size: 40px; line-height: 1; }
.score .pts { font-family: var(--font-display); font-weight: 800; font-size: 22px; }
.bar { height: 16px; border-radius: 999px; background: rgba(255,255,255,.75); overflow: hidden; margin-top: 12px; }
.bar > div { height: 100%; background: var(--ok); border-radius: 999px; transition: width .3s; }
.score .sub { font-weight: 800; font-size: 14px; margin-top: 8px; }
.alert {
  background: var(--warn); color: var(--warn-ink); border-radius: 18px; padding: 14px;
  text-align: center; font-family: var(--font-display); font-weight: 800; font-size: 19px;
}
.alert.good { background: var(--ok-soft); color: #18663b; }

/* ---------- tarjeta de tarea ---------- */
.task {
  background: var(--card); border: 4px solid var(--line); border-radius: 24px;
  padding: 14px; display: grid; gap: 12px;
}
.task.done { border-color: var(--ok); }
.task.rejected { border-color: var(--bad); }
.task-head { display: flex; align-items: center; gap: 12px; }
.task-head h3 { flex: 1; font-size: 21px; }
.task-head .emoji { font-size: 30px; }
.check {
  flex: none; width: 64px; height: 64px; border-radius: 18px;
  border: 4px solid var(--line); display: grid; place-items: center; background: var(--card);
}
.check svg { width: 38px; height: 38px; stroke: var(--line); }
.check.on { background: var(--ok); border-color: var(--ok); }
.check.on svg { stroke: #fff; }
.hint { font-size: 14px; font-weight: 800; color: var(--muted); }
.note { border-radius: 14px; padding: 10px 12px; font-weight: 700; font-size: 15px; background: var(--soft); }
.note.bad { background: var(--bad-soft); color: var(--bad); }
.reps { display: grid; gap: 8px; }
.rep {
  display: grid; grid-template-columns: 1fr auto; grid-template-areas: "name ctl" "quick ctl";
  align-items: center; gap: 6px 8px; background: var(--soft); border-radius: 18px; padding: 10px 10px 10px 12px;
}
.rep-name { grid-area: name; font-weight: 800; font-size: 17px; }
.rep-quick { grid-area: quick; display: flex; flex-wrap: wrap; gap: 4px; min-width: 0; }
.chip-q {
  height: 34px; min-width: 40px; padding: 0 6px; border-radius: 999px;
  background: var(--card); border: 2px dashed var(--kid); font-weight: 800; font-size: 15px;
}
.chip-q:active, .step:active { transform: scale(.94); }
.rep-ctl { grid-area: ctl; display: flex; align-items: center; gap: 6px; }
.step {
  width: 46px; height: 50px; border-radius: 15px; background: var(--card); border: 2px solid var(--line);
  font-family: var(--font-display); font-size: 30px; font-weight: 700; line-height: 1;
  touch-action: manipulation; user-select: none; -webkit-user-select: none;
}
.step.plus { background: var(--kid); border-color: transparent; box-shadow: 0 3px 0 rgba(43, 45, 66, .18); }
.rep-val {
  width: 52px; height: 50px; border: 0; border-radius: 14px; background: var(--card); min-width: 0;
  text-align: center; font-family: var(--font-display); font-size: 28px; font-weight: 700;
  -moz-appearance: textfield; appearance: textfield;
}
.rep-val::-webkit-inner-spin-button, .rep-val::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }
.photo-btn {
  display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; height: 56px;
  border-radius: 16px; border: 3px dashed var(--kid); background: var(--kid-soft); font-weight: 800;
}
.thumbs { display: flex; flex-wrap: wrap; gap: 10px; }
.thumb { position: relative; }
.thumb img { width: 84px; height: 84px; border-radius: 14px; object-fit: cover; background: var(--soft); }
.thumb .del {
  position: absolute; top: -8px; right: -8px; width: 30px; height: 30px; border-radius: 50%;
  background: var(--bad); color: #fff; font-weight: 800; font-size: 16px; box-shadow: 0 2px 0 rgba(0,0,0,.2);
}
.subject { background: var(--soft); border-radius: 16px; padding: 12px; display: grid; gap: 10px; }
.subject .sname { font-weight: 800; font-size: 18px; }

/* ---------- semana ---------- */
.day {
  display: flex; align-items: center; gap: 12px; background: var(--card);
  border: 3px solid var(--line); border-radius: 18px; padding: 12px 14px;
}
.day.today { border-color: var(--kid); }
.day .dname { font-family: var(--font-display); font-weight: 800; font-size: 19px; }
.day .money { text-align: right; }
.day .money b { font-family: var(--font-display); font-size: 21px; display: block; }

/* ---------- panel de papá ---------- */
.admin { max-width: 760px; }
.admin .topbar { background: var(--card); border-bottom: 2px solid var(--line); }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; }
.kidcard {
  text-align: left; background: var(--kid-soft); border: 3px solid transparent; border-radius: 18px; padding: 12px;
}
.kidcard.on { border-color: var(--kid); box-shadow: var(--pop); }
.kidcard .n { font-family: var(--font-display); font-weight: 800; font-size: 19px; }
.kidcard .e { font-family: var(--font-display); font-weight: 800; font-size: 26px; }
.weeknav { display: flex; align-items: center; gap: 8px; }
.weeknav .lbl { flex: 1; text-align: center; font-weight: 800; }
.weeknav button { width: 46px; height: 46px; border-radius: 14px; background: var(--card); border: 2px solid var(--line); font-size: 22px; font-weight: 800; }

.grid { width: 100%; border-collapse: separate; border-spacing: 4px; table-layout: fixed; }
.grid th { font-size: 22px; font-weight: 400; padding: 2px 0; }
.grid th.d, .grid td.d { width: 46px; font-weight: 800; font-size: 15px; text-align: left; }
.grid th.m, .grid td.m { width: 64px; text-align: right; font-weight: 800; font-size: 14px; }
.cell {
  width: 100%; height: 44px; border-radius: 12px; display: grid; place-items: center;
  font-weight: 800; font-size: 18px; background: var(--soft); color: var(--muted);
}
.cell.ok { background: var(--ok-soft); color: var(--ok); }
.cell.val { background: var(--ok); color: #fff; }
.cell.bad { background: var(--bad); color: #fff; }
.cell.miss { background: var(--bad-soft); color: var(--bad); }
.cell.na { background: transparent; color: var(--line); }
.cell.fut { background: transparent; border: 2px dashed var(--line); }
.cell .cam { font-size: 11px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; font-weight: 700; color: var(--muted); }
.legend span::before { content: ""; display: inline-block; width: 12px; height: 12px; border-radius: 4px; margin-right: 5px; vertical-align: -1px; background: var(--c); }
.zero td { opacity: .55; }

.big-photo { width: 100%; border-radius: 16px; background: var(--soft); }
textarea, .field input, .field select {
  width: 100%; border: 2px solid var(--line); border-radius: 14px; background: var(--bg); padding: 12px;
}
textarea { min-height: 80px; resize: vertical; }
.field { display: grid; gap: 6px; font-weight: 800; font-size: 15px; }
.field input, .field select { height: 50px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.swatches { display: flex; gap: 10px; }
.swatch { width: 44px; height: 44px; border-radius: 50%; background: var(--kid); border: 4px solid transparent; }
.swatch.on { border-color: var(--ink); }
.toggle { display: flex; align-items: center; gap: 10px; font-weight: 800; }
.toggle input { width: 26px; height: 26px; accent-color: var(--ok); }

.section { background: var(--card); border: 2px solid var(--line); border-radius: 22px; padding: 16px; display: grid; gap: 14px; }
.section h2 { font-size: 23px; }
.listrow { display: flex; align-items: center; gap: 12px; padding: 8px 0; border-top: 2px solid var(--soft); }
.listrow:first-of-type { border-top: 0; }
.wd { display: grid; grid-template-columns: 34px 1fr; gap: 8px; align-items: center; }
.wd b { font-family: var(--font-display); font-size: 18px; }
.wd input { height: 46px; }
.rot { width: 100%; border-collapse: collapse; }
.rot th, .rot td { padding: 6px 4px; text-align: left; font-size: 14px; }
.rot td select { width: 100%; height: 42px; border-radius: 12px; border: 2px solid var(--line); background: var(--bg); padding: 0 2px; font-size: 13px; font-weight: 700; }
.rot th { font-size: 13px; }
.rot td:first-child { width: 44px; font-weight: 800; }
.rot td select.ov { border-color: var(--primary); }

/* ---------- varios ---------- */
#toast {
  position: fixed; left: 50%; top: calc(14px + env(safe-area-inset-top)); transform: translate(-50%, -150%);
  z-index: 100; background: var(--ink); color: #fff; font-weight: 800; padding: 12px 18px; border-radius: 14px;
  transition: transform .25s; max-width: 90vw; text-align: center;
}
#toast.show { transform: translate(-50%, 0); }
#toast.bad { background: var(--bad); }
#toast.ok { background: var(--ok); }
.lightbox { position: fixed; inset: 0; z-index: 80; background: rgba(0,0,0,.9); display: grid; place-items: center; padding: 12px; }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 10px; }
.spinner { padding: 60px 0; text-align: center; color: var(--muted); font-weight: 800; }
.empty { text-align: center; color: var(--muted); padding: 24px 8px; font-weight: 700; }

/* ---------- hucha ---------- */
.score .label { font-weight: 800; font-size: 15px; margin-bottom: 4px; }
.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.admin-tiles { grid-template-columns: repeat(3, 1fr); margin-top: 0; }
.tile { background: rgba(255, 255, 255, .78); border-radius: 16px; padding: 10px 12px; display: grid; gap: 1px; }
.admin-tiles .tile { background: var(--kid-soft); }
.tile span { font-size: 13px; font-weight: 800; color: var(--muted); }
.tile b { font-family: var(--font-display); font-size: 24px; line-height: 1.15; }
.tile small { font-size: 13px; font-weight: 700; }
.bigsum { font-family: var(--font-display); font-size: 24px; }
.mov { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 2px solid var(--soft); }
.mov:first-of-type { border-top: 0; }
.mov-ico { font-size: 24px; }
.amt { font-family: var(--font-display); font-size: 19px; white-space: nowrap; }
.amt.pos { color: var(--ok); }
.amt.neg { color: var(--bad); }
.mini-del { width: 32px; height: 32px; border-radius: 50%; background: var(--soft); font-weight: 800; color: var(--muted); flex: none; }
.kidcard .small b { font-size: 15px; }

/* panel en móvil: tres hijos en una fila y sin desbordes */
.cards { grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; }
.kidcard { min-width: 0; padding: 10px; }
.kidcard .n { font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.2px; }
.nowrap { white-space: nowrap; }
.kidcard .e { font-size: 22px; }
.kidcard .small { font-size: 12px; }
.tile { min-width: 0; }
.admin-tiles { gap: 8px; }
.admin-tiles .tile { padding: 8px 10px; }
.admin-tiles .tile b { font-size: clamp(16px, 4.6vw, 24px); }
.section > * { min-width: 0; }

/* que ningún contenido ensanche la columna en móviles estrechos */
.stack, .task { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 359px) {
  .step { width: 40px; }
  .rep-val { width: 44px; font-size: 24px; }
  .chip-q { min-width: 36px; padding: 0 4px; font-size: 14px; }
}

/* ---------- escalada ---------- */
:root { --eff: #e8590c; --feel: #2f6fdb; }
.climb-seg button { height: 52px; font-size: 16px; }
.climb-seg button.on { background: var(--kid); color: var(--ink); }
.scale-block { display: grid; gap: 6px; }
.scale-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.scale-head b { font-size: 17px; }
.scale10 { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
.sc {
  height: 46px; border-radius: 14px; background: var(--soft); border: 2px solid transparent;
  font-family: var(--font-display); font-size: 21px; font-weight: 700; touch-action: manipulation;
}
.sc:active { transform: scale(.94); }
.sc.eff.on { background: var(--eff); color: #fff; }
.sc.feel.on { background: var(--feel); color: #fff; }
.climb-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.climb-stats div { background: var(--soft); border-radius: 14px; padding: 8px 6px; display: grid; text-align: center; }
.climb-stats b { font-family: var(--font-display); font-size: 22px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.climb-stats span { font-size: 11px; font-weight: 800; color: var(--muted); line-height: 1.2; }
.climb-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; font-weight: 800; color: var(--ink); }
.climb-legend .lg::before { content: ""; display: inline-block; width: 14px; height: 3px; border-radius: 2px; margin-right: 6px; vertical-align: 3px; background: var(--c); }
.lg.s-eff { --c: var(--eff); } .lg.s-feel { --c: var(--feel); }
.lg.rest { color: var(--muted); } .lg.rest::before { width: 2px; height: 8px; vertical-align: 0; --c: var(--muted); }
.climb-svg { width: 100%; height: auto; display: block; touch-action: none; }
.climb-svg .grid { stroke: var(--line); stroke-width: 1; }
.climb-svg .tick { fill: var(--muted); font-size: 11px; font-weight: 700; font-family: var(--font); }
.climb-svg .line { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.climb-svg .dot { stroke: var(--card); stroke-width: 2; }
.climb-svg .s-eff.line { stroke: var(--eff); } .climb-svg .s-eff.dot { fill: var(--eff); }
.climb-svg .s-feel.line { stroke: var(--feel); } .climb-svg .s-feel.dot { fill: var(--feel); }
.climb-svg .restmark { stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.climb-svg .guide { stroke: var(--ink); stroke-width: 1; stroke-dasharray: 3 3; }
.climb-readout { min-height: 22px; font-size: 14px; font-weight: 700; text-align: center; color: var(--ink); }
.climb-table summary { font-weight: 800; font-size: 14px; color: var(--muted); cursor: pointer; }
.climb-table table { width: 100%; border-collapse: collapse; margin-top: 6px; font-size: 14px; font-variant-numeric: tabular-nums; }
.climb-table th, .climb-table td { text-align: left; padding: 5px 4px; border-top: 1px solid var(--line); }

/* ---------- ranking ---------- */
.tabbar a { font-size: 17px; gap: 6px; }
.seg3 { grid-template-columns: repeat(3, 1fr); }
.rank-title { font-size: 30px; }
.rank-list { display: grid; gap: 10px; }
.rank-row {
  display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 20px;
  background: var(--card); border: 3px solid var(--line);
}
.rank-row.me { border-color: var(--kid); background: var(--kid-soft); }
.rank-pos { width: 34px; text-align: center; font-family: var(--font-display); font-weight: 800; font-size: 24px; flex: none; }
.rank-name { font-family: var(--font-display); font-weight: 800; font-size: 20px; display: flex; align-items: center; gap: 6px; }
.you { font-family: var(--font); font-size: 12px; font-weight: 800; background: var(--kid); border-radius: 999px; padding: 1px 8px; }
.rank-bar { height: 8px; border-radius: 999px; background: var(--soft); margin-top: 6px; overflow: hidden; }
.rank-bar > div { height: 100%; border-radius: 999px; background: var(--kid); }
.rank-pts { font-family: var(--font-display); font-size: 22px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.rank-pts small { font-family: var(--font); font-size: 13px; color: var(--muted); }

/* ---------- resumen diario ---------- */
.report-btn { background: var(--card); }
.report-text {
  margin: 0; padding: 14px; border-radius: 16px; background: var(--soft); white-space: pre-wrap; word-break: break-word;
  font-family: var(--font); font-size: 15px; line-height: 1.45; max-height: 50vh; overflow: auto;
}
a.btn { text-decoration: none; color: inherit; }
a.btn.ok { color: #fff; }

/* ---------- pestañas de papá y línea de tiempo ---------- */
.admin-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 10px 20px 0; }
.admin-tabs a {
  display: flex; align-items: center; justify-content: center; height: 46px; border-radius: 14px;
  background: var(--soft); color: var(--ink); text-decoration: none; font-weight: 800;
}
.admin-tabs a.on { background: var(--ink); color: #fff; }
.timeline { display: grid; gap: 14px; position: relative; padding-left: 18px; }
.timeline::before { content: ""; position: absolute; left: 5px; top: 8px; bottom: 8px; width: 3px; border-radius: 2px; background: var(--line); }
.tl-day {
  position: relative; display: grid; gap: 10px; min-width: 0;
  background: var(--card); border: 2px solid var(--line); border-radius: 20px; padding: 14px;
}
.tl-day::before {
  content: ""; position: absolute; left: -19px; top: 18px; width: 13px; height: 13px; border-radius: 50%;
  background: var(--card); border: 3px solid var(--primary);
}
.tl-day.sent::before { background: var(--ok); border-color: var(--ok); }
.tl-head { display: flex; align-items: center; gap: 8px; }
.tl-when { font-family: var(--font-display); font-size: 21px; text-transform: capitalize; }
.tl-date { color: var(--muted); font-weight: 800; }
.copied { font-size: 13px; font-weight: 800; color: var(--ok); background: var(--ok-soft); border-radius: 999px; padding: 3px 10px; }
.tl-kids { display: grid; gap: 10px; }
.tl-kid { display: flex; align-items: center; gap: 10px; min-width: 0; }
.tl-emoji { font-size: 26px; flex: none; }
.tl-name { font-weight: 800; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.tl-tag { font-size: 11px; font-weight: 800; border-radius: 999px; padding: 1px 8px; }
.tl-tag.ok { background: var(--ok-soft); color: #18663b; }
.tl-tag.bad { background: var(--bad-soft); color: var(--bad); }
.tl-bar { height: 7px; border-radius: 999px; background: var(--soft); margin: 5px 0 3px; overflow: hidden; }
.tl-bar > div { height: 100%; border-radius: 999px; background: var(--primary); }
.tl-bar > div.full { background: var(--ok); }
.tl-bar > div.zero { background: var(--bad); opacity: .5; }
.tl-meta { font-size: 13px; font-weight: 700; color: var(--muted); }
.tl-money { text-align: right; display: grid; flex: none; }
.tl-money b { font-family: var(--font-display); font-size: 18px; font-variant-numeric: tabular-nums; }
.tl-money span { font-size: 12px; font-weight: 800; color: var(--muted); }
.tl-text summary { font-weight: 800; font-size: 14px; color: var(--muted); cursor: pointer; }
.tl-text .report-text { margin-top: 8px; font-size: 14px; }
.tl-tag.wait { background: var(--warn); color: var(--warn-ink); }

/* ---------- envío automático ---------- */
.channel { display: grid; gap: 8px; padding: 12px; border-radius: 16px; background: var(--soft); }
.channel .field input { background: var(--card); }
.channel details summary { cursor: pointer; }
input[type="time"] { font-family: var(--font-display); font-size: 20px; }

/* ---------- podio en la cabecera de papá ---------- */
.podium-head { display: grid; gap: 8px; padding: 12px 20px 2px; background: var(--card); border-bottom: 2px solid var(--line); }
.podium-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.podium-top > b { font-family: var(--font-display); font-size: 20px; white-space: nowrap; }
.seg.mini { gap: 4px; flex: 1; max-width: 250px; }
.seg.mini button { height: 32px; border-radius: 10px; font-size: 13px; }
.podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; align-items: end; padding-bottom: 10px; }
.pod {
  display: grid; justify-items: center; gap: 1px; min-width: 0; text-align: center;
  background: var(--kid-soft); border-radius: 16px 16px 8px 8px; padding: 8px 6px;
  border-bottom: 5px solid var(--kid);
}
.pod.p1 { padding-top: 14px; padding-bottom: 14px; }
.pod.p3 { padding-top: 4px; }
.pod-medal { font-size: 20px; line-height: 1; }
.pod-emoji { font-size: 24px; line-height: 1.1; }
.pod.p1 .pod-emoji { font-size: 30px; }
.pod-name { font-weight: 800; font-size: 14px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pod-pts { font-family: var(--font-display); font-size: 16px; font-variant-numeric: tabular-nums; }
.admin-tabs { padding-top: 12px; }
