/* Zakir Import — деловой каталог. Тёплая палитра, латунный акцент, антиква Fraunces + Manrope. */

:root {
  --paper:      #f7f4ee;
  --surface:    #fffefb;
  --surface-2:  #f0ebe1;
  --ink:        #1b1917;
  --ink-soft:   #5f574d;
  --ink-faint:  #8b8171;
  --line:       #e3dccd;
  --brass:      #9a7742;
  --brass-deep: #7d5f33;
  --forest:     #2f4739;
  --ok:         #3f7d5c;
  --danger:     #a23b2e;

  --wa: #1e7d47;
  --tg: #2f7fb0;

  --shadow-lg: 0 2px 6px rgba(27, 25, 23, .05), 0 24px 60px rgba(27, 25, 23, .12);
  --shadow-sm: 0 1px 2px rgba(27, 25, 23, .06), 0 8px 24px rgba(27, 25, 23, .06);

  --serif: "Fraunces", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --sans:  "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --page: 1220px;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper:      #15120e;
    --surface:    #1c1914;
    --surface-2:  #24201a;
    --ink:        #efe9dd;
    --ink-soft:   #a99e8c;
    --ink-faint:  #7d7566;
    --line:       #322c22;
    --brass:      #c6a15f;
    --brass-deep: #d9ba7c;
    --forest:     #7fa892;
    --ok:         #63b98c;
    --danger:     #d97a6b;
    --wa: #43b072;
    --tg: #58a6d4;
    --shadow-lg: 0 2px 6px rgba(0,0,0,.4), 0 24px 60px rgba(0,0,0,.5);
    --shadow-sm: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
  }
}
:root[data-theme="dark"] {
  --paper:      #15120e;
  --surface:    #1c1914;
  --surface-2:  #24201a;
  --ink:        #efe9dd;
  --ink-soft:   #a99e8c;
  --ink-faint:  #7d7566;
  --line:       #322c22;
  --brass:      #c6a15f;
  --brass-deep: #d9ba7c;
  --forest:     #7fa892;
  --ok:         #63b98c;
  --danger:     #d97a6b;
  --wa: #43b072;
  --tg: #58a6d4;
  --shadow-lg: 0 2px 6px rgba(0,0,0,.4), 0 24px 60px rgba(0,0,0,.5);
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4), 0 8px 24px rgba(0,0,0,.35);
}

* { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: none; }
input, textarea, select { font: inherit; color: inherit; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--brass); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

.wrap { max-width: var(--page); margin: 0 auto; padding: 0 28px; }
@media (max-width: 640px) { .wrap { padding: 0 18px; } }

.eyebrow {
  font-size: 11.5px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase;
  color: var(--brass-deep);
}
.serif { font-family: var(--serif); font-weight: 400; letter-spacing: -.005em; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  height: 68px;
}
.wordmark { font-family: var(--serif); font-size: 22px; font-weight: 500; letter-spacing: .01em; display: flex; align-items: baseline; gap: 9px; }
.wordmark .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--brass); display: inline-block; transform: translateY(-3px); }
.nav { display: flex; gap: 26px; }
.nav a { font-size: 12px; font-weight: 600; letter-spacing: .13em; text-transform: uppercase; color: var(--ink-soft); padding: 6px 0; border-bottom: 1px solid transparent; transition: color .15s, border-color .15s; }
.nav a:hover { color: var(--ink); border-color: var(--brass); }
@media (max-width: 860px) { .nav { display: none; } }

/* ---------- intro band ---------- */
.intro { border-bottom: 1px solid var(--line); background: linear-gradient(180deg, var(--surface), var(--paper)); }
.intro .wrap { padding-top: 54px; padding-bottom: 46px; max-width: 940px; }
.intro h1 {
  font-family: var(--serif); font-weight: 400; letter-spacing: -.015em;
  font-size: clamp(30px, 5vw, 46px); line-height: 1.12; text-wrap: balance; margin: 14px 0 0;
}
.intro p { margin-top: 16px; color: var(--ink-soft); font-size: 16px; max-width: 60ch; }
.intro .rule { width: 54px; height: 2px; background: var(--brass); margin-top: 26px; }
.intro .quick { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }

