*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink: #0f0e0d;
  --paper: #f5f2ec;
  --paper2: #ede9e0;
  --accent: #c8401a;
  --accent2: #1a4dc8;
  --muted: #7a756c;
  --border: rgba(15,14,13,0.12);
  --card-bg: #fff;
  --green: #1a6c2e;
  --green-bg: #edf7f0;
  --amber: #8a5a00;
  --amber-bg: #fdf6e3;
  --red: #b81c1c;
  --red-bg: #fdf0f0;
}

html { font-size: 16px; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--paper);
  color: var(--ink);
  min-height: 100vh;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.6;
}

.wrap { max-width: 720px; margin: 0 auto; padding: 0 24px; position: relative; z-index: 1; }

/* Header */
header {
  padding: 40px 0 0;
  display: flex;
  align-items: baseline;
  gap: 16px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 24px;
  flex-wrap: wrap;
}

.logo {
  font-family: 'Instrument Serif', serif;
  font-size: 22px;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.3px;
}

.logo span { color: var(--accent); font-style: italic; }

.logo-tag {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

nav {
  margin-left: auto;
  display: flex;
  gap: 20px;
  align-items: center;
}

nav a {
  font-size: 13px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 400;
  transition: color 0.12s;
}

nav a:hover { color: var(--ink); }

/* Breadcrumb */
.breadcrumb {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  padding: 20px 0 0;
  display: flex;
  gap: 6px;
  align-items: center;
}

.breadcrumb a { color: var(--muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--ink); }
.breadcrumb span { opacity: 0.5; }

/* Page hero */
.page-hero { padding: 36px 0 32px; }

.page-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 12px;
}

.page-headline {
  font-family: 'Instrument Serif', serif;
  font-size: clamp(28px, 5vw, 44px);
  line-height: 1.15;
  letter-spacing: -0.8px;
  color: var(--ink);
  margin-bottom: 14px;
}

.page-headline em { font-style: italic; color: var(--accent); }

.page-sub {
  font-size: 16px;
  color: var(--muted);
  line-height: 1.65;
  font-weight: 300;
  max-width: 560px;
}

/* Answer card */
.answer-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 24px;
}

.answer-card-header {
  padding: 20px 28px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
}

.answer-card-header h2 {
  font-family: 'Instrument Serif', serif;
  font-size: 22px;
  letter-spacing: -0.3px;
}

.tag {
  font-size: 12px;
  font-weight: 500;
  padding: 5px 12px;
  border-radius: 20px;
  flex-shrink: 0;
}

.tag-safe { background: var(--green-bg); color: var(--green); }
.tag-check { background: var(--amber-bg); color: var(--amber); }
.tag-info { background: var(--paper2); color: var(--muted); }

.answer-card-body { padding: 24px 28px; }

.answer-text {
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink);
  font-weight: 300;
  margin-bottom: 24px;
}

.answer-text p + p { margin-top: 14px; }

.answer-text strong { font-weight: 500; }

/* Details grid */
.details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.detail-pill {
  background: var(--paper);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
}

.detail-pill-label {
  font-family: 'DM Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 4px;
}

.detail-pill-value {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
}

/* Action box */
.action-box {
  background: var(--paper);
  border-left: 3px solid var(--ink);
  border-radius: 0 10px 10px 0;
  padding: 16px 18px;
  font-size: 14px;
  line-height: 1.65;
  color: var(--ink);
  font-weight: 300;
}

.action-box strong {
  font-weight: 500;
  display: block;
  margin-bottom: 4px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

/* Tool CTA */
.tool-cta {
  background: var(--ink);
  color: var(--paper);
  border-radius: 16px;
  padding: 28px;
  text-align: center;
  margin: 32px 0;
}

.tool-cta h3 {
  font-family: 'Instrument Serif', serif;
  font-size: 22px;
  margin-bottom: 8px;
}

.tool-cta p {
  font-size: 14px;
  opacity: 0.7;
  margin-bottom: 18px;
  font-weight: 300;
}

.tool-cta a {
  display: inline-block;
  background: var(--paper);
  color: var(--ink);
  border-radius: 10px;
  padding: 11px 24px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: opacity 0.15s;
}

.tool-cta a:hover { opacity: 0.85; }

/* FAQ */
.faq-section { padding: 40px 0; border-top: 1px solid var(--border); }

.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-bottom: 8px;
}

.section-heading {
  font-family: 'Instrument Serif', serif;
  font-size: 26px;
  letter-spacing: -0.4px;
  margin-bottom: 24px;
  color: var(--ink);
}

.faq-item { border-bottom: 1px solid var(--border); padding: 18px 0; }
.faq-item:first-of-type { border-top: 1px solid var(--border); }

.faq-q {
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 0;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.faq-q::after {
  content: '+';
  font-family: 'DM Mono', monospace;
  font-size: 18px;
  color: var(--muted);
  flex-shrink: 0;
  transition: transform 0.2s;
}

.faq-item.open .faq-q::after { transform: rotate(45deg); }

.faq-a {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.7;
  font-weight: 300;
  display: none;
  padding-top: 10px;
}

.faq-item.open .faq-a { display: block; }

/* Related charges */
.related-section { padding: 40px 0; border-top: 1px solid var(--border); }

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
  margin-top: 20px;
}

.related-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  text-decoration: none;
  color: var(--ink);
  transition: all 0.12s;
  display: block;
}

.related-card:hover { border-color: var(--ink); transform: translateY(-1px); }

.related-card-code {
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  color: var(--muted);
  margin-bottom: 4px;
}

.related-card-name {
  font-size: 14px;
  font-weight: 500;
}

/* Ad slot */
.ad-slot { margin: 28px 0; text-align: center; min-height: 90px; }

/* Footer */
footer {
  padding: 28px 0;
  border-top: 1px solid var(--border);
  margin-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-note { font-size: 12px; color: var(--muted); font-weight: 300; }
.footer-note a { color: var(--muted); }
.footer-tag { font-family: 'DM Mono', monospace; font-size: 11px; color: var(--muted); letter-spacing: 0.05em; }

/* Article body */
.article-body {
  font-size: 15px;
  line-height: 1.85;
  color: var(--ink);
  font-weight: 300;
  margin-bottom: 40px;
}

.article-body p { margin-bottom: 18px; }
.article-body p:last-child { margin-bottom: 0; }

.article-body h2 {
  font-family: 'Instrument Serif', serif;
  font-size: 22px;
  letter-spacing: -0.3px;
  color: var(--ink);
  margin: 36px 0 14px;
  padding-top: 36px;
  border-top: 1px solid var(--border);
}

.article-body h2:first-child { margin-top: 0; padding-top: 0; border-top: none; }

.article-body ul,
.article-body ol {
  padding-left: 22px;
  margin-bottom: 18px;
}

.article-body li {
  margin-bottom: 8px;
}

.article-body strong { font-weight: 500; }

.article-body a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.article-body .action-box {
  margin-top: 32px;
}

.article-body .action-box a {
  color: var(--ink);
  font-weight: 500;
}

@media (max-width: 500px) {
  header { padding-top: 28px; }
  nav { margin-left: 0; width: 100%; }
  .page-hero { padding: 24px 0 20px; }
  .answer-card-body { padding: 18px; }
  .answer-card-header { padding: 16px 18px; }
  footer { flex-direction: column; }
}
