@charset "UTF-8";
/* Geist variable font */
@font-face {
  font-family: "Geist";
  src: url("/assets/fonts/geist/Geist[wght].woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Geist";
  src: url("/assets/fonts/geist/Geist-Italic[wght].woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}
:root {
  --bg:#0b0d10;
  --card:#11151a;
  --panel:#0e1217;
  --text:#ecf1f4;
  --muted:#a0a5aa;
  --border:#1a1f27;
  --accent:#2a3441;
  --category:#99aabb;
}

:root[data-theme=light] {
  --bg:#f5f7fb;
  --card:#ffffff;
  --panel:#f0f3f7;
  --text:#0a0c10;
  --muted:#4a5563;
  --border:#dbe2ea;
  --accent:#c9d4e2;
  --category:#3f5a73;
}

/* Uniform theme flip animation — no global text-color fade */
html.theme-anim, html.theme-anim * {
  transition: background-color 0.25s ease, border-color 0.25s ease, fill 0.25s ease, stroke 0.25s ease !important;
}

/* If you still want a tiny fade on chrome text (not body copy), opt-in: */
html.theme-anim .brand,
html.theme-anim .accordion-toggle,
html.theme-anim .nav a,
html.theme-anim .cats-chip {
  transition: color 0.18s ease;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

html:focus-within {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font: 16px/1.6 "Geist", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  transition: background-color 0.3s ease-in-out, color 0.3s ease-in-out;
}

img {
  max-width: 100%;
  display: block;
}

/* ---- CLS helpers for images with explicit attributes ---- */
img[width][height] {
  height: auto;
} /* keep aspect ratio with reserved slot */
.brand-logo {
  width: 41px;
  height: 31px;
  display: block;
  aspect-ratio: 41/31;
} /* lock header layout */
/* -------------------------------------------------------- */
h1, h2, h3, h4, h5, p, strong, ul, ol, li {
  margin: 0;
}

.container {
  max-width: 1366px;
  margin: 0 auto;
  padding: 16px;
}

.row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 16px;
}

.site-header, .site-footer {
  border-top: 1px solid rgba(27, 34, 44, 0.125);
  border-bottom: 1px solid rgba(27, 34, 44, 0.125);
  background: color-mix(in srgb, var(--bg), #000 5%);
}

.brand {
  font-weight: 800;
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
  display: flex;
  gap: 0.5rem;
  font-size: 2rem;
  line-height: 2rem;
}

.brand:focus-visible, .nav a:focus-visible, a.skip-link:focus, a:focus-visible {
  outline: 2px solid #7fb0ff;
  outline-offset: 2px;
  border-radius: 6px;
}

.content {
  margin: 16px 0;
}

.content .grid .card {
  margin: 0 0 16px 0;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
  contain: layout paint;
  margin: 16px 0;
}

.list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.list li {
  margin: 6px 0;
}

a {
  color: inherit;
  text-underline-offset: 2px;
  text-decoration-thickness: 1.5px;
}

.sidebar .list a {
  display: inline-block;
  padding: 2px 0;
  text-decoration: none;
  margin-left: 23px;
}

.sidebar .list a:hover {
  text-decoration: underline;
}

.nav a {
  margin-left: 0;
  text-decoration: none;
}

.toggle-container {
  width: 251px;
  padding: 14px;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  background-color: var(--panel);
  border-radius: 6px;
  transition: background-color 0.3s ease-in-out 0.1s;
}

.fa-sun, .fa-moon {
  font-size: 1.5rem;
  color: #828FA3;
}

/* Toggle switch */
.switch {
  position: relative;
  display: inline-block;
  width: 54px;
  height: 32px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: #635FC7;
  transition: 0.4s;
  border-radius: 34px;
}

.slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 5px;
  bottom: 5px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}

.switch input:checked + .slider:before {
  transform: translateX(22px);
}

/* Forms */
.input-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.input-row label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}

.input-row input, .input-row select {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid #2a2f38;
  background: var(--panel);
  color: var(--text);
}

.input-row input:focus-visible, .input-row select:focus-visible {
  outline: 2px solid #7fb0ff;
  outline-offset: 2px;
}

.result {
  font-size: 32px;
  font-weight: 700;
}

/* Ads */
.ad {
  background: var(--panel);
  border: 1px dashed var(--accent);
  border-radius: 10px;
  text-align: center;
  color: var(--muted);
}

/* Reserve space for ads to prevent CLS */
.ad.ad-top, .ad.ad-bottom {
  min-height: 90px;
} /* base default */
.ad.ad-incontent {
  min-height: 250px;
}

@media (min-width: 1200px) {
  .ad.ad-top, .ad.ad-bottom {
    min-height: 250px;
  }
  .sidebar .ad.ad-sidebar {
    min-height: 600px;
  }
}
@media (min-width: 1024px) and (max-width: 1199.98px) {
  .ad.ad-top, .ad.ad-bottom {
    min-height: 90px;
  }
  .sidebar .ad.ad-sidebar {
    min-height: 600px;
  }
  .ad.ad-incontent {
    min-height: 280px;
  }
}
@media (max-width: 900px) {
  .ad.ad-top, .ad.ad-bottom {
    min-height: 100px;
  }
}
/* Anchor ad close button */
#ad-anchor {
  position: relative;
}

#ad-anchor .ad-anchor__close {
  position: absolute;
  top: 4px;
  right: 6px;
  border: 0;
  background: transparent;
  color: inherit;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

/* A11y helpers */
.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.skip-link:focus {
  position: fixed;
  left: 16px;
  top: 16px;
  width: auto;
  height: auto;
  padding: 8px 12px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 10px;
  z-index: 9999;
}

/* -------- Sidebar positioning -------- */
.sidebar {
  align-self: start;
}

@media (min-width: 901px) {
  .sidebar {
    position: sticky;
    top: 16px;
    max-height: calc(100vh - 32px);
    overflow: auto;
  }
}
/* remove outer padding in sidebar card so accordion sits flush */
.sidebar {
  background: transparent;
  border: none;
}

.sidebar .card {
  background: transparent;
  border: none;
  position: relative;
  padding: 0;
}

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

.category-title {
  margin: 12px 0 6px 0;
  color: var(--category);
  font-weight: 600;
  font-size: 13px;
}

.card:is(a) {
  display: block;
  text-decoration: none;
  color: inherit;
}

.card:is(a):hover {
  border-color: color-mix(in srgb, var(--border), currentColor 35%);
}

.card:is(a):focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

/* ---------- Sidebar accordion ---------- */
.accordion {
  display: grid;
  gap: 12px;
}

.accordion-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--panel);
}

