/*
 * LotWise design system. See docs/design-system.md.
 * One stylesheet for tokens, type, the app shell and every shared component.
 * Page-specific styles: public/css/pages/*.css (tokens only).
 */

/* ---------- fonts: FiraGO (Georgian, Latin, Cyrillic in one family) ---------- */
@font-face { font-family: 'FiraGO'; font-style: normal; font-weight: 400; font-display: swap; src: url('/fonts/firago-400.woff2') format('woff2'); }
@font-face { font-family: 'FiraGO'; font-style: normal; font-weight: 500; font-display: swap; src: url('/fonts/firago-500.woff2') format('woff2'); }
@font-face { font-family: 'FiraGO'; font-style: normal; font-weight: 600; font-display: swap; src: url('/fonts/firago-600.woff2') format('woff2'); }
@font-face { font-family: 'FiraGO'; font-style: normal; font-weight: 700; font-display: swap; src: url('/fonts/firago-700.woff2') format('woff2'); }

/* ---------- tokens ---------- */
:root {
  --bg: #f6f7f9;
  --surface: #ffffff;
  --surface-2: #f9fafb;
  --surface-3: #f2f4f7;
  --text: #101828;
  --text-2: #475467;
  --muted: #667085;
  --faint: #98a2b3;
  --border: #e4e7ec;
  --border-strong: #d0d5dd;
  --navy: #10233f;
  --teal: #008f83;
  --teal-hover: #007a70;
  --teal-press: #00675f;
  --teal-text: #00766c;
  --teal-soft: #e6f4f2;
  --teal-ring: rgba(0, 143, 131, 0.22);
  --success: #067647;
  --success-soft: #ecfdf3;
  --success-line: #abefc6;
  --warning: #b54708;
  --warning-soft: #fffaeb;
  --warning-line: #fedf89;
  --danger: #c4320a;
  --danger-strong: #d92d20;
  --danger-soft: #fef3f2;
  --danger-line: #fecdca;
  --info: #175cd3;
  --info-soft: #eff8ff;

  --font: 'FiraGO', 'Noto Sans Georgian', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --fs-xs: 12px;
  --fs-sm: 13px;
  --fs: 14px;
  --fs-md: 16px;
  --fs-lg: 18px;
  --fs-xl: 24px;
  --lh: 1.5;

  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 20px; --s6: 24px; --s8: 32px; --s10: 40px;
  --r-sm: 6px;
  --r: 8px;
  --r-lg: 10px;
  --shadow-xs: 0 1px 2px rgba(16, 24, 40, 0.05);
  --shadow-pop: 0 12px 24px -6px rgba(16, 24, 40, 0.14), 0 4px 8px -4px rgba(16, 24, 40, 0.06);
  --ease: 140ms cubic-bezier(0.2, 0, 0, 1);
  --ease-pop: 180ms cubic-bezier(0.2, 0, 0, 1);
  --ring: 0 0 0 3px var(--teal-ring);

  --rail-w: 224px;
  --rail-w-min: 64px;
  --top-h: 56px;
  color-scheme: light;
}
[data-theme='dark'] {
  --bg: #0b111c;
  --surface: #111827;
  --surface-2: #151e2e;
  --surface-3: #1b2638;
  --text: #e7ebf1;
  --text-2: #aab4c3;
  --muted: #8390a4;
  --faint: #5f6b7e;
  --border: #222d40;
  --border-strong: #2e3a50;
  --navy: #dce4f0;
  --teal: #0f9d8f;
  --teal-hover: #14ae9f;
  --teal-press: #0d8b7f;
  --teal-text: #3cc9ba;
  --teal-soft: rgba(20, 166, 151, 0.14);
  --teal-ring: rgba(60, 201, 186, 0.3);
  --success: #47cd89;
  --success-soft: rgba(71, 205, 137, 0.12);
  --success-line: rgba(71, 205, 137, 0.3);
  --warning: #fdb022;
  --warning-soft: rgba(253, 176, 34, 0.1);
  --warning-line: rgba(253, 176, 34, 0.3);
  --danger: #f97066;
  --danger-strong: #f97066;
  --danger-soft: rgba(249, 112, 102, 0.1);
  --danger-line: rgba(249, 112, 102, 0.3);
  --info: #84caff;
  --info-soft: rgba(132, 202, 255, 0.1);
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-pop: 0 16px 32px -8px rgba(0, 0, 0, 0.6), 0 4px 8px -4px rgba(0, 0, 0, 0.4);
  color-scheme: dark;
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text); font: 400 var(--fs) / var(--lh) var(--font);
  font-feature-settings: 'kern', 'liga', 'calt'; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
