/* Screen-specific layout. Shared parts live in base.css and kit.css. */

/* ---------- sign-in ---------- */
.auth{flex:1;display:flex;flex-direction:column;gap:16px;justify-content:center;padding-block:12px;width:100%;max-width:420px;margin-inline:auto}
.auth-logo{display:flex;flex-direction:column;align-items:center;gap:2px;padding-bottom:6px}
.auth-logo .brand{font-size:2.5rem}
.auth-form{display:flex;flex-direction:column;gap:14px}
.auth-form .textlink{align-self:center}
.auth .code{letter-spacing:.18em;text-transform:uppercase}
.auth .demo{gap:6px}
.auth-legal{text-align:center;font-size:.78rem;color:var(--ink-3)}
.auth-legal a{color:inherit}
.legal-links{display:flex;flex-wrap:wrap;gap:6px 18px}
/* the user guide (#/help): two actions on top, then a chapter per area that opens in place */
.hp-top{gap:0;padding-block:6px}
.hp-act{display:flex;align-items:center;gap:12px;padding-block:10px}
.hp-act + .hp-act{border-top:1px solid var(--line)}
.hp-act .row-t{flex:1;min-width:0}
.hp-act .row-t small,.hp summary .row-t small{white-space:normal;overflow:visible}
.hp{padding:0;gap:0}
.hp summary{display:flex;align-items:center;gap:12px;padding:14px 16px;cursor:pointer;list-style:none;border-radius:var(--r)}
.hp summary::-webkit-details-marker{display:none}
.hp summary .row-t{flex:1;min-width:0}
.hp summary h2{font-size:1rem;font-weight:600}
.hp summary .chev{transition:transform 180ms var(--ease-out);transform:rotate(-90deg)}
.hp[open] summary .chev{transform:rotate(90deg)}
.hp-list{margin:0;padding:0 16px 4px;list-style:none;display:flex;flex-direction:column}
.hp-list li{display:flex;flex-direction:column;gap:2px;padding-block:10px;border-top:1px solid var(--line);font-size:.9rem;color:var(--ink-2)}
.hp-list b{color:var(--ink);font-weight:600}
.hp-show{display:flex;flex-wrap:wrap;gap:8px;padding:8px 16px 16px}
.hp-show svg{width:14px;height:14px}
.hp-note{padding:6px 16px 14px}
.hp-end{text-align:center;padding-block:4px 12px}
@media (prefers-reduced-motion: reduce){.hp summary .chev{transition:none}}