/* ---------- toolbar (search + filters) ---------- */
.toolbar { position: sticky; top: 68px; z-index: 30; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.toolbar .wrap { display: flex; align-items: center; gap: 16px; height: 58px; }
.search { position: relative; flex: 1; max-width: 380px; }
.search input {
  width: 100%; height: 38px; padding: 0 14px 0 36px; border: 1px solid var(--line);
  border-radius: 2px; background: var(--surface); font-size: 14px; letter-spacing: .01em;
}
.search input::placeholder { color: var(--ink-faint); }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--ink-faint); }
.toggles { display: flex; gap: 18px; margin-left: auto; }
.toggle { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-soft); white-space: nowrap; }
.toggle input { accent-color: var(--brass); width: 15px; height: 15px; }
@media (max-width: 640px) { .toolbar .wrap { height: auto; padding-top: 12px; padding-bottom: 12px; flex-wrap: wrap; } .search { max-width: none; } .toggles { margin-left: 0; } }

/* ---------- categories ---------- */
.cats { border-bottom: 1px solid var(--line); background: var(--surface); }
.cats .wrap { display: flex; gap: 4px; overflow-x: auto; padding-top: 10px; padding-bottom: 10px; scrollbar-width: thin; }
.cat {
  white-space: nowrap; font-size: 12.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink-soft); padding: 7px 14px; border: 1px solid transparent; border-radius: 2px; transition: all .14s;
}
.cat:hover { color: var(--ink); }
.cat.on { color: var(--ink); border-color: var(--line); background: var(--paper); }
.cat .n { color: var(--ink-faint); font-weight: 500; margin-left: 6px; }

/* ---------- product grid ---------- */
main { padding: 40px 0 20px; }
.meta-row { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 22px; }
.meta-row .n { font-size: 13px; color: var(--ink-soft); letter-spacing: .04em; }

.grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 34px 26px; }
@media (max-width: 1080px) { .grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 760px)  { .grid { grid-template-columns: repeat(2, 1fr); gap: 26px 16px; } }

.product { display: flex; flex-direction: column; gap: 12px; cursor: pointer; }
.product-media {
  position: relative; aspect-ratio: 3 / 4; background: var(--surface-2); overflow: hidden;
  border: 1px solid var(--line);
}
.product-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2,.6,.2,1); }
.product:hover .product-media img { transform: scale(1.04); }
.product-media .noimg { position: absolute; inset: 0; display: grid; place-items: center; color: var(--brass); opacity: .5; }
.product-media .flags { position: absolute; left: 0; bottom: 0; display: flex; gap: 0; }
.flag {
  font-size: 10px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  padding: 5px 9px; background: var(--surface); color: var(--ink-soft); border-top: 1px solid var(--line); border-right: 1px solid var(--line);
}
.flag.opt { background: var(--brass); color: #fff; border-color: var(--brass); }
.flag.out { color: var(--ink-faint); }

.product-info { display: flex; flex-direction: column; gap: 3px; }
.product-cat { font-size: 10.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-faint); }
.product-name { font-size: 14.5px; font-weight: 500; line-height: 1.4; }
.product-price { font-family: var(--serif); font-size: 18px; font-weight: 500; margin-top: 5px; }
.product-logi { font-size: 12px; color: var(--ink-soft); }
.product-logi b { font-weight: 600; color: var(--ink); }

