:root {
  --bg: #0f1419;
  --surface: #1a2332;
  --surface-2: #223148;
  --border: #2d3a4d;
  --text: #e7ecf3;
  --muted: #8b9bb4;
  --accent: #5b9fd4;
  --accent-hover: #7ab3e0;
  --ok: #3dcc8a;
  --radius: 12px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Ubuntu, sans-serif;
  --max: 920px;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font);
  background: radial-gradient(1200px 600px at 20% -10%, #1a3050 0%, var(--bg) 55%);
  color: var(--text);
  line-height: 1.6;
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }
.site-header {
  border-bottom: 1px solid var(--border);
  background: rgba(15, 20, 25, 0.85);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 20;
}
.site-header .inner,
.site-footer .inner,
.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1rem;
}
.site-header .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.25rem;
  flex-wrap: wrap;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}
.brand {
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  text-decoration: none;
}
.brand:hover { text-decoration: none; color: var(--accent-hover); }
.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  font-size: 0.92rem;
  font-weight: 600;
}
.nav a { color: var(--muted); text-decoration: none; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.wrap { padding: 1.5rem 1rem 3rem; }
h1 {
  font-size: clamp(1.55rem, 4vw, 1.95rem);
  font-weight: 700;
  margin: 0 0 0.4rem;
  letter-spacing: -0.02em;
  line-height: 1.25;
}
h2 {
  font-size: 1.25rem;
  margin: 2rem 0 0.75rem;
  letter-spacing: -0.015em;
}
h3 {
  font-size: 1.05rem;
  margin: 1.25rem 0 0.45rem;
}
.sub, .lede { color: var(--muted); font-size: 1rem; margin: 0 0 1.25rem; max-width: 62ch; }
label.field-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}
textarea {
  width: 100%;
  min-height: 180px;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 1rem;
  resize: vertical;
  outline: none;
  transition: border-color 0.15s;
}
textarea:focus { border-color: var(--accent); }
.btns {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0;
}
button {
  appearance: none;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, transform 0.1s;
}
button:hover { border-color: var(--accent); background: var(--surface-2); }
button:active { transform: scale(0.98); }
button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #0a1220;
}
button.primary:hover { background: var(--accent-hover); }
button.copied {
  background: var(--ok);
  border-color: var(--ok);
  color: #0a1220;
}
.meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.85rem;
  margin-top: 0.35rem;
  flex-wrap: wrap;
}
.tool-card {
  background: rgba(26, 35, 50, 0.55);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 2px);
  padding: 1.1rem 1rem 1rem;
  margin-bottom: 0.5rem;
}
.privacy-note {
  color: var(--muted);
  font-size: 0.85rem;
  margin: 0.25rem 0 0;
}
.content section { margin-top: 0.5rem; }
.content p { margin: 0 0 0.9rem; max-width: 70ch; }
.content ul, .content ol { margin: 0 0 1rem; padding-left: 1.25rem; max-width: 70ch; }
.content li { margin-bottom: 0.4rem; }
.example-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: 1fr;
}
@media (min-width: 640px) {
  .example-grid { grid-template-columns: 1fr 1fr; }
}
.example {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
}
.example strong { display: block; margin-bottom: 0.35rem; }
.example code {
  display: block;
  font-size: 0.88rem;
  color: var(--muted);
  white-space: pre-wrap;
  word-break: break-word;
}
.faq details {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.75rem 1rem;
  margin-bottom: 0.55rem;
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before {
  content: "+ ";
  color: var(--accent);
  font-weight: 700;
}
.faq details[open] summary::before { content: "– "; }
.faq details p { margin: 0.65rem 0 0.15rem; color: var(--muted); }
.ad-slot {
  /* Placeholder only — no live AdSense until publisher ID provided */
  margin: 1.5rem 0;
  min-height: 90px;
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  background: rgba(26, 35, 50, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 0.75rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}
.ad-slot[hidden], .ad-slot.is-empty-ready {
  /* Keep layout reserved but visually quiet when empty */
}
.page-prose { max-width: 68ch; }
.page-prose p { margin: 0 0 1rem; }
.contact-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.15rem;
  margin: 1rem 0 1.5rem;
}
.contact-box dt { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.04em; color: var(--muted); margin-top: 0.75rem; }
.contact-box dt:first-child { margin-top: 0; }
.contact-box dd { margin: 0.2rem 0 0; }
.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0 2rem;
  color: var(--muted);
  font-size: 0.85rem;
}
.site-footer .inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 0.75rem 1rem; }
.footer-links a { color: var(--muted); }
.footer-links a:hover { color: var(--text); }
