@font-face {
  font-family: "Space Grotesk";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("./fonts/space-grotesk-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Fraunces";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("./fonts/fraunces-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light dark;
  /* Fallback for engines without light-dark(). */
  --paper: #f3f0e8;
  --paper-2: #faf8f1;
  --paper-3: #eae5d8;
  --ink: #17160f;
  --ink-2: #625d50;
  --ink-3: #6f695c;
  --line: #d9d3c4;
  --line-strong: #b9b1a0;
  --accent: #c2410c;
  --accent-soft: #f9e2d8;
  --ok: #1a6b43;
  --ok-soft: #e0f1e6;
  --err: #b3261e;
  --err-soft: #fae3e0;
  --warn: #8a5a00;
  --band-bg: #17160f;
  --band-ink: #f3f0e8;
  --paper: light-dark(#f3f0e8, #0e0e0d);
  --paper-2: light-dark(#faf8f1, #151513);
  --paper-3: light-dark(#eae5d8, #1d1c19);
  --ink: light-dark(#17160f, #f2efe6);
  --ink-2: light-dark(#625d50, #a8a296);
  --ink-3: light-dark(#6f695c, #938c7d);
  --line: light-dark(#d9d3c4, #2c2b26);
  --line-strong: light-dark(#b9b1a0, #46443c);
  --accent: light-dark(#c2410c, #ff6b3d);
  --accent-soft: light-dark(#f9e2d8, #2b1710);
  --ok: light-dark(#1a6b43, #72d49c);
  --ok-soft: light-dark(#e0f1e6, #12251a);
  --err: light-dark(#b3261e, #ff8a80);
  --err-soft: light-dark(#fae3e0, #2a1412);
  --warn: light-dark(#8a5a00, #f0bd63);
  --band-bg: light-dark(#17160f, #1d1c19);
  --band-ink: light-dark(#f3f0e8, #f2efe6);
  --terminal: #14140f;
  --terminal-2: #1c1b16;
  --terminal-ink: #e9e5d8;
  --terminal-muted: #8f8a7c;
  --radius: 6px;
  --radius-lg: 9px;
  --max: 1240px;
  --font-sans: "Space Grotesk", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, "SFMono-Regular", "Cascadia Code", "JetBrains Mono", Consolas, monospace;
  --shadow: 0 18px 50px rgba(0, 0, 0, 0.12);
}
[data-theme="light"] { color-scheme: light; }
[data-theme="dark"] { color-scheme: dark; }

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent); color: #fff; }

h1, h2, h3, h4, p, ul, ol, dl, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }

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

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.copy-fallback { position: fixed; top: 0; left: 0; opacity: 0; pointer-events: none; }
.icon { width: 18px; height: 18px; flex: none; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: 16px;
  z-index: 100;
  background: var(--ink);
  color: var(--paper);
  padding: 10px 14px;
  border-radius: 4px;
  font-size: 0.85rem;
}
.skip-link:focus { top: 12px; }
.noscript {
  max-width: var(--max);
  margin: 16px auto 0;
  padding: 10px 14px;
  border-left: 2px solid var(--accent);
  background: var(--accent-soft);
  color: var(--ink-2);
  font-size: 0.82rem;
}
@media (max-width: 560px) { .noscript { margin-left: 16px; margin-right: 16px; } }

.mono { font-family: var(--font-mono); }
.muted { color: var(--ink-2); }
.small { font-size: 0.82rem; }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.eyebrow-dot {
  width: 7px;
  height: 7px;
  background: var(--accent);
  border-radius: 50%;
  flex: none;
}
.kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  height: 22px;
  padding: 0 5px;
  border: 1px solid var(--line);
  border-bottom-color: var(--line-strong);
  border-radius: 4px;
  background: var(--paper);
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}
.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 24px;
  height: 66px;
  display: flex;
  align-items: center;
  gap: 28px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: -0.02em;
  flex: none;
}
.brand-mark {
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent);
  color: #fff;
  border-radius: 5px;
}
.brand-mark svg { width: 18px; height: 18px; }
.brand-name { font-size: 1.02rem; }
.brand-tld { color: var(--ink-2); font-weight: 400; }

.site-nav { display: flex; gap: 22px; font-size: 0.88rem; }
.site-nav a { color: var(--ink-2); transition: color 0.15s ease; }
.site-nav a:hover { color: var(--ink); }

.header-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.search-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  padding: 0 8px 0 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--ink-2);
  font-size: 0.83rem;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.search-trigger:hover { border-color: var(--line-strong); color: var(--ink); }
.search-trigger .icon { width: 15px; height: 15px; }
.search-trigger .kbd { border: 0; background: transparent; padding: 0 2px; }

.lang-switch {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 34px;
  min-width: 34px;
  padding: 0 6px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
}
.lang-switch:hover { border-color: var(--line-strong); color: var(--ink); }

.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper-2);
  color: var(--ink-2);
  transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}
.icon-btn:hover { color: var(--ink); border-color: var(--line-strong); background: var(--paper-3); }
.icon-btn .icon { width: 16px; height: 16px; }
.theme-dark { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-light { display: none; }
  :root:not([data-theme="light"]) .theme-dark { display: inline-flex; }
}
[data-theme="dark"] .theme-light { display: none; }
[data-theme="dark"] .theme-dark { display: inline-flex; }
[data-theme="light"] .theme-light { display: inline-flex; }
[data-theme="light"] .theme-dark { display: none; }

/* Buttons and links */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 8px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: var(--paper-2);
  color: var(--ink);
  font-size: 0.84rem;
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease, transform 0.15s ease;
}
.btn:hover { border-color: var(--ink); background: var(--paper-3); }
.btn .icon { width: 15px; height: 15px; }
.btn--primary { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.btn--primary:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn--ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn--ghost:hover { border-color: var(--line); background: var(--paper-2); color: var(--ink); }
.btn--sm { min-height: 30px; padding: 5px 10px; font-size: 0.76rem; }
.btn--sm .icon { width: 13px; height: 13px; }
.btn--lg { min-height: 46px; padding: 11px 20px; font-size: 0.92rem; }
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  color: var(--ink);
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 2px;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.text-link:hover { color: var(--accent); border-color: var(--accent); }
.text-link .icon { width: 14px; height: 14px; }
.text-btn {
  border: 0;
  background: none;
  padding: 0;
  color: var(--ink-2);
  font-size: 0.75rem;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.text-btn:hover { color: var(--ink); }

/* Hero */
.hero {
  max-width: var(--max);
  margin: 0 auto;
  padding: 76px 24px 0;
  position: relative;
  isolation: isolate;
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0 24px auto;
  height: 460px;
  background-image: radial-gradient(color-mix(in srgb, var(--ink) 13%, transparent) 1px, transparent 1px);
  background-size: 24px 24px;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 85%);
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 85%);
  pointer-events: none;
  z-index: -1;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .hero::before { background-image: radial-gradient(color-mix(in srgb, var(--ink) 22%, transparent) 1px, transparent 1px); }
}
[data-theme="dark"] .hero::before { background-image: radial-gradient(color-mix(in srgb, var(--ink) 22%, transparent) 1px, transparent 1px); }

.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(340px, 0.8fr);
  gap: 56px;
  align-items: center;
}
.hero-copy .eyebrow { margin-bottom: 22px; }
.hero h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(3.2rem, 7.6vw, 6.5rem);
  line-height: 0.94;
  letter-spacing: -0.035em;
  margin-left: -0.045em;
}
.hero h1 span { display: block; }
.hero h1 em {
  display: block;
  font-style: normal;
  color: var(--accent);
  font-weight: 400;
}
.hero .lead {
  max-width: 560px;
  margin-top: 28px;
  font-size: clamp(1rem, 1.4vw, 1.13rem);
  line-height: 1.65;
  color: var(--ink-2);
}
.hero-actions { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin-top: 32px; }

.hero-panel {
  background: var(--paper-2);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  box-shadow: 8px 8px 0 0 color-mix(in srgb, var(--line) 75%, transparent);
  overflow: hidden;
}
.panel-head,
.panel-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.panel-head { border-bottom: 1px solid var(--line); }
.panel-foot { border-top: 1px solid var(--line); }
.panel-foot .kbd { min-width: 34px; }
.pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 var(--accent);
  animation: pulse 2.8s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 45%, transparent); }
  70% { box-shadow: 0 0 0 7px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}
.panel-list li + li { border-top: 1px solid var(--line); }
.panel-list a {
  display: grid;
  grid-template-columns: 26px 1fr 18px;
  gap: 10px;
  align-items: center;
  padding: 13px 16px;
  transition: background 0.15s ease;
}
.panel-list a:hover { background: var(--accent-soft); }
.panel-list .icon { width: 15px; height: 15px; color: var(--ink-3); }
.panel-list a:hover .icon { color: var(--accent); }
.panel-num { font-family: var(--font-sans); font-size: 0.66rem; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.panel-text { min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.panel-text strong { font-size: 0.86rem; font-weight: 600; }
.panel-text small { color: var(--ink-2); font-size: 0.74rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.hero-stats {
  margin-top: 72px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.hero-stats span {
  display: flex;
  align-items: baseline;
  gap: 9px;
  padding: 18px 6px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.hero-stats span + span { border-left: 1px solid var(--line); padding-left: 20px; }
.hero-stats strong { font-family: var(--font-sans); font-size: 1.2rem; color: var(--ink); font-weight: 600; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }

/* Sections */
.tools-section,
.why-section,
.faq-section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 100px 24px 0;
  scroll-margin-top: 86px;
}
.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
  margin-bottom: 30px;
}
.section-head h2,
.faq-head h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2rem, 3.6vw, 3rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
  margin-top: 10px;
}
.section-head--stack { display: block; max-width: 720px; }
.lead--narrow { max-width: 620px; margin-top: 18px; color: var(--ink-2); font-size: 1.02rem; line-height: 1.65; }

.search-field {
  display: flex;
  align-items: center;
  gap: 9px;
  width: min(430px, 100%);
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--paper-2);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.search-field:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent);
}
.search-field .icon { width: 17px; height: 17px; color: var(--ink-2); }
.search-field input {
  flex: 1;
  min-width: 0;
  height: 44px;
  border: 0;
  background: transparent;
  outline: 0;
  font-size: 0.9rem;
}
.search-field input::placeholder { color: var(--ink-3); }
.search-field .kbd { flex: none; }

.filter-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}
.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip {
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font-size: 0.76rem;
  line-height: 1.3;
  transition: all 0.15s ease;
}
.chip:hover { border-color: var(--line-strong); color: var(--ink); }
.chip.is-active { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.result-count { font-family: var(--font-sans); font-size: 0.7rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-2); white-space: nowrap; font-variant-numeric: tabular-nums; }

.recent {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  padding: 10px 12px;
  margin-bottom: 20px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--paper-2) 60%, transparent);
}
.recent-label { font-family: var(--font-mono); font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--ink-2); }
.recent-list { display: flex; flex-wrap: wrap; gap: 6px; }
.recent-list a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  font-size: 0.74rem;
}
.recent-list a:hover { border-color: var(--accent); color: var(--accent); }
.recent-list .icon { width: 12px; height: 12px; }

.show-more-wrap { display: flex; justify-content: flex-start; margin: 0 0 16px; }
.tool-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}
.tool-card {
  display: flex;
  flex-direction: column;
  min-height: 196px;
  padding: 18px 18px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
  transition: border-color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}
