:root {
  --bg: #F6F1EA;
  --card: #FFFFFF;
  --ink: #2A1E1F;
  --muted: #7C6F6C;
  --line: #ECE3DA;
  --acc: #7B2D3B;
  --acc-soft: #F2DEDE;
  --sage: #8BA27A;
  --ring-bg: #EFE2DE;
  --c: #F2DEDE;
  --c2: #7B2D3B;
  --serif: "Fraunces", Georgia, serif;
  --sans: "Manrope", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.5 var(--sans);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
button, input, textarea { font: inherit; color: inherit; }
[hidden] { display: none !important; }

#app {
  max-width: 480px;
  margin: 0 auto;
  padding: calc(20px + env(safe-area-inset-top)) 16px calc(32px + env(safe-area-inset-bottom));
}
.screen { animation: in .3s ease both; }
@keyframes in { from { opacity: 0; transform: translateY(6px); } }

/* Tipografía */
.h-hero { font: 400 46px/1.02 var(--serif); letter-spacing: -.02em; margin: 14px 0 14px; }
.h-hero b, .h-title b, .h-card b { font-weight: 700; color: var(--acc); }
.h-title { font: 400 34px/1.08 var(--serif); letter-spacing: -.015em; margin: 10px 0 4px; }
.h-title.sm { font-size: 28px; margin: 4px 0 16px; }
.h-card { font: 400 24px/1.15 var(--serif); }
.h-sec { font: 700 20px/1.2 var(--serif); margin: 30px 4px 12px; }
.lead { font-size: 16.5px; color: #43373A; }
.sub { font-size: 14px; color: var(--muted); font-weight: 600; }
.centro { text-align: center; }
.pill-top {
  display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .02em;
  border: 1.5px solid var(--ink); border-radius: 999px; padding: 5px 12px;
}
.tag {
  font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  color: var(--c2); margin-bottom: 10px;
}

/* Hero */
.hero {
  position: relative; overflow: hidden;
  background: linear-gradient(165deg, #F2DEDE 0%, #F3E7D6 60%, #E3EAD7 100%);
  border-radius: 28px; padding: 24px 22px 22px;
}
.hero-arte { margin: 18px -6px -6px; }
.hero-arte svg { display: block; width: 100%; height: auto; }
.ilus {
  flex: none; width: 52px; height: 52px; border-radius: 50%;
  background: var(--c); display: grid; place-items: center; overflow: hidden;
}
.ilus svg { width: 80%; height: 80%; }

.chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 14px 0 14px; }
.chips span {
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 12px; font-size: 13.5px; font-weight: 600;
}
.chips b { font-family: var(--serif); font-size: 16px; color: var(--acc); }

/* Tarjetas */
.card {
  background: var(--card); border-radius: 24px; padding: 20px;
  box-shadow: 0 1px 2px rgba(42,30,31,.04), 0 6px 20px rgba(42,30,31,.05);
}
.form { display: grid; gap: 14px; }
.form label { display: grid; gap: 6px; font-size: 14px; font-weight: 700; }
.form input {
  border: 1.5px solid var(--line); background: #FCFAF7; border-radius: 14px;
  padding: 14px; font-size: 16px; font-weight: 500; outline: none;
}
.form input:focus { border-color: var(--acc); background: #fff; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }
.error { font-size: 14px; color: #B5452E; text-align: center; font-weight: 600; }

.btn {
  display: block; width: 100%; text-align: center; text-decoration: none;
  background: var(--acc); color: #fff; border: 0; border-radius: 999px;
  padding: 16px 20px; font-weight: 700; font-size: 16px; cursor: pointer;
  transition: transform .1s ease, opacity .2s;
}
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .45; cursor: default; }
.btn.ghost { background: transparent; color: var(--ink); border: 1.5px solid var(--ink); margin-top: 10px; }
.screen > .btn { margin-top: 18px; }

.link {
  display: block; width: fit-content; margin: 18px auto 0; background: none; border: 0;
  color: var(--acc); font-weight: 700; font-size: 15px; text-decoration: underline;
  text-underline-offset: 3px; cursor: pointer; text-align: center;
}

/* Lista de días */
.tareas { list-style: none; display: grid; gap: 10px; }
.tarea {
  position: relative; display: flex; align-items: center; gap: 12px; width: 100%;
  background: var(--card); border: 0; border-radius: 22px; padding: 14px 14px 14px 22px;
  text-align: left; cursor: pointer;
  box-shadow: 0 1px 2px rgba(42,30,31,.04), 0 6px 18px rgba(42,30,31,.05);
}
.tarea::before {
  content: ""; position: absolute; left: 10px; top: 16px; bottom: 16px;
  width: 4px; border-radius: 4px; background: var(--c2);
}
.tarea .info { flex: 1; min-width: 0; }
.tarea .meta { display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.tarea .meta .pill { padding: 3px 10px; font-size: 12px; }
.tarea .meta i { width: 1.5px; height: 14px; background: var(--c2); }
.tarea .t { display: block; font-weight: 800; font-size: 16.5px; margin-top: 6px; }
.tarea .d { display: block; font-size: 13.5px; color: var(--muted); margin-top: 2px; }
.tarea .ilus { width: 56px; height: 56px; }
.tarea .ring {
  flex: none; width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--ink);
  display: grid; place-items: center;
}
.tarea.hecho .ring { background: var(--acc); border-color: var(--acc); }
.tarea.hecho .ring::after, .checks input:checked::after {
  content: ""; width: 6px; height: 11px; border: solid #fff; border-width: 0 2px 2px 0;
  transform: rotate(45deg) translate(-1px, -1px);
}
.tarea.hecho .t { text-decoration: line-through; text-decoration-thickness: 1.5px; color: var(--muted); }
.tarea.cerrado { cursor: default; opacity: .55; box-shadow: none; }
.tarea.cerrado .ring { border-style: dashed; border-color: var(--muted); }
.tarea.hoy { box-shadow: 0 0 0 2px var(--acc), 0 8px 22px rgba(123,45,59,.12); }

.pill {
  display: inline-flex; align-items: center; gap: 7px; border: 1.5px solid var(--ink);
  background: var(--card); border-radius: 999px; padding: 8px 16px; font-weight: 700; font-size: 14px; cursor: pointer;
  color: var(--ink);
}
.pill.chico { padding: 6px 12px; }
.pill.play::before { content: ""; border-style: solid; border-width: 5px 0 5px 8px; border-color: transparent transparent transparent currentColor; }
.pill.pausa::before { content: ""; width: 8px; height: 10px; border-left: 3px solid currentColor; border-right: 3px solid currentColor; }

/* Semana */
.top { margin-bottom: 16px; }
.semana { list-style: none; display: flex; justify-content: space-between; margin: 4px 0 18px; }
.semana li { display: grid; justify-items: center; gap: 6px; font-size: 11px; font-weight: 800; color: var(--muted); letter-spacing: .06em; }
.semana b {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  font: 600 16px/1 var(--serif); color: var(--ink);
}
.semana .hecho b { background: var(--c); }
.semana .hoy b { background: var(--acc); color: #fff; }
.semana .hoy { color: var(--acc); }

/* Método */
.rules { list-style: none; display: grid; gap: 10px; margin: 14px 0; }
.rules li {
  display: flex; gap: 14px; align-items: flex-start; background: var(--card);
  border-radius: 22px; padding: 16px;
  box-shadow: 0 1px 2px rgba(42,30,31,.04), 0 6px 18px rgba(42,30,31,.05);
}
.rules strong {
  flex: none; width: 52px; height: 52px; border-radius: 50%;
  display: grid; place-items: center; background: var(--c); color: var(--c2);
  font: 700 22px/1 var(--serif);
}
.rules h3 { font: 800 16.5px/1.3 var(--sans); }
.rules p { color: var(--muted); font-size: 14.5px; margin-top: 3px; }
.note { background: var(--acc-soft); box-shadow: none; }
.note p:last-child { font-size: 15px; }

/* Día */
.barra-dia { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.back { background: none; border: 0; font-weight: 700; padding: 6px 0; cursor: pointer; }
.back::before { content: "\2190  "; }
.dots { display: flex; gap: 6px; margin: 0 0 16px; }
.dots span { flex: 1; height: 5px; border-radius: 99px; background: #E6DCD3; transition: background .3s; }
.dots span.on { background: var(--acc); }

.lamina { animation: in .3s ease both; }
.slide { background: var(--c); border-radius: 28px; padding: 26px 22px; }
.slide.centro { text-align: center; }
.slide-arte { width: 170px; height: 170px; margin: -6px auto 14px; }
.slide-arte svg, .ilus-xl svg { width: 100%; height: 100%; }
.concepto { font: 700 32px/1.08 var(--serif); letter-spacing: -.015em; margin: 0 0 14px; }
.texto { font-size: 16.5px; line-height: 1.6; color: #362B2C; }
.yo {
  background: var(--card); border-radius: 22px; padding: 18px 20px; margin-top: 10px;
  box-shadow: 0 1px 2px rgba(42,30,31,.04), 0 6px 18px rgba(42,30,31,.05);
}
.yo p { font: italic 400 17px/1.55 var(--serif); }
.yo cite { display: block; margin-top: 10px; font: 800 13px/1 var(--sans); font-style: normal; color: var(--c2); }
.ilus-xl { width: 160px; height: 160px; margin: 0 auto 16px; border-radius: 50%; background: rgba(255,255,255,.6); display: grid; place-items: center; }
.ilus-xl svg { width: 82%; height: 82%; }
.regla { font: 700 34px/1.1 var(--serif); letter-spacing: -.015em; margin: 0 0 14px; color: var(--ink); }

.bat { display: grid; gap: 10px; }
.bat button {
  display: grid; grid-template-columns: 56px 1fr; grid-template-rows: auto auto; column-gap: 14px;
  align-items: center; text-align: left; background: var(--card); border: 2px solid transparent;
  border-radius: 22px; padding: 18px; cursor: pointer;
  box-shadow: 0 1px 2px rgba(42,30,31,.04), 0 6px 18px rgba(42,30,31,.05);
}
.bat svg { grid-row: span 2; width: 56px; height: 28px; color: var(--ink); }
.bat b { font-size: 17px; font-weight: 800; }
.bat span { font-size: 14px; color: var(--muted); font-weight: 600; }
.bat button:active { border-color: var(--acc); }

.foco-titulo { font: 700 26px/1.15 var(--serif); text-align: center; margin: 4px 8px 4px; letter-spacing: -.01em; }
.anillo { position: relative; width: min(250px, 72vw); aspect-ratio: 1; margin: 18px auto 8px; }
.anillo svg { width: 100%; height: 100%; }
#arco { transition: stroke-dashoffset .5s linear; }
.anillo-centro {
  position: absolute; inset: 17%; border-radius: 50%; background: var(--c);
  display: grid; place-items: center;
}
.anillo-centro svg { width: 76%; height: 76%; }
.controles { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 14px 0 18px; }
.controles .sep { width: 2px; height: 22px; background: var(--ink); border-radius: 2px; }
.resta { font-weight: 800; font-size: 16px; font-variant-numeric: tabular-nums; min-width: 86px; }

.checks {
  list-style: none; background: var(--card); border-radius: 22px; padding: 6px 16px;
  box-shadow: 0 1px 2px rgba(42,30,31,.04), 0 6px 18px rgba(42,30,31,.05);
}
.checks li + li { border-top: 1px solid var(--line); }
.checks label { display: flex; gap: 14px; align-items: center; padding: 13px 0; cursor: pointer; font-weight: 600; }
.checks input {
  appearance: none; -webkit-appearance: none; flex: none;
  width: 24px; height: 24px; border: 2px solid var(--ink); border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
}
.checks input:checked { background: var(--acc); border-color: var(--acc); }
.checks input:checked + span { color: var(--muted); text-decoration: line-through; }
.checks .num {
  margin-left: auto; flex: none; width: 34px; height: 34px; border-radius: 50%;
  background: var(--c); color: var(--c2); display: grid; place-items: center; font: 700 14px/1 var(--serif);
}
.pregunta {
  margin-top: 10px; padding: 14px 16px; border-radius: 18px; background: var(--c);
  font-size: 15px; font-weight: 700;
}

.field { display: grid; gap: 8px; margin-top: 14px; font-size: 14.5px; font-weight: 700; }
.field:first-child { margin-top: 0; }
.prompt { font: 700 22px/1.25 var(--serif); }
textarea, .field input {
  width: 100%; border: 0; background: rgba(255,255,255,.85); border-radius: 16px;
  padding: 14px; font-size: 16px; font-weight: 500; resize: vertical; outline: none;
}
textarea { min-height: 130px; }
textarea:focus, .field input:focus { background: #fff; box-shadow: 0 0 0 2px var(--acc); }

.nav { display: flex; gap: 10px; margin-top: 22px; }
.nav .btn { margin-top: 0; padding-left: 12px; padding-right: 12px; }
.nav .btn.ghost { flex: 0 0 34%; }

#final-cta { margin-top: 18px; }
canvas#tarjeta {
  width: 100%; height: auto; border-radius: 22px; margin: 18px 0 4px;
  box-shadow: 0 10px 30px rgba(42,30,31,.12);
}

.foot { text-align: center; font-size: 13px; color: var(--muted); margin-top: 30px; font-weight: 600; }

.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 999px;
  font-size: 14px; font-weight: 700; max-width: calc(100% - 32px);
}

@media (max-width: 360px) {
  .h-hero { font-size: 40px; }
  .semana b { width: 34px; height: 34px; }
}
.en-c { background: var(--c); margin-top: 6px; }

/* Encabezado con racha */
.fila-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.racha {
  display: inline-flex; align-items: center; gap: 6px; background: var(--card);
  border-radius: 999px; padding: 5px 12px 5px 8px; font-size: 13px; font-weight: 700;
  box-shadow: 0 1px 2px rgba(42,30,31,.05);
}
.racha svg { width: 18px; height: 18px; }
.racha b { font: 700 15px/1 var(--serif); color: var(--acc); }

/* Conversación con Nataly */
.chat { display: grid; gap: 10px; margin-bottom: 16px; }
.msg { display: flex; align-items: flex-end; gap: 8px; }
.msg p {
  max-width: 84%; padding: 13px 16px; border-radius: 20px 20px 20px 6px;
  background: var(--acc); color: #fff; font-size: 15.5px; font-weight: 500; line-height: 1.45;
}
.msg .av {
  flex: none; width: 32px; height: 32px; border-radius: 50%; background: var(--c);
  color: var(--c2); display: grid; place-items: center; font: 700 15px/1 var(--serif);
}
.yo-msg { justify-content: flex-end; }
.yo-msg p { background: var(--card); color: var(--ink); border-radius: 20px 20px 6px 20px; font-weight: 700;
  box-shadow: 0 1px 2px rgba(42,30,31,.05); }
#energia .bat { margin-left: 40px; }

/* Avance en cada tarjeta */
.tarea .cl { display: inline-block; margin-top: 8px; font-size: 12px; font-weight: 700; color: var(--c2);
  background: var(--c); border-radius: 999px; padding: 3px 10px; }
.ilus-ring {
  flex: none; width: 64px; height: 64px; border-radius: 50%; padding: 4px;
  background: conic-gradient(var(--c2) var(--p, 0%), #EFE8E0 0);
  display: grid; place-items: center;
}
.ilus-ring .ilus { width: 56px; height: 56px; border: 3px solid #fff; }

/* Vaciado de cabeza */
.dump-b { margin-top: 12px; }
.dump-sub { margin: 16px 0 8px; font: 700 18px/1.3 var(--serif); }
.dump { list-style: none; display: grid; gap: 8px; }
.dump-it {
  width: 100%; display: flex; align-items: center; gap: 12px; text-align: left;
  background: rgba(255,255,255,.9); border: 2px solid transparent; border-radius: 16px;
  padding: 12px 14px; font-weight: 600; cursor: pointer;
}
.dump-it span { flex: 1; }
.dump-it svg { flex: none; width: 22px; height: 22px; fill: none; stroke: #B9A9A3; }
.dump-it.top { border-color: var(--acc); background: #fff; }
.dump-it.top svg { fill: var(--acc); stroke: var(--acc); }

/* Tus 3 */
.top3 { margin-bottom: 12px; border-left: 4px solid var(--acc); }
.checks.plano { box-shadow: none; padding: 0; background: none; }

/* Ahora mismo (widget) */
.ahora {
  display: flex; gap: 14px; background: #2A1E1F; color: #fff; border-radius: 26px;
  padding: 18px; margin-bottom: 12px; cursor: pointer;
}
.ahora .tag { color: #E9B8B5; }
.ahora-izq { flex: 0 0 42%; }
.mini { position: relative; width: 78px; height: 78px; margin: 2px 0 10px; }
.mini svg { width: 100%; height: 100%; }
.mini .ilus { position: absolute; inset: 11px; width: auto; height: auto; }
.ahora-t { display: block; font-size: 15px; font-weight: 800; line-height: 1.25; }
.ahora-r { display: block; font-size: 13px; color: #D9CBC6; margin-top: 3px; font-variant-numeric: tabular-nums; }
.ahora-der { flex: 1; display: flex; flex-direction: column; justify-content: space-between; gap: 12px; min-width: 0; }
.ahora-der ul { list-style: none; display: grid; gap: 7px; font-size: 13.5px; font-weight: 600; }
.ahora-der li { display: flex; gap: 8px; align-items: flex-start; line-height: 1.3; }
.ahora-der li::before {
  content: ""; flex: none; width: 14px; height: 14px; border: 1.8px solid #fff; border-radius: 50%; margin-top: 1px;
}
.ahora-der li.ok { color: #B5A7A2; text-decoration: line-through; }
.ahora-der li.ok::before { background: #E9B8B5; border-color: #E9B8B5; }
.ahora .pill { align-self: flex-start; background: #fff; border-color: #fff; }
.aviso { margin-bottom: 10px; } .aviso p:last-child { font-size: 15px; }

/* Inicio a tu ritmo */
.fecha-reto { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin: -4px 0 12px; }
.fecha-reto b { font: 700 18px/1 var(--serif); color: var(--acc); }
.fecha-reto span { font-size: 14px; font-weight: 600; color: #5E4E4C; }
.social { text-align: center; font-weight: 700; margin-top: 12px; color: var(--acc); }

/* Total soltado */
.total { display: flex; gap: 14px; align-items: center; background: var(--c); border-radius: 24px; padding: 14px 18px; margin-bottom: 12px; }
.total .ilus { width: 58px; height: 58px; background: rgba(255,255,255,.7); }
.total-n { font: 400 24px/1.1 var(--serif); }
.total-n b { font-weight: 700; color: var(--c2); font-size: 30px; }
.total-g { font-size: 13.5px; font-weight: 700; color: #5E4E4C; margin-top: 2px; }

/* Contador del día */
.soltar, .fotos { margin-top: 12px; }
.contador { display: flex; align-items: center; justify-content: center; gap: 22px; margin: 4px 0 12px; }
.contador b { font: 700 52px/1 var(--serif); min-width: 90px; text-align: center; color: var(--c2); font-variant-numeric: tabular-nums; }
.cnt {
  width: 52px; height: 52px; border-radius: 50%; border: 2px solid var(--ink); background: var(--card);
  font-size: 26px; font-weight: 700; line-height: 1; cursor: pointer;
}
.cnt-rapidos { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }

/* Antes y después */
.foto-par { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.foto {
  aspect-ratio: 3 / 4; border-radius: 18px; border: 2px dashed #CDBDB4; background: var(--c) center / cover no-repeat;
  display: flex; align-items: flex-end; justify-content: center; padding: 10px; cursor: pointer;
}
.foto span { background: #fff; border-radius: 999px; padding: 6px 12px; font-size: 13px; font-weight: 800; }
.foto.con-foto { border: 0; }

canvas#historia { width: 100%; height: auto; border-radius: 22px; margin: 18px 0 4px; box-shadow: 0 10px 30px rgba(42,30,31,.12); }
