/* ── Design Tokens — punterfy palette ── */
:root {
  --bg:             #181716;
  --surface:        #21201e;
  --surface-raised: #181716;
  --border:         #2c2b29;
  --border-hover:   #3a3835;
  --border-focus:   #625e5b;
  --text-primary:   #e2e0dc;
  --text-secondary: #827f7a;
  --text-muted:     #565450;
  --no:             #ef4444;
  --unlikely:       #f97316;
  --split:          #a78bfa;
  --yeah:           #10b981;
  --absolutely:     #10b981;
  --conf-high:      #10b981;
  --conf-medium:    #f97316;
  --conf-low:       #ef4444;
}

/* ── Reset & Base ── */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.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;
}

.home-main {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
}

/* ── States ── */
.state {
  display: none;
  min-height: 0;
  flex: 1 0 auto;
  align-items: center;
  justify-content: center;
}

.state.active {
  display: flex;
}

/* ── Wordmark as nav link ── */
.wordmark-link {
  display: flex;
  align-items: center;
  color: #ffffff;
  text-decoration: none;
  line-height: 1;
}

.wordmark-link:hover,
.wordmark-link:visited,
.wordmark-link:active,
.wordmark-link:focus {
  color: #ffffff;
  text-decoration: none;
}

.nav-brand {
  font-family: 'Libre Baskerville', serif;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.01em;
  color: #ffffff;
}

/* ── Hero wordmark (homepage center) ── */
.hero-wordmark {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.hero-brand {
  font-family: 'Libre Baskerville', serif;
  font-weight: 700;
  font-size: 2.2rem;
  letter-spacing: -0.01em;
  color: #ffffff;
}

/* ── Input State ── */
.input-container {
  width: 100%;
  max-width: 560px;
  padding: 2rem;
  text-align: center;
}

.tagline {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 0.4rem;
}

.supporting-line {
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-style: italic;
  margin-bottom: 2rem;
}

.site-footer {
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  text-align: center;
  margin-top: 1.5rem;
}

.input-row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

#opinion-input {
  flex: 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}

#opinion-input::placeholder {
  color: var(--text-muted);
}

#opinion-input:focus {
  border-color: var(--border-focus);
}

#submit-btn {
  background: #ffffff;
  color: #181716;
  border: none;
  border-radius: 8px;
  padding: 0.85rem 1.4rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: opacity 0.2s;
}

#submit-btn:hover {
  opacity: 0.85;
}

#submit-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}


/* ── Loading State ── */
.loading-container {
  text-align: center;
}

.loading-ring-wrap {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 2rem auto 1rem;
}

.loading-ring {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.loading-ring-track {
  fill: none;
  stroke: var(--border);
  stroke-width: 6;
}

.loading-ring-fill {
  fill: none;
  stroke: var(--text-secondary);
  stroke-width: 6;
  stroke-linecap: round;
  stroke-dasharray: 251.2;
  stroke-dashoffset: 251.2;
  transition: stroke-dashoffset 0.6s ease;
}

.loading-ring-pct {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'DM Mono', monospace;
  font-size: 1rem;
  color: var(--text-primary);
}

.loading-text {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: opacity 0.3s ease;
}

/* ── Result State ── */
.result-container {
  width: 100%;
  max-width: 900px;
  padding: 2rem;
  animation: slideUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}

.back-btn {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
  margin-bottom: 1.5rem;
  padding: 0;
  transition: color 0.2s;
}

.back-btn:hover {
  color: var(--text-primary);
}

.result-opinion {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
  font-style: italic;
}

.result-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
}

/* ── Arc Meter ── */
.arc-section {
  position: relative;
  width: 220px;
  height: 150px;
  margin: -2rem auto 0.5rem;
}

