:root {
  color-scheme: light;
  --page: #f3f5f2;
  --surface: #ffffff;
  --surface-muted: #f8faf8;
  --text: #17201c;
  --muted: #5d6962;
  --border: #d9e0da;
  --accent: #2563eb;
  --accent-dark: #1746ad;
  --focus: #b45309;
  --pass: #17663a;
  --pass-bg: #e8f6ed;
  --fail: #9f2f2f;
  --fail-bg: #fcecec;
  --radius: 14px;
  --shadow: 0 12px 34px rgb(23 32 28 / 7%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

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

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  background:
    radial-gradient(circle at 12% 0%, rgb(37 99 235 / 7%), transparent 27rem),
    var(--page);
  color: var(--text);
  font-size: 16px;
  line-height: 1.55;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
input[type="color"],
input[type="range"],
select {
  cursor: pointer;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
a:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

a {
  color: var(--accent-dark);
  text-underline-offset: 0.2em;
}

.skip-link {
  position: fixed;
  z-index: 20;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.7rem 1rem;
  border-radius: 8px;
  background: var(--text);
  color: white;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  z-index: 10;
  top: 0;
  border-bottom: 1px solid rgb(217 224 218 / 85%);
  background: rgb(243 245 242 / 90%);
  backdrop-filter: blur(14px);
}

.header-inner {
  display: flex;
  width: min(1160px, calc(100% - 2rem));
  min-height: 4.4rem;
  margin: 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 0.65rem;
  color: var(--text);
  font-weight: 760;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.brand-mark {
  width: 1.25rem;
  height: 1.25rem;
  border: 2px solid white;
  border-radius: 50%;
  background: conic-gradient(from 30deg, #ef4444, #eab308, #22c55e, #06b6d4, #2563eb, #8b5cf6, #ef4444);
  box-shadow: 0 0 0 1px var(--border);
}

nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem 1rem;
}

nav a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 650;
  text-decoration: none;
}

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

main {
  width: min(1160px, calc(100% - 2rem));
  margin: 0 auto;
}

.hero {
  padding: clamp(4rem, 10vw, 8rem) 0 clamp(3rem, 8vw, 6rem);
}

.eyebrow,
.section-index,
.preview-kicker,
.score-label {
  margin: 0 0 0.7rem;
  color: var(--accent-dark);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1 {
  max-width: 13ch;
  margin: 0;
  font-size: clamp(2.65rem, 7vw, 5.6rem);
  line-height: 0.98;
  letter-spacing: -0.065em;
}

.hero-copy {
  max-width: 62ch;
  margin: 1.6rem 0 0;
  color: var(--muted);
  font-size: clamp(1.05rem, 2vw, 1.25rem);
}

.hero-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.75rem;
}

.hero-pills span {
  padding: 0.42rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgb(255 255 255 / 70%);
  color: var(--muted);
  font-size: 0.83rem;
  font-weight: 650;
}

.notice {
  margin-bottom: 1rem;
  padding: 1rem;
  border: 1px solid #f2c36b;
  border-radius: 10px;
  background: #fff9e8;
}

.tool-card {
  margin-bottom: 1.25rem;
  padding: clamp(1.1rem, 3vw, 2rem);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
  scroll-margin-top: 5.5rem;
}

.section-heading {
  display: flex;
  margin-bottom: 1.5rem;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(1.6rem, 3vw, 2.15rem);
  line-height: 1.1;
  letter-spacing: -0.04em;
}

.section-heading > p {
  max-width: 42ch;
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
  text-align: right;
}

fieldset {
  min-width: 0;
  margin: 0;
  padding: 1rem;
  border: 1px solid var(--border);
  border-radius: 11px;
}

legend {
  padding: 0 0.4rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
}

label {
  display: grid;
  gap: 0.42rem;
  min-width: 0;
  color: var(--muted);
  font-size: 0.83rem;
  font-weight: 680;
}

input[type="text"],
input[type="number"],
input[readonly],
select,
textarea {
  width: 100%;
  min-height: 44px;
  padding: 0.65rem 0.75rem;
  border: 1px solid #cbd4cd;
  border-radius: 8px;
  background: white;
  color: var(--text);
}

input[readonly],
textarea[readonly] {
  background: var(--surface-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.83rem;
}

input[aria-invalid="true"] {
  border-color: var(--fail);
}

input[type="color"] {
  width: 100%;
  min-width: 54px;
  height: 48px;
  padding: 0.25rem;
  border: 1px solid #cbd4cd;
  border-radius: 8px;
  background: white;
}

input[type="range"] {
  width: 100%;
  min-height: 44px;
  accent-color: var(--accent);
}

button {
  min-height: 44px;
  padding: 0.62rem 0.9rem;
  border: 1px solid var(--text);
  border-radius: 8px;
  background: var(--text);
  color: white;
  font-size: 0.84rem;
  font-weight: 750;
}

button:hover:not(:disabled) {
  filter: brightness(1.1);
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
}

.secondary-button,
.copy-row button,
.code-output button,
.swap-button {
  border-color: var(--border);
  background: var(--surface-muted);
  color: var(--text);
}

