:root {
  color-scheme: dark;
  --ink: #f2f3f8;
  --muted: #b0b3c5;
  --line: #353847;
  --bg: #111218;
  --card: #1b1d26;
  --surface: #20222d;
  --control: #262936;
  --violet: #6858ec;
  --action-hover: #5a49d6;
  --accent-text: #b8afff;
  --accent-line: #665c94;
  --lime: var(--accent-text);
  --soft-violet: #2b2646;
  --danger: var(--accent-text);
  --danger-bg: var(--soft-violet);
  --danger-line: var(--accent-line);
  --success: var(--accent-text);
  --success-bg: var(--soft-violet);
  --success-line: var(--accent-line);
  --warning: var(--accent-text);
  --warning-bg: var(--soft-violet);
  --warning-line: var(--accent-line);
  --repeat: #ffba79;
  --repeat-bg: #462a16;
  --info: var(--accent-text);
  --info-bg: var(--soft-violet);
  --radius: 24px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
  font-synthesis: none;
}

/* Standalone, crawlable shop pages retain the existing offer design. */
.brand-route { display: flex; flex-direction: column; min-height: 100vh; }
.brand-route main { order: 0; padding-bottom: 0; }
.brand-route main .catalog { display: none; }
.brand-route footer { order: 2; }
.brand-route .brand-dialog-backdrop { position: static; display: block; padding: 24px 0; background: none; backdrop-filter: none; z-index: auto; }
.brand-route .brand-dialog { width: min(1000px, calc(100% - 40px)); max-height: none; margin: 0 auto; overflow: visible; }
.brand-route .brand-dialog-head { position: static; }
.brand-route #brand-dialog-title { margin: 0; font-size: clamp(22px, 4vw, 32px); line-height: 1.25; }
.brand-route .brand-dialog-offers { max-height: none; overflow: visible; }
.brand-route #category-menu-toggle, .brand-route .search-row { display: none; }
.brand-route .offer-item { overflow-wrap: anywhere; }
.thanks-action[hidden] { display: none; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; touch-action: manipulation; -webkit-text-size-adjust: 100%; }
body { margin: 0; min-width: 320px; background: var(--bg); }
.catalog-page main { padding-top: 77px; }
button, input, select { font: inherit; }
button, a, .promo-card { touch-action: manipulation; }
button, select { cursor: pointer; }
a { color: inherit; text-decoration: none; }
.shell { width: min(1180px, calc(100% - 40px)); margin: 0 auto; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

.site-header { position: sticky; top: 0; z-index: 20; background: rgba(17,18,24,.94); backdrop-filter: blur(18px); border-bottom: 1px solid var(--line); }
.header-inner { height: 76px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 12px; }
.brand-mark { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 15px; overflow: hidden; background: var(--violet); color: var(--lime); font-size: 23px; font-weight: 950; box-shadow: 0 5px 16px rgba(91,85,246,.24); }
.brand-copy { display: flex; flex-direction: column; font-size: 14px; line-height: 1.05; text-transform: uppercase; letter-spacing: .04em; }
.brand-copy strong { font-size: 17px; letter-spacing: -.01em; }
.header-actions { display: flex; align-items: center; gap: 8px; }
.developer-toggle { display: inline-flex; align-items: center; gap: 7px; min-height: 48px; padding: 0 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); color: var(--muted); font-size: 12px; }
.developer-toggle[hidden] { display: none; }
.developer-toggle span { color: var(--accent-text); font: 850 12px/1 ui-monospace, monospace; }
.developer-toggle b { font-weight: 800; }
.developer-toggle:hover, .developer-toggle[aria-pressed="true"] { border-color: var(--accent-line); background: var(--soft-violet); color: var(--accent-text); }
.vk-link { display: inline-flex; align-items: center; gap: 9px; padding: 9px 14px 9px 9px; border-radius: 14px; background: var(--info-bg); color: var(--info); font-weight: 750; font-size: 14px; transition: transform .18s ease, background .18s ease; }
.vk-link:hover { transform: translateY(-1px); background: var(--soft-violet); }
.vk-icon { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 9px; background: #2787f5; color: white; font-size: 11px; font-weight: 900; }

.eyebrow { margin: 0 0 7px; color: var(--lime); text-transform: uppercase; letter-spacing: .13em; font-size: 12px; font-weight: 900; }
h1 { margin: 0; font-size: clamp(38px, 5.2vw, 62px); line-height: .96; letter-spacing: -.05em; }
.compact-toolbar { position: fixed; z-index: 50; inset: 0 0 auto; padding: 10px 0; border-bottom: 1px solid var(--line); background: rgba(17,18,24,.96); backdrop-filter: blur(18px); box-shadow: 0 5px 18px rgba(26,26,48,.06); }
.toolbar-inner { position: relative; }
.toolbar-layout { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 16px; }
.compact-brand { display: inline-flex; min-width: 238px; align-items: center; gap: 10px; touch-action: manipulation; }
.compact-brand-mark { display: grid; width: 40px; height: 40px; flex: none; place-items: center; border-radius: 13px; background: transparent; }
.compact-brand-mark img { display: block; width: 100%; height: 100%; }
.brand-accent { color: var(--accent-text); }
.compact-brand-copy { display: grid; gap: 2px; min-width: 0; }
.compact-brand-copy strong { font-size: 16px; line-height: 1.05; letter-spacing: -.02em; white-space: nowrap; }
.compact-brand-copy small { color: var(--muted); font-size: 12px; line-height: 1.1; white-space: nowrap; }
.search-row { display: flex; align-items: center; gap: 8px; }
.search-box { position: relative; display: flex; flex: 1; min-width: 0; align-items: center; height: 56px; border: 1px solid var(--line); background: var(--surface); border-radius: 17px; padding: 0 16px; }
.search-box svg { width: 24px; height: 24px; fill: none; stroke: var(--muted); stroke-width: 2; flex: none; }
.search-box input { min-width: 0; flex: 1; height: 100%; border: 0; outline: 0; color: var(--ink); font-size: 18px; background: transparent; padding: 0 14px; }
.search-box input::placeholder { color: var(--muted); }
.search-box kbd { padding: 6px 9px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 8px; color: var(--muted); font: 12px/1 ui-monospace, monospace; }
.category-menu-toggle { display: inline-flex; min-width: 128px; height: 56px; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--accent-line); border-radius: 17px; background: var(--soft-violet); color: var(--accent-text); padding: 0 15px; font-size: 14px; font-weight: 850; }
.category-menu-toggle svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.category-menu-toggle span { white-space: nowrap; }
.category-menu { position: absolute; z-index: 55; top: calc(100% + 10px); right: 0; display: grid; width: min(420px, 100%); grid-template-columns: 1fr 1fr; gap: 7px; border: 1px solid var(--line); border-radius: 20px; background: var(--card); padding: 10px; box-shadow: 0 20px 55px rgba(25,25,50,.18); }
.category-menu[hidden] { display: none; }
.category-chip { display: grid; gap: 3px; min-width: 0; min-height: 66px; align-content: center; border: 1px solid transparent; border-radius: 13px; background: var(--surface); color: var(--ink); padding: 10px 12px; text-align: left; }
.category-chip span { font-size: 14px; font-weight: 800; }
.category-chip small { color: var(--muted); font-size: 11px; line-height: 1.3; }
.category-chip:hover { background: var(--soft-violet); }
.category-chip.is-active { border-color: var(--accent-line); background: var(--soft-violet); color: var(--accent-text); }
.floating-developer { position: fixed; z-index: 45; right: max(16px, env(safe-area-inset-right)); bottom: max(16px, env(safe-area-inset-bottom)); width: 48px; height: 48px; min-height: 48px; justify-content: center; padding: 0; border-radius: 50%; box-shadow: 0 10px 28px rgba(31,31,59,.18); }
.floating-developer[hidden] { display: none; }