.arc-meter {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.arc-fill {
  transition: none;
}

.arc-percent {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'DM Mono', monospace;
  font-size: 2.6rem;
  font-weight: 500;
  line-height: 1;
}

.percent-sign {
  font-size: 1.2rem;
  opacity: 0.5;
}

/* ── Verdict Word ── */
.verdict-word {
  text-align: center;
  font-family: 'DM Mono', monospace;
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  text-transform: lowercase;
}

/* ── One-liner ── */
.one-liner {
  border-left: 3px solid var(--border-hover);
  padding-left: 1rem;
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
  font-style: italic;
  color: var(--text-primary);
  line-height: 1.5;
}

/* ── Crowd Read ── */
.crowd-read {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
}

.trend-section {
  margin-bottom: 1.5rem;
  padding: 1rem 1.1rem;
  background: #181716;
  border: 1px solid var(--border);
  border-radius: 12px;
}

.trend-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.8rem;
  flex-wrap: wrap;
}

.trend-label,
.trend-stat-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.trend-span {
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  color: var(--text-secondary);
}

.trend-chart-wrap {
  margin-bottom: 0.9rem;
}

.trend-chart {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 640 / 260;
  background:
    linear-gradient(to top, rgba(255,255,255,0.03) 1px, transparent 1px) 0 0 / 100% 25%,
    transparent;
  border-radius: 8px;
}

.trend-point-label {
  font-family: 'DM Mono', monospace;
  font-size: 12px;
  fill: var(--text-primary);
}

.trend-point-date {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  fill: var(--text-muted);
}