.tool-card:hover {
  border-color: var(--ink);
  transform: translate(-2px, -2px);
  box-shadow: 4px 4px 0 0 var(--line);
}
.card-top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 20px; }
.card-index { font-family: var(--font-sans); font-size: 0.66rem; color: var(--ink-3); letter-spacing: 0.04em; font-variant-numeric: tabular-nums; }
.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 5px;
  background: var(--paper);
  color: var(--ink);
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}
.card-icon .icon { width: 19px; height: 19px; }
.tool-card:hover .card-icon { background: var(--accent); border-color: var(--accent); color: #fff; }
.tool-card h3 { font-size: 1.08rem; font-weight: 600; letter-spacing: -0.015em; margin-bottom: 5px; }
.tool-card p { font-size: 0.84rem; color: var(--ink-2); line-height: 1.5; flex: 1; }
.card-cta {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 18px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.card-cta .icon { width: 13px; height: 13px; transition: transform 0.18s ease; }
.tool-card:hover .card-cta { color: var(--accent); }
.tool-card:hover .card-cta .icon { transform: translateX(3px); }

.empty-state {
  padding: 60px 20px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  text-align: center;
}
.empty-state p:first-child { font-family: var(--font-display); font-size: 1.7rem; margin-bottom: 6px; }
.empty-state .btn { margin-top: 16px; }

/* Why */
.why-section {
  max-width: none;
  margin-top: 100px;
  padding: 74px 24px 78px;
  background: var(--band-bg);
  color: var(--band-ink);
}
.why-section .section-head,
.why-grid { max-width: var(--max); margin-left: auto; margin-right: auto; }
.why-section .eyebrow { color: color-mix(in srgb, var(--band-ink) 65%, transparent); }
.why-section .lead--narrow { color: color-mix(in srgb, var(--band-ink) 72%, transparent); }
.why-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 34px;
  margin-top: 50px;
}
.why-card { border-top: 1px solid color-mix(in srgb, var(--band-ink) 28%, transparent); padding-top: 18px; }
.why-num { font-family: var(--font-mono); font-size: 0.64rem; color: var(--accent); }
.why-card h3 { font-size: 1.06rem; margin: 22px 0 8px; }
.why-card p { font-size: 0.9rem; line-height: 1.65; color: color-mix(in srgb, var(--band-ink) 68%, transparent); }

/* FAQ */
.faq-section {
  display: grid;
  grid-template-columns: minmax(240px, 0.75fr) minmax(0, 1.4fr);
  gap: 60px;
  padding-bottom: 100px;
}
.faq-head .text-link { margin-top: 22px; }
.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 17px 0;
  cursor: pointer;
  font-size: 0.97rem;
  font-weight: 500;
  list-style: none;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary .plus { width: 17px; height: 17px; color: var(--ink-2); transition: transform 0.2s ease, color 0.2s ease; }
.faq-list details[open] summary .plus { transform: rotate(45deg); color: var(--accent); }
.faq-list details p { padding: 0 34px 18px 0; color: var(--ink-2); font-size: 0.9rem; line-height: 1.65; }
.faq-list--home { max-width: 820px; }

/* Tool page */
.page-wrap {
  max-width: 1160px;
  margin: 0 auto;
  padding: 30px 24px 100px;
}
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span[aria-current] { color: var(--ink); }
.tool-head { margin: 36px 0 26px; }
.tool-title-row { display: flex; gap: 20px; align-items: flex-start; }
.tool-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  flex: none;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent);
}
.tool-icon .icon { width: 27px; height: 27px; }
.tool-head .eyebrow { margin-top: 5px; margin-bottom: 7px; }
.tool-head h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  font-weight: 500;
  line-height: 1;
  letter-spacing: -0.03em;
}
.tool-head .lead { margin-top: 12px; max-width: 700px; color: var(--ink-2); font-size: 1.02rem; line-height: 1.55; }
.meta-pills { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 20px; }
.meta-pills span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.61rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.meta-pills .icon { width: 12px; height: 12px; }
.meta-favorite {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 0.61rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.meta-favorite:hover { border-color: var(--accent); color: var(--accent); }
.meta-favorite.is-active { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }
.meta-favorite.is-active .icon { fill: currentColor; }
.meta-favorite .icon { width: 12px; height: 12px; }
.tool-meta-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.tool-byline { font-family: var(--font-mono); font-size: 0.64rem; color: var(--ink-3); }
.tool-byline a { color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; }
.tool-byline a:hover { color: var(--accent); }
.tool-note {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 560px;
  font-size: 0.74rem;
  color: var(--ink-2);
}
.tool-note .icon { width: 13px; height: 13px; color: var(--accent); }
.facts {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 22px 0 8px;
}
.facts li {
  padding: 5px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.footer-top {
  color: var(--ink-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.footer-top:hover { color: var(--accent); }
.to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 35;
  width: 40px;
  height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--paper-2);
  color: var(--ink);
  font-size: 1.1rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}
.to-top:hover { border-color: var(--accent); color: var(--accent); }

/* Workspace */
.workspace {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  overflow: hidden;
  box-shadow: 0 1px 0 0 color-mix(in srgb, var(--line) 70%, transparent);
}
.ws-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--paper-3) 55%, var(--paper-2));
}
.ws-label {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.ws-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}
.ws-badge .icon { width: 12px; height: 12px; }
.ws-meta { font-family: var(--font-mono); font-size: 0.64rem; color: var(--ink-2); }
.ws-body { padding: 18px; }
.ws-body > * + * { margin-top: 16px; }

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field label {
  font-family: var(--font-mono);
  font-size: 0.63rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.field-hint { font-family: var(--font-mono); font-size: 0.6rem; color: var(--ink-3); }
.input,
.textarea,
select.input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
  color: var(--ink);
  padding: 9px 11px;
  font-size: 0.88rem;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.input:focus,
.textarea:focus {
  outline: 0;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 12%, transparent);
}
select.input { appearance: auto; }
.input--short { width: 150px; }
.textarea {
  resize: vertical;
  min-height: 84px;
  line-height: 1.55;
}
input[type="file"] { padding: 7px 9px; font-size: 0.8rem; }
input[type="file"]::file-selector-button {
  margin-right: 10px;
  padding: 5px 9px;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: var(--paper-3);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 0.76rem;
  cursor: pointer;
}
input[type="file"]::file-selector-button:hover { border-color: var(--ink); }
.code,
textarea.code,
input.code {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.6;
}
.range { width: 100%; accent-color: var(--accent); }
.color-input {
  width: 68px;
  height: 42px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
}

