/* Ladle: a food-magazine look. Fraunces for headings, the system sans for reading, warm paper, one accent colour. */
@font-face { font-family: "Fraunces"; font-style: normal; font-weight: 300 800; font-display: swap; src: url(/ladle/fonts/fraunces.woff2) format("woff2"); }
@font-face { font-family: "Fraunces"; font-style: italic; font-weight: 300 800; font-display: swap; src: url(/ladle/fonts/fraunces-italic.woff2) format("woff2"); }

:root {
  --paper: #fbf7f0; --paper2: #f4ede2; --card: #ffffff; --ink: #1f1a16; --ink2: #6b5f53; --ink3: #9a8d80; --line: #ebe2d5; --line2: #ddd2c2;
  --accent: #c8553d; --accent-d: #a4442f; --accent-l: #dc8a77; --accent-soft: rgba(200, 85, 61, .12); --on-accent: #fff; --accent-t: var(--accent-tl, var(--accent));
  --herb: #4f7a3a; --butter: #f2c14e; --danger: #b3261e;
  --shadow: 0 1px 2px rgba(60, 40, 20, .06), 0 6px 20px rgba(60, 40, 20, .07); --shadow-lg: 0 18px 50px rgba(40, 25, 10, .18);
  --serif: "Fraunces", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --r: 18px; --r-sm: 12px; --tabh: 64px; --side: 248px;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
  --ease: cubic-bezier(.2, .8, .2, 1); --spring: cubic-bezier(.34, 1.56, .64, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --paper: #171412; --paper2: #1f1b18; --card: #24201c; --ink: #f4ede4; --ink2: #b9ab9c; --ink3: #8a7d70; --line: #342e29; --line2: #433b34;
  --accent-t: var(--accent-td, #e8735a); --accent-soft: rgba(232, 115, 90, .16); --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25); --shadow-lg: 0 18px 50px rgba(0, 0, 0, .5); --herb: #8ab86a; color-scheme: dark; } }
:root[data-theme="dark"] {
  --paper: #171412; --paper2: #1f1b18; --card: #24201c; --ink: #f4ede4; --ink2: #b9ab9c; --ink3: #8a7d70; --line: #342e29; --line2: #433b34;
  --accent-t: var(--accent-td, #e8735a); --accent-soft: rgba(232, 115, 90, .16); --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .25); --shadow-lg: 0 18px 50px rgba(0, 0, 0, .5); --herb: #8ab86a; color-scheme: dark; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; background: var(--paper); }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.5 var(--sans); -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; min-height: 100vh; overflow-x: hidden; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--accent-t); }
img { max-width: 100%; }
:focus-visible { outline: 2.5px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--ink2); } .sm { font-size: 13.5px; } [hidden] { display: none !important; }
.grow { flex: 1; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; letter-spacing: -.01em; margin: 0; font-optical-sizing: auto; }
.eyebrow { margin: 0 0 4px; font: 700 11.5px/1.3 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--accent-t); }

/* ---------- shell ---------- */
#app { min-height: 100vh; }
#side { position: sticky; top: 0; z-index: 30; }
.top { display: flex; align-items: center; gap: 8px; height: calc(52px + var(--safe-t)); padding: var(--safe-t) 12px 0; background: color-mix(in srgb, var(--paper) 86%, transparent); backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s; }
body.scrolled .top { border-bottom-color: var(--line); }
.yz-link { flex: 1; color: var(--accent-t); font-weight: 600; font-size: 15px; text-decoration: none; padding: 8px 4px; min-height: 44px; display: flex; align-items: center; }
.wordmark { position: absolute; left: 50%; transform: translateX(-50%); font: 600 21px/1 var(--serif); letter-spacing: -.02em; display: flex; align-items: center; gap: 6px; pointer-events: none; }
.wordmark span::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 50%; background: var(--accent); margin-right: 7px; vertical-align: 2px; box-shadow: 14px 0 0 -2px var(--butter); margin-right: 21px; }
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: transparent; color: var(--ink); text-decoration: none; transition: background .15s, transform .15s; flex: none; position: relative; }
.icon-btn:hover { background: var(--accent-soft); }
.icon-btn:active { transform: scale(.92); }
.icon-btn.sm { width: 34px; height: 34px; } .icon-btn.sm svg { width: 18px; height: 18px; }
.icon-btn.on { color: var(--accent-t); } .icon-btn.on svg { fill: currentColor; }
.icon-btn.pulse { animation: pulse .5s var(--spring); }
@keyframes pulse { 40% { transform: scale(1.3); } }
#tabs { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; display: flex; justify-content: space-around; height: calc(var(--tabh) + var(--safe-b)); padding: 6px 8px var(--safe-b); background: color-mix(in srgb, var(--paper) 88%, transparent); backdrop-filter: saturate(1.4) blur(16px); -webkit-backdrop-filter: saturate(1.4) blur(16px); border-top: 1px solid var(--line); }
#tabs a { flex: 1; max-width: 140px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; color: var(--ink3); text-decoration: none; font-size: 11.5px; font-weight: 600; border-radius: 14px; position: relative; transition: color .2s; -webkit-user-select: none; user-select: none; }
#tabs a svg { transition: transform .3s var(--spring); }
#tabs a.on { color: var(--accent-t); }
#tabs a.on svg { transform: translateY(-1px) scale(1.06); }
#tabs a:active svg { transform: scale(.88); }
.badge { position: absolute; top: 2px; left: calc(50% + 8px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--accent); color: var(--on-accent); font: 700 11px/18px var(--sans); text-align: center; }
.side-foot { display: none; }
main#view { outline: none; padding: 0 16px calc(var(--tabh) + var(--safe-b) + 28px); max-width: 760px; margin: 0 auto; }
body.cook-on { overflow: hidden; }

/* desktop: a sidebar and a wide, intentional page */
@media (min-width: 900px) {
  #app { display: grid; grid-template-columns: var(--side) minmax(0, 1fr); }
  #side { height: 100vh; display: flex; flex-direction: column; border-right: 1px solid var(--line); background: var(--paper2); padding: 0 14px 18px; }
  .top { background: none; backdrop-filter: none; -webkit-backdrop-filter: none; padding: 14px 0 0; height: auto; flex-wrap: wrap; border: 0 !important; }
  .yz-link { flex: 0 0 100%; min-height: 32px; font-size: 14px; }
  .wordmark { position: static; transform: none; font-size: 30px; flex: 1; padding: 6px 4px 14px; }
  #tabs { position: static; flex-direction: column; justify-content: flex-start; height: auto; padding: 8px 0; background: none; backdrop-filter: none; -webkit-backdrop-filter: none; border: 0; gap: 2px; }
  #tabs a { flex: none; max-width: none; flex-direction: row; justify-content: flex-start; gap: 12px; padding: 11px 14px; font-size: 15px; color: var(--ink2); }
  #tabs a:hover { background: var(--accent-soft); color: var(--ink); }
  #tabs a.on { background: var(--card); color: var(--accent-t); box-shadow: var(--shadow); }
  .badge { position: static; margin-left: auto; }
  .side-foot { display: flex; flex-direction: column; gap: 10px; margin-top: auto; }
  .dinner-btn { border: 0; border-radius: 14px; padding: 14px; background: var(--accent); color: var(--on-accent); font: 600 16px/1.2 var(--serif); box-shadow: var(--shadow); transition: transform .15s; }
  .dinner-btn:hover { transform: translateY(-1px); background: var(--accent-d); }
  .side-all { font-size: 13px; color: var(--ink2); text-decoration: none; padding: 4px 6px; }
  main#view { max-width: 1180px; width: 100%; min-width: 0; padding: 26px 40px 60px; }
  #timer-tray { left: calc(var(--side) + 24px) !important; bottom: 24px !important; }
  #toast { left: calc(50% + var(--side) / 2) !important; bottom: 28px !important; }
}

/* ---------- buttons, fields, chips ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: 999px; border: 1.5px solid transparent; font-weight: 600; font-size: 15px; text-decoration: none; transition: transform .15s var(--ease), background .15s, box-shadow .15s; -webkit-user-select: none; user-select: none; white-space: nowrap; }
.btn svg { width: 20px; height: 20px; flex: none; }
.btn:active:not(:disabled) { transform: scale(.96); }
.btn:disabled { opacity: .45; cursor: default; }
.btn.primary { background: var(--accent); color: var(--on-accent); box-shadow: 0 6px 16px -6px var(--accent); }
.btn.primary:hover:not(:disabled) { background: var(--accent-d); }
.btn.ghost { background: var(--card); color: var(--ink); border-color: var(--line2); }
.btn.ghost:hover:not(:disabled) { border-color: var(--accent-l); }
.btn.danger { background: var(--danger); color: #fff; } .btn.ghost.danger { background: transparent; color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); }
.btn.big { min-height: 54px; font-size: 16.5px; padding: 12px 22px; }
.btn.sm { min-height: 38px; padding: 7px 14px; font-size: 14px; }
.btn.link { background: none; color: var(--ink2); font-weight: 500; text-decoration: underline; text-underline-offset: 3px; }
.row-btns { display: flex; gap: 10px; justify-content: flex-end; margin-top: 18px; flex-wrap: wrap; }
.row-btns.left { justify-content: flex-start; } .row-btns .btn { flex: 1 1 auto; } .row-btns.left .btn { flex: 0 0 auto; }
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px 16px 4px; margin: 0 -16px; scroll-snap-type: x proximity; }
.chips::-webkit-scrollbar { display: none; }
.chips.center { justify-content: flex-start; flex-wrap: wrap; margin: 0; padding: 0; }
.chip { flex: none; border: 1.5px solid var(--line2); background: var(--card); color: var(--ink2); padding: 7px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; min-height: 38px; transition: all .2s var(--ease); scroll-snap-align: start; }
.chip.on { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip:active { transform: scale(.95); }
.search { position: relative; display: flex; align-items: center; gap: 8px; margin: 16px 0 12px; }
.search > svg { position: absolute; left: 14px; width: 20px; height: 20px; color: var(--ink3); pointer-events: none; }
.search input { flex: 1; min-width: 0; height: 48px; border-radius: 999px; border: 1.5px solid var(--line2); background: var(--card); padding: 0 16px 0 44px; outline: none; transition: border-color .15s, box-shadow .15s; }
.search input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.add-btn { background: var(--accent) !important; color: var(--on-accent) !important; width: 48px; height: 48px; box-shadow: 0 8px 18px -8px var(--accent); }
.seg { display: inline-flex; background: var(--paper2); border: 1px solid var(--line); border-radius: 999px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; border-radius: 999px; padding: 6px 13px; font-size: 13.5px; font-weight: 600; color: var(--ink2); min-height: 34px; transition: background .2s, color .2s; }
.seg button[aria-pressed="true"] { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .12); }
.seg.wide { display: flex; margin: 14px 0; } .seg.wide button { flex: 1; }
.stepper { display: flex; align-items: center; gap: 4px; background: var(--paper2); border-radius: 999px; padding: 4px; width: max-content; margin: 12px 0; border: 1px solid var(--line); }
.stepper .icon-btn { width: 40px; height: 40px; background: var(--card); font-size: 22px; font-weight: 500; box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.stepper output { min-width: 112px; text-align: center; font-size: 14px; color: var(--ink2); line-height: 1.15; }
.stepper output b { font: 600 20px/1 var(--serif); color: var(--ink); }
.stepper output small { display: block; font-size: 11.5px; color: var(--accent-t); font-weight: 600; }
.stepper.sm output { min-width: 44px; } .stepper.big { margin: 8px auto; } .stepper.big output { min-width: 150px; }
.fld { display: block; margin: 14px 0; }
.fld > span, .fld legend { display: block; font-size: 13px; font-weight: 700; color: var(--ink2); margin-bottom: 6px; }
.fld > span i, .fld legend i { font-style: normal; font-weight: 500; color: var(--ink3); }
.fld input, .fld textarea { width: 100%; border: 1.5px solid var(--line2); background: var(--card); border-radius: var(--r-sm); padding: 11px 13px; outline: none; transition: border-color .15s, box-shadow .15s; resize: vertical; }
.fld input:focus, .fld textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.fld.big input { font: 600 22px/1.3 var(--serif); padding: 12px 14px; }
.fld-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 10px; }
.fld-row .fld { margin: 6px 0; }
fieldset.fld { border: 1px dashed var(--line2); border-radius: var(--r); padding: 12px 14px; }
.hint { display: block; font-size: 12.5px; color: var(--herb); margin-top: 5px; min-height: 1em; font-weight: 600; }
.shake { animation: shake .4s; } @keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.switch { display: flex; align-items: flex-start; gap: 12px; padding: 12px 0; cursor: pointer; }
.switch input { appearance: none; -webkit-appearance: none; flex: none; width: 46px; height: 28px; border-radius: 14px; background: var(--line2); position: relative; transition: background .2s; margin: 0; cursor: pointer; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .25s var(--spring); }
.switch input:checked { background: var(--herb); } .switch input:checked::after { transform: translateX(18px); }
.switch span b { display: block; font-weight: 600; } .switch span small { display: block; color: var(--ink2); font-size: 13px; }
.pro-tag { display: inline-flex; align-items: center; gap: 3px; font: 700 10.5px/1 var(--sans); letter-spacing: .06em; text-transform: uppercase; color: var(--accent-t); background: var(--accent-soft); padding: 4px 7px; border-radius: 6px; vertical-align: 2px; }
.pro-tag svg { width: 12px; height: 12px; }

/* ---------- headings of each screen ---------- */
.hero-h { padding: 18px 0 4px; }
.hero-h h1 { font-size: clamp(34px, 9vw, 52px); line-height: 1.02; font-weight: 600; letter-spacing: -.025em; font-variation-settings: "SOFT" 50, "WONK" 1; }
.hero-h .sub { margin: 6px 0 0; color: var(--ink2); }
.hero-h.row { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
@media (min-width: 900px) { .hero-h { padding-top: 6px; } }

/* ---------- recipe box ---------- */
.dinner-card { width: 100%; display: flex; align-items: center; gap: 14px; text-align: left; margin: 14px 0 18px; padding: 16px 18px; border-radius: var(--r); border: 0; color: #fff; background: linear-gradient(120deg, var(--accent) 0%, var(--accent-d) 100%); box-shadow: 0 14px 30px -14px var(--accent); position: relative; overflow: hidden; transition: transform .2s var(--ease); }
.dinner-card::after { content: ""; position: absolute; right: -30px; top: -40px; width: 160px; height: 160px; border-radius: 50%; background: radial-gradient(circle, rgba(255, 255, 255, .22), transparent 70%); }
.dinner-card:active { transform: scale(.98); }
.dinner-card svg { width: 30px; height: 30px; flex: none; }
.dinner-card span { flex: 1; } .dinner-card b { display: block; font: 600 21px/1.15 var(--serif); } .dinner-card small { opacity: .85; font-size: 13.5px; }
@media (min-width: 900px) { .box .dinner-card { display: none; } }
.grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1100px) { .grid { grid-template-columns: repeat(4, 1fr); gap: 20px; } }
.rcard { display: block; text-decoration: none; color: inherit; border-radius: var(--r); background: var(--card); box-shadow: var(--shadow); overflow: hidden; transition: transform .25s var(--ease), box-shadow .25s; animation: rise .5s var(--ease) both; animation-delay: calc(var(--i) * 28ms); }
.rcard:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.rcard:active { transform: scale(.98); }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }
.rcard-pic { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--paper2); }
.pic { display: block; width: 100%; height: 100%; object-fit: cover; }
.rcard:hover .pic { transform: scale(1.04); } .rcard .pic { transition: transform .6s var(--ease); }
.fav-dot { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(255, 255, 255, .92); color: var(--accent-t); }
.fav-dot svg { width: 17px; height: 17px; fill: currentColor; }
.rcard-t { padding: 10px 12px 13px; }
.rcard-t h3 { font-size: 16.5px; line-height: 1.2; font-weight: 600; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rcard-t p { margin: 6px 0 0; display: flex; gap: 8px; flex-wrap: wrap; font-size: 12.5px; color: var(--ink2); align-items: center; }
.rcard-t p span { display: inline-flex; align-items: center; gap: 3px; }
.rcard-t p svg { width: 14px; height: 14px; }
.tg { text-transform: capitalize; }
.tg + .tg::before { content: "·"; margin-right: 8px; color: var(--ink3); }
.cap-note { text-align: center; color: var(--ink2); font-size: 13px; margin: 20px 0; }
.empty { text-align: center; padding: 36px 20px; max-width: 420px; margin: 0 auto; grid-column: 1 / -1; }
.empty h2 { font-size: 24px; margin: 12px 0 6px; }
.empty p { color: var(--ink2); margin: 0 0 18px; }
.empty-art { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto; background: var(--accent-soft); color: var(--accent-t); }
.empty-art svg { width: 34px; height: 34px; }

/* ---------- recipe ---------- */
.r-top { display: flex; align-items: center; gap: 4px; margin: 6px -8px 0; }
.r-hero { margin: 4px 0 0; border-radius: 22px; overflow: hidden; aspect-ratio: 4 / 3; box-shadow: var(--shadow); background: var(--paper2); }
@media (min-width: 900px) { .r-hero { aspect-ratio: 21 / 9; } }
.r-head { padding: 20px 0 6px; }
.r-head h1 { font-size: clamp(32px, 8.5vw, 54px); line-height: 1.04; letter-spacing: -.025em; font-variation-settings: "SOFT" 30, "WONK" 1; text-wrap: balance; }
.blurb { font: italic 400 19px/1.45 var(--serif); color: var(--ink2); margin: 12px 0 0; text-wrap: pretty; }
.meta { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 16px 0 0; color: var(--ink2); font-size: 14px; }
.meta span { display: inline-flex; align-items: center; gap: 6px; } .meta svg { width: 18px; height: 18px; color: var(--accent-t); } .meta b { color: var(--ink); font-weight: 600; }
.r-cta { display: flex; gap: 10px; margin: 20px 0 6px; } .r-cta .btn { flex: 1; }
.r-cols { display: grid; gap: 8px 48px; }
@media (min-width: 900px) { .r-cols { grid-template-columns: minmax(300px, 380px) 1fr; } .ings { position: sticky; top: 20px; align-self: start; } }
.sec-h { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 22px; }
.ings h2, .method h2 { font-size: 26px; }
.method h2 { margin-top: 22px; }
.ing-sec { font: 700 12px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink3); margin: 18px 0 4px; }
.ing-list { list-style: none; margin: 0; padding: 0; }
.ing { width: 100%; display: grid; grid-template-columns: 26px minmax(64px, auto) 1fr; gap: 10px; align-items: baseline; text-align: left; border: 0; background: none; padding: 10px 2px; border-bottom: 1px solid var(--line); transition: opacity .3s; }
.ing .box { align-self: center; width: 22px; height: 22px; border-radius: 7px; border: 2px solid var(--line2); display: grid; place-items: center; transition: all .25s var(--spring); }
.ing .box svg { width: 15px; height: 15px; stroke-width: 3; color: #fff; transform: scale(0); transition: transform .3s var(--spring); }
.ing .amt { font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ing .nm small { color: var(--ink2); }
.ing.done { opacity: .45; } .ing.done .nm { text-decoration: line-through; text-decoration-color: var(--ink3); }
.ing.done .box { background: var(--herb); border-color: var(--herb); } .ing.done .box svg { transform: scale(1); }
#r-tolist { margin-top: 16px; }
.nutr { margin-top: 16px; }
.nutr h3 { font-size: 18px; margin-bottom: 6px; }
.nutr dl { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 0; }
.nutr dl div { background: var(--paper2); border-radius: var(--r-sm); padding: 10px; text-align: center; }
.nutr dt { font-size: 11.5px; color: var(--ink2); } .nutr dd { margin: 2px 0 0; font: 600 17px/1.2 var(--serif); }
.nutr-lock { width: 100%; display: flex; align-items: center; gap: 12px; text-align: left; padding: 14px; border-radius: var(--r-sm); border: 1.5px dashed var(--line2); background: transparent; color: var(--ink2); }
.nutr-lock svg { color: var(--accent-t); } .nutr-lock b { display: block; color: var(--ink); } .nutr-lock small { color: var(--accent-t); font-weight: 700; }
.steps { list-style: none; margin: 10px 0 0; padding: 0; counter-reset: s; }
.step { display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.step .n { font: 600 28px/1 var(--serif); color: var(--accent-t); font-variation-settings: "WONK" 1; }
.step p { margin: 0; font-size: 17px; line-height: 1.6; text-wrap: pretty; }
.st-sec { font: 700 12px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink3); padding: 18px 0 2px; }
.tchip { display: inline-flex; align-items: center; gap: 4px; border: 0; padding: 2px 9px 2px 6px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-d); font-weight: 700; font-size: .92em; line-height: 1.5; vertical-align: 1px; transition: transform .15s; }
:root[data-theme="dark"] .tchip { color: var(--accent-l); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .tchip { color: var(--accent-l); } }
.tchip svg { width: 15px; height: 15px; } .tchip:active { transform: scale(.94); }
.notes { margin-top: 22px; padding: 16px 18px; background: var(--paper2); border-radius: var(--r); } .notes h3 { font-size: 18px; } .notes p { margin: 6px 0 0; white-space: pre-wrap; }
.src { color: var(--ink3); font-size: 13.5px; margin: 18px 0 0; font-style: italic; font-family: var(--serif); }

/* ---------- editor ---------- */
.editor .r-top { position: sticky; top: calc(52px + var(--safe-t)); z-index: 5; background: var(--paper); padding: 6px 8px; }
@media (min-width: 900px) { .editor .r-top { top: 0; } .editor { max-width: 760px; } }
.ed-h { font-size: 22px; margin-left: 4px; }
.ed-photo { position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--r); overflow: hidden; border: 0; padding: 0; background: var(--paper2); margin-top: 6px; }
.ed-photo-l { position: absolute; left: 50%; bottom: 14px; transform: translateX(-50%); display: inline-flex; gap: 8px; align-items: center; padding: 9px 16px; border-radius: 999px; background: rgba(20, 15, 10, .66); color: #fff; font-weight: 600; font-size: 14px; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.ed-photo-l svg { width: 18px; height: 18px; }

/* ---------- sheets ---------- */
#sheets { position: relative; z-index: 80; }
.sheet-wrap { position: fixed; inset: 0; z-index: 80; display: flex; align-items: flex-end; justify-content: center; }
.sheet-bg { position: absolute; inset: 0; background: rgba(20, 12, 6, .38); opacity: 0; transition: opacity .25s; }
.sheet { position: relative; width: 100%; max-height: min(88vh, 900px); overflow: auto; overscroll-behavior: contain; background: var(--paper); border-radius: 24px 24px 0 0; padding: 4px 18px calc(18px + var(--safe-b)); box-shadow: var(--shadow-lg); transform: translateY(100%); transition: transform .34s var(--ease); outline: none; }
.sheet-wrap.in .sheet-bg { opacity: 1; } .sheet-wrap.in .sheet { transform: none; }
.sheet-wrap.out .sheet-bg { opacity: 0; } .sheet-wrap.out .sheet { transform: translateY(100%); transition-duration: .24s; }
.grab { width: 100%; height: 22px; position: sticky; top: 0; cursor: grab; touch-action: none; display: flex; justify-content: center; align-items: center; }
.grab::after { content: ""; width: 40px; height: 5px; border-radius: 3px; background: var(--line2); }
.sheet-h { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin: 0 -8px 6px 0; }
.sheet-h h2 { font-size: 24px; }
@media (min-width: 700px) {
  .sheet-wrap { align-items: center; }
  .sheet { width: min(480px, calc(100% - 40px)); border-radius: 24px; padding: 8px 24px 24px; transform: translateY(24px) scale(.97); opacity: 0; transition: transform .3s var(--ease), opacity .25s; }
  .sheet.wide { width: min(640px, calc(100% - 40px)); }
  .sheet-wrap.in .sheet { opacity: 1; } .sheet-wrap.out .sheet { transform: translateY(12px) scale(.98); opacity: 0; }
  .grab { display: none; }
}
.menu { display: flex; flex-direction: column; margin: 0 -8px; }
.menu-i { display: flex; align-items: center; gap: 14px; padding: 13px 10px; border: 0; background: none; border-radius: 12px; text-align: left; font-size: 16px; }
.menu-i:hover { background: var(--accent-soft); }
.menu-i svg { color: var(--ink2); flex: none; } .menu-i span { flex: 1; } .menu-i small { display: block; color: var(--ink2); font-size: 13px; }
.menu-i.danger, .menu-i.danger svg { color: var(--danger); }
#toast { width: max-content; position: fixed; left: 50%; bottom: calc(var(--tabh) + var(--safe-b) + 14px); transform: translate(-50%, 20px); z-index: 120; display: flex; align-items: center; gap: 12px; max-width: calc(100% - 32px); padding: 11px 12px 11px 18px; border-radius: 16px; background: var(--ink); color: var(--paper); font-size: 14.5px; box-shadow: var(--shadow-lg); opacity: 0; pointer-events: none; transition: opacity .2s, transform .3s var(--spring); }
#toast.on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
#toast:not(:has(button)) { padding-right: 18px; }
#toast button { border: 0; background: color-mix(in srgb, var(--paper) 18%, transparent); color: var(--paper); font-weight: 700; padding: 7px 12px; border-radius: 10px; white-space: nowrap; }

/* ---------- import ---------- */
.paste-box { position: relative; }
.paste-box textarea { width: 100%; border: 1.5px solid var(--line2); background: var(--card); border-radius: var(--r); padding: 14px; outline: none; resize: vertical; font-size: 15px; line-height: 1.5; min-height: 180px; }
.paste-box textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.paste-tools { display: flex; gap: 8px; margin-top: 8px; }
.imp-prev:empty { display: none; }
.imp-card { display: grid; grid-template-columns: 96px 1fr; gap: 14px; margin-top: 14px; padding: 12px; border-radius: var(--r); background: var(--card); box-shadow: var(--shadow); animation: rise .35s var(--ease); }
.imp-card .pic { border-radius: 12px; aspect-ratio: 1; height: auto; }
.imp-card h3 { font-size: 19px; line-height: 1.2; } .imp-card ul { margin: 6px 0 0; padding-left: 18px; font-size: 13.5px; }

/* ---------- plan ---------- */
.wk-nav { display: flex; align-items: center; gap: 4px; }
.wk-nav .icon-btn { background: var(--card); box-shadow: var(--shadow); }
.pro-dot { position: absolute; top: 6px; right: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.pro-banner { display: flex; align-items: center; gap: 12px; margin: 12px 0; padding: 12px 14px; border-radius: var(--r); background: var(--accent-soft); }
.pro-banner > svg { color: var(--accent-t); flex: none; } .pro-banner p { margin: 0; flex: 1; font-size: 14px; }
.tray-wrap { margin: 14px -16px 4px; padding: 12px 0 10px; background: var(--paper2); border-block: 1px solid var(--line); position: sticky; top: calc(52px + var(--safe-t)); z-index: 6; }
@media (min-width: 900px) { .tray-wrap { margin: 16px 0 6px; border-radius: var(--r); border: 1px solid var(--line); top: 12px; } }
.tray-h { display: flex; align-items: center; gap: 10px; padding: 0 16px 8px; font-size: 13.5px; color: var(--ink2); }
.tray-h b { flex: 1; font-weight: 600; }
.tray-s { position: relative; display: flex; align-items: center; } .tray-s svg { position: absolute; left: 9px; width: 16px; height: 16px; color: var(--ink3); }
.tray-s input { width: 96px; height: 34px; border-radius: 999px; border: 1px solid var(--line2); background: var(--card); padding: 0 10px 0 30px; outline: none; font-size: 14px; transition: width .25s var(--ease); }
.tray-s input:focus { width: 150px; border-color: var(--accent); }
.tray { display: flex; gap: 10px; overflow-x: auto; padding: 2px 16px 4px; scrollbar-width: none; }
.tray::-webkit-scrollbar { display: none; }
.tray-r { flex: none; width: 104px; border-radius: 14px; background: var(--card); box-shadow: var(--shadow); overflow: hidden; cursor: grab; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; transition: transform .2s var(--ease); }
.tray-r .pic { aspect-ratio: 4 / 3; height: auto; pointer-events: none; }
.tray-r span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin: 6px 8px 8px; font: 600 12.5px/1.2 var(--sans); }
.tray-r:active { transform: scale(.96); }
.tray-empty { padding: 10px 0; }
.days { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
@media (min-width: 900px) { .days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; align-items: stretch; } }
.day { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); padding: 10px 10px 8px; display: grid; grid-template-columns: 54px 1fr; gap: 0 10px; border: 2px solid transparent; transition: border-color .2s, background .2s, transform .2s var(--ease); }
.day header { grid-row: span 2; display: flex; flex-direction: column; align-items: center; padding-top: 4px; }
.dname { font: 700 11.5px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink2); }
.dnum { font: 600 28px/1.1 var(--serif); }
.today-tag { font: 700 10px/1 var(--sans); color: var(--on-accent); background: var(--accent); border-radius: 6px; padding: 3px 5px; margin-top: 3px; letter-spacing: .04em; text-transform: uppercase; }
.day.today { border-color: var(--accent-l); }
.day.today .dnum, .day.today .dname { color: var(--accent-t); }
.day.past { opacity: .72; }
.day.over { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 6%, var(--card)); transform: scale(1.01); }
.pe-list { display: flex; flex-direction: column; gap: 6px; min-height: 36px; }
.day-empty { margin: 0; padding: 8px 2px; color: var(--ink3); font: italic 15px/1.3 var(--serif); }
.day-add { justify-self: start; display: inline-flex; align-items: center; gap: 4px; border: 0; background: none; color: var(--accent-t); font-weight: 700; font-size: 13.5px; padding: 8px 6px; min-height: 36px; border-radius: 10px; }
.day-add svg { width: 17px; height: 17px; } .day-add:hover { background: var(--accent-soft); }
@media (min-width: 900px) {
  .day { grid-template-columns: 1fr; min-height: 300px; align-content: start; padding: 10px 8px; }
  .day header { grid-row: auto; flex-direction: row; gap: 6px; align-items: baseline; padding: 0 2px 8px; }
  .dnum { font-size: 22px; } .today-tag { margin: 0 0 0 auto; }
  .day-add { margin-top: 2px; }
}
.pe { display: grid; grid-template-columns: 46px 1fr auto; align-items: center; gap: 10px; padding: 6px; border-radius: 12px; background: var(--paper2); cursor: grab; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: manipulation; transition: transform .2s var(--ease), opacity .2s, box-shadow .2s; position: relative; }
.pe:hover { box-shadow: inset 0 0 0 1.5px var(--line2); }
.pe-pic { width: 46px; height: 46px; border-radius: 9px; pointer-events: none; }
.pe-t { min-width: 0; line-height: 1.2; } .pe-t b { display: block; font-size: 14.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pe-t small { display: flex; flex-wrap: wrap; align-items: center; gap: 0 3px; font-size: 11.5px; color: var(--ink2); } .pe-t small svg { width: 13px; height: 13px; }
.pe-t small:first-child { font-weight: 700; color: var(--accent-t); letter-spacing: .02em; }
.pe-grip { color: var(--ink3); } .pe-grip svg { width: 18px; height: 18px; }
.pe.left { background: color-mix(in srgb, var(--herb) 10%, var(--paper2)); } .pe.left .pe-t small:first-child { color: var(--herb); }
.pe.eaten .pe-t b { text-decoration: line-through; text-decoration-color: var(--ink3); color: var(--ink2); }
@media (min-width: 900px) { .pe { grid-template-columns: 1fr; padding: 5px; } .pe-pic { width: 100%; height: auto; aspect-ratio: 4 / 3; } .pe-grip { display: none; } .pe-t b { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; } }
.pe.lifting, .tray-r.lifting { opacity: .3; transform: scale(.97); }
.drag-ghost { position: fixed !important; z-index: 200; pointer-events: none; box-shadow: var(--shadow-lg) !important; opacity: .96; margin: 0; transition: none !important; }
body.dragging, body.dragging * { cursor: grabbing !important; -webkit-user-select: none; user-select: none; }
.drop-mark { height: 4px; border-radius: 2px; background: var(--accent); margin: 2px 0; animation: mark .2s var(--ease); }
@keyframes mark { from { transform: scaleX(.3); opacity: 0; } }
.landed { animation: landed .55s var(--spring); }
@keyframes landed { 0% { transform: scale(.85); opacity: .4; } 60% { transform: scale(1.04); } }
.plan-foot { display: flex; gap: 10px; justify-content: center; margin: 22px 0 0; flex-wrap: wrap; }
.day-pick { display: grid; grid-template-columns: repeat(7, 1fr); gap: 5px; margin: 6px 0 14px; }
.day-pick button { display: flex; flex-direction: column; align-items: center; padding: 8px 0 6px; border-radius: 12px; border: 1.5px solid var(--line2); background: var(--card); min-height: 62px; transition: all .2s var(--ease); }
.day-pick small { font-size: 11px; color: var(--ink2); font-weight: 600; } .day-pick b { font: 600 19px/1.2 var(--serif); } .day-pick i { font-style: normal; color: var(--accent-t); font-size: 10px; line-height: 1; height: 8px; letter-spacing: 1px; }
.day-pick button[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); } .day-pick button[aria-pressed="true"] small, .day-pick button[aria-pressed="true"] i { color: inherit; }
.day-pick button:disabled { opacity: .35; }
.cd-r, .log-card { display: flex; align-items: center; gap: 12px; padding: 8px; background: var(--card); border-radius: 14px; box-shadow: var(--shadow); margin-bottom: 14px; }
.cd-r .pic, .log-card .pic { width: 56px; height: 56px; border-radius: 10px; flex: none; }
.cd-r b, .log-card b { font: 600 17px/1.2 var(--serif); } .log-card small { display: block; color: var(--ink2); font-size: 13px; }
.pick-list { display: flex; flex-direction: column; gap: 4px; max-height: 52vh; overflow: auto; margin: 0 -6px; }
.pick { display: grid; grid-template-columns: 52px 1fr 24px; gap: 12px; align-items: center; padding: 6px; border: 0; background: none; border-radius: 12px; text-align: left; }
.pick:hover { background: var(--accent-soft); }
.pick .pic { width: 52px; height: 52px; border-radius: 10px; } .pick b { display: block; font-weight: 600; } .pick small { color: var(--ink2); font-size: 12.5px; } .pick > svg { color: var(--accent-t); }

