/* Hot Deals for Heroes — colors taken from the supplied logo.
   Logo rule: the logo only ever sits on white or the soft light-blue bar. */
:root {
  --blue: #0080c1;        /* HOT letters */
  --blue-dark: #12517a;   /* HOT letters, shadow side */
  --flame: #f7931e;       /* flame / price tag */
  --flame-red: #f25721;   /* flame tip */
  --cta: #d4461a;         /* flame red, deepened for readable white text */
  --red: #a8272c;         /* "4 HEROES" */
  --sky: #eaf4fb;         /* soft light-blue bar */
  --ink: #1b2a3a;
  --muted: #5b6b7b;
  --line: #dbe5ee;
  --bg: #f7fafc;
  --card: #ffffff;
  --ok: #1d7a46;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(18, 81, 122, .06), 0 4px 14px rgba(18, 81, 122, .07);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  -webkit-text-size-adjust: 100%;
}
* { box-sizing: border-box; }
html { scroll-padding-top: 100px; }
body { margin: 0; background: var(--bg); line-height: 1.5; min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1; padding-top: 18px; padding-bottom: 40px; outline: none; }
a { color: var(--blue-dark); }
img { max-width: 100%; }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 8px; top: 8px; background: #fff; padding: 8px 12px; z-index: 100; border-radius: 8px; }
:focus-visible { outline: 3px solid var(--flame); outline-offset: 2px; }

