/* DealsKoti — public site
   Idea: shelf of price tags. The marigold tag is the one loud thing; everything else stays quiet. */

:root {
  --paper: #F5F6FA;
  --surface: #FFFFFF;
  --ink: #1C2140;
  --ink-2: #3A4063;
  --muted: #62698A;
  --line: #E0E3EE;
  --marigold: #F2A007;
  --on-marigold: #2B1E00;
  --save: #0C8050;
  --tg: #229ED9;
  --band: #1C2140;
  --on-band: #F5F6FA;
  --radius-lg: 20px;
  --radius: 12px;
  --display: "Bricolage Grotesque", "Segoe UI", system-ui, sans-serif;
  --body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #11142A; --surface: #191D37; --ink: #EDEFF8; --ink-2: #C9CDE2; --muted: #9CA3C2;
    --line: #2A2F52; --marigold: #F5B12E; --save: #3CC98A; --band: #191D37; --on-band: #EDEFF8;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #11142A; --surface: #191D37; --ink: #EDEFF8; --ink-2: #C9CDE2; --muted: #9CA3C2;
  --line: #2A2F52; --marigold: #F5B12E; --save: #3CC98A; --band: #191D37; --on-band: #EDEFF8;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 1rem/1.6 var(--body);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); line-height: 1.12; margin: 0 0 .5em; letter-spacing: -.02em; }
h1 { font-size: clamp(2rem, 4.2vw, 3rem); font-weight: 800; }
h2 { font-size: clamp(1.35rem, 2.4vw, 1.75rem); font-weight: 700; }
h3 { font-size: 1rem; font-weight: 600; }
p { margin: 0 0 1em; }
.wrap { width: min(1200px, 100% - 2.5rem); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.center { text-align: center; }
.lead { font-size: 1.125rem; color: var(--ink-2); max-width: 60ch; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: var(--paper); padding: 8px 14px; border-radius: 8px; z-index: 99; }
.skip:focus { left: 8px; }
:focus-visible { outline: 3px solid var(--marigold); outline-offset: 2px; border-radius: 4px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font: 600 .95rem/1 var(--body); padding: .85em 1.25em; border-radius: 999px;
  border: 1.5px solid var(--ink); background: transparent; color: var(--ink);
  text-decoration: none; cursor: pointer; transition: background .15s, color .15s;
}
.btn:hover { background: var(--ink); color: var(--paper); }
.btn-primary { background: var(--ink); color: var(--paper); }
.btn-primary:hover { background: var(--ink-2); border-color: var(--ink-2); }
.btn-tg { background: var(--tg); border-color: var(--tg); color: #fff; }
.btn-tg:hover { background: #1A87BC; border-color: #1A87BC; color: #fff; }
.btn-sm { padding: .6em 1em; font-size: .875rem; }
.btn-lg { padding: 1em 1.6em; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: wait; }
.text-link { color: inherit; font-weight: 600; }

/* ---------- Header ---------- */
.site-head {
  position: sticky; top: 0; z-index: 20;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--line);
  padding-top: env(safe-area-inset-top, 0px);
}
.head-row { display: flex; align-items: center; gap: 1.5rem; height: 64px; }
.logo { display: inline-flex; align-items: center; gap: .5rem; text-decoration: none; font: 800 1.3rem/1 var(--display); letter-spacing: -.03em; }
.logo svg { width: 30px; height: 30px; transform: rotate(-8deg); }
.main-nav { display: flex; gap: .25rem; }
.main-nav a { text-decoration: none; font-weight: 500; padding: .5rem .8rem; border-radius: 999px; color: var(--ink-2); }
.main-nav a:hover { color: var(--ink); background: var(--surface); }
.main-nav a[aria-current="page"] { color: var(--ink); font-weight: 700; }
.head-actions { margin-left: auto; display: flex; align-items: center; gap: .5rem; }
.head-search input {
  width: 200px; font: inherit; font-size: .9rem; padding: .55rem .9rem; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
}
.icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; }
.icon-btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.menu-btn { display: none; }

/* ---------- Price tag (the signature element) ---------- */
.tag {
  position: absolute; top: 12px; left: 10px; z-index: 2;
  background: var(--marigold); color: var(--on-marigold);
  padding: .3em .7em .3em 1.15em; font: 800 .9rem/1.1 var(--display);
  clip-path: polygon(10px 0, 100% 0, 100% 100%, 10px 100%, 0 50%);
  transform: rotate(-4deg);
}
.tag::before { content: ""; position: absolute; left: 7px; top: 50%; width: 5px; height: 5px; margin-top: -2.5px; border-radius: 50%; background: var(--surface); }

/* ---------- Hero ---------- */
.hero { padding: clamp(2.5rem, 6vw, 5rem) 0 clamp(2rem, 4vw, 3.5rem); }
.hero-grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero h1 { font-size: clamp(2.5rem, 6vw, 4.6rem); line-height: 1; letter-spacing: -.045em; max-width: 12ch; }
.hero .lead { margin: 1.1rem 0 1.6rem; }
.hero-search { display: flex; gap: .5rem; max-width: 520px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 6px; }
.hero-search input { flex: 1; min-width: 0; font: inherit; border: 0; background: transparent; color: var(--ink); padding: 0 .9rem; }
.hero-search input:focus { outline: none; }
.hero-search:focus-within { border-color: var(--ink); }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 1.25rem 0 0; }
.chips a { display: inline-block; text-decoration: none; font-size: .875rem; font-weight: 500; padding: .4rem .85rem; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); background: var(--surface); }
.chips a:hover { border-color: var(--ink); color: var(--ink); }

