/* Carrera Tech — panel claro con color por área */

:root {
  --paper: #F4F6FB;
  --paper-line: #E8ECF4;
  --card: #FFFFFF;
  --line: #E3E7F0;
  --line-2: #EEF1F7;
  --ink: #12141C;
  --ink-2: #4A5163;
  --ink-3: #8A90A2;

  --web: #2D6BFF;
  --ing: #F97316;
  --rep: #8B5CF6;
  --log: #10B981;
  --mat: #F43F7A;
  --xp: #FFB800;
  --fuego: #FF5A36;

  --display: "Bricolage Grotesque", "Inter", system-ui, sans-serif;
  --body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Consolas, monospace;

  --r: 22px;
  --r-sm: 14px;
  --shadow: 0 1px 2px rgba(18, 20, 28, .04), 0 8px 24px -12px rgba(18, 20, 28, .12);
  --shadow-lift: 0 2px 4px rgba(18, 20, 28, .05), 0 16px 32px -14px rgba(18, 20, 28, .22);
  --side-w: 248px;
  --bn-h: 68px;
  --safe-b: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    linear-gradient(var(--paper-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--paper-line) 1px, transparent 1px);
  background-size: 24px 24px;
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
h1, h2, h3 { font-family: var(--display); margin: 0; letter-spacing: -0.02em; line-height: 1.1; }
p { margin: 0; }
a { color: inherit; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--c, var(--web)) 55%, transparent); outline-offset: 2px; border-radius: 10px; }
[hidden] { display: none !important; }

.muted { color: var(--ink-2); font-size: 14px; }
.hint { color: var(--ink-3); font-size: 12.5px; margin-top: 10px; }
.eyebrow { font-family: var(--mono); font-size: 11.5px; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 8px; }
.eyebrow b { color: var(--ink-2); font-weight: 600; }

