/* Временный кабинет. Цвета, скругления и типографика — из дизайн-прототипа сайта агентства. */
:root {
  --bg: #F5F6F4; --card: #FFFFFF; --ink: #111614; --muted: #56605C; --line: #E1E5E1; --line-strong: #C3CAC5;
  --accent: #0E5A4E; --accent-dark: #083B33; --soft: #E7EAE7; --photo: #D9DFDB;
  --ok: #0E5A4E; --ok-bg: #DCEBE6; --warn: #8A5A00; --warn-bg: #FBEFD5; --fail: #A12B1E; --fail-bg: #F8DEDA;
  --font: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --head: Manrope, Inter, system-ui, sans-serif;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--font); }
a { color: var(--accent); } a:hover { color: var(--accent-dark); }
h1, h2, h3 { font-family: var(--head); letter-spacing: -0.01em; margin: 0; }
h1 { font-size: clamp(26px, 3.4vw, 36px); line-height: 1.15; }
h2 { font-size: 20px; } h3 { font-size: 15px; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.header { background: var(--bg); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.header-in { max-width: 1200px; margin: 0 auto; padding: 8px 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 28px; }
.brand { display: flex; align-items: center; gap: 10px; min-height: 48px; font: 700 15px var(--head); letter-spacing: 0.14em; color: var(--ink); text-decoration: none; }
.brand-mark { width: 28px; height: 28px; border-radius: 8px; background: var(--accent); }
.nav { display: flex; flex-wrap: wrap; gap: 0 24px; flex: 1; }
.nav a { display: flex; align-items: center; min-height: 48px; font-weight: 500; text-decoration: none; color: var(--ink); box-shadow: inset 0 -2px 0 transparent; }
.nav a[aria-current="page"] { color: var(--accent); box-shadow: inset 0 -2px 0 var(--accent); }
.who { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 14px; }

main { max-width: 1200px; margin: 0 auto; padding: 32px 24px 80px; display: flex; flex-direction: column; gap: 24px; }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.between { justify-content: space-between; }
.muted { color: var(--muted); } .small { font-size: 13px; } .mono { font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; }
.card { background: var(--card); border-radius: 20px; padding: 24px; display: flex; flex-direction: column; gap: 14px; }
.stats { grid-template-columns: repeat(auto-fit, minmax(min(140px, 100%), 1fr)) !important; }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr)); }
.stat { background: var(--card); border-radius: 16px; padding: 18px 20px; }
.stat b { display: block; font: 700 26px var(--head); }
.stat span { color: var(--muted); font-size: 13px; }

.btn { min-height: 44px; padding: 0 18px; border-radius: 12px; border: 1px solid var(--ink); background: transparent; font-weight: 600; cursor: pointer; }
.btn:hover { background: var(--soft); }
.btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn.primary:hover { background: var(--accent-dark); }
.btn.danger { border-color: var(--fail); color: var(--fail); }
.btn.link { border: none; padding: 0; color: var(--accent); font-weight: 500; min-height: 32px; }
.btn:disabled { opacity: .5; cursor: default; }
.chip { min-height: 40px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--card); font-size: 14px; font-weight: 500; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.field input, .field select, .field textarea { min-height: 44px; padding: 8px 12px; border-radius: 10px; border: 1px solid var(--line-strong); background: var(--card); font-weight: 400; color: var(--ink); }
.field textarea { min-height: 120px; font-family: ui-monospace, Consolas, monospace; font-size: 13px; }

.pill { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--soft); white-space: nowrap; }
.pill.ok { background: var(--ok-bg); color: var(--ok); } .pill.warn { background: var(--warn-bg); color: var(--warn); } .pill.fail { background: var(--fail-bg); color: var(--fail); }

.layout { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 28px 36px; }
.filters { flex: 1 1 250px; display: flex; flex-direction: column; gap: 22px; }
.results { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.obj { position: relative; display: flex; flex-direction: column; gap: 12px; color: var(--ink); text-decoration: none; }
.obj:hover { color: var(--ink); }
.obj-photo { aspect-ratio: 4 / 3; border-radius: 16px; background: var(--photo) center / cover no-repeat; position: relative; display: flex; align-items: flex-end; padding: 12px; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: #46514D; overflow: hidden; }
.obj-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.obj-state { position: absolute; top: 12px; left: 12px; background: #fff; }
.obj-price { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.obj-price b { font: 700 21px var(--head); }
.obj-l1 { font-weight: 500; } .obj-l2 { color: var(--muted); font-size: 14px; }
.obj-flags { color: var(--warn); font-size: 13px; }

table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); }
td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: top; overflow-wrap: break-word; min-width: 84px; }
.scroll { overflow-x: auto; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; }
.gallery img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; background: var(--photo); }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 14px 24px; }
.facts div span { display: block; color: var(--muted); font-size: 12px; }
.pre { white-space: pre-wrap; overflow-wrap: anywhere; }
.bar { display: flex; height: 10px; border-radius: 999px; overflow: hidden; background: var(--soft); }
.bar i { display: block; height: 100%; }

.login { max-width: 380px; margin: 12vh auto 0; }
.notice { padding: 12px 16px; border-radius: 12px; background: var(--fail-bg); color: var(--fail); }
.notice.ok { background: var(--ok-bg); color: var(--ok); }
dialog { border: none; border-radius: 20px; padding: 28px; max-width: min(640px, 92vw); width: 100%; }
dialog::backdrop { background: rgba(17, 22, 20, .45); }
dialog pre { background: var(--bg); border-radius: 12px; padding: 14px; overflow: auto; max-height: 50vh; margin: 0; font-size: 12.5px; }
.hint { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.45; max-width: 760px; }
.kv { display: grid; grid-template-columns: minmax(110px, max-content) 1fr; gap: 4px 14px; margin: 0; font-size: 14px; }
.kv dt { color: var(--muted); } .kv dd { margin: 0; overflow-wrap: anywhere; }
.kv .kv { font-size: 13px; }
ul.plain { margin: 0; padding-left: 18px; }
.dlg, .form { display: flex; flex-direction: column; gap: 14px; }
.form h3 { margin-top: 4px; }
.setting { display: flex; flex-direction: column; gap: 6px; padding: 14px 0; border-top: 1px solid var(--line); }
.setting .field input, .setting .field textarea { max-width: 520px; width: 100%; }
.setting .field textarea, .dlg textarea { font-family: var(--font); font-size: 14px; min-height: 0; }
.pair { font-weight: 400; color: var(--ink); } .pair input { width: 130px !important; }
.help summary { cursor: pointer; font: 600 16px var(--head); }
.help ol { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; max-width: 760px; }
.fail-text { color: var(--fail); margin-top: 4px; }
.stat { text-decoration: none; color: var(--ink); } a.stat:hover { outline: 2px solid var(--accent); }
.notice .kv dt { color: inherit; opacity: .8; } .notice .hint { color: inherit; opacity: .8; margin-top: 6px; }
td .pill + .small { display: block; }
.fb { display: flex; flex-direction: column; gap: 8px; padding: 14px 0; border-top: 1px solid var(--line); }
.fb p { margin: 0; }
.proposal { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 12px 14px; border-radius: 12px; background: var(--bg); }
.proposal > div:first-child { flex: 1 1 320px; }
.dlg textarea, .form textarea { width: 100%; max-width: 760px; }
.form .field textarea, .form .field input { font-family: var(--font); font-size: 14px; }
@media (max-width: 640px) { main { padding: 20px 16px 64px; } .header-in { padding: 6px 16px; } .card { padding: 18px; } }