.trend-empty {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.trend-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.trend-stat {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.trend-stat-value {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  color: var(--text-secondary);
  line-height: 1.35;
}

/* ── Pros & Cons ── */
.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.pros h2, .pros h3, .cons h2, .cons h3 {
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  margin-bottom: 0.6rem;
}

.pros ul, .cons ul {
  list-style: none;
}

.pros li, .cons li {
  position: relative;
  padding-left: 1rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-bottom: 0.4rem;
}

.pros li::before {
  content: "+";
  position: absolute;
  left: 0;
  color: var(--yeah);
  font-family: 'DM Mono', monospace;
  font-weight: 500;
}

.cons li::before {
  content: "−";
  position: absolute;
  left: 0;
  color: var(--no);
  font-family: 'DM Mono', monospace;
  font-weight: 500;
}

/* ── Source Breakdown ── */
.source-breakdown {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
  flex-wrap: wrap;
}

.source-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  white-space: nowrap;
}

.source-icons {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.source-tag {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.source-tag svg {
  flex-shrink: 0;
  display: block;
}

.source-count {
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* ── Verdict Colours ── */
.verdict-no { color: var(--no); }
.verdict-unlikely { color: var(--unlikely); }
.verdict-split { color: var(--split); }
.verdict-yeah { color: var(--yeah); }
.verdict-absolutely { color: var(--absolutely); }

/* ── Thin Data State ── */
.thin-container {
  width: 100%;
  max-width: 560px;
  padding: 2rem;
  text-align: center;
  animation: slideUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.thin-message {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
  margin-top: 1.5rem;
}

/* ── Error State ── */
.error-container {
  width: 100%;
  max-width: 560px;
  padding: 2rem;
  text-align: center;
  animation: slideUp 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.error-message {
  color: var(--text-secondary);
  font-size: 1rem;
  line-height: 1.6;
  margin-top: 1.5rem;
}

.error-upgrade-btn {
  margin-top: 1rem;
  width: auto;
  min-width: 220px;
}

/* ── Share Button ── */
.share-section {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.25rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border);
}

.share-btn {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.55rem 1.1rem;
  color: var(--text-secondary);
  font-family: 'DM Mono', monospace;
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}

.share-btn:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.share-status {
  font-size: 0.8rem;
  color: var(--text-secondary);
  transition: opacity 0.3s;
}

/* ── Share Card (offscreen, for capture) ── */
.share-card {
  position: fixed;
  left: -9999px;
  top: 0;
  width: 480px;
  background: #15191d;
  border-radius: 0;
  z-index: -1;
}

.share-card-inner {
  padding: 2.5rem 2rem 2rem;
  text-align: center;
}

.share-card-opinion {
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-style: italic;
  margin-bottom: 1.25rem;
}

.share-card-arc-row {
  position: relative;
  width: 180px;
  height: 130px;
  margin: 0 auto 0.25rem;
}

.share-card-arc {
  width: 100%;
  height: 100%;
  overflow: visible;
}

.share-card-percent {
  position: absolute;
  bottom: 12px;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'DM Mono', monospace;
  font-size: 2.2rem;
  font-weight: 500;
  color: #ffffff;
  line-height: 1;
}

.share-card-percent .percent-sign {
  font-size: 1rem;
}

.share-card-verdict {
  font-family: 'DM Mono', monospace;
  font-size: 1.6rem;
  font-weight: 500;
  text-transform: lowercase;
  margin-bottom: 1rem;
}

.share-card-oneliner {
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-style: italic;
  color: var(--text-primary);
  line-height: 1.5;
  margin-bottom: 1.5rem;
  padding: 0 1rem;
}

.share-card-wordmark {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  color: rgba(255,255,255,0.25);
}

.share-card-wordmark span {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: -0.03em;
}


/* ── Responsive ── */
@media (max-width: 480px) {
  .input-row {
    flex-direction: column;
  }

  .pros-cons {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .result-container, .input-container {
    padding: 1.5rem;
  }
}

/* ── Site header ── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 2rem;
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.user-menu {
  display: flex;
  align-items: center;
  gap: 0;
  min-width: 92px;
  justify-content: flex-end;
}

.nav-links a {
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.15s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
}

.nav-links a.nav-cta {
  background: #ffffff;
  color: #181716;
  border-radius: 6px;
  padding: 0.4rem 0.9rem;
  font-weight: 600;
}

.nav-links a.nav-cta:hover {
  opacity: 0.88;
  color: #181716;
}

.login-btn,
.logout-btn,
.billing-btn,
.account-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  padding: 0.4rem 0.75rem;
  cursor: pointer;
  white-space: nowrap;
}

.login-btn:hover,
.logout-btn:hover,
.billing-btn:hover,
.account-btn:hover {
  border-color: var(--border-focus);
  color: var(--text-primary);
}

/* ── Nav search — desktop (hidden on mobile) ── */
.nav-search-wrap {
  position: relative;
  flex: 1;
  min-width: 0;
}

.nav-search-input {
  display: block;
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.5rem 1rem;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  outline: none;
  transition: border-color 0.15s;
}

.nav-search-input:focus {
  border-color: var(--border-focus);
}

.nav-search-input::placeholder {
  color: var(--text-muted);
}

.nav-search-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 200;
}

.nav-divider {
  width: 100%;
  height: 1px;
  background: var(--border);
}

/* ── Category nav — row 2, all screen sizes ── */
.category-nav {
  padding: 0 2rem;
  max-width: 1000px;
  margin: 0 auto;
  width: 100%;
}

.category-pills {
  display: flex;
  justify-content: center;
  gap: 0.6rem;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 0.4rem 0;
}

.category-pills::-webkit-scrollbar {
  display: none;
}

.category-pill {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 500;
  padding: 0.3rem 0.75rem;
  border-radius: 20px;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}

.category-pill:hover {
  background: var(--surface);
  color: var(--text-primary);
}

.category-pill.active {
  background: var(--surface);
  color: var(--text-primary);
  border: 1px solid var(--border-hover);
}

/* ── Mobile search row — row 3, mobile only (hidden on desktop) ── */
.mobile-search-row {
  display: none;
  border-top: 1px solid var(--border);
  padding: 0.5rem 1rem;
}

.mobile-search-inner {
  position: relative;
}

.mobile-search-input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 1rem;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  outline: none;
  transition: border-color 0.15s;
}

.mobile-search-input:focus {
  border-color: var(--border-focus);
}

.mobile-search-input::placeholder {
  color: var(--text-muted);
}

.mobile-search-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: 200;
  background: var(--surface);
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  overflow: hidden;
}

/* ── Responsive ── */
@media (max-width: 768px) {
  /* Hide desktop search, show mobile search row */
  .nav-search-wrap {
    display: none;
  }

  .mobile-search-row {
    display: block;
  }

  .site-nav {
    padding: 0.75rem 1rem;
  }

  .nav-links {
    gap: 0.75rem;
  }

  .category-nav {
    padding: 0 1rem;
  }

  .result-card .verdict-vote {
    justify-content: center;
  }

  .result-card .arc-section {
    margin-top: -1rem;
  }

  .trend-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 960px) and (min-width: 769px) {
  .nav-search-wrap {
    max-width: 280px;
  }

  .category-pills {
    gap: 0.15rem;
  }
}

/* ── Browse page layout ── */
.browse-page {
  background: var(--bg);
}

.browse-main {
  max-width: 1280px;
  margin: 0 auto;
  padding: 2rem 2rem 4rem;
  flex: 1 0 auto;
  width: 100%;
}

.browse-page-header {
  margin-bottom: 1.5rem;
}

.browse-page-header h1 {
  font-family: 'Libre Baskerville', serif;
  font-size: 1.4rem;
  line-height: 1.15;
  color: var(--text-primary);
  text-transform: lowercase;
  margin-bottom: 0.5rem;
}

.browse-page-header p {
  max-width: 640px;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.65;
}

/* ── Search bar ── */
.search-wrap {
  position: relative;
  width: 100%;
  max-width: 480px;
  margin: 1.5rem auto 2rem;
}

.search-input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.15s;
}

.search-input:focus {
  border-color: var(--border-focus);
}

.search-input::placeholder {
  color: var(--text-muted);
}

.search-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--surface);
  border: 1px solid var(--border-hover);
  border-radius: 8px;
  overflow: hidden;
  z-index: 100;
}

