@charset "UTF-8";

:root {
  color-scheme: light;
  --purple: #7254d3;
  --purple-dark: #5e40bd;
  --purple-light: #f0ecfb;
  --ink: #35234f;
  --muted: #665079;
  --quiet: #725c84;
  --line: #eae8ef;
  --canvas: #f7f7fa;
  --green: #668b6f;
  --radius: 14px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  font-size: 14px;
  line-height: 1.5;
  color: var(--ink);
  background: var(--canvas);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; min-width: 320px; }
button, input, select, textarea { font: inherit; }
button, input, select { -webkit-tap-highlight-color: transparent; }
button { cursor: pointer; color: inherit; border: 0; background: none; padding: 0; }
button:disabled { opacity: .45; cursor: not-allowed; }
button, a, input, select { touch-action: manipulation; }
button, a { transition: background-color .16s ease, color .16s ease, border-color .16s ease, box-shadow .16s ease; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible {
  outline: 3px solid #a48de5;
  outline-offset: 3px;
}
input, select { min-width: 0; max-width: 100%; color: var(--ink); }
input::placeholder { color: #583969; opacity: 1; }
input[type="search"]::-webkit-search-cancel-button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.3; }
svg { flex-shrink: 0; }
.icon { width: 20px; height: 20px; vertical-align: middle; }
.skip-link { position: fixed; top: -70px; left: 24px; z-index: 100; padding: 12px 18px; border-radius: 10px; color: #fff; background: var(--purple); }
.skip-link:focus { top: 14px; }
.button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 44px; padding: 10px 17px; border: 1px solid transparent; border-radius: 9px; font-size: 12px; font-weight: 600; line-height: 1.4; white-space: nowrap; }
.button .icon { width: 17px; height: 17px; }
.button.primary { background: var(--purple); color: #fff; }
.button.primary:hover:not(:disabled) { background: var(--purple-dark); }
.button.secondary { background: #fff; border-color: #e3e0ea; color: #595564; }
.button.secondary:hover:not(:disabled) { background: #f8f6fe; border-color: #c9bde9; color: var(--purple); }
.button.full { width: 100%; }
.button.full + .button.full { margin-top: 10px; }
.icon-button, .tiny-button, .title-edit { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 40px; height: 40px; border-radius: 9px; color: var(--muted); }
.icon-button:hover, .tiny-button:hover, .title-edit:hover { background: var(--purple-light); color: var(--purple); }
.icon-button .icon { width: 18px; height: 18px; }
.bordered { border: 1px solid var(--line); background: white; }
.text-button { display: inline-flex; align-items: center; gap: 7px; min-height: 40px; color: var(--purple); font-size: 12px; font-weight: 600; }
.text-button .icon { width: 15px; }
.danger-text { color: #bf535b !important; }

/* A quiet, permanent home for lists. */
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 20; width: 222px; padding: 35px 20px 18px; display: flex; flex-direction: column; background: #fff; border-right: 1px solid var(--line); overflow-y: auto; }
.brand { display: flex; align-items: center; gap: 9px; padding-left: 8px; color: #53406e; font-size: 31px; line-height: 1; font-weight: 750; letter-spacing: -1.8px; }
.brand-symbol { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 34px; height: 36px; background: var(--purple); color: #fffaf1; border-radius: 10px; }
.brand-symbol .icon { width: 23px; height: 23px; }
.brand-dot { margin-left: -9px; color: var(--purple); }
.brand-tagline { padding-left: 8px; margin-top: 12px; color: var(--quiet); font-size: 12px; letter-spacing: .15px; }
.nav-label { color: #725585; font-size: 11px; font-weight: 650; letter-spacing: 1.4px; }
.sidebar > .nav-label { margin: 42px 12px 12px; }
.sidebar nav { display: grid; gap: 5px; }
.nav-item { display: flex; align-items: center; gap: 11px; width: 100%; min-height: 44px; padding: 0 12px; text-align: left; border-radius: 8px; color: #583969; font-size: 12px; font-weight: 500; }
.nav-item .icon { width: 18px; height: 18px; }
.nav-item:hover { background: #f9f7fd; color: var(--purple); }
.nav-item.active { background: var(--purple-light); color: var(--purple); font-weight: 650; }
.nav-count { display: grid; place-items: center; margin-left: auto; min-width: 21px; height: 21px; border-radius: 6px; background: #e7dff8; color: #725585; font-size: 12px; }
.sidebar-lists { margin-top: 23px; }
.sidebar-section-title { display: flex; align-items: center; justify-content: space-between; padding-left: 12px; }
.tiny-button .icon { width: 14px; height: 14px; }
.list-nav { display: flex; align-items: center; width: 100%; gap: 9px; padding: 0 12px; min-height: 40px; border-radius: 8px; text-align: left; color: #583969; font-size: 13px; }
.list-nav:hover { background: #faf8fd; color: var(--purple); }
.list-nav > span:nth-child(2) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-nav.selected { color: #5d516e; font-weight: 600; }
.list-dot { flex-shrink: 0; width: 6px; height: 6px; border-radius: 50%; background: #b6d0bc; }
.list-nav.selected .list-dot { background: #b29adf; }
.list-nav small { margin-left: auto; font-size: 12px; color: var(--quiet); }
.new-list-button { display: flex; align-items: center; justify-content: center; gap: 7px; min-height: 38px; width: calc(100% - 16px); margin: 11px 8px 0; border: 1px dashed #dad3e7; border-radius: 7px; color: #725585; font-size: 12px; }
.new-list-button .icon { width: 13px; height: 13px; }
.new-list-button:hover { color: var(--purple); border-color: var(--purple); background: #faf8ff; }
.sidebar-bottom { margin-top: auto; padding-top: 44px; }
.local-card { padding: 16px 14px 10px; background: #f7f8f6; border: 1px solid #eff1eb; border-radius: 11px; }
.local-icon { display: block; margin-bottom: 8px; color: #8da18a; }
.local-icon .icon { width: 19px; height: 19px; }
.local-card strong { display: block; font-size: 12px; font-weight: 650; color: #777f70; }
.local-card p { margin-top: 6px; font-size: 11px; line-height: 1.7; color: #a2a797; }
.local-card button { display: flex; align-items: center; gap: 7px; min-height: 37px; font-size: 11px; font-weight: 600; color: #88937d; }
.local-card button .icon { width: 12px; height: 12px; }
.profile-button { display: flex; align-items: center; gap: 9px; width: 100%; padding-top: 18px; text-align: left; }
.avatar { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 32px; flex-shrink: 0; border-radius: 50%; background: #f1edf8; color: #725585; }
.avatar .icon { width: 15px; height: 15px; }
.profile-button strong { display: block; font-size: 11px; font-weight: 600; color: #583969; }
.profile-button small { display: block; margin-top: 2px; font-size: 10px; color: #725585; }
.profile-button > .icon { margin-left: auto; width: 13px; height: 13px; color: #725585; }

/* Workspace and the three at-a-glance totals. */
.workspace { min-height: 100vh; margin-left: 222px; }
.sidebar { scrollbar-width: none; -ms-overflow-style: none; }
.sidebar::-webkit-scrollbar { display: none; width: 0; height: 0; }
.sidebar-brand-row { display: flex; align-items: center; justify-content: space-between; gap: 4px; flex-shrink: 0; }
.sidebar-brand-row .brand { gap: 7px; padding-left: 0; font-size: 28px; }
.sidebar-toggle { width: 32px; height: 40px; }
.sidebar-toggle:hover { color: var(--purple-dark); background: var(--purple-light); }
.sidebar-backup, .list-short-icon { display: none; }
@media (min-width: 761px) {
  .sidebar-collapsed .sidebar { width: 76px; padding: 24px 12px 18px; }
  .sidebar-collapsed .workspace { margin-left: 76px; }
  .sidebar-collapsed .sidebar-brand-row { flex-direction: column; gap: 12px; }
  .sidebar-collapsed .sidebar-toggle { width: 44px; }
  .sidebar-collapsed .brand-word, .sidebar-collapsed .brand-tagline,
  .sidebar-collapsed .sidebar .nav-label, .sidebar-collapsed .nav-item > span,
  .sidebar-collapsed .sidebar-section-title, .sidebar-collapsed .list-nav > span:not(.list-short-icon),
  .sidebar-collapsed .list-nav > small, .sidebar-collapsed .new-list-button > span,
  .sidebar-collapsed .local-card, .sidebar-collapsed .profile-button > span:not(.avatar),
  .sidebar-collapsed .profile-button > .icon { display: none; }
  .sidebar-collapsed .sidebar nav { margin-top: 22px; }
  .sidebar-collapsed .nav-item, .sidebar-collapsed .list-nav { justify-content: center; padding: 0; min-height: 44px; }
  .sidebar-collapsed .list-short-icon { display: inline-flex; }
  .sidebar-collapsed .sidebar-lists { border-top: 1px solid var(--line); padding-top: 15px; }
  .sidebar-collapsed .new-list-button { width: 100%; min-height: 44px; margin: 12px 0 0; }
  .sidebar-collapsed .new-list-button .icon { width: 20px; height: 20px; }
  .sidebar-collapsed .sidebar-bottom { padding-top: 24px; }
  .sidebar-collapsed .sidebar-backup { display: flex; margin: 0 auto 12px; width: 44px; height: 44px; }
  .sidebar-collapsed .profile-button { justify-content: center; padding: 8px 0; }
  .sidebar-collapsed.shopping-mode .workspace { margin-left: 0; }
}
.topbar { height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 34px; border-bottom: 1px solid var(--line); background: #ffffffa6; }
.breadcrumb { display: flex; align-items: center; gap: 13px; font-size: 13px; color: #725585; }
.breadcrumb > span { color: #725585; }
.breadcrumb strong { font-weight: 500; color: #583969; }
.topbar-end { display: flex; align-items: center; gap: 18px; }
.save-status { display: inline-flex; align-items: center; gap: 6px; color: #725585; font-size: 11px; }
.save-status i { width: 5px; height: 5px; border-radius: 50%; background: #9cbaa0; }
.save-status.error { color: #b46b55; }
.save-status.error i { background: #c18061; }
.help-button { width: 28px; color: #725585; }
.help-button .icon { width: 16px; }
main { max-width: 1320px; margin: 0 auto; padding: 34px 34px 0; outline: none; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 25px; }
.page-heading > div:first-child { min-width: 0; }
.eyebrow { display: flex; align-items: center; gap: 7px; color: #725585; font-size: 11px; font-weight: 600; letter-spacing: 1.5px; }
.eyebrow .icon { width: 12px; height: 12px; }
h1 { display: flex; align-items: center; gap: 5px; margin-top: 7px; font-size: 31px; font-weight: 650; letter-spacing: -1.15px; overflow-wrap: anywhere; }
.title-edit { width: 32px; height: 36px; margin-left: 3px; color: #725585; }
.title-edit .icon { width: 14px; height: 14px; }
.page-heading p { margin-top: 8px; color: #725585; font-size: 13px; }
.heading-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; padding-top: 13px; }
.heading-actions .button { min-height: 40px; padding: 9px 14px; font-size: 12px; }
.heading-actions .button .icon { width: 14px; height: 14px; }
.heading-actions > .icon-button { width: 37px; height: 40px; }
.mobile-list-switch { display: none; }
.demo-banner { display: flex; align-items: center; gap: 8px; margin: -4px 0 20px; padding: 10px 13px; border: 1px solid #e8e1f6; border-radius: 9px; background: #f5f1fc; color: #725585; font-size: 12px; }
.demo-banner > .icon { width: 14px; height: 14px; color: #725585; }
.demo-banner strong { font-weight: 600; }
.demo-banner button { display: flex; align-items: center; justify-content: flex-end; gap: 7px; min-height: 25px; margin-left: auto; flex-shrink: 0; color: #725585; font-size: 11px; font-weight: 600; }
.demo-banner button .icon { width: 12px; height: 12px; }
.summary-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-bottom: 28px; }
.stat-card { display: flex; align-items: center; gap: 17px; min-height: 113px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.stat-card > div { min-width: 0; }
.stat-icon { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 42px; height: 44px; border-radius: 12px; }
.stat-icon .icon { width: 21px; height: 21px; }
.lavender { background: #f3effb; color: #725585; }
.mint { background: #eef5ef; color: #8fab95; }
.stat-card > div > span { display: block; margin-bottom: 3px; color: #583969; font-size: 12px; }
.stat-card strong { display: block; color: #43374f; font-size: 23px; line-height: 1.25; font-weight: 650; letter-spacing: -.65px; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.stat-card > div > small { display: block; margin-top: 7px; color: #725585; font-size: 11px; }
.stat-card strong small { margin-left: 1px; font-size: 16px; font-weight: 500; }
.mini-ring { position: relative; display: grid; place-items: center; flex-shrink: 0; width: 48px; height: 48px; border-radius: 50%; background: conic-gradient(#a48acd var(--progress, 0%), #f0ebf6 0); }
.mini-ring::before { content: ""; position: absolute; inset: 4px; border-radius: inherit; background: white; }
.mini-ring > span { z-index: 1; font-size: 13px; font-weight: 650; color: #725585; }
.mini-ring small { font-size: 11px; font-weight: 400; color: #725585; }
.content-grid { display: grid; grid-template-columns: minmax(0, 1fr) 286px; gap: 24px; align-items: start; }
.list-content, .right-rail, #items-area { min-width: 0; }
.right-rail { display: grid; gap: 20px; }

/* A fast add field, natural filters, and readable supermarket sections. */
.add-panel { padding: 21px 22px 17px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 15px; }
.section-heading h2 { color: #583969; font-size: 13px; font-weight: 600; letter-spacing: -.1px; }
.section-heading > span { color: #725585; font-size: 11px; }
.quick-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 8px; }
.quick-name { display: flex; align-items: center; min-width: 0; height: 43px; padding-left: 12px; border: 1px solid #e9e3f0; border-radius: 8px; background: #fcfbfe; }
.quick-name > .icon { width: 16px; height: 16px; color: #725585; }
.quick-name input { width: 100%; min-height: 40px; padding: 8px 10px; border: 0; outline: none; background: transparent; font-size: 13px; }
.quick-name:focus-within { border-color: #ab93d8; box-shadow: 0 0 0 3px #f1ebfb; }
.quick-form > .button { min-height: 43px; padding: 9px 14px; font-size: 12px; }
.quick-form > .button .icon { width: 13px; height: 13px; }
.quick-detail { grid-column: 1 / -1; display: inline-flex; align-items: center; gap: 7px; justify-self: start; min-height: 34px; margin: 9px 0 8px; padding: 6px 11px; border: 1px solid #e5ddee; border-radius: 7px; background: #faf7fd; color: #725585; font-size: 11px; font-weight: 500; }
.quick-detail:hover { background: #f0eafa; border-color: #cdbde2; color: #583969; }
.quick-detail:active { background: #e9e0f5; }
.quick-detail .icon { width: 13px; height: 13px; }
.suggestions { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 3px; }
.suggestions > span { margin-right: 2px; color: #725585; font-size: 11px; }
.suggestions button { display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-height: 28px; padding: 3px 9px; border: 1px solid #efebf4; border-radius: 6px; color: #725585; font-size: 11px; }
.suggestions button .icon { width: 10px; height: 10px; }
.suggestions button:hover { color: var(--purple); background: #f5f0fd; }
.list-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-top: 25px; }
.status-tabs { display: flex; align-items: center; gap: 17px; }
.status-tabs button { display: flex; align-items: center; gap: 5px; min-height: 40px; border-bottom: 2px solid transparent; color: #725585; font-size: 12px; white-space: nowrap; }
.status-tabs button.active { border-color: #a58acb; color: #725585; font-weight: 600; }
.status-tabs span { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 17px; padding: 0 4px; border-radius: 5px; background: #efebf5; color: #725585; font-size: 11px; }
.shopping-toggle { display: flex; align-items: center; justify-content: center; gap: 6px; min-height: 36px; padding: 5px 9px; border: 1px solid #e6e0ee; border-radius: 7px; color: #725585; background: #fff; font-size: 11px; white-space: nowrap; }
.shopping-toggle .icon { width: 13px; height: 13px; }
.shopping-toggle.active { background: #efe8fb; border-color: #ccb9e5; color: var(--purple); }
.list-search-row { display: flex; align-items: center; gap: 12px; margin-top: 16px; }
.search-input { display: flex; align-items: center; gap: 7px; flex: 1; min-width: 0; height: 38px; border: 1px solid #e9e3ed; border-radius: 7px; background: #fff; padding: 0 11px; }
.search-input > .icon { width: 14px; height: 14px; color: #725585; }
.search-input input { width: 100%; border: 0; outline: 0; background: transparent; font-size: 12px; }
.search-input:focus-within { border-color: #ac91cc; box-shadow: 0 0 0 3px #eee7f6; }
.sort-control { display: flex; align-items: center; gap: 5px; flex-shrink: 0; color: #725585; }
.sort-control .icon { width: 15px; height: 15px; }
.sort-control select { min-height: 38px; max-width: 115px; padding: 0 3px; border: 0; background: transparent; color: #725585; font-size: 11px; cursor: pointer; }
.category-chips { display: flex; align-items: center; gap: 6px; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-width: thin; scrollbar-color: #ddd4e8 transparent; margin: 13px 0 20px; padding-bottom: 4px; }
.category-chips button { flex-shrink: 0; min-height: 29px; padding: 5px 10px; border: 1px solid #e8e2ee; border-radius: 7px; color: #725585; background: #fff; font-size: 11px; white-space: nowrap; }
.category-chips button.active { border-color: #d7c8ed; background: #f0eafa; color: #725585; }
.category-chips button:hover { border-color: #b99bcf; color: var(--purple); }
.product-group { overflow: hidden; margin-bottom: 17px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.group-heading { display: flex; align-items: center; gap: 9px; min-height: 58px; padding: 12px 18px; border-bottom: 1px solid #f1edf5; }
.category-icon { display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; width: 28px; height: 29px; border-radius: 8px; background: #f0f5ed; font-size: 15px; }
.category-icon.padaria, .category-icon.mercearia { background: #faf4e8; }
.category-icon.laticinios, .category-icon.limpeza { background: #edf5f8; }
.category-icon.carnes, .category-icon.higiene { background: #faf0f1; }
.category-icon.bebidas { background: #f1edf8; }
.group-heading h3 { font-size: 13px; color: #583969; font-weight: 600; }
.group-count { display: grid; place-items: center; min-width: 17px; height: 17px; padding: 0 4px; border-radius: 50%; font-size: 11px; color: #725585; background: #f5f0f9; }
.group-heading > small { margin-left: auto; color: #725585; font-size: 11px; font-variant-numeric: tabular-nums; }
.table-head, .product-row { display: grid; grid-template-columns: minmax(0, 1fr) 108px 95px 90px 28px; column-gap: 8px; padding-left: 15px; padding-right: 15px; }
.table-head { align-items: center; min-height: 34px; border-bottom: 1px solid #f6f2f8; background: #fdfcfe; color: #725585; font-size: 10px; font-weight: 500; letter-spacing: .6px; }
.table-head > span:first-child { padding-left: 10px; }
.table-head > span:nth-child(2) { text-align: center; }
.table-head > span:nth-child(3), .table-head > span:nth-child(4) { text-align: right; }
.product-row { align-items: center; min-height: 77px; border-bottom: 1px solid #f3eff6; }
.product-row:last-child { border-bottom: 0; }
.product-row:hover { background: #fdfbff; }
.product-main { display: flex; align-items: center; min-width: 0; gap: 3px; margin-left: -6px; }
.check-item { position: relative; display: flex; align-items: center; justify-content: center; flex-shrink: 0; width: 40px; height: 44px; border-radius: 7px; color: #fff; }
.check-item::before { content: ""; position: absolute; width: 19px; height: 19px; border: 1.5px solid #d9cee3; border-radius: 50%; background: white; }
.check-item:hover::before { border-color: #a78ac6; background: #f5effc; }
.check-item .icon { position: relative; z-index: 1; width: 12px; height: 12px; stroke-width: 2.3; }
.checked .check-item::before { border-color: #b29bc9; background: #b29bc9; }
.product-name { display: flex; flex-direction: column; justify-content: center; min-width: 0; min-height: 44px; padding: 5px 2px; text-align: left; }
.product-name strong { color: #583969; font-size: 13px; font-weight: 500; overflow-wrap: anywhere; }
.product-name > span { display: block; margin-top: 4px; color: #725585; font-size: 11px; overflow-wrap: anywhere; }
.checked .product-name strong { color: #725585; text-decoration: line-through; text-decoration-color: #c8bdd0; }
.checked .product-name > span { color: #725585; }
.quantity-control { display: flex; align-items: center; justify-content: space-between; width: 108px; min-height: 32px; border: 1px solid #ede5f4; border-radius: 7px; background: #fdfbff; }
.quantity-control button { display: grid; place-items: center; flex: 0 0 30px; min-height: 36px; color: #725585; border-radius: 6px; }
.quantity-control button:hover { background: #f0e7fa; color: var(--purple); }
.quantity-control button .icon { width: 10px; height: 10px; }
.quantity-control > span { min-width: 0; text-align: center; color: #725585; font-size: 12px; overflow-wrap: anywhere; }
.quantity-control small { font-size: 11px; color: #725585; }
.unit-price { display: flex; flex-direction: column; align-items: flex-end; justify-content: center; min-height: 44px; color: #725585; font-size: 12px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; text-align: right; }
.unit-price small { margin-top: 3px; color: #725585; font-size: 11px; }
.unit-price:hover { color: var(--purple); }
.unit-price.no-price { color: #725585; font-size: 11px; }
.subtotal { text-align: right; color: #583969; font-size: 13px; font-weight: 550; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.checked .unit-price, .checked .subtotal { color: #725585; }
.row-menu { width: 40px; margin-left: -6px; color: #725585; }
.row-menu .icon { width: 15px; height: 15px; }
.list-bottom-note { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; margin-top: 9px; color: #725585; font-size: 11px; }
.list-bottom-note > .icon { width: 11px; height: 11px; color: #725585; }
.list-bottom-note button { display: inline-flex; align-items: center; gap: 4px; min-height: 36px; margin-left: auto; color: #725585; font-size: 11px; }
.list-bottom-note button .icon { width: 11px; height: 11px; }

/* A gentle budget nudge and an intentionally useful tip. */
.budget-card { padding: 23px 22px 17px; border: 1px solid #e7dff0; border-radius: var(--radius); background: #f4effa; }
.rail-title { display: flex; align-items: center; gap: 9px; margin-bottom: 22px; }
.rail-title-icon { display: flex; color: #725585; }
.rail-title-icon .icon { width: 17px; height: 17px; }
.rail-title h2 { color: #725585; font-size: 12px; font-weight: 600; }
.budget-label { display: flex; align-items: center; justify-content: space-between; color: #725585; font-size: 12px; }
.budget-label button { display: grid; place-items: center; width: 30px; height: 28px; margin: -4px -4px -4px 0; border-radius: 5px; color: #725585; }
.budget-label button:hover { background: #e9dff3; }
.budget-label .icon { width: 12px; height: 12px; }
.budget-value { margin: 4px 0 17px; color: #725585; font-size: 29px; font-weight: 650; letter-spacing: -1px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.budget-value button { display: inline-flex; align-items: center; gap: 8px; min-height: 40px; font-size: 19px; font-weight: 600; letter-spacing: -.5px; }
.budget-value .icon { width: 15px; height: 15px; }
.budget-track { height: 6px; overflow: hidden; border-radius: 8px; background: #e9def2; }
.budget-track span { display: block; max-width: 100%; height: 100%; border-radius: inherit; background: #b69bcd; transition: width .35s ease; }
.budget-track.over span { background: #c98787; }
.budget-caption { margin-top: 9px; color: #725585; font-size: 11px; }
.budget-caption.over { color: #725585; }
.budget-divider { height: 1px; margin: 22px 0 16px; background: #e7dcef; }
.budget-lines { margin: 0; }
.budget-lines > div { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 13px; }
.budget-lines dt { color: #725585; font-size: 11px; }
.budget-lines dt small { font-size: 10px; color: #725585; }
.budget-lines dd { margin: 0; color: #725585; font-size: 12px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.budget-lines .budget-total { border-top: 1px dashed #ded0e9; padding-top: 13px; margin-top: 4px; }
.budget-total dt, .budget-total dd { color: #725585; font-weight: 600; }
.budget-total dd { font-size: 13px; }
.unpriced-note { display: flex; align-items: flex-start; gap: 5px; margin: 4px 0 15px; color: #725585; font-size: 11px; line-height: 1.6; }
.unpriced-note .icon { width: 12px; height: 12px; margin-top: 1px; }
.finish-button { width: 100%; margin-top: 6px; min-height: 40px; font-size: 12px; }
.finish-button .icon { width: 14px; height: 14px; }
.finish-note { margin-top: 9px; text-align: center; color: #725585; font-size: 10px; }
.tip-card { position: relative; overflow: hidden; min-height: 251px; padding: 23px 22px 16px; border: 1px solid #e4eadf; border-radius: var(--radius); background: #f0f4eb; }
.tip-symbol { display: flex; align-items: center; justify-content: center; width: 29px; height: 31px; margin-bottom: 13px; border-radius: 8px; color: #9aa98a; background: #e8eedf; }
.tip-symbol .icon { width: 17px; height: 17px; }
.tiny-label { display: block; color: #9ca78d; font-size: 10px; font-weight: 600; letter-spacing: 1.1px; text-transform: uppercase; }
.tip-card h3 { position: relative; z-index: 1; margin: 7px 0 10px; color: #89967c; font-size: 17px; line-height: 1.4; font-weight: 550; letter-spacing: -.35px; }
.tip-card p { position: relative; z-index: 1; max-width: 205px; color: #a8b29c; font-size: 11px; line-height: 1.8; }
.tip-card button { position: relative; z-index: 1; display: flex; align-items: center; gap: 7px; min-height: 36px; margin-top: 6px; color: #95a185; font-size: 11px; font-weight: 600; }
.tip-card button .icon { width: 12px; height: 12px; }
.tip-decoration { position: absolute; right: -12px; bottom: -10px; width: 94px; height: 101px; transform: rotate(-19deg); opacity: .8; }
.tip-decoration span { position: absolute; right: 8px; bottom: 3px; width: 31px; height: 65px; background: #e3ead8; border-radius: 100% 0 100% 0; transform: rotate(22deg); }
.tip-decoration span:nth-child(2) { right: 28px; bottom: 22px; width: 29px; height: 57px; background: #dce7d0; transform: rotate(-18deg); }
.tip-decoration span:nth-child(3) { right: 5px; bottom: 37px; width: 25px; height: 54px; background: #e8eddf; transform: rotate(52deg); }
.offline-note { display: flex; align-items: center; gap: 9px; justify-content: center; padding: 0 10px; text-align: left; color: #725585; font-size: 11px; line-height: 1.8; }
.offline-note > .icon { width: 16px; height: 16px; color: #725585; }
.offline-note strong { font-weight: 400; color: #725585; }
.page-footer { display: flex; align-items: center; justify-content: space-between; gap: 15px; max-width: 1320px; margin: 42px auto 0; padding: 0 34px 25px; color: #725585; font-size: 11px; }
.page-footer > span:last-child { display: flex; align-items: center; gap: 5px; }
.page-footer .icon { width: 11px; height: 11px; color: #aeb7a1; }
.mobile-nav { display: none; }

/* Empty, saved, and completed lists share the same visual language. */
.empty-state { display: flex; align-items: center; flex-direction: column; padding: 44px 24px; border: 1px dashed #e1d7eb; border-radius: var(--radius); background: #fdfcfe; text-align: center; }
.empty-state.large { min-height: 370px; justify-content: center; margin-top: 24px; }
.empty-art { display: grid; place-items: center; width: 68px; height: 68px; margin-bottom: 20px; border-radius: 22px; color: #725585; background: #f0e8f8; transform: rotate(-5deg); }
.empty-art .icon { width: 31px; height: 31px; transform: rotate(5deg); stroke-width: 1.3; }
.empty-state h3 { font-size: 17px; font-weight: 550; letter-spacing: -.3px; color: #583969; }
.empty-state p { margin: 10px 0 22px; color: #725585; font-size: 13px; line-height: 1.8; }
.collection-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 18px; color: #725585; font-size: 13px; }
.collection-header > span { min-width: 0; overflow-wrap: anywhere; }
.collection-header strong { font-weight: 550; color: #583969; }
.favorite-grid, .history-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.favorite-card, .history-card { position: relative; padding: 23px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.favorite-emoji { display: grid; place-items: center; width: 51px; height: 51px; margin-bottom: 18px; border-radius: 16px; background: #f5f2f8; font-size: 25px; }
.favorite-remove { position: absolute; right: 14px; top: 14px; color: #725585; }
.favorite-remove .icon { fill: #eadcf3; }
.favorite-card .tiny-label { color: #725585; }
.favorite-card h3, .history-card h3 { margin-top: 7px; color: #583969; font-size: 17px; font-weight: 550; overflow-wrap: anywhere; }
.favorite-card p, .history-card p { margin-top: 7px; color: #725585; font-size: 12px; }
.favorite-card > .button { width: 100%; margin-top: 20px; font-size: 12px; }
.history-summary { display: flex; flex-direction: column; padding: 23px 26px; margin-bottom: 22px; border: 1px solid #e6ddef; border-radius: var(--radius); background: #f3edf9; color: #725585; }
.history-summary > span { font-size: 12px; }
.history-summary > strong { margin: 3px 0; font-size: 28px; font-weight: 600; letter-spacing: -.9px; overflow-wrap: anywhere; }
.history-summary > small { color: #725585; font-size: 11px; }
.history-card-top { display: flex; align-items: center; gap: 9px; margin-bottom: 18px; }
.history-card-top > span:nth-child(2) { color: #725585; font-size: 11px; }
.history-card-top .stat-icon { width: 35px; height: 37px; border-radius: 10px; }
.history-card-top .icon-button { margin-left: auto; width: 27px; }
.history-card > strong { display: block; margin-top: 17px; color: #725585; font-size: 23px; font-weight: 600; letter-spacing: -.5px; }
.history-card-actions { display: flex; gap: 8px; margin-top: 20px; }
.history-card-actions .button { flex: 1; padding: 9px 10px; font-size: 12px; }

/* Native dialogs retain browser focus trapping and keyboard dismissal. */
dialog { width: min(520px, calc(100% - 32px)); max-height: calc(100dvh - 48px); margin: auto; padding: 27px; border: 1px solid #ebe4f2; border-radius: 18px; color: var(--ink); background: #fff; box-shadow: 0 22px 90px #30203f20; overscroll-behavior: contain; }
dialog::backdrop { background: #30243e55; backdrop-filter: blur(4px); }
dialog[open] { animation: dialog-in .18s ease-out; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -2px -7px 21px 0; }
.modal-head h2 { min-width: 0; font-size: 21px; font-weight: 600; letter-spacing: -.65px; color: #65516f; overflow-wrap: anywhere; }
.modal-head .icon-button { color: #725585; }
.modal-description { margin-bottom: 20px; color: #725585; font-size: 12px; line-height: 1.85; overflow-wrap: anywhere; }
.modal-description strong { color: #583969; font-weight: 600; }
.modal-form { display: flex; flex-direction: column; gap: 16px; }
.modal-form label { display: flex; flex-direction: column; gap: 7px; color: #583969; font-size: 13px; font-weight: 550; }
.modal-form input:not([type="checkbox"]), .modal-form select, .share-link-row input { display: block; width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid #e6dcec; border-radius: 8px; background: #fefcfe; color: #583969; font-size: 12px; font-weight: 400; }
.modal-form input::placeholder { color: #725585; }
.modal-form select { cursor: pointer; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.money-input { display: flex; align-items: center; min-width: 0; border: 1px solid #e6dcec; border-radius: 8px; background: #fefcfe; }
.money-input > span { padding-left: 12px; color: #725585; font-size: 13px; font-weight: 400; }
.modal-form .money-input input { border: 0; background: transparent; }
.money-input:focus-within { outline: 3px solid #e7d9f2; outline-offset: 1px; }
.money-input input:focus-visible { outline: none; }
.field-hint { margin: -3px 0 0; color: #725585; font-size: 12px; line-height: 1.7; }
.optional { display: inline; margin: -23px 0 0 auto; color: #725585; font-size: 11px; font-weight: 400; }
.modal-form .checkbox-label { display: flex; flex-direction: row; align-items: center; gap: 9px; min-height: 40px; padding: 7px 11px; border: 1px solid #eee4f5; border-radius: 8px; background: #faf6fd; color: #725585; }
.checkbox-label input { width: 17px; height: 17px; accent-color: var(--purple); }
.form-error { margin-top: -4px; color: #725585; font-size: 13px; line-height: 1.6; }
.form-error:empty { display: none; }
.modal-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 8px; padding-top: 17px; border-top: 1px solid #f0e8f6; }
.modal-actions .button { font-size: 13px; }
.action-menu { display: grid; gap: 6px; }
.action-menu > button { display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 10px 11px; border-radius: 9px; text-align: left; color: #725585; font-size: 12px; }
.action-menu > button:hover { background: #f8f1fd; }
.action-menu > button > .icon { width: 18px; height: 18px; color: #725585; }
.action-menu > button > .icon:last-child:not(:first-child) { margin-left: auto; width: 14px; }
.action-menu button span { min-width: 0; overflow-wrap: anywhere; }
.action-menu strong { display: block; font-size: 12px; font-weight: 550; }
.action-menu small { display: block; margin-top: 4px; color: #725585; font-size: 11px; line-height: 1.6; }
.action-menu + .field-hint { margin-top: 19px; }
.share-illustration { display: grid; place-items: center; width: 65px; height: 65px; margin: 0 auto 18px; border-radius: 20px; color: #725585; background: #f2e9f9; }
.share-illustration > .icon { width: 29px; height: 29px; }
.shared-name { margin-bottom: 8px; text-align: center; color: #583969; font-size: 22px; letter-spacing: -.5px; overflow-wrap: anywhere; }
.shared-name + .modal-description { text-align: center; }
.share-label { display: block; margin-bottom: 8px; font-size: 12px; color: #725585; }
.share-link-row { display: flex; gap: 8px; }
.share-link-row input { flex: 1; color: #725585; font-size: 12px; }
.share-link-row .button { padding: 10px 14px; font-size: 13px; }
.share-explanation { display: flex; gap: 9px; margin: 17px 0 12px; padding: 13px; border-radius: 9px; background: #f7f1fb; color: #725585; }
.share-explanation .icon { width: 16px; height: 16px; margin-top: 2px; }
.share-explanation p { font-size: 12px; line-height: 1.8; }
.share-explanation strong { font-weight: 600; }
.compare-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 13px; }
.compare-columns fieldset { display: flex; flex-direction: column; gap: 14px; min-width: 0; margin: 0; padding: 16px 13px; border: 1px solid #e9dff0; border-radius: 11px; background: #fdfbfe; }
.compare-columns legend { padding: 0 5px; color: #725585; font-size: 12px; font-weight: 600; }
.compare-columns label { font-size: 12px; }
.compare-result { padding: 17px; border: 1px solid #dde9d9; border-radius: 10px; background: #f0f6ec; color: #88a17c; text-align: center; }
.compare-result > .icon { display: block; margin: 0 auto 8px; width: 24px; height: 24px; }
.compare-result strong { display: block; font-size: 13px; font-weight: 600; }
.compare-result p { margin-top: 8px; color: #98ad8d; font-size: 13px; }
.compare-result span { display: block; margin-top: 5px; font-size: 12px; }
.finish-summary { display: flex; flex-direction: column; align-items: center; padding: 23px; margin-bottom: 20px; border: 1px solid #e9def2; border-radius: 12px; background: #f8f2fc; color: #725585; }
.finish-summary > .icon { width: 29px; height: 29px; margin-bottom: 9px; }
.finish-summary strong { font-size: 33px; font-weight: 600; letter-spacing: -1px; }
.finish-summary > span { margin-top: 4px; color: #725585; font-size: 12px; }
.history-items { max-height: 350px; overflow-y: auto; margin-bottom: 21px; padding-right: 5px; }
.history-items > div { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 12px 0; border-bottom: 1px solid #f0e9f5; color: #725585; font-size: 13px; }
.history-items > div > span { min-width: 0; overflow-wrap: anywhere; }
.history-items small { display: block; margin-top: 3px; color: #725585; font-size: 11px; }
.history-items strong { color: #725585; font-size: 12px; text-align: right; font-weight: 550; }
.about-brand { display: flex; align-items: center; gap: 9px; margin-bottom: 17px; color: #725585; font-size: 31px; font-weight: 650; letter-spacing: -1.4px; }
.about-features { display: grid; gap: 18px; margin: 24px 0; }
.about-features p { display: flex; align-items: flex-start; gap: 12px; color: #725585; font-size: 13px; line-height: 1.8; }
.about-features .icon { width: 19px; height: 19px; margin-top: 2px; color: #725585; }
.about-features strong { display: block; color: #725585; font-weight: 600; }

/* Feedback stays close without moving the list. */
.toasts { position: fixed; z-index: 100; left: calc(50% + 111px); bottom: 24px; width: max-content; max-width: min(620px, calc(100vw - 32px)); transform: translateX(-50%); pointer-events: none; }
.toast { display: flex; align-items: center; gap: 10px; padding: 11px 12px 11px 16px; border: 1px solid #e3d5ec; border-radius: 12px; color: #f7f2fc; background: #685379; box-shadow: 0 6px 26px #44305222; pointer-events: auto; animation: toast-in .2s ease-out; }
.toast > .icon { width: 16px; height: 16px; color: #725585; }
.toast > span { font-size: 13px; line-height: 1.6; }
.toast button { min-height: 36px; flex-shrink: 0; color: #725585; font-size: 13px; font-weight: 600; }
.toast button:not(.toast-close) { padding: 0 6px; text-decoration: underline; text-underline-offset: 3px; }
.toast .toast-close { width: 30px; }
.toast-close .icon { width: 14px; height: 14px; }
.shopping-dock { position: fixed; bottom: 22px; left: 50%; z-index: 25; display: flex; align-items: center; justify-content: space-between; gap: 26px; width: min(600px, calc(100% - 48px)); padding: 15px 20px; border: 1px solid #ddd0e7; border-radius: 16px; background: #fffffff2; box-shadow: 0 8px 35px #51346312; transform: translateX(-50%); backdrop-filter: blur(15px); }
.shopping-dock > span:first-child { display: flex; flex-direction: column; }
.shopping-dock small { color: #725585; font-size: 11px; }
.shopping-dock strong { color: #725585; font-size: 22px; line-height: 1.4; letter-spacing: -.5px; }
.shopping-dock > span:nth-child(2) { color: #725585; font-size: 13px; }
.shopping-mode .sidebar, .shopping-mode .page-footer, .shopping-mode .add-panel, .shopping-mode .demo-banner, .shopping-mode .tip-card, .shopping-mode .offline-note, .shopping-mode .mobile-list-switch { display: none; }
.shopping-mode .workspace { margin-left: 0; padding-bottom: 100px; }
.shopping-mode main { max-width: 1120px; }
.shopping-mode .product-row { min-height: 86px; }
.shopping-mode .check-item { width: 48px; height: 52px; }
.shopping-mode .check-item::before { width: 25px; height: 25px; }
.shopping-mode .check-item .icon { width: 15px; height: 15px; }
.shopping-mode .product-name strong { font-size: 14px; }
.shopping-mode .list-toolbar { margin-top: 0; }
.shopping-mode .summary-cards { margin-bottom: 22px; }

@keyframes dialog-in { from { opacity: 0; transform: translateY(8px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Preserve content width before the desktop navigation becomes mobile. */
@media (min-width: 1600px) {
  main { padding-top: 40px; }
  .page-heading { margin-bottom: 30px; }
  .stat-card { min-height: 124px; }
  .product-row { min-height: 82px; }
}
@media (max-width: 1180px) {
  .content-grid { grid-template-columns: minmax(0, 1fr); }
  .right-rail { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; margin-top: 7px; }
  .offline-note { grid-column: 1 / -1; margin-top: -5px; }
  .stat-card { gap: 12px; padding: 18px 15px; }
  .stat-icon { width: 35px; height: 38px; }
  .mini-ring { width: 41px; height: 41px; }
  .stat-card strong { font-size: 21px; }
  .favorite-grid, .history-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shopping-mode .content-grid { grid-template-columns: minmax(0, 1fr) 264px; }
  .shopping-mode .right-rail { display: block; margin-top: 0; }
  .shopping-mode .table-head, .shopping-mode .product-row { grid-template-columns: minmax(0, 1fr) 108px 80px 75px 28px; }
}
@media (max-width: 960px) {
  .topbar { padding: 0 25px; }
  main { padding: 27px 25px 0; }
  .page-heading { align-items: flex-start; }
  h1 { font-size: 27px; }
  .heading-actions { padding-top: 21px; }
  .heading-actions .button { width: 40px; padding: 0; }
  .heading-actions .button span { display: none; }
  .summary-cards { gap: 10px; }
  .stat-card { gap: 9px; padding: 15px 12px; min-height: 101px; }
  .stat-card > .stat-icon, .stat-card > .mini-ring { display: none; }
  .stat-card strong { font-size: 22px; }
  .table-head, .product-row { grid-template-columns: minmax(0, 1fr) 108px 83px 75px 28px; gap: 6px; padding-left: 12px; padding-right: 12px; }
  .demo-banner { align-items: flex-start; flex-wrap: wrap; }
  .demo-banner > span { flex: 1; min-width: 200px; }
  .demo-banner button { margin-left: 22px; }
  .section-heading > span { display: none; }
  .page-footer { padding-inline: 25px; }
  .page-footer > span:last-child { display: none; }
  .shopping-mode .content-grid { grid-template-columns: minmax(0, 1fr); }
  .shopping-mode .right-rail { display: none; }
}

@media (max-width: 760px) {
  :root { font-size: 15px; }
  .sidebar { display: none; }
  .workspace { margin-left: 0; padding-bottom: 78px; }
  .topbar { height: 58px; gap: 9px; padding: 0 18px; }
  .breadcrumb { gap: 9px; font-size: 12px; }
  .topbar-end { gap: 5px; }
  .save-status { max-width: 151px; font-size: 11px; }
  .help-button { display: none; }
  main { padding: 25px 18px 0; }
  .page-heading { gap: 10px; margin-bottom: 20px; }
  .eyebrow { font-size: 11px; letter-spacing: 1.3px; }
  h1 { margin-top: 7px; font-size: 28px; letter-spacing: -.9px; }
  .page-heading p { font-size: 12px; line-height: 1.7; }
  .heading-actions { gap: 5px; padding-top: 16px; }
  .heading-actions .button, .heading-actions > .icon-button { width: 40px; height: 40px; }
  .title-edit { width: 27px; }
  .mobile-list-switch { display: flex; align-items: center; justify-content: space-between; gap: 13px; padding: 9px 12px; margin-bottom: 16px; border: 1px solid var(--line); border-radius: 9px; background: #fff; }
  .mobile-list-switch label { font-size: 12px; color: #725585; }
  .mobile-list-switch select { flex: 1; min-height: 30px; max-width: 75%; padding: 0 3px; border: 0; background: transparent; color: #725585; font-size: 13px; font-weight: 500; }
  .demo-banner { padding: 10px 11px; margin-bottom: 16px; font-size: 11px; }
  .demo-banner > span { min-width: 180px; line-height: 1.7; }
  .demo-banner button { min-height: 30px; }
  .summary-cards { gap: 9px; margin-bottom: 20px; }
  .stat-card { min-height: 108px; padding: 15px 13px; border-radius: 11px; }
  .stat-card > div > span { font-size: 11px; }
  .stat-card strong { font-size: 22px; letter-spacing: -.6px; }
  .stat-card > div > small { font-size: 11px; line-height: 1.5; }
  .stat-card strong small { font-size: 15px; }
  .content-grid { gap: 22px; }
  .add-panel { padding: 18px; border-radius: 12px; }
  .section-heading { margin-bottom: 13px; }
  .section-heading h2 { font-size: 13px; }
  .quick-name input { font-size: 12px; }
  .quick-form > .button { font-size: 13px; }
  .quick-detail { min-height: 36px; font-size: 12px; }
  .suggestions { gap: 7px; }
  .suggestions > span { font-size: 11px; }
  .suggestions button { min-height: 35px; padding-inline: 10px; font-size: 12px; }
  .list-toolbar { margin-top: 19px; gap: 9px; }
  .status-tabs { gap: 17px; }
  .status-tabs button { min-height: 42px; font-size: 13px; }
  .status-tabs span { font-size: 11px; }
  .shopping-toggle { min-height: 40px; padding-inline: 10px; font-size: 12px; }
  .list-search-row { margin-top: 13px; }
  .search-input { height: 42px; }
  .search-input input { font-size: 13px; }
  .sort-control select { min-height: 40px; font-size: 12px; }
  .category-chips { gap: 7px; margin: 12px 0 16px; padding-bottom: 5px; }
  .category-chips button { min-height: 38px; padding-inline: 12px; font-size: 12px; }
  .product-group { margin-bottom: 15px; }
  .group-heading { min-height: 56px; padding: 12px 16px; }
  .group-heading h3 { font-size: 12px; }
  .group-heading > small { font-size: 12px; }
  .table-head { font-size: 10px; }
  .product-row { min-height: 84px; }
  .product-name strong { font-size: 12px; }
  .product-name > span { font-size: 11px; }
  .unit-price { font-size: 13px; }
  .subtotal { font-size: 12px; }
  .list-bottom-note { font-size: 11px; }
  .list-bottom-note button { min-height: 40px; font-size: 11px; }
  .budget-card { padding: 22px; }
  .rail-title h2 { font-size: 13px; }
  .budget-lines dt, .budget-lines dd { font-size: 13px; }
  .budget-label { font-size: 13px; }
  .budget-label button { width: 40px; height: 40px; margin: -8px -8px -8px 0; }
  .budget-caption { font-size: 11px; }
  .finish-note { font-size: 11px; }
  .finish-button { min-height: 44px; font-size: 12px; }
  .tip-card p { font-size: 12px; }
  .tip-card button { min-height: 40px; font-size: 12px; }
  .offline-note { font-size: 11px; }
  .page-footer { margin-top: 26px; padding: 0 18px 24px; justify-content: center; font-size: 11px; text-align: center; }
  .mobile-nav { position: fixed; inset: auto 0 0; z-index: 30; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 7px 10px calc(7px + env(safe-area-inset-bottom)); border-top: 1px solid #eae2f0; background: #ffffffed; backdrop-filter: blur(18px); }
  .mobile-nav button { display: flex; align-items: center; justify-content: center; flex-direction: column; gap: 5px; min-height: 50px; border-radius: 9px; color: #725585; font-size: 11px; }
  .mobile-nav .icon { width: 20px; height: 20px; }
  .mobile-nav button.active { color: #725585; background: #f5edfb; font-weight: 600; }
  .toasts { left: 50%; bottom: calc(80px + env(safe-area-inset-bottom)); }
  .toast { gap: 8px; padding: 10px 8px 10px 12px; }
  .toast > span { font-size: 12px; }
  .toast > .icon { display: none; }
  dialog { max-height: calc(100dvh - 32px); padding: 24px 21px; }
  .modal-head h2 { font-size: 22px; }
  .modal-form input:not([type="checkbox"]), .modal-form select, .share-link-row input { min-height: 46px; font-size: 16px; }
  .modal-form label { font-size: 12px; }
  .modal-description { font-size: 12px; }
  .modal-actions .button { min-height: 44px; white-space: normal; }
  .field-hint { font-size: 13px; }
  .optional { font-size: 12px; }
  .action-menu > button { min-height: 59px; }
  .action-menu small { font-size: 12px; }
  .compare-columns label { font-size: 12px; }
  .share-link-row input { font-size: 12px; }
  .share-explanation p { font-size: 13px; }
  .empty-state { padding: 39px 20px; }
  .empty-state.large { min-height: 340px; }
  .empty-state h3 { font-size: 19px; }
  .empty-state p { font-size: 12px; }
  .collection-header { font-size: 12px; }
  .favorite-card, .history-card { padding: 20px; }
  .shopping-mode .topbar { height: 49px; }
  .shopping-mode main { padding-top: 20px; }
  .shopping-mode .workspace { padding-bottom: 92px; }
  .shopping-mode .mobile-nav { display: none; }
  .shopping-mode .summary-cards { margin-bottom: 15px; }
  .shopping-mode .page-heading { margin-bottom: 16px; }
  .shopping-mode .page-heading p, .shopping-mode .eyebrow { display: none; }
  .shopping-mode .heading-actions { padding-top: 4px; }
  .shopping-dock { bottom: calc(12px + env(safe-area-inset-bottom)); width: calc(100% - 24px); gap: 12px; padding: 13px 15px; border-radius: 13px; }
  .shopping-dock strong { font-size: 22px; }
  .shopping-dock > span:nth-child(2) { font-size: 12px; }
  .shopping-dock .button { min-height: 44px; font-size: 13px; }
  .shopping-mode ~ .toasts { bottom: calc(104px + env(safe-area-inset-bottom)); }
}

@media (max-width: 550px) {
  main { padding-inline: 16px; }
  .topbar { padding-inline: 16px; }
  .page-heading { position: relative; padding-right: 90px; }
  .page-heading > div:first-child { width: 100%; }
  h1 { align-items: flex-start; font-size: 26px; }
  .title-edit { margin-top: -1px; }
  .heading-actions { position: absolute; right: 0; top: 15px; padding: 0; }
  .page-heading > .button { position: absolute; top: 17px; right: 0; padding: 10px; font-size: 12px; }
  .summary-cards { gap: 7px; }
  .stat-card { padding: 12px 10px; min-height: 104px; }
  .stat-card > div > span { font-size: 11px; }
  .stat-card strong { font-size: 19px; letter-spacing: -.55px; }
  .stat-card > div > small { font-size: 10px; }
  .stat-card strong small { font-size: 13px; }
  .add-panel { padding: 17px 15px 14px; }
  .quick-form { gap: 0 7px; }
  .quick-name { padding-left: 9px; }
  .quick-form > .button { padding-inline: 11px; }
  .quick-form > .button .icon { display: none; }
  .suggestions > span { width: 100%; margin-top: 2px; }
  .suggestions { gap: 6px; }
  .suggestions button { min-height: 34px; padding-inline: 10px; }
  .list-toolbar { gap: 7px; }
  .status-tabs { flex: 1; justify-content: space-between; gap: 7px; }
  .status-tabs button { font-size: 12px; }
  .shopping-toggle { width: 40px; height: 40px; padding: 0; margin-left: 5px; }
  .shopping-toggle .icon { width: 17px; height: 17px; }
  .shopping-toggle span { display: none; }
  .shopping-toggle.active { width: auto; padding-inline: 9px; margin: 6px 0 0; }
  .shopping-toggle.active span { display: inline; font-size: 11px; }
  .category-chips { margin-top: 11px; }
  .table-head { display: none; }
  .product-row, .shopping-mode .product-row { position: relative; grid-template-columns: minmax(102px, 1fr) minmax(66px, .8fr) minmax(74px, .8fr); gap: 5px 10px; padding: 12px 14px 15px; }
  .product-main { grid-column: 1 / -1; margin: 0 30px 0 -7px; gap: 3px; }
  .product-name { padding: 5px 0; }
  .product-name strong { font-size: 13px; }
  .product-name > span { font-size: 11px; }
  .row-menu { position: absolute; top: 14px; right: 7px; margin: 0; width: 40px; height: 40px; }
  .quantity-control { grid-column: 1; width: 110px; min-height: 40px; margin-top: 2px; }
  .quantity-control button { flex-basis: 33px; min-height: 40px; }
  .quantity-control > span { font-size: 13px; }
  .quantity-control small { font-size: 11px; }
  .unit-price { grid-column: 2; min-height: 42px; font-size: 13px; }
  .unit-price small { font-size: 11px; }
  .subtotal { grid-column: 3; align-self: center; font-size: 12px; }
  .subtotal::before { content: "Subtotal"; display: block; margin-bottom: 3px; color: #725585; font-size: 11px; font-weight: 400; }
  .group-heading { padding-inline: 15px; }
  .right-rail { grid-template-columns: minmax(0, 1fr); gap: 17px; }
  .budget-card { padding: 23px; }
  .budget-value { font-size: 32px; margin-bottom: 19px; }
  .budget-lines > div { margin-bottom: 14px; }
  .budget-lines .budget-total dd { font-size: 15px; }
  .budget-caption { font-size: 12px; }
  .unpriced-note { font-size: 12px; }
  .tip-card { min-height: 227px; padding: 22px; }
  .tip-card p { max-width: 260px; }
  .tip-card h3 { font-size: 19px; }
  .tiny-label { font-size: 11px; }
  .offline-note { padding: 6px 0; font-size: 12px; }
  .list-bottom-note { gap: 4px; font-size: 11px; }
  .list-bottom-note button { font-size: 11px; }
  .favorite-grid, .history-grid { grid-template-columns: minmax(0, 1fr); gap: 15px; }
  .favorite-card { padding: 23px; }
  .favorite-card .button { width: auto; min-width: 175px; }
  .favorite-emoji { float: right; margin: 4px 33px 0 15px; }
  .favorite-card h3 { font-size: 19px; }
  .favorite-remove { right: 9px; }
  .collection-header { align-items: flex-start; gap: 9px; }
  .collection-header > .text-button { min-height: 31px; flex-shrink: 0; font-size: 12px; }
  .history-card > strong { font-size: 27px; }
  .history-card-actions .button { font-size: 12px; }
  dialog { border-radius: 15px; padding: 22px 19px; }
  .modal-head { margin-bottom: 19px; }
  .modal-head h2 { font-size: 21px; }
  .modal-actions { gap: 8px; }
  .modal-actions .button { flex: 1; padding: 10px 11px; font-size: 12px; }
  .modal-form { gap: 15px; }
  .form-grid { gap: 10px; }
  .form-grid label { font-size: 12px; }
  .modal-form input:not([type="checkbox"]), .modal-form select { padding-inline: 10px; }
  .share-link-row { flex-wrap: wrap; }
  .share-link-row input { flex-basis: 100%; }
  .share-link-row > .button { width: 100%; }
  .compare-columns { gap: 10px; }
  .compare-columns fieldset { padding: 12px 10px; }
  .compare-columns label { font-size: 11px; }
  .compare-result p { font-size: 12px; }
  .toast { flex-wrap: wrap; gap: 4px 9px; }
  .toast > span { flex: 1; min-width: 145px; }
  .toast button { font-size: 12px; }
  .toast .toast-close { width: 23px; }
  .shopping-mode .product-main { margin-left: -10px; }
  .shopping-mode .product-name strong { font-size: 15px; }
  .shopping-mode .page-heading { padding-right: 88px; }
  .shopping-mode .heading-actions { top: 1px; }
  .shopping-mode .stat-card { min-height: 91px; }
  .shopping-dock { gap: 10px; }
  .shopping-dock > span:nth-child(2) { font-size: 11px; }
  .shopping-dock strong { font-size: 21px; }
}

@media (max-width: 360px) {
  .breadcrumb { gap: 5px; font-size: 11px; }
  .save-status { max-width: 127px; font-size: 10px; }
  .topbar { padding-inline: 14px; }
  main { padding-inline: 14px; }
  h1 { font-size: 24px; }
  .page-heading p { font-size: 11px; }
  .summary-cards { gap: 6px; }
  .stat-card { padding: 12px 8px; }
  .stat-card strong { font-size: 16px; }
  .stat-card > div > span { font-size: 10px; }
  .stat-card > div > small { font-size: 10px; }
  .status-tabs { gap: 5px; }
  .status-tabs button { gap: 3px; font-size: 11px; }
  .shopping-toggle { margin-left: 0; }
  .product-row, .shopping-mode .product-row { grid-template-columns: minmax(98px, 1fr) minmax(59px, .7fr) minmax(62px, .7fr); gap: 4px 8px; padding-inline: 11px; }
  .quantity-control { width: 103px; }
  .quantity-control button { flex-basis: 30px; }
  .unit-price { font-size: 12px; }
  .subtotal { font-size: 13px; }
  .quick-name input { font-size: 13px; padding-left: 7px; }
  .quick-form > .button { padding-inline: 10px; font-size: 12px; }
  .suggestions button { padding-inline: 8px; }
  .list-bottom-note button { margin-left: 0; }
  .modal-actions { flex-wrap: wrap; }
  .modal-actions > .button { min-width: 105px; }
  .modal-head h2 { font-size: 20px; }
  .compare-columns { grid-template-columns: minmax(0, 1fr); }
  .shopping-dock > span:nth-child(2) { display: none; }
}

@media (pointer: coarse) {
  .suggestions button, .category-chips button, .quick-detail, .sort-control select,
  .demo-banner button, .new-list-button, .list-bottom-note button { min-height: 40px; }
  .quantity-control { width: 100%; min-width: 108px; }
  .quantity-control button { position: relative; min-height: 40px; }
  .quantity-control button::after { content: ""; position: absolute; inset: 0 -5px; }
  .budget-label button { width: 40px; height: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

@media print {
  @page { margin: 15mm; }
  :root, body { color: #222; background: #fff; font-size: 11pt; }
  .sidebar, .topbar, .heading-actions, .title-edit, .mobile-list-switch, .demo-banner,
  .add-panel, .list-toolbar, .list-search-row, .category-chips, .tip-card, .offline-note,
  .page-footer, .mobile-nav, .list-bottom-note, .row-menu, .finish-button, .finish-note,
  .shopping-dock, .toasts, dialog, .skip-link, .budget-label button { display: none !important; }
  .workspace, .shopping-mode .workspace { margin: 0; padding: 0; }
  main, .shopping-mode main { max-width: none; padding: 0; }
  .page-heading { margin-bottom: 18px; padding: 0; }
  .page-heading h1 { font-size: 24pt; }
  .page-heading p, .eyebrow { display: block !important; color: #555; }
  .summary-cards { gap: 12px; margin-bottom: 20px; }
  .stat-card { min-height: auto; padding: 12px; border-color: #ccc; }
  .stat-card > .stat-icon, .mini-ring { display: none; }
  .stat-card strong, .stat-card > div > span, .stat-card > div > small { color: #222; }
  .content-grid, .shopping-mode .content-grid { display: block; }
  .product-group { overflow: visible; break-inside: avoid; border-color: #ccc; margin-bottom: 14px; }
  .group-heading { min-height: 40px; padding: 8px 12px; }
  .group-heading h3, .group-heading > small { color: #222; font-size: 10pt; }
  .table-head, .product-row, .shopping-mode .product-row { display: grid; grid-template-columns: minmax(0, 1fr) 85px 90px 90px; gap: 10px; padding: 7px 12px; min-height: 48px; background: #fff; }
  .table-head { min-height: 28px; font-size: 7pt; color: #555; }
  .table-head > span:last-child { display: none; }
  .product-main { grid-column: 1; margin: 0; gap: 2px; }
  .product-name strong, .checked .product-name strong, .shopping-mode .product-name strong { color: #222; font-size: 10pt; }
  .product-name > span, .checked .product-name > span { color: #666; font-size: 7pt; }
  .check-item { width: 24px; height: 30px; }
  .check-item::before { width: 16px; height: 16px; border: 1px solid #777; }
  .checked .check-item::before { background: #fff; border-color: #444; }
  .check-item .icon { color: #222; }
  .quantity-control { grid-column: 2; justify-content: center; min-width: 0; width: auto; border: 0; background: transparent; }
  .quantity-control button { display: none; }
  .quantity-control > span, .quantity-control small { color: #222; font-size: 9pt; }
  .unit-price { grid-column: 3; color: #222 !important; font-size: 9pt; }
  .unit-price small { color: #777; }
  .subtotal { grid-column: 4; color: #222 !important; font-size: 9pt; }
  .subtotal::before { display: none; }
  .right-rail, .shopping-mode .right-rail { display: block; margin-top: 18px; }
  .budget-card { max-width: 360px; padding: 16px; border-color: #ccc; background: #fff; break-inside: avoid; }
  .budget-card * { color: #222 !important; }
  .budget-value { font-size: 20pt; }
  .budget-track { display: none; }
  .budget-lines dt, .budget-lines dd { font-size: 9pt; }
}

/* Product editor: compact desktop layout, scroll-safe on small viewports. */
@media screen {
  dialog:has(#item-form) { width: min(660px, calc(100% - 32px)); padding: 22px 24px; max-height: calc(100dvh - 32px); overflow-y: auto; scrollbar-width: none; }
  dialog:has(#item-form)::-webkit-scrollbar { display: none; }
  dialog:has(#item-form) .modal-head { margin-bottom: 14px; }
  #item-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 16px; }
  #item-form > :first-child, #item-form > .form-grid:nth-child(4),
  #item-form > .field-hint, #item-form > label:nth-child(6),
  #item-form > .form-error, #item-form > .modal-actions { grid-column: 1 / -1; }
  #item-form label { gap: 5px; }
  #item-form .field-hint { font-size: 12px; line-height: 1.5; margin: 0; }
  #item-form .form-error:empty { display: none; }
  #item-form .checkbox-label { grid-column: 1 / -1; }
  #item-form .modal-actions { margin-top: 0; padding-top: 12px; }
  #item-form .optional { margin-top: -24px; }
}
@media screen and (max-width: 600px) {
  dialog:has(#item-form) { width: calc(100% - 20px); max-height: calc(100dvh - 20px); padding: 18px 16px; border-radius: 16px; }
  dialog:has(#item-form) .modal-head { margin-bottom: 12px; }
  dialog:has(#item-form) .modal-head h2 { font-size: 20px; }
  #item-form { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  #item-form > * { grid-column: 1 !important; }
  #item-form input:not([type="checkbox"]), #item-form select { min-height: 44px; font-size: 16px; }
  #item-form .form-grid { gap: 10px; }
  #item-form .modal-actions { position: sticky; bottom: -18px; z-index: 2; padding: 12px 0 max(8px, env(safe-area-inset-bottom)); background: #fff; box-shadow: 0 -8px 12px #ffffffeb; }
  #item-form .modal-actions .button { flex: 1; min-height: 44px; }
}

/* Keep the product editor compact and reachable on short laptop screens. */
@media screen and (min-width: 601px) {
  dialog:has(#item-form) { width: min(760px, calc(100% - 40px)); max-height: none; overflow: visible; padding: 18px 24px; }
  dialog:has(#item-form) .modal-head { margin-bottom: 10px; }
  #item-form { grid-template-columns: 1.1fr .9fr; gap: 9px 16px; }
  #item-form > :first-child { grid-column: 1 / -1; }
  #item-form > .form-grid:nth-child(2) { grid-column: 1; }
  #item-form > label:nth-child(3) { grid-column: 2; }
  #item-form > .form-grid:nth-child(4) { grid-column: 1 / -1; }
  #item-form > .field-hint { grid-column: 1 / -1; line-height: 1.4; }
  #item-form > label:nth-child(6) { grid-column: 1; }
  #item-form > .checkbox-label { grid-column: 2; align-self: end; }
  #item-form > .form-error, #item-form > .modal-actions { grid-column: 1 / -1; }
  #item-form > label:nth-child(6) { align-self: end; }
  #item-form label { gap: 4px; font-size: 12px; }
  #item-form input:not([type="checkbox"]), #item-form select { min-height: 39px; padding-block: 7px; }
  #item-form .field-hint { font-size: 11px; }
  #item-form .checkbox-label { min-height: 39px; }
  #item-form .modal-actions { padding-top: 9px; }
}
/* The sidebar is fixed in place: all navigation remains visible without scrolling. */
.sidebar { overflow: hidden; overscroll-behavior: none; }
.sidebar nav, .sidebar-lists, .sidebar-bottom { flex-shrink: 0; }
.sidebar > .brand-tagline { margin-bottom: 0; }
.sidebar > .nav-label { margin-top: 26px; margin-bottom: 9px; }
.sidebar-lists { margin-top: 16px; }
.sidebar-bottom { padding-top: 16px; }
@media (max-height: 790px) and (min-width: 761px) {
  .sidebar { padding-top: 17px; padding-bottom: 10px; }
  .sidebar > .nav-label { margin-top: 17px; }
  .sidebar nav { gap: 2px; }
  .nav-item { min-height: 39px; }
  .sidebar-lists { margin-top: 10px; }
  .list-nav { min-height: 32px; }
  .new-list-button { min-height: 32px; margin-top: 7px; }
  .sidebar-bottom { padding-top: 8px; }
  .local-card { padding: 10px 12px 7px; }
  .local-card p { margin-top: 3px; line-height: 1.45; }
  .local-card button { min-height: 31px; }
  .profile-button { padding-top: 9px; }
}
@media (max-height: 620px) and (min-width: 761px) {
  .sidebar { padding-top: 10px; padding-bottom: 7px; }
  .sidebar > .nav-label { margin-top: 10px; margin-bottom: 5px; }
  .sidebar .brand-tagline { display: none; }
  .nav-item { min-height: 34px; }
  .sidebar-lists { margin-top: 6px; }
  .list-nav { min-height: 28px; }
  .new-list-button { min-height: 29px; }
  .sidebar-bottom { padding-top: 5px; }
  .local-card { padding: 7px 10px 5px; }
  .local-card .local-icon, .local-card p { display: none; }
  .local-card button { min-height: 28px; }
  .profile-button { padding-top: 5px; }
}

.auth-shell { min-height: 100dvh; display: grid; place-items: center; padding: clamp(20px, 5vw, 68px); background: radial-gradient(ellipse at 14% 8%, #eee8ff 0, transparent 35%), radial-gradient(ellipse at 92% 96%, #e9f3e9 0, transparent 34%), #f7f7fa; }
.auth-layout { width: min(100%, 1080px); display: grid; grid-template-columns: minmax(0, 1fr) minmax(390px, 460px); align-items: center; gap: clamp(40px, 8vw, 112px); }
.auth-story { position: relative; overflow: hidden; min-height: 570px; display: flex; flex-direction: column; justify-content: center; padding: clamp(26px, 4vw, 50px); border: 1px solid #e4def1; border-radius: 28px; background: linear-gradient(145deg, #f1edfb 0%, #f8f6fc 52%, #eff4ef 100%); }
.auth-story::after { position: absolute; right: -86px; top: -95px; width: 280px; height: 280px; border: 1px solid #d8ccef; border-radius: 50%; box-shadow: 0 0 0 28px #7254d309, 0 0 0 58px #7254d306; content: ''; pointer-events: none; }
.auth-story-brand { position: relative; z-index: 1; align-self: flex-start; margin: 0 0 clamp(42px, 7vh, 70px) -8px; }
.auth-story-kicker { color: #6947be; font-size: 11px; font-weight: 750; letter-spacing: .13em; }
.auth-story h2 { margin: 12px 0 12px; color: #30205b; font-size: clamp(30px, 3.5vw, 44px); line-height: 1.12; letter-spacing: -.045em; }
.auth-story h2 span { color: #7254d3; }
.auth-story > p { max-width: 410px; color: #665079; font-size: 15px; line-height: 1.7; }
.auth-preview { position: relative; z-index: 1; max-width: 440px; margin-top: 32px; padding: 17px 18px 12px; border: 1px solid #e6e0ef; border-radius: 18px; background: #ffffffdf; box-shadow: 0 18px 48px #49327412; transform: rotate(-1deg); }
.auth-preview-head, .auth-preview-row, .auth-preview-total { display: flex; align-items: center; gap: 10px; }
.auth-preview-head { justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid #eee9f5; color: #533a83; font-size: 12px; font-weight: 700; }
.auth-preview-head span:first-child { display: inline-flex; align-items: center; gap: 8px; }
.auth-preview-head .icon { width: 16px; height: 16px; color: #7254d3; }
.auth-preview-head span:last-child { border-radius: 20px; padding: 3px 8px; color: #6c5792; background: #f0ecfb; font-size: 10px; font-weight: 600; }
.auth-preview-row { min-height: 42px; border-bottom: 1px solid #f1edf5; color: #57466c; font-size: 11px; }
.auth-preview-row > i { width: 16px; height: 16px; flex: 0 0 16px; border: 1px solid #d9cfe9; border-radius: 50%; }
.auth-preview-row > i.auth-preview-check { display: grid; place-items: center; border-color: #b8a6dd; color: #fff; background: #b8a6dd; }
.auth-preview-check .icon { width: 11px; height: 11px; }
.auth-preview-row span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.auth-preview-row small { margin-left: auto; color: #7358a0; font-size: 10px; white-space: nowrap; }
.auth-preview-total { justify-content: space-between; padding-top: 12px; color: #7054af; font-size: 11px; font-weight: 650; }
.auth-preview-total .icon { width: 16px; height: 16px; }
.auth-story-foot { display: flex; align-items: center; gap: 8px; margin-top: 28px; color: #6f6388; font-size: 11px; }
.auth-story-foot .icon { width: 16px; height: 16px; color: #668b6f; }
.auth-card { width: 100%; padding: clamp(28px, 4vw, 42px); border: 1px solid #e8e1f2; border-radius: 24px; background: #fff; box-shadow: 0 24px 72px #432a7618; }
.auth-brand { display: inline-flex; margin-bottom: 30px; }
.auth-layout > .auth-card > .auth-brand { display: none; }
.auth-eyebrow { display: block; margin-bottom: 9px; color: #6947be; font-size: 11px; font-weight: 750; letter-spacing: .12em; }
.auth-card h1 { margin: 0 0 8px; color: #39285d; font-size: clamp(26px, 3vw, 31px); font-weight: 620; line-height: 1.2; letter-spacing: -.035em; }
.auth-card > p { margin: 0 0 25px; color: #746a83; font-size: 14px; line-height: 1.7; }
.auth-form { display: grid; gap: 16px; }
.auth-form label { display: grid; gap: 7px; color: #55466b; font-size: 13px; font-weight: 520; }
.auth-form input { width: 100%; min-height: 48px; padding: 0 14px; border: 1px solid #e3dced; border-radius: 11px; color: #514565; background: #fff; font: inherit; font-size: 15px; font-weight: 450; }
.auth-form input:focus { outline: 3px solid #7655d329; border-color: #7655d3; }
.auth-form .button { min-height: 48px; margin-top: 3px; font-weight: 550; }
.auth-text-button { display: block; margin: 14px auto 0; border: 0; padding: 5px; color: #715b99; background: transparent; font: inherit; font-size: 13px; font-weight: 450; cursor: pointer; }
.auth-text-button:hover { text-decoration: underline; }
.auth-privacy { margin: 23px 0 0 !important; border-top: 1px solid #eee9f5; padding-top: 15px; color: #887c9c !important; font-size: 12px !important; }
.auth-feedback { margin: 0; border: 1px solid #e9dffc; border-radius: 10px; padding: 10px 12px; color: #50358f; background: #f8f4ff; font-size: 13px; line-height: 1.5; }
.auth-setup ol { display: grid; gap: 13px; margin: 0 0 22px; padding-left: 22px; color: #52456b; font-size: 13px; line-height: 1.6; }
.auth-setup li::marker { color: #7151ca; font-weight: 750; }
.auth-setup code { border-radius: 5px; padding: 2px 5px; color: #553a96; background: #f2edfa; font-size: 12px; overflow-wrap: anywhere; }
.auth-setup a { color: #6543b1; font-weight: 650; }
.auth-card .auth-note { border-radius: 11px; padding: 12px 14px; color: #74688a; background: #f5f3f8; font-size: 12px; }
.account-chip { max-width: 220px; overflow: hidden; border: 1px solid #e3daef; border-radius: 9px; padding: 7px 10px; color: #573b91; background: #fff; font: inherit; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.account-chip:hover { border-color: #c9b9e7; background: #f7f3fc; }
@media (min-width: 761px) and (max-width: 1000px) {
  .auth-layout { grid-template-columns: minmax(0, 1fr) minmax(340px, 410px); gap: 26px; }
  .auth-story { min-height: 530px; padding: 28px; }
  .auth-preview { padding-inline: 13px; }
}
@media (max-width: 760px) {
  .auth-shell { align-items: start; padding: max(18px, env(safe-area-inset-top)) 16px max(22px, env(safe-area-inset-bottom)); }
  .auth-layout { width: min(100%, 500px); grid-template-columns: minmax(0, 1fr); gap: 14px; margin: auto; }
  .auth-story { min-height: auto; padding: 20px 22px; border-radius: 20px; }
  .auth-story::after { right: -130px; top: -165px; }
  .auth-story-brand { margin: 0 0 22px -6px; }
  .auth-story-kicker { font-size: 9px; }
  .auth-story h2 { margin: 7px 0 5px; font-size: clamp(24px, 7vw, 31px); }
  .auth-story > p { max-width: 440px; font-size: 12px; line-height: 1.5; }
  .auth-preview, .auth-story-foot { display: none; }
  .auth-card { margin-block: 0; padding: clamp(24px, 7vw, 34px); border-radius: 20px; }
  .auth-layout > .auth-card > .auth-brand { display: inline-flex; margin-bottom: 23px; }
  .auth-card h1 { font-size: clamp(25px, 7vw, 30px); }
  .account-chip { max-width: 110px; padding-inline: 7px; font-size: 10px; }
}
@media (max-height: 790px) and (min-width: 761px) {
  .sidebar-collapsed .sidebar { padding-top: 12px; padding-bottom: 9px; }
  .sidebar-collapsed .sidebar nav { margin-top: 12px; }
  .sidebar-collapsed .nav-item, .sidebar-collapsed .list-nav,
  .sidebar-collapsed .sidebar-backup, .sidebar-collapsed .new-list-button { min-height: 37px; }
  .sidebar-collapsed .sidebar-lists { padding-top: 8px; margin-top: 10px; }
  .sidebar-collapsed .sidebar-bottom { padding-top: 8px; }
}