html:lang(ka) body { --lh: 1.6; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; color: var(--text); letter-spacing: -0.01em; }
html:lang(ka) h1, html:lang(ka) h2, html:lang(ka) h3, html:lang(ka) h4 { letter-spacing: 0; }
h2 { font-size: var(--fs-md); line-height: 1.4; }
h3 { font-size: 15px; line-height: 1.4; }
p { margin: 0; }
a { color: var(--teal-text); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
b, strong { font-weight: 600; }
img { max-width: 100%; }
svg { flex: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
::selection { background: var(--teal-soft); }
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: var(--r-sm); }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.muted { color: var(--muted); }
.hint { color: var(--muted); font-size: var(--fs-xs); font-weight: 400; line-height: 1.45; }
.small { font-size: var(--fs-sm); }
.nowrap { white-space: nowrap; }
.center { text-align: center; }
.num, .price, .kpi-value, .n { font-variant-numeric: tabular-nums; }
.code { font-variant-numeric: tabular-nums slashed-zero; font-feature-settings: 'tnum', 'zero'; letter-spacing: 0.01em; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2); }
.spacer { flex: 1; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3) var(--s4); }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s3) var(--s4); }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s3) var(--s4); }
@media (max-width: 760px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } .hide-phone { display: none !important; } }
@media (max-width: 1024px) { .hide-sm { display: none !important; } }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px;
  border: 1px solid var(--border-strong); border-radius: var(--r); background: var(--surface); color: var(--text);
  font: 500 var(--fs) / 1 var(--font); white-space: nowrap; text-decoration: none; box-shadow: var(--shadow-xs);
  transition: background var(--ease), border-color var(--ease), color var(--ease), box-shadow var(--ease), transform var(--ease);
}
.btn:hover { background: var(--surface-2); border-color: var(--border-strong); text-decoration: none; }
.btn:active { transform: translateY(0.5px); background: var(--surface-3); }
.btn:focus-visible { box-shadow: var(--ring); border-radius: var(--r); }
.btn svg { width: 16px; height: 16px; }
.btn.primary { background: var(--teal); border-color: var(--teal); color: #fff; }
.btn.primary:hover { background: var(--teal-hover); border-color: var(--teal-hover); }
.btn.primary:active { background: var(--teal-press); }
.btn.ghost { background: transparent; border-color: transparent; box-shadow: none; color: var(--text-2); }
.btn.ghost:hover { background: var(--surface-3); color: var(--text); }
.btn.danger { color: var(--danger); }
.btn.danger:hover { background: var(--danger-soft); border-color: var(--danger-line); }
.btn.primary.danger { background: var(--danger-strong); border-color: var(--danger-strong); color: #fff; }
.btn.dark { background: var(--navy); border-color: var(--navy); color: #fff; }
.btn.sm { height: 30px; padding: 0 10px; font-size: var(--fs-sm); border-radius: var(--r-sm); }
.btn.lg { height: 42px; padding: 0 18px; font-size: 15px; }
.btn.icon { width: 36px; padding: 0; }
.btn.icon.sm { width: 30px; }
.btn.block { width: 100%; }
.btn:disabled, .btn[aria-disabled='true'] { opacity: 0.5; cursor: not-allowed; transform: none; }
.btn.busy { position: relative; color: transparent !important; pointer-events: none; }
.btn.busy::after { content: ''; position: absolute; inset: 0; margin: auto; width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--border-strong); border-top-color: var(--text-2); animation: spin 0.7s linear infinite; }
.btn.primary.busy::after { border-color: rgba(255, 255, 255, 0.4); border-top-color: #fff; }
@keyframes spin { to { transform: rotate(360deg); } }
.linklike { border: 0; background: none; padding: 0; color: var(--teal-text); font: inherit; font-weight: 500; cursor: pointer; text-align: left; }
.linklike:hover { text-decoration: underline; text-underline-offset: 2px; }

/* ---------- form controls ---------- */
.field { display: grid; gap: 6px; font-size: var(--fs-sm); font-weight: 500; color: var(--text-2); min-width: 0; }
.field > .hint { margin-top: -2px; }
input[type='text'], input[type='email'], input[type='tel'], input[type='number'], input[type='password'], input[type='search'],
input[type='url'], input[type='date'], input:not([type]), select, textarea {
  width: 100%; min-width: 0; height: 36px; padding: 0 12px; border: 1px solid var(--border-strong); border-radius: var(--r);
  background: var(--surface); color: var(--text); font: 400 var(--fs) / 1.4 var(--font); box-shadow: var(--shadow-xs);
  transition: border-color var(--ease), box-shadow var(--ease);
}
textarea { height: auto; padding: 9px 12px; resize: vertical; line-height: 1.5; }
select { padding-right: 32px; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23667085' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 10px center; background-size: 16px; cursor: pointer; }
input::placeholder, textarea::placeholder { color: var(--faint); }
input:hover, select:hover, textarea:hover { border-color: var(--faint); }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--teal); box-shadow: var(--ring); }
input:disabled, select:disabled, textarea:disabled { background: var(--surface-2); color: var(--muted); cursor: not-allowed; }
input[type='checkbox'], input[type='radio'] { width: 16px; height: 16px; margin: 0; accent-color: var(--teal); cursor: pointer; }
input[type='search']::-webkit-search-cancel-button { cursor: pointer; }
.check-row { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); font-size: var(--fs-sm); }
.check-row label, label.check { display: inline-flex; align-items: center; gap: var(--s2); font-weight: 400; color: var(--text); cursor: pointer; }
.form-error { padding: 10px 12px; border-radius: var(--r); background: var(--danger-soft); border: 1px solid var(--danger-line); color: var(--danger); font-size: var(--fs-sm); }
.search-input { position: relative; display: flex; align-items: center; flex: 1; min-width: 180px; }
.search-input > svg { position: absolute; left: 11px; width: 16px; height: 16px; color: var(--muted); pointer-events: none; }
.search-input input { padding-left: 34px; }
.pw-wrap { position: relative; display: block; }
.pw-wrap input { padding-right: 64px; }
.pw-wrap button { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border: 0; background: none; color: var(--muted); font-size: var(--fs-xs); font-weight: 500; padding: 4px 6px; border-radius: var(--r-sm); }
.pw-wrap button:hover { color: var(--text); background: var(--surface-3); }
.strength { height: 4px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.strength i { display: block; height: 100%; width: 0; transition: width var(--ease), background var(--ease); }

/* Switch */
.switch { display: inline-flex; align-items: center; gap: var(--s2); cursor: pointer; font-size: var(--fs); color: var(--text); }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch .track { position: relative; width: 34px; height: 20px; border-radius: 99px; background: var(--border-strong); transition: background var(--ease); flex: none; }
.switch .track::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(16, 24, 40, 0.2); transition: transform var(--ease); }
.switch input:checked + .track { background: var(--teal); }
.switch input:checked + .track::after { transform: translateX(14px); }
.switch input:focus-visible + .track { box-shadow: var(--ring); }

/* Segmented control */
.seg { display: inline-flex; gap: 2px; padding: 3px; background: var(--surface-3); border-radius: var(--r); border: 1px solid var(--border); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg > button, .seg > a { border: 0; background: none; height: 28px; padding: 0 12px; border-radius: var(--r-sm); color: var(--text-2); font: 500 var(--fs-sm) / 1 var(--font); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; text-decoration: none; transition: background var(--ease), color var(--ease); }
.seg > button:hover, .seg > a:hover { color: var(--text); text-decoration: none; }
.seg > [aria-pressed='true'], .seg > [aria-selected='true'], .seg > .active { background: var(--surface); color: var(--text); box-shadow: var(--shadow-xs), 0 0 0 1px var(--border); }

/* Chips (filters) and pills (status) */
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; border: 1px solid var(--border-strong); border-radius: 99px; background: var(--surface); color: var(--text-2); font: 500 var(--fs-sm) / 1 var(--font); cursor: pointer; white-space: nowrap; transition: background var(--ease), border-color var(--ease), color var(--ease); }
.chip:hover { border-color: var(--faint); color: var(--text); }
.chip[aria-pressed='true'], .chip.on { background: var(--teal-soft); border-color: var(--teal); color: var(--teal-text); }
.chip svg { width: 14px; height: 14px; }
.pill, .badge { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: 99px; background: var(--surface-3); color: var(--text-2); font: 500 var(--fs-xs) / 1 var(--font); white-space: nowrap; }
.pill.good { background: var(--success-soft); color: var(--success); }
.pill.warn { background: var(--warning-soft); color: var(--warning); }
.pill.bad { background: var(--danger-soft); color: var(--danger); }
.pill.cone, .pill.info, .pill.teal { background: var(--teal-soft); color: var(--teal-text); }
.tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-sm); border: 1px solid var(--border); color: var(--text-2); font-size: var(--fs-xs); background: var(--surface); }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 3px var(--success-soft); flex: none; }
.dot.off { background: var(--faint); box-shadow: 0 0 0 3px var(--surface-3); }
.dot.warn { background: var(--warning); box-shadow: 0 0 0 3px var(--warning-soft); }
.dot.bad { background: var(--danger-strong); box-shadow: 0 0 0 3px var(--danger-soft); }

