/* Example Domain clone — deliberately boring, perfectly executed.
   Tokens from brief: #F0F0F2 / #FFFFFF / #333333 / #334488 / #273A7A
   Single shared stylesheet for all pages. No imagery. */
:root {
  --bg: #F0F0F2;
  --bg-fallback: #EEEEEE;
  --surface: #FFFFFF;
  --text: #333333;
  --muted: #6B7280;
  --link: #334488;
  --link-hover: #273A7A;
  --border: #E5E7EB;
  --shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  --radius: 8px;
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg-fallback);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: flex;
  flex-direction: column;
}

/* Accessibility */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--link);
  color: #fff;
  padding: 8px 14px;
  border-radius: 0 0 6px 0;
  z-index: 50;
  font-size: 14px;
  text-decoration: none;
}
.skip-link:focus { left: 0; }

:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
  border-radius: 2px;
}

/* Shared minimal nav (same on all pages) */
.site-nav {
  background: transparent;
  padding: 18px 0 0;
}
.site-nav-inner {
  width: 90%;
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 13px;
}
.site-nav-inner.wide { max-width: 760px; }
.brand {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: -0.01em;
}
.brand:hover { color: var(--text); }
.site-nav-links { display: flex; gap: 16px; }
.site-nav-links a {
  color: var(--muted);
  text-decoration: none;
}
.site-nav-links a:hover { color: var(--link-hover); text-decoration: underline; }
.site-nav-links a.active { color: var(--link); font-weight: 500; }

/* Layout shell */
.viewport {
  flex: 1;
  display: grid;
  place-items: start center;
  align-content: start;
  padding: 0 16px 32px;
}
.viewport--top { align-content: start; }

/* Card — signature element */
.card {
  width: 90%;
  max-width: 600px;
  margin: 5em auto 1.5em;
  padding: 2em;
  background: var(--surface);
  border-radius: 5px;
  border-radius: var(--radius);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  box-shadow: var(--shadow);
  border: 1px solid transparent;
}
.card--wide {
  max-width: 760px;
  width: 90%;
}

.eyebrow {
  margin: 0 0 0.75em;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.4;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

h1 {
  margin: 0 0 0.5em;
  font-size: 28px;
  line-height: 1.2;
  letter-spacing: -0.02em;
  font-weight: 600;
  color: var(--text);
}

h2 {
  font-size: 18px;
  line-height: 1.35;
  letter-spacing: -0.01em;
  font-weight: 600;
  margin: 1.75em 0 0.5em;
}

p {
  margin: 0 0 1em;
  font-size: 16px;
  line-height: 1.6;
  font-weight: 400;
  max-width: 65ch;
}
p:last-child { margin-bottom: 0; }

/* Text link as CTA — only colour accent */
a.learn,
.inline-link,
.foot-note a,
.crumbs a,
.docs-foot a {
  color: var(--link);
  text-decoration: none;
}
a.learn:hover,
.inline-link:hover,
.foot-note a:hover,
.crumbs a:hover,
.docs-foot a:hover {
  color: var(--link-hover);
  text-decoration: underline;
}
a.learn:visited,
.inline-link:visited { color: var(--link); }

code, pre {
  font-family: var(--mono);
  font-size: 0.92em;
}
code {
  background: #F3F4F6;
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 0.1em 0.35em;
}
pre {
  background: #F9FAFB;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1em;
  overflow-x: auto;
  line-height: 1.55;
  font-size: 13.5px;
}
pre code {
  background: none;
  border: 0;
  padding: 0;
}

.foot-note,
.caption,
.docs-foot {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  margin: 0 auto;
  max-width: 600px;
}

.divider {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 1.5em 0;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  margin-top: 1em;
}

.btn {
  display: inline-block;
  font-family: var(--font);
  font-size: 14px;
  font-weight: 500;
  color: var(--link);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 14px;
  cursor: pointer;
}
.btn:hover {
  color: var(--link-hover);
  border-color: var(--link-hover);
}

/* Second page specifics — same boring language */
.crumbs {
  width: 90%;
  max-width: 760px;
  margin: 1.5em auto 0;
  font-size: 13px;
  color: var(--muted);
}
.crumbs [aria-current="page"] { color: var(--text); }

.lede { color: var(--text); }

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1em;
  margin: 1.5em 0;
}
.panel {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1em 1.1em;
  background: #FCFCFD;
}
.panel h2 { margin-top: 0; }
.clean-list {
  margin: 0.5em 0 0;
  padding-left: 1.1em;
  font-size: 14.5px;
  line-height: 1.65;
}
.hint { font-size: 13px; color: var(--muted); min-height: 1.4em; margin: 0.5em 0 0; }

.spec-table, .ref-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14.5px;
  margin: 1.25em 0;
}
.spec-table caption {
  text-align: left;
  font-size: 13px;
  color: var(--muted);
  padding-bottom: 0.5em;
}
.spec-table th, .spec-table td,
.ref-table th, .ref-table td {
  text-align: left;
  padding: 0.6em 0.7em;
  border: 1px solid var(--border);
}
.spec-table thead th, .ref-table thead th {
  background: #F9FAFB;
  font-weight: 600;
}

.site-footer {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  padding: 0 16px 28px;
}
.site-footer a { color: var(--link); text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }

/* Responsive — fluid only, no heavy breakpoints */
@media (max-width: 640px) {
  .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .card, .card--wide {
    margin: 2em auto 1em;
    padding: 1.5em;
  }
  h1 { font-size: 24px; }
  p { font-size: 15px; }
  .site-nav-inner { font-size: 12.5px; }
}

/* High-contrast edge only when needed */
@media (forced-colors: active) {
  .card { border: 1px solid CanvasText; }
}

/* Dark mode — same metrics, swapped surfaces */
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1A1A1A;
    --bg-fallback: #1A1A1A;
    --surface: #2A2A2A;
    --text: #E5E5E5;
    --muted: #9CA3AF;
    --link: #9DB4E8;
    --link-hover: #C3D2F2;
    --border: #3A3A3A;
    --shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
  }
  code { background: #333; border-color: #444; }
  pre, .panel { background: #222; border-color: #3A3A3A; }
  .spec-table thead th, .ref-table thead th { background: #222; }
  ::selection { background: rgba(157, 180, 232, 0.3); }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}
