/* Tech Myth or Fact
   Scoped to this page. Uses the site obsidian tokens from css/style.css. */

.tm-page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.25rem 1.25rem 4.5rem;
  color: var(--text);
}

.tm-crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin: 0.5rem 0 1.25rem;
  font-size: 0.85rem;
  color: var(--text-faint);
}

.tm-crumb a {
  color: var(--text-muted);
  text-decoration: none;
}

.tm-crumb a:hover {
  color: var(--primary-soft);
}

.tm-hero {
  position: static;
  top: auto;
  z-index: auto;
  max-width: 42rem;
  margin-bottom: 1.25rem;
  background: transparent;
  border: 0;
  box-shadow: none;
  backdrop-filter: none;
}

.tm-badge {
  display: inline-block;
  margin-bottom: 0.75rem;
  padding: 0.3rem 0.7rem;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  color: var(--primary-soft);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.tm-hero h1,
.tm-prose h2,
.tm-faq h2,
.tm-related h2,
.tm-claim,
.tm-score-heading {
  margin: 0 0 0.45rem;
  font-family: var(--font-brand), Georgia, serif;
  font-weight: 600;
}

.tm-hero h1 {
  font-size: clamp(2.2rem, 6vw, 3.6rem);
  line-height: 0.98;
  letter-spacing: -0.03em;
}

.tm-hero p,
.tm-prose p,
.tm-faq p,
.tm-hint,
.tm-explain,
.tm-why,
.tm-summary,
.tm-share,
.tm-answer-line {
  color: var(--text-muted);
  font-size: 1.02rem;
  line-height: 1.6;
}

.tm-hero p {
  margin: 0 0 0.9rem;
}

.tm-steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tm-steps li {
  margin: 0;
  padding: 0.75rem 0.8rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.tm-steps strong {
  display: block;
  margin-bottom: 0.15rem;
  color: var(--text);
}

.tm-client {
  margin: 1.25rem 0 2rem;
}

.tm-status {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.2rem 1rem;
  margin-bottom: 0.75rem;
}

.tm-status p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.92rem;
}

#tm-progress,
#tm-streak {
  color: var(--text);
  font-weight: 650;
}

#tm-streak {
  text-align: right;
}

.tm-meter {
  grid-column: 1 / -1;
  height: 6px;
  margin-top: 0.35rem;
  overflow: hidden;
  background: var(--bg-elevated);
  border-radius: 999px;
}

.tm-meter-fill {
  width: 0;
  height: 100%;
  background: var(--primary);
  transition: width 160ms ease;
}

.tm-stage {
  touch-action: pan-y;
}

.tm-card {
  min-height: 280px;
  padding: 1.25rem 1.2rem 1.1rem;
  background: var(--card);
  border: 1px solid var(--border-strong);
  border-radius: 18px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.28);
}

.tm-card.is-fresh {
  animation: tm-in 180ms ease;
}

.tm-card.is-dragging {
  animation: none;
  transition: none;
}

.tm-card.is-myth {
  border-color: #93c5fd;
}

.tm-card.is-fact {
  border-color: #86efac;
}

