:root {
  --bg: #eef2f6;
  --bg-2: #ffffff;
  --bg-3: #e4ebf2;
  --card: #ffffff;
  --line: #d3dde6;
  --text: #152033;
  --muted: #5a6a7c;
  --gold: #1f4e79;
  --gold-2: #163a5c;
  --orange: #2b6ea3;
  --ok: #1a7f4b;
  --shadow: 0 10px 28px rgba(21, 32, 51, .08);
  --radius: 16px;
  --max: 1240px;
  --font: "Manrope", system-ui, sans-serif;
  --display: "Unbounded", "Manrope", sans-serif;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { background: var(--bg); color: var(--text); font-family: var(--font); }
html { scroll-behavior: smooth; }
body { min-height: 100vh; display: flex; flex-direction: column; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
a.prose-link, .prose a { color: var(--gold-2); text-decoration: underline; text-underline-offset: 3px; }
button, input, select, textarea { font: inherit; color: inherit; }
.wrap { width: min(var(--max), calc(100% - 32px)); margin: 0 auto; }
main { flex: 1; }

.topbar {
  position: sticky; top: 0; z-index: 40;
  background: rgba(255,255,255,.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.topbar-in {
  display: flex; align-items: center; gap: 18px;
  min-height: 72px;
}
.logo {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--display); font-weight: 700; letter-spacing: -.03em;
  font-size: 15px; white-space: nowrap;
}
.logo-mark {
  width: 36px; height: 36px; border-radius: 10px;
  background: var(--gold);
  display: grid; place-items: center; color: #fff; font-weight: 800;
}
.nav { display: flex; gap: 4px; margin-left: 12px; flex-wrap: wrap; }
.nav a {
  padding: 8px 12px; border-radius: 999px; color: var(--muted); font-size: 14px;
}
.nav a:hover, .nav a.active { color: var(--text); background: var(--bg-3); }
.top-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.pill {
  border: 1px solid var(--line); background: var(--bg-2);
  padding: 9px 14px; border-radius: 999px; font-size: 13px; color: var(--text);
}
.btn {
  border: 0; cursor: pointer; border-radius: 999px;
  padding: 11px 16px; font-weight: 700; display: inline-flex; align-items: center; gap: 8px;
}
.btn-gold { background: var(--gold); color: #fff; }
.btn-ghost { background: #fff; border: 1px solid var(--line); color: var(--text); }
.btn:hover { filter: brightness(1.05); }

.hero {
  position: relative; overflow: hidden;
  padding: 48px 0 20px;
}
.hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 28px; align-items: center; position: relative; }
h1 {
  font-family: var(--display); font-size: clamp(30px, 4.6vw, 48px);
  line-height: 1.08; letter-spacing: -.04em; max-width: 16ch;
}
.lead { color: var(--muted); font-size: 17px; margin-top: 16px; max-width: 52ch; line-height: 1.55; }
.stats { display: flex; gap: 12px; margin-top: 28px; flex-wrap: wrap; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; min-width: 120px; box-shadow: var(--shadow); }
.stat b { display: block; font-size: 22px; font-family: var(--display); }
.stat span { color: var(--muted); font-size: 12px; }
.hero-card {
  background: var(--card);
  border: 1px solid var(--line); border-radius: 24px; padding: 22px; box-shadow: var(--shadow);
}
.hero-card h3 { font-size: 16px; margin-bottom: 12px; }
.check { list-style: none; display: grid; gap: 9px; color: var(--muted); font-size: 14px; }
.check li { display: flex; gap: 8px; align-items: flex-start; }
.check i { color: var(--ok); font-style: normal; }

.section { padding: 18px 0 48px; }
.section h2 {
  font-family: var(--display); font-size: 28px; letter-spacing: -.03em; margin-bottom: 8px;
}
.sub { color: var(--muted); margin-bottom: 20px; }

.filters {
  position: sticky; top: 72px; z-index: 20;
  background: rgba(243,245,248,.94); backdrop-filter: blur(12px);
  border: 1px solid var(--line); border-radius: 18px; padding: 14px;
  display: grid; grid-template-columns: 1.4fr repeat(4, .75fr) auto; gap: 8px;
  margin-bottom: 18px;
}
.filters input, .filters select, .hero-card input, .hero-card textarea {
  background: #fff; border: 1px solid var(--line); border-radius: 12px;
  padding: 11px 12px; outline: none; width: 100%;
}
.filters input:focus, .filters select:focus, .hero-card input:focus, .hero-card textarea:focus { border-color: var(--gold); }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 16px; }
.chip {
  border: 1px solid var(--line); background: #fff; color: var(--muted);
  border-radius: 999px; padding: 7px 12px; cursor: pointer; font-size: 13px;
}
.chip.on, .chip:hover { color: #fff; background: var(--gold); border-color: var(--gold); }

.toolbar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; gap: 12px; }
.toolbar p { color: var(--muted); font-size: 14px; }

.grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
}
.card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column; min-height: 100%;
  box-shadow: var(--shadow);
  transition: transform .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-3px); border-color: #c9d3e0; }
.photo {
  aspect-ratio: 4/3; background: #e8edf3; position: relative; overflow: hidden;
}
.photo img { width: 100%; height: 100%; object-fit: cover; }
.badges { position: absolute; left: 10px; top: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.badge {
  font-size: 11px; font-weight: 700; padding: 5px 8px; border-radius: 999px;
  background: rgba(255,255,255,.92); color: var(--text);
}
.badge.ok { color: var(--ok); }
.badge.gold { color: var(--gold-2); }
.card-body { padding: 14px 14px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.brand { color: var(--gold-2); font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.card h3 { font-size: 16px; line-height: 1.3; }
.meta { color: var(--muted); font-size: 13px; }
.price-row { margin-top: auto; display: flex; justify-content: space-between; align-items: end; gap: 8px; }
.price { font-family: var(--display); font-size: 22px; }
.price small { font-size: 12px; color: var(--muted); font-family: var(--font); }

.empty { text-align: center; padding: 60px 16px; color: var(--muted); }

.modal {
  position: fixed; inset: 0; z-index: 80; display: none;
  background: rgba(27,36,48,.45); padding: 24px 16px; overflow: auto;
}
.modal.open { display: block; }
.modal-card {
  width: min(1080px, 100%); margin: 20px auto; background: #fff;
  border: 1px solid var(--line); border-radius: 24px; overflow: hidden;
}
.modal-grid { display: grid; grid-template-columns: 1.1fr .9fr; }
.gallery { background: #eef1f5; }
.gallery-main { aspect-ratio: 4/3; }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.thumbs { display: flex; gap: 8px; padding: 10px; overflow: auto; }
.thumbs img { width: 72px; height: 54px; object-fit: cover; border-radius: 8px; opacity: .7; cursor: pointer; border: 2px solid transparent; }
.thumbs img.on { opacity: 1; border-color: var(--gold); }
.modal-info { padding: 22px; }
.modal-info h2 { font-size: 26px; margin: 6px 0 10px; }
.close {
  float: right; border: 0; background: var(--bg-3); color: var(--text);
  width: 36px; height: 36px; border-radius: 50%; cursor: pointer;
}
.spec { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 14px; }
.spec td { padding: 8px 0; border-bottom: 1px solid var(--line); }
.spec td:first-child { color: var(--muted); width: 42%; }
.modal-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; }

.features { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.feat { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; box-shadow: var(--shadow); }
.feat b { display: block; margin-bottom: 6px; }

.page { padding: 28px 0 60px; }
.prose { color: #3a4656; line-height: 1.7; max-width: 75ch; }
.prose h3 { color: var(--text); margin: 22px 0 8px; }
.prose ul { padding-left: 18px; }

.footer {
  border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 13px; background: #fff;
}
.footer-in { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }

.toast {
  position: fixed; right: 16px; bottom: 16px; z-index: 90;
  background: #e8f6ee; color: #145c38; border: 1px solid #b7e0c8;
  padding: 12px 14px; border-radius: 12px; display: none;
}

@media (max-width: 980px) {
  .hero-grid, .modal-grid, .grid, .features { grid-template-columns: 1fr 1fr; }
  .filters { grid-template-columns: 1fr 1fr; position: static; }
  .nav { display: none; }
}
@media (max-width: 640px) {
  .grid, .features, .hero-grid, .modal-grid { grid-template-columns: 1fr; }
  .filters { grid-template-columns: 1fr; }
  h1 { max-width: none; }
}

.menu-btn {
  display: none;
  width: 42px; height: 42px; border: 1px solid var(--line); background: #fff;
  border-radius: 12px; cursor: pointer; margin-left: auto; flex-shrink: 0;
  align-items: center; justify-content: center;
}
.menu-btn span, .menu-btn span:before, .menu-btn span:after {
  display: block; width: 18px; height: 2px; background: var(--text); position: relative;
}
.menu-btn span:before, .menu-btn span:after {
  content: ""; position: absolute; left: 0;
}
.menu-btn span:before { top: -6px; }
.menu-btn span:after { top: 6px; }
.more-wrap { display: flex; justify-content: center; margin: 22px 0 8px; }
.mob-bar {
  display: none;
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 50;
  background: #fff; border-top: 1px solid var(--line);
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  gap: 8px;
}
.mob-bar a { flex: 1; justify-content: center; text-align: center; }
.price-row .btn { white-space: nowrap; }
@media (max-width: 980px) {
  .topbar-in { flex-wrap: wrap; min-height: 60px; gap: 8px; }
  .top-actions .pill, .top-actions .btn-ghost { display: none; }
  .menu-btn { display: flex; }
  .nav {
    display: none;
    width: 100%;
    order: 5;
    flex-direction: column;
    margin: 0;
    padding-bottom: 10px;
  }
  body.menu-open .nav { display: flex; }
  body.menu-open .nav a { background: var(--bg-3); }
  .mob-bar { display: flex; }
  main, .page { padding-bottom: 72px; }
}