.search-result-row {
  display: flex;
  align-items: center;
  padding: 0.65rem 1rem;
  cursor: pointer;
  transition: background 0.1s;
  gap: 0.75rem;
  color: inherit;
  text-decoration: none;
}

.search-result-thumb {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  object-fit: cover;
  flex-shrink: 0;
}

.search-result-thumb--placeholder {
  width: 32px;
  height: 32px;
  border-radius: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.75rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-result-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex: 1;
  min-width: 0;
  gap: 1rem;
}

.search-result-row:hover {
  background: #242b32;
}

.search-result-opinion {
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-result-verdict {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  font-weight: 600;
  flex-shrink: 0;
}

/* ── Verdicts grid ── */
.verdicts-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.85rem;
  align-items: stretch;
}

@media (max-width: 800px) {
  .verdicts-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 520px) {
  .verdicts-grid { grid-template-columns: 1fr; }
  .browse-main { padding: 0 1rem 3rem; }
  .site-nav { padding: 1rem; }
}

/* ── Verdict card ── */
.verdict-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.1rem 1.2rem;
  cursor: pointer;
  transition: border-color 0.15s ease;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  height: 100%;
  color: inherit;
  text-decoration: none;
}

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

.card-top-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.card-top-right {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 1;
  min-width: 0;
}

.card-subject {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.card-opinion {
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
}

.card-verdict-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.15rem;
}

.card-verdict-word {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.78rem;
  letter-spacing: -0.01em;
  text-transform: lowercase;
}

.card-percent {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 0.78rem;
  color: var(--text-secondary);
  letter-spacing: -0.01em;
}

.card-one-liner {
  font-family: 'Inter', sans-serif;
  font-size: 0.78rem;
  color: var(--text-muted);
  font-style: italic;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  margin: 0;
}

.card-bottom-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 0.5rem;
}

