:root {
  color-scheme: light;
  --bg: #f7f4ed;
  --panel: #fffdf8;
  --panel-strong: #f0eadf;
  --ink: #24211c;
  --muted: #6c665b;
  --line: #d8d0c2;
  --accent: #0f766e;
  --accent-strong: #115e59;
  --gold: #d98d20;
  --blue: #315a96;
  --danger: #a43f32;
  --shadow: 0 18px 50px rgba(47, 39, 25, 0.11);
  --radius: 8px;
  --max: 1120px;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(36, 33, 28, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(36, 33, 28, 0.035) 1px, transparent 1px),
    var(--bg);
  background-size: 32px 32px;
  font-family: "Avenir Next", "Segoe UI", Helvetica, sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 100;
  padding: 10px 14px;
  border: 2px solid var(--ink);
  border-radius: 6px;
  background: var(--panel);
  color: var(--ink);
  font-weight: 800;
  text-decoration: none;
  transform: translateY(-160%);
}

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

:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
}

.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;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(36, 33, 28, 0.12);
  background: rgba(247, 244, 237, 0.88);
  backdrop-filter: blur(16px);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 14px 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--ink);
  border-radius: 7px;
  background: var(--gold);
  box-shadow: 3px 3px 0 var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 900;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font-size: 0.94rem;
}

.nav-links a {
  border-radius: 6px;
  padding: 8px 10px;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a[aria-current="page"] {
  background: rgba(15, 118, 110, 0.1);
  color: var(--accent-strong);
}

.nav-links a:focus-visible {
  background: rgba(49, 90, 150, 0.1);
}

main {
  min-height: calc(100vh - 67px);
}

.hero,
.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: 54px 20px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.8fr);
  gap: 44px;
  align-items: center;
  padding-top: 68px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 28px;
  height: 2px;
  background: var(--accent);
}

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.05;
  letter-spacing: 0;
}

h1 {
  max-width: 820px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.6rem, 7vw, 5.6rem);
  font-weight: 900;
}

h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.85rem, 4vw, 3rem);
}

h3 {
  font-size: 1.1rem;
}

.lead {
  max-width: 690px;
  margin: 22px 0 0;
  color: var(--muted);
  font-size: clamp(1.04rem, 2vw, 1.25rem);
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--ink);
  border-radius: 7px;
  background: var(--ink);
  color: #fffdf8;
  box-shadow: 4px 4px 0 rgba(36, 33, 28, 0.24);
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  padding: 11px 16px;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover {
  box-shadow: 2px 2px 0 rgba(36, 33, 28, 0.26);
  transform: translate(2px, 2px);
}

.button.secondary {
  background: var(--panel);
  color: var(--ink);
}

.button.ghost {
  border-color: var(--line);
  background: transparent;
  color: var(--ink);
  box-shadow: none;
}

.button:disabled {
  cursor: not-allowed;
  opacity: 0.52;
  transform: none;
}

.hero-board {
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow), 7px 7px 0 var(--ink);
  overflow: hidden;
}

.board-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--ink);
}

.board-strip span {
  min-height: 10px;
}

.board-strip span:nth-child(1) {
  background: var(--accent);
}

.board-strip span:nth-child(2) {
  background: var(--gold);
}

.board-strip span:nth-child(3) {
  background: var(--blue);
}

.mini-list {
  display: grid;
  gap: 10px;
  padding: 22px;
}

.mini-ticket {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fffaf0;
  padding: 12px 14px;
  font-weight: 800;
}

.mini-ticket span {
  display: inline-flex;
  min-width: 58px;
  justify-content: center;
  border-radius: 999px;
  background: rgba(15, 118, 110, 0.1);
  color: var(--accent-strong);
  font-size: 0.82rem;
}

.tool-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.72fr);
  gap: 22px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 22px 20px 58px;
}

.tool-intro {
  max-width: var(--max);
  margin: 0 auto;
  padding: 58px 20px 14px;
}

.section-kicker {
  margin: 0 0 8px;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.tool-card,
.results-panel,
.content-block,
.tool-tile,
.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.92);
}

.tool-card,
.results-panel {
  box-shadow: var(--shadow);
}

.tool-card {
  padding: 22px;
}

.field-label,
.control-title {
  display: block;
  margin-bottom: 8px;
  font-weight: 900;
}

textarea,
input[type="number"],
input[type="search"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fffdf8;
  color: var(--ink);
  font: inherit;
  outline: none;
}