.hero-drop {
  position: relative; display: flex; flex-direction: column; text-decoration: none;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  padding: 3.25rem 1.5rem 1.5rem; min-height: 380px;
}
.hero-drop-label { position: absolute; top: 1.1rem; right: 1.25rem; font-size: .8rem; font-weight: 600; color: var(--muted); }
.hero-drop img { width: 100%; height: 220px; object-fit: contain; background: #fff; border-radius: var(--radius); padding: 12px; margin-bottom: 1rem; }
.hero-drop-title { font-weight: 600; line-height: 1.35; margin-bottom: .5rem; }
.hero-drop-price strong { font: 800 1.6rem/1 var(--display); }
.hero-drop-price s { color: var(--muted); margin-left: .35rem; }
.hero-drop .asof { margin-top: .35rem; }
.hero-tag {
  position: absolute; top: -18px; left: -14px; z-index: 3;
  display: flex; flex-direction: column; align-items: flex-start;
  background: var(--marigold); color: var(--on-marigold);
  padding: .9rem 1.2rem .8rem 2.2rem;
  clip-path: polygon(22px 0, 100% 0, 100% 100%, 22px 100%, 0 50%);
  transform: rotate(-9deg); transform-origin: 20% 50%;
  filter: drop-shadow(0 10px 18px rgba(28, 33, 64, .18));
}
.hero-tag b { font: 800 2.6rem/.9 var(--display); letter-spacing: -.04em; }
.hero-tag small { font-weight: 700; font-size: .8rem; }
.hero-tag .hole { position: absolute; left: 14px; top: 50%; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: var(--paper); }
.hero-drop-empty { align-items: center; justify-content: center; }
.hero-drop-empty .hero-tag { position: static; transform: rotate(-9deg); }
@media (prefers-reduced-motion: no-preference) {
  .hero-tag { animation: swing 1.4s cubic-bezier(.2, .9, .3, 1.2) .2s both; }
  @keyframes swing { from { transform: rotate(-32deg) translateY(-12px); opacity: 0; } to { transform: rotate(-9deg); opacity: 1; } }
}

/* ---------- Sections ---------- */
.section { padding: clamp(1.75rem, 4vw, 3rem) 0; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.section-head h2 { margin: 0; }
.section-head p { margin: 0; font-size: .9rem; }
.page-top { padding: 2.5rem 0 .5rem; }
.count-line { font-size: .9rem; }

/* ---------- Shelf: tiled product grid with hairline gaps ---------- */
.shelf {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1px;
  background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-lg); overflow: hidden;
}
.card { position: relative; min-width: 0; display: flex; flex-direction: column; background: var(--surface); }
.card-img { position: relative; display: block; aspect-ratio: 1; background: #fff; padding: 1.25rem; }
.card-img img { width: 100%; height: 100%; object-fit: contain; transition: transform .25s ease; }
.card:hover .card-img img { transform: scale(1.04); }
.img-empty { display: block; width: 100%; height: 100%; background: repeating-linear-gradient(45deg, #F0F1F6 0 10px, #fff 10px 20px); border-radius: 8px; }
.card-body { display: flex; flex-direction: column; flex: 1; padding: .9rem 1rem 1.1rem; border-top: 1px solid var(--line); }
.card-brand { font-size: .78rem; font-weight: 600; color: var(--muted); margin: 0 0 .2rem; }
.card-title { font: 600 .95rem/1.4 var(--body); letter-spacing: 0; margin: 0 0 .4rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.card-title a { text-decoration: none; }
.card-title a:hover { text-decoration: underline; }
.card-rating { font-size: .82rem; margin: 0 0 .5rem; display: flex; align-items: center; gap: .35rem; }
.stars::before {
  content: "★★★★★"; letter-spacing: 1px;
  background: linear-gradient(90deg, var(--marigold) calc(var(--r) / 5 * 100%), var(--line) 0);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.card-foot { margin-top: auto; }
.price { margin: 0; display: flex; align-items: baseline; gap: .45rem; flex-wrap: wrap; }
.price strong { font: 800 1.25rem/1.1 var(--display); color: var(--ink); }
.price s { color: var(--muted); font-size: .88rem; }
.price-check { font-size: .88rem; color: var(--muted); font-weight: 500; }
.asof { font-size: .72rem; color: var(--muted); margin: .2rem 0 0; }
.btn-buy { width: 100%; margin-top: .8rem; padding: .7em 1em; font-size: .88rem; }

/* ---------- Categories ---------- */
.cat-grid { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: .75rem; }
.cat-grid a {
  display: flex; flex-direction: column; gap: .2rem; text-decoration: none; height: 100%;
  padding: 1.1rem 1.2rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.cat-grid a:hover { border-color: var(--ink); }
.cat-name { font: 700 1.1rem/1.2 var(--display); }
.cat-count { font-size: .85rem; color: var(--muted); }

.filter-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-top: 1rem; }
.cat-tabs { display: flex; gap: .4rem; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.cat-tabs a { white-space: nowrap; text-decoration: none; font-size: .9rem; font-weight: 500; padding: .45rem .9rem; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2); }
.cat-tabs a[aria-current="page"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.sort-form { display: flex; align-items: center; gap: .5rem; font-size: .9rem; }
.sort-form select { font: inherit; padding: .45rem .8rem; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); }
.pager { display: flex; justify-content: center; align-items: center; gap: 1.25rem; margin-top: 2rem; }
.pager a { font-weight: 600; }

.empty-state { text-align: center; padding: 3rem 1rem; }
.empty-state p { color: var(--muted); max-width: 46ch; margin-inline: auto; }

/* ---------- Telegram band ---------- */
.tg-band { background: var(--band); color: var(--on-band); padding: clamp(2.5rem, 5vw, 3.5rem) 0; margin-top: 2rem; }
.tg-band-row { display: flex; align-items: center; justify-content: space-between; gap: 2rem; flex-wrap: wrap; }
.tg-band h2 { font-size: clamp(1.6rem, 3.2vw, 2.3rem); margin-bottom: .35rem; max-width: 22ch; }
.tg-band p { margin: 0; opacity: .8; max-width: 52ch; }
.tg-band-actions { display: flex; align-items: center; gap: 1.25rem; flex-wrap: wrap; }
.exclusive-note { padding: 1.5rem 0 0; }
.exclusive-note p { margin: 0; font-size: .92rem; color: var(--ink-2); border: 1px dashed var(--line); border-radius: var(--radius); padding: .9rem 1.1rem; }
.exclusive-note a { font-weight: 700; }

/* ---------- Telegram page ---------- */
.tg-hero { padding: clamp(2.5rem, 6vw, 4.5rem) 0 1rem; }
.tg-hero-grid { display: grid; grid-template-columns: 1.2fr .8fr; gap: 3rem; align-items: center; }
.tg-hero h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); letter-spacing: -.04em; max-width: 14ch; }
.tg-hero .lead { margin-bottom: 1.5rem; }
.phone { background: var(--surface); border: 1px solid var(--line); border-radius: 28px; padding: 1rem; max-width: 320px; justify-self: center; width: 100%; }
.phone-head { display: flex; align-items: center; gap: .6rem; padding-bottom: .8rem; border-bottom: 1px solid var(--line); margin-bottom: .8rem; }
.phone-head .av { width: 36px; height: 36px; border-radius: 50%; background: var(--marigold); }
.phone-head span { display: flex; flex-direction: column; line-height: 1.2; }
.phone-head small { color: var(--muted); font-size: .75rem; }
.bubble { display: flex; flex-direction: column; gap: .1rem; background: var(--paper); border-radius: 14px 14px 14px 4px; padding: .75rem .9rem; margin-bottom: .6rem; font-size: .88rem; }
.bubble .bp b { font-family: var(--display); }
.bubble s { color: var(--muted); }
.bubble i { font-style: normal; color: var(--tg); font-weight: 600; font-size: .82rem; margin-top: .2rem; }
.bot-list { display: grid; gap: 1rem; }
.bot { display: flex; justify-content: space-between; gap: 2rem; flex-wrap: wrap; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1.5rem; }
.bot-main { flex: 1 1 380px; }
.bot-main h3 { font: 700 1.3rem/1.2 var(--display); margin-bottom: .1rem; }
.bot-side { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: .75rem; }
.bot-price { font-weight: 600; margin: 0; }
.ticks { list-style: none; padding: 0; margin: .5rem 0 0; display: grid; gap: .35rem; }
.ticks li { padding-left: 1.6rem; position: relative; }
.ticks li::before { content: ""; position: absolute; left: 2px; top: .45em; width: 11px; height: 6px; border-left: 2px solid var(--save); border-bottom: 2px solid var(--save); transform: rotate(-45deg); }
.steps { list-style: none; counter-reset: s; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }
.steps li { counter-increment: s; display: flex; flex-direction: column; gap: .2rem; padding: 1.1rem 1.2rem; border-top: 3px solid var(--marigold); background: var(--surface); border-radius: 0 0 var(--radius) var(--radius); }
.steps li::before { content: "Step " counter(s); font-size: .8rem; font-weight: 700; color: var(--muted); }
.steps span { color: var(--muted); font-size: .92rem; }

/* ---------- Exclusive ---------- */
.exclusive { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(2rem, 5vw, 4rem); padding: clamp(2.5rem, 5vw, 4rem) 0; align-items: start; }
.exclusive h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); letter-spacing: -.04em; max-width: 15ch; }
.exclusive .ticks { margin: 1.25rem 0 1.5rem; gap: .6rem; }
.ex-card, .form-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 1.6rem; }
.ex-price { display: flex; align-items: baseline; gap: .5rem; margin-bottom: 1.1rem; }
.ex-price b { font: 800 2.6rem/1 var(--display); letter-spacing: -.03em; }
.ex-price span { color: var(--muted); }
label { display: block; font-size: .88rem; font-weight: 600; margin-bottom: .9rem; }
input:not([type="checkbox"]):not([type="search"]), textarea, select.full {
  display: block; width: 100%; margin-top: .35rem; font: 400 1rem/1.4 var(--body);
  padding: .75rem .9rem; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--ink);
}
input:focus, textarea:focus { outline: none; border-color: var(--ink); }
label.check { display: flex; gap: .55rem; align-items: flex-start; font-weight: 500; }
label.check input { margin-top: .25rem; accent-color: var(--ink); }
.form-error { background: #FDECEC; color: #8A1C1C; padding: .7rem .9rem; border-radius: 10px; font-size: .9rem; }
.notice { background: var(--paper); padding: .9rem 1rem; border-radius: 10px; }
.hp { position: absolute; left: -5000px; }

/* ---------- Contact / legal ---------- */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); padding: clamp(2.5rem, 5vw, 4rem) 0; align-items: start; }
.contact-list { display: grid; grid-template-columns: auto 1fr; gap: .6rem 1.25rem; margin: 1.5rem 0; }
.contact-list dt { font-weight: 700; }
.contact-list dd { margin: 0; }
.legal { padding: clamp(2.5rem, 5vw, 4rem) 0; max-width: 760px; }
.prose { font-size: 1.02rem; }
.prose h2 { font-size: 1.3rem; margin-top: 2rem; }
.prose p, .prose li { max-width: 70ch; color: var(--ink-2); }