/* ---------- header ---------- */
.topbar { background: var(--sky); border-bottom: 1px solid #d3e6f4; position: sticky; top: 0; z-index: 20; padding-top: env(safe-area-inset-top); }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 84px; padding-top: 6px; padding-bottom: 6px; }
.brand img { display: block; height: 72px; width: auto; }
.topnav { display: flex; align-items: center; gap: 6px; }
.navlink { text-decoration: none; font-weight: 600; color: var(--blue-dark); padding: 8px 10px; border-radius: 10px; }
.navlink:hover, .navlink[aria-current="page"] { background: #fff; }
@media (max-width: 560px) {
  .brand img { height: 58px; }
  .topbar-inner { min-height: 72px; }
  .navlink.hide-sm { display: none; }
  .navlink { padding: 8px 8px; }
}

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 12px; font: inherit; font-weight: 700; padding: 12px 18px; cursor: pointer; text-decoration: none; min-height: 46px; line-height: 1.2; }
.btn-sm { min-height: 40px; padding: 8px 14px; font-size: .95rem; }
.btn-cta { background: var(--cta); color: #fff; }
.btn-cta:hover { background: #b93a12; }
.btn-blue { background: var(--blue-dark); color: #fff; }
.btn-blue:hover { background: #0d3f60; }
.btn-ghost { background: #fff; color: var(--blue-dark); border: 1.5px solid var(--line); }
.btn-ghost:hover { border-color: var(--blue); }
.btn-ok { background: var(--ok); color: #fff; }
.btn-danger { background: #fff; color: var(--red); border: 1.5px solid #e7c3c5; }
.btn-danger:hover { background: #fdf2f2; }
.btn[disabled] { opacity: .6; cursor: default; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; }

/* ---------- home ---------- */
.hero { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 20px; margin-bottom: 18px; border-top: 5px solid var(--flame); }
.hero h1 { margin: 0 0 6px; font-size: clamp(1.45rem, 4vw, 2rem); color: var(--blue-dark); line-height: 1.2; }
.hero p { margin: 0 0 14px; color: var(--muted); }
.hero .who { color: var(--red); font-weight: 700; letter-spacing: .02em; }
.search { display: flex; gap: 8px; }
.search input { flex: 1; min-width: 0; }
.notice { background: #fff8ec; border: 1px solid #f6d8a8; color: #7a4a06; padding: 10px 14px; border-radius: 12px; margin: 0 0 16px; font-size: .95rem; }
.section-title { display: flex; align-items: baseline; justify-content: space-between; margin: 22px 0 10px; }
.section-title h2 { margin: 0; font-size: 1.2rem; color: var(--blue-dark); }
.cats { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.cat { display: flex; align-items: center; gap: 10px; background: #fff; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px; text-decoration: none; color: var(--ink); font-weight: 600; }
.cat:hover, .cat[aria-current="true"] { border-color: var(--blue); background: #f4faff; }
.cat .ico { font-size: 1.35rem; }
.cat .n { margin-left: auto; color: var(--muted); font-weight: 500; font-size: .85rem; }

/* ---------- deal cards ---------- */
.deals { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.deal-card { position: relative; display: flex; flex-direction: column; background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; text-decoration: none; color: var(--ink); border: 1.5px solid transparent; }
.deal-card:hover { border-color: var(--blue); }
.deal-card .cat-label { font-size: .8rem; font-weight: 700; color: var(--blue); text-transform: uppercase; letter-spacing: .04em; }
.deal-card h3 { margin: 6px 0 4px; font-size: 1.15rem; line-height: 1.25; color: var(--ink); }
.deal-card .biz { font-weight: 600; color: var(--blue-dark); }
.deal-card .meta { margin-top: auto; padding-top: 10px; color: var(--muted); font-size: .88rem; display: flex; justify-content: space-between; gap: 8px; }
.tag { display: inline-block; font-size: .72rem; font-weight: 800; letter-spacing: .06em; padding: 3px 8px; border-radius: 999px; vertical-align: middle; }
.tag-sample { background: #fff1d6; color: #8a5300; border: 1px dashed #d99a2b; }
.tag-featured { background: var(--flame); color: #3a1d00; }
.deal-card .card-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px; }
.deal-card .tags { display: flex; gap: 6px; }
.empty { background: #fff; border-radius: var(--radius); padding: 28px 20px; text-align: center; color: var(--muted); box-shadow: var(--shadow); }

/* ---------- deal page ---------- */
.back { display: inline-block; margin-bottom: 12px; text-decoration: none; font-weight: 600; }
.deal-page { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.deal-head { padding: 22px 20px 18px; border-bottom: 1px solid var(--line); border-top: 5px solid var(--flame); }
.deal-head .cat-label { font-size: .85rem; font-weight: 700; color: var(--blue); text-transform: uppercase; letter-spacing: .04em; }
.deal-head h1 { margin: 6px 0 4px; font-size: clamp(1.5rem, 4.5vw, 2.1rem); line-height: 1.15; color: var(--ink); }
.deal-head .biz { font-size: 1.1rem; font-weight: 700; color: var(--blue-dark); margin: 0; }
.deal-actions { padding: 16px 20px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; border-bottom: 1px solid var(--line); background: #fbfdff; }
.deal-actions .btn { width: 100%; }
.deal-body { padding: 18px 20px 22px; }
.deal-body h2 { font-size: 1rem; margin: 18px 0 4px; color: var(--blue-dark); }
.deal-body h2:first-child { margin-top: 0; }
.deal-body p { margin: 0; white-space: pre-line; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin: 18px 0 0; padding: 0; list-style: none; }
.facts li { background: var(--bg); border-radius: 12px; padding: 10px 12px; }
.facts b { display: block; font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.claim { margin-top: 18px; background: var(--sky); border-radius: 12px; padding: 12px 14px; }

/* ---------- forms ---------- */
.panel { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 22px 20px; }
.panel h1 { margin: 0 0 6px; color: var(--blue-dark); font-size: clamp(1.4rem, 4vw, 1.8rem); }
.lead { color: var(--muted); margin: 0 0 18px; }
fieldset { border: 0; padding: 0; margin: 0 0 8px; }
legend { font-weight: 800; color: var(--red); letter-spacing: .03em; text-transform: uppercase; font-size: .85rem; margin-bottom: 8px; padding: 0; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
@media (max-width: 640px) { .grid2 { grid-template-columns: 1fr; } }
.field { margin-bottom: 14px; }
label { display: block; font-weight: 600; margin-bottom: 4px; }
.opt { font-weight: 400; color: var(--muted); }
.hint { font-size: .85rem; color: var(--muted); margin-top: 3px; }
input, select, textarea { width: 100%; font: inherit; padding: 11px 12px; border: 1.5px solid #c9d6e2; border-radius: 10px; background: #fff; color: var(--ink); min-height: 46px; }
textarea { min-height: 110px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--blue); outline: 3px solid rgba(0, 128, 193, .18); outline-offset: 0; }
.err { color: #b3261e; font-size: .88rem; margin-top: 3px; font-weight: 600; }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #b3261e; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.check input { width: 22px; min-height: 22px; height: 22px; margin-top: 2px; flex: none; }
.privacy { font-size: .88rem; background: var(--bg); border-radius: 10px; padding: 10px 12px; color: var(--muted); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.form-error { background: #fdecea; color: #8c1d18; border-radius: 10px; padding: 10px 12px; margin-bottom: 14px; font-weight: 600; }
.success { text-align: center; padding: 30px 20px; }
.success .big { font-size: 2.6rem; }

/* ---------- about / login ---------- */
.logo-white { background: #fff; display: flex; justify-content: center; padding: 6px 0 2px; }
.logo-white img { width: min(360px, 90%); height: auto; }
.steps { padding-left: 20px; }
.steps li { margin-bottom: 8px; }
.login { max-width: 420px; margin: 10px auto; }

/* ---------- admin ---------- */
.admin-top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.admin-top h1 { margin: 0; color: var(--blue-dark); font-size: 1.5rem; }
.tabs { display: flex; gap: 6px; overflow-x: auto; margin-bottom: 14px; padding-bottom: 2px; }
.tab { border: 1.5px solid var(--line); background: #fff; border-radius: 999px; padding: 8px 14px; font: inherit; font-weight: 600; cursor: pointer; white-space: nowrap; color: var(--ink); }
.tab[aria-selected="true"] { background: var(--blue-dark); border-color: var(--blue-dark); color: #fff; }
.tab .c { opacity: .75; margin-left: 4px; }
.admin-list { display: grid; gap: 12px; }
.arow { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 14px 16px; border-left: 5px solid var(--line); }
.arow.s-pending { border-left-color: var(--flame); }
.arow.s-approved { border-left-color: var(--ok); }
.arow.s-rejected, .arow.s-removed { border-left-color: #9aa7b4; }
.arow-head { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: baseline; }
.arow-head h3 { margin: 0; font-size: 1.08rem; }
.status { font-size: .75rem; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; padding: 2px 8px; border-radius: 999px; }
.st-pending { background: #fff1d6; color: #8a5300; }
.st-approved { background: #e3f4ea; color: var(--ok); }
.st-rejected, .st-removed, .st-expired { background: #eef1f4; color: #4d5b69; }
.arow .sub { color: var(--muted); font-size: .9rem; margin: 2px 0 8px; }
.arow dl { display: grid; grid-template-columns: max-content 1fr; gap: 2px 12px; margin: 0 0 10px; font-size: .92rem; }
.arow dt { color: var(--muted); }
.arow dd { margin: 0; white-space: pre-line; word-break: break-word; }
.arow .btn-row .btn { min-height: 38px; padding: 7px 12px; font-size: .9rem; }
.inline-box { margin-top: 10px; background: var(--bg); border-radius: 10px; padding: 10px; }
.inline-box pre { margin: 0; white-space: pre-wrap; font-size: .8rem; max-height: 280px; overflow: auto; }
.dialog-back { position: fixed; inset: 0; background: rgba(15, 30, 45, .45); display: flex; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 24px 12px; z-index: 50; }
.dialog { background: #fff; border-radius: var(--radius); width: min(720px, 100%); padding: 20px; }

/* ---------- footer / toast ---------- */
.footer { background: #fff; border-top: 1px solid var(--line); padding: 20px 0 calc(24px + env(safe-area-inset-bottom)); font-size: .92rem; color: var(--muted); }
.footer p { margin: 0 0 6px; }
.footer-main { color: var(--ink); }
.footer .fine { font-size: .8rem; margin-top: 10px; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%) translateY(140%); opacity: 0; visibility: hidden; transition: transform .25s, opacity .25s, visibility .25s; background: var(--blue-dark); color: #fff; padding: 10px 16px; border-radius: 10px; z-index: 60; max-width: 90vw; }
.toast.show { transform: translateX(-50%) translateY(0); opacity: 1; visibility: visible; }
.loading { color: var(--muted); padding: 30px 0; text-align: center; }

/* ---------- map (v2) ---------- */
.title-side { display: inline-flex; align-items: center; gap: 10px; }
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 2px 8px; margin: 0 -2px; scrollbar-width: thin; }
.chip { flex: none; border: 1.5px solid var(--line); background: #fff; color: var(--ink); border-radius: 999px; padding: 8px 14px; font: inherit; font-weight: 600; font-size: .92rem; cursor: pointer; white-space: nowrap; min-height: 40px; }
.chip:hover { border-color: var(--blue); }
.chip[aria-pressed="true"] { background: var(--blue-dark); border-color: var(--blue-dark); color: #fff; }
.map-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 6px 0 12px; }
.city-filter { display: inline-flex; align-items: center; gap: 8px; margin-top: 12px; }
.city-filter label { font-weight: 600; white-space: nowrap; }
.city-filter select { width: auto; min-width: 180px; min-height: 44px; }
.map-tools .city-filter { margin-top: 0; }
.browse-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 12px; }
.browse-controls .city-filter { margin-top: 0; }
.radius-filter { display: inline-flex; align-items: center; gap: 8px; }
.radius-filter label { font-weight: 600; white-space: nowrap; }
.radius-filter select { width: auto; min-width: 170px; min-height: 44px; }
.map-tools .radius-filter { margin-top: 0; }
.radius-active { font-weight: 600; color: var(--blue-dark); margin: 0 0 12px; }
.radius-status { min-height: 1.2em; }
.map-wrap { position: relative; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); background: #e9eef2; }
.map-box { position: relative; z-index: 0; height: min(62vh, 560px); min-height: 360px; width: 100%; } /* own stacking layer, so the deal card always sits above pins */
.map-box .loading { padding-top: 120px; }
.map-legend { display: flex; align-items: center; gap: 6px; margin: 8px 2px 0; white-space: pre; }
.legend-pin { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: #fff; border: 2px solid var(--blue-dark); color: var(--blue-dark); font-size: .6rem; }
.legend-featured { background: linear-gradient(160deg, var(--flame), var(--flame-red)); border-color: #fff; box-shadow: 0 0 0 2px var(--flame-red); font-size: .75rem; }

/* pins (rendered inside Google's markers; anchored at the bottom tip) */
.pin { position: relative; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: #fff; border: 3px solid var(--blue-dark); box-shadow: 0 2px 6px rgba(0,0,0,.28); margin-bottom: 8px; cursor: pointer; transition: transform .15s; }
.pin::after { content: ""; position: absolute; left: 50%; bottom: -11px; transform: translateX(-50%); border: 7px solid transparent; border-top: 9px solid var(--blue-dark); border-bottom: 0; }
.pin-ico { font-size: 17px; line-height: 1; }
.pin-featured { width: 52px; height: 52px; border: 3px solid #fff; background: linear-gradient(160deg, var(--flame) 0%, var(--flame-red) 100%); box-shadow: 0 0 0 3px var(--flame-red), 0 4px 12px rgba(242, 87, 33, .55); margin-bottom: 11px; }
.pin-featured::after { bottom: -14px; border-left: 9px solid transparent; border-right: 9px solid transparent; border-top: 12px solid var(--flame-red); border-bottom: 0; }
.pin-featured .pin-ico { font-size: 26px; }
.pin-featured::before { content: ""; position: absolute; inset: -9px; border-radius: 50%; border: 3px solid rgba(247, 147, 30, .55); animation: pin-pulse 2s ease-out infinite; }
@keyframes pin-pulse { 0% { transform: scale(.9); opacity: 1; } 100% { transform: scale(1.35); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .pin-featured::before { animation: none; opacity: .6; } }
.pin-selected { transform: scale(1.18); border-color: var(--cta); }
.pin-featured.pin-selected { border-color: #fff; }
.you-dot { width: 18px; height: 18px; border-radius: 50%; background: #1a73e8; border: 3px solid #fff; box-shadow: 0 0 0 6px rgba(26, 115, 232, .25); transform: translateY(9px); }

/* tapped-pin summary */
.map-card-slot { position: absolute; z-index: 5; left: 12px; right: 12px; bottom: 12px; pointer-events: none; display: flex; justify-content: center; }
.map-card { pointer-events: auto; position: relative; background: #fff; border-radius: var(--radius); box-shadow: 0 6px 24px rgba(15, 40, 65, .25); padding: 14px 16px; width: min(440px, 100%); border-top: 4px solid var(--flame); }
.map-card h3 { margin: 6px 30px 2px 0; font-size: 1.1rem; line-height: 1.25; }
.map-card .biz { font-weight: 700; color: var(--blue-dark); }
.map-card .cat-label { font-size: .78rem; font-weight: 700; color: var(--blue); text-transform: uppercase; letter-spacing: .04em; }
.map-card .card-top { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; padding-right: 30px; }
.map-card .tags { display: flex; gap: 6px; }
.map-card-meta { display: flex; flex-wrap: wrap; gap: 4px 14px; color: var(--muted); font-size: .9rem; margin: 6px 0 10px; }
.map-card .btn-row .btn { min-height: 40px; }
.map-card-x { position: absolute; top: 8px; right: 8px; width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--bg); font-size: 1rem; cursor: pointer; color: var(--muted); }
@media (max-width: 899px) {
  .map-card { padding: 12px 14px; }
  .map-card h3 { font-size: 1.02rem; }
  .map-card-meta { margin: 4px 0 8px; font-size: .85rem; }
  .map-card .hint { display: none; }
  .map-card .btn-row { gap: 8px; }
  .map-card .btn-row .btn { min-height: 38px; padding: 6px 10px; font-size: .88rem; }
}
@media (min-width: 900px) { .map-card-slot { left: auto; right: 16px; top: 16px; bottom: auto; width: 400px; } }

.map-fallback { height: 100%; min-height: 360px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 12px; padding: 24px; color: var(--ink); background: var(--sky); }
.map-soon .btn-row.center, .btn-row.center { justify-content: center; }
main.wrap { padding-top: 18px; padding-bottom: 40px; } /* .wrap's side padding was overriding main's top/bottom spacing */