.catalog { padding: 16px 0 70px; }

h2 { font-size: 32px; margin: 0; letter-spacing: -.035em; }
.audience-tabs { display: inline-flex; gap: 4px; padding: 4px; margin: 0 0 16px; border-radius: 14px; background: var(--surface); }
.audience-tab { border: 0; border-radius: 10px; padding: 9px 14px; background: transparent; color: var(--muted); font-weight: 750; font-size: 14px; }
.audience-tab.is-active { background: var(--soft-violet); color: var(--accent-text); box-shadow: 0 2px 7px rgba(25,25,46,.08); }
.source-note { display: flex; align-items: center; gap: 9px; margin: 0 0 18px; color: var(--muted); font-size: 13px; }
.source-note[hidden] { display: none; }
.source-note-dot { width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%; background: var(--violet); }
.developer-tools { display: none; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 16px; padding: 11px 13px; border: 1px dashed var(--accent-line); border-radius: 13px; background: var(--surface); color: var(--muted); font-size: 12px; }
.developer-mode .developer-tools:not([hidden]) { display: flex; }
.developer-tools a { flex: none; color: var(--accent-text); font-weight: 800; }
.developer-tool-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px 14px; }
.developer-tools a:hover { text-decoration: underline; text-underline-offset: 3px; }
.developer-tools b { display: inline-grid; min-width: 22px; height: 22px; margin-left: 4px; place-items: center; border-radius: 7px; background: var(--violet); color: white; font-size: 11px; }