/* ---------- surfaces ---------- */
.panel, .card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); min-width: 0; }
.card { padding: var(--s5); }
.card > h3, .card > h2 { margin-bottom: var(--s3); }
.panel-head { display: flex; align-items: center; gap: var(--s3); min-height: 52px; padding: var(--s3) var(--s4) var(--s3) var(--s5); border-bottom: 1px solid var(--border); }
.panel-head h2, .panel-head h3 { font-size: 15px; }
.panel-head .sub { color: var(--muted); font-size: var(--fs-sm); }
.panel-head .actions { margin-left: auto; display: flex; gap: var(--s2); align-items: center; }
.panel-body { padding: var(--s4) var(--s5); }
.panel-foot { padding: var(--s3) var(--s5); border-top: 1px solid var(--border); display: flex; gap: var(--s2); align-items: center; }
.section { margin-top: var(--s8); }
.section:first-child { margin-top: 0; }
.section-head { display: flex; align-items: center; gap: var(--s3); margin-bottom: var(--s3); flex-wrap: wrap; min-height: 32px; }
.section-head h2 { font-size: var(--fs-md); }
.section-head .muted { font-size: var(--fs-sm); }
.section-head .more, .more { margin-left: auto; color: var(--teal-text); font-weight: 500; font-size: var(--fs-sm); }

/* Notices */
.notice, .limit-note, .banner {
  display: flex; align-items: center; gap: var(--s3); padding: 10px 14px; border-radius: var(--r); border: 1px solid var(--border);
  background: var(--surface); color: var(--text-2); font-size: var(--fs-sm);
}
.notice svg, .banner svg { width: 16px; height: 16px; color: var(--muted); }
.notice .btn, .banner .btn { margin-left: auto; }
.notice.warn, .limit-note { background: var(--warning-soft); border-color: var(--warning-line); color: var(--text); }
.banner { background: var(--danger-soft); border-color: var(--danger-line); color: var(--text); margin: var(--s3) var(--s6) 0; }
.search-error { padding: 8px 10px; border-radius: var(--r-sm); background: var(--danger-soft); color: var(--danger); font-size: var(--fs-xs); line-height: 1.45; overflow-wrap: anywhere; }
.imp-banner { display: flex; align-items: center; gap: var(--s3); padding: 8px var(--s6); background: var(--navy); color: #fff; font-size: var(--fs-sm); }
[data-theme='dark'] .imp-banner { background: #1d3557; }
.imp-banner svg { width: 16px; height: 16px; }
.imp-banner .btn { margin-left: auto; }

/* Empty states: compact, the height of their content. */
.empty { display: grid; justify-items: center; gap: 6px; padding: var(--s8) var(--s6); text-align: center; background: var(--surface); border: 1px dashed var(--border-strong); border-radius: var(--r-lg); }
.empty > svg, .empty .empty-icon { width: 20px; height: 20px; color: var(--muted); margin-bottom: 4px; }
.empty h3 { font-size: 15px; }
.empty p { color: var(--muted); font-size: var(--fs-sm); max-width: 46ch; }
.empty .btn { margin-top: var(--s2); }
.empty.inline { padding: var(--s5); border-style: solid; }

/* Skeleton */
.skeleton { position: relative; overflow: hidden; background: var(--surface-3); border-radius: var(--r); min-height: 16px; }
.skeleton::after { content: ''; position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.55), transparent); animation: shimmer 1.2s infinite; }
[data-theme='dark'] .skeleton::after { background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent); }
@keyframes shimmer { to { transform: translateX(100%); } }

