/* App layer on top of the brand kit (vt.css). All colors come from the kit's tokens. */
html, body { margin: 0; height: 100%; width: 100%; overflow: hidden; }
body { background: #F6F5F3; overscroll-behavior: none; -webkit-tap-highlight-color: transparent; }
@media (prefers-color-scheme: dark) { body { background: #121318; } }
body.theme-dark { background: #121318; }
body.theme-light { background: #F6F5F3; }
/* (the wide-screen frame colours are in the min-width block below, for both themes) */
#app { position: fixed; inset: 0; max-width: 560px; margin: 0 auto; box-shadow: 0 0 0 1px var(--border-subtle); }
.boot { flex: 1; display: flex; align-items: center; justify-content: center; }
.boot img { animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .4; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* ---------- fixes on top of vt.css ---------- */
.vt .btn-primary { color: var(--on-brand); }
.vt .btn-secondary { color: var(--text-primary); }
.vt .btn-tertiary { color: var(--brand); }
.vt .btn-danger { color: #FFFFFF; }
.vt.dark .btn-danger { color: #2A0F0F; }
.vt .btn.c-danger, .vt .icon-btn.c-danger { color: var(--danger); }
.vt .btn:disabled { opacity: .45; cursor: default; }
.vt-body > *, .sheet > * { flex-shrink: 0; }
.card.row, .card.row-3 { flex-direction: row; align-items: center; }
.vt button { cursor: pointer; }
.vt :focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
[hidden] { display: none !important; }

/* ---------- screen layout ---------- */
.screen { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; }
.screen > .vt-top { padding: calc(env(safe-area-inset-top, 0px) + 14px) 16px 8px; min-height: 0; }
.screen > .vt-body { overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; padding-bottom: 32px; }
.vt-nav { height: auto; padding: 6px 8px calc(env(safe-area-inset-bottom, 0px) + 8px); }
.vt-nav a { cursor: pointer; min-height: 48px; justify-content: center; }
.vt-nav .add { cursor: pointer; }
.title-btn { display: inline-flex; align-items: center; gap: 4px; background: none; border: 0; padding: 0; color: inherit; font: inherit; }

/* ---------- small components ---------- */
.flip-ltr { } [dir="ltr"] .flip-ltr { transform: scaleX(-1); }
.flip-rtl { } [dir="rtl"] .flip-rtl { transform: scaleX(-1); }
.avatar { width: 40px; height: 40px; border-radius: 999px; background: var(--brand-subtle); color: var(--brand); display: inline-flex; align-items: center; justify-content: center; font-weight: 600; font-size: 16px; flex-shrink: 0; overflow: hidden; border: 0; padding: 0; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.s { width: 32px; height: 32px; font-size: 13px; }
.avatar.l { width: 72px; height: 72px; font-size: 28px; font-family: var(--font-display-ar); }
.avatar.k1 { background: var(--accent-subtle); color: var(--accent); }
.avatar.k2 { background: var(--warning-subtle); color: var(--warning); }
.avatar.n { background: var(--bg-item-tile); color: var(--text-secondary); }
.avatar.f { background: var(--info-subtle); color: var(--info); }
.stack { display: flex; }
.stack .avatar { border: 2px solid var(--bg-surface); margin-inline-start: -8px; }
.stack .avatar:first-child { margin-inline-start: 0; }
.notif { position: relative; }
.ndot { position: absolute; top: 8px; inset-inline-end: 8px; min-width: 9px; height: 9px; border-radius: 9px; background: var(--danger); border: 2px solid var(--bg-canvas); }
.icon-btn.on { color: var(--brand); }
.icon-btn:disabled { opacity: .4; }
.lay3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.lay3 .tall { grid-row: span 2; aspect-ratio: auto; min-height: 100%; }
.lay3 .tall img { height: 78%; }
.tile { cursor: default; }
.tile img { pointer-events: none; }
.tile.photo img { width: 100%; height: 100%; object-fit: contain; } /* brand rule: never crop the piece */
.tile .swapb, .tile .pinb { position: absolute; width: 30px; height: 30px; border-radius: 999px; display: flex; align-items: center; justify-content: center; box-shadow: var(--elevation-1); border: 0; padding: 0; }
.tile .swapb { bottom: 6px; inset-inline-end: 6px; background: var(--bg-surface); color: var(--text-secondary); }
.tile .pinb { top: 6px; inset-inline-start: 6px; background: var(--bg-surface); color: var(--text-tertiary); }
.tile .pinb.on { background: var(--brand); color: var(--on-brand); }
.tile.sel { outline: 2.5px solid var(--brand); outline-offset: -2.5px; }
a.tile-link, button.tile-link { display: block; text-align: start; background: none; border: 0; padding: 0; color: inherit; cursor: pointer; }
.mini { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.mini .tile { border-radius: 8px; }
.mini3 { display: grid; grid-template-columns: repeat(3, 44px); gap: 4px; }
.mini3 .tile { border-radius: 8px; }
.stat .lbl { font-size: 12px; line-height: 18px; color: var(--text-tertiary); font-weight: 500; }
.stat.c { align-items: center; text-align: center; padding: 12px 8px; }
.stat.c .num { font-size: 20px; line-height: 28px; }
.list.flat { border: 1px solid var(--border-subtle); }
.li { text-align: start; width: 100%; background: transparent; border-inline: 0; border-top: 0; font: inherit; color: inherit; }
button.li { cursor: pointer; }
.li .lead.brand { background: var(--brand-subtle); color: var(--brand); }
.li .lead.sage { background: var(--accent-subtle); color: var(--accent); }
.li .lead.info { background: var(--info-subtle); color: var(--info); }
.li .lead.warn { background: var(--warning-subtle); color: var(--warning); }
.li .lead.ok { background: var(--success-subtle); color: var(--success); }
.li .lead.danger { background: var(--danger-subtle); color: var(--danger); }
.li.unread { background: var(--brand-subtle); }
.opt { background: var(--bg-surface); border: 1px solid var(--border-subtle); border-radius: 16px; padding: 16px; display: flex; flex-direction: column; gap: 10px; text-align: start; font: inherit; color: inherit; cursor: pointer; }
.opt .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--brand-subtle); color: var(--brand); display: flex; align-items: center; justify-content: center; }
.composer { display: flex; gap: 8px; align-items: center; padding: 8px 16px 12px; background: var(--bg-canvas); border-top: 1px solid var(--border-subtle); }
.composer input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; font: inherit; color: var(--text-primary); }
.composer .input { border-radius: 999px; height: 48px; }
.send { width: 48px; height: 48px; border-radius: 999px; background: var(--brand); color: var(--on-brand); border: 0; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.bubble { white-space: pre-wrap; }
.bubble.ai.card-b { padding: 12px; display: flex; flex-direction: column; gap: 10px; width: 86%; max-width: 86%; }
.typing { display: inline-flex; gap: 4px; }
.typing i { width: 7px; height: 7px; border-radius: 9px; background: var(--text-tertiary); animation: blink 1.2s infinite; }
.typing i:nth-child(2) { animation-delay: .2s; } .typing i:nth-child(3) { animation-delay: .4s; }
@keyframes blink { 50% { opacity: .25; } }
.swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.swatches .s { width: 36px; height: 36px; border-radius: 999px; border: 1px solid var(--border-default); position: relative; padding: 0; cursor: pointer; }
.swatches .s.on { outline: 2px solid var(--brand); outline-offset: 2px; }
.swatches.big .s { width: 44px; height: 44px; cursor: default; }
.ftitle { font-size: 14px; font-weight: 600; color: var(--text-secondary); }
.perm { display: flex; gap: 6px; flex-wrap: wrap; }
.perm .badge { height: 24px; }
.mut { text-decoration: line-through; color: var(--text-tertiary); }
.hint-row { display: flex; align-items: center; gap: 6px; font-size: 12px; line-height: 18px; color: var(--text-tertiary); }
.mk-l { width: 7px; height: 7px; border-radius: 9px; display: inline-block; }
.chip { cursor: pointer; font-family: inherit; }
.chip:disabled { opacity: .5; }
/* touch targets: the small controls keep their 36px look, their tappable area is 44px tall (an invisible layer, no layout change) */
.vt .btn-sm, .vt .chip, .vt .tabs button, .vt .toggle { position: relative; }
.vt .btn-sm::before, .vt .chip::before, .vt .tabs button::before { content: ""; position: absolute; inset: -4px 0; }
.vt .toggle::before { content: ""; position: absolute; inset: -8px -4px; }
.vt span.chip::before { content: none; }
/* a choice made of radio inputs that look like chips (gender) — 44px to touch */
.choice { display: flex; flex-wrap: wrap; gap: 8px; border: 0; padding: 0; margin: 0; }
.choice legend { padding: 0; margin-bottom: 6px; font-size: 14px; font-weight: 600; }
.choice .chip { height: 44px; position: relative; }
.choice .chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.choice .chip:has(input:checked) { background: var(--brand); border-color: var(--brand); color: var(--on-brand); }
.choice .chip:has(input:focus-visible) { outline: 2px solid var(--brand); outline-offset: 2px; }
.chips.scroll { overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.chips.scroll::-webkit-scrollbar { display: none; }
.hscroll { overflow-x: auto; scrollbar-width: none; }
.hscroll::-webkit-scrollbar { display: none; }
.tabs span, .tabs button { cursor: pointer; border: 0; background: transparent; font: inherit; flex: 1; height: 36px; border-radius: 999px; display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 500; color: var(--text-secondary); white-space: nowrap; padding: 0 6px; }
.tabs .on { background: var(--brand); color: var(--on-brand); }
.toggle { border: 0; padding: 0; cursor: pointer; }
.check { cursor: pointer; padding: 0; }
.search input, .input input, .input select, textarea.input { flex: 1; min-width: 0; border: 0; background: transparent; outline: none; font: inherit; color: var(--text-primary); }
.search { color: var(--text-tertiary); }
.search input::placeholder, .input input::placeholder, textarea.input::placeholder { color: var(--text-tertiary); }
.input:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-subtle); }
/* The rounded wrapper owns the focus cue; avoid a second square ring on its inner editor. */
.vt .input :is(input, textarea, select):is(:focus, :focus-visible) { outline: none; box-shadow: none; }
textarea.input { height: auto; min-height: 88px; padding: 12px 14px; resize: vertical; }
select.input, .input select { appearance: none; background: transparent; }
.attr .v input, .attr .v select { width: 100%; border: 0; background: transparent; font: inherit; color: inherit; outline: none; padding: 6px 0; }
.attr .v select { appearance: none; }
.attr .v input::placeholder { color: var(--text-tertiary); font-weight: 400; }
.harm { display: flex; align-items: center; gap: 14px; }
.harm .ring { width: 64px; height: 64px; border-radius: 999px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.harm .ring.ok { background: var(--success-subtle); color: var(--success); }
.harm .ring.warn { background: var(--warning-subtle); color: var(--warning); }
.harm .ring.wait { background: var(--bg-item-tile); color: var(--text-tertiary); }
.cal .d { border: 0; padding: 4px 0 0; font: inherit; color: inherit; cursor: pointer; }
/* a day's colour is the cell itself (the legend's colours, lightened so the number stays readable); no dots.
   (until 2026-10-23: a dot per state under the number, and the selected day in --brand-subtle) */
.cal .d.sel { box-shadow: inset 0 0 0 1.5px var(--text-tertiary); }
.cal .d .n { position: relative; z-index: 1; line-height: 16px; }
.st-worn { --st: var(--success); }
.st-plan { --st: #D2689C; } /* pink: the legend's plum (--brand) reads grey-mauve once lightened */
.vt.dark .st-plan { --st: var(--brand); } /* (in dark mode --brand is already pink) */
.st-travel { --st: var(--accent); }
.cal .d[class*="st-"], .li[class*="st-"], .cal-week[class*="st-"] { background: color-mix(in srgb, var(--st) 18%, var(--bg-surface)); }
.cal .d.out[class*="st-"] { background: color-mix(in srgb, var(--st) 9%, transparent); }
.cal .d.today { box-shadow: none; }
.cal-week.today { outline: 2px solid var(--brand); outline-offset: -2px; }
.cal-pv { display: block; width: 78%; aspect-ratio: 3 / 4; border-radius: 6px; overflow: hidden; background: var(--bg-item-tile); cursor: zoom-in; flex-shrink: 0; }
.cal-pv img { width: 100%; height: 100%; object-fit: cover; max-height: none; }
.cal .d .cal-pv { width: auto; height: calc(100% - 26px); }
.cal .d .cal-pv img { width: 100%; height: 100%; max-height: none; object-fit: cover; }
.li .cal-pv { width: 44px; height: 44px; aspect-ratio: auto; border-radius: 8px; }
.cal-pv-big { display: block; width: 100%; height: auto; border-radius: 16px; background: var(--bg-item-tile); }
.cal .d img { max-height: 55%; object-fit: contain; }
.cal .d .mk { left: 50%; transform: translateX(-50%); }
/* a day can carry two dots side by side (travel + planned event) */
.cal .d .mks { position: absolute; bottom: 4px; left: 50%; transform: translateX(-50%); display: flex; gap: 3px; }
.cal .d .mks .mk { position: static; transform: none; }
.cal .d .mk.travel { background: var(--accent); }
.badge-warn { background: var(--warning-subtle); color: var(--ai-processing); }
.input.title-btn.error { border: 1px solid var(--danger); }
.empty img { opacity: .9; }
.skeleton { background: linear-gradient(90deg, var(--bg-item-tile), var(--border-subtle), var(--bg-item-tile)); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 12px; }
@keyframes sk { to { background-position: -200% 0; } }
.spin { width: 18px; height: 18px; border-radius: 999px; border: 2px solid currentColor; border-top-color: transparent; animation: rot .8s linear infinite; display: inline-block; }
@keyframes rot { to { transform: rotate(360deg); } }
.tryon { position: relative; aspect-ratio: 3 / 4; border-radius: 16px; background: var(--bg-item-tile); overflow: hidden; display: flex; align-items: center; justify-content: center; }
.tryon img { width: 100%; height: 100%; object-fit: cover; }
.tryon .badge { position: absolute; top: 8px; inset-inline-start: 8px; }
.tryon .fig { width: 70%; color: var(--border-default); }
.grid-photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.grid-photos button { aspect-ratio: 3/4; border-radius: 12px; overflow: hidden; border: 0; padding: 0; background: var(--bg-item-tile); position: relative; }
.grid-photos button img { width: 100%; height: 100%; object-fit: cover; }
.grid-photos button.sel { outline: 2.5px solid var(--brand); outline-offset: -2.5px; }
.palette-row { display: flex; gap: 6px; }
.palette-row i { width: 18px; height: 18px; border-radius: 999px; border: 1px solid var(--border-default); }
.legend-ai { display: flex; gap: 12px; }
.err-text { color: var(--danger); font-size: 13px; }
.center { text-align: center; }
.mt-auto { margin-top: auto; }
.w100 { width: 100%; }
.nowrap { white-space: nowrap; }
.ellipsis { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- overlays ---------- */
.overlay { position: absolute; inset: 0; z-index: 50; }
.overlay .scrim { animation: fade .22s ease-out; }
.overlay .sheet { max-height: 88%; overflow-y: auto; padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 24px); animation: up .26s cubic-bezier(.2, 0, 0, 1); }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: 0; } }
.toast { position: absolute; bottom: calc(env(safe-area-inset-bottom, 0px) + 96px); z-index: 80; animation: up .22s ease-out; }
.toast.no-nav { bottom: calc(env(safe-area-inset-bottom, 0px) + 24px); }

/* camera / file pick busy layer */
.busy { position: absolute; inset: 0; z-index: 70; background: var(--scrim); display: flex; align-items: center; justify-content: center; }
.busy .card { align-items: center; text-align: center; max-width: 280px; }

/* login */
.login-hero { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 40px 16px 8px; text-align: center; }
.login-hero .wm { font-family: var(--font-display); font-weight: 500; font-size: 30px; letter-spacing: .18em; }
.login-hero .wm-ar { font-family: var(--font-display-ar); font-weight: 700; font-size: 24px; }

/* wide screens: keep the phone column, add breathing room */
@media (min-width: 600px) {
  #app { top: 16px; bottom: 16px; border-radius: 28px; overflow: hidden; box-shadow: 0 20px 60px rgba(21,22,26,.18); }
  body { background: #E4E2DE; }
}
@media (min-width: 600px) and (prefers-color-scheme: dark) { body { background: #0B0C0F; } }
@media (min-width: 600px) { body.theme-light { background: #E4E2DE; } body.theme-dark { background: #0B0C0F; } }
.attr .swatches .s { width: 28px; height: 28px; }

/* in-app camera (design 05) */
/* a label photo (review, the piece's care section) */
.label-card { display: inline-flex; align-items: center; gap: 8px; border: 0; background: var(--bg-item-tile); border-radius: 10px; padding: 4px 10px 4px 4px; font: inherit; font-size: 13px; color: var(--text-secondary); cursor: pointer; min-height: 44px; align-self: flex-start; }
.label-card img { width: 36px; height: 36px; border-radius: 8px; object-fit: cover; }
.tile .pinzone { position: absolute; inset: 0; border: 0; background: transparent; padding: 0; cursor: pointer; border-radius: inherit; }
.tile .pinzone:focus-visible { outline: 2px solid var(--brand); outline-offset: -2px; }
.tile .pin { z-index: 1; pointer-events: none; }
.tile .swapb { z-index: 2; }

/* care symbols */
.care-row { display: flex; flex-wrap: wrap; gap: 8px; }
.care-ic { width: 46px; height: 46px; border-radius: 12px; border: 1px solid var(--border-subtle); background: var(--bg-surface); color: var(--text-primary); display: flex; align-items: center; justify-content: center; padding: 0; cursor: pointer; }
.care-ic:active { background: var(--brand-subtle); }
.care-big { width: 96px; height: 96px; border-radius: 24px; background: var(--brand-subtle); color: var(--brand); display: flex; align-items: center; justify-content: center; }
.care-pick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.care-opt { display: flex; align-items: center; gap: 8px; min-height: 48px; padding: 6px 10px; border-radius: 12px; border: 1px solid var(--border-default); background: var(--bg-surface); color: var(--text-primary); font: inherit; font-size: 13px; text-align: start; cursor: pointer; }
.care-opt.on { border-color: var(--brand); background: var(--brand-subtle); color: var(--brand); }
.care-opt svg { flex-shrink: 0; }

/* web photo picker on the review screen */
.pick-photos { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pick-photos .ph { position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--bg-item-tile); border: 0; padding: 0; cursor: pointer; }
.pick-photos .ph img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.pick-photos .ph.sel { outline: 2.5px solid var(--brand); outline-offset: -2.5px; }
.pick-photos .ph .tag { position: absolute; inset-inline: 4px; bottom: 4px; font-size: 11px; line-height: 16px; padding: 0 5px; border-radius: 999px; background: rgba(21,22,26,.66); color: #F6F5F3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pick-photos .ph .ok { position: absolute; top: 4px; inset-inline-start: 4px; width: 20px; height: 20px; border-radius: 999px; background: var(--brand); color: var(--on-brand); display: flex; align-items: center; justify-content: center; }
.hero-photo { width: 104px; flex-shrink: 0; }
/* travel (trips) */
.card.flash { box-shadow: 0 0 0 2px var(--accent); }
.meter { height: 8px; border-radius: 99px; background: var(--bg-item-tile); overflow: hidden; }
.meter > span { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.meter.over > span { background: var(--danger); }
.pack-row { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 14px; background: transparent; border: 0; border-bottom: 1px solid var(--border-subtle); text-align: start; cursor: pointer; color: inherit; font: inherit; }
.pack-row:last-child { border-bottom: 0; }
.pack-row .txt { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.pack-row.done .txt > :first-child { text-decoration: line-through; color: var(--text-tertiary); }
.pack-thumb { width: 44px; flex-shrink: 0; }
.pack-thumb .tile { border-radius: 10px; }
/* laundry */
.care-mini { display: inline-flex; gap: 4px; color: var(--text-secondary); margin-top: 4px; }
.pick-tile { position: relative; }
.pick-tile.sel .tile { outline: 2.5px solid var(--brand); outline-offset: -2.5px; }
/* composite preview: the pieces grid is the ground, a generated picture is a layer (never stretched or cut) */
.c-warn { color: var(--warning); }
.cprev-wrap { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.cprev { position: relative; }
.cprev-grid { transition: opacity .2s; }
.cprev.busy .cprev-grid { opacity: .4; }
.cprev-layer { position: relative; border-radius: 16px; overflow: hidden; background: var(--bg-item-tile); aspect-ratio: 3 / 4; opacity: 0; transition: opacity .2s; }
.cprev-layer.in { opacity: 1; }
.cprev-layer img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center; }
.cprev-layer .badge { position: absolute; top: 8px; inset-inline-start: 8px; }
.cprev-layer .cprev-old { top: 36px; }
.cprev-grid.under { display: none; }
.cprev-wait { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center; padding: 16px; font-size: 14px; font-weight: 500; color: var(--text-primary); }
.cprev-ctl { display: flex; flex-direction: column; gap: 8px; }
.cprev-ctl .btn, .cprev-ctl .tabs button { min-height: 44px; }
.cprev-orient { width: 100%; }
/* home: the date and, beside it, the weather now — a line of its own over the greeting and the buttons
   (a very long city name is cut, never pushed to a new line) */
.home-top { flex-wrap: wrap; row-gap: 2px; }
.home-date { flex-basis: 100%; gap: 8px; align-items: center; flex-wrap: nowrap; min-width: 0; }
.home-date > .t-sm { flex-shrink: 0; white-space: nowrap; }
.home-date .weather { display: block; min-width: 0; height: 26px; line-height: 26px; padding: 0 10px; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-date .weather svg { vertical-align: -3px; width: 14px; height: 14px; margin-inline-end: 4px; }
/* home: today's (or tomorrow's) look — a tap blurs it and shows two buttons over it */
.today-card { cursor: pointer; }
.today-look { position: relative; }
.today-look .cprev-wrap { transition: filter .2s; }
.today-look.menu .cprev-wrap { filter: blur(10px); pointer-events: none; }
.today-menu { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px; }
.today-menu[hidden] { display: none; }
.today-menu .btn { min-height: 48px; min-width: 200px; }
.cprev-wrap[data-auto="1"][data-orient="landscape"] .cprev-layer { aspect-ratio: 4 / 3; }
@media (prefers-reduced-motion: reduce) { .today-look .cprev-wrap { transition: none; } }
.cprev-strip { display: flex; flex-wrap: wrap; gap: 8px; }
.cprev-strip[hidden] { display: none; }
.cprev-strip .tile-link { width: 56px; flex: 0 0 56px; }
.cprev-strip .tile { border-radius: 10px; }
/* mini: the picture takes the first square; a small spinner while one is being made */
.cprev-mini .cprev-layer { position: absolute; top: 0; inset-inline-start: 0; width: calc((100% - 18px) / 4); aspect-ratio: 1 / 1; border-radius: 8px; z-index: 1; }
.cprev-mini .cprev-layer .badge { display: none; }
.cprev-mini .cprev-grid.under { display: block; }
.cprev-mini.spinning .cprev::after { content: ""; position: absolute; top: 4px; inset-inline-end: 4px; width: 14px; height: 14px; border-radius: 99px; border: 2px solid var(--brand); border-top-color: transparent; animation: rot .8s linear infinite; }
.consent-row { align-items: flex-start; min-height: 44px; }
.consent-row input { width: 20px; height: 20px; margin-top: 2px; flex-shrink: 0; accent-color: var(--brand); }
@media (prefers-reduced-motion: reduce) { .cprev-grid, .cprev-layer { transition: none; } }
.cprev-wait > span:last-child { background: var(--bg-surface); padding: 4px 12px; border-radius: 999px; box-shadow: var(--elevation-1, 0 1px 3px rgba(0,0,0,.12)); }

/* Product preparation and explicit post-save matching. */
.product-intake-photo { width:100%; height:340px; object-fit:contain; border-radius:16px; background:repeating-conic-gradient(#c5c8cc 0% 25%,#e8eaed 0% 50%) 50%/20px 20px; }
.product-match-slot:empty { display:none; }
.product-match-card { border:1px solid var(--brand); padding:12px; gap:10px; }
.product-match-pair { display:grid; grid-template-columns:1fr 1fr; gap:10px; }
.product-match-pair img { display:block; width:100%; height:120px; border-radius:10px; object-fit:contain; background:repeating-conic-gradient(#c5c8cc 0% 25%,#e8eaed 0% 50%) 50%/20px 20px; }
@media(max-width:380px){.product-match-pair img{height:110px}.product-intake-photo{height:290px}}

.product-match-toggle {display:flex;flex-direction:column;gap:10px;width:100%;padding:0;text-align:start;color:inherit;}
.product-match-heading {width:100%;gap:10px;align-items:flex-start;}
.product-match-heading strong {font-size:14px;line-height:1.4;flex:1;}
.product-match-heading .badge {flex-shrink:0;font-size:11px;}
.product-match-toggle .product-match-pair {width:100%;}

/* Match actions use the same blurred overlay treatment as today's look. */
.product-match-card {position:relative;overflow:hidden;}
.product-match-toggle {transition:filter .2s;}
.product-match-card.menu .product-match-toggle {filter:blur(10px);pointer-events:none;}
.product-match-menu {position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:16px;background:rgba(0,0,0,.12);}
.product-match-menu .btn {min-height:48px;min-width:min(200px,100%);}
@media(prefers-reduced-motion:reduce){.product-match-toggle {transition:none;}}

.processing-entry {display:flex;flex-direction:column;gap:10px;}
.processing-card {display:flex;flex-direction:row;align-items:center;gap:14px;padding:12px;}
.processing-card>img {width:110px;height:125px;flex-shrink:0;object-fit:contain;border-radius:12px;background:var(--bg-secondary,#24262c);}
.processing-meta {display:flex;gap:10px;align-items:center;font-size:13px;}
.processing-field {display:inline-flex;align-items:center;gap:6px;text-align:start;min-height:28px;padding:0;color:inherit;}
.processing-field strong {font-size:15px;line-height:1.4;overflow-wrap:anywhere;}
.processing-add {width:64px;height:56px;align-self:center;border-radius:18px;}
.processing-empty {text-align:center;padding:30px 16px;}
@media(max-width:380px){.processing-card>img{width:90px;height:115px}.processing-actions .btn{font-size:13px;padding-inline:10px;}}

.product-match-menu>.row {width:100%;max-width:320px;gap:10px;}
.product-match-menu>.row .btn {min-width:0;flex:1;padding-inline:10px;}
.product-match-preview {display:flex;flex-direction:column;gap:14px;}
.product-match-preview .product-match-pair img {height:170px;}
.product-preview-actions {position:sticky;bottom:0;padding:12px 0;background:var(--bg-surface,#1b1d22);}
.product-preview-actions .btn {min-width:0;padding-inline:10px;}
.product-match-preview .attr {gap:10px;}
.product-match-preview .attr .v {overflow-wrap:anywhere;}

.product-match-preview-trigger {align-self:center;min-width:120px;}
.product-match-card.menu .product-match-preview-trigger {visibility:hidden;pointer-events:none;}

.processing-image-placeholder {width:110px;height:125px;flex-shrink:0;display:flex;align-items:center;justify-content:center;border-radius:12px;background:var(--bg-secondary,#24262c);color:var(--text-tertiary,#999);}
@media(max-width:380px){.processing-image-placeholder{width:90px;height:115px;}}

/* Shared specialist selector: same controls and identity across registration and settings. */
.stylist-picker-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,280px),1fr));gap:14px}.stylist-profile-choice{width:100%;text-align:start;gap:14px;color:inherit;border:1px solid var(--border-default);cursor:pointer}.stylist-profile-choice.selected{border-color:var(--accent);box-shadow:inset 0 0 0 1px var(--accent)}.stylist-profile-avatar{height:76px;width:76px;object-fit:cover;border-radius:24px;flex-shrink:0;background:var(--bg-item-tile)}.stylist-profile-avatar.small{width:44px;height:44px;border-radius:50%}.stylist-profile-choice .c-2{white-space:pre-wrap;overflow-wrap:anywhere}.stylist-profile-check{display:grid;place-items:center;flex-shrink:0;width:25px;height:25px;border-radius:50%;border:1px solid var(--border-default)}.stylist-profile-check svg{opacity:0}.stylist-profile-choice.selected .stylist-profile-check{background:var(--accent);color:var(--on-brand)}.stylist-profile-choice.selected .stylist-profile-check svg{opacity:1}

.offline-status{position:fixed;bottom:calc(90px + env(safe-area-inset-bottom,0px));inset-inline-end:16px;z-index:30;max-width:calc(100vw - 32px);padding:9px 15px;border-radius:999px;background:#4A1F3D;color:#fff;font-size:12px;text-decoration:none;box-shadow:0 3px 14px #0002;}

.tile{position:relative;isolation:isolate}.tile>.badge{position:absolute;top:8px;inset-inline-start:8px;z-index:4}.tile img{position:relative;z-index:0}
.auth-transition>.processing-state{max-width:300px}

/* Guided capture: the preview is the photo. The whole frame stays visible and the controls sit around it, never over it. */
#app > .cam-ov { position: fixed; inset: 0; z-index: 90; background: #171717; container-type: size; }
.vt.cam {
  --camera-text: #fff;
  --camera-yellow: #ffe354;
  position: absolute; inset: 0; isolation: isolate; box-sizing: border-box;
  display: grid; gap: 8px; align-items: center; justify-items: center;
  grid-template: "close dest torch" auto "vf vf vf" minmax(0, 1fr) "note note note" auto "gal shoot ." auto "steps steps steps" auto / 48px minmax(0, 1fr) 48px;
  padding: calc(env(safe-area-inset-top, 0px) + 6px) calc(env(safe-area-inset-right, 0px) + 16px) calc(env(safe-area-inset-bottom, 0px) + 8px) calc(env(safe-area-inset-left, 0px) + 16px);
  background: #171717; color: var(--camera-text); overflow: hidden;
}
.cam [hidden] { display: none; }
.cam-header, .cam-footer, .cam-bar { display: contents; }
.cam [data-c=close] { grid-area: close; }
.cam-destination { grid-area: dest; }
.cam [data-c=torch] { grid-area: torch; }
.cam .vf { grid-area: vf; position: relative; align-self: stretch; justify-self: stretch; display: grid; place-items: center; min-width: 0; min-height: 0; }
.cam-instruction { grid-area: note; }
.cam-thumb { grid-area: gal; }
.cam .shutter { grid-area: shoot; }
.cam-steps { grid-area: steps; }
.cam .vf :is(video, .cam-freeze) { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.cam-destination, .cam-control, .cam-skip, .cam-steps {
  background: transparent; border: 1px solid #ffffff66;
  box-shadow: inset 0 1px 0 #ffffff33, 0 2px 8px #0003;
}
.cam-destination {
  max-width: 100%; min-width: 0; overflow: hidden; text-overflow: ellipsis; box-sizing: border-box;
  white-space: nowrap; font-size: 12px; padding: 8px 14px; border-radius: 999px;
}
.cam-control, .cam-skip { color: var(--camera-text); font: inherit; cursor: pointer; }
.cam-control {
  display: grid; place-items: center;
  inline-size: 46px; block-size: 46px; border-radius: 50%; padding: 0;
}
.cam-control[aria-pressed=true] { color: var(--camera-yellow); background: #0003; }
.cam-control:focus-visible, .cam-skip:focus-visible, .cam .shutter:focus-visible {
  outline: 2px solid var(--camera-yellow); outline-offset: 3px;
}
.cam-fallback { position: relative; margin: 12px; text-align: center; font-size: 13px; }
.cam-steps {
  width: min(100%, 390px); box-sizing: border-box;
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px;
  padding: 4px; border-radius: 22px;
}
.cam-steps span {
  display: flex; justify-content: center; align-items: center; gap: 4px;
  border-radius: 999px; text-align: center; padding: 4px 3px;
  min-height: 34px; box-sizing: border-box; font-size: 11px; line-height: 1.2;
}
.cam-steps svg { flex-shrink: 0; }
.cam-steps span.on { background: #ffffff1f; color: var(--camera-yellow); }
.cam-instruction { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; }
.cam-hint { margin: 0; font-size: 13px; line-height: 1.35; text-align: center; }
.cam-skip {
  flex-shrink: 0; min-height: 44px; border-radius: 999px;
  padding-inline: 15px; font-size: 12px; font-weight: 700; color: var(--camera-yellow);
}
.cam-thumb { border-radius: 14px; overflow: hidden; }
.cam-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cam .shutter {
  inline-size: 72px; block-size: 72px;
  border: 3px solid #fff9fc; border-radius: 50%; padding: 4px;
  display: grid; place-items: center; background: transparent; cursor: pointer;
}
.cam .shutter::after { content: ""; border-radius: 50%; width: 100%; height: 100%; background: #efd0e3; }
.cam .shutter:active::after { transform: scale(.92); }
.cam .shutter:disabled { opacity: .55; }
/* A tall phone: the 3:4 frame spans the full width of the screen. */
@container (max-aspect-ratio: 53/100) {
  .cam .vf { margin-inline: -16px; }
}
/* Short portrait windows (closed or upright Duo, SE, iPad): controls move beside the frame, so it keeps its width. */
@container (min-aspect-ratio: 53/100) and (max-aspect-ratio: 1/1) {
  .vt.cam {
    grid-template: "dest close" auto "vf torch" auto "vf shoot" minmax(0, 1fr) "vf gal" auto "note note" auto "steps steps" auto / minmax(0, 1fr) 72px;
    padding-inline: calc(env(safe-area-inset-left, 0px) + 10px) calc(env(safe-area-inset-right, 0px) + 10px);
  }
  .cam-instruction { min-height: 0; }
}
/* Landscape: one column of controls; the frame has the full height. */
@container (min-aspect-ratio: 1/1) {
  .vt.cam { grid-template: "vf close . torch" auto "vf dest dest dest" auto "vf note note note" minmax(0, 1fr) "vf gal shoot ." auto "vf steps steps steps" auto / minmax(0, 1fr) 56px 72px 56px; }
  .cam-instruction { flex-direction: column; }
}
/* A partly folded Duo: the frame on one side of the fold, the controls on the other. */
@container (min-width: 1px) {
  .vt.cam[data-fold=columns] {
    direction: ltr; padding: 0; column-gap: 0;
    grid-template: ". . . . . ." calc(env(safe-area-inset-top, 0px) + 6px) "vf . close . torch ." auto "vf . dest dest dest ." auto "vf . note note note ." minmax(0, 1fr) "vf . gal shoot . ." auto "vf . steps steps steps ." auto ". . . . . ." calc(env(safe-area-inset-bottom, 0px) + 4px)
      / var(--fold-first) calc(var(--fold-gap) + 12px) 56px minmax(72px, 1fr) 56px calc(env(safe-area-inset-right, 0px) + 12px);
  }
  .vt.cam[data-fold=rows] {
    padding-block: 0; row-gap: 0;
    grid-template: "vf vf vf" var(--fold-first) ". . ." var(--fold-gap) "close dest torch" auto "note note note" minmax(0, 1fr) "gal shoot ." auto "steps steps steps" auto ". . ." calc(env(safe-area-inset-bottom, 0px) + 8px) / 48px minmax(0, 1fr) 48px;
  }
  .cam[data-fold=rows] .vf { margin-block-start: env(safe-area-inset-top, 0px); margin-inline: 0; }
  .cam[data-fold=columns] .vf { margin-inline: env(safe-area-inset-left, 0px) 0; }
}
.ref-laundry-body .laundry-empty{margin-block-start:20px}
.readiness-extra{display:block;margin-top:5px;font-weight:400}
@media(prefers-reduced-motion:reduce){.typing i{animation:none;opacity:.65}}
/* Approved account preparation: an opaque wipe replaces each silhouette. */
.account-preparation{display:flex;flex-direction:column;align-items:center;gap:18px;text-align:center;color:var(--brand)}
.account-preparation>p{font-size:18px;color:var(--text-primary);margin:0}
.account-portrait{position:relative;width:180px;height:220px;direction:ltr}
.account-portrait svg{position:absolute;inset:0;width:100%;height:100%;fill:currentColor;stroke:none}
.account-portrait path{fill-opacity:.58}
.account-portrait-woman{background:var(--bg-canvas);clip-path:inset(0 100% 0 0);animation:account-portrait-reveal 6s ease-in-out infinite}
.account-portrait-scan{position:absolute;inset:8px auto 8px 0;width:1px;background:currentColor;box-shadow:0 0 12px color-mix(in srgb,currentColor 30%,transparent);animation:account-portrait-scan 6s ease-in-out infinite}
@keyframes account-portrait-reveal{0%,8%{clip-path:inset(0 100% 0 0)}44%,56%{clip-path:inset(0 0 0 0)}92%,100%{clip-path:inset(0 100% 0 0)}}
@keyframes account-portrait-scan{0%,8%{transform:translateX(0)}44%,56%{transform:translateX(180px)}92%,100%{transform:translateX(0)}}
@media(prefers-reduced-motion:reduce){.account-portrait-woman,.account-portrait-scan{animation:none}.account-portrait-woman{clip-path:inset(0 0 0 50%)}.account-portrait-scan{transform:translateX(90px)}}
.auth-transition:has(.account-preparation){background:var(--bg-canvas)}