/* ---------- estructura ---------- */
.app { min-height: 100vh; }
.main {
  padding: 28px 40px 60px;
  margin-left: var(--side-w);
  max-width: calc(1180px + var(--side-w));
}
.view { display: none; }
.view.active { display: block; animation: aparecer .28s ease-out; }
.view > * + * { margin-top: 18px; }
@keyframes aparecer { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- marca ---------- */
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { display: grid; grid-template-columns: repeat(2, 9px); gap: 3px; transform: rotate(-8deg); }
.brand-mark i { width: 9px; height: 9px; border-radius: 3px; }
.brand-mark i:nth-child(1) { background: var(--web); }
.brand-mark i:nth-child(2) { background: var(--ing); }
.brand-mark i:nth-child(3) { background: var(--rep); }
.brand-mark i:nth-child(4) { background: var(--log); }
.brand-name { font-family: var(--display); font-size: 19px; font-weight: 600; letter-spacing: -0.02em; }
.brand-name b { font-weight: 800; }

/* ---------- menú lateral ---------- */
.side {
  position: fixed; inset: 0 auto 0 0; width: var(--side-w);
  display: flex; flex-direction: column; gap: 22px;
  padding: 26px 16px 18px;
  background: rgba(255, 255, 255, .78);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-right: 1px solid var(--line);
  z-index: 20;
}
.side .brand { padding: 0 10px; }
.side-nav { display: flex; flex-direction: column; gap: 2px; overflow-y: auto; }
.nav-btn {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border: 0; border-radius: 12px;
  background: transparent; color: var(--ink-2);
  font-size: 14.5px; font-weight: 500; text-align: left;
  transition: background .15s, color .15s;
}
.nav-btn svg { color: var(--ink-3); transition: color .15s; }
.nav-btn:hover { background: var(--line-2); color: var(--ink); }
.nav-btn.active { background: color-mix(in srgb, var(--c) 11%, white); color: var(--ink); font-weight: 600; }
.nav-btn.active svg { color: var(--c); }
.nav-badge {
  margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px;
  border-radius: 99px; background: var(--rep); color: #fff;
  font: 600 11px/20px var(--mono); text-align: center;
}

.side-level {
  margin-top: auto;
  padding: 14px; border-radius: 18px;
  background: var(--ink); color: #fff;
}
.sl-top { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.sl-top b { display: block; font-family: var(--display); font-size: 16px; font-weight: 700; }
.sl-top small { display: block; font-family: var(--mono); font-size: 11.5px; color: rgba(255,255,255,.6); }
.sl-badge {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 12px;
  background: var(--xp); color: var(--ink);
  font: 800 18px/1 var(--display);
}
.sl-next { display: block; margin-top: 8px; font-family: var(--mono); font-size: 11px; color: rgba(255,255,255,.6); }

/* ---------- barras ---------- */
.bar { height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.bar i { display: block; height: 100%; width: 0; border-radius: inherit; background: var(--c, var(--web)); transition: width .5s cubic-bezier(.2,.8,.2,1); }
.side-level .bar { background: rgba(255,255,255,.14); }
.bar-xp i { background: var(--xp); }

/* ---------- barra de arriba / abajo (celular) ---------- */
.topbar, .bottom-nav, .sheet, .sheet-backdrop { display: none; }

/* ---------- tarjetas ---------- */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 22px;
  box-shadow: var(--shadow);
  min-width: 0;
}
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.card-head h2 { font-size: 19px; font-weight: 700; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 99px;
  background: var(--line-2); color: var(--ink-2);
  font: 600 11.5px/1.4 var(--mono); white-space: nowrap;
}
.chip-solid { background: var(--c, var(--ink)); color: #fff; }
.tag {
  display: inline-flex; align-items: center; padding: 3px 9px; border-radius: 8px;
  background: var(--line-2); color: var(--ink-2);
  font: 500 11.5px/1.4 var(--mono); white-space: nowrap;
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.grid-wide-left { grid-template-columns: 1.25fr 1fr; }
.grid-even > .card { height: 100%; }
.grid-even { align-items: stretch; }
.stack { display: flex; flex-direction: column; gap: 18px; min-width: 0; }

/* ---------- botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 42px; padding: 0 16px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--card); color: var(--ink);
  font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: transform .12s, background .15s, border-color .15s, box-shadow .15s;
}
.btn:hover { border-color: #CBD2E0; }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: default; transform: none; }
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--c, var(--web)); border-color: transparent; color: #fff; box-shadow: 0 6px 16px -8px var(--c, var(--web)); }
.btn-primary:hover { border-color: transparent; filter: brightness(1.06); }
.btn-ink { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-ink:hover { border-color: var(--ink); background: #252836; }
.btn-icon { width: 42px; padding: 0; }
.btn-sm { min-height: 34px; padding: 0 12px; font-size: 13px; border-radius: 10px; }
.btn-lg { min-height: 50px; padding: 0 22px; font-size: 15px; border-radius: 14px; }
.btn-danger { background: #FFF1F2; border-color: #FECDD3; color: #BE123C; }
.btn-danger:hover { border-color: #FDA4AF; }

.seg { display: inline-flex; padding: 3px; gap: 2px; border-radius: 12px; background: var(--line-2); flex-wrap: wrap; }
.seg button {
  border: 0; background: transparent; color: var(--ink-2);
  padding: 7px 12px; border-radius: 9px; font-size: 13px; font-weight: 600;
  transition: background .15s, color .15s;
}
.seg button.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(18,20,28,.12); }
.seg-sm button { padding: 5px 10px; font-size: 12px; font-family: var(--mono); }

/* ---------- HOY: tarjeta principal ---------- */
.hero {
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas: "text ring" "pills ring";
  gap: 18px 28px; align-items: center;
  padding: 28px 30px;
  position: relative; overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 5px;
  background: linear-gradient(90deg, var(--web) 0 25%, var(--ing) 25% 50%, var(--rep) 50% 75%, var(--log) 75%);
}
.hero-text { grid-area: text; min-width: 0; }
.hero h1 { font-size: clamp(30px, 4.2vw, 46px); font-weight: 800; letter-spacing: -0.035em; }
.hero-sub { margin-top: 8px; color: var(--ink-2); font-size: 16px; max-width: 46ch; }
.hero-pills { grid-area: pills; display: flex; flex-wrap: wrap; gap: 8px; }
.hp {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 12px 7px 9px; border-radius: 99px;
  background: var(--line-2); color: var(--ink-2); font-size: 13px;
}
.hp b { font-family: var(--mono); font-weight: 700; color: var(--ink); }
.hp svg { width: 17px; height: 17px; }
.hp-fuego svg { color: var(--fuego); fill: color-mix(in srgb, var(--fuego) 25%, transparent); }
.hp-xp svg { color: #E0A100; fill: color-mix(in srgb, var(--xp) 45%, transparent); }
.hp-reloj svg { color: var(--web); }

.ring-wrap { grid-area: ring; position: relative; width: 196px; height: 196px; }
.ring { width: 100%; height: 100%; display: block; overflow: visible; }
.ring .seg-bg { stroke-opacity: .16; }
.ring .seg-fill { stroke-dashoffset: 0; transition: stroke-opacity .35s; }
.ring-center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring-center b { font: 800 44px/1 var(--display); letter-spacing: -0.04em; }
.ring-center small { margin-top: 4px; font-family: var(--mono); font-size: 11px; color: var(--ink-3); }
.ring-wrap.full .ring-center b { color: var(--log); }
.ring-wrap.full::after {
  content: "CUMPLIDO"; position: absolute; left: 50%; bottom: -4px; transform: translateX(-50%) rotate(-4deg);
  padding: 3px 10px; border-radius: 8px; background: var(--log); color: #fff;
  font: 700 11px/1.4 var(--mono); letter-spacing: .06em;
}

/* ---------- HOY: grilla ---------- */
.home-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: 18px; align-items: start; }

.checklist { display: flex; flex-direction: column; gap: 8px; }
.check {
  display: grid; grid-template-columns: 34px 1fr auto; align-items: center; gap: 12px;
  width: 100%; padding: 12px 14px 12px 12px; text-align: left;
  border: 1px solid var(--line); border-radius: 16px; background: var(--card);
  position: relative; overflow: hidden;
  transition: background .2s, border-color .2s, transform .12s;
}
.check::before { content: ""; position: absolute; left: 0; top: 10px; bottom: 10px; width: 4px; border-radius: 0 4px 4px 0; background: var(--c); }
.check:hover { border-color: color-mix(in srgb, var(--c) 45%, var(--line)); }
.check:active { transform: scale(.985); }
.check-box {
  display: grid; place-items: center; width: 30px; height: 30px; border-radius: 10px;
  border: 2px solid color-mix(in srgb, var(--c) 40%, var(--line)); color: #fff;
  transition: background .2s, border-color .2s;
}
.check-box svg { width: 18px; height: 18px; stroke-width: 3; opacity: 0; transform: scale(.5); transition: opacity .2s, transform .25s cubic-bezier(.3,1.6,.5,1); }
.check-body { min-width: 0; }
.check-body b { display: block; font-size: 15px; font-weight: 600; }
.check-body small { display: block; color: var(--ink-3); font-size: 12.5px; line-height: 1.35; }
.check-min { font: 500 11.5px/1 var(--mono); color: var(--ink-3); white-space: nowrap; }
.check.on { background: color-mix(in srgb, var(--c) 8%, white); border-color: color-mix(in srgb, var(--c) 35%, white); }
.check.on .check-box { background: var(--c); border-color: var(--c); }
.check.on .check-box svg { opacity: 1; transform: none; }
.check.on .check-body b { color: var(--ink); }
.check.on .check-min { color: var(--c); font-weight: 700; }

.day-foot { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--line); }
.goal-line { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; margin-bottom: 8px; font-size: 13.5px; color: var(--ink-2); }
.goal-line b { font-family: var(--mono); font-size: 13px; color: var(--ink); }
.bar-goal { height: 10px; }
.bar-goal i { background: linear-gradient(90deg, var(--web), var(--rep)); }
.bar-goal.met i { background: var(--log); }

/* Ahora mismo */
.card-next { --c: var(--web); }
.next-title { font: 700 21px/1.2 var(--display); letter-spacing: -0.02em; margin-bottom: 10px; }
.next-meta { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 14px; }
.next-meta .tag-pct { background: var(--c); color: #fff; font-weight: 700; }
.next-note { color: var(--ink-2); font-size: 13.5px; margin-top: 12px; }
.yesterday {
  display: flex; gap: 10px; margin-top: 16px; padding: 12px 14px; border-radius: 14px;
  background: color-mix(in srgb, var(--log) 9%, white); border: 1px solid color-mix(in srgb, var(--log) 25%, white);
}
.yesterday svg { color: var(--log); width: 18px; height: 18px; margin-top: 2px; }
.yesterday small { display: block; font: 600 11px/1.4 var(--mono); text-transform: uppercase; letter-spacing: .04em; color: #0B8A60; }
.yesterday p { font-size: 14px; color: var(--ink); }
.next-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 16px; flex-wrap: wrap; }
.next-foot small { color: var(--ink-3); font-size: 12.5px; }

/* Enfoque */
.card-focus { --c: var(--rep); }
.focus { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.focus-time { font: 600 46px/1 var(--mono); letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.focus-actions { display: flex; gap: 8px; }
.card-focus.running .focus-time { color: var(--rep); }
.card-focus.resting { --c: var(--log); }
.card-focus.resting .focus-time { color: var(--log); }
.bar-focus i { transition: width 1s linear; }

/* Constancia */
.heat-wrap { display: flex; gap: 8px; }
.heat-days { display: grid; grid-template-rows: repeat(7, 1fr); gap: 4px; font: 500 10px/1 var(--mono); color: var(--ink-3); }
.heat-days span { display: flex; align-items: center; }
.heat {
  flex: 1; min-width: 0;
  display: grid; grid-template-rows: repeat(7, auto); grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr);
  gap: 4px;
}
.hc { aspect-ratio: 1; border-radius: 4px; background: var(--line-2); max-width: 22px; }
.hc.l1 { background: #C9F2E1; }
.hc.l2 { background: #86E3BE; }
.hc.l3 { background: #34C88E; }
.hc.l4 { background: #0B9E68; }
.hc.pre { opacity: .45; }
.hc.future { background: transparent; }
.hc.today { outline: 2px solid var(--ink); outline-offset: 1px; }
.heat-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 14px; flex-wrap: wrap; font-size: 12.5px; }
.heat-legend { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); font-family: var(--mono); font-size: 11px; }
.heat-legend i { width: 11px; height: 11px; border-radius: 3px; background: var(--line-2); }
.heat-legend .l1 { background: #C9F2E1; } .heat-legend .l2 { background: #86E3BE; }
.heat-legend .l3 { background: #34C88E; } .heat-legend .l4 { background: #0B9E68; }

/* Logros */
.logros { display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 14px 10px; }
.medal { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; min-width: 0; }
.medal-ico {
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: 50%;
  background: var(--line-2); color: var(--ink-3);
  font: 700 13px/1 var(--mono); letter-spacing: -0.03em;
  border: 2px dashed #D6DBE6;
}
.medal b { font-size: 12.5px; font-weight: 600; line-height: 1.2; color: var(--ink-2); }
.medal small { font-size: 11px; color: var(--ink-3); line-height: 1.25; }
.medal-bar { width: 44px; height: 4px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-top: 2px; }
.medal-bar i { display: block; height: 100%; background: var(--ink-3); border-radius: inherit; }
.medal.on .medal-ico {
  border: 0; color: #fff; background: var(--c);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--c) 18%, white), 0 8px 16px -8px var(--c);
}
.medal.on b { color: var(--ink); }

/* ---------- encabezado de cada vista ---------- */
.view-head { padding: 6px 2px 4px; }
.view-head h1 { font-size: clamp(32px, 4.5vw, 48px); font-weight: 800; letter-spacing: -0.04em; position: relative; display: inline-block; }
.view-head h1::after {
  content: ""; position: absolute; left: -4px; right: -6px; bottom: 4px; height: 12px; z-index: -1;
  background: color-mix(in srgb, var(--c) 28%, transparent); border-radius: 4px; transform: rotate(-1deg);
}
.view-head h1 { z-index: 0; isolation: isolate; }
.view-head p:not(.eyebrow) { margin-top: 8px; color: var(--ink-2); max-width: 62ch; }
.view-head .eyebrow { color: color-mix(in srgb, var(--c) 80%, var(--ink)); }

/* ---------- formularios ---------- */
.field { display: block; margin-top: 16px; }
.field > span, .mini-label { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.mini-label { margin-top: 18px; }
input[type=text], input[type=number], input[type=date], input[type=search], input[type=url], textarea, select {
  width: 100%; padding: 11px 13px; border-radius: 12px;
  border: 1px solid var(--line); background: #FBFCFE;
  font-size: 15px; transition: border-color .15s, box-shadow .15s, background .15s;
}
input:focus, textarea:focus, select:focus {
  outline: none; background: #fff;
  border-color: var(--c, var(--web));
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--c, var(--web)) 15%, transparent);
}
textarea { resize: vertical; min-height: 64px; line-height: 1.45; }
.date-input { width: auto; padding: 7px 10px; font-family: var(--mono); font-size: 13px; }
input[type=range] { width: 100%; accent-color: var(--c, var(--web)); height: 28px; margin: 0; }

.counters { display: grid; grid-template-columns: 1fr; gap: 12px; }
.counter { padding: 12px; border-radius: 16px; background: var(--line-2); }
.counter > span { display: block; font-size: 12.5px; font-weight: 600; color: var(--ink-2); margin-bottom: 8px; }
.stepper { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.stepper button {
  width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--card); font-size: 20px; font-weight: 600; line-height: 1; color: var(--ink);
}
.stepper button:active { transform: scale(.94); }
.stepper b { font: 700 28px/1 var(--display); min-width: 2ch; text-align: center; }

.range-row { margin-top: 16px; }
.range-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 4px; font-size: 13px; font-weight: 600; color: var(--ink-2); }
.range-top b { font-family: var(--mono); color: var(--ink); }
.quick { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.quick button {
  padding: 5px 11px; border-radius: 99px; border: 1px solid var(--line); background: var(--card);
  font: 600 12px/1.4 var(--mono); color: var(--ink-2);
}
.quick button.on { background: var(--c); border-color: var(--c); color: #fff; }

.routine-edit { display: flex; flex-wrap: wrap; gap: 6px; }
.re-item {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 12px 7px 9px; border-radius: 99px;
  border: 1px solid var(--line); background: var(--card); font-size: 13px; font-weight: 500; color: var(--ink-2);
}
.re-item i { width: 10px; height: 10px; border-radius: 50%; border: 2px solid var(--rc); }
.re-item.on { background: color-mix(in srgb, var(--rc) 12%, white); border-color: color-mix(in srgb, var(--rc) 40%, white); color: var(--ink); }
.re-item.on i { background: var(--rc); }

.two-fields { display: grid; grid-template-columns: 1.4fr 1fr; gap: 12px; align-items: start; }
.two-fields .field { margin-top: 16px; }
.seg-energy { display: flex; width: 100%; }
.seg-energy button { flex: 1; padding: 9px 0; font-family: var(--mono); }
.seg-energy button.on { background: var(--c); color: #fff; }
.energy-word { display: block; margin-top: 6px; font-size: 12px; color: var(--ink-3); }

.form-actions { display: flex; align-items: center; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
.saved-note { font-size: 12.5px; color: var(--ink-3); font-family: var(--mono); }

/* Historial */
.history { display: flex; flex-direction: column; gap: 8px; max-height: 720px; overflow-y: auto; margin: 0 -6px; padding: 0 6px; }
.h-item {
  padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line); background: var(--card);
  cursor: pointer; transition: border-color .15s, background .15s; text-align: left; width: 100%;
}
.h-item:hover { border-color: #CBD2E0; }
.h-item.sel { border-color: var(--c); background: color-mix(in srgb, var(--c) 6%, white); }
.h-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.h-top b { font-family: var(--display); font-size: 15px; }
.h-top small { color: var(--ink-3); font-family: var(--mono); font-size: 11.5px; }
.h-dots { display: inline-flex; gap: 4px; }
.h-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--line); }
.h-dot.on { background: var(--rc); }
.h-item p { margin-top: 6px; font-size: 13.5px; color: var(--ink-2); overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.h-money { color: #0B8A60 !important; font-weight: 700; }
.h-done { color: var(--log); font-family: var(--mono); font-size: 11px; font-weight: 700; }

/* ---------- Apuntes ---------- */
.card-review { border-color: color-mix(in srgb, var(--rep) 30%, var(--line)); }
#review-today { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
#review-today > .muted { grid-column: 1 / -1; }
.review-item {
  display: flex; flex-direction: column; gap: 10px; padding: 16px; border-radius: 18px;
  background: color-mix(in srgb, var(--rep) 7%, white); border: 1px solid color-mix(in srgb, var(--rep) 22%, white);
}
.review-badge { align-self: flex-start; padding: 3px 9px; border-radius: 8px; background: var(--rep); color: #fff; font: 700 11px/1.4 var(--mono); letter-spacing: .04em; }
.review-body b { font-family: var(--display); font-size: 16px; }
.review-body p { font-size: 14px; color: var(--ink-2); margin-top: 4px; }
.review-item .btn { align-self: flex-start; }

.search { margin-bottom: 12px; }
.notes-list { display: flex; flex-direction: column; gap: 10px; max-height: 620px; overflow-y: auto; }
.note-item { padding: 14px; border-radius: 14px; border: 1px solid var(--line); }
.note-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 6px; }
.note-top b { font-family: var(--display); font-size: 15px; }
.note-top small { font: 500 11px/1.4 var(--mono); color: var(--ink-3); }
.note-top small.rep { color: var(--rep); font-weight: 700; }
.note-item p { font-size: 14px; color: var(--ink-2); white-space: pre-line; }
.nota-puntos { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.nota-punto { padding: 4px 10px; border-radius: 99px; background: var(--line-2); font-size: 12px; color: var(--ink-2); }

/* ---------- Inglés ---------- */
.ladder { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; }
.rung {
  position: relative; padding: 14px; border-radius: 18px; min-width: 0;
  background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow);
  text-decoration: none; display: block;
}
.rung-lvl { font: 800 28px/1 var(--display); letter-spacing: -0.03em; color: var(--ink-3); }
.rung-name { display: block; margin-top: 8px; font-size: 13px; font-weight: 600; line-height: 1.25; }
.rung small { display: block; margin-top: 4px; font-size: 11.5px; color: var(--ink-3); font-family: var(--mono); }
.rung-state { position: absolute; top: 12px; right: 12px; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--line); }
.rung-state svg { width: 13px; height: 13px; stroke-width: 3; color: #fff; }
.rung.done { background: color-mix(in srgb, var(--ing) 8%, white); border-color: color-mix(in srgb, var(--ing) 30%, white); }
.rung.done .rung-lvl { color: var(--ing); }
.rung.done .rung-state { background: var(--ing); border-color: var(--ing); }
.rung.now { background: var(--ing); border-color: var(--ing); color: #fff; box-shadow: 0 12px 24px -12px var(--ing); }
.rung.now .rung-lvl { color: #fff; }
.rung.now small { color: rgba(255,255,255,.8); }
.rung.now .rung-state { border-color: #fff; background: rgba(255,255,255,.25); }

.card-stage { border-top: 5px solid var(--ing); }
.stage-title { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
.unlock { margin-top: 14px; padding: 12px 14px; border-radius: 14px; background: color-mix(in srgb, var(--ing) 8%, white); font-size: 14px; }
.unlock b { display: block; font: 600 11px/1.4 var(--mono); text-transform: uppercase; letter-spacing: .04em; color: #C2410C; margin-bottom: 2px; }
.link-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0; }
.link-btn {
  display: inline-flex; align-items: center; gap: 6px; padding: 9px 14px; border-radius: 12px;
  border: 1px solid var(--line); text-decoration: none; font-size: 13.5px; font-weight: 600;
}
.link-btn svg { width: 15px; height: 15px; }
.link-btn:hover { border-color: var(--ing); }
.link-main { background: var(--ink); border-color: var(--ink); color: #fff; }
.link-main:hover { border-color: var(--ink); background: #252836; }
.bar-ing i { background: var(--ing); }
.progress-text { margin: 8px 0 14px; font: 500 12px/1.4 var(--mono); color: var(--ink-3); }

.steps { margin: 0; padding: 0; list-style: none; counter-reset: paso; display: flex; flex-direction: column; gap: 12px; }
.steps li { counter-increment: paso; position: relative; padding-left: 40px; font-size: 14px; color: var(--ink-2); }
.steps li::before {
  content: counter(paso); position: absolute; left: 0; top: -2px;
  width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center;
  background: color-mix(in srgb, var(--c, var(--ink)) 12%, white); color: var(--c, var(--ink));
  font: 700 13px/1 var(--mono);
}
.steps b { color: var(--ink); }

/* ---------- Certificaciones ---------- */
.filters { margin-top: 18px; }
.filters button { padding: 8px 14px; }
.certs-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.cert {
  position: relative; display: flex; flex-direction: column; gap: 10px;
  padding: 18px 18px 16px 22px; border-radius: 20px;
  background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); overflow: hidden; min-width: 0;
}
.cert::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--c); }
.cert.active-cert { border: 2px solid var(--c); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c) 14%, transparent), var(--shadow-lift); }
.cert.hecha { background: color-mix(in srgb, var(--c) 5%, white); }
.cert-top { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.cert-name { font: 700 16.5px/1.25 var(--display); letter-spacing: -0.015em; }
.cert-plat { margin-top: 4px; font: 500 11.5px/1.4 var(--mono); color: var(--ink-3); }
.cert-status { flex: none; padding: 3px 9px; border-radius: 8px; font: 700 11px/1.4 var(--mono); background: var(--line-2); color: var(--ink-3); }
.cert-status.st-curso { background: var(--c); color: #fff; }
.cert-status.st-hecha { background: var(--log); color: #fff; }
.cert-note { font-size: 13.5px; color: var(--ink-2); }
.cert-range { display: flex; align-items: center; gap: 10px; }
.cert-pct { font: 700 13px/1 var(--mono); min-width: 4ch; text-align: right; }
.cert-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; margin-top: 2px; }
.cert-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.cert-link { font-size: 13px; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 4px; color: var(--ink-2); }
.cert-link:hover { color: var(--ink); }
.cert-link svg { width: 15px; height: 15px; }
.cert .btn-on { background: var(--c); border-color: var(--c); color: #fff; }
.cert-here { font: 700 10.5px/1 var(--mono); letter-spacing: .06em; color: var(--c); text-transform: uppercase; }

.links-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; }
.link-card {
  display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 16px;
  border: 1px solid var(--line); text-decoration: none; min-width: 0;
  transition: border-color .15s, transform .12s;
}
.link-card:hover { border-color: var(--lc); transform: translateY(-1px); }
.link-ico {
  flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 12px;
  background: color-mix(in srgb, var(--lc) 12%, white); color: var(--lc);
  font: 700 12px/1 var(--mono); letter-spacing: -0.03em;
}
.link-card b { display: block; font-size: 14px; }
.link-card small { display: block; font-size: 12px; color: var(--ink-3); line-height: 1.3; }

/* ---------- Proyectos ---------- */
.kanban { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; align-items: start; }
.kcol { padding: 12px; border-radius: 20px; background: rgba(255,255,255,.55); border: 1px dashed #D3D9E5; min-width: 0; }
.kcol-head { display: flex; justify-content: space-between; align-items: center; padding: 4px 6px 12px; }
.kcol-head b { display: inline-flex; align-items: center; gap: 8px; font-family: var(--display); font-size: 16px; }
.kcol-head b::before { content: ""; width: 10px; height: 10px; border-radius: 50%; background: var(--kc); }
.kcol-head span { font: 700 12px/1 var(--mono); color: var(--ink-3); }
.kcol-body { display: flex; flex-direction: column; gap: 10px; }
.kcol-body > .muted { padding: 14px 6px; font-size: 13px; color: var(--ink-3); }
.kcard { padding: 14px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); min-width: 0; }
.kcard b { font-family: var(--display); font-size: 15.5px; letter-spacing: -0.01em; }
.kcard p { margin-top: 4px; font-size: 13px; color: var(--ink-2); }
.k-etapa { display: inline-block; margin-top: 10px; padding: 2px 8px; border-radius: 7px; font: 600 11px/1.5 var(--mono); background: color-mix(in srgb, var(--ec) 12%, white); color: var(--ec); }
.seg-k { display: flex; width: 100%; margin-top: 12px; }
.seg-k button { flex: 1; padding: 6px 4px; font-size: 12px; }
.seg-k button.on { background: var(--kc); color: #fff; }
.k-url { display: flex; gap: 6px; margin-top: 10px; }
.k-url input { padding: 8px 10px; font-size: 13px; border-radius: 10px; min-width: 0; }
.k-open { display: inline-flex; align-items: center; gap: 4px; margin-top: 10px; font-size: 13px; font-weight: 600; color: var(--mat); text-decoration: none; word-break: break-all; }
.k-open svg { width: 14px; height: 14px; }

/* ---------- Plan ---------- */
.timeline { position: relative; display: flex; flex-direction: column; gap: 14px; padding-left: 34px; }
.timeline::before { content: ""; position: absolute; left: 15px; top: 20px; bottom: 20px; width: 3px; border-radius: 3px; background: linear-gradient(var(--web), var(--xp), #0EA5E9, var(--rep), #EC4899, var(--log), var(--ing), var(--ink)); opacity: .35; }
.tl-item { position: relative; }
.tl-dot {
  position: absolute; left: -34px; top: 18px; width: 33px; height: 33px; border-radius: 11px;
  display: grid; place-items: center; background: var(--c); color: #fff; font: 700 12px/1 var(--mono);
  box-shadow: 0 0 0 4px var(--paper);
}
.tl-card { padding: 18px 20px; border-radius: 20px; background: var(--card); border: 1px solid var(--line); box-shadow: var(--shadow); }
.tl-item.now .tl-card { border: 2px solid var(--c); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c) 14%, transparent), var(--shadow-lift); }
.tl-item.past .tl-dot::after { content: ""; }
.tl-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; flex-wrap: wrap; }
.tl-top h3 { font-size: 19px; font-weight: 700; }
.tl-top h3 span { display: block; margin-top: 3px; font: 500 11.5px/1.4 var(--mono); color: var(--ink-3); letter-spacing: 0; }
.tl-meta { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.tl-here { padding: 3px 9px; border-radius: 8px; background: var(--c); color: #fff; font: 700 11px/1.4 var(--mono); letter-spacing: .04em; }
.tl-card > p { margin-top: 10px; font-size: 14px; color: var(--ink-2); }
.tl-check { margin-top: 12px; padding: 10px 12px; border-radius: 12px; background: color-mix(in srgb, var(--c) 7%, white); font-size: 13.5px; }
.tl-check b { color: var(--c); }
.tl-bars { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.tl-bar label { display: flex; justify-content: space-between; font: 500 11.5px/1.4 var(--mono); color: var(--ink-3); margin-bottom: 5px; }
.tl-bar .bar { height: 6px; }

/* ---------- Ajustes ---------- */
.sync-estado { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 10px; padding: 6px 12px; border-radius: 999px; background: #E7F8F1; color: #047857; font-size: 13px; font-weight: 600; }
.sync-estado::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--log); }
.sync-estado.err { background: #FFF1EC; color: #B4380F; }
.sync-estado.err::before { background: var(--fuego); }
#sync-link { margin-top: 12px; font-family: var(--mono); font-size: 12.5px; color: var(--ink-2); text-overflow: ellipsis; }
.danger { margin-top: 22px; padding-top: 18px; border-top: 1px dashed var(--line); }
.danger b { display: block; margin-bottom: 4px; color: #BE123C; }
.danger .btn { margin-top: 12px; }

/* ---------- avisos y celebración ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 60;
  max-width: calc(100vw - 32px); padding: 12px 18px; border-radius: 14px;
  background: var(--ink); color: #fff; font-size: 14px; font-weight: 500;
  box-shadow: 0 16px 32px -12px rgba(18,20,28,.45);
  transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  transition: transform .3s cubic-bezier(.2,.9,.3,1.2), opacity .25s;
}
.toast.show { transform: translate(-50%, 0); opacity: 1; }

.celebra { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; pointer-events: none; }
.celebra > span {
  font: 800 clamp(48px, 12vw, 96px)/1 var(--display); letter-spacing: -0.04em;
  padding: 10px 28px 14px; border-radius: 22px;
  background: var(--xp); color: var(--ink);
  border: 4px solid var(--ink); box-shadow: 8px 8px 0 var(--ink);
  transform: rotate(-6deg) scale(.4); opacity: 0;
}
.celebra.show > span { animation: sello 1.3s cubic-bezier(.2,1.4,.4,1) forwards; }
@keyframes sello {
  0% { opacity: 0; transform: rotate(-14deg) scale(.4); }
  18% { opacity: 1; transform: rotate(-6deg) scale(1.08); }
  30% { transform: rotate(-6deg) scale(1); }
  80% { opacity: 1; transform: rotate(-6deg) scale(1); }
  100% { opacity: 0; transform: rotate(-6deg) scale(.96) translateY(-10px); }
}
.confeti { position: absolute; left: 50%; top: 50%; width: 10px; height: 14px; border-radius: 3px; opacity: 0; }
.celebra.show .confeti { animation: confeti 1.1s ease-out forwards; animation-delay: var(--d, 0s); }
@keyframes confeti {
  0% { opacity: 1; transform: translate(-50%, -50%) rotate(0); }
  100% { opacity: 0; transform: translate(calc(-50% + var(--x)), calc(-50% + var(--y))) rotate(var(--r)); }
}

/* ---------- Clientes ---------- */
.cli-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.cli-stat { border-top: 4px solid var(--kc); min-width: 0; }
.cli-stat small { display: block; font: 700 11px/1.4 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.cli-stat b { display: block; margin-top: 6px; font-family: var(--display); font-size: 30px; line-height: 1.1; letter-spacing: -0.02em; color: var(--ink); overflow-wrap: anywhere; }
.cli-guia { --c: var(--log); }
.cli-guia .muted { margin-top: 14px; font-size: 13px; }
.ckanban { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.ckanban.is-empty { display: block; }
.cli-card { border-left: 4px solid var(--kc); }
.cli-card b, .cli-card p { overflow-wrap: anywhere; }
.cli-contacto { font: 500 12px/1.5 var(--mono); color: var(--ink-3) !important; }
.cli-valor { display: inline-block; margin-top: 8px; padding: 2px 8px; border-radius: 7px; font: 700 12px/1.5 var(--mono); background: color-mix(in srgb, var(--kc) 14%, white); color: var(--ink); }
.cli-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }

/* ---------- Revisión de la semana y repaso activo ---------- */
.card-semana { border-top: 4px solid var(--rep); }
.sem-nums { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.sem-nums div { padding: 12px; border-radius: 14px; background: color-mix(in srgb, var(--rep) 7%, white); min-width: 0; }
.sem-nums b { display: block; font-family: var(--display); font-size: 24px; line-height: 1.1; }
.sem-nums small { display: block; margin-top: 2px; font-size: 12px; color: var(--ink-3); }
.sem-campos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 14px; margin-bottom: 16px; }
.sem-ok { display: flex; align-items: center; gap: 8px; margin-top: 14px; font-weight: 600; color: var(--ink-2); }
.sem-ok svg { width: 20px; height: 20px; flex: none; color: var(--log); }
.review-pista { font-style: italic; }
.review-oculto .nota-puntos { margin-top: 0; }
.review-oculto > p { font-size: 14px; color: var(--ink-2); }
.review-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.card-ia { --c: var(--ink); }
.card-ia .muted { margin-top: 14px; font-size: 13px; }
.card-ia a { color: var(--web); font-weight: 600; }

/* ---------- tablet ---------- */
@media (max-width: 1180px) {
  .main { padding: 24px 28px 56px; }
  .ladder { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .rung-name { font-size: 12px; }
  .ckanban { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* ---------- celular ---------- */
@media (max-width: 899px) {
  .side { display: none; }
  .main { margin-left: 0; padding: 14px 16px calc(var(--bn-h) + var(--safe-b) + 28px); }

  .topbar {
    display: flex; align-items: center; justify-content: space-between; gap: 10px;
    position: sticky; top: 0; z-index: 30;
    padding: 12px 16px; padding-top: calc(12px + env(safe-area-inset-top, 0px));
    background: rgba(244, 246, 251, .86);
    backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border-bottom: 1px solid transparent; transition: border-color .2s;
  }
  .topbar.scrolled { border-bottom-color: var(--line); }
  .top-pills { display: flex; gap: 6px; }
  .pill {
    display: inline-flex; align-items: center; gap: 5px; padding: 5px 10px 5px 8px; border-radius: 99px;
    background: var(--card); border: 1px solid var(--line); font: 700 13px/1 var(--mono);
  }
  .pill svg { width: 15px; height: 15px; }
  .pill-fuego svg { color: var(--fuego); fill: color-mix(in srgb, var(--fuego) 25%, transparent); }
  .pill-xp svg { color: #E0A100; fill: color-mix(in srgb, var(--xp) 45%, transparent); }

  .bottom-nav {
    display: grid; grid-template-columns: repeat(5, 1fr);
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    height: calc(var(--bn-h) + var(--safe-b)); padding: 6px 6px var(--safe-b);
    background: rgba(255, 255, 255, .92);
    backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--line);
  }
  .bn {
    position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
    border: 0; background: transparent; color: var(--ink-3);
    font-size: 11px; font-weight: 600; border-radius: 14px;
  }
  .bn svg { width: 23px; height: 23px; transition: transform .2s; }
  .bn.active { color: var(--ink); }
  .bn.active svg { color: var(--c); transform: translateY(-1px); }
  .bn.active::before { content: ""; position: absolute; top: 0; width: 22px; height: 3px; border-radius: 0 0 3px 3px; background: var(--c); }
  .bn-dot { position: absolute; top: 8px; left: calc(50% + 8px); width: 9px; height: 9px; border-radius: 50%; background: var(--rep); border: 2px solid #fff; }

  .sheet-backdrop {
    display: block; position: fixed; inset: 0; z-index: 45; background: rgba(18, 20, 28, .32);
    opacity: 0; pointer-events: none; transition: opacity .25s;
  }
  .sheet {
    display: flex; flex-direction: column; gap: 6px;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
    padding: 10px 14px calc(18px + var(--safe-b));
    background: var(--card); border-radius: 26px 26px 0 0;
    box-shadow: 0 -16px 40px -12px rgba(18,20,28,.3);
    transform: translateY(105%); transition: transform .32s cubic-bezier(.2,.9,.3,1);
  }
  body.sheet-open .sheet { transform: none; }
  body.sheet-open .sheet-backdrop { opacity: 1; pointer-events: auto; }
  .sheet-grab { align-self: center; width: 40px; height: 5px; border-radius: 99px; background: var(--line); margin-bottom: 6px; }
  .sheet-item {
    display: flex; align-items: center; gap: 14px; padding: 12px; border: 0; border-radius: 16px;
    background: transparent; text-align: left;
  }
  .sheet-item:active, .sheet-item.active { background: color-mix(in srgb, var(--c) 9%, white); }
  .sheet-item > svg { width: 40px; height: 40px; padding: 9px; border-radius: 12px; background: color-mix(in srgb, var(--c) 12%, white); color: var(--c); }
  .sheet-item b { display: block; font-size: 15px; }
  .sheet-item small { display: block; font-size: 12.5px; color: var(--ink-3); }

  .toast { bottom: calc(var(--bn-h) + var(--safe-b) + 14px); }

  .card { padding: 18px 16px; border-radius: 20px; }
  .view > * + * { margin-top: 14px; }
  .grid-2, .grid-wide-left, .home-grid { grid-template-columns: 1fr; gap: 14px; }
  .stack { gap: 14px; }

  .hero {
    grid-template-columns: 1fr auto;
    grid-template-areas: "text ring" "pills pills";
    gap: 16px 12px; padding: 22px 18px 18px;
  }
  .hero h1 { font-size: 28px; }
  .hero-sub { font-size: 14px; }
  .ring-wrap { width: 118px; height: 118px; }
  .ring-center b { font-size: 28px; }
  .ring-center small { font-size: 9.5px; }
  .ring-wrap.full::after { font-size: 9.5px; bottom: -8px; }
  .hp { font-size: 12.5px; padding: 6px 10px 6px 8px; }

  .check { grid-template-columns: 30px 1fr auto; gap: 10px; padding: 11px 12px 11px 10px; }
  .check-box { width: 28px; height: 28px; }
  .check-body b { font-size: 14.5px; }

  .focus-time { font-size: 40px; }
  .logros { grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); }
  .medal-ico { width: 50px; height: 50px; font-size: 12px; }

  .view-head { padding-top: 8px; }
  .view-head h1 { font-size: 34px; }
  .view-head p:not(.eyebrow) { font-size: 14.5px; }

  .ladder { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 8px; margin: 0 -16px; padding: 2px 16px 6px; scrollbar-width: none; }
  .ladder::-webkit-scrollbar { display: none; }
  .rung { flex: 0 0 132px; scroll-snap-align: start; }

  .filters { display: flex; width: 100%; }
  .filters button { flex: 1; padding: 8px 4px; font-size: 12.5px; }
  .certs-grid, .links-grid { grid-template-columns: 1fr; }
  .kanban { grid-template-columns: 1fr; }
  .tl-bars { grid-template-columns: 1fr; gap: 10px; }
  .two-fields { grid-template-columns: 1fr; gap: 0; }
  .history { max-height: none; }
  .notes-list { max-height: none; }
  #review-today { grid-template-columns: 1fr; }
  .cli-stats { grid-template-columns: 1fr; gap: 10px; }
  .cli-stat { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; border-top: 0; border-left: 4px solid var(--kc); }
  .cli-stat b { margin-top: 0; font-size: 24px; text-align: right; }
  .ckanban { grid-template-columns: 1fr; }
  .ckanban .kcol.vacia { display: none; }
  .sem-nums { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sem-campos { grid-template-columns: 1fr; }
}

@media (max-width: 370px) {
  .hero { grid-template-columns: 1fr 100px; }
  .ring-wrap { width: 100px; height: 100px; }
  .ring-center b { font-size: 24px; }
  .hero h1 { font-size: 25px; }
  .bn { font-size: 10px; }
}

/* ---------- movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .celebra .confeti { display: none; }
  .celebra.show > span { animation: none; opacity: 1; transform: rotate(-6deg); }
}