/* KPIs: one strip, not floating cards. */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; }
.kpi { display: grid; align-content: start; gap: 4px; padding: var(--s4) var(--s5); border-right: 1px solid var(--border); min-width: 0; color: inherit; text-decoration: none; position: relative; }
.kpi:last-child { border-right: 0; }
a.kpi:hover { background: var(--surface-2); text-decoration: none; }
.kpi .kpi-label, .kpi .l { order: -1; color: var(--muted); font-size: var(--fs-sm); line-height: 1.4; }
.kpi .kpi-value, .kpi .n { font-size: 22px; line-height: 1.25; font-weight: 600; color: var(--text); letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi .kpi-note { color: var(--muted); font-size: var(--fs-xs); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.kpi.hot .kpi-value, .kpi.hot .n { color: var(--warning); }
.kpi.good .kpi-value { color: var(--teal-text); }

/* Key-value lists */
.kv { display: grid; grid-template-columns: minmax(110px, auto) 1fr; gap: 8px 16px; margin: 0; font-size: var(--fs-sm); }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; color: var(--text); font-weight: 500; min-width: 0; overflow-wrap: anywhere; }

/* Tables */
.table-wrap, .table-scroll { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); }
table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
th { text-align: left; font-weight: 500; font-size: var(--fs-xs); color: var(--muted); background: var(--surface-2); padding: 9px var(--s4); border-bottom: 1px solid var(--border); white-space: nowrap; position: sticky; top: 0; z-index: 1; }
th button { border: 0; background: none; padding: 0; font: inherit; color: inherit; display: inline-flex; gap: 4px; align-items: center; }
th button:hover { color: var(--text); }
td { padding: 10px var(--s4); border-bottom: 1px solid var(--border); vertical-align: middle; color: var(--text); }
tbody tr:last-child td { border-bottom: 0; }
tbody tr { transition: background var(--ease); }
tbody tr:hover td, tr.click:hover td { background: var(--surface-2); }
tr.click { cursor: pointer; }
.panel > .table-wrap, .panel > .table-scroll { border: 0; border-radius: 0 0 var(--r-lg) var(--r-lg); }

/* Pager */
.pager { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s3) 0 0; color: var(--muted); font-size: var(--fs-sm); flex-wrap: wrap; }

/* Timeline / activity */
.timeline { display: grid; }
.timeline .ev { display: grid; grid-template-columns: auto 1fr; gap: 2px 12px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: var(--fs-sm); }
.timeline .ev:last-child { border-bottom: 0; }
.timeline .ev time { color: var(--muted); font-size: var(--fs-xs); white-space: nowrap; font-variant-numeric: tabular-nums; padding-top: 1px; }