.tm-kicker {
  margin: 0 0 0.45rem;
  color: var(--primary-soft);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.tm-claim,
.tm-score-heading {
  font-size: clamp(1.45rem, 3vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.tm-actions,
.tm-score-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.7rem;
  margin-top: 1.1rem;
}

.tm-choice,
.tm-next,
.tm-copy,
.tm-again {
  min-height: 64px;
  padding: 0.85rem 1rem;
  border-radius: 14px;
  font: inherit;
  font-size: 1.15rem;
  font-weight: 700;
  cursor: pointer;
}

.tm-choice {
  color: var(--text);
  background: var(--bg-elevated);
  border: 1px solid var(--border-strong);
}

.tm-choice:hover,
.tm-next:hover,
.tm-copy:hover,
.tm-again:hover {
  border-color: var(--primary-soft);
}

.tm-myth {
  box-shadow: inset 4px 0 0 #93c5fd;
}

.tm-fact {
  box-shadow: inset -4px 0 0 #86efac;
}

.tm-swipe-note,
.tm-hint {
  margin: 0.75rem 0 0;
  color: var(--text-faint);
  font-size: 0.88rem;
}

.tm-judgement,
.tm-score-num,
.tm-streak-final,
.tm-copy-status {
  margin: 0.35rem 0;
  font-weight: 650;
}

.tm-judgement.is-right,
.tm-review li.is-right .tm-review-mark {
  color: #86efac;
}

.tm-judgement.is-wrong,
.tm-review li.is-wrong .tm-review-mark {
  color: #fecaca;
}

.tm-explain,
.tm-answer-line,
.tm-summary,
.tm-share {
  margin: 0.55rem 0 0;
}

.tm-why {
  margin: 0.7rem 0 0;
  padding: 0.75rem 0.8rem;
  background: var(--bg-elevated);
  border-radius: 12px;
}

.tm-why-label {
  display: block;
  margin-bottom: 0.15rem;
  color: var(--text);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.tm-next,
.tm-again {
  color: var(--primary-ink);
  background: var(--primary);
  border: 1px solid transparent;
}

.tm-copy {
  color: var(--text);
  background: transparent;
  border: 1px solid var(--border-strong);
}

.tm-score-num {
  color: var(--text);
  font-family: var(--font-brand), Georgia, serif;
  font-size: clamp(2rem, 5vw, 3rem);
  line-height: 1;
}

.tm-share {
  padding: 0.75rem 0.8rem;
  background: var(--bg-elevated);
  border-radius: 12px;
  overflow-wrap: anywhere;
}

.tm-review {
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
}

.tm-review li {
  display: grid;
  gap: 0.15rem;
  margin: 0;
  padding: 0.7rem 0;
  border-top: 1px solid var(--border);
}

.tm-review-mark {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.tm-review-claim {
  color: var(--text);
  line-height: 1.4;
}

.tm-review-answer {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.tm-choice:focus-visible,
.tm-next:focus-visible,
.tm-copy:focus-visible,
.tm-again:focus-visible,
.tm-claim:focus-visible,
.tm-judgement:focus-visible,
.tm-score-heading:focus-visible {
  outline: 2px solid var(--primary-soft);
  outline-offset: 3px;
}

.tm-prose,
.tm-faq,
.tm-related {
  max-width: 42rem;
  margin: 2rem 0;
}

.tm-prose h3 {
  margin: 1.4rem 0 0.4rem;
  font-family: var(--font-brand), Georgia, serif;
  font-size: 1.35rem;
  font-weight: 600;
}

.tm-prose a,
.tm-faq a {
  color: var(--primary-soft);
}

.tm-faq details {
  border-top: 1px solid var(--border);
}

.tm-faq summary {
  padding: 0.85rem 0;
  color: var(--text);
  font-weight: 650;
  cursor: pointer;
}

.tm-related-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.7rem;
}

.tm-related-grid a {
  display: block;
  padding: 0.9rem 1rem;
  color: var(--text-muted);
  text-decoration: none;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
}

.tm-related-grid a:hover {
  border-color: var(--primary-soft);
}

.tm-related-grid strong {
  display: block;
  margin-bottom: 0.2rem;
  color: var(--text);
}

.tm-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

@keyframes tm-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 700px) {
  .tm-page {
    padding: 1rem 0.9rem 4rem;
  }

  .tm-steps,
  .tm-related-grid {
    grid-template-columns: 1fr;
  }

  .tm-status {
    grid-template-columns: 1fr;
  }

  #tm-streak {
    text-align: left;
  }

  .tm-card {
    padding: 1rem 0.9rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tm-card,
  .tm-card.is-fresh,
  .tm-meter-fill,
  .tm-choice,
  .tm-next,
  .tm-copy,
  .tm-again {
    animation: none;
    transition: none;
  }
}
