:root {
  color-scheme: light dark;
  --bg: #ffffff;
  --surface: #f7f7f8;
  --fg: #16181d;
  --muted: #5d6470;
  --border: #e3e4e8;
  --accent: #0b6b3a;
  --accent-fg: #ffffff;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #101214;
    --surface: #171a1e;
    --fg: #e9eaee;
    --muted: #9aa1ac;
    --border: #2a2f36;
    --accent: #57d38c;
    --accent-fg: #0b1a12;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 16px/1.55 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
a:hover { color: var(--accent); }

.site-header,
main,
.site-footer {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 20px;
}

.site-header { padding-top: 48px; }

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: clamp(340px, 34vw, 520px);
  overflow: hidden;
  border-bottom: 1px solid var(--border);
}

.hero-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 68% 50%;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(8, 13, 22, 0.94) 0%, rgba(8, 13, 22, 0.86) 32%, rgba(8, 13, 22, 0.42) 56%, rgba(8, 13, 22, 0.05) 76%, transparent 100%);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 64px 20px;
}

.hero .eyebrow { color: #ffd866; }
.hero h1 { color: #ffffff; }
.hero .lede { color: #d2dae6; }
.hero .stamp { color: #a6b5c8; }
.hero .stamp a { color: #ffd866; }

@media (max-width: 720px) {
  .hero { min-height: 0; }
  .hero-img { object-position: 72% 40%; }
  .hero::after {
    background:
      linear-gradient(180deg, rgba(8, 13, 22, 0.84) 0%, rgba(8, 13, 22, 0.93) 45%, rgba(8, 13, 22, 0.97) 100%),
      linear-gradient(90deg, rgba(8, 13, 22, 0.6) 0%, rgba(8, 13, 22, 0) 78%);
  }
  .hero-inner { padding: 44px 20px 40px; }
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0 0 12px;
  font-size: clamp(28px, 4vw, 40px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.lede {
  margin: 0 0 8px;
  max-width: 62ch;
  color: var(--muted);
}

.stamp { margin: 0; font-size: 14px; color: var(--muted); }
.stamp a { color: var(--accent); }

main { padding-top: 32px; }

section + section { margin-top: 52px; }

.section-title {
  margin: 0 0 6px;
  font-size: 22px;
  letter-spacing: -0.01em;
}

.section-lede {
  margin: 0 0 18px;
  max-width: 62ch;
  color: var(--muted);
}

.anchors {
  display: flex;
  gap: 18px;
  margin-top: 18px;
  font-size: 14px;
}

.anchors a {
  color: #ffd866;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 216, 102, 0.45);
}

.faq {
  display: grid;
  gap: 10px;
  max-width: 70ch;
}

.faq details {
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}

.faq summary {
  cursor: pointer;
  font-weight: 600;
}

.faq p {
  margin: 8px 0 0;
  color: var(--muted);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 14px;
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.card h2 {
  margin: 0;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 600;
}

.card h2 a::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 12px;
}

.card .price { margin: 0; font-weight: 700; }
.card .price-note { margin: 0; font-size: 13px; color: var(--muted); }
.card .meta { margin: 0; font-size: 13px; color: var(--muted); }
.card .source { margin: auto 0 0; font-size: 13px; color: var(--accent); font-weight: 600; }

.badge {
  align-self: flex-start;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-fg);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

/* ---------- Ad surface ---------- */
/* The rail only exists when an AdSense client is configured, so the page never ships
   empty boxes; without it the content column goes full width and fits three cards. */

.layout { display: grid; gap: 28px; }
.layout__main { min-width: 0; }
.layout__rail { display: none; }

@media (min-width: 1080px) {
  .layout--ads { grid-template-columns: minmax(0, 1fr) 300px; align-items: start; }
  .layout--ads .layout__rail { display: block; position: sticky; top: 16px; }
}

.ad-slot {
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px dashed var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.ad-slot--rail { width: 300px; min-height: 600px; }
.ad-slot--infeed { grid-column: 1 / -1; min-height: 110px; margin: 2px 0; }
ins.adsbygoogle { display: block; width: 100%; }
.ad-slot:empty::before { content: attr(data-label); }

.site-footer {
  margin-top: 48px;
  padding-bottom: 56px;
  font-size: 14px;
  color: var(--muted);
}

.site-footer a { color: var(--accent); }

/* ---------- Directory: service-uri auto pe sector ---------- */

.muted { color: var(--muted); }

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: -24px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--border);
  overflow: hidden;
}

.stat {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 16px 18px;
  background: var(--bg);
}

.stat__value {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.stat__label { font-size: 12px; color: var(--muted); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 13px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--fg);
  font: inherit;
  font-size: 13px;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
}

.chip:hover { border-color: var(--accent); color: var(--accent); }

.chip--active,
.chip[aria-pressed="true"] {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-fg);
  font-weight: 600;
}

.chip--active:hover,
.chip[aria-pressed="true"]:hover { color: var(--accent-fg); }

.chip--soon { opacity: .55; cursor: not-allowed; }
.chip--soon:hover { border-color: var(--border); color: var(--fg); }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.toolbar {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  gap: 10px;
  margin-bottom: 20px;
  padding: 12px;
  border: 1px solid var(--border);
  border-top: 0;
  border-radius: 0 0 14px 14px;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(10px);
}

.toolbar__row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.toolbar__icon {
  display: inline-flex;
  color: var(--muted);
}

.toolbar__input {
  flex: 1;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--bg);
  color: var(--fg);
  font: inherit;
  font-size: 15px;
}

.toolbar__input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; }

.toolbar__count {
  margin: 0;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  white-space: nowrap;
}

.grid--shops { grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); }

.shop {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 14px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  scroll-margin-top: 16px;
}

.shop--top { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }

.shop__rank {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg);
  font-size: 17px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
}

.shop--top .shop__rank {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-fg);
}

