/* Shared styles for the listing page and the admin page */
:root {
  --bg: #f6f7f5;
  --surface: #ffffff;
  --fg: #1d2421;
  --muted: #5d6a64;
  --line: #dde2de;
  --accent: #1f6b5c;
  --accent-ink: #ffffff;
  --accent-soft: #e2efeb;
  --danger: #b3261e;
  --display: "Instrument Serif", Georgia, "Times New Roman", serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #121715; --surface: #1a201e; --fg: #e8ece9; --muted: #9aa8a1; --line: #2d3532;
    --accent: #5cbfa8; --accent-ink: #0b1411; --accent-soft: #1d2f2a; --danger: #ef7b72;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--body); font-size: 16px; line-height: 1.55; }
img { max-width: 100%; }
[hidden] { display: none !important; }
.wrap { max-width: 1120px; margin: 0 auto; padding-block: 32px 72px;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  display: grid; gap: 32px; }

.eyebrow { font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
h1 { font-family: var(--display); font-weight: 400; font-size: clamp(38px, 7vw, 64px); line-height: 1; margin: 0; text-wrap: balance; }
h2 { font-family: var(--display); font-weight: 400; font-size: 30px; line-height: 1.1; margin: 0; }
.city { color: var(--muted); font-size: 18px; }
.muted { color: var(--muted); }

.specs { display: flex; flex-wrap: wrap; gap: 8px 24px; align-items: baseline; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding-block: 14px; }
.price { font-family: var(--display); font-size: 34px; line-height: 1; }
.spec { font-variant-numeric: tabular-nums; }
.spec b { font-weight: 600; }
.spec span { color: var(--muted); }

button, .btn { font: inherit; cursor: pointer; }
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--surface); color: var(--fg); border-radius: 8px; padding: 9px 15px; font-weight: 500; text-decoration: none; }
.btn:hover { border-color: var(--accent); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn.danger { color: var(--danger); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

label { display: grid; gap: 4px; font-size: 12px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); min-width: 0; }
input, textarea { font: inherit; font-size: 16px; letter-spacing: 0; text-transform: none; color: var(--fg); background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; width: 100%; }
textarea { min-height: 140px; resize: vertical; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px; display: grid; gap: 14px; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }

.ph { position: relative; display: block; width: 100%; max-width: 100%; aspect-ratio: 4 / 3; border-radius: 10px; overflow: hidden; background: var(--line); border: 0; padding: 0; }
.ph img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s; }
.ph:hover img { transform: scale(1.025); }
.num { position: absolute; right: 10px; bottom: 10px; background: rgba(0,0,0,.55); color: #fff; font-size: 12px; padding: 2px 7px; border-radius: 6px; font-variant-numeric: tabular-nums; }
.badge { position: absolute; left: 10px; top: 10px; background: var(--surface); color: var(--fg); font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; padding: 4px 8px; border-radius: 6px; }

.status { font-size: 14px; color: var(--muted); min-height: 1.5em; }
.status.err { color: var(--danger); }
.empty { border: 1px solid var(--line); border-radius: 12px; padding: 44px 20px; text-align: center; color: var(--muted); background: var(--surface); }
footer { font-size: 13px; color: var(--muted); }
@media (prefers-reduced-motion: reduce) { .ph img { transition: none; } }