/* ---------- client home ---------- */
.next .eyebrow{color:var(--secondary-text)}
.week{flex-direction:row;align-items:center;gap:16px}
.week-in b{font-size:1.5rem;font-weight:800;line-height:1}
.week-in span{font-size:.72rem;color:var(--ink-3)}
.stat b{display:block;font-size:1.375rem;font-weight:700;line-height:1.15;font-variant-numeric:tabular-nums}
.stat span{display:block;font-size:.78rem;color:var(--ink-3)}
.stat.h{flex-direction:row;align-items:center}
.daylist .time{min-width:30px;height:30px;border-radius:9px;display:grid;place-items:center;background:var(--tile-2);font-size:.875rem;font-weight:700;color:var(--ink-2)}
.daylist .row.next-up .time{background:var(--accent);color:var(--on-accent)}
.next-h{display:flex;align-items:center;gap:12px}
.next .btn + .textlink,.textlink.center{align-self:center;text-align:center}
.nudge .tile-h{align-items:center}
.nudge .btn{flex:none}
.week{display:flex;align-items:center;gap:16px}
.week-t{min-width:0;display:flex;flex-direction:column;gap:6px;align-items:flex-start}
.week-in b small{font-size:.8rem;font-weight:600;color:var(--ink-3)}
#goalRing{flex:none;border-radius:50%}
.streak{display:inline-flex;align-items:center;gap:4px;font-size:.78rem;font-weight:600;color:var(--ink-2)}
.streak svg{width:15px;height:15px;color:var(--decor)}
.wstrip{display:grid;grid-template-columns:repeat(7,1fr);gap:4px;direction:rtl}
.wcell{display:flex;flex-direction:column;align-items:center;gap:4px;font-size:.7rem;color:var(--ink-3)}
.wcell .wd{font-weight:600}
.wcell .wc{width:34px;height:34px;border-radius:50%;display:grid;place-items:center;font-size:.84rem;font-weight:700;color:var(--ink-2);background:var(--tile-2)}
.wcell .wc svg{width:16px;height:16px}
.wcell.is-done .wc{background:var(--accent);color:var(--on-accent)}
.wcell.is-today .wc{background:var(--wash);color:var(--secondary-text);box-shadow:inset 0 0 0 2px var(--secondary)}
.wcell.is-planned .wc{background:var(--wash);color:var(--secondary-text)}
.wcell.is-missed .wc{background:transparent;box-shadow:inset 0 0 0 1.5px var(--line-2)}
.wcell.is-rest .wc,.wcell.is-rest_past .wc,.wcell.is-rest_today .wc{background:transparent}
.wcell.is-rest .wc::after,.wcell.is-rest_past .wc::after,.wcell.is-rest_today .wc::after{content:"";width:5px;height:5px;border-radius:50%;background:var(--line-2)}
.wcell.is-now .wd{color:var(--ink);font-weight:700}
.wcell .wl{font-size:.66rem;line-height:1.2}
.dcode{flex:none;width:38px;height:38px;border-radius:11px;display:grid;place-items:center;background:var(--accent);color:var(--on-accent);font-size:.97rem;font-weight:800;direction:ltr}
.dcode.alt{background:var(--wash);color:var(--secondary-text)}
.dcode.lg{width:46px;height:46px;font-size:1.15rem;border-radius:13px}
.daylist .row{grid-template-columns:auto minmax(0,1fr) auto}
.daylist .row > span:last-child{display:none}
.daylist .row-t{text-align:start;padding:0}
.daylist .row-t b{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.stat > span{order:-1}
.stat b small{font-size:.78rem;font-weight:600;color:var(--ink-3)}
.pills{display:flex;flex-direction:column;gap:4px;align-items:flex-end}
.chips.wrap{flex-wrap:wrap;overflow:visible;margin-inline:0;padding-inline:0}
.chip.big{width:44px;height:44px;padding:0;font-size:1rem;display:grid;place-items:center}
.center-tile{align-items:stretch;text-align:center}
.habits{display:flex;flex-direction:column;margin-block:-4px}
.habit{display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:12px;padding:10px 2px;text-align:start;transition:background-color 120ms ease}
.habit + .habit{border-top:1px solid var(--line)}
.habit:active{background:var(--tile-2)}
.habit-c{width:28px;height:28px;border-radius:50%;display:grid;place-items:center;box-shadow:inset 0 0 0 1.8px var(--line-2);color:transparent;transition:background-color 160ms ease,color 160ms ease}
.habit-c svg{width:15px;height:15px}
.habit.done .habit-c{background:var(--accent);box-shadow:none;color:var(--on-accent)}
.habit-n{font-size:.97rem;font-weight:500}
.habit.done .habit-n{color:var(--ink-3)}
.habit-m{display:flex;align-items:center;gap:10px;font-size:.78rem;color:var(--ink-3)}
.habit-s{display:inline-flex;align-items:center;gap:2px;font-weight:600;color:var(--ink-2)}
.habit-s svg{width:14px;height:14px;color:var(--decor)}
.recov{display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));gap:12px 8px}
.recov-i{display:flex;flex-direction:column;align-items:center;gap:3px;text-align:center}
.recov-i .ring-in b{font-size:.78rem;font-weight:700}
.recov-i > b{font-size:.8rem;font-weight:600}
.recov-i > span{font-size:.7rem;color:var(--ink-3)}
.ring.dec .r-f{stroke:var(--decor)}
.legend{display:flex;gap:14px;font-size:.75rem;color:var(--ink-3)}
.legend span{display:inline-flex;align-items:center;gap:5px}
.legend i{width:9px;height:9px;border-radius:50%;background:var(--accent)}
.legend i.sec{background:var(--secondary)}
.legend i.dec{background:var(--decor)}
@media (hover: hover) and (pointer: fine){
  .habit:hover{background:var(--tile-2)}
}
.week-in{display:flex;flex-direction:column;align-items:center;gap:1px}
#nutZone:empty{display:none}
#nutZone .tile{gap:16px}