textarea {
  min-height: 260px;
  resize: vertical;
  padding: 14px;
}

textarea:focus,
input[type="number"]:focus,
input[type="search"]:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.12);
}

.field-hint {
  margin: -2px 0 10px;
  color: var(--muted);
  font-size: 0.92rem;
}

.input-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.9rem;
}

.controls {
  display: grid;
  gap: 12px;
  min-width: 0;
  margin-top: 20px;
  padding: 0;
  border: 0;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.choice {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fffaf0;
  cursor: pointer;
  padding: 12px;
}

.choice:has(input:checked) {
  border-color: var(--accent);
  background: rgba(15, 118, 110, 0.09);
}

.choice strong {
  display: block;
  line-height: 1.2;
}

.choice small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

.number-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 112px;
  gap: 12px;
  align-items: end;
  margin-top: 14px;
}

input[type="number"] {
  min-height: 44px;
  padding: 8px 10px;
}

.alert {
  display: none;
  margin-top: 14px;
  border: 1px solid rgba(164, 63, 50, 0.35);
  border-radius: 7px;
  background: rgba(164, 63, 50, 0.08);
  color: var(--danger);
  padding: 10px 12px;
  font-weight: 700;
}

.alert.visible {
  display: block;
}

.results-panel {
  min-height: 100%;
  padding: 18px;
}

.results-head {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 14px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
}

.results-head p {
  margin: 5px 0 0;
  color: var(--muted);
}

.result-actions {
  display: flex;
  gap: 8px;
}

.action-button {
  display: inline-grid;
  min-width: 62px;
  height: 38px;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel);
  cursor: pointer;
  color: var(--ink);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 800;
  padding: 0 10px;
}

.action-button:hover {
  border-color: var(--accent);
  color: var(--accent-strong);
}

.action-button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}

