/*
 * Stylesheet for the Pass The Foundation SEO Knowledge Base (/resources/).
 *
 * These pages are plain, hand-authored static HTML — NOT part of the React
 * app/bundle — so they load instantly and are fully readable by any crawler
 * (including ones that don't execute JavaScript, like social-preview
 * scrapers) with zero build-tool coupling. This file is served verbatim
 * from a stable, un-hashed URL (public/ folder passthrough), so it's safe
 * to hardcode this path in every generated page.
 *
 * Colors are copied from tailwind.config.js (base/brand/signal/correct) so
 * these pages feel visually consistent with the main app without pulling in
 * the app's Tailwind build.
 */

:root {
  --base-50: #f6f7fa;
  --base-100: #eef0f5;
  --base-200: #dfe3ec;
  --base-300: #c6ccda;
  --base-400: #9aa3b8;
  --base-500: #6e7690;
  --base-600: #4f5670;
  --base-700: #383e54;
  --base-800: #262b3d;
  --base-900: #181b29;

  --brand-50: #eef1fb;
  --brand-100: #d7def5;
  --brand-200: #aebceb;
  --brand-600: #2c3b82;
  --brand-700: #232f68;
  --brand-800: #1c2652;

  --signal-600: #0e9488;
  --correct-500: #1fa971;

  --font-display: 'Space Grotesk', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--base-50);
  color: var(--base-900);
  font-family: var(--font-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--brand-800);
  color: #fff;
  padding: 0.6rem 1rem;
  z-index: 100;
  border-radius: 0 0 8px 0;
}
.skip-link:focus {
  left: 0;
}

a {
  color: var(--brand-600);
}
a:hover {
  color: var(--brand-800);
}

/* ---------- Site header ---------- */
.rpg-header {
  border-bottom: 1px solid var(--base-200);
  background: #fff;
}
.rpg-header__inner {
  max-width: 860px;
  margin: 0 auto;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.rpg-header__logo {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
}
.rpg-header__name {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--base-900);
  text-decoration: none;
}
.rpg-header__name:hover {
  color: var(--brand-700);
}

/* ---------- Breadcrumbs ---------- */
.rpg-breadcrumbs {
  max-width: 720px;
  margin: 1.5rem auto 0;
  padding: 0 1.25rem;
  font-size: 0.8rem;
  color: var(--base-500);
}
.rpg-breadcrumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
}
.rpg-breadcrumbs a {
  color: var(--base-500);
  text-decoration: none;
}
.rpg-breadcrumbs a:hover {
  color: var(--brand-700);
  text-decoration: underline;
}
.rpg-breadcrumbs li[aria-current='page'] {
  color: var(--base-700);
  font-weight: 500;
}
.rpg-breadcrumbs li:not(:last-child)::after {
  content: '/';
  margin-left: 0.35rem;
  color: var(--base-300);
}

/* ---------- Article ---------- */
.rpg-main {
  max-width: 720px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 4rem;
}
.rpg-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--signal-600);
  margin: 0 0 0.5rem;
}
.rpg-h1 {
  font-family: var(--font-display);
  font-size: 2rem;
  line-height: 1.2;
  font-weight: 600;
  color: var(--base-900);
  margin: 0 0 1.75rem;
}
.rpg-section {
  margin: 2.25rem 0;
}
.rpg-section h2 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--base-900);
  margin: 0 0 0.75rem;
}
.rpg-section h3 {
  font-family: var(--font-display);
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--base-800);
  margin: 1.5rem 0 0.5rem;
}
.rpg-section h3:first-of-type {
  margin-top: 1rem;
}

/* ---------- Comparison table (e.g. Incident vs Problem) ---------- */
.rpg-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.5rem 0 1rem;
  font-size: 0.9rem;
  background: #fff;
  border: 1px solid var(--base-200);
  border-radius: 10px;
  overflow: hidden;
}
.rpg-table th,
.rpg-table td {
  text-align: left;
  padding: 0.6rem 0.9rem;
  border-bottom: 1px solid var(--base-100);
}
.rpg-table thead th {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--brand-800);
  background: var(--base-50);
  border-bottom: 1px solid var(--base-200);
}
.rpg-table tbody tr:last-child td {
  border-bottom: none;
}
.rpg-table td {
  color: var(--base-700);
}
.rpg-section p {
  margin: 0 0 0.9rem;
  color: var(--base-700);
}
.rpg-section ul,
.rpg-section ol {
  margin: 0 0 0.9rem;
  padding-left: 1.25rem;
  color: var(--base-700);
}
.rpg-section li {
  margin-bottom: 0.4rem;
}

