/* Хранение. Тихий светлый интерфейс; яркое — только цвет комнаты, который работает как адрес.
   Шрифты: Jost — заголовки, Golos Text — текст (Google Fonts; без сети — системные). */
:root {
  --bg: #EEF1F4;
  --card: #FFFFFF;
  --ink: #1C2230;
  --ink-2: #566070;
  --ink-3: #8A93A0;
  --line: #DFE4EA;
  --soft: #E6EAEF;
  --danger: #C23A2B;
  --focus: #2F5BD6;
  --r: 16px;
  --f-d: 'Jost', 'Futura', sans-serif;
  --f-b: 'Golos Text', system-ui, sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body { font: 15px/1.45 var(--f-b); color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
#app { height: 100%; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 8px; }
.sr { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ic { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.ic.sm { width: 17px; height: 17px; }

/* ---------- оболочка ---------- */
/* приложение — колонка во всю высоту; на широком экране по центру */
.shell { height: 100vh; height: 100dvh; max-width: 600px; margin: 0 auto; display: flex; flex-direction: column; }
@media (min-width: 640px) { body { background: #DDE2E8; } .shell { background: var(--bg); box-shadow: 0 0 0 1px var(--line); } }
.bar { flex: none; display: flex; align-items: center; gap: 4px; min-height: 64px; padding: calc(10px + env(safe-area-inset-top)) 14px 4px 6px; }
.bar-t { flex: 1; min-width: 0; margin: 0; font: 600 25px/1.12 var(--f-d); letter-spacing: -.01em; color: color-mix(in srgb, var(--c, #1C2230) 72%, #000); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bar .t-in { height: 44px; font: 600 21px var(--f-d); color: var(--ink); -webkit-line-clamp: unset; }
.sub-a { color: inherit; }
.main { flex: 1; overflow-y: auto; padding: 4px 18px 28px; overscroll-behavior: contain; }
.main.top { padding-top: calc(22px + env(safe-area-inset-top)); }
.tabs { position: relative; z-index: 5; flex: none; display: grid; grid-template-columns: 1fr 1fr 1fr; background: var(--card); border-top: 1px solid var(--line); padding: 6px 6px calc(8px + env(safe-area-inset-bottom)); }
.tab { display: flex; flex-direction: column; align-items: center; gap: 2px; min-height: 52px; justify-content: center; font: 500 12px var(--f-b); color: var(--ink-3); text-decoration: none; }
.tab.on { color: var(--ink); font-weight: 600; }
.cam-c { width: 52px; height: 52px; margin-top: -22px; border-radius: 18px; display: grid; place-items: center; background: var(--ink); color: #fff; box-shadow: 0 8px 18px -8px rgba(28, 34, 48, .6); }
.tab.cam { color: var(--ink); }
.icon-btn { width: 44px; height: 44px; display: grid; place-items: center; border: 0; border-radius: 14px; background: transparent; color: var(--ink); cursor: pointer; text-decoration: none; flex: none; }
.icon-btn:hover { background: var(--soft); }

/* ---------- текст ---------- */
.t1 { font: 600 30px/1.08 var(--f-d); letter-spacing: -.015em; margin: 0; }
.t2 { font: 600 21px/1.15 var(--f-d); margin: 4px 0 8px; }
.sub { color: var(--ink-2); margin: 6px 0 14px; font-size: 14px; }
.hint { color: var(--ink-2); font-size: 13px; margin: 8px 0 0; }
.cap { font: 600 12px var(--f-b); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 8px; }
.muted { color: var(--ink-2); }
.small { font-size: 13px; }
p { margin: 0 0 8px; }
.desc { color: var(--ink-2); margin: 12px 0; }
.link { border: 0; background: none; padding: 0; color: var(--ink); text-decoration: underline; cursor: pointer; font-size: inherit; }
.link.block { display: block; margin: 16px auto 0; padding: 10px; }
.link.danger { color: var(--danger); display: inline-flex; gap: 6px; align-items: center; padding: 10px 0; text-decoration: none; }
.qty { font: 600 12px var(--f-b); color: var(--ink-2); background: var(--soft); padding: 2px 7px; border-radius: 6px; vertical-align: middle; letter-spacing: 0; }
.qty.big { font-size: 14px; }
.qty { white-space: nowrap; }

/* ---------- кнопки, чипы, поля ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 50px; padding: 0 20px; border: 0; border-radius: 14px; background: var(--ink); color: #fff; font: 600 15px var(--f-b); cursor: pointer; text-decoration: none; }
.btn.wide, .btn-g.wide { width: 100%; }
.btn.danger { background: var(--danger); }
.btn:disabled { opacity: .35; cursor: not-allowed; }
.btn-g { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--card); font-weight: 600; cursor: pointer; }
.btn-s { display: inline-flex; align-items: center; gap: 6px; min-height: 38px; padding: 0 13px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--card); color: var(--ink); font: 600 13.5px var(--f-b); cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn-s.dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.icon-sm { width: 36px; height: 36px; display: grid; place-items: center; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .7); color: var(--ink); cursor: pointer; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; margin: 10px -18px 4px; padding: 0 18px 4px; scrollbar-width: none; }
.chip { display: inline-flex; align-items: center; gap: 4px; min-height: 36px; padding: 0 13px; border: 1.5px solid var(--line); border-radius: 99px; background: var(--card); font: 500 14px var(--f-b); cursor: pointer; text-decoration: none; white-space: nowrap; }
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.search { display: flex; align-items: center; gap: 10px; height: 52px; padding: 0 16px; margin: 16px 0 6px; border-radius: 16px; background: var(--card); box-shadow: 0 1px 0 var(--line); color: var(--ink-3); }
.search:focus-within { box-shadow: 0 0 0 2px var(--ink); }
.search input { flex: 1; border: 0; outline: none; background: transparent; font-size: 16px; color: var(--ink); min-width: 0; }
.search.sm { height: 44px; margin: 0 0 8px; background: var(--bg); box-shadow: none; }
.form { margin: 6px 0; }
.fld { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.fld > span { font: 600 13px var(--f-b); color: var(--ink-2); }
.fld input, .fld textarea, .fld select { width: 100%; min-height: 48px; padding: 11px 13px; border: 1.5px solid var(--line); border-radius: 12px; background: var(--card); font-size: 16px; }
.fld input:focus, .fld textarea:focus { outline: none; border-color: var(--ink); }
.two { display: grid; grid-template-columns: 1fr 2fr; gap: 10px; }
.ai { font: 700 10px var(--f-b); letter-spacing: .04em; padding: 2px 6px; border-radius: 5px; background: #E7E9FB; color: #3540A8; vertical-align: 1px; }
.note { font-size: 13px; padding: 10px 12px; border-radius: 12px; background: #E7E9FB; color: #2E3790; margin: 0 0 12px; }
.col { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.row-acts { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* ---------- главная: дома и комнаты-контейнеры ---------- */
.hero-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.house { margin-top: 24px; }
.h-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.h-name { font: 600 20px var(--f-d); margin: 0; }
.h-s { font-size: 13px; color: var(--ink-3); }
.h-head.edit { align-items: center; }
.h-head.edit .h-name { flex: 1; min-width: 0; border: 1.5px dashed var(--ink-3); border-radius: 10px; padding: 6px 10px; background: var(--card); }
.bins { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
/* плитка комнаты: фото во всю ширину, под ним название с точкой цвета комнаты */
.bin { display: flex; flex-direction: column; gap: 2px; padding: 0 0 12px; border-radius: 18px; overflow: hidden; background: var(--card); text-decoration: none; color: var(--ink); }
.bin:hover { box-shadow: 0 0 0 2px var(--line); }
.bin-ph { display: block; height: 128px; margin-bottom: 8px; background: var(--soft); }
.bin.edit .bin-ph { height: 84px; }
.bin-n { display: flex; align-items: center; gap: 7px; padding: 0 12px; font: 600 17px/1.15 var(--f-d); }
.bin-s { padding: 0 12px 0 28px; font-size: 13px; color: var(--ink-2); }
.bin.add { min-height: 176px; align-items: center; justify-content: center; gap: 6px; padding: 0; border: 2px dashed #C3CAD3; background: transparent; color: var(--ink-2); font-weight: 600; cursor: pointer; }
.bin.edit { gap: 8px; }
.bin.edit .bin-name, .bin.edit .bin-tools { margin-left: 10px; margin-right: 10px; }
.bin-name { min-height: 40px; border: 1.5px dashed var(--ink-3); border-radius: 10px; padding: 6px 9px; background: #fff; font: 600 16px var(--f-d); }
.bin-tools { display: flex; gap: 6px; margin-top: auto; }
.bin-tools .icon-sm, .bin-tools .dot-btn { background: var(--soft); }
/* порядок комнат: плитку тянут за ручку */
.bin-drag { touch-action: none; cursor: grab; color: var(--ink-2); }
.bin.dragging { position: relative; z-index: 20; box-shadow: 0 18px 40px -12px rgba(20, 30, 50, .45), 0 0 0 2px var(--c); }
.bin.dragging .bin-drag { cursor: grabbing; }
.ic.inline { width: 15px; height: 15px; vertical-align: -3px; }
.dot-btn { width: 36px; height: 36px; display: grid; place-items: center; border: 0; border-radius: 10px; background: rgba(255, 255, 255, .7); cursor: pointer; }
.dot-btn i { width: 18px; height: 18px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 3px #fff, 0 0 0 4px var(--c); }
.add-form { justify-content: center; gap: 8px; padding: 12px; border: 2px dashed #C3CAD3; }
.add-form input { width: 100%; min-height: 42px; border: 1.5px solid var(--line); border-radius: 10px; padding: 6px 10px; font-size: 16px; }
.add-acts { display: flex; gap: 6px; flex-wrap: wrap; }
.add-acts .btn-s { min-height: 34px; padding: 0 10px; }
.house-add-btn { display: flex; align-items: center; justify-content: center; gap: 6px; width: 100%; min-height: 52px; margin-top: 22px; border: 0; border-radius: 16px; background: transparent; color: var(--ink-2); font-weight: 600; cursor: pointer; }
.house-add-btn:hover { background: var(--soft); }
.house-add { display: flex; gap: 8px; margin-top: 22px; }
.house-add input { flex: 1; min-width: 0; min-height: 44px; border: 1.5px solid var(--line); border-radius: 12px; padding: 6px 12px; font-size: 16px; }

/* ---------- адрес: дом › комната › место › полка ---------- */
.addr { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; margin: 0 0 10px; font-size: 13px; }
.addr .seg { padding: 4px 9px; border-radius: 8px; text-decoration: none; background: color-mix(in srgb, var(--c) 12%, #fff); color: color-mix(in srgb, var(--c) 62%, #000); font-weight: 500; }
.addr a.seg:hover { background: color-mix(in srgb, var(--c) 22%, #fff); }
.addr .seg.last { background: color-mix(in srgb, var(--c) 72%, #000); color: #fff; font-weight: 600; }
.addr .sep { color: var(--ink-3); }

/* ---------- списки ---------- */
.sec { margin-top: 24px; }
.spot-row, .item-row { display: flex; align-items: center; gap: 12px; padding: 10px; margin-bottom: 8px; border-radius: 16px; background: var(--card); text-decoration: none; }
.spot-row:hover, .item-row:hover { box-shadow: 0 0 0 2px color-mix(in srgb, var(--c) 45%, #fff); }
.spot-ph { width: 104px; height: 80px; flex: none; border-radius: 11px; overflow: hidden; background: var(--soft); }
.item-ph { width: 56px; height: 56px; flex: none; border-radius: 11px; overflow: hidden; background: var(--soft); }
.th { width: 100% !important; height: 100% !important; display: block; object-fit: cover; }
.ph-none { display: grid; place-items: center; color: var(--ink-3); background: var(--soft); }
.body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.body .t { font-weight: 600; }
.body .s { font-size: 13px; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.body .s2 { font-size: 12.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chev { color: var(--ink-3); width: 18px; height: 18px; }
.cdot { width: 9px; height: 9px; border-radius: 50%; background: var(--c); flex: none; display: inline-block; }
.empty { padding: 20px 16px; border-radius: 18px; border: 2px dashed #C9D0D8; text-align: center; margin: 12px 0; }
.empty p:first-child { font-weight: 600; }
.count { font-size: 13px; color: var(--ink-2); margin: 6px 0 10px; }
.grp { display: flex; align-items: center; gap: 8px; font: 600 15px var(--f-d); margin: 18px 0 8px; color: color-mix(in srgb, var(--c) 70%, #000); }
.grp-h { color: var(--ink-3); font-weight: 500; }
.ev { display: flex; flex-direction: column; padding: 10px 0; border-bottom: 1px solid var(--line); margin: 0; font-size: 14px; }
.ev small { color: var(--ink-3); font-size: 12px; }

/* ---------- фото ---------- */
.photo { margin: 0 0 6px; border-radius: 18px; overflow: hidden; background: #111722; --hl: #4F5BD5; }
.photo > svg { display: block; width: 100%; }
.photo figcaption { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; background: var(--card); font-size: 12.5px; color: var(--ink-2); }
.photo figcaption .link { color: var(--ink-2); }
.photo.big > svg { max-height: 300px; }
.photo.top { margin: 0 -18px 14px; border-radius: 0; }
.photo.top > svg { max-height: 260px; }
.photos.multi { display: grid; grid-auto-flow: column; grid-auto-columns: 86%; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -18px; padding: 0 18px; scrollbar-width: none; }
.photos.multi .photo { scroll-snap-align: center; }
.photo-empty { display: flex; align-items: center; gap: 14px; padding: 18px; border-radius: 18px; border: 2px dashed #C3CAD3; text-decoration: none; color: var(--ink); margin: 6px 0; }
.photo-empty .ic { width: 30px; height: 30px; }
.photo-empty span { display: flex; flex-direction: column; }
.photo-empty small { color: var(--ink-2); font-size: 13px; }
.hl-line { fill: none; stroke: var(--hl); stroke-linejoin: round; }
.hl-under { fill: none; stroke: #000; opacity: .3; stroke-linejoin: round; }
.pin-dot { fill: #fff; stroke: var(--hl); }
.pin-ring { fill: none; stroke: #fff; transform-box: fill-box; transform-origin: center; animation: ring 1.6s ease-out infinite; }
@keyframes ring { from { transform: scale(.45); opacity: 1; } to { transform: scale(1); opacity: 0; } }
.rg-poly { fill: color-mix(in srgb, var(--hl) 10%, transparent); stroke: var(--hl); }
.rg:hover .rg-poly, .rg:focus-visible .rg-poly { fill: color-mix(in srgb, var(--hl) 32%, transparent); }
.rg:focus { outline: none; }
.rg-tag rect { fill: rgba(15, 20, 30, .78); }
.rg-tag text { fill: #fff; font-family: var(--f-b); font-weight: 600; }
.ai-q { fill: color-mix(in srgb, var(--hl) 16%, transparent); stroke: #fff; }
.ai-n { fill: #fff; }
.ai-t { fill: #1C2230; font-family: var(--f-d); font-weight: 700; }
.dr { fill: rgba(255, 255, 255, .25); stroke: #fff; stroke-dasharray: 10 6; }
.where { margin: 6px 0 4px; }
.steps { display: flex; align-items: center; gap: 4px; margin-top: 8px; }
.step { flex: 1 1 0; min-width: 0; aspect-ratio: 4 / 3; padding: 0; border: 2px solid transparent; border-radius: 12px; overflow: hidden; background: #111722; cursor: pointer; opacity: .65; }
.step.on { border-color: var(--c); opacity: 1; }
.arr { color: var(--ink-3); }

/* ---------- снять ---------- */
.shoot { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; min-height: 180px; margin: 16px 0; border-radius: 22px; background: var(--ink); color: #fff; cursor: pointer; text-align: center; }
.shoot .ic { width: 38px; height: 38px; margin-bottom: 4px; }
.shoot small { opacity: .7; }
.shoot.sm { min-height: 120px; }
.shoot:focus-within { outline: 3px solid var(--focus); outline-offset: 3px; }
.think { padding-top: 10px; }
.think .photo { position: relative; }
.scan { position: absolute; left: 0; right: 0; top: -30%; height: 30%; background: linear-gradient(transparent, rgba(255, 255, 255, .45), transparent); animation: scan 1.2s linear infinite; }
@keyframes scan { to { top: 100%; } }
.think-t { font: 600 18px var(--f-d); text-align: center; margin-top: 12px; }
.seg3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; padding: 4px; margin-bottom: 14px; border-radius: 14px; background: var(--soft); }
.seg3 button { min-height: 42px; border: 0; border-radius: 10px; background: transparent; font: 600 13px/1.15 var(--f-b); color: var(--ink-2); cursor: pointer; padding: 4px; }
.seg3 button.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 3px rgba(0, 0, 0, .1); }
.where-field { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 66px; padding: 8px 10px; border: 1.5px solid var(--line); border-left: 6px solid var(--c); border-radius: 14px; background: var(--card); text-align: left; cursor: pointer; }
.wf-ph { width: 56px; height: 46px; border-radius: 9px; overflow: hidden; flex: none; }
.pin-ph svg { touch-action: none; }
.checks { list-style: none; padding: 0; margin: 0 0 14px; border-radius: 14px; background: var(--card); overflow: hidden; }
.checks label { display: flex; gap: 12px; align-items: center; padding: 12px; border-bottom: 1px solid var(--line); cursor: pointer; }
.checks li:last-child label { border-bottom: 0; }
.checks input { width: 20px; height: 20px; accent-color: var(--ink); flex: none; }
.checks span { display: flex; flex-direction: column; font-weight: 600; }
.checks small { font-weight: 400; color: var(--ink-2); font-size: 12.5px; }

/* ---------- листы ---------- */
.sheet-wrap { position: fixed; inset: 0; z-index: 50; }
.sheet-bg { position: absolute; inset: 0; background: rgba(20, 26, 38, .45); opacity: 0; transition: opacity .2s; }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; max-width: 600px; margin: 0 auto; max-height: 90%; overflow: auto; padding: 22px 18px calc(18px + env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; background: var(--bg); transform: translateY(100%); transition: transform .24s cubic-bezier(.2, .8, .2, 1); }
.sheet-wrap.in .sheet-bg { opacity: 1; }
.sheet-wrap.in .sheet { transform: none; }
.sheet-x { position: absolute; top: 10px; right: 10px; }
.sheet-t { font: 600 20px/1.2 var(--f-d); margin: 2px 44px 14px 0; }
.sheet-foot { position: sticky; bottom: calc(-18px - env(safe-area-inset-bottom)); display: flex; flex-direction: column; gap: 8px; padding: 12px 0 18px; background: var(--bg); }
.opts { display: flex; flex-direction: column; gap: 6px; }
.opt { min-height: 50px; padding: 0 16px; border: 0; border-radius: 14px; background: var(--card); text-align: left; font-weight: 600; cursor: pointer; }
.opt.on { background: var(--ink); color: #fff; }
.tree { min-height: 120px; }
.tn-house { font: 600 15px var(--f-d); margin: 14px 0 6px; }
.tn-list, .tn ul { list-style: none; margin: 0; padding: 0; }
.tn-row { display: flex; align-items: center; gap: 2px; padding-left: calc(var(--d) * 18px); border-radius: 12px; }
.tn-row.sel { background: color-mix(in srgb, var(--c) 18%, #fff); box-shadow: inset 0 0 0 2px var(--c); }
.tn-tog { width: 34px; height: 44px; display: grid; place-items: center; border: 0; background: none; color: var(--ink-3); cursor: pointer; flex: none; }
.tn-name { flex: 1; display: flex; align-items: center; gap: 8px; min-height: 44px; border: 0; background: none; text-align: left; font-weight: 500; cursor: pointer; padding: 0 8px 0 0; }
.tn-name small { margin-left: auto; color: var(--ink-3); font-size: 12px; }
.tn-row.sel .tn-name { font-weight: 600; }

/* ---------- тост ---------- */
.toast { position: fixed; left: 14px; right: 14px; max-width: 572px; margin: 0 auto; bottom: calc(90px + env(safe-area-inset-bottom)); z-index: 70; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: 16px; background: var(--ink); color: #fff; font-size: 14px; opacity: 0; transform: translateY(14px); pointer-events: none; transition: opacity .2s, transform .2s; }
.toast.in { opacity: 1; transform: none; pointer-events: auto; }
.toast span { flex: 1; }
.toast button { border: 0; border-radius: 10px; padding: 8px 11px; background: #fff; color: var(--ink); font: 600 13px var(--f-b); cursor: pointer; }

.no-ph { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; width: 100%; height: 100%; color: var(--ink-3); background: var(--soft); }
.no-ph small { font-size: 12px; font-weight: 500; }
.search-btn { display: flex; align-items: center; gap: 10px; width: 100%; height: 52px; padding: 0 16px; margin: 16px 0 4px; border: 0; border-radius: 16px; background: var(--card); color: var(--ink-3); font-size: 16px; text-align: left; cursor: pointer; box-shadow: 0 1px 0 var(--line); }
.search-btn:hover { box-shadow: 0 0 0 2px var(--line); }
.place-card { display: block; margin-bottom: 12px; border-radius: 20px; overflow: hidden; background: var(--card); text-decoration: none; }
.place-card:hover { box-shadow: 0 0 0 2px color-mix(in srgb, var(--c) 40%, #fff); }
.pc-ph { display: block; height: 176px; }
.pc-b { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px 13px; }
.pc-b .t { font: 600 18px/1.2 var(--f-d); }
.pc-b .s { font-size: 13px; color: var(--ink-2); }
.pc-b .s2 { font-size: 12.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-in { flex: 1; min-width: 0; padding: 4px 10px; border: 1.5px dashed var(--ink-3); border-radius: 12px; background: var(--card); color: var(--ink); }
.t-in:focus { outline: none; border-style: solid; border-color: var(--ink); }
.edit-bar { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 14px; }
.btn-s.danger { color: var(--danger); }
.dot-btn.wide { width: auto; display: inline-flex; gap: 10px; padding: 0 13px 0 11px; min-height: 38px; border: 1.5px solid var(--line); background: var(--card); font: 600 13.5px var(--f-b); }
.dot-btn.wide i { width: 14px; height: 14px; }
.acts2 { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 16px 0; }
.acts2 .btn, .acts2 .btn-g { min-height: 50px; }
.add-item { margin-top: 22px; }
.spot-row .s2 { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---------- разметка на фото ---------- */
.ed-fig { box-shadow: 0 0 0 2px var(--ink); }
.ed-svg { touch-action: none; user-select: none; -webkit-user-select: none; }
.ed-q { fill: color-mix(in srgb, var(--hl) 12%, transparent); stroke: #fff; cursor: pointer; }
.ed-q.sel { fill: color-mix(in srgb, var(--hl) 30%, transparent); stroke: var(--hl); }
.ed-p { fill: #fff; stroke: var(--hl); cursor: grab; }
.ed-p.sel { fill: var(--hl); stroke: #fff; }
.ed-h { fill: #fff; stroke: var(--ink); cursor: grab; }
.ed-svg.drawing { cursor: crosshair; }
.ed-svg.drawing .ed-q, .ed-svg.drawing .ed-p { pointer-events: none; }
.ed-cap span { flex: 1; min-width: 0; }
.ed-cap b { color: var(--ink); }
.mark-h { margin-top: 18px; }
.more { margin-top: 16px; }
.more summary { cursor: pointer; font-weight: 600; color: var(--ink-2); padding: 10px 0; }
.more .opts { margin-top: 8px; }

/* ---------- выбор цвета комнаты ---------- */
.cs-top { display: flex; gap: 14px; align-items: center; margin-bottom: 18px; }
.cs-prev { width: 150px; flex: none; }
.bin.preview { pointer-events: none; transition: background .2s, border-color .2s; }
.bin.preview { box-shadow: 0 0 0 1px var(--line); }
.bin.preview .bin-ph { height: 92px; }
.bin.preview .cdot { width: 12px; height: 12px; }
.swatches { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px 10px; margin-bottom: 6px; }
.sw { position: relative; aspect-ratio: 1; border: 0; border-radius: 50%; background: var(--s); color: #fff; display: grid; place-items: center; cursor: pointer;
  box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .16), inset 0 2px 0 rgba(255, 255, 255, .25); transition: transform .12s; }
.sw:hover { transform: scale(1.07); }
.sw.on { box-shadow: 0 0 0 3px var(--bg), 0 0 0 5px var(--s), inset 0 -3px 0 rgba(0, 0, 0, .16); }
.sw .ic { stroke-width: 2.6; }
.sw-taken { position: absolute; bottom: -8px; left: 50%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--ink-3); }
.cs-h { margin-top: 18px; }
.hue { position: relative; height: 36px; margin: 4px 0 20px; border-radius: 99px; cursor: pointer; touch-action: none;
  background: linear-gradient(to right, hsl(0 58% 48%), hsl(30 58% 48%), hsl(60 58% 48%), hsl(90 58% 48%), hsl(120 58% 48%), hsl(150 58% 48%), hsl(180 58% 48%), hsl(210 58% 48%), hsl(240 58% 48%), hsl(270 58% 48%), hsl(300 58% 48%), hsl(330 58% 48%), hsl(360 58% 48%));
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .08); }
.hue-thumb { position: absolute; top: 50%; left: var(--x, 0%); width: 30px; height: 30px; border-radius: 50%; background: var(--t); transform: translate(-50%, -50%) scale(.82);
  border: 4px solid #fff; box-shadow: 0 2px 8px rgba(0, 0, 0, .3); transition: transform .12s; }
.hue.on .hue-thumb { transform: translate(-50%, -50%) scale(1.05); }
.hue:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

/* ---------- вход ---------- */
.boot { display: grid; place-items: center; min-height: 100vh; min-height: 100dvh; padding: 24px; text-align: center; color: var(--ink-2); }
.login { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px 18px calc(24px + env(safe-area-inset-bottom)); }
.lg-card { width: 100%; max-width: 380px; }
.lg-card .sub { margin-bottom: 22px; }
/* знак: три плитки комнат — цвет как адрес */
.lg-mark { display: flex; gap: 6px; margin-bottom: 18px; }
.lg-mark i { width: 34px; height: 26px; border-radius: 8px; background: var(--c); }
.lg-mark i:nth-child(2) { width: 22px; }
.lg-mark i:nth-child(3) { width: 14px; }
.lg-err { min-height: 20px; margin: 0 0 8px; color: var(--danger); font-size: 14px; }

/* ---------- шапка, связь, аккаунт, участники ---------- */
.hero-acts { display: flex; align-items: center; gap: 4px; }
.hero-acts .icon-btn { margin-right: -8px; }
.netbar { display: flex; align-items: center; gap: 8px; margin: 10px 0 0; padding: 10px 12px; border-radius: 12px; background: #FFF1D6; color: #6B4A00; font-size: 13px; }
.note { display: flex; gap: 8px; align-items: flex-start; }
.note.warn { background: #FFF1D6; color: #6B4A00; }
.think-ph { aspect-ratio: 4 / 3; }
.empty.first { text-align: left; border-style: solid; border-color: var(--line); background: var(--card); margin-top: 22px; }
.empty .house-add { margin-top: 14px; }
.acc-login { display: flex; align-items: center; gap: 8px; font-size: 17px; margin: 0 0 12px; }
.people { list-style: none; margin: 12px 0 18px; padding: 0; border-radius: 14px; background: var(--card); overflow: hidden; }
.person { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 54px; padding: 6px 8px 6px 14px; border-bottom: 1px solid var(--line); }
.person:last-child { border-bottom: 0; }
.person > span { display: flex; align-items: center; gap: 8px; font-weight: 600; }
.person small { font-weight: 400; color: var(--ink-3); }
.h-head .link { color: var(--ink-3); }
.h-head.edit .icon-sm { background: var(--soft); }
.btn-g { text-decoration: none; color: var(--ink); }

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