.controls-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  align-items: end;
}
.checks-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px 16px;
}
.check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.84rem;
  color: var(--ink-2);
  cursor: pointer;
  min-height: 30px;
}
.check input { accent-color: var(--accent); width: 15px; height: 15px; flex: none; }
.check:hover { color: var(--ink); }

.actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.actions .hint { margin-left: 2px; }
.hint { color: var(--ink-3); font-size: 0.76rem; line-height: 1.5; }
.status { min-height: 20px; font-family: var(--font-mono); font-size: 0.72rem; color: var(--ink-2); }
.status.is-error { color: var(--err); }
.status.is-ok { color: var(--ok); }
.count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 20px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--paper-3);
  color: var(--ink-2);
  font-size: 0.6rem;
}

.toolbar { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 14px; }
.field--inline { flex-direction: row; align-items: center; gap: 7px; }
.field--inline label { margin: 0; white-space: nowrap; }
.field--inline .input { width: auto; min-width: 100px; }
.field--grow { flex: 1; min-width: 180px; }
.field--grow .input { width: 100%; }
.toolbar-end { margin-left: auto; display: flex; gap: 6px; flex-wrap: wrap; }

.work-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.work-grid .field { min-width: 0; }
.work-grid .textarea { min-height: 180px; }

.seg {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 4px;
  overflow: hidden;
  background: var(--paper);
}
.seg-opt { position: relative; }
.seg-opt input { position: absolute; opacity: 0; pointer-events: none; }
.seg-opt span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 5px 12px;
  font-size: 0.78rem;
  color: var(--ink-2);
  cursor: pointer;
  border-right: 1px solid var(--line);
}
.seg-opt:last-child span { border-right: 0; }
.seg-opt input:checked + span { background: var(--ink); color: var(--paper); }
.seg-opt input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: -3px; }
.seg-opt span:hover { color: var(--ink); }
.seg-opt input:checked + span:hover { color: var(--paper); }

