:root {
  --bg: #0a0b0c; --s1: #121315; --s2: #191b1d; --s3: #222427;
  --line: #2a2c2f; --line2: #44474b;
  --txt: #f3f3f2; --muted: #adb0b3; --dim: #8a8d91;
  --silver: #c9ccce; --white: #ffffff;
  --ok: #8fa88f; --warn: #bda674; --bad: #b5807a;
  --sans: 'Inter Tight', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  --r: 6px; --rail: 232px; --bottom: 62px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html { background: var(--bg); -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100dvh; color: var(--txt); font: 400 15px/1.45 var(--sans); background:
  radial-gradient(900px 420px at 72% -120px, rgba(214,216,218,.075), transparent 70%), var(--bg); background-attachment: fixed; }
body.locked { overflow: hidden; }
body.dragging { user-select: none; -webkit-user-select: none; cursor: grabbing; }
h1, h2, h3, h4, p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; }
small { font-size: 12px; color: var(--muted); }
:focus-visible { outline: 1.5px solid var(--white); outline-offset: 2px; }
[hidden] { display: none !important; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); } .grow { flex: 1; }
.eyebrow { font: 500 11px/1.3 var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }

#app { min-height: 100dvh; }
.rail { position: fixed; inset: 0 auto 0 0; width: var(--rail); border-right: 1px solid var(--line); background: rgba(14,15,16,.86); display: flex; flex-direction: column; padding: 20px 12px 14px; overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 8px 18px; }
.brand strong { display: block; font: 500 13px var(--mono); letter-spacing: .12em; }
.brand small { display: block; font-size: 9.5px; line-height: 1.3; color: var(--dim); margin-top: 2px; }
.nav-g { margin-bottom: 14px; }
.nav-g > small { display: block; font: 500 10px var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--dim); padding: 0 10px 5px; }
.nav-i { display: flex; align-items: center; gap: 11px; height: 36px; padding: 0 10px; border-radius: var(--r); color: var(--muted); position: relative; transition: color .15s, background .15s; }
.nav-i:hover { color: var(--txt); background: var(--s1); }
.nav-i.on { color: var(--white); background: var(--s2); }
.nav-i.on::before { content: ''; position: absolute; left: -12px; top: 9px; bottom: 9px; width: 2px; background: var(--silver); }
.rail-f { margin-top: auto; padding: 10px 10px 0; }
.sync { font: 400 11px var(--mono); color: var(--dim); }
.sync.warn { color: var(--warn); }
#view { display: block; margin-left: var(--rail); padding: 28px 32px 56px; max-width: calc(1180px + var(--rail)); outline: none; }
#view.enter { animation: enter .22s ease-out; }
@keyframes enter { from { opacity: 0; transform: translateY(5px); } }
.bottom { display: none; }

.view-h { display: flex; justify-content: space-between; align-items: flex-end; gap: 14px; margin-bottom: 18px; }
.view-h h1 { font-size: 30px; font-weight: 500; letter-spacing: -.015em; margin-top: 3px; }
.view-r { display: flex; gap: 8px; align-items: center; flex-shrink: 0; }
.section { font: 500 11px var(--mono); letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin: 24px 0 10px; }