.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.promo-card { position: relative; display: flex; height: 100%; flex-direction: column; min-width: 0; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 0; overflow: hidden; cursor: pointer; box-shadow: 0 7px 28px rgba(31,31,59,.05); transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.promo-card:hover { transform: translateY(-3px); border-color: var(--accent-line); box-shadow: 0 14px 35px rgba(40,37,100,.1); }
.promo-card:focus-visible { outline: 3px solid rgba(91,82,246,.32); outline-offset: 3px; }
.card-top { display: flex; align-items: center; gap: 12px; min-width: 0; }
.store-logo { display: grid; place-items: center; width: 50px; height: 50px; flex: none; border-radius: 15px; border: 0; background: transparent; overflow: hidden; }
.store-logo img { width: 100%; height: 100%; object-fit: contain; padding: 0; }
.store-meta { min-width: 0; flex: 1; }
.store-meta h3 { margin: 0 0 3px; font-size: 17px; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.store-meta h3 a:hover { color: var(--accent-text); }
.store-meta p { margin: 0; color: var(--muted); font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card-offer-count { flex: none; align-self: flex-start; min-height: 27px; max-width: 118px; padding: 6px 9px; border-radius: 9px; background: var(--soft-violet); color: var(--accent-text); font-size: 11px; font-weight: 850; line-height: 1.25; text-align: center; }
.card-availability { display: flex; margin-top: 11px; }
.card-availability span { display: inline-flex; min-height: 26px; align-items: center; padding: 4px 9px; border-radius: 9px; background: var(--repeat-bg); color: var(--repeat); font-size: 11px; font-weight: 850; }
.card-offer { display: flex; flex: 1; flex-direction: column; min-width: 0; margin-top: 14px; }
.card-action-box { margin-top: auto; }
.card-open-row { display: flex; min-height: 55px; align-items: center; justify-content: space-between; gap: 12px; margin: 16px -18px 0; padding: 12px 18px; border-top: 1px solid var(--line); background: var(--surface); color: var(--muted); }
.card-open-row > span { font-size: 12px; font-weight: 700; }
.card-open-row strong { display: inline-flex; flex: none; align-items: center; gap: 7px; color: var(--accent-text); font-size: 13px; font-weight: 900; }
.card-open-row b { font-size: 17px; line-height: 1; transition: transform .18s ease; }
.promo-card:hover .card-open-row b { transform: translateX(3px); }
.offer-list { display: grid; gap: 12px; margin-top: 13px; }
.promo-card .offer-list { flex: 1; }
.offer-item { min-width: 0; }
.offer-item + .offer-item { padding-top: 16px; border-top: 1px solid var(--line); }
.offer-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 9px; }
.tag { display: inline-flex; align-items: center; min-height: 25px; padding: 4px 8px; border-radius: 8px; background: var(--success-bg); color: var(--success); font-size: 11px; font-weight: 850; }
.tag.repeat { background: var(--repeat-bg); color: var(--repeat); }
.tag.expiring { background: var(--danger-bg); color: var(--danger); }
.tag.region { background: var(--info-bg); color: var(--info); max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.offer-title { margin: 0 0 13px; font-size: 16px; line-height: 1.38; letter-spacing: -.015em; }
.promo-card .offer-title { display: -webkit-box; min-height: 45px; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.code-box { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; padding: 7px; border-radius: 15px; background: var(--control); }
.link-offer-box { display: grid; grid-template-columns: minmax(0,1fr) auto; align-items: center; gap: 10px; padding: 9px; border-radius: 15px; background: var(--control); }
.link-offer-box > span { display: grid; gap: 3px; min-width: 0; padding-left: 7px; }
.link-offer-box strong { font-size: 14px; }
.link-offer-box small { color: var(--muted); font-size: 12px; }
.code-content { display: grid; min-width: 0; align-content: center; gap: 3px; padding: 7px 10px; }
.code-trigger { width: 100%; border: 0; border-radius: 10px; background: transparent; color: inherit; text-align: left; cursor: pointer; }
.code-trigger:hover { background: var(--soft-violet); }
.code-trigger:active { transform: scale(.985); }
.code-content small { color: var(--muted); font-size: 11px; line-height: 1; }
.code-value { display: block; min-width: 0; padding: 0; font: 800 15px/1.15 ui-monospace, SFMono-Regular, Menlo, monospace; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; letter-spacing: .035em; }
.copy-btn { min-height: 48px; border: 0; border-radius: 10px; padding: 0 17px; background: var(--violet); color: white; font-size: 13px; font-weight: 850; touch-action: manipulation; transition: background .18s ease, transform .18s ease; }
.copy-btn.copy-go { min-width: 164px; }
.copy-btn:hover { background: var(--action-hover); }
.copy-btn:active { transform: scale(.97); }
.offer-bottom { display: flex; justify-content: space-between; gap: 10px; align-items: center; margin-top: 10px; }
.expiry { color: var(--muted); font-size: 12px; }
.link-required { color: var(--accent-text); font-size: 12px; font-weight: 800; }
.offer-action-note { display: flex; align-items: center; gap: 6px; width: fit-content; margin: 10px 0 7px; padding: 6px 9px; border-radius: 9px; background: var(--soft-violet); line-height: 1.25; }
.offer-action-note span { color: #f0c878; font-size: 14px; line-height: 1; }
.offer-conditions { margin-top: 12px; padding-top: 11px; border-top: 1px solid var(--line); }
.offer-conditions summary { list-style: none; cursor: pointer; color: var(--accent-text); font-size: 13px; font-weight: 800; }
.offer-conditions summary::-webkit-details-marker { display: none; }
.offer-conditions summary::after { content: "↓"; float: right; }
.offer-conditions[open] summary::after { content: "↑"; }
.offer-conditions p { margin: 9px 0 0; color: var(--muted); font-size: 13px; line-height: 1.48; }
.developer-source { display: none; margin-top: 14px; padding: 12px; border: 1px dashed var(--accent-line); border-radius: 13px; background: var(--surface); }
.developer-mode .developer-source { display: block; }
.ranking-audit { display: grid; gap: 5px; margin-bottom: 11px; padding-bottom: 11px; border-bottom: 1px solid var(--line); }
.ranking-audit > div { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.ranking-audit strong { font-size: 12px; }
.ranking-audit span { flex: none; padding: 4px 7px; border-radius: 7px; background: var(--success-bg); color: var(--success); font-size: 10px; font-weight: 850; }
.ranking-audit.needs-review span { background: var(--warning-bg); color: var(--warning); }
.ranking-audit p { margin: 0; color: var(--muted); font-size: 11px; line-height: 1.4; }
.ranking-audit-question { color: var(--warning); font-size: 11px; line-height: 1.4; }
.developer-source-title { display: block; margin-bottom: 8px; color: var(--muted); font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .035em; }
.developer-source-list { display: grid; gap: 6px; }
.developer-source-list a, .developer-source-list > div { position: relative; display: grid; gap: 2px; min-width: 0; padding: 9px 34px 9px 10px; border-radius: 10px; background: var(--card); color: var(--ink); }
.developer-source-list a:hover { background: var(--soft-violet); }
.developer-source-list b, .developer-source-list small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.developer-source-list b { font-size: 12px; }
.developer-source-list small { color: var(--muted); font-size: 12px; }
.developer-source-list a > span { position: absolute; right: 11px; top: 50%; color: var(--accent-text); transform: translateY(-50%); font-weight: 900; }
.all-offers-link { display: flex; align-items: center; justify-content: space-between; min-height: 42px; margin: 15px 0 -6px; padding: 8px 2px 0; border-top: 1px solid var(--line); color: var(--accent-text); font-size: 13px; font-weight: 850; }
.all-offers-link::after { content: "→"; margin-left: auto; padding-left: 10px; font-size: 17px; }
.catalog-ad-slot { grid-column: 1 / -1; display: grid; min-height: 96px; place-content: center; gap: 5px; border: 1px dashed var(--line); border-radius: 20px; background: linear-gradient(135deg, var(--card), var(--soft-violet)); color: var(--muted); text-align: center; }
.catalog-ad-slot span { font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .12em; }
.catalog-ad-slot b { color: var(--muted); font-size: 13px; }
.more-wrap { margin-top: 15px; padding-top: 14px; border-top: 1px solid var(--line); }
.more-wrap summary { list-style: none; cursor: pointer; color: var(--muted); font-size: 13px; font-weight: 750; user-select: none; }
.more-wrap summary::-webkit-details-marker { display: none; }
.more-wrap summary::after { content: "↓"; float: right; color: var(--accent-text); }
.more-wrap[open] summary::after { content: "↑"; }
.extra-list { display: grid; gap: 9px; margin-top: 13px; }
.extra-offer { padding: 12px; border-radius: 14px; background: var(--surface); }
.extra-offer p { margin: 0 0 9px; font-size: 13px; line-height: 1.35; }
.extra-code-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.extra-code-row code { min-width: 0; overflow: hidden; text-overflow: ellipsis; font-size: 12px; font-weight: 800; }
.mini-copy { flex: none; border: 0; background: transparent; color: var(--accent-text); font-size: 12px; font-weight: 850; padding: 5px; }

.empty-state { max-width: 440px; margin: 48px auto 0; text-align: center; }
.empty-icon { width: 62px; height: 62px; display: grid; place-items: center; margin: 0 auto 16px; border-radius: 20px; background: var(--soft-violet); color: var(--accent-text); font-size: 25px; font-weight: 950; transform: rotate(-6deg); }
.empty-state h3 { margin: 0; font-size: 22px; }
.empty-state p { color: var(--muted); }
.empty-state button { border: 0; padding: 11px 16px; border-radius: 12px; background: var(--violet); color: white; font-weight: 800; }
footer { border-top: 1px solid var(--line); background: var(--card); }
.footer-inner { min-height: 104px; display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.footer-inner div { display: flex; flex-direction: column; gap: 4px; }
.footer-inner span, .footer-inner p { color: var(--muted); font-size: 13px; }
.footer-inner p { margin: 0; }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 20px; margin-top: 8px; }
.footer-links a { padding: 8px 0; color: var(--muted); font-size: 14px; line-height: 1.5; text-decoration: underline; text-underline-offset: 3px; }
.footer-links a:hover, .information-content a:hover { color: var(--ink); }
.footer-links a:focus-visible, .information-page a:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 4px; border-radius: 2px; }
.information-page { display: flex; flex-direction: column; min-height: 100vh; }
.information-header { padding-block: 24px; }
.information-content { max-width: 800px; flex: 1; padding-block: 24px 56px; font-size: 16px; line-height: 1.75; overflow-wrap: anywhere; }
.information-content h1 { margin: 0 0 20px; font-size: clamp(28px, 5vw, 40px); line-height: 1.2; letter-spacing: -.02em; }
.information-content h2 { margin: 0 0 12px; font-size: 22px; line-height: 1.35; }
.information-content section { margin-top: 32px; }
.information-content p { margin: 0 0 14px; }
.information-content ul { padding-left: 22px; }
.information-content li { margin-bottom: 10px; }
.information-content a { color: var(--accent-text); text-decoration: underline; text-underline-offset: 3px; }
.information-lead { font-size: 19px; color: var(--muted); }
.information-date, .contact-pending { color: var(--muted); font-size: 14px; }
.contact-details { margin: 16px 0; }
.contact-details dt { color: var(--muted); font-size: 14px; margin-top: 14px; }
.contact-details dd { margin: 2px 0 0; }
.contact-pending { display: block; }
.settings-link { color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.settings-link:hover { color: var(--ink); }
.brand-dialog-backdrop { position: fixed; z-index: 70; inset: 0; display: grid; place-items: center; padding: 24px; background: rgba(5,6,10,.72); backdrop-filter: blur(8px); }
.brand-dialog-backdrop[hidden] { display: none; }
.page-scroll-locked { position: fixed; width: 100%; overflow: hidden; }
.brand-dialog { position: relative; display: flex; flex-direction: column; width: min(100%, 760px); max-height: 88vh; max-height: min(88dvh, 900px); overflow: hidden; border: 1px solid var(--line); border-radius: 26px; background: var(--bg); box-shadow: 0 28px 90px rgba(0,0,0,.34); }
.brand-dialog-head { display: flex; align-items: center; gap: 14px; padding: 22px 72px 18px 22px; border-bottom: 1px solid var(--line); background: var(--card); }
.brand-dialog-logo { display: grid; place-items: center; width: 58px; height: 58px; flex: none; overflow: hidden; border: 0; border-radius: 17px; background: transparent; }
.brand-dialog-logo img { width: 100%; height: 100%; padding: 0; object-fit: contain; }
.brand-dialog-head h2 { font-size: 26px; }
.brand-dialog-head p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.brand-audience-filter { display: flex; flex: none; gap: 6px; overflow-x: auto; padding: 10px 12px; border-bottom: 1px solid var(--line); background: var(--card); scrollbar-width: none; }
.brand-audience-filter::-webkit-scrollbar { display: none; }
.brand-audience-filter[hidden] { display: none; }
.brand-audience-filter button { display: inline-flex; min-height: 36px; flex: none; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 11px; padding: 0 11px; background: var(--surface); color: var(--muted); font-size: 12px; font-weight: 800; }
.brand-audience-filter button small { display: inline-grid; min-width: 19px; height: 19px; place-items: center; border-radius: 7px; background: var(--card); color: inherit; font-size: 10px; }
.brand-audience-filter button.is-active { border-color: var(--accent-line); background: var(--soft-violet); color: var(--accent-text); }
.brand-audience-filter button:disabled { opacity: .38; cursor: default; }
.brand-dialog-offers { display: grid; min-height: 0; gap: 10px; overflow-y: auto; overscroll-behavior: contain; padding: 12px; }
.brand-dialog-offers .offer-item { padding: 16px; border: 1px solid var(--line); border-radius: 18px; background: var(--card); }
.brand-dialog-offers .offer-item + .offer-item { border-top: 1px solid var(--line); }
.brand-dialog-offers .offer-tags { margin-bottom: 8px; }
.brand-dialog-offers .offer-title { margin-bottom: 12px; }
.brand-dialog-offers .offer-bottom { margin-top: 10px; }

.dialog-backdrop { position: fixed; z-index: 80; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(5,6,10,.72); backdrop-filter: blur(8px); }
.dialog-backdrop[hidden] { display: none; }
.thanks-dialog { position: relative; width: min(100%, 460px); max-height: calc(100dvh - 32px); overflow-y: auto; border-radius: 26px; background: var(--card); padding: 28px; text-align: center; box-shadow: 0 28px 80px rgba(0,0,0,.28); }
.dialog-close { position: absolute; top: 12px; right: 12px; display: grid; width: 40px; height: 40px; place-items: center; border: 0; border-radius: 12px; background: var(--control); color: var(--muted); font-size: 25px; line-height: 1; }
.copy-success-icon { display: grid; width: 62px; height: 62px; place-items: center; margin: 0 auto 13px; border-radius: 20px; background: var(--soft-violet); color: var(--accent-text); font-size: 28px; font-weight: 950; }
.thanks-dialog h2 { margin: 0; font-size: 28px; }
.copied-code { display: inline-flex; max-width: 100%; margin: 10px auto 20px; padding: 8px 12px; overflow: hidden; border-radius: 10px; background: var(--control); color: var(--ink); font: 850 14px/1.2 ui-monospace, SFMono-Regular, Menlo, monospace; text-overflow: ellipsis; white-space: nowrap; }
.thanks-action { display: grid; width: 100%; min-height: 70px; grid-template-columns: auto 1fr; align-items: center; gap: 12px; border: 0; border-radius: 18px; padding: 12px 15px; background: var(--violet); color: white; text-align: left; }
.thanks-action:not([aria-disabled="true"]):hover { background: var(--action-hover); }
.thanks-action > span:nth-child(2) { display: grid; gap: 3px; }
.thanks-action strong { font-size: 16px; }
.thanks-action[aria-disabled="true"] { background: var(--success-bg); color: var(--success); cursor: default; }
.thanks-status { margin: 10px 0 0; color: var(--success); font-size: 14px; }
.thanks-status:empty { margin: 0; }
.thanks-heart { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 13px; background: rgba(255,255,255,.15); font-size: 19px; }
.feedback-question { margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--line); }
.feedback-question > strong { font-size: 17px; }
.feedback-question > p:not(.feedback-state) { margin: 5px 0 14px; color: var(--muted); font-size: 13px; }
.feedback-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.feedback-button { min-height: 52px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); color: var(--ink); font-size: 14px; font-weight: 850; }
.feedback-button.worked { border-color: #3c7353; background: #183327; color: #9adcb4; }
.feedback-button.failed { border-color: #79434d; background: #3b2229; color: #ffb0b8; }
.feedback-button:disabled { cursor: default; }
.feedback-button:disabled:not(.selected) { opacity: .45; }
.feedback-button.selected { opacity: 1; transform: scale(.98); box-shadow: 0 0 0 2px currentColor inset; }
.feedback-state { margin: 12px 0 0; padding: 10px; border-radius: 11px; background: var(--control); color: var(--muted); font-size: 13px; }
.feedback-state.saved { background: #183327; color: #9adcb4; }
.feedback-state.error { background: #3b2229; color: #ffb0b8; }
.not-used { min-height: 44px; margin-top: 8px; border: 0; background: transparent; color: var(--muted); font-size: 13px; font-weight: 750; }
.not-used:hover { color: var(--ink); }

@media (max-width: 940px) { .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) {
  .shell { width: min(100% - 24px, 1180px); }
  .catalog-page main { padding-top: 108px; }
  .header-inner { height: 66px; }
  .brand-mark { width: 40px; height: 40px; border-radius: 13px; }
  .brand-copy { font-size: 12px; }
  .brand-copy strong { font-size: 15px; }
  .developer-toggle { width: 44px; min-height: 44px; justify-content: center; padding: 0; }
  .developer-toggle b { display: none; }
  .vk-link { padding-right: 9px; }
  .vk-text { display: none; }
  .compact-toolbar { padding: 8px 0; }
  .toolbar-layout { grid-template-columns: 1fr; gap: 7px; }
  .compact-brand { min-width: 0; gap: 9px; }
  .compact-brand-mark { width: 36px; height: 36px; border-radius: 11px; }
  .compact-brand-mark img { width: 100%; height: 100%; }
  .compact-brand-copy strong { font-size: 15px; }
  .compact-brand-copy small { font-size: 12px; }
  .search-box { height: 48px; border-radius: 14px; padding-inline: 12px; }
  .search-box input { font-size: 16px; }
  .search-box kbd { display: none; }
  .category-menu-toggle { flex: none; min-width: 132px; height: 48px; border-radius: 14px; padding-inline: 10px; }
  .category-menu { top: calc(100% + 8px); width: 100%; grid-template-columns: 1fr; max-height: calc(100dvh - 122px); overflow-y: auto; }
  .catalog { padding-top: 12px; }

  .cards { grid-template-columns: 1fr; }
  .promo-card { border-radius: 20px; padding: 16px 16px 0; }
  .card-offer-count { max-width: 96px; }
  .card-open-row { min-height: 58px; margin: 15px -16px 0; padding: 12px 16px; }
  .promo-card .offer-title { min-height: 44px; }
  .offer-title { font-size: 16px; }
  .code-box { grid-template-columns: minmax(88px, 1fr) auto; }
  .link-offer-box { grid-template-columns: 1fr; }
  .link-offer-box > span { padding: 5px 7px 2px; }
  .card-action-box.link-offer-box { grid-template-columns: minmax(0,1fr) auto; }
  .copy-btn { min-height: 50px; padding-inline: 14px; }
  .copy-btn.copy-go { min-width: 157px; }
  .audience-tabs { width: 100%; }
  .audience-tab { flex: 1; padding-inline: 6px; font-size: 12px; }
  .footer-inner { flex-direction: column; align-items: flex-start; justify-content: center; padding: 22px 0; }
  .brand-dialog-backdrop { align-items: end; padding: 0; }
  .brand-dialog { width: 100%; max-height: 92vh; max-height: 92dvh; border: 0; border-radius: 24px 24px 0 0; }
  .brand-dialog-head { padding: 18px 62px 15px 15px; }
  .brand-dialog-logo { width: 50px; height: 50px; border-radius: 15px; }
  .brand-dialog-head h2 { font-size: 22px; }
  .brand-audience-filter { padding: 8px; }
  .brand-audience-filter button { min-height: 34px; padding-inline: 10px; }
  .brand-dialog-offers { padding: 8px; }
  .brand-dialog-offers .offer-item { padding: 15px; border-radius: 16px; }
  .developer-tools { align-items: flex-start; flex-direction: column; }
  .developer-tool-links { justify-content: flex-start; }
  .thanks-dialog { align-self: end; width: 100%; max-height: 92dvh; border-radius: 24px 24px 0 0; padding: 26px 16px 18px; }
}

@media (max-width: 380px) {
  .brand-copy span { display: none; }
  .copy-btn.copy-go { min-width: 148px; padding-inline: 11px; font-size: 12px; }
  .code-value { padding-inline: 7px; font-size: 13px; }
  .card-offer-count { max-width: 88px; padding-inline: 7px; font-size: 10px; }
  .card-open-row { align-items: flex-start; flex-direction: column; gap: 5px; }
  .compact-brand-copy small { display: none; }
}

@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto !important; transition: none !important; } }

/* The fixed header follows its real height, including larger text and safe areas. */
html { scroll-behavior: auto; }
.catalog-page main { padding-top: var(--toolbar-height, 108px); }
.compact-toolbar { padding-top: max(8px, env(safe-area-inset-top)); }
.search-box:focus-within { border-color: var(--violet); box-shadow: 0 0 0 3px var(--soft-violet); }
button:focus-visible, a:focus-visible, summary:focus-visible { outline: 3px solid #8a84ff; outline-offset: 3px; }
.brand-dialog-head { flex: none; min-width: 0; }
.brand-dialog-head > div { min-width: 0; }
.brand-dialog-head h2 { overflow-wrap: anywhere; }
.brand-dialog-offers { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
.thanks-dialog { overscroll-behavior: contain; }
.copied-code { display: block; white-space: normal; overflow-wrap: anywhere; user-select: all; line-height: 1.6; }
.offer-conditions p { overflow-wrap: anywhere; font-size: 14px; }
.offer-conditions summary { min-height: 28px; font-size: 14px; }
.dialog-empty { padding: 18px; line-height: 1.5; color: var(--muted); }
.copy-btn { display: inline-flex; align-items: center; justify-content: center; text-align: center; }
.category-chip small, .tag, .card-offer-count, .code-content small { font-size: 12px; }
@media (min-width: 681px) { .catalog-page main { padding-top: var(--toolbar-height, 77px); } }
@media (max-width: 680px) {
  .audience-tab { font-size: 14px; min-height: 44px; }
  .audience-tab[data-audience="all"] { flex: none; padding-inline: 12px; }
  .brand-audience-filter button { flex: 1; min-width: 0; justify-content: center; font-size: 14px; min-height: 44px; padding: 6px 8px; }
  .brand-audience-filter button[data-brand-audience="all"] { flex: none; }
  .brand-audience-filter { flex-wrap: wrap; }
  .code-box { grid-template-columns: minmax(0, 1fr) auto; }
  .brand-dialog-offers .code-value { white-space: normal; overflow-wrap: anywhere; line-height: 1.4; }
}
@media (max-width: 380px) {
  .code-box:has(.copy-go) { grid-template-columns: 1fr; }
  .code-box:has(.copy-go) .copy-btn { width: 100%; }
  .card-offer-count { font-size: 12px; }
  .search-box svg { width: 18px; height: 18px; }
  .search-box input { padding-inline: 8px; }
}

.catalog-status { padding: 18px; border-radius: 16px; background: var(--soft-violet); color: var(--accent-text); margin: 12px 0 24px; line-height: 1.6; }
.catalog-status button { margin-left: 8px; color: var(--accent-text); font: inherit; font-weight: 700; background: var(--card); border: 1px solid var(--accent-line); border-radius: 10px; padding: 8px 12px; cursor: pointer; }
.catalog-edit-link { display: inline-block; margin-bottom: 12px; font-weight: 700; }

/* Clear input without a second browser-native clear icon. */
.search-box input::-webkit-search-cancel-button { -webkit-appearance: none; }
.search-box { padding-right: 7px; }
.clear-search { display: grid; flex: none; place-items: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 10px; background: transparent; color: var(--muted); }
.clear-search[hidden] { display: none; }
.clear-search:hover { background: var(--control); color: var(--ink); }
.clear-search svg { width: 20px; height: 20px; stroke: currentColor; }
.search-box:has(.clear-search:not([hidden])) kbd { display: none; }
.search-box kbd { margin-right: 7px; }
/* A quiet outline identifies the code; its deadline stays with it. */
.code-box, .link-offer-box { border: 1px solid #59516f; }
.brand-dialog-offers .code-content { gap: 5px; }
.brand-dialog-offers .code-value { font-size: 22px; line-height: 1.3; white-space: normal; overflow-wrap: anywhere; letter-spacing: .025em; }
.brand-dialog-offers .code-expiry { font: 400 13px/1.3 Inter, ui-sans-serif, system-ui, sans-serif; color: var(--muted); }
.offer-action-note { margin: 8px 0 7px; line-height: 1.4; }
.brand-dialog-offers { align-content: start; align-items: start; gap: 12px; }
.brand-dialog-offers .offer-item { border-color: #45495c; }
@media (min-width: 960px) {
  .brand-dialog { width: min(1080px, 100%); }
  .brand-dialog.single-offer { width: min(760px, 100%); }
  .brand-dialog-offers { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: auto; column-gap: 12px; padding: 16px; }
  .brand-dialog.single-offer .brand-dialog-offers { grid-auto-rows: auto; }
  .brand-dialog.single-offer .brand-dialog-offers { grid-template-columns: 1fr; }
  .brand-dialog-offers .offer-item { min-width: 0; padding: 14px; }
  .brand-dialog-offers .offer-title { font-size: 16px; line-height: 1.4; }
  .brand-dialog-offers .copy-btn { padding-inline: 12px; align-self: center; }
  .brand-dialog-offers .copy-go { min-width: 0; max-width: 158px; line-height: 1.3; padding-block: 10px; }
  .brand-dialog-offers .offer-conditions { margin-top: 10px; padding-top: 8px; }
  .brand-dialog-offers .offer-conditions p { margin-top: 6px; }
  .dialog-empty { grid-column: 1 / -1; }
}
@media (max-width: 680px) {
  .search-row { gap: 8px; }
  .search-box { padding-left: 10px; padding-right: 2px; }
  .search-box input { padding-inline: 8px; }
  .search-box svg { width: 18px; height: 18px; }
  .clear-search { width: 36px; height: 40px; }
  .search-box:has(.clear-search:not([hidden])) > svg { display: none; }
  .category-menu-toggle { gap: 7px; font-size: 14px; }
}

.region-toggle { gap: 6px; border: 1px solid transparent; cursor: pointer; font: inherit; font-size: 12px; font-weight: 850; }
.region-toggle:hover, .region-toggle[aria-expanded="true"] { border-color: var(--info); }
.region-details { position: fixed; inset: auto; z-index: 100; margin: 0; overflow: auto; overscroll-behavior: contain; border: 1px solid var(--accent-line); box-shadow: 0 14px 40px #0008; padding: 12px 14px; border-radius: 11px; background: var(--info-bg); color: var(--info); font-size: 14px; line-height: 1.5; }
.region-details[hidden] { display: none; }
.region-details strong { font-size: 13px; }
.region-details p { margin: 3px 0 0; overflow-wrap: anywhere; }

.offer-title strong { font-weight: 600; color: var(--ink); }
.code-value { font-size: 19px; }
.code-content { padding-block: 8px; }
.brand-dialog-offers { overflow-anchor: none; }
.brand-dialog-offers .offer-item { overflow-anchor: none; }
.brand-dialog-offers .code-box { align-items: center; }
.offer-footer { position: relative; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.offer-footer > .expiry { display: block; padding-right: 155px; font-size: 12px; line-height: 20px; }
.offer-footer .offer-conditions { margin: 0; padding: 0; border: 0; }
.offer-footer .offer-conditions summary { position: absolute; right: 0; top: 10px; min-height: 20px; font-size: 13px; line-height: 20px; }
.offer-footer .offer-conditions summary::after { display: none; }
.offer-footer .offer-conditions p { margin-top: 10px; }
.offer-footer:not(:has(.offer-conditions)) > .expiry { padding-right: 0; }
@media (min-width: 960px) {
  .brand-dialog-offers .offer-footer .offer-conditions { margin: 0; padding: 0; }
}
@media (max-width: 380px) {
  .offer-footer > .expiry { padding-right: 0; }
  .offer-footer .offer-conditions summary { position: static; margin-top: 5px; }
}

/* Keep the service heading anchored while conditions grow below it. */
.brand-dialog-backdrop { align-items: start; padding-top: 6dvh; }
.brand-dialog-head { flex: none; }
.brand-dialog-offers { scrollbar-gutter: stable; }
.tag.new, .tag.any { color: #9adcb4; background: #183327; }
@media (min-width: 960px) {
  .brand-dialog-offers.independent-columns { grid-auto-rows: 1px; row-gap: 0; }
}
@media (max-width: 680px) {
  .brand-dialog-backdrop { padding-top: 8dvh; }
}

.offer-title { font-family: system-ui, -apple-system, "Segoe UI", sans-serif; letter-spacing: normal; }
.copy-heading { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; text-align: left; }
.copy-heading .copy-success-icon { width: 32px; height: 32px; margin: 0; border-radius: 10px; font-size: 20px; font-weight: 600; }
.copy-heading h2 { font-size: clamp(16px, 4.6vw, 22px); line-height: 1.3; font-weight: 600; letter-spacing: -.015em; }
.copy-heading .dialog-close { position: static; width: 32px; height: 32px; font-size: 23px; }
.thanks-action { min-height: 70px; padding: 12px 14px; }
.thanks-action strong { font-size: 18px; line-height: 1.25; font-weight: 650; }
.thanks-action[aria-disabled="true"] { background: var(--success-bg); color: var(--success); cursor: default; }
.thanks-status { margin: 10px 0 0; color: var(--success); font-size: 14px; }
.thanks-status:empty { margin: 0; }
.thanks-heart { width: 36px; height: 36px; font-size: 20px; }
.feedback-actions { margin-top: 14px; }
.feedback-button { font-weight: 600; }
@media (max-width: 380px) {
  .copy-heading { gap: 7px; }
  .copy-heading .copy-success-icon, .copy-heading .dialog-close { width: 28px; height: 28px; }
  .thanks-action { gap: 10px; padding-inline: 14px; }
  .thanks-action strong { font-size: 18px; }
}

.offer-audience-note { margin: -5px 0 13px; color: var(--muted); font-size: 14px; font-weight: 400; line-height: 1.45; }

/* Compact post-copy dialog: explicit closing and confirmed votes. */
.thanks-dialog{width:min(100%,420px);padding:24px;border:1px solid #2c2e3b;border-radius:24px}.thanks-dialog .copy-heading{margin-bottom:16px}.thanks-dialog #thanks-title{font-size:20px;line-height:1.3;letter-spacing:-.35px}.thanks-dialog #copied-code[hidden],#feedback-choices[hidden],#feedback-confirmation[hidden]{display:none}.thanks-dialog .feedback-question{border:0;margin:0 0 16px;padding:0;min-height:108px;display:flex;flex-direction:column;justify-content:center}.thanks-dialog .feedback-actions{gap:10px}.thanks-dialog .feedback-actions button{min-height:46px;font:inherit;font-size:14px;font-weight:650;border-radius:11px;flex:1;cursor:pointer}.feedback-confirm-label{margin:0 0 10px;font-size:14px;font-weight:650;line-height:20px}.feedback-cancel{background:#292b37;border:1px solid #424451;color:#d4d5df}.feedback-submit{background:#7055ed;color:#fff;border:1px solid #7055ed}.feedback-submit:disabled,.feedback-cancel:disabled{opacity:.5;cursor:default}.thanks-dialog .feedback-state{font-size:12px;line-height:16px;margin:10px 0 0}.thanks-dialog .thanks-action{min-height:56px;margin:0}.thanks-dialog .thanks-status:empty{display:none}.copy-done{width:100%;min-height:44px;margin-top:12px;border:1px solid #424451;border-radius:11px;background:transparent;color:#ccceda;font:inherit;font-size:14px;cursor:pointer}.copy-done:focus-visible,.feedback-submit:focus-visible,.feedback-cancel:focus-visible{outline:2px solid #baaaff;outline-offset:3px}.feedback-button.selected{outline:2px solid currentColor;outline-offset:2px}
@media(max-width:680px){#thanks-dialog{place-items:center;padding:16px}.thanks-dialog{align-self:center;max-height:calc(100dvh - 32px);padding:22px 18px;border-radius:24px}.thanks-dialog #thanks-title{font-size:18px}.thanks-dialog .feedback-actions button{font-size:14px}}
.offer-key-facts{overflow-wrap:anywhere}.offer-item .tag,.card-offer .tag{white-space:normal}