.output { border-top: 1px solid var(--line); }
.ws-body + .output { border-top: 1px solid var(--line); }
.output-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 9px 16px;
  background: color-mix(in srgb, var(--paper-3) 55%, var(--paper-2));
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.output-meta { letter-spacing: 0; text-transform: none; }
.output-pre {
  margin: 0;
  padding: 16px;
  min-height: 74px;
  max-height: 380px;
  overflow: auto;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.65;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  tab-size: 2;
}
.output-pre--short { min-height: 120px; max-height: 260px; }
.output-pre:empty::before { content: attr(data-empty); color: var(--terminal-muted); }
.code-view {
  margin: 0;
  padding: 16px;
  overflow: auto;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  line-height: 1.65;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  tab-size: 2;
}
.work-grid > .field > .code-view { min-height: 332px; max-height: 620px; height: 100%; }
.code-view .tok-key { color: #ffb27a; }
.code-view .tok-string { color: #9fe8bd; }
.code-view .tok-number { color: #8ab4ff; }
.code-view .tok-bool { color: #f0bd63; }
.code-view .tok-punct { color: #8f8a7c; }
.code-view .tok-comment { color: #8f8a7c; font-style: italic; }
.code-view .tok-keyword { color: #ff9b8f; }
.code-view .tok-type { color: #7dd3fc; }
.output-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 16px;
  border-top: 1px solid var(--line);
}
.output-actions .btn { background: var(--paper); }

.pw-result {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 18px 16px;
  background: var(--terminal);
}
.pw-result code {
  flex: 1;
  min-width: 0;
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: clamp(0.9rem, 2vw, 1.18rem);
  letter-spacing: 0.03em;
  overflow-wrap: anywhere;
}
.pw-result .btn {
  flex: none;
  border-color: var(--terminal-muted);
  background: var(--terminal-2);
  color: var(--terminal-ink);
}
.pw-result .btn:hover { border-color: var(--accent); color: #fff; background: var(--accent); }
.strength { padding: 0 16px; margin-top: 12px; }
.strength progress {
  width: 100%;
  height: 6px;
  appearance: none;
  border: 0;
  border-radius: 99px;
  overflow: hidden;
  background: var(--line);
}
.strength progress::-webkit-progress-bar { background: var(--line); }
.strength progress::-webkit-progress-value { background: var(--accent); transition: width 0.2s ease; }
.strength progress::-moz-progress-bar { background: var(--accent); }
.strength[data-level="weak"] progress::-webkit-progress-value { background: var(--err); }
.strength[data-level="weak"] progress::-moz-progress-bar { background: var(--err); }
.strength[data-level="fair"] progress::-webkit-progress-value { background: var(--warn); }
.strength[data-level="fair"] progress::-moz-progress-bar { background: var(--warn); }
.strength[data-level="strong"] progress::-webkit-progress-value { background: var(--ok); }
.strength[data-level="strong"] progress::-moz-progress-bar { background: var(--ok); }
.strength-legend {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 16px 2px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--ink-2);
}
.pw .ws-body .hint { margin-top: 0; }

.prose-output {
  padding: 18px 16px;
  min-height: 120px;
  max-height: 380px;
  overflow: auto;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-size: 0.92rem;
  line-height: 1.75;
  white-space: pre-wrap;
}
.prose-output p + p { margin-top: 1em; }

.hash-output {
  display: block;
  padding: 18px 16px;
  min-height: 66px;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: 0.86rem;
  line-height: 1.7;
  overflow-wrap: anywhere;
}
.diff-list { max-height: 380px; overflow: auto; }
.diff-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) minmax(0, 1.2fr);
  gap: 10px;
  align-items: start;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.74rem;
}
.diff-row:last-child { border-bottom: 0; }
.diff-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 3px;
  font-size: 0.66rem;
  font-weight: 700;
}
.diff-tag--added { background: var(--ok-soft); color: var(--ok); }
.diff-tag--removed { background: var(--err-soft); color: var(--err); }
.diff-tag--changed { background: var(--accent-soft); color: var(--accent); }
.diff-path { overflow-wrap: anywhere; }
.diff-values { color: var(--ink-2); overflow-wrap: anywhere; }
.diff-values del { color: var(--err); text-decoration: line-through; }
.diff-values ins { color: var(--ok); text-decoration: none; }
.diff-empty { padding: 22px 16px; color: var(--ink-2); font-family: var(--font-mono); font-size: 0.78rem; }

.kv-list { border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.kv-row {
  display: grid;
  grid-template-columns: 120px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.kv-row:last-child { border-bottom: 0; }
.kv-row .micro-label { margin: 0; }
.kv-key { font-family: var(--font-mono); font-size: 0.76rem; color: var(--accent); overflow-wrap: anywhere; }
.kv-value { font-family: var(--font-mono); font-size: 0.76rem; overflow-wrap: anywhere; }
.kv-list .diff-empty { padding: 14px 12px; }

.perm-grid {
  display: grid;
  grid-template-columns: minmax(90px, 1fr) repeat(3, 70px);
  gap: 6px 10px;
  align-items: center;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
}
.perm-head,
.perm-scope { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink-3); }
.perm-grid .check { min-height: 26px; justify-content: center; }
.perm-grid .check span { font-family: var(--font-mono); font-size: 0.68rem; }
.inline-input { display: flex; gap: 8px; align-items: center; }
.inline-input .input { flex: 1; min-width: 0; }
.inline-input .btn { flex: none; }
.semver-result {
  display: flex;
  align-items: center;
  min-height: 38px;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: 0.82rem;
}

.zone-list { border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.zone-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 13px;
  border-bottom: 1px solid var(--line);
  border-left: 3px solid transparent;
  background: var(--paper);
}
.zone-row:last-child { border-bottom: 0; }
.zone-row.is-work { border-left-color: var(--ok); }
.zone-row.is-off { border-left-color: var(--line-strong); }
.zone-row.is-night { border-left-color: var(--err); background: var(--err-soft); }
.zone-row strong { display: block; font-size: 0.84rem; font-weight: 500; }
.zone-label { display: block; font-family: var(--font-mono); font-size: 0.6rem; color: var(--ink-3); margin-top: 2px; }
.zone-row code { font-family: var(--font-mono); font-size: 0.76rem; text-align: right; }

.totp-panel {
  padding: 22px 16px;
  border-radius: 5px;
  background: var(--terminal);
  color: var(--terminal-ink);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.totp-panel code {
  font-family: var(--font-mono);
  font-size: clamp(2rem, 7vw, 3.5rem);
  letter-spacing: 0.16em;
  color: var(--accent);
  line-height: 1.1;
  text-align: center;
}
.totp-progress { display: flex; align-items: center; gap: 10px; width: min(100%, 460px); }
.totp-progress progress { flex: 1; height: 6px; accent-color: var(--accent); }
.totp-progress span { font-size: 0.7rem; color: var(--terminal-muted); min-width: 34px; text-align: right; }

.stat-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px; }
.stat-card { padding: 13px 14px; border: 1px solid var(--line); border-radius: 5px; background: var(--paper); }
.stat-card strong { display: block; font-family: var(--font-sans); font-size: 1.5rem; font-weight: 600; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-card span { display: block; margin-top: 4px; font-family: var(--font-mono); font-size: 0.58rem; letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink-3); }
.word-list { border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.word-row {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) 34px;
  gap: 8px;
  align-items: center;
  padding: 7px 10px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.word-row:last-child { border-bottom: 0; }
.word-row .micro-label { margin: 0; }
.word-row code { font-family: var(--font-mono); font-size: 0.76rem; overflow-wrap: anywhere; }
.word-row > span:last-child { font-family: var(--font-mono); font-size: 0.7rem; color: var(--accent); text-align: right; }
.slug-output {
  display: block;
  padding: 18px 16px;
  min-height: 62px;
  background: var(--terminal);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: clamp(1rem, 2.4vw, 1.35rem);
  overflow-wrap: anywhere;
}

.claims { display: flex; flex-wrap: wrap; gap: 7px; }
.claim {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--ink-2);
}
.claim strong { color: var(--ink); font-weight: 500; }
.claim--ok { border-color: color-mix(in srgb, var(--ok) 40%, var(--line)); color: var(--ok); }
.claim--err { border-color: color-mix(in srgb, var(--err) 40%, var(--line)); color: var(--err); }
.notice {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 11px 13px;
  border-left: 2px solid var(--accent);
  background: var(--accent-soft);
  color: var(--ink-2);
  font-size: 0.82rem;
  line-height: 1.55;
}
.notice .icon { color: var(--accent); margin-top: 2px; }

.regex-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--terminal);
  color: var(--terminal-muted);
}
.regex-slash { font-family: var(--font-mono); font-size: 0.9rem; color: var(--terminal-muted); }
.regex-input {
  flex: 1;
  width: auto;
  min-width: 0;
  border: 0;
  background: transparent;
  color: var(--terminal-ink);
  box-shadow: none;
  padding: 4px 2px;
  font-size: 0.86rem;
}
.regex-input:focus { box-shadow: none; border: 0; }
.flags { display: flex; gap: 3px; margin-left: 4px; }
.flag { position: relative; }
.flag input { position: absolute; opacity: 0; }
.flag span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 3px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--terminal-muted);
  cursor: pointer;
}
.flag input:checked + span { background: var(--accent); color: #fff; }
.flag input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 1px; }

.regex-highlight {
  margin: 0;
  padding: 12px;
  min-height: 180px;
  max-height: 260px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.regex-highlight mark { background: var(--accent); color: #fff; border-radius: 2px; padding: 0 1px; }
.regex-highlight .regex-empty { color: var(--terminal-muted); }
.match-list {
  max-height: 260px;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
}
.match-list li { padding: 8px 11px; border-bottom: 1px solid var(--line); font-size: 0.76rem; }
.match-list li:last-child { border-bottom: 0; }
.match-head { display: flex; gap: 8px; align-items: baseline; font-family: var(--font-mono); }
.match-head code { color: var(--accent); overflow-wrap: anywhere; }
.match-index { color: var(--ink-3); font-size: 0.62rem; white-space: nowrap; }
.match-groups { margin-top: 3px; color: var(--ink-2); font-family: var(--font-mono); font-size: 0.68rem; overflow-wrap: anywhere; }
.match-empty { padding: 14px 11px; color: var(--ink-3); font-size: 0.76rem; }

.cron-fields { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.cron-field { text-align: center; }
.cron-result {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
}
.micro-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 3px;
}
.cron-expression { font-family: var(--font-mono); font-size: 1.05rem; color: var(--accent); }
.cron-description { font-size: 0.92rem; color: var(--ink-2); }
.run-list { display: grid; gap: 0; border-top: 1px solid var(--line); }
.run-list li {
  padding: 7px 0;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: var(--ink-2);
}
.run-list li span { color: var(--ink-3); margin-right: 10px; }

.ts-grid { border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.ts-row {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 9px 12px;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.ts-row:last-child { border-bottom: 0; }
.ts-row > span:first-child {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.ts-row code { font-family: var(--font-mono); font-size: 0.79rem; overflow-wrap: anywhere; }
.ts-row .icon-btn { width: 28px; height: 28px; }
.ts-row .icon-btn .icon { width: 13px; height: 13px; }
.ts-zone { display: flex; align-items: center; gap: 8px; min-width: 0; flex-wrap: wrap; }
.ts-zone .input { width: auto; min-width: 150px; padding: 5px 8px; font-size: 0.74rem; }

.diff-lines {
  max-height: 420px;
  overflow: auto;
  background: var(--terminal);
  color: var(--terminal-ink);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  line-height: 1.6;
}
.diff-line { display: grid; grid-template-columns: 8px 42px minmax(0, 1fr); }
.diff-line span { padding: 1px 8px; }
.diff-line .ln { color: var(--terminal-muted); text-align: right; user-select: none; border-right: 1px solid #2e2c24; }
.diff-line .dl { white-space: pre-wrap; overflow-wrap: anywhere; }
.diff-line--add { background: rgba(56, 161, 105, 0.18); }
.diff-line--add .dl { color: #9fe8bd; }
.diff-line--del { background: rgba(229, 62, 62, 0.16); }
.diff-line--del .dl { color: #f5a3a3; }
.diff-line--same .dl { color: var(--terminal-muted); }
.diff-line .marker { color: var(--terminal-muted); user-select: none; }
.diff-line--add .marker { color: #9fe8bd; }
.diff-line--del .marker { color: #f5a3a3; }

.case-results, .format-grid { border: 1px solid var(--line); border-radius: 4px; overflow: hidden; }
.case-row, .format-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.case-row:last-child, .format-row:last-child { border-bottom: 0; }
.case-label, .format-label {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-2);
}
.case-value, .format-row code { font-family: var(--font-mono); font-size: 0.79rem; overflow-wrap: anywhere; }
.case-row .icon-btn, .format-row .icon-btn { width: 28px; height: 28px; }
.case-row .icon-btn .icon, .format-row .icon-btn .icon { width: 13px; height: 13px; }
.format-row code { color: var(--accent); }

.color-head { display: flex; gap: 18px; align-items: stretch; }
.swatch { width: 150px; min-height: 120px; border: 1px solid var(--line); border-radius: 5px; background: #e2481f; flex: none; }
.color-controls { flex: 1; display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.color-controls .field { min-width: 150px; }
.color-controls .status { flex-basis: 100%; margin: 0; }
.contrast-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.contrast-card {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
}
.contrast-card[data-bg="white"] { background: #fff; color: #17160f; }
.contrast-card[data-bg="black"] { background: #17160f; color: #f3f0e8; }
.contrast-card[data-bg="white"] .micro-label { color: #625d50; }
.contrast-card[data-bg="black"] .micro-label { color: #a8a296; }
.contrast-card strong { font-family: var(--font-mono); font-size: 1.2rem; }
.contrast-card .badge {
  padding: 3px 7px;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  text-transform: uppercase;
}
.badge.is-pass { color: var(--ok); }
.contrast-card[data-bg="black"] .badge.is-pass { color: #72d49c; }
.badge.is-fail { color: var(--err); }
.contrast-card[data-bg="black"] .badge.is-fail { color: #ff8a80; }

.http-list { border: 1px solid var(--line); border-radius: 4px; overflow: hidden; max-height: 640px; overflow-y: auto; }
.http-row {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 190px;
  gap: 14px;
  align-items: baseline;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.http-row:last-child { border-bottom: 0; }
.http-code { font-family: var(--font-sans); font-size: 1rem; color: var(--accent); font-variant-numeric: tabular-nums; font-weight: 500; }
.http-body .http-title { display: block; font-size: 0.9rem; font-weight: 600; }
.http-body p { margin-top: 2px; font-size: 0.8rem; color: var(--ink-2); line-height: 1.5; }
.http-name { font-size: 0.66rem; color: var(--ink-3); text-align: right; }
.empty { padding: 30px; text-align: center; color: var(--ink-2); border: 1px dashed var(--line-strong); }

/* Below tool */
.below-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 60px;
  margin-top: 70px;
}
.prose h2 {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 2.4vw, 2rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 46px 0 14px;
}
.prose h2:first-child { margin-top: 0; }
.prose > p { color: var(--ink-2); font-size: 0.95rem; line-height: 1.75; max-width: 720px; }
.steps { counter-reset: step; margin-top: 6px; border-top: 1px solid var(--line); }
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 34px 1fr;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink-2);
  font-size: 0.9rem;
}
.steps li::before {
  content: "0" counter(step);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--accent);
  padding-top: 3px;
}
.prose .faq-list { margin-top: 6px; }
.related-aside { position: sticky; top: 90px; align-self: start; }
.related-aside h2 {
  font-family: var(--font-mono);
  font-size: 0.64rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 10px;
}
.related-list { border-top: 1px solid var(--line); }
.related-list li { border-bottom: 1px solid var(--line); }
.related-list a { display: grid; grid-template-columns: 30px 1fr 14px; gap: 10px; align-items: center; padding: 12px 0; }
.related-list a:hover strong { color: var(--accent); }
.related-icon { color: var(--ink-2); display: inline-flex; }
.related-icon .icon { width: 17px; height: 17px; }
.related-list a > span:nth-child(2) { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.related-list strong { font-size: 0.84rem; font-weight: 500; transition: color 0.15s ease; }
.related-list small { color: var(--ink-3); font-size: 0.71rem; line-height: 1.4; }
.related-list a > .icon { width: 13px; height: 13px; color: var(--ink-3); }
.related-list a:hover > .icon { color: var(--accent); }
.aside-note {
  margin-top: 24px;
  padding: 15px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-2);
}
.aside-note .icon { color: var(--accent); width: 17px; height: 17px; }
.aside-note p { color: var(--ink-2); font-size: 0.78rem; line-height: 1.55; margin: 7px 0 10px; }
.back-link { display: inline-flex; align-items: center; gap: 7px; margin-top: 50px; font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--ink-2); }
.back-link:hover { color: var(--accent); }

/* Simple pages */
.simple-head { margin: 42px 0 40px; max-width: 800px; }
.simple-head h1 { font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 500; letter-spacing: -0.03em; line-height: 1.02; margin-top: 14px; }
.simple-head .lead { color: var(--ink-2); margin-top: 16px; font-size: 1.05rem; line-height: 1.65; }
.page-prose { max-width: 900px; padding-bottom: 60px; }
.page-prose section { margin-top: 34px; }
.page-prose section h2 { margin-top: 0; font-size: 1.5rem; }
.page-prose section p { max-width: 760px; }
.back-link-wrap { margin-top: 50px; }
.notfound { padding-top: 100px; padding-bottom: 120px; }
.notfound h1 { font-family: var(--font-display); font-size: clamp(3rem, 8vw, 6rem); font-weight: 500; letter-spacing: -0.04em; line-height: 1; margin: 14px 0; }
.notfound .lead { color: var(--ink-2); margin-bottom: 26px; }
.notfound .btn { margin-bottom: 30px; }

/* Palette */
.palette {
  width: min(640px, calc(100% - 32px));
  max-height: 72vh;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--paper-2);
  color: var(--ink);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin: 12vh auto auto;
}
.palette::backdrop { background: rgba(10, 10, 8, 0.55); backdrop-filter: blur(3px); }
.palette-top { display: flex; align-items: center; gap: 10px; padding: 11px 13px; border-bottom: 1px solid var(--line); }
.palette-top > .icon { color: var(--ink-2); }
.palette-input { flex: 1; min-width: 0; border: 0; background: transparent; outline: 0; font-size: 0.98rem; }
.palette-input::placeholder { color: var(--ink-3); }
.palette-list { max-height: 52vh; overflow: auto; padding: 6px; }
.palette-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
  padding: 9px 10px;
  border-radius: 5px;
  cursor: pointer;
}
.palette-item[aria-selected="true"] { background: var(--accent-soft); }
.palette-item:hover { background: var(--paper-3); }
.palette-item[aria-selected="true"]:hover { background: var(--accent-soft); }
.palette-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--paper);
  color: var(--ink-2);
}
.palette-item[aria-selected="true"] .palette-icon { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 35%, var(--line)); }
.palette-icon .icon { width: 16px; height: 16px; }
.palette-text { min-width: 0; display: flex; flex-direction: column; }
.palette-text strong { font-size: 0.86rem; font-weight: 500; }
.palette-text small { color: var(--ink-3); font-size: 0.72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.palette-cat { font-family: var(--font-mono); font-size: 0.58rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--ink-3); }
.palette-empty { padding: 22px; text-align: center; color: var(--ink-2); font-size: 0.85rem; }
.palette-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 13px;
  border-top: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.6rem;
  color: var(--ink-3);
}

/* Toast */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 80;
  transform: translate(-50%, 18px);
  padding: 9px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: var(--ink);
  color: var(--paper);
  font-size: 0.8rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }
.toast.is-error { background: var(--err); color: #fff; border-color: var(--err); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 80px; }
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 54px 24px 40px;
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 50px;
}
.footer-brand p { margin-top: 14px; max-width: 380px; color: var(--ink-2); font-size: 0.88rem; line-height: 1.65; }
.footer-note { display: flex; gap: 7px; align-items: flex-start; font-size: 0.76rem !important; color: var(--ink-3) !important; }
.footer-note .icon { width: 14px; height: 14px; color: var(--accent); margin-top: 3px; }
.footer-cols { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.footer-col h2 {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 12px;
}
.footer-col li + li { margin-top: 8px; }
.footer-col a { font-size: 0.84rem; color: var(--ink-2); }
.footer-col a:hover { color: var(--accent); }
.footer-bottom {
  max-width: var(--max);
  margin: 0 auto;
  padding: 13px 24px 20px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* Responsive */
@media (max-width: 1080px) {
  .hero-inner { grid-template-columns: 1fr; gap: 44px; }
  .hero-panel { max-width: 560px; }
  .hero::before { height: 620px; }
  .tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .faq-section { grid-template-columns: 1fr; gap: 30px; }
  .below-grid { grid-template-columns: 1fr; gap: 46px; }
  .related-aside { position: static; }
  .footer-inner { grid-template-columns: 1fr; gap: 34px; }
}
@media (max-width: 860px) {
  .site-nav { display: none; }
  .header-inner { gap: 14px; }
  .search-trigger-label { display: none; }
  .why-grid { grid-template-columns: 1fr; gap: 26px; }
  .section-head { flex-direction: column; align-items: stretch; }
  .search-field { width: 100%; }
  .controls-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cron-fields { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tool-head h1 { font-size: clamp(2.2rem, 7vw, 3rem); }
}
@media (max-width: 760px) {
  .work-grid > .field > .code-view { min-height: 220px; max-height: 420px; }
  .hero { padding-top: 52px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); }
  .hero-stats span:nth-child(3) { border-left: 0; padding-left: 6px; border-top: 1px solid var(--line); }
  .hero-stats span:nth-child(4) { border-top: 1px solid var(--line); }
  .tools-section, .why-section, .faq-section { padding-top: 72px; }
  .work-grid { grid-template-columns: 1fr; }
  .toolbar-end { margin-left: 0; }
  .http-row { grid-template-columns: 52px 1fr; }
  .http-name { display: none; }
  .ts-row { grid-template-columns: 1fr auto; }
  .ts-row > span:first-child { grid-column: 1 / -1; }
  .ts-zone { grid-column: 1; }
  .color-head { flex-direction: column; }
  .swatch { width: 100%; min-height: 100px; }
  .case-row, .format-row { grid-template-columns: 110px minmax(0, 1fr) auto; }
  .cron-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cron-fields .field:last-child { grid-column: span 2; }
  .footer-cols { gap: 20px; }
  .palette { margin-top: 6vh; }
}
@media (max-width: 560px) {
  .header-inner { padding: 0 14px; height: 58px; }
  .brand-name { font-size: 0.94rem; }
  .brand-mark { width: 27px; height: 27px; }
  .lang-switch { min-width: 30px; height: 30px; }
  .icon-btn { width: 30px; height: 30px; }
  .search-trigger { height: 30px; padding: 0 7px; }
  .search-trigger .kbd { display: none; }
  .hero, .tools-section, .why-section, .faq-section, .page-wrap { padding-left: 16px; padding-right: 16px; }
  .hero h1 { font-size: clamp(2.9rem, 15vw, 4.4rem); }
  .hero-actions { gap: 16px; }
  .hero-stats { margin-top: 48px; }
  .hero-stats span { padding: 13px 4px; font-size: 0.58rem; }
  .hero-stats strong { font-size: 1rem; }
  .tool-grid { grid-template-columns: 1fr; }
  .tool-card { min-height: 170px; }
  .filter-row { flex-direction: column; align-items: flex-start; gap: 10px; }
  .chips { flex-wrap: wrap; width: 100%; }
  .controls-grid, .checks-grid { grid-template-columns: 1fr; }
  .ws-body { padding: 14px; }
  .output-bar, .output-actions { padding-left: 12px; padding-right: 12px; }
  .tool-title-row { gap: 13px; }
  .tool-icon { width: 44px; height: 44px; }
  .tool-icon .icon { width: 22px; height: 22px; }
  .tool-head { margin-top: 26px; }
  .tool-meta-line { align-items: flex-start; flex-direction: column; gap: 8px; }
  .tool-head .lead { font-size: 0.94rem; }
  .cron-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .case-row, .format-row { grid-template-columns: 1fr auto; }
  .case-label, .format-label { grid-column: 1 / -1; }
  .contrast-grid { grid-template-columns: 1fr; }
  .diff-row { grid-template-columns: 20px 1fr; }
  .diff-values { grid-column: 2; }
  .footer-bottom { flex-direction: column; gap: 6px; }
  .footer-inner { padding-top: 38px; }
  .palette { width: calc(100% - 20px); }
  .palette-cat { display: none; }
  .palette-item { grid-template-columns: 30px 1fr; }
  .toast { max-width: calc(100% - 24px); text-align: center; }
}

@media (max-width: 860px) {
  .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) {
  .kv-row { grid-template-columns: 1fr auto; }
  .kv-row .micro-label { grid-column: 1 / -1; }
  .zone-row { flex-direction: column; align-items: flex-start; }
  .zone-row code { text-align: left; }
  .perm-grid { grid-template-columns: minmax(70px, 1fr) repeat(3, 48px); padding: 10px; }
  .inline-input { flex-wrap: wrap; }
  .inline-input .btn { width: 100%; }

  .hero-panel { display: none; }
  .hero-inner { gap: 0; }
  .hero::before { height: 520px; }
  .hero-stats { margin-top: 40px; }
  .tool-card { min-height: 160px; padding: 16px; }
  .btn { min-height: 42px; }
  .btn--sm { min-height: 36px; }
  .icon-btn { width: 34px; height: 34px; }
  .lang-switch { min-width: 32px; height: 32px; }
  .search-trigger { height: 34px; }
  .chip { min-height: 36px; padding: 7px 13px; font-size: 0.79rem; }
  .recent-list a { min-height: 32px; padding: 5px 10px; }
  .meta-favorite { min-height: 34px; padding: 7px 10px; }
  .input, .textarea, select.input, textarea.code, input.code, .search-field input, .palette-input { font-size: 16px; }
  .input, .textarea, select.input { padding: 10px 12px; }
  .field label { font-size: 0.68rem; }
  .field .hint, .hint { font-size: 0.8rem; }
  .toolbar-end { width: 100%; justify-content: flex-start; }
  .field--inline { flex-wrap: wrap; }
  .seg { max-width: 100%; overflow-x: auto; }
  .case-row .icon-btn, .format-row .icon-btn, .ts-row .icon-btn { width: 34px; height: 34px; }
  .perm-grid .check { min-height: 34px; }
  .footer-col a { display: inline-block; padding: 3px 0; }
  .simple-head h1 { font-size: clamp(2rem, 9vw, 3rem); }
  .tool-head h1 { font-size: clamp(2.1rem, 8vw, 3rem); }
  .page-prose .tool-byline { display: block; margin-top: 24px; }

  .palette { width: 100%; max-width: 100%; height: 100dvh; max-height: 100dvh; margin: 0; border: 0; border-radius: 0; }
  .palette[open] { display: flex; flex-direction: column; }
  .palette-top { padding-top: max(11px, env(safe-area-inset-top)); }
  .palette-foot { padding-bottom: max(8px, env(safe-area-inset-bottom)); }
  .palette[open] .palette-list { flex: 1; max-height: none; }
  .palette-cat { display: none; }
  .palette-item { grid-template-columns: 30px 1fr; }
  .to-top { display: none; }
  .toast { bottom: max(24px, env(safe-area-inset-bottom)); max-width: calc(100% - 24px); text-align: center; }
}

@supports (padding: max(0px)) {
  .site-header { padding-top: env(safe-area-inset-top); }
  .site-footer { padding-bottom: env(safe-area-inset-bottom); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}
