:root {
  --bg: #f5f7fb;
  --surface: #ffffff;
  --surface-alt: #eef3ff;
  --text: #13213a;
  --muted: #5b6b87;
  --line: #d7e0f0;
  --brand: #2357ff;
  --brand-strong: #123ad1;
  --success-bg: #ebfff2;
  --success-text: #126636;
  --danger-bg: #fff1f1;
  --danger-text: #a12d2d;
  --warning-bg: #fff8e8;
  --warning-text: #8a5a00;
  --shadow: 0 18px 40px rgba(19, 33, 58, 0.08);
  --radius: 18px;
  --radius-sm: 12px;
  --max: 1160px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: linear-gradient(180deg, #f9fbff 0%, var(--bg) 100%);
  color: var(--text);
  font: 16px/1.65 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  min-height: 100vh;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--brand);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

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

.container {
  width: min(calc(100% - 2rem), var(--max));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(249, 251, 255, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(215, 224, 240, 0.7);
}

.site-header__row {
  min-height: 74px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text);
  text-decoration: none;
}

.brand:hover {
  text-decoration: none;
}

.brand__mark {
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--brand) 0%, #6ca7ff 100%);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.32), 0 10px 24px rgba(35, 87, 255, 0.24);
  position: relative;
}

.brand__mark::after {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.96);
}

.brand__name {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}

.brand__name small {
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0;
}

.site-nav {
  display: none;
  gap: 1rem;
  align-items: center;
}

.site-nav a {
  color: var(--muted);
  font-weight: 600;
}

.site-nav a[aria-current="page"] {
  color: var(--text);
}

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 999px;
  box-shadow: var(--shadow);
}

.lang-switch a,
.lang-switch span {
  min-width: 44px;
  text-align: center;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
}

.lang-switch span {
  background: var(--brand);
  color: #fff;
}

.lang-switch a {
  color: var(--muted);
}

.hero {
  padding: 4.5rem 0 3rem;
}

.hero__grid {
  display: grid;
  gap: 1.5rem;
  align-items: start;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: fit-content;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  background: rgba(35, 87, 255, 0.08);
  color: var(--brand-strong);
  font-weight: 700;
  font-size: 0.92rem;
}

.hero h1,
.page-heading h1 {
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin: 1rem 0 1rem;
}

.hero p.lede,
.page-heading p.lede {
  max-width: 64ch;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.18rem);
  margin: 0;
}

.hero-card,
.card,
.notice,
.stat-card,
.link-card,
.summary-card,
.process-card,
.decision-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.hero-card,
.card,
.process-card,
.decision-card,
.summary-card {
  padding: 1.25rem;
}

.hero-card ul,
.page-copy ul {
  margin: 1rem 0 0;
  padding-left: 1.25rem;
}

.grid-2,
.grid-3,
.tool-card-grid,
.link-grid,
.footer-grid {
  display: grid;
  gap: 1rem;
}

.tool-card-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.link-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.link-card {
  padding: 1.1rem;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.link-card:hover {
  text-decoration: none;
  transform: translateY(-2px);
  border-color: rgba(35, 87, 255, 0.38);
}

.link-card h2,
.link-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.08rem;
  letter-spacing: -0.02em;
}

.link-card p {
  margin: 0;
  color: var(--muted);
}

.page-section {
  padding: 1rem 0 3.25rem;
}

.page-heading {
  padding: 2.5rem 0 1.5rem;
}

.page-heading__grid {
  display: grid;
  gap: 1rem;
  align-items: start;
}

.badge-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0;
  list-style: none;
  margin: 1rem 0 0;
}

.badge-list li {
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  background: var(--surface-alt);
  border: 1px solid #d5e1ff;
  color: var(--text);
  font-weight: 600;
}

.notice {
  padding: 0.95rem 1rem;
  margin: 0 0 1rem;
}

.notice strong {
  display: block;
  margin-bottom: 0.2rem;
}

.notice--privacy {
  background: var(--surface-alt);
  border-color: #cfe0ff;
}