.rpg-intro {
  font-size: 1rem;
  color: var(--base-700);
  margin: 0 0 1.5rem;
}

.rpg-quick-answer {
  background: #fff;
  border: 1px solid var(--base-200);
  border-left: 4px solid var(--brand-600);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
}
.rpg-quick-answer h2 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--brand-700);
  font-family: var(--font-mono);
  margin-bottom: 0.5rem;
}
.rpg-quick-answer p {
  font-size: 1.05rem;
  color: var(--base-900);
  margin: 0;
}

/* ---------- Practice question ---------- */
.rpg-question-card {
  background: #fff;
  border: 1px solid var(--base-200);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
}
.rpg-question-card p.rpg-question-text {
  font-weight: 500;
  color: var(--base-900);
}
.rpg-question-card ol {
  list-style: upper-alpha;
  padding-left: 1.4rem;
}
.rpg-question-card details {
  margin-top: 1rem;
  border-top: 1px solid var(--base-200);
  padding-top: 0.85rem;
}
.rpg-question-card summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--brand-700);
}
.rpg-answer-correct {
  display: inline-block;
  margin-top: 0.5rem;
  font-weight: 600;
  color: var(--correct-500);
}

/* ---------- FAQ ---------- */
.rpg-faq details {
  background: #fff;
  border: 1px solid var(--base-200);
  border-radius: 10px;
  padding: 0.9rem 1.25rem;
  margin-bottom: 0.6rem;
}
.rpg-faq summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--base-900);
  list-style: none;
}
.rpg-faq summary::-webkit-details-marker {
  display: none;
}
.rpg-faq summary::before {
  content: '+ ';
  color: var(--brand-600);
  font-weight: 700;
}
.rpg-faq details[open] summary::before {
  content: '\2212 ';
}
.rpg-faq p {
  margin: 0.6rem 0 0.1rem;
  color: var(--base-700);
}

/* ---------- Related topics ---------- */
.rpg-related ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.rpg-related li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--base-100);
}
.rpg-related li:last-child {
  border-bottom: none;
}
.rpg-related .rpg-muted {
  color: var(--base-400);
}

/* ---------- CTA ---------- */
.rpg-cta {
  margin-top: 2.5rem;
  background: var(--brand-800);
  color: #fff;
  border-radius: 14px;
  padding: 2rem 1.75rem;
  text-align: center;
}
.rpg-cta h2 {
  font-family: var(--font-display);
  font-size: 1.4rem;
  margin: 0 0 0.6rem;
  color: #fff;
}
.rpg-cta p {
  color: var(--brand-100);
  max-width: 480px;
  margin: 0 auto 1.5rem;
}
.rpg-cta-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}
.rpg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.5rem;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  transition: transform 0.15s ease;
}
.rpg-btn:hover {
  transform: translateY(-1px);
}
.rpg-btn-primary {
  background: #fff;
  color: var(--brand-800);
}
.rpg-btn-secondary {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.4);
}

/* ---------- Resources hub ---------- */
.rpg-hub-list {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
  display: grid;
  gap: 1rem;
}
.rpg-hub-card {
  display: block;
  background: #fff;
  border: 1px solid var(--base-200);
  border-radius: 10px;
  padding: 1.25rem 1.5rem;
  text-decoration: none;
  transition: border-color 0.15s ease;
}
.rpg-hub-card:hover {
  border-color: var(--brand-600);
}
.rpg-hub-card h2 {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--base-900);
  margin: 0 0 0.4rem;
}
.rpg-hub-card p {
  color: var(--base-600);
  margin: 0;
  font-size: 0.9rem;
}

/* ---------- Footer (matches the app's Footer.tsx content/tone) ---------- */
.rpg-footer {
  border-top: 1px solid var(--base-800);
  background: var(--base-900);
  color: var(--base-400);
  text-align: center;
  font-size: 0.75rem;
  line-height: 1.6;
  padding: 1.5rem 1.25rem;
}
.rpg-footer a {
  color: var(--base-300);
  font-weight: 500;
}
.rpg-footer a:hover {
  color: #fff;
}
.rpg-footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.25rem 1rem;
  max-width: 640px;
  margin: 0.75rem auto;
}
.rpg-footer__disclaimer {
  max-width: 640px;
  margin: 1rem auto 0;
  padding-top: 1rem;
  border-top: 1px solid var(--base-800);
}

@media (max-width: 600px) {
  .rpg-h1 {
    font-size: 1.6rem;
  }
}