.card-sources {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.source-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.source-pill svg {
  flex-shrink: 0;
  display: block;
  fill: var(--text-muted);
}

.source-pill .source-count {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.confidence-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  flex-shrink: 0;
}

.confidence-high   { background: var(--conf-high); }
.confidence-medium { background: var(--conf-medium); }
.confidence-low    { background: var(--conf-low); }

.confidence-dot.verdict-no         { background: var(--no); }
.confidence-dot.verdict-unlikely   { background: var(--unlikely); }
.confidence-dot.verdict-split      { background: var(--split); }
.confidence-dot.verdict-yeah       { background: var(--yeah); }
.confidence-dot.verdict-absolutely { background: var(--absolutely); }

/* ── Pagination ── */
.pagination {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  justify-content: center;
  margin-top: 2.5rem;
}

.page-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.4rem 0.85rem;
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}

.page-btn:hover:not(:disabled) {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.page-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.page-info {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  color: var(--text-muted);
  min-width: 100px;
  text-align: center;
}

/* ── Empty state ── */
.empty-state {
  text-align: center;
  padding: 4rem 2rem;
  grid-column: 1 / -1;
}

.empty-state p {
  font-family: 'Inter', sans-serif;
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.empty-state a {
  font-family: 'Inter', sans-serif;
  color: var(--text-secondary);
  font-size: 0.875rem;
  text-decoration: none;
  transition: color 0.15s;
}

.empty-state a:hover {
  color: var(--text-primary);
}

/* ── Browse link (main page) ── */
.browse-link {
  display: inline-block;
  margin-top: 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  color: var(--text-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.browse-link:hover {
  color: var(--text-secondary);
}

.browse-link--result {
  display: block;
  text-align: center;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
}

/* ── Best Comment ── */
.best-comment {
  margin-bottom: 1.5rem;
  padding: 1rem 1.2rem;
  background: #181716;
  border: 1px solid var(--border);
  border-radius: 10px;
}

.best-comment-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.trophy-icon {
  font-size: 0.85rem;
  line-height: 1;
}

.best-comment-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.72rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.best-comment-source {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-left: auto;
}

.best-comment-text {
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  font-style: italic;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
  border: none;
  padding: 0;
}

/* ── Card thumbnail (browse page) ── */
.card-thumb {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--border);
}

.card-thumb--placeholder {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ── Result page thumbnail ── */
.one-liner-row {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.result-thumb {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  object-fit: cover;
  flex-shrink: 0;
}

.one-liner-row .one-liner {
  margin-bottom: 0;
  flex: 1;
}

/* ── Result page header ── */
.result-header {
  margin-bottom: 1.5rem;
}

.result-subject {
  display: block;
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 0.4rem;
}

.result-question {
  font-family: 'Libre Baskerville', serif;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin: 0;
}

/* ── Invalid input state ── */
.invalid-container {
  width: 100%;
  max-width: 480px;
  padding: 2rem;
  text-align: center;
  animation: slideUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.invalid-emoji {
  font-size: 2.2rem;
  margin-bottom: 1rem;
  line-height: 1;
}

.invalid-headline {
  font-family: 'DM Mono', monospace;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.invalid-body {
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 2rem;
}

.back-btn-invalid {
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.6rem 1.2rem;
  color: var(--text-secondary);
  font-family: 'Inter', sans-serif;
  font-size: 0.85rem;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}

.back-btn-invalid:hover {
  border-color: var(--border-hover);
  color: var(--text-primary);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
}

.modal-content {
  position: relative;
  width: min(420px, calc(100vw - 2rem));
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
  z-index: 1;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

.modal-close {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  border: none;
  background: none;
  color: var(--text-secondary);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.modal-close:hover {
  color: var(--text-primary);
}

.auth-form h2 {
  font-family: 'DM Mono', monospace;
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.auth-social {
  margin-bottom: 1rem;
}

.auth-subtitle {
  color: var(--text-secondary);
  font-size: 0.85rem;
  margin-bottom: 1.25rem;
}

.auth-provider-buttons {
  display: grid;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.auth-provider-btn {
  width: 100%;
  background: #181716;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text-primary);
  padding: 0.8rem 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  cursor: pointer;
  text-transform: lowercase;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.auth-provider-btn:hover {
  border-color: var(--border-focus);
}

.auth-provider-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  display: block;
}

.auth-provider-label {
  line-height: 1;
  text-align: center;
}

.auth-divider {
  position: relative;
  text-align: center;
  margin: 1rem 0 1.1rem;
}

.auth-divider::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  border-top: 1px solid var(--border);
}

.auth-divider span {
  position: relative;
  z-index: 1;
  padding: 0 0.75rem;
  background: var(--surface);
  color: var(--text-muted);
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.auth-form input {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
  outline: none;
}

.auth-form input:focus {
  border-color: var(--border-focus);
}

.auth-form input::placeholder {
  color: var(--text-muted);
}

.auth-error {
  color: var(--no);
  font-size: 0.85rem;
  margin-bottom: 0.75rem;
}

.auth-submit {
  width: 100%;
  background: #ffffff;
  color: #181716;
  border: none;
  border-radius: 8px;
  padding: 0.85rem 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
}

.auth-submit:hover {
  opacity: 0.88;
}

.auth-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.auth-switch {
  margin-top: 1rem;
  text-align: center;
  color: var(--text-secondary);
  font-size: 0.85rem;
}

.auth-switch a {
  color: var(--text-primary);
}

.auth-secondary {
  width: 100%;
  margin-top: 0.7rem;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.9rem;
  cursor: pointer;
}

.auth-secondary:hover {
  border-color: var(--border-focus);
  color: var(--text-primary);
}

.upgrade-toast {
  position: fixed;
  left: 50%;
  bottom: 2rem;
  transform: translateX(-50%);
  background: #10b981;
  color: #ffffff;
  padding: 0.9rem 1.2rem;
  border-radius: 10px;
  font-size: 0.9rem;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  z-index: 1200;
}

.upgrade-toast.fade-out {
  opacity: 0;
  transition: opacity 0.3s ease;
}

/* ── Related verdicts ── */
.related-verdicts {
  margin-top: 1.5rem;
  margin-bottom: 2rem;
}

.related-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.related-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
}

@media (max-width: 520px) {
  .related-grid {
    grid-template-columns: 1fr;
  }
}

/* ── Verdict vote ── */
.verdict-vote {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.vote-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.6rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.4;
}

.vote-buttons {
  display: flex;
  gap: 0.5rem;
}

.vote-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.4rem;
  padding-left: 0.6rem;
  cursor: pointer;
  transition: border-color 0.15s, opacity 0.15s, background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.vote-btn--agree {
  color: var(--yeah);
}

.vote-btn--disagree {
  color: var(--no);
}

.vote-btn:hover:not(:disabled) {
  border-color: var(--border-hover);
  background: var(--surface);
}

.vote-btn:disabled {
  cursor: default;
  opacity: 0.35;
}

.vote-btn.voted {
  opacity: 1;
  border-color: var(--border-hover);
  background: var(--surface);
}

.vote-count {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-left: 0.25rem;
}

.vote-btn.voted .vote-count {
  color: var(--text-secondary);
}

.vote-group {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.5rem;
}

/* ── Verdict date label ── */
.verdict-date-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.6rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* ── Confidence badge ── */
.confidence-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 0.25rem;
  margin-bottom: 1.25rem;
}

.confidence-badge {
  font-family: 'DM Mono', monospace;
  font-size: 0.7rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
}

.confidence-high {
  color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.confidence-medium {
  color: #f59e0b;
  background: rgba(245, 158, 11, 0.1);
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.confidence-low {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
}

.confidence-count {
  font-family: 'Inter', sans-serif;
  font-size: 0.72rem;
  color: var(--text-muted);
}

/* ── Queue state ── */
.queue-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  text-align: center;
}

.queue-label {
  font-family: 'Inter', sans-serif;
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0;
}

.queue-position {
  font-family: 'Inter', sans-serif;
  color: var(--text-primary);
  font-size: 1.4rem;
  margin: 0;
}

.queue-number {
  font-family: 'DM Mono', monospace;
  color: var(--split);
}

.queue-sub {
  font-family: 'Inter', sans-serif;
  color: var(--text-muted);
  font-size: 0.8rem;
  margin: 0;
}

/* Individual verdict page */
.verdict-page-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem;
  flex: 1 0 auto;
  width: 100%;
}

.verdict-page-header {
  margin-bottom: 1.5rem;
}

@media (max-width: 640px) {
  .trend-summary {
    grid-template-columns: 1fr;
  }

  .trend-chart {
    aspect-ratio: 640 / 300;
  }
}

/* ── Account panel ── */
.account-email-row {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  margin-bottom: 1.25rem;
}

.account-email-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.account-email {
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  color: var(--text-secondary);
  word-break: break-all;
}

.account-plan-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.account-plan-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 0.9rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: border-color 0.15s;
}

.account-plan-card--active {
  border-color: var(--border-focus);
}

.account-plan-badge {
  font-family: 'DM Mono', monospace;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.account-plan-badge--pro {
  color: var(--split);
}

.account-plan-name {
  font-family: 'DM Mono', monospace;
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1;
}

.account-plan-usage {
  display: flex;
  align-items: baseline;
  gap: 0.15rem;
  flex-wrap: wrap;
}

.account-usage-used {
  font-family: 'DM Mono', monospace;
  font-size: 1.15rem;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1;
}

.account-usage-sep,
.account-usage-limit {
  font-family: 'DM Mono', monospace;
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1;
}

.account-usage-unit {
  font-family: 'Inter', sans-serif;
  font-size: 0.7rem;
  color: var(--text-muted);
  width: 100%;
  margin-top: 0.1rem;
}

.account-plan-perks {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin-top: 0.1rem;
}

.account-perk {
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.account-perk::before {
  content: "+ ";
  color: var(--yeah);
  font-family: 'DM Mono', monospace;
  font-weight: 500;
}

.account-plan-price {
  font-family: 'DM Mono', monospace;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: auto;
  padding-top: 0.35rem;
}

.site-footer-shell {
  border-top: 1px solid var(--border);
  margin-top: 3rem;
}

.site-footer-inner {
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  padding: 1rem 2rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-footer-brand {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.site-footer-copy {
  font-family: 'Inter', sans-serif;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.site-footer-links,
.site-footer-social {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.site-footer-links a {
  font-family: 'Inter', sans-serif;
  font-size: 0.8rem;
  color: var(--text-secondary);
  text-decoration: none;
}

.site-footer-links a:hover {
  color: var(--text-primary);
}

.site-footer-social a {
  width: 18px;
  height: 18px;
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.site-footer-social a:hover {
  color: var(--text-primary);
}

.site-footer-social svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.content-page-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem;
  flex: 1 0 auto;
  width: 100%;
}

.content-page-header {
  margin-bottom: 1.5rem;
}

.content-page-kicker {
  display: inline-block;
  font-family: 'DM Mono', monospace;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 0.6rem;
}

.content-page-header h1 {
  font-family: 'Libre Baskerville', serif;
  font-size: 1.8rem;
  line-height: 1.2;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.content-page-intro {
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 720px;
}

.content-page-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 2rem;
}

.content-page-section + .content-page-section {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.content-page-section h2 {
  font-family: 'DM Mono', monospace;
  font-size: 0.88rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.content-page-section p {
  font-family: 'Inter', sans-serif;
  font-size: 0.92rem;
  line-height: 1.75;
  color: var(--text-secondary);
}

.content-page-section p + p {
  margin-top: 0.85rem;
}

@media (max-width: 768px) {
  .site-footer-inner {
    padding: 1rem 1rem 1.5rem;
    flex-direction: column;
    align-items: flex-start;
  }

  .content-page-container {
    padding: 1.5rem;
  }

  .content-page-card {
    padding: 1.25rem;
  }
}
