/* Flash Deals CO — dark neon, un solo tema. */
:root {
  --bg: #1A0B2E;
  --surface: #241043;
  --surface-2: #2E1657;
  --line: #3F2477;
  --neon: #9B4DFF;
  --orange: #FF7A1A;
  --orange-ink: #1A0B2E;
  --coral: #FF5A5F;
  --fg: #F6F0FF;
  --muted: #B9ABDA;
  --ok: #4ADE80;
  --font-display: "Orbitron", "Arial Black", system-ui, sans-serif;
  --font-body: "Exo 2", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 80px; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--bg) radial-gradient(60rem 30rem at 85% -10%, rgba(155,77,255,.22), transparent 60%) no-repeat;
  color: var(--fg);
  font: 16px/1.5 var(--font-body);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
img { max-width: 100%; }
[hidden] { display: none !important; }
a { color: inherit; }
button { font: inherit; color: inherit; cursor: pointer; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
.wrap { width: 100%; max-width: 72rem; margin-inline: auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }

/* top bar */
.bar { position: sticky; top: 0; z-index: 20; padding-top: env(safe-area-inset-top, 0px); background: rgba(26,11,46,.92); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.bar .wrap { display: flex; align-items: center; gap: 12px 16px; padding-block: 10px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.logo-ico { height: 44px; width: auto; flex: none; mix-blend-mode: lighten; }
.brand b { font-family: var(--font-display); font-weight: 900; font-size: 1.05rem; letter-spacing: .02em; line-height: 1; display: block; color: var(--orange); }
.brand span { font-family: var(--font-display); font-weight: 700; font-size: .72rem; letter-spacing: .12em; color: var(--fg); display: block; margin-top: 3px; }
.search { flex: 1 1 14rem; min-width: 0; }
.search input { width: 100%; min-width: 0; background: var(--surface); border: 1px solid var(--line); color: var(--fg); border-radius: 999px; padding: 9px 16px; font: inherit; }
.search input::placeholder { color: var(--muted); }
.social { display: flex; gap: 8px; flex-wrap: wrap; }
.btn { border: 1px solid var(--neon); background: transparent; color: var(--fg); border-radius: 999px; padding: 8px 14px; font-weight: 600; font-size: .9rem; text-decoration: none; display: inline-flex; align-items: center; gap: 6px; }
.btn:hover { background: rgba(155,77,255,.18); }
.btn[aria-disabled="true"] { opacity: .6; cursor: not-allowed; }
.btn-hot { background: var(--orange); border-color: var(--orange); color: var(--orange-ink); }
.btn-hot:hover { background: #ff8f3a; }

/* hero */
.hero { padding-block: 36px 20px; }
.hero-wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.hero-logo { width: min(26rem, 100%); height: auto; mix-blend-mode: lighten; }
.hero h1 { font-family: var(--font-display); font-weight: 900; font-size: clamp(1.6rem, 4.6vw, 2.8rem); line-height: 1.12; margin: 0 0 12px; max-width: 18ch; text-wrap: balance; }
.hero h1 em { font-style: normal; color: var(--orange); text-shadow: 0 0 24px rgba(255,122,26,.45); }
.hero p { color: var(--muted); max-width: 52ch; margin: 0 0 20px; }
.hero .cta { display: flex; gap: 10px; flex-wrap: wrap; }
.hero .btn-hot { padding: 11px 22px; font-size: 1rem; }

/* tabs + chips */
.controls { padding-block: 8px 0; display: grid; gap: 14px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { background: none; border: 0; padding: 10px 18px; font-family: var(--font-display); font-weight: 700; font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); border-bottom: 3px solid transparent; white-space: nowrap; }
.tab[aria-selected="true"] { color: var(--fg); border-bottom-color: var(--orange); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: .88rem; color: var(--muted); }
.chip[aria-pressed="true"] { background: var(--neon); border-color: var(--neon); color: #fff; }
.notice { margin: 16px 0 0; padding: 10px 14px; border: 1px dashed var(--neon); border-radius: 8px; color: var(--muted); font-size: .88rem; }

/* grid */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 16px; padding-block: 20px 36px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; display: flex; flex-direction: column; min-width: 0; overflow: hidden; cursor: pointer; content-visibility: auto; contain-intrinsic-size: auto 380px; }
@media (prefers-reduced-motion: no-preference) { .card { transition: transform .15s ease, border-color .15s ease; } .card:hover { transform: translateY(-2px); border-color: var(--neon); } }
.thumb, .d-thumb { position: relative; display: grid; place-items: center; overflow: hidden; background: linear-gradient(135deg, var(--surface-2), #1f0d3a); }
.thumb { aspect-ratio: 16 / 10; border-bottom: 1px solid var(--line); }
.thumb svg, .d-thumb svg { stroke: var(--neon); fill: none; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 8px rgba(155,77,255,.6)); }
.thumb svg { width: 64px; height: 64px; stroke-width: 1.6; }
.pimg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: #fff; display: block; }
.off { position: absolute; top: 10px; left: 10px; background: var(--coral); color: #fff; font-family: var(--font-display); font-weight: 700; font-size: .8rem; padding: 4px 8px; border-radius: 6px; }
.tag-c, .tag-k { position: absolute; right: 10px; background: rgba(26,11,46,.85); font-size: .72rem; padding: 3px 8px; border-radius: 999px; }
.tag-c { top: 10px; border: 1px solid var(--ok); color: var(--ok); }
.tag-k { top: 40px; border: 1px solid var(--orange); color: var(--orange); }
.body { padding: 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.meta { display: flex; justify-content: space-between; gap: 8px; font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.card h3 { margin: 0; font-size: 1rem; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.card-link { text-decoration: none; }
.card-link:hover { text-decoration: underline; }
.price, .d-price { display: flex; align-items: baseline; flex-wrap: wrap; font-variant-numeric: tabular-nums; }
.price { gap: 10px; }
.price b { font-family: var(--font-display); font-size: 1.35rem; }
.price s, .d-price s { color: var(--muted); }
.price s { font-size: .9rem; }
.cop { font-size: .78rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.row { margin-top: auto; display: flex; align-items: center; gap: 10px; padding-top: 6px; }
.row .btn-hot { flex: 1; justify-content: center; }
.votes { display: flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.vote { background: none; border: 0; padding: 7px 10px; font-size: .82rem; font-variant-numeric: tabular-nums; color: var(--muted); }
.vote[aria-pressed="true"].up { background: rgba(255,122,26,.22); color: var(--orange); }
.vote[aria-pressed="true"].down { background: rgba(155,77,255,.25); color: #cdb0ff; }
.empty { grid-column: 1 / -1; text-align: center; color: var(--muted); padding: 40px 0; }

/* coupons */
.coupons { display: grid; gap: 12px; padding-block: 20px 36px; grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr)); }
.coupon { background: var(--surface); border: 1px dashed var(--orange); border-radius: 10px; padding: 14px; display: grid; gap: 8px; min-width: 0; }
.coupon h3 { margin: 0; font-size: 1rem; font-weight: 600; }
.coupon p { margin: 0; color: var(--muted); font-size: .88rem; }
.coupon .btn { width: fit-content; }
.code { display: flex; gap: 8px; align-items: center; }
.code code { flex: 1; min-width: 0; background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 7px 10px; font-family: var(--font-display); font-size: .85rem; letter-spacing: .08em; overflow-wrap: anywhere; user-select: all; }

footer { border-top: 1px solid var(--line); padding-block: 24px 36px; color: var(--muted); font-size: .85rem; }
footer p { margin: 0 0 8px; max-width: 70ch; }

/* detail */
.detail { padding-block: 20px 40px; display: grid; gap: 28px; }
.back { color: var(--muted); text-decoration: none; font-size: .9rem; width: fit-content; }
.back:hover { color: var(--fg); }
.d-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 24px; align-items: start; }
@media (max-width: 720px) { .d-top { grid-template-columns: minmax(0, 1fr); } }
.d-thumb { aspect-ratio: 4 / 3; border: 1px solid var(--line); border-radius: 10px; }
.d-thumb svg { width: 120px; height: 120px; stroke-width: 1.4; }
.d-info { display: grid; gap: 12px; min-width: 0; }
.d-info h1 { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.25rem, 3.4vw, 1.8rem); line-height: 1.2; margin: 0; overflow-wrap: anywhere; text-wrap: balance; }
.d-price { gap: 12px; }
.d-price b { font-family: var(--font-display); font-size: 1.9rem; }
.d-info .row { margin-top: 0; flex-wrap: wrap; }
.d-info .row .btn-hot { flex: 0 1 auto; padding: 11px 22px; }
.pill { display: inline-block; border: 1px solid var(--ok); color: var(--ok); border-radius: 999px; font-size: .75rem; padding: 2px 10px; width: fit-content; }
.pill.no { border-color: var(--muted); color: var(--muted); }
.pill.kp { border-color: var(--orange); color: var(--orange); }
.linkbox { border: 1px solid var(--line); background: var(--surface); border-radius: 10px; padding: 12px; display: grid; gap: 8px; min-width: 0; }
.lbl { font-size: .75rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.linkbox code { font-size: .8rem; word-break: break-all; }
.sec h2 { font-family: var(--font-display); font-size: 1.05rem; letter-spacing: .04em; margin: 0 0 10px; }
.sec p { margin: 0 0 10px; max-width: 65ch; }
.sec ul { margin: 0; padding-left: 1.2rem; display: grid; gap: 4px; }

/* comments */
.cform { display: grid; gap: 8px; max-width: 40rem; }
.cform textarea { width: 100%; min-height: 84px; resize: vertical; background: var(--surface); border: 1px solid var(--line); color: var(--fg); border-radius: 8px; padding: 10px 12px; font: inherit; }
.cform .actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.status { color: var(--muted); font-size: .88rem; margin: 0; }
.clist { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 10px; max-width: 40rem; }
.cmt { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px; display: grid; gap: 4px; min-width: 0; }
.cmt .who { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; font-size: .85rem; color: var(--muted); }
.cmt .who b { color: var(--fg); }
.cmt p { margin: 0; overflow-wrap: anywhere; white-space: pre-wrap; }
.cmt .del { margin-left: auto; background: none; border: 0; color: var(--muted); font-size: .8rem; text-decoration: underline; }

/* admin */
.adminbar { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; border-top: 1px dashed var(--line); padding-top: 10px; }
.adm { position: fixed; inset: 0; z-index: 40; background: rgba(10,4,20,.82); overflow: auto; padding: max(16px, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) max(16px, env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px)); }
.adm-box { max-width: 40rem; margin: 0 auto; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 18px; display: grid; gap: 14px; }
.adm-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.adm-head h2 { margin: 0; font-family: var(--font-display); font-size: 1.1rem; }
.adm-form { display: grid; gap: 6px; }
.adm-form label { font-size: .78rem; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-top: 8px; }
.adm-form input, .adm-form select, .adm-form textarea { width: 100%; min-width: 0; background: var(--bg); border: 1px solid var(--line); color: var(--fg); border-radius: 8px; padding: 9px 12px; font: inherit; }
.adm-form .two { display: grid; grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr)); gap: 12px; }
.adm-form .hint { margin: 0; font-size: .85rem; color: var(--ok); overflow-wrap: anywhere; }
.adm-form .prev { max-width: 12rem; max-height: 12rem; border-radius: 8px; background: #fff; object-fit: contain; }
.adm-form .actions { margin-top: 10px; }
.adm-box h3 { margin: 0 0 6px; font-family: var(--font-display); font-size: .95rem; }
.hrow { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 6px 0; border-top: 1px solid var(--line); }
.hrow span { min-width: 0; overflow-wrap: anywhere; font-size: .9rem; }