.more-row { display: flex; justify-content: center; padding: 46px 0 8px; }
.empty { text-align: center; color: var(--ink-soft); padding: 60px 20px; border: 1px solid var(--line); background: var(--surface); }
.empty .serif { font-size: 22px; color: var(--ink); display: block; margin-bottom: 8px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 46px; padding: 0 22px; border-radius: 2px; font-size: 13px; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase; transition: transform .12s, background .15s, border-color .15s;
  border: 1px solid transparent;
}
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--brass); color: #fff; }
.btn.primary:hover { background: var(--brass-deep); }
.btn.dark { background: var(--ink); color: var(--paper); }
.btn.dark:hover { background: color-mix(in srgb, var(--ink) 85%, var(--brass)); }
.btn.line { border-color: var(--ink); color: var(--ink); }
.btn.line:hover { border-color: var(--brass); color: var(--brass-deep); }
.btn.wa { background: var(--wa); color: #fff; }
.btn.tg { background: var(--tg); color: #fff; }
.btn.sm { height: 38px; padding: 0 16px; font-size: 11.5px; }
.btn:disabled { opacity: .45; pointer-events: none; }
.btn .dotc { width: 7px; height: 7px; border-radius: 50%; }

/* pill quick links in intro */
.pill {
  display: inline-flex; align-items: center; gap: 8px; height: 36px; padding: 0 15px;
  border: 1px solid var(--line); border-radius: 2px; font-size: 12px; font-weight: 600;
  letter-spacing: .05em; text-transform: uppercase; color: var(--ink-soft); background: var(--surface);
}
.pill:hover { color: var(--ink); border-color: var(--brass); }
.pill .dotc { width: 7px; height: 7px; border-radius: 50%; }

/* ---------- sections: wholesale + finder ---------- */
.band { border-top: 1px solid var(--line); margin-top: 60px; }
.band.wholesale { background: var(--forest); color: #f2efe6; }
:root[data-theme="dark"] .band.wholesale, :root:not([data-theme="light"]) .band.wholesale { background: #1a2820; }
.band .wrap { padding: 64px 28px; display: grid; grid-template-columns: 1fr 1fr; gap: 54px; align-items: start; }
@media (max-width: 900px) { .band .wrap { grid-template-columns: 1fr; gap: 34px; } }
.band.wholesale .eyebrow { color: color-mix(in srgb, var(--brass) 70%, #fff); }
.band h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(26px, 4vw, 36px); line-height: 1.14; margin: 12px 0 0; text-wrap: balance; }
.band.wholesale p { color: #d9d4c6; margin-top: 16px; max-width: 46ch; }
.band .figure { font-family: var(--serif); font-size: clamp(44px, 8vw, 72px); font-weight: 400; line-height: 1; color: #fff; margin-top: 8px; }
.band .figure small { display: block; font-family: var(--sans); font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: color-mix(in srgb, var(--brass) 65%, #fff); margin-top: 12px; }

.finder { background: var(--surface); }
.finder h2 { color: var(--ink); }
.finder p { color: var(--ink-soft); margin-top: 14px; max-width: 46ch; }

.form { display: flex; flex-direction: column; gap: 16px; }
.f-field { display: flex; flex-direction: column; gap: 6px; }
.f-field label { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); }
.band.wholesale .f-field label { color: color-mix(in srgb, #fff 62%, var(--forest)); }
.f-field input, .f-field textarea {
  border: 0; border-bottom: 1px solid var(--line); background: transparent; padding: 8px 2px; font-size: 15px; border-radius: 0;
}
.band.wholesale .f-field input, .band.wholesale .f-field textarea { border-bottom-color: rgba(255,255,255,.25); color: #fff; }
.band.wholesale .f-field input::placeholder, .band.wholesale .f-field textarea::placeholder { color: rgba(255,255,255,.4); }
.f-field input:focus, .f-field textarea:focus { outline: none; border-bottom-color: var(--brass); }
.f-check { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink-soft); }
.band.wholesale .f-check { color: #d9d4c6; }
.f-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 6px; }
.f-note { font-size: 12.5px; color: var(--ink-faint); }
.band.wholesale .f-note { color: rgba(255,255,255,.5); }

/* ---------- footer ---------- */
.site-footer { border-top: 2px solid var(--brass); background: var(--surface); }
.site-footer .wrap { padding: 40px 28px; display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; }
.site-footer .contacts { display: flex; gap: 10px; flex-wrap: wrap; }
.site-footer small { color: var(--ink-faint); font-size: 12px; letter-spacing: .03em; }
.site-footer .adm { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--ink-faint); border-bottom: 1px solid var(--line); }
.site-footer .adm:hover { color: var(--brass-deep); border-color: var(--brass); }

/* ---------- product overlay ---------- */
.overlay { position: fixed; inset: 0; z-index: 80; background: color-mix(in srgb, var(--ink) 55%, transparent); display: grid; place-items: center; padding: 24px; }
.sheet {
  background: var(--paper); width: min(1000px, 100%); max-height: 92vh; overflow-y: auto;
  display: grid; grid-template-columns: 1.1fr .9fr; box-shadow: var(--shadow-lg); position: relative;
}
@media (max-width: 820px) { .sheet { grid-template-columns: 1fr; max-height: 94vh; } }
.sheet .close { position: absolute; top: 12px; right: 14px; z-index: 2; width: 40px; height: 40px; display: grid; place-items: center; background: var(--paper); border: 1px solid var(--line); font-size: 18px; border-radius: 2px; }
.sheet-media { background: var(--surface-2); border-right: 1px solid var(--line); }
.sheet-media .main { aspect-ratio: 3 / 4; }
@media (max-width: 820px) {
  .sheet-media { border-right: 0; border-bottom: 1px solid var(--line); }
  .sheet-media .main { aspect-ratio: auto; height: 42vh; }
  .sheet-media .main img { object-position: center top; }
}
.sheet-media .main img { width: 100%; height: 100%; object-fit: cover; }
.sheet-media .noimg { width: 100%; height: 100%; display: grid; place-items: center; color: var(--brass); opacity: .5; }
.sheet-thumbs { display: flex; gap: 8px; padding: 10px; }
.sheet-thumbs img { width: 56px; height: 72px; object-fit: cover; border: 1px solid var(--line); opacity: .55; cursor: pointer; }
.sheet-thumbs img.on { opacity: 1; border-color: var(--brass); }
.sheet-body { padding: 30px 32px 34px; }
.sheet-body .product-cat { margin-bottom: 8px; }
.sheet-body h2 { font-family: var(--serif); font-weight: 400; font-size: 27px; line-height: 1.16; letter-spacing: -.01em; }
.sheet-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.tag { font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; padding: 4px 9px; border: 1px solid var(--line); color: var(--ink-soft); }
.tag.opt { background: var(--brass); color: #fff; border-color: var(--brass); }
.tag.ok { color: var(--ok); border-color: color-mix(in srgb, var(--ok) 40%, var(--line)); }
.sheet-price { font-family: var(--serif); font-size: 30px; font-weight: 500; margin-top: 20px; }
.sheet-logi { font-size: 13.5px; color: var(--ink-soft); margin-top: 4px; }
.sheet-logi b { color: var(--ink); }
.sheet-desc { margin-top: 18px; font-size: 14.5px; color: var(--ink-soft); white-space: pre-line; line-height: 1.7; }
.spec { width: 100%; border-collapse: collapse; margin-top: 20px; font-size: 13.5px; }
.spec td { padding: 9px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.spec td:first-child { color: var(--ink-faint); width: 44%; padding-right: 14px; letter-spacing: .02em; }
.sheet-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 26px; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%);
  background: var(--ink); color: var(--paper); padding: 12px 20px; font-size: 13.5px; letter-spacing: .02em;
  z-index: 120; box-shadow: var(--shadow-lg); max-width: 90vw; text-align: center; border-radius: 2px;
}

/* ---------- skeleton ---------- */
.sk { background: linear-gradient(90deg, var(--surface-2), color-mix(in srgb, var(--surface-2) 60%, var(--paper)), var(--surface-2)); background-size: 200% 100%; animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.sk-media { aspect-ratio: 3/4; border: 1px solid var(--line); }
.sk-line { height: 12px; margin-top: 8px; }