/* ---------- shopping list ---------- */
.ring { position: relative; width: 64px; height: 64px; flex: none; }
.ring svg { width: 64px; height: 64px; transform: rotate(-90deg); }
.ring circle { fill: none; stroke: var(--line); stroke-width: 4; }
.ring circle.fg { stroke: var(--herb); stroke-linecap: round; stroke-dasharray: 119.4; stroke-dashoffset: calc(119.4 * (1 - var(--p) / 100)); transition: stroke-dashoffset .6s var(--ease); }
.ring b { position: absolute; inset: 0; display: grid; place-items: center; font: 600 15px/1 var(--serif); }
.offer { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin: 12px 0; padding: 14px; border-radius: var(--r); background: color-mix(in srgb, var(--herb) 12%, var(--card)); border: 1px solid color-mix(in srgb, var(--herb) 30%, transparent); }
.offer p { margin: 0; flex: 1 1 220px; font-size: 14px; } .offer span { display: flex; gap: 8px; margin-left: auto; }
.add-item { display: flex; gap: 8px; margin: 16px 0 6px; position: relative; }
.add-item input { flex: 1; min-width: 0; height: 50px; border-radius: 14px; border: 1.5px dashed var(--line2); background: transparent; padding: 0 16px; outline: none; transition: all .2s; }
.add-item input:focus { border-style: solid; border-color: var(--accent); background: var(--card); box-shadow: 0 0 0 4px var(--accent-soft); }
.add-item .icon-btn { width: 50px; height: 50px; border-radius: 14px; background: var(--accent); color: var(--on-accent); }
.glist { display: grid; gap: 4px 28px; }
.glist > * { min-width: 0; }
@media (min-width: 900px) { .glist { grid-template-columns: 1fr 1fr; align-items: start; } .gg.basket, .gg.fold { grid-column: 1 / -1; } }
.gg { margin-top: 16px; }
.gg h2 { display: flex; align-items: center; gap: 8px; font: 700 12.5px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink2); padding: 0 2px 8px; }
.gg h2 small { margin-left: auto; font-weight: 600; color: var(--ink3); letter-spacing: 0; }
.gg h2 .emo { font-size: 17px; letter-spacing: 0; }
.gg-t { display: flex; align-items: center; gap: 8px; width: 100%; border: 0; background: none; padding: 0; font: inherit; letter-spacing: inherit; text-transform: inherit; color: inherit; min-height: 32px; }
.gg-t svg { width: 18px; height: 18px; transition: transform .25s var(--ease); } .gg-t[aria-expanded="true"] svg { transform: rotate(90deg); }
.gg-t small { margin-left: auto; }
.gg ul { list-style: none; margin: 0; padding: 0; background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.fold-note { margin: -2px 2px 0; }
.gi { display: flex; align-items: center; border-bottom: 1px solid var(--line); position: relative; }
.gi:last-child { border-bottom: 0; }
.gi-b { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; padding: 12px 6px 12px 14px; border: 0; background: none; text-align: left; min-height: 56px; }
.gi-box { width: 26px; height: 26px; flex: none; border-radius: 50%; border: 2px solid var(--line2); display: grid; place-items: center; transition: background .3s var(--ease), border-color .3s, transform .3s var(--spring); }
.gi-box svg { width: 17px; height: 17px; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 22; stroke-dashoffset: 22; transition: stroke-dashoffset .35s var(--ease) .08s; }
.gi-t { flex: 1; min-width: 0; } .gi-t b { display: block; font-weight: 600; position: relative; width: fit-content; max-width: 100%; }
.gi-t b::after { content: ""; position: absolute; left: -2px; right: -2px; top: 52%; height: 1.6px; background: var(--ink2); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease) .1s; }
.gi-t small { display: block; color: var(--ink3); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gi-a { flex: none; font-variant-numeric: tabular-nums; font-weight: 600; color: var(--ink2); font-size: 14.5px; text-align: right; max-width: 40%; }
.gi-m { margin-right: 4px; color: var(--ink3); }
.gi.done .gi-box { background: var(--herb); border-color: var(--herb); }
.gi.done .gi-box svg { stroke-dashoffset: 0; }
.gi.done .gi-t b::after { transform: scaleX(1); }
.gi.done .gi-t b, .gi.done .gi-a { color: var(--ink3); }
.gi.ticking .gi-box { animation: tickpop .45s var(--spring); }
.gi.ticking { animation: tickrow .52s var(--ease); }
@keyframes tickpop { 40% { transform: scale(1.25); } }
@keyframes tickrow { 0%, 60% { background: color-mix(in srgb, var(--herb) 10%, transparent); } }
.gi.staple .gi-b { opacity: .85; }
.basket ul { opacity: .9; }
.spark { position: fixed; width: 7px; height: 7px; border-radius: 2px; z-index: 300; pointer-events: none; }
.confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 300; pointer-events: none; }
.list-acts { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 26px 0 0; }
.spent { text-align: center; display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 16px; } .spent svg { width: 17px; height: 17px; }
.list-empty .basket-art { color: var(--ink); margin: 0 auto 4px; animation: bob 4s ease-in-out infinite; width: 200px; }
@keyframes bob { 50% { transform: translateY(-5px) rotate(-1deg); } }
.aisle-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.aisle-pick button { display: flex; align-items: center; gap: 8px; padding: 10px; border-radius: 12px; border: 1.5px solid var(--line2); background: var(--card); text-align: left; font-size: 14px; }
.aisle-pick button[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.money-in { position: relative; } .money-in b { position: absolute; left: 14px; bottom: 13px; font: 600 22px/1 var(--serif); color: var(--ink2); }
.money-in input { padding-left: 38px !important; font-variant-numeric: tabular-nums; }

/* ---------- timers ---------- */
#timer-tray { position: fixed; left: 12px; right: 12px; bottom: calc(var(--tabh) + var(--safe-b) + 10px); z-index: 50; display: flex; flex-direction: column; gap: 8px; pointer-events: none; align-items: flex-start; }
body.cook-on #timer-tray { display: none; }
.tmr { pointer-events: auto; display: flex; align-items: center; gap: 10px; padding: 6px 6px 6px 8px; border-radius: 999px; background: var(--ink); color: var(--paper); box-shadow: var(--shadow-lg); animation: rise .3s var(--spring); }
.tmr-ring { width: 34px; height: 34px; transform: rotate(-90deg); }
.tmr-ring circle { fill: none; stroke: color-mix(in srgb, var(--paper) 25%, transparent); stroke-width: 3.5; }
.tmr-ring circle + circle { stroke: var(--butter); stroke-dasharray: 97.4; stroke-linecap: round; transition: stroke-dashoffset .25s linear; }
.tmr-t b { display: block; font: 600 17px/1 var(--serif); font-variant-numeric: tabular-nums; } .tmr-t small { font-size: 11.5px; opacity: .75; }
.tmr .icon-btn { color: var(--paper); } .tmr .icon-btn:hover { background: rgba(255, 255, 255, .12); }
.tmr.rang { background: var(--accent); animation: ring 1s ease-in-out infinite; }
@keyframes ring { 0%, 100% { transform: rotate(0); } 10% { transform: rotate(-3deg); } 20% { transform: rotate(3deg); } 30% { transform: rotate(0); } }

/* ---------- cook mode ---------- */
.cook { position: fixed; inset: 0; z-index: 90; display: flex; flex-direction: column; background: #1d1814; color: #f6efe5; opacity: 0; transform: scale(1.02); transition: opacity .3s, transform .35s var(--ease); --ink2: #c4b6a6; --line: #3a322b; --paper2: #2a241f; --card: #2a241f; }
.cook:focus { outline: none; }
.cook.in { opacity: 1; transform: none; } .cook.out { opacity: 0; transform: scale(.98); }
.ck-top { display: flex; align-items: center; gap: 8px; padding: calc(8px + var(--safe-t)) 10px 4px; }
.ck-top .icon-btn { color: #f6efe5; } .ck-top .icon-btn:hover { background: rgba(255, 255, 255, .08); }
.ck-title { flex: 1; min-width: 0; line-height: 1.2; } .ck-title small { display: block; font: 700 10.5px/1.4 var(--sans); letter-spacing: .12em; text-transform: uppercase; color: var(--butter); } .ck-title b { display: block; font: 600 16px/1.2 var(--serif); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ck-mic.on { background: var(--accent) !important; animation: mic 1.6s ease-in-out infinite; }
@keyframes mic { 50% { box-shadow: 0 0 0 8px rgba(200, 85, 61, .25); } }
.ck-ing-b { background: transparent !important; color: #f6efe5 !important; border-color: #4a4038 !important; }
.ck-dots { display: flex; gap: 5px; padding: 6px 16px 0; }
.ck-dots i { flex: 1; height: 4px; border-radius: 2px; background: #3a322b; transition: background .3s; }
.ck-dots i.past { background: var(--accent-l); } .ck-dots i.on { background: var(--butter); }
.ck-body { flex: 1; display: flex; min-height: 0; position: relative; }
.ck-ings { position: absolute; inset: 0 0 0 auto; width: min(360px, 88vw); z-index: 3; background: #26201b; padding: 18px 18px 24px; overflow: auto; transform: translateX(105%); transition: transform .32s var(--ease); box-shadow: -20px 0 40px rgba(0, 0, 0, .35); }
.ck-ings.open { transform: none; }
.ck-ings h2 { font-size: 22px; margin-bottom: 8px; } .ck-ings h2 small { font: 500 13px var(--sans); color: var(--ink2); }
.ck-ings ul { list-style: none; margin: 0; padding: 0; }
.ck-ings button { width: 100%; display: grid; grid-template-columns: 24px auto 1fr; gap: 10px; align-items: baseline; text-align: left; border: 0; border-bottom: 1px solid #3a322b; background: none; color: inherit; padding: 10px 0; font-size: 16px; }
.ck-ings .box { align-self: center; width: 20px; height: 20px; border-radius: 6px; border: 2px solid #5a4e44; display: grid; place-items: center; } .ck-ings .box svg { width: 14px; height: 14px; stroke-width: 3; transform: scale(0); transition: transform .25s var(--spring); }
.ck-ings button.done { opacity: .45; } .ck-ings button.done .box { background: var(--herb); border-color: var(--herb); } .ck-ings button.done .box svg { transform: none; }
.ck-ings .amt { font-weight: 700; white-space: nowrap; }
@media (min-width: 1000px) { .ck-ings { position: static; transform: none; box-shadow: none; border-right: 1px solid #3a322b; background: transparent; width: 340px; } .ck-ing-b { display: none !important; } }
.ck-stage { flex: 1; display: flex; align-items: center; justify-content: center; padding: 16px 22px; overflow: auto; touch-action: pan-y; }
.ck-step { max-width: 820px; width: 100%; }
.ck-step.from-r { animation: fromR .38s var(--ease); } .ck-step.from-l { animation: fromL .38s var(--ease); }
@keyframes fromR { from { opacity: 0; transform: translateX(40px); } } @keyframes fromL { from { opacity: 0; transform: translateX(-40px); } }
.ck-n { font: 700 13px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--butter); margin: 0 0 16px; } .ck-n span { color: var(--ink2); }
.ck-text { font: 450 clamp(26px, 6.6vw, 46px)/1.32 var(--serif); margin: 0; letter-spacing: -.01em; text-wrap: pretty; font-variation-settings: "SOFT" 60; }
.ck-text .tchip { background: rgba(242, 193, 78, .16); color: var(--butter); font: 700 .7em/1.4 var(--sans); vertical-align: .14em; padding: 3px 10px 3px 7px; }
.ck-tbtns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; }
.timer-big { background: var(--butter); color: #2a1f0e; font-size: 17px; min-height: 52px; }
.ck-used { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; padding: 0; margin: 26px 0 0; }
.ck-used li { padding: 7px 12px; border-radius: 999px; background: #2a241f; font-size: 14.5px; color: #e9ddcf; } .ck-used b { color: #fff; }
.ck-done { text-align: center; } .ck-done h2 { font-size: clamp(30px, 7vw, 48px); margin: 0 0 10px; text-wrap: balance; }
.ck-done-pic { width: 200px; height: 150px; margin: 0 auto 22px; border-radius: 20px; overflow: hidden; box-shadow: 0 20px 50px rgba(0, 0, 0, .5); animation: landed .7s var(--spring); }
.ck-timers { display: flex; gap: 8px; padding: 0 14px; overflow-x: auto; }
.ck-t { flex: none; display: flex; align-items: center; gap: 8px; padding: 6px 6px 6px 14px; border-radius: 999px; background: #2e2722; }
.ck-t b { font: 600 20px/1 var(--serif); font-variant-numeric: tabular-nums; color: var(--butter); } .ck-t small { font-size: 12px; color: var(--ink2); max-width: 140px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ck-t .icon-btn { color: #f6efe5; }
.ck-t.rang { background: var(--accent); } .ck-t.rang b { color: #fff; }
.ck-foot { display: flex; align-items: center; gap: 12px; padding: 12px 14px calc(14px + var(--safe-b)); }
.ck-foot .btn { flex: 0 0 auto; min-width: 120px; } .ck-foot .btn.ghost { background: transparent; color: #f6efe5; border-color: #4a4038; }
.ck-foot #ck-next { flex: 1; max-width: 420px; margin-left: auto; min-height: 60px; font-size: 18px; }
.ck-hint { flex: 1; text-align: center; font-size: 13px; color: var(--ink2); }
@media (max-width: 520px) { .ck-hint { display: none; } .ck-foot .btn.ghost span { display: none; } .ck-foot .btn.ghost { min-width: 60px; } }

/* ---------- picker ---------- */
.lo-card { width: 100%; display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin-bottom: 14px; border-radius: 14px; border: 0; text-align: left; background: color-mix(in srgb, var(--herb) 14%, var(--card)); color: var(--ink); }
.lo-card > svg:first-child { color: var(--herb); } .lo-card span { flex: 1; } .lo-card b { display: block; } .lo-card small { color: var(--ink2); }
.spin { perspective: 900px; margin: 18px 0 4px; }
.spin-card { border-radius: 22px; overflow: hidden; background: var(--card); box-shadow: var(--shadow-lg); transform-origin: 50% 100%; }
.spin-pic { aspect-ratio: 4 / 3; background: var(--paper2); }
.spin-t { padding: 14px 18px 18px; min-height: 104px; } .spin-t h3 { font-size: 24px; line-height: 1.15; text-wrap: balance; } .spin-t p { margin: 4px 0 0; }
.spin-card.land { animation: land .6s var(--spring); }
@keyframes land { 0% { transform: rotateX(18deg) translateY(-14px) scale(.96); } }

/* ---------- settings ---------- */
.set { padding: 6px 0 14px; border-bottom: 1px solid var(--line); } .set:last-child { border: 0; }
.set h3 { font: 700 12.5px/1 var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink2); margin: 14px 0 6px; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 8px 0; }
.set-row > span small { display: block; color: var(--ink2); font-size: 12.5px; }
.set-col { padding: 8px 0; }
.swatches { display: flex; flex-wrap: wrap; gap: 10px; margin: 10px 0 6px; }
.sw { display: flex; flex-direction: column; align-items: center; gap: 5px; border: 0; background: none; padding: 2px; width: 66px; }
.sw i { width: 40px; height: 40px; border-radius: 50%; background: var(--c); box-shadow: inset 0 0 0 3px var(--paper), 0 0 0 2px transparent; transition: box-shadow .2s, transform .2s var(--spring); }
.sw[aria-pressed="true"] i { box-shadow: inset 0 0 0 3px var(--paper), 0 0 0 2.5px var(--c); transform: scale(1.06); }
.sw small { font-size: 11.5px; color: var(--ink2); text-align: center; line-height: 1.2; }
.conn { margin: 4px 0 12px; padding-left: 18px; font-size: 14px; color: var(--ink2); } .conn b { color: var(--ink); }
.pro-on { display: flex; align-items: center; gap: 8px; color: var(--herb); font-weight: 600; }
.about { font-size: 13px; color: var(--ink2); }
.pal { display: flex; gap: 6px; margin: 12px 0; } .pal i { flex: 1; height: 44px; border-radius: 10px; }

/* ---------- onboarding ---------- */
.onb { position: fixed; inset: 0; z-index: 100; background: var(--paper); display: flex; align-items: center; justify-content: center; padding: calc(20px + var(--safe-t)) 22px calc(20px + var(--safe-b)); overflow: auto; opacity: 0; transition: opacity .35s; }
.onb.in { opacity: 1; } .onb.out { opacity: 0; pointer-events: none; }
.onb-in:focus { outline: none; }
.onb-in { max-width: 440px; width: 100%; text-align: center; display: flex; flex-direction: column; align-items: center; }
.onb-fan { position: relative; width: 280px; height: 170px; margin: 0 auto 18px; }
.onb-fan img { position: absolute; left: 50%; top: 10px; width: 170px; aspect-ratio: 4 / 3; height: auto; border-radius: 16px; box-shadow: var(--shadow-lg); transform: translateX(-50%) rotate(calc((var(--k) - 1) * 12deg)) translateX(calc((var(--k) - 1) * 52px)) translateY(calc(var(--k) * -1px + (var(--k) - 1) * (var(--k) - 1) * 10px)); animation: fan .9s var(--spring) both; animation-delay: calc(var(--k) * 90ms + .1s); }
.onb-fan img:nth-child(2) { z-index: 2; }
@keyframes fan { from { transform: translateX(-50%) translateY(40px) rotate(0) scale(.8); opacity: 0; } }
.onb-h { font-size: 64px; line-height: 1; letter-spacing: -.035em; font-variation-settings: "SOFT" 100, "WONK" 1; }
.onb-p { font: italic 400 20px/1.4 var(--serif); color: var(--ink2); margin: 12px 0 20px; }
.onb-l { list-style: none; margin: 0 0 24px; padding: 0; text-align: left; display: flex; flex-direction: column; gap: 12px; width: 100%; }
.onb-l li { display: flex; gap: 12px; align-items: center; font-size: 15px; color: var(--ink2); }
.onb-l svg { flex: none; width: 38px; height: 38px; padding: 8px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-t); }
.onb-l b { color: var(--ink); }
.onb .btn.big { width: 100%; }
.onb-yz { margin-top: 18px; font-size: 13px; color: var(--ink3); }

/* ---------- transitions ---------- */
::view-transition-old(root), ::view-transition-new(root) { animation-duration: .3s; animation-timing-function: cubic-bezier(.2, .8, .2, 1); }
:root[data-dir="fwd"]::view-transition-old(root) { animation-name: vtOutL; } :root[data-dir="fwd"]::view-transition-new(root) { animation-name: vtInR; }
:root[data-dir="back"]::view-transition-old(root) { animation-name: vtOutR; } :root[data-dir="back"]::view-transition-new(root) { animation-name: vtInL; }
:root[data-dir="tab"]::view-transition-old(root) { animation-name: vtFadeOut; animation-duration: .18s; } :root[data-dir="tab"]::view-transition-new(root) { animation-name: vtFadeIn; animation-duration: .26s; }
@keyframes vtOutL { to { opacity: 0; transform: translateX(-30px); } } @keyframes vtInR { from { opacity: 0; transform: translateX(30px); } }
@keyframes vtOutR { to { opacity: 0; transform: translateX(30px); } } @keyframes vtInL { from { opacity: 0; transform: translateX(-30px); } }
@keyframes vtFadeOut { to { opacity: 0; } } @keyframes vtFadeIn { from { opacity: 0; transform: translateY(6px); } }
::view-transition-group(*) { animation-duration: .38s; animation-timing-function: cubic-bezier(.2, .8, .2, 1); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-delay: 0ms !important; transition-duration: .001ms !important; }
  ::view-transition-group(*), ::view-transition-old(*), ::view-transition-new(*) { animation: none !important; }
}