.notice--warning {
  background: var(--warning-bg);
  color: var(--warning-text);
  border-color: #f4d58b;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.button,
.button:visited {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 48px;
  padding: 0.8rem 1.2rem;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
}

.button:hover {
  transform: translateY(-1px);
  text-decoration: none;
}

.button--primary {
  background: var(--brand);
  color: #fff;
}

.button--primary:hover {
  background: var(--brand-strong);
}

.button--secondary {
  background: var(--surface);
  color: var(--text);
  border-color: var(--line);
}

.button--ghost {
  background: transparent;
  color: var(--brand);
  border-color: #b9c9ff;
}

.dropzone {
  position: relative;
  display: grid;
  place-items: center;
  text-align: center;
  gap: 0.55rem;
  min-height: 220px;
  padding: 1.5rem;
  border: 2px dashed #adc4ff;
  border-radius: calc(var(--radius) - 2px);
  background:
    radial-gradient(circle at top, rgba(35, 87, 255, 0.08), transparent 55%),
    linear-gradient(180deg, #fbfdff 0%, #f2f7ff 100%);
  cursor: pointer;
}

.dropzone.is-dragover {
  border-color: var(--brand);
  background:
    radial-gradient(circle at top, rgba(35, 87, 255, 0.14), transparent 55%),
    linear-gradient(180deg, #fbfdff 0%, #ebf2ff 100%);
}

.dropzone__title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.dropzone__sub {
  color: var(--muted);
}

.dropzone__hint {
  font-size: 0.95rem;
  color: var(--muted);
  max-width: 42ch;
}

.status-panel {
  margin-top: 1rem;
}

.status-card {
  padding: 1rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: #fbfdff;
}

.status-card.is-loading {
  border-color: #bed0ff;
  background: #eff5ff;
}

.status-card.is-error {
  border-color: #efb0b0;
  background: var(--danger-bg);
  color: var(--danger-text);
}

.status-card.is-success {
  border-color: #abd8bd;
  background: var(--success-bg);
  color: var(--success-text);
}

.tool-output {
  margin-top: 1rem;
  display: grid;
  gap: 1rem;
}

.meta-summary {
  display: grid;
  gap: 0.9rem;
}

.stat-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

.stat-card {
  padding: 1rem;
}

.stat-card strong {
  display: block;
  font-size: 1.5rem;
  letter-spacing: -0.03em;
}

.stat-card span {
  color: var(--muted);
}

.banner {
  padding: 1rem 1.1rem;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-weight: 700;
}

.banner--success {
  background: var(--success-bg);
  border-color: #a6d7ba;
  color: var(--success-text);
}

.banner--danger {
  background: var(--danger-bg);
  border-color: #efb0b0;
  color: var(--danger-text);
}

.banner--warning {
  background: var(--warning-bg);
  border-color: #f0cf78;
  color: var(--warning-text);
}

.meta-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
}

.meta-table {
  width: 100%;
  border-collapse: collapse;
}

.meta-table th,
.meta-table td {
  text-align: left;
  padding: 0.85rem 0.95rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.meta-table th {
  background: #f7faff;
  font-size: 0.95rem;
}

.meta-table tr:last-child td {
  border-bottom: 0;
}

.preview-grid {
  display: grid;
  gap: 1rem;
}

.preview-card {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: #fbfdff;
}

.preview-card img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  border: 1px solid var(--line);
}

.kicker {
  margin: 0 0 0.35rem;
  color: var(--muted);
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.info-list {
  margin: 0.6rem 0 0;
  padding-left: 1.15rem;
}

.decision-card {
  display: grid;
  gap: 1rem;
}

.decision-pill {
  width: fit-content;
  padding: 0.75rem 1rem;
  border-radius: 999px;
  font-size: clamp(1.1rem, 3vw, 1.45rem);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.decision-pill--yes {
  background: var(--danger-bg);
  color: var(--danger-text);
}

.decision-pill--no {
  background: var(--success-bg);
  color: var(--success-text);
}

.content-columns {
  display: grid;
  gap: 1.2rem;
}

.content-card {
  padding: 1.25rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.content-card h2,
.content-card h3 {
  margin-top: 0;
  letter-spacing: -0.03em;
}

.content-card p:last-child,
.content-card ul:last-child {
  margin-bottom: 0;
}

.faq-list {
  display: grid;
  gap: 0.9rem;
}

.faq-item {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 1rem 0.25rem;
  box-shadow: var(--shadow);
}

.faq-item summary {
  cursor: pointer;
  font-weight: 800;
  list-style: none;
  padding-bottom: 0.75rem;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item p {
  margin-top: 0;
  color: var(--muted);
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0 2.8rem;
  background: rgba(255,255,255,0.75);
  margin-top: 2rem;
}

.site-footer h2,
.site-footer h3 {
  margin-top: 0;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.site-footer p,
.site-footer li,
.site-footer a {
  color: var(--muted);
}

.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.45rem;
}

.site-footer__brand {
  max-width: 32rem;
}

.smallprint {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
  z-index: 999;
  padding: 0.75rem 1rem;
  background: #fff;
  border-radius: 12px;
  border: 1px solid var(--line);
}

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

@media (min-width: 860px) {
  .site-nav {
    display: inline-flex;
  }

  .hero__grid,
  .page-heading__grid,
  .grid-2,
  .preview-grid,
  .content-columns,
  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .hero-card,
  .card,
  .process-card,
  .decision-card,
  .summary-card {
    padding: 1.5rem;
  }
}