.shop__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.shop__name {
  margin: 0;
  font-size: 17px;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

.shop__name a { text-decoration: none; }
.shop__name a:hover { color: var(--accent); }

.shop__cat {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--accent);
  white-space: nowrap;
}

.shop__rating {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 6px 0 0;
  font-size: 14px;
}

.shop__rating .star { color: #e8a300; font-size: 15px; }

.shop__desc {
  margin: 8px 0 0;
  font-size: 14px;
  color: var(--muted);
}

.shop__addr {
  margin: 8px 0 0;
  font-size: 13px;
  color: var(--muted);
}

.shop__body {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.shop__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
  padding-top: 14px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 1px solid var(--accent);
  border-radius: 9px;
  background: var(--accent);
  color: var(--accent-fg);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.btn:hover { color: var(--accent-fg); filter: brightness(1.06); }

.btn--ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--fg);
  font-weight: 500;
}

.btn--ghost:hover { border-color: var(--accent); color: var(--accent); filter: none; }

.empty {
  padding: 24px;
  border: 1px dashed var(--border);
  border-radius: 12px;
  color: var(--muted);
  text-align: center;
}

[data-grid] .shop[hidden] { display: none; }

@media (max-width: 720px) {
  .stats { grid-template-columns: repeat(2, 1fr); margin-top: 0; }
  .grid--shops { grid-template-columns: 1fr; }
  .shop { grid-template-columns: 36px 1fr; padding: 16px; }
  .shop__rank { width: 36px; height: 36px; font-size: 15px; }
}

/* ---------- Sector x category landing pages ---------- */

.page-head {
  padding: 40px 0 24px;
  border-bottom: 1px solid var(--border);
}

.crumbs {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  font-size: 13px;
  color: var(--muted);
}

.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--accent); }
.crumbs [aria-current] { color: var(--fg); font-weight: 600; }

.page-head h1 { margin-bottom: 10px; }

.statline {
  margin: 14px 0 0;
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.cat-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.cat-row {
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
}

.cat-row__rank {
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  text-align: center;
}

.cat-row__name {
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
}

.cat-row__name:hover { color: var(--accent); }

.cat-row__meta {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  color: var(--muted);
}

.cat-row__meta .star { color: #e8a300; }

.cat-row__actions { display: flex; gap: 8px; }

.prose { max-width: 74ch; }

.prose p {
  margin: 0 0 12px;
  font-size: 15px;
  line-height: 1.65;
}

.sub-title {
  margin: 24px 0 8px;
  font-size: 16px;
}

.cat-ask {
  margin: 0;
  padding-left: 20px;
  color: var(--fg);
  font-size: 15px;
}

.cat-ask li { margin-bottom: 6px; }

.cat-nav { margin-top: 44px; }

@media (max-width: 720px) {
  .cat-row {
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 10px;
    padding: 12px;
  }
  .cat-row__actions { grid-column: 1 / -1; }
  .page-head { padding-top: 24px; }
}

/* ---------- City hub: sector cards ---------- */

.sector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}

.sector-card {
  display: block;
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  text-decoration: none;
}

.sector-card:hover { border-color: var(--accent); }

.sector-card__num {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

.sector-card__title {
  display: block;
  margin: 2px 0 4px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.sector-card__meta { font-size: 13px; color: var(--muted); }

.hero .eyebrow a {
  color: #ffd866;
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 216, 102, 0.45);
}

/* ---------- Static build-time map ---------- */

.map-block { margin: 28px 0 0; }

.map-img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
}

.map-note {
  margin: 6px 0 0;
  font-size: 12px;
  color: var(--muted);
}

.map-note a { color: inherit; }