.result-list {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.empty-state {
  display: grid;
  min-height: 280px;
  place-items: center;
  border: 1px dashed var(--line);
  border-radius: 7px;
  color: var(--muted);
  text-align: center;
  padding: 24px;
}

.group-card {
  border: 1px solid var(--line);
  border-left: 6px solid var(--accent);
  border-radius: 7px;
  background: #fffdf8;
  padding: 14px;
  animation: rise 220ms ease both;
}

.group-card:nth-child(3n + 2) {
  border-left-color: var(--gold);
}

.group-card:nth-child(3n) {
  border-left-color: var(--blue);
}

.group-card h3 {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.group-card h3 span {
  color: var(--muted);
  font-family: "Avenir Next", "Segoe UI", Helvetica, sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
}

.name-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.name-list li {
  border: 1px solid rgba(36, 33, 28, 0.12);
  border-radius: 999px;
  background: var(--panel-strong);
  padding: 6px 10px;
  font-weight: 700;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
}

.content-block,
.tool-tile,
.faq-item {
  padding: 18px;
}

.content-block p,
.tool-tile p,
.faq-item p {
  margin: 9px 0 0;
  color: var(--muted);
}

.tool-tile {
  display: flex;
  min-height: 235px;
  flex-direction: column;
  text-decoration: none;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.tool-tile:hover {
  border-color: var(--accent);
  box-shadow: 4px 4px 0 rgba(15, 118, 110, 0.16);
  transform: translateY(-2px);
}

.tool-category {
  margin-bottom: 26px;
  color: var(--accent-strong);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.tool-link-text {
  margin-top: auto;
  padding-top: 24px;
  color: var(--accent-strong);
  font-weight: 900;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.section-head p {
  max-width: 610px;
  margin: 0;
  color: var(--muted);
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.hub-toolbar {
  display: grid;
  grid-template-columns: minmax(230px, 1fr) auto auto;
  gap: 18px;
  align-items: end;
  margin-bottom: 18px;
  padding: 16px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.58);
}

.search-field,
.filter-wrap {
  display: grid;
  gap: 7px;
}

.search-field label,
.filter-wrap .field-label {
  margin: 0;
  font-size: 0.86rem;
  font-weight: 900;
}

input[type="search"] {
  min-height: 44px;
  padding: 9px 12px;
}

.filter-group {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel);
}

.filter-group button {
  min-height: 36px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 0.86rem;
  font-weight: 800;
  padding: 7px 10px;
}

.filter-group button:hover,
.filter-group button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--panel);
}

.tool-count {
  min-width: 54px;
  margin: 0 0 9px;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 800;
  text-align: right;
}

.hub-empty {
  margin: 18px 0 0;
  border: 1px dashed var(--line);
  padding: 24px;
  color: var(--muted);
  text-align: center;
}

.section-band {
  border-top: 1px solid rgba(36, 33, 28, 0.12);
  border-bottom: 1px solid rgba(36, 33, 28, 0.12);
}

.process-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.process-grid li {
  position: relative;
  padding-left: 48px;
}

.process-grid li > span {
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid var(--ink);
  border-radius: 6px;
  background: var(--gold);
  box-shadow: 3px 3px 0 rgba(36, 33, 28, 0.2);
  font-weight: 900;
}

.process-grid p {
  margin: 8px 0 0;
  color: var(--muted);
}

.privacy-band {
  display: grid;
  grid-template-columns: minmax(260px, 0.65fr) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
}

.privacy-band p:last-child {
  margin: 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.inline-note {
  margin-top: 18px;
  border-left: 4px solid var(--gold);
  background: rgba(217, 141, 32, 0.08);
  padding: 11px 13px;
  color: var(--muted);
  font-size: 0.92rem;
}

.inline-note strong {
  color: var(--ink);
}

.picker-result .group-card {
  border-left-color: var(--gold);
  padding: 24px;
}

.picker-result .name-list li {
  border: 0;
  background: transparent;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.9rem;
  font-weight: 900;
  padding: 0;
}

.footer {
  border-top: 1px solid rgba(36, 33, 28, 0.12);
  color: var(--muted);
  padding: 26px 20px;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  max-width: var(--max);
  margin: 0 auto;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 10px;
}

.legal-intro {
  max-width: var(--max);
  margin: 0 auto;
  padding: 68px 20px 34px;
}

.legal-intro h1 {
  font-size: clamp(2.6rem, 7vw, 4.8rem);
}

.legal-meta {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.legal-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 230px;
  gap: 64px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 18px 20px 72px;
}

.legal-content {
  max-width: 760px;
}

.legal-content section {
  scroll-margin-top: 110px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
}

.legal-content section:first-child {
  border-top: 0;
  padding-top: 0;
}

.legal-content h2 {
  font-size: clamp(1.55rem, 3vw, 2.1rem);
}

.legal-content h3 {
  margin-top: 22px;
}

.legal-content p,
.legal-content li {
  color: var(--muted);
}

.legal-content p {
  margin: 14px 0 0;
}

.legal-content ul {
  margin: 14px 0 0;
  padding-left: 22px;
}

.legal-content a {
  color: var(--accent-strong);
  font-weight: 700;
}

.legal-note {
  margin-top: 18px;
  border-left: 4px solid var(--gold);
  background: rgba(217, 141, 32, 0.08);
  padding: 14px 16px;
}

.legal-note strong {
  color: var(--ink);
}

.legal-nav {
  align-self: start;
  position: sticky;
  top: 98px;
  border-left: 1px solid var(--line);
  padding-left: 22px;
}

.legal-nav h2 {
  font-family: inherit;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.legal-nav ul {
  display: grid;
  gap: 8px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
}

.legal-nav a {
  color: var(--muted);
  font-size: 0.94rem;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.tool-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 18px;
}

.tool-list a {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--panel);
  padding: 14px;
  text-decoration: none;
}

.tool-list a:hover {
  border-color: var(--accent);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 860px) {
  .nav {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-links {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
  }

  .hero,
  .tool-shell,
  .content-grid,
  .faq-grid,
  .process-grid,
  .privacy-band,
  .legal-shell {
    grid-template-columns: 1fr;
  }

  .legal-nav {
    position: static;
    order: -1;
    border-left: 0;
    border-bottom: 1px solid var(--line);
    padding: 0 0 22px;
  }

  .legal-nav ul {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hub-toolbar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .tool-count {
    margin: 0;
    text-align: left;
  }

  .hero {
    padding-top: 44px;
  }

}

@media (max-width: 560px) {
  .hero,
  .section,
  .tool-intro,
  .tool-shell,
  .legal-intro,
  .legal-shell {
    padding-left: 14px;
    padding-right: 14px;
  }

  .tool-list,
  .legal-nav ul {
    grid-template-columns: 1fr;
  }

  .option-grid,
  .number-control {
    grid-template-columns: 1fr;
  }

  .results-head,
  .section-head {
    align-items: stretch;
    flex-direction: column;
  }

  .result-actions {
    align-self: flex-start;
  }

  .filter-group {
    display: grid;
    grid-template-columns: 1fr;
  }

  .button {
    width: 100%;
  }
}

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