.accordion-header {
  margin: 0;
}

.accordion-toggle {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  background: transparent;
  border: 0;
  color: var(--text);
  text-align: left;
  cursor: pointer;
  font: inherit;
  border-bottom: 1px solid transparent;
}

.accordion-toggle[aria-expanded=true] {
  border-bottom-color: var(--border);
}

.accordion-toggle:focus-visible {
  outline: 2px solid #7fb0ff;
  outline-offset: 2px;
  border-radius: 6px;
}

.acc-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.acc-count {
  color: var(--muted);
  font-weight: 400;
}

.acc-arrow {
  width: 12px;
  height: 12px;
  display: inline-block;
  border-right: 2px solid var(--muted);
  border-bottom: 2px solid var(--muted);
  transform: rotate(-45deg);
  transition: transform 0.2s ease-in-out;
  margin-right: 2px;
  margin-left: auto;
}

.accordion-toggle[aria-expanded=true] .acc-arrow {
  transform: rotate(45deg);
}

/* animated panel; inner padding provides spacing */
.accordion-panel {
  padding: 0;
}

.accordion-panel__inner {
  padding: 8px 12px 12px;
}

/* ---------- Homepage categories summary ---------- */
.cats-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--panel);
  text-decoration: none;
  color: inherit;
}

.cat-pill:hover {
  border-color: color-mix(in srgb, var(--border), currentColor 35%);
}