/* Bars (admin charts with real data only) */
.bars { display: flex; align-items: flex-end; gap: 4px; height: 120px; padding-top: var(--s2); }
.bar { flex: 1; min-height: 2px; background: var(--teal); border-radius: 3px 3px 0 0; opacity: 0.85; position: relative; }
.bar:hover { opacity: 1; }
.bar[data-tip]:hover::after { content: attr(data-tip); position: absolute; bottom: calc(100% + 6px); left: 50%; transform: translateX(-50%); background: var(--navy); color: #fff; font-size: var(--fs-xs); padding: 4px 8px; border-radius: var(--r-sm); white-space: nowrap; z-index: 3; }
[data-theme='dark'] .bar[data-tip]:hover::after { background: #000; }
.bar-labels { display: flex; gap: 4px; margin-top: 6px; }
.bar-labels span { flex: 1; text-align: center; font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; }
.hbar { display: grid; grid-template-columns: minmax(80px, 30%) 1fr auto; gap: var(--s3); align-items: center; font-size: var(--fs-sm); padding: 4px 0; }
.hbar .t { height: 6px; background: var(--surface-3); border-radius: 99px; overflow: hidden; }
.hbar .t i { display: block; height: 100%; background: var(--teal); border-radius: inherit; }

/* Usage meters */
.usage { display: grid; gap: 6px; }
.usage-top { display: flex; justify-content: space-between; gap: var(--s3); font-size: var(--fs-sm); color: var(--text-2); }
.usage-top b { color: var(--text); font-variant-numeric: tabular-nums; }
.usage-bar { height: 6px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.usage-bar i { display: block; height: 100%; background: var(--teal); border-radius: inherit; }
.usage-bar.warn i { background: var(--warning); }
.usage-bar.full i { background: var(--danger-strong); }

/* Avatar */
.avatar { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--teal-soft); color: var(--teal-text); font: 600 12px/1 var(--font); border: 0; flex: none; }
button.avatar { cursor: pointer; }
button.avatar:hover { box-shadow: 0 0 0 3px var(--surface-3); }
.ucell { display: flex; align-items: center; gap: var(--s3); min-width: 0; }
.ucell > span:last-child { display: grid; min-width: 0; }
.ucell b { font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ucell span span { color: var(--muted); font-size: var(--fs-xs); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- app shell ---------- */
.shell { display: grid; grid-template-columns: var(--rail-w) minmax(0, 1fr); min-height: 100vh; }
body.rail-min .shell { grid-template-columns: var(--rail-w-min) minmax(0, 1fr); }

.rail { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: var(--s3); padding: var(--s3); background: var(--surface); border-right: 1px solid var(--border); overflow: hidden auto; scrollbar-width: thin; z-index: 30; }
.rail-top { display: flex; align-items: center; gap: var(--s2); height: 40px; padding: 0 var(--s1) 0 var(--s2); }
.brand { display: flex; align-items: center; min-width: 0; text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand .logo-img { height: 26px; width: auto; display: block; }
.brand .brand-mark { display: none; width: 30px; height: 30px; border-radius: 7px; }
.logo-img.on-dark { display: none; }
[data-theme='dark'] .logo-img.on-light { display: none; }
[data-theme='dark'] .logo-img.on-dark { display: block; }
.rail-collapse { margin-left: auto; color: var(--muted); }
.rail-new { width: 100%; justify-content: flex-start; gap: var(--s2); }
.rail-new .kbd { margin-left: auto; }
.rail nav { display: grid; gap: 1px; }
.rail-sep { padding: var(--s4) var(--s3) 6px; font-size: var(--fs-xs); font-weight: 500; color: var(--faint); white-space: nowrap; overflow: hidden; }
.rail-link {
  display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 var(--s3); border-radius: var(--r); color: var(--text-2);
  font-size: var(--fs); font-weight: 500; text-decoration: none; white-space: nowrap; position: relative; transition: background var(--ease), color var(--ease);
}
.rail-link svg { width: 18px; height: 18px; color: var(--muted); }
.rail-link span:not(.count) { overflow: hidden; text-overflow: ellipsis; }
.rail-link:hover { background: var(--surface-3); color: var(--text); text-decoration: none; }
.rail-link.active { background: var(--surface-3); color: var(--text); }
.rail-link.active svg { color: var(--teal); }
.rail-link.active::before { content: ''; position: absolute; left: calc(-1 * var(--s3)); top: 8px; bottom: 8px; width: 2px; border-radius: 0 2px 2px 0; background: var(--teal); }
.rail-link .count { margin-left: auto; min-width: 20px; height: 18px; padding: 0 6px; border-radius: 99px; background: var(--teal-soft); color: var(--teal-text); font: 600 11px/18px var(--font); text-align: center; font-variant-numeric: tabular-nums; }
.rail-link .count:empty { display: none; }
.rail-foot { margin-top: auto; display: grid; gap: 2px; padding-top: var(--s3); border-top: 1px solid var(--border); }
.rail-foot button, .health-line { display: flex; align-items: center; gap: 10px; height: 32px; padding: 0 var(--s3); border: 0; background: none; border-radius: var(--r); color: var(--text-2); font-size: var(--fs-sm); white-space: nowrap; overflow: hidden; text-align: left; }
.rail-foot button:hover { background: var(--surface-3); color: var(--text); }
.rail-foot button svg { width: 16px; height: 16px; color: var(--muted); }
.health-line { color: var(--muted); }
.health-line .dot { margin: 0 4px; }
/* Collapsed rail: icons only. */
body.rail-min .rail { padding: var(--s3) 10px; align-items: stretch; }
body.rail-min .brand .logo-img { display: none !important; }
body.rail-min .brand .brand-mark { display: block; }
body.rail-min .rail-top { flex-direction: column; height: auto; gap: var(--s2); padding: 0; }
body.rail-min .rail-collapse { margin: 0; }
body.rail-min .rail-collapse svg { transform: rotate(180deg); }
body.rail-min .rail-new { width: 42px; padding: 0; justify-content: center; margin: 0 auto; }
body.rail-min .rail-new span, body.rail-min .rail-link span, body.rail-min .rail-sep, body.rail-min .rail-foot button span, body.rail-min #healthText { display: none; }
body.rail-min .rail-sep { display: block; height: 1px; padding: 0; margin: var(--s2) 6px; background: var(--border); font-size: 0; }
body.rail-min .rail-link, body.rail-min .rail-foot button, body.rail-min .health-line { justify-content: center; padding: 0; }
body.rail-min .rail-link.active::before { left: -10px; }
body.rail-min .rail-link .count { position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px; line-height: 16px; padding: 0 4px; font-size: 10px; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: var(--s4); height: var(--top-h); padding: 0 var(--s6); background: var(--surface); border-bottom: 1px solid var(--border); }
.topbar-brand { display: none; }
.topbar-brand img { width: 30px; height: 30px; border-radius: 7px; display: block; }
.crumbs { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: var(--fs-sm); color: var(--muted); white-space: nowrap; }
.crumbs a { color: var(--muted); }
.crumbs a:hover { color: var(--text); text-decoration: none; }
.crumbs > span:last-child { color: var(--text); font-weight: 500; overflow: hidden; text-overflow: ellipsis; }
.crumbs svg { width: 15px; height: 15px; }
.crumbs .sep { color: var(--faint); }
.global-search { position: relative; display: flex; align-items: center; flex: 0 1 420px; margin-left: auto; }
.global-search > svg { position: absolute; left: 11px; width: 16px; height: 16px; color: var(--muted); pointer-events: none; }
.global-search input { height: 34px; padding-left: 34px; padding-right: 36px; background: var(--surface-2); border-color: var(--border); box-shadow: none; font-size: var(--fs-sm); }
.global-search input:focus { background: var(--surface); }
.global-search .kbd { position: absolute; right: 8px; }
.kbd { display: inline-grid; place-items: center; min-width: 20px; height: 20px; padding: 0 5px; border: 1px solid var(--border-strong); border-bottom-width: 2px; border-radius: 5px; color: var(--muted); font: 500 11px/1 var(--font); background: var(--surface); }
.topbar-actions { display: flex; align-items: center; gap: var(--s2); }
.monitor { display: inline-flex; align-items: center; gap: var(--s2); height: 30px; padding: 0 10px; border: 1px solid var(--border); border-radius: 99px; color: var(--text-2); font-size: var(--fs-xs); font-weight: 500; white-space: nowrap; text-decoration: none; }
.monitor:hover { background: var(--surface-2); text-decoration: none; color: var(--text); }
.monitor:empty { display: none; }
.top-icons { display: flex; align-items: center; gap: var(--s1); }
.icon-pop { position: relative; }
.bell-btn { position: relative; }
.bell-btn .dotn { position: absolute; top: 3px; right: 3px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 99px; background: var(--danger-strong); color: #fff; font: 600 10px/16px var(--font); text-align: center; border: 2px solid var(--surface); box-sizing: content-box; }

#notices { display: grid; gap: var(--s2); padding: 0 var(--s6); }
#notices:not(:empty) { padding-top: var(--s4); }
.page-head { display: flex; align-items: flex-end; gap: var(--s4); padding: var(--s6) var(--s6) var(--s5); flex-wrap: wrap; }
.page-head > div:first-child { min-width: 0; flex: 1 1 320px; }
.page-head h1 { font-size: var(--fs-xl); line-height: 1.25; font-weight: 600; letter-spacing: -0.02em; }
html:lang(ka) .page-head h1 { font-size: 22px; line-height: 1.35; letter-spacing: 0; }
.page-head .sub { margin-top: 4px; color: var(--muted); font-size: var(--fs); max-width: 72ch; }
.page-head .sub:empty { display: none; }
#topActions { display: flex; gap: var(--s2); align-items: center; flex-wrap: wrap; }
.page { padding: 0 var(--s6) var(--s10); width: 100%; max-width: 1600px; }

/* Popovers and menus */
.pop { position: absolute; right: 0; top: calc(100% + 8px); z-index: 50; width: 320px; max-width: calc(100vw - 24px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-pop); overflow: hidden; animation: pop-in var(--ease-pop); }
@keyframes pop-in { from { opacity: 0; transform: translateY(-4px); } }
.pop-head { display: flex; align-items: center; gap: var(--s2); padding: var(--s3) var(--s4); border-bottom: 1px solid var(--border); font-weight: 600; }
.pop-head .linklike { margin-left: auto; font-size: var(--fs-sm); }
.pop-list { max-height: min(420px, 70vh); overflow-y: auto; }
.pop-empty { padding: var(--s6) var(--s4); text-align: center; color: var(--muted); font-size: var(--fs-sm); }
.note { display: grid; grid-template-columns: 28px 1fr; gap: 10px; width: 100%; padding: 10px var(--s4); border: 0; border-bottom: 1px solid var(--border); background: none; text-align: left; font: inherit; color: inherit; }
.note:hover { background: var(--surface-2); }
.note.unread { background: var(--teal-soft); }
.note .ic { width: 28px; height: 28px; border-radius: var(--r); background: var(--surface-3); display: grid; place-items: center; color: var(--text-2); }
.note .ic svg { width: 15px; height: 15px; }
.note > span:last-child { display: grid; gap: 2px; min-width: 0; font-size: var(--fs-sm); }
.note b { font-weight: 500; }
.note span span { color: var(--text-2); font-size: var(--fs-xs); }
.note time { color: var(--muted); font-size: 11px; }
.menu-pop { width: 260px; padding: 6px; }
.menu-pop .who { padding: 8px 10px 10px; border-bottom: 1px solid var(--border); margin: -6px -6px 6px; display: grid; gap: 2px; }
.menu-pop .who b { font-weight: 600; }
.menu-pop .who span { color: var(--muted); font-size: var(--fs-xs); overflow: hidden; text-overflow: ellipsis; }
.menu-pop .who .pill { justify-self: start; margin-top: 4px; }
.menu-pop a, .menu-pop .mi { display: flex; align-items: center; gap: 10px; width: 100%; height: 34px; padding: 0 10px; border: 0; border-radius: var(--r-sm); background: none; color: var(--text); font-size: var(--fs-sm); text-decoration: none; text-align: left; }
.menu-pop a:hover, .menu-pop .mi:hover { background: var(--surface-3); text-decoration: none; }
.menu-pop svg { width: 16px; height: 16px; color: var(--muted); }
.menu-pop .lang-row { display: flex !important; align-items: center; justify-content: space-between; gap: var(--s2); padding: 6px 10px !important; margin: 4px -6px; border-top: 1px solid var(--border) !important; border-bottom: 1px solid var(--border) !important; font-size: var(--fs-sm); }
.lang-switch { display: inline-flex; padding: 2px; gap: 2px; border: 1px solid var(--border); border-radius: var(--r-sm); background: var(--surface-2); }
.lang-switch button { border: 0; background: none; min-width: 32px; height: 24px; padding: 0 6px; border-radius: 4px; color: var(--muted); font: 600 11.5px/1 var(--font); }
.lang-switch button:hover { color: var(--text); }
.lang-switch button[aria-pressed='true'] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-xs), 0 0 0 1px var(--border); }

/* Dialogs */
dialog.sheet { width: min(560px, calc(100vw - 32px)); max-height: calc(100vh - 48px); padding: 0; border: 1px solid var(--border); border-radius: var(--r-lg); background: var(--surface); color: var(--text); box-shadow: var(--shadow-pop); overflow: auto; }
dialog.sheet.small { width: min(440px, calc(100vw - 32px)); }
dialog.sheet.wide, dialog.sheet.small.wide { width: min(680px, calc(100vw - 32px)); }
dialog.sheet[open] { animation: dlg-in var(--ease-pop); }
@keyframes dlg-in { from { opacity: 0; transform: translateY(6px) scale(0.99); } }
dialog::backdrop { background: rgba(16, 24, 40, 0.45); }
[data-theme='dark'] dialog::backdrop { background: rgba(0, 0, 0, 0.6); }
.sheet-body { display: grid; gap: var(--s3); padding: var(--s5) var(--s6) var(--s6); }
.sheet-body h2 { font-size: var(--fs-lg); }
.sheet-body > p.muted { font-size: var(--fs-sm); margin-top: -4px; }
.sheet-foot { display: flex; justify-content: flex-end; gap: var(--s2); margin-top: var(--s3); }

/* Drawer (side panel) */
.drawer { position: fixed; inset: 0; z-index: 60; display: flex; justify-content: flex-end; }
.drawer-backdrop { position: absolute; inset: 0; background: rgba(16, 24, 40, 0.4); animation: fade-in var(--ease-pop); }
@keyframes fade-in { from { opacity: 0; } }
.drawer-panel { position: relative; width: min(520px, 100vw); height: 100%; overflow-y: auto; background: var(--surface); border-left: 1px solid var(--border); box-shadow: var(--shadow-pop); animation: slide-in var(--ease-pop); }
.drawer-panel.wide { width: min(760px, 100vw); }
@keyframes slide-in { from { transform: translateX(16px); opacity: 0.6; } }

/* Toasts */
.toasts { position: fixed; right: var(--s5); bottom: var(--s5); z-index: 90; display: grid; gap: var(--s2); width: min(380px, calc(100vw - 32px)); }
.toast { display: flex; align-items: flex-start; gap: var(--s3); padding: 12px 14px; border-radius: var(--r-lg); background: var(--surface); border: 1px solid var(--border); border-left: 3px solid var(--teal); box-shadow: var(--shadow-pop); font-size: var(--fs-sm); color: var(--text); animation: pop-in var(--ease-pop); }
.toast.success { border-left-color: var(--success); }
.toast.error { border-left-color: var(--danger-strong); }
.toast span { flex: 1; }
.toast button { border: 0; background: none; color: var(--teal-text); font-weight: 600; padding: 0; }

/* Maintenance screen */
.maintenance { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: var(--s6); background: var(--bg); }
.maintenance-card { width: min(420px, 100%); display: grid; justify-items: center; gap: var(--s3); padding: var(--s8) var(--s6); text-align: center; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); }
.maintenance-card .logo-img { height: 28px; }
.maintenance-card h1 { font-size: var(--fs-lg); margin-top: var(--s2); }
.maintenance-card p { color: var(--text-2); font-size: var(--fs-sm); }

/* ---------- vehicles (shared by home, discovery, saved) ---------- */
.lots, .vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(236px, 1fr)); gap: var(--s4); }
.vcard { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; min-width: 0; transition: border-color var(--ease), box-shadow var(--ease); }
.vcard:hover { border-color: var(--border-strong); box-shadow: var(--shadow-xs), 0 4px 12px -6px rgba(16, 24, 40, 0.12); }
.vcard.is-new { border-color: var(--teal); }
.v-photo { position: relative; display: block; width: 100%; aspect-ratio: 16 / 10; padding: 0; border: 0; background: var(--surface-3); cursor: pointer; overflow: hidden; }
.v-photo img { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; display: block; }
.v-photo .ph { position: absolute; inset: 0; display: grid; place-items: center; color: var(--faint); }
.v-photo .ph svg { width: 28px; height: 28px; }
.v-photo .v-new { position: absolute; z-index: 2; left: 8px; top: 8px; height: 20px; padding: 0 7px; border-radius: 5px; background: var(--teal); color: #fff; font: 600 11px/20px var(--font); }
.vcard .save-btn { position: absolute; z-index: 3; top: 8px; right: 8px; width: 30px; height: 30px; display: grid; place-items: center; padding: 0; border: 0; border-radius: var(--r-sm); background: rgba(255, 255, 255, 0.92); color: var(--text-2); box-shadow: var(--shadow-xs); transition: color var(--ease), background var(--ease); }
.vcard .save-btn:hover { color: var(--text); background: #fff; }
.vcard .save-btn svg { width: 16px; height: 16px; }
.vcard .save-btn[aria-pressed='true'] { background: var(--teal); color: #fff; }
.v-body { display: grid; gap: var(--s2); padding: var(--s3) var(--s3) var(--s3); flex: 1; align-content: start; }
.v-title { font-size: var(--fs); font-weight: 600; line-height: 1.35; color: var(--text); cursor: pointer; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.v-title:hover { color: var(--teal-text); }
.v-sub { display: flex; gap: var(--s2); align-items: center; font-size: var(--fs-xs); color: var(--muted); min-width: 0; }
.v-sub span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lotno { font-variant-numeric: tabular-nums slashed-zero; color: var(--text-2); }
.v-price { display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.v-price .price { font-size: 18px; font-weight: 600; color: var(--text); letter-spacing: -0.01em; }
.v-price .price-label { font-size: var(--fs-xs); color: var(--muted); }
.v-price .bid { margin-left: auto; font-size: var(--fs-xs); color: var(--text-2); font-variant-numeric: tabular-nums; }
.deal { display: flex; align-items: center; gap: 6px; font-size: var(--fs-xs); color: var(--text-2); font-variant-numeric: tabular-nums; }
.deal b { font-weight: 600; }
.deal.good b { color: var(--success); }
.deal.ok b { color: var(--warning); }
.deal.bad b { color: var(--danger); }
.deal .track { flex: 1; height: 4px; border-radius: 99px; background: var(--surface-3); overflow: hidden; min-width: 40px; }
.deal .track i { display: block; height: 100%; border-radius: inherit; background: var(--success); }
.deal.ok .track i { background: var(--warning); }
.deal.bad .track i { background: var(--danger-strong); }
.v-facts { display: grid; grid-template-columns: 1fr 1fr; gap: 4px var(--s3); margin: 0; padding-top: var(--s2); border-top: 1px solid var(--border); font-size: var(--fs-xs); }
.v-facts div { display: grid; min-width: 0; }
.v-facts dt { color: var(--muted); }
.v-facts dd { margin: 0; color: var(--text); font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-variant-numeric: tabular-nums; }
.v-flags { display: flex; flex-wrap: wrap; gap: 4px; }
.v-flags .pill { height: 20px; font-size: 11px; padding: 0 7px; }
.v-foot { display: flex; align-items: center; gap: var(--s2); padding: var(--s2) var(--s3); border-top: 1px solid var(--border); font-size: var(--fs-xs); color: var(--muted); }
.v-foot .found { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.v-foot .btn { margin-left: auto; }
.remind-tag { display: inline-flex; gap: 4px; align-items: center; color: var(--teal-text); font-size: var(--fs-xs); font-weight: 500; }
.remind-tag svg { width: 14px; height: 14px; }

/* ---------- searches (monitoring) ---------- */
.mon-name { display: grid; gap: 2px; min-width: 0; }
.mon-name b { font-weight: 500; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mon-name span { color: var(--muted); font-size: var(--fs-xs); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mon-state { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; font-size: var(--fs-sm); color: var(--text-2); }

/* ---------- phones and tablets ---------- */
.tabbar { display: none; }
@media (max-width: 1024px) {
  :root { --rail-w: 200px; }
  .global-search { flex-basis: 300px; }
  .monitor { display: none; }
}
@media (max-width: 860px) {
  .shell, body.rail-min .shell { grid-template-columns: minmax(0, 1fr); }
  .rail { display: none; }
  .topbar { padding: 0 var(--s4); gap: var(--s3); height: 52px; }
  .topbar-brand { display: block; }
  .crumbs { display: none; }
  .global-search { flex: 1; margin-left: 0; }
  .global-search .kbd { display: none; }
  .page-head { padding: var(--s5) var(--s4) var(--s4); }
  .page-head h1 { font-size: 21px; }
  html:lang(ka) .page-head h1 { font-size: 19px; }
  #notices { padding: 0 var(--s4); }
  .banner { margin: var(--s3) var(--s4) 0; }
  .page { padding: 0 var(--s4) calc(84px + env(safe-area-inset-bottom)); }
  .imp-banner { padding: 8px var(--s4); flex-wrap: wrap; }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr); align-items: center; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); background: var(--surface); border-top: 1px solid var(--border);
  }
  .tabbar a, .tabbar button { position: relative; display: grid; justify-items: center; gap: 2px; padding: 4px 0; border: 0; background: none; color: var(--muted); font: 500 10.5px/1.2 var(--font); text-decoration: none; min-height: 44px; align-content: center; }
  .tabbar a svg { width: 20px; height: 20px; }
  .tabbar a.active { color: var(--teal-text); }
  .tabbar a span:not(.count) { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 0 2px; }
  .tabbar .count { position: absolute; top: 0; left: 55%; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 99px; background: var(--danger-strong); color: #fff; font: 600 10px/16px var(--font); }
  .tabbar .count:empty { display: none; }
  .tabbar .new-btn .plus { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; background: var(--teal); color: #fff; }
  .tabbar .new-btn svg { width: 22px; height: 22px; }
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpi { border-bottom: 1px solid var(--border); }
  .kpi:nth-child(2n) { border-right: 0; }
  .kpi:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .lots, .vgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
  .toasts { left: var(--s4); right: var(--s4); bottom: calc(76px + env(safe-area-inset-bottom)); width: auto; }
  .drawer-panel, .drawer-panel.wide { width: 100vw; }
  dialog.sheet { width: calc(100vw - 16px); max-height: calc(100vh - 16px); }
  input, select, textarea { font-size: 16px !important; }
  .btn { height: 40px; }
  .btn.sm { height: 34px; }
  .btn.icon { width: 40px; }
  .pop { position: fixed; left: 8px; right: 8px; top: 58px; width: auto; }
}
@media (max-width: 430px) {
  .lots, .vgrid { gap: 10px; }
  .v-body { padding: 10px; gap: 6px; }
  .v-title { font-size: 13px; }
  .v-price .price { font-size: 16px; }
  .v-facts { grid-template-columns: 1fr; }
  .v-facts div:nth-child(n + 3) { display: none; }
  .v-foot .found { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
.rail-foot button span, .health-line span:last-child { overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 430px) {
  .vcard .v-sub span:not(.lotno) { display: none; }
  .vcard .v-sub .lotno { overflow: visible; }
  .vcard .deal { flex-wrap: nowrap; }
  .vcard .deal > span:not(.track) { display: none; }
}