/* ---------- Footer ---------- */
.site-foot { border-top: 1px solid var(--line); margin-top: 3rem; padding: 3rem 0 calc(1.5rem + env(safe-area-inset-bottom, 0px)); font-size: .92rem; }
.tg-band + .exclusive-note + .site-foot, .tg-band + .site-foot { margin-top: 2rem; }
.foot-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 2rem; }
.foot-brand p { color: var(--muted); max-width: 34ch; margin: .8rem 0 1rem; }
.site-foot h2 { font: 700 .95rem/1.2 var(--body); letter-spacing: 0; margin-bottom: .8rem; }
.site-foot ul { list-style: none; padding: 0; margin: 0; display: grid; gap: .45rem; }
.site-foot ul a { text-decoration: none; color: var(--ink-2); }
.site-foot ul a:hover { color: var(--ink); text-decoration: underline; }
.foot-legal { border-top: 1px solid var(--line); margin-top: 2.5rem; padding-top: 1.25rem; color: var(--muted); font-size: .8rem; }
.foot-legal p { max-width: 110ch; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .head-search { display: none; }
  .hero-grid, .tg-hero-grid, .exclusive, .contact { grid-template-columns: 1fr; }
  .hero-drop { max-width: 440px; margin: 1rem 0 0 14px; }
  .hero-tag b { font-size: 2.1rem; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-brand { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .menu-btn { display: grid; }
  .main-nav {
    display: none; position: absolute; top: 100%; left: 0; right: 0; flex-direction: column;
    background: var(--surface); border-bottom: 1px solid var(--line); padding: .5rem 1.25rem 1rem;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: .8rem .5rem; border-radius: 8px; font-size: 1.05rem; }
  .site-head { position: sticky; }
  .head-row { position: relative; }
  .shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-drop { padding-top: 4.25rem; }
  .hero-drop-label { top: 1.35rem; }
  .card-img { padding: .75rem; }
  .card-body { padding: .75rem .75rem .9rem; }
  .card-title { font-size: .88rem; }
  .price strong { font-size: 1.08rem; }
  .btn-buy { font-size: .82rem; padding: .65em .6em; }
  .hero-search { flex-direction: column; border-radius: 18px; }
  .hero-search input { padding: .7rem .9rem; }
}
@media (max-width: 380px) {
  .shelf { grid-template-columns: 1fr; }
}