.cat-pill img {
  width: 20px;
  height: 20px;
}

.cat-pill .cat-name {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.cat-pill .cat-count {
  color: var(--muted);
  font-size: 12px;
}

/* NEW: visible category descriptions (homepage) */
.cat-left {
  display: grid;
  grid-auto-rows: min-content;
  gap: 4px;
}

.cat-desc {
  display: block;
  font-size: 12px;
  line-height: 1.3;
  color: var(--muted);
  margin-left: 28px;
}

@media (max-width: 600px) {
  .cat-desc {
    margin-left: 0;
  }
}
/* ---- Cats bar tooltip (mobile-only, overlay with fade) ---- */
.cats-wrap {
  position: sticky;
}

.cats-hint {
  position: absolute;
  left: 16px;
  right: 16px;
  top: 6px;
  z-index: 60;
  display: none;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 0.22s ease, transform 0.22s ease;
  pointer-events: none;
}

.cats-hint.is-visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.cats-hint.is-hiding {
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
}

.cats-hint__inner {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--card);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.25);
}

.cats-hint__inner::after {
  content: "";
  position: absolute;
  left: 24px;
  bottom: -8px;
  width: 14px;
  height: 14px;
  background: var(--card);
  border-left: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transform: rotate(-45deg);
}

.cats-hint__text {
  font-size: 14px;
  color: var(--muted);
}

.cats-hint__btn {
  margin-left: auto;
  border: 0;
  background: var(--panel);
  color: inherit;
  padding: 6px 10px;
  border-radius: 8px;
  cursor: pointer;
}

.cats-hint__btn:focus-visible {
  outline: 2px solid #7fb0ff;
  outline-offset: 2px;
  border-radius: 6px;
}

/* ---------- New: actions bar (vote + share) ---------- */
.actions-bar {
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
}

.actions-bar .btn {
  border: 1px solid var(--border);
  background: var(--panel);
  color: var(--text);
  padding: 8px 12px;
  border-radius: 10px;
  cursor: pointer;
}

.actions-bar .btn:disabled {
  opacity: 0.6;
  cursor: default;
}

.vote {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

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

.vote-btn {
  line-height: 1;
  font-size: 18px;
  width: auto;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.vote-btn .ico {
  width: 18px;
  height: 18px;
  display: inline-block;
  background: currentColor;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}

.vote-btn .ico-up {
  -webkit-mask-image: url("/assets/svg/thumbs-up.svg");
  mask-image: url("/assets/svg/thumbs-up.svg");
}

.vote-btn .ico-down {
  -webkit-mask-image: url("/assets/svg/thumbs-down.svg");
  mask-image: url("/assets/svg/thumbs-down.svg");
}

.vote-btn .label {
  font-size: 14px;
}

.vote-btn:hover {
  border-color: color-mix(in srgb, var(--border), currentColor 35%);
}

.vote-btn:active {
  transform: translateY(1px);
}

.vote-btn.is-selected {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

/* sr-only helper */
.sr-only {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---- Responsive ---- */
@media (max-width: 900px) {
  .cats-hint {
    display: block;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .input-row {
    grid-template-columns: 1fr;
  }
  .result {
    font-size: 28px;
  }
  .sidebar {
    position: static;
    order: 2;
  }
  .content {
    order: 1;
  }
  .nav a {
    padding: 10px 0;
    display: inline-block;
  }
}
/* Focus style for chips */
.cats-chip:focus-visible {
  outline: 2px solid #7fb0ff;
  outline-offset: 2px;
  border-radius: 6px;
}

.acc-ico {
  width: 16px;
  height: 16px;
  display: inline-block;
}/*# sourceMappingURL=style.css.map */