.panel { position: relative; background: linear-gradient(180deg, rgba(255,255,255,.022), transparent 90px), var(--s1); border: 1px solid var(--line); border-radius: var(--r); padding: 15px 16px; margin-bottom: 12px; }
.panel::before, .panel::after { content: ''; position: absolute; width: 9px; height: 9px; border: solid var(--line2); pointer-events: none; }
.panel::before { top: -1px; left: -1px; border-width: 1px 0 0 1px; border-top-left-radius: var(--r); }
.panel::after { bottom: -1px; right: -1px; border-width: 0 1px 1px 0; border-bottom-right-radius: var(--r); }
.panel > * + * { margin-top: 8px; }
.panel-h { display: flex; justify-content: space-between; align-items: center; min-height: 28px; gap: 10px; }
.panel-h h2 { font: 500 11px var(--mono); letter-spacing: .13em; text-transform: uppercase; color: var(--silver); }
.panel-r { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; }
.panel.cta { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.panel.cta > * + * { margin-top: 0; }
.panel.cta h2 { font-size: 17px; font-weight: 500; } .panel.cta p { color: var(--muted); font-size: 13.5px; }
.cols { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 12px; align-items: start; }
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; align-items: start; }
.grid .panel { margin: 0; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 38px; padding: 0 14px; border-radius: var(--r); background: var(--s3); border: 1px solid var(--line2); font-size: 14px; font-weight: 500; white-space: nowrap; transition: background .15s, border-color .15s; }
.btn:hover { background: #2c2e31; border-color: var(--silver); }
.btn.primary { background: linear-gradient(180deg, #f5f5f4, #bfc2c5); color: #0b0c0d; border-color: #e6e7e8; }
.btn.primary:hover { background: #fff; }
.btn.ghost { background: transparent; }
.btn.danger { background: transparent; border-color: var(--line2); color: var(--bad); }
.btn.small { min-height: 32px; padding: 0 10px; font-size: 13px; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: var(--r); color: var(--muted); flex-shrink: 0; font-size: 18px; }
.icon-btn:hover { color: var(--white); background: var(--s3); }
.icon-btn.void { visibility: hidden; }
.link { font-size: 13px; color: var(--muted); text-decoration: underline; text-decoration-color: var(--line2); text-underline-offset: 3px; }
.link:hover { color: var(--white); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 12px; }
.chip { min-height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); font-size: 13px; white-space: nowrap; }
.chip:hover { border-color: var(--line2); color: var(--txt); }
.chip.on { background: var(--silver); border-color: var(--silver); color: #0b0c0d; font-weight: 500; }
.tag { display: inline-flex; align-items: center; padding: 2px 7px; border: 1px solid var(--line2); border-radius: 3px; font-size: 11px; color: var(--muted); white-space: nowrap; }
.tag-on { color: var(--txt); border-color: var(--silver); }
.tag-x { cursor: pointer; }
.tags { display: flex; gap: 5px; flex-wrap: wrap; }
.notice { border-left: 2px solid var(--silver); padding: 8px 12px; background: var(--s1); margin-bottom: 12px; color: var(--muted); }
.notice strong { color: var(--txt); font-weight: 500; }
.fine { font-size: 12.5px; color: var(--dim); line-height: 1.45; }
.empty { padding: 14px 2px; color: var(--dim); font-size: 13.5px; }
.struck { color: var(--dim); text-decoration: line-through; }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }

.bar { height: 3px; background: var(--s3); border-radius: 2px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--silver); border-radius: 2px; transition: width .35s ease; }
.ring { position: relative; flex-shrink: 0; }
.ring svg { display: block; }
.ring-bg { fill: none; stroke: var(--s3); }
.ring-fg { fill: none; stroke: var(--white); stroke-linecap: butt; transition: stroke-dasharray .4s ease; }
.ring-tick { stroke: var(--line2); stroke-width: 1; }
.ring-in { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
.ring-in .small { font-size: 12px; }
.ring-big { text-align: center; }
.ring-big .mono { display: block; font-size: 34px; font-weight: 300; line-height: 1; }
.ring-big small { font: 400 9px var(--mono); letter-spacing: .12em; color: var(--muted); }

.hero { display: flex; justify-content: space-between; align-items: center; gap: 20px; padding: 6px 0 20px; }
.hero-l { min-width: 0; flex: 1; max-width: 620px; }
.day-num { display: flex; align-items: baseline; gap: 12px; margin: 6px 0 8px; }
.day-tag { font: 400 14px var(--mono); letter-spacing: .2em; color: var(--muted); }
.day-val { font-size: clamp(56px, 9vw, 84px); font-weight: 300; line-height: 1; letter-spacing: -.04em; background: linear-gradient(180deg, #ffffff 25%, #9fa3a7); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero-m { display: flex; gap: 10px; align-items: baseline; }
.hero-m strong { font-weight: 500; } .hero-m .mono { font-size: 12px; color: var(--muted); }
.hero-f { color: var(--muted); font-size: 14px; margin: 2px 0 10px; }

.row { display: flex; align-items: center; gap: 11px; min-height: 44px; padding: 5px 0; border-top: 1px solid var(--line); margin-top: 0 !important; }
.panel-h + .row { border-top: 0; }
.row.habit, .row.card-row { cursor: pointer; }
.row-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.row-t strong { font-weight: 500; font-size: 14px; }
.row-t span { overflow-wrap: anywhere; }
.habit .row-t span { color: var(--muted); font-size: 13px; }
.habit.is-on .row-t strong { color: var(--white); }
.row-time { font-size: 12.5px; color: var(--silver); width: 44px; flex-shrink: 0; }
.chk { width: 24px; height: 24px; flex-shrink: 0; border: 1px solid var(--line2); border-radius: 4px; display: inline-flex; align-items: center; justify-content: center; color: #0b0c0d; position: relative; transition: background .12s, border-color .12s; }
.chk::after { content: ''; position: absolute; inset: -10px; }
.chk:hover { border-color: var(--silver); }
.chk.on { background: var(--silver); border-color: var(--silver); }
.commit { white-space: pre-line; color: var(--muted); font-size: 14.5px; line-height: 1.55; }
.commit.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.now { display: flex; gap: 12px; align-items: flex-start; }
.now-t { font-size: 22px; font-weight: 300; }
.now strong { font-weight: 500; } .now p { color: var(--muted); font-size: 13.5px; }
.next { display: flex; gap: 8px; align-items: baseline; color: var(--muted); font-size: 13px; padding-top: 8px; border-top: 1px solid var(--line); }
.triage { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 8px 0; border-top: 1px solid var(--line); margin-top: 0 !important; }
.triage-a { display: flex; gap: 5px; flex-shrink: 0; }
.video-t { font-size: 16px; }
.stages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 5px; }
.stage { min-height: 40px; border: 1px solid var(--line2); border-radius: var(--r); font-size: 13px; color: var(--muted); }
.stage.on { background: var(--silver); border-color: var(--silver); color: #0b0c0d; font-weight: 500; }
.tracker { display: flex; align-items: center; gap: 10px; min-height: 46px; border-top: 1px solid var(--line); margin-top: 0 !important; }
.panel-h + .tracker { border-top: 0; }
.tracker-l { flex: 1; font-size: 14px; }
.tracker-u { width: 26px; font-size: 11.5px; color: var(--dim); }
.stepper { display: flex; align-items: center; }
.stepper input { width: 50px; height: 34px; text-align: center; background: var(--s2); border: 1px solid var(--line); border-radius: 4px; -moz-appearance: textfield; font-size: 14px; }
.stepper input::-webkit-outer-spin-button, .stepper input::-webkit-inner-spin-button { -webkit-appearance: none; }
.big-step { display: flex; align-items: center; justify-content: center; gap: 22px; }
.big-step > .mono:not(button) { font-size: 42px; font-weight: 300; min-width: 70px; text-align: center; }
.big-step .icon-btn { border: 1px solid var(--line2); font-size: 22px; width: 44px; height: 44px; }
.rate { font-size: 11px; padding-left: 12px; position: relative; color: var(--muted); white-space: nowrap; }
.rate::before { content: ''; position: absolute; left: 0; top: 50%; width: 7px; height: 7px; border-radius: 50%; transform: translateY(-50%); }
.r-bom::before { background: var(--ok); } .r-ajustar::before { background: var(--warn); } .r-ruim::before { background: var(--bad); }

.date-nav { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; text-align: center; }
.date-nav strong { display: block; font-weight: 500; }
.date-nav small { font-size: 11px; letter-spacing: .08em; }
.week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; }
.week-d { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 4px 0; border-radius: 4px; }
.week-d.sel { background: var(--s3); }
.week-b { width: 8px; height: 56px; background: var(--s3); border-radius: 2px; display: flex; align-items: flex-end; overflow: hidden; }
.week-b i { display: block; width: 100%; background: var(--silver); border-radius: 2px 2px 0 0; }
.meter { padding: 5px 0; margin-top: 0 !important; }
.meter-h { display: flex; justify-content: space-between; font-size: 13px; margin-bottom: 5px; }
.timeline { display: flex; flex-direction: column; }
.tl { display: flex; gap: 14px; text-align: left; padding: 10px 6px; border-top: 1px solid var(--line); border-left: 2px solid transparent; }
.tl:first-child { border-top: 0; } .tl:hover { background: var(--s2); }
.tl.now { border-left-color: var(--white); background: var(--s2); }
.tl .mono { color: var(--silver); font-size: 14px; width: 48px; flex-shrink: 0; padding-top: 1px; }
.tl strong { font-weight: 500; } .tl p { color: var(--muted); font-size: 13.5px; }
.cal-head, .cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-head small { text-align: center; color: var(--dim); font-size: 11px; }
.cal-c { aspect-ratio: 1; max-height: 92px; width: 100%; border-radius: 4px; padding: 5px; display: flex; flex-direction: column; justify-content: space-between; background: rgba(210,212,214,var(--a,0)); border: 1px solid var(--line); text-align: left; position: relative; }
.cal-c.void { border: 0; background: none; } .cal-c.off { opacity: .42; }
.cal-c.today { border-color: var(--white); }
.cal-c .mono { font-size: 11px; align-self: flex-end; color: var(--white); text-shadow: 0 0 3px #000; }
.cal-c small { font-size: 11px; color: var(--txt); text-shadow: 0 0 3px #000; }
.cal-c.ed i { width: 100%; height: 3px; border-radius: 1px; }
.cal-c.ed.planned i, .lg.planned { background: var(--line2); }
.cal-c.ed.going i, .lg.going { background: var(--dim); }
.cal-c.ed.posted i, .lg.posted { background: var(--white); }
.legend { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding-top: 6px; }
.legend-b { width: 90px; height: 6px; border-radius: 2px; background: linear-gradient(90deg, rgba(210,212,214,.1), rgba(210,212,214,.85)); }
.lg { width: 12px; height: 4px; display: inline-block; margin-left: 6px; }

.filters .chips { margin-bottom: 8px; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
.filters .chips::-webkit-scrollbar { display: none; }
.board { display: flex; gap: 10px; overflow-x: auto; align-items: flex-start; padding: 6px 0 12px; scrollbar-color: var(--line2) transparent; }
.col { flex: 1 0 222px; min-width: 222px; background: var(--s1); border: 1px solid var(--line); border-radius: var(--r); padding: 8px; }
.col-h { display: flex; align-items: center; gap: 8px; padding: 0 2px 6px 6px; }
.col-h h3 { font: 500 11px var(--mono); letter-spacing: .12em; text-transform: uppercase; color: var(--silver); flex: 1; }
.col-h .mono { font-size: 12px; color: var(--dim); }
.col-body { min-height: 90px; display: flex; flex-direction: column; gap: 6px; }
.kcard { background: var(--s2); border: 1px solid var(--line); border-radius: 5px; padding: 10px 11px; cursor: grab; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.kcard:hover { border-color: var(--line2); }
.kcard.arch { opacity: .55; }
.kcard h4 { font-weight: 500; font-size: 14px; line-height: 1.3; overflow-wrap: anywhere; }
.kcard footer { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin-top: 8px; }
.kcard.ghost { position: fixed; left: 0; top: 0; z-index: 90; pointer-events: none; margin: 0; border-color: var(--silver); box-shadow: 0 14px 34px rgba(0,0,0,.65); }
.kph { border: 1px dashed var(--line2); border-radius: 5px; flex-shrink: 0; }
.mini-st { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3px; margin-top: 8px; }
.mini-st i { height: 3px; background: var(--s3); border-radius: 1px; } .mini-st i.on { background: var(--silver); }

.goals { display: flex; flex-direction: column; gap: 10px; }
.goal { background: var(--s1); border: 1px solid var(--line); border-radius: var(--r); }
.goal.arch { opacity: .6; }
.goal-h { display: flex; align-items: center; gap: 14px; width: 100%; padding: 12px 14px; text-align: left; }
.goal-t { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.goal-t h3 { font-size: 17px; font-weight: 500; }
.goal-target { color: var(--silver); }
.chev { color: var(--muted); transition: transform .18s; display: inline-flex; } .chev.on { transform: rotate(180deg); }
.chev-r { color: var(--dim); display: inline-flex; }
.goal-b { padding: 2px 14px 14px; display: flex; flex-direction: column; gap: 12px; }
.goal-why { color: var(--muted); font-size: 14px; }
.stage-b { border-left: 1px solid var(--line2); padding-left: 12px; }
.stage-b header { display: flex; justify-content: space-between; align-items: center; }
.stage-b h4, .group h4, .more-g h4, .entry-day h4, .modal-b > h4 { font: 500 11px var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--silver); }
.step .row-t { cursor: pointer; }
.quick { display: flex; gap: 4px; margin-top: 6px; }
.quick input { flex: 1; min-width: 0; height: 36px; padding: 0 10px; background: transparent; border: 1px solid var(--line); border-radius: 4px; font-size: 14px; }
.quick input:focus { border-color: var(--silver); outline: 0; }
.group { margin-top: 12px; }
.mini-goal { display: flex; justify-content: space-between; font-size: 13.5px; padding: 3px 0; }
.practices { list-style: none; margin: 8px 0 0; padding: 0; }
.practices li { display: flex; justify-content: space-between; gap: 10px; padding: 7px 0; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--muted); cursor: pointer; }
.practices small { color: var(--dim); font-size: 11px; }
.vision { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.vision-t { position: relative; min-height: 170px; overflow: hidden; border: 1px solid var(--line); border-radius: var(--r); background: linear-gradient(150deg, var(--s3), var(--s1)); text-align: left; display: flex; align-items: flex-end; }
.vision-t:hover { border-color: var(--silver); }
.vision-t img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; filter: grayscale(.5); }
.vision-b { position: relative; padding: 12px; }
.vision-b h3 { font-size: 16px; font-weight: 500; } .vision-b p { color: var(--muted); font-size: 13px; }
.jentry { border-top: 1px solid var(--line); margin-top: 0 !important; padding: 6px 0 10px; }
.jentry header { display: flex; justify-content: space-between; align-items: center; }
.jentry p { white-space: pre-wrap; color: var(--muted); overflow-wrap: anywhere; }
.panel textarea, .field input, .field select, .field textarea { width: 100%; background: var(--s2); border: 1px solid var(--line); border-radius: 4px; padding: 9px 10px; font-size: 16px; resize: vertical; }
.panel textarea:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--silver); outline: 0; }
.field input, .field select { height: 42px; padding-block: 0; }
.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 5px; }
.field small { display: block; margin-top: 4px; font-size: 12px; color: var(--dim); }
.field .chips { margin: 0; }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.stat { background: var(--s1); border: 1px solid var(--line); border-radius: var(--r); padding: 12px 14px; display: flex; flex-direction: column; }
.stat strong { font-size: 34px; font-weight: 300; line-height: 1.15; }
.charts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.chart { background: var(--s1); border: 1px solid var(--line); border-radius: var(--r); padding: 11px 12px; min-width: 0; }
.chart-h { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.chart-h h3 { font-size: 13.5px; font-weight: 500; }
.chart-val { font-size: 13px; color: var(--silver); }
.chart-empty { color: var(--dim); font-size: 13px; padding: 34px 0; text-align: center; }
.chart-box { position: relative; touch-action: pan-y; margin-top: 6px; }
.chart-svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart .grid { stroke: var(--line); stroke-width: .6; display: inline; }
.chart .tick { fill: var(--dim); font: 9px var(--mono); }
.mark-line { fill: none; stroke: var(--silver); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; vector-effect: non-scaling-stroke; }
.mark-dot { fill: var(--silver); stroke: var(--s1); stroke-width: 1; }
.mark-bar { fill: var(--dim); } .mark-bar.hi { fill: var(--white); }
.cross { stroke: var(--line2); stroke-width: 1; }
.cross-dot { fill: var(--white); stroke: var(--s1); stroke-width: 2; }
.chart-tip { position: absolute; top: -8px; left: 0; background: var(--s3); border: 1px solid var(--line2); border-radius: 3px; padding: 3px 7px; font: 11px var(--mono); white-space: pre; pointer-events: none; }
.chart-table summary, .more summary { cursor: pointer; font-size: 12px; color: var(--dim); margin-top: 4px; }
.chart-table table { width: 100%; font-size: 12px; border-collapse: collapse; margin-top: 4px; }
.chart-table td { padding: 3px 0; border-top: 1px solid var(--line); color: var(--muted); }
.chart-table td:last-child { text-align: right; }
.more { margin-top: 14px; }
.kv { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; }

.modal-wrap { position: fixed; inset: 0; z-index: 50; background: rgba(0,0,0,.66); display: flex; align-items: center; justify-content: center; padding: 20px; animation: fade .15s ease-out; }
@keyframes fade { from { opacity: 0; } }
.modal { width: 100%; max-width: 480px; max-height: 88dvh; display: flex; flex-direction: column; background: var(--s1); border: 1px solid var(--line2); border-radius: 8px; overflow: hidden; }
.modal > form, .modal > div { display: flex; flex-direction: column; min-height: 0; }
.modal-h { display: flex; justify-content: space-between; align-items: center; padding: 10px 10px 8px 16px; border-bottom: 1px solid var(--line); }
.modal-h h3 { font-size: 16px; font-weight: 500; }
.modal-b { padding: 14px 16px; overflow-y: auto; }
.modal-b > h4 { margin: 8px 0 8px; }
.modal-f { display: flex; gap: 8px; padding: 10px 16px calc(10px + var(--safe-b)); border-top: 1px solid var(--line); }
.form-err { color: var(--bad); font-size: 13px; }
.manage { display: flex; align-items: center; gap: 2px; margin-bottom: 5px; }
.manage input { flex: 1; min-width: 0; height: 36px; background: var(--s2); border: 1px solid var(--line); border-radius: 4px; padding: 0 10px; font-size: 16px; }
.entry-day { margin-bottom: 14px; }
.entry-day .row:first-of-type { border-top: 0; }
.more-g { margin-bottom: 14px; }
.more-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 7px; }
.more-i { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 14px 4px; border: 1px solid var(--line); border-radius: var(--r); color: var(--muted); font-size: 13px; }
.more-i:hover { color: var(--white); border-color: var(--line2); }
#toast { position: fixed; left: 50%; bottom: 30px; transform: translate(-50%, 16px); background: var(--silver); color: #0b0c0d; padding: 8px 14px; border-radius: 4px; font-size: 14px; opacity: 0; pointer-events: none; transition: .2s; z-index: 95; }
#toast.on { opacity: 1; transform: translate(-50%, 0); }
.auth { min-height: 100dvh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; text-align: center; gap: 8px; }
.auth h1 { font: 400 22px var(--mono); letter-spacing: .18em; margin-top: 10px; }
.auth form { display: flex; flex-direction: column; gap: 9px; width: 100%; max-width: 320px; margin-top: 22px; }
.auth input { height: 46px; padding: 0 12px; background: var(--s2); border: 1px solid var(--line2); border-radius: 4px; font-size: 16px; }

@media (max-width: 980px) {
  .charts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .vision { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
  .rail { display: none; }
  #view { margin-left: 0; padding: calc(14px + var(--safe-t)) 16px calc(var(--bottom) + var(--safe-b) + 22px); }
  .cols, .grid, .charts { grid-template-columns: minmax(0, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .hero { gap: 10px; padding-bottom: 14px; }
  .hero .ring, .hero .ring svg { width: 108px !important; height: 108px !important; }
  .ring-big .mono { font-size: 27px; }
  .view-h h1 { font-size: 25px; }
  .panel.cta { flex-direction: column; align-items: stretch; }
  .triage { flex-direction: column; align-items: stretch; }
  .col { flex: 0 0 82%; min-width: 0; scroll-snap-align: start; }
  .board { scroll-snap-type: x proximity; margin: 0 -16px; padding: 6px 16px 12px; scroll-padding-left: 16px; }
  body.dragging .board { scroll-snap-type: none; }
  .vision-t { min-height: 140px; }
  .bottom { display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; inset: auto 0 0 0; height: calc(var(--bottom) + var(--safe-b)); padding-bottom: var(--safe-b); background: rgba(13,14,15,.95); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-top: 1px solid var(--line); z-index: 40; }
  .bot-i { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; color: var(--dim); font-size: 11px; }
  .bot-i.on { color: var(--white); }
  .modal-wrap { align-items: flex-end; padding: 0; }
  .modal { max-width: none; border-radius: 12px 12px 0 0; border-width: 1px 0 0; max-height: 90dvh; animation: up .2s ease-out; }
  @keyframes up { from { transform: translateY(30px); } }
  #toast { bottom: calc(var(--bottom) + var(--safe-b) + 14px); }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
