/* oakenbit site styles. System fonts only; no external resources. */
:root {
  --bg: #fbfaf7;
  --surface: #ffffff;
  --fg: #1d1b16;
  --muted: #5a5548;
  --line: #e2ddd1;
  --accent: #3d5a2a;
  --accent-strong: #2c4220;
  --accent-fg: #ffffff;
  --warm: #9a5b17;
  --ok: #2f6b2f;
  --warn: #8a5a00;
  --danger: #a4261b;
  --focus: #1f6feb;
  --code-bg: #f1eee6;
  --radius: 10px;
  --maxw: 72rem;
  --font: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans', sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, 'Liberation Mono', monospace;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171613;
    --surface: #211f1b;
    --fg: #ece8de;
    --muted: #b3ac9c;
    --line: #37342d;
    --accent: #8fb573;
    --accent-strong: #a8c98f;
    --accent-fg: #11100d;
    --warm: #e2a45a;
    --ok: #8fcf8f;
    --warn: #f0b44c;
    --danger: #ff8a7d;
    --focus: #79b8ff;
    --code-bg: #2a2823;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
[hidden] {
  display: none !important;
}
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 1rem/1.6 var(--font);
}
img,
svg {
  max-width: 100%;
  height: auto;
}
a {
  color: var(--accent);
  text-underline-offset: 0.15em;
}
a:hover {
  color: var(--accent-strong);
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
code,
kbd,
pre,
textarea.mono {
  font-family: var(--mono);
  font-size: 0.92em;
}
code {
  background: var(--code-bg);
  padding: 0.05em 0.3em;
  border-radius: 4px;
  overflow-wrap: anywhere;
}
pre {
  background: var(--code-bg);
  border-radius: 6px;
  padding: 0.7rem 0.9rem;
  overflow-x: auto;
  max-width: 100%;
}
pre code {
  padding: 0;
  background: none;
  overflow-wrap: normal;
}
h1,
h2,
h3 {
  line-height: 1.25;
}
h1 {
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  margin: 0.2em 0 0.3em;
}
h2 {
  font-size: 1.4rem;
  margin-top: 2em;
}
h3 {
  font-size: 1.1rem;
  margin-top: 1.5em;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--surface);
  padding: 0.5rem 1rem;
  z-index: 10;
}
.skip-link:focus {
  left: 1rem;
  top: 1rem;
}
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 1rem;
}
.narrow {
  max-width: 46rem;
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 3.5rem;
  flex-wrap: wrap;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--fg);
  text-decoration: none;
  letter-spacing: 0.01em;
}
.brand img {
  width: 28px;
  height: 28px;
}
.site-nav ul {
  display: flex;
  gap: 1.1rem;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}
.site-nav a {
  color: var(--fg);
  text-decoration: none;
}
.site-nav a:hover,
.site-nav a[aria-current='page'],
.site-nav a[aria-current='true'] {
  text-decoration: underline;
}
.site-nav {
  margin-left: auto;
}
.lang-switch {
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.15rem 0.7rem;
  text-decoration: none;
}
/* Phones: logo and language switch on the first row, the navigation wraps below. */
@media (max-width: 760px) {
  .site-header .wrap {
    gap: 0.3rem 1rem;
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
  }
  .lang-switch {
    order: 2;
    margin-left: auto;
  }
  .site-nav {
    order: 3;
    flex-basis: 100%;
    margin-left: 0;
  }
  .site-nav ul {
    gap: 0.2rem 0.9rem;
  }
  .site-nav a {
    display: inline-block;
    padding: 0.2rem 0;
  }
}

main {
  padding: 1.5rem 0 3rem;
}
.lead {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 44rem;
}

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(16.5rem, 1fr));
  gap: 1rem;
  padding: 0;
  list-style: none;
}
.card {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.1rem 1.2rem;
}
.card h3 {
  margin: 0 0 0.3rem;
}
.card h3 a {
  color: var(--fg);
  text-decoration: none;
}
.card h3 a::after {
  content: '';
  position: absolute;
  inset: 0;
}
.card:hover,
.card:focus-within {
  border-color: var(--accent);
}
.card p {
  margin: 0.3rem 0 0;
  color: var(--muted);
}
.tag {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--warm);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Tool UI */
.tool {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem;
  margin: 1.2rem 0 2rem;
}
.privacy-note {
  font-size: 0.93rem;
  color: var(--muted);
  margin: 0.4rem 0 0;
  padding-left: 0.7rem;
  border-left: 3px solid var(--accent);
}
.dropzone {
  display: block;
  border: 2px dashed var(--line);
  border-radius: var(--radius);
  padding: 1.6rem 1rem;
  text-align: center;
  cursor: pointer;
  background: var(--bg);
}
.dropzone:hover,
.dropzone.dragover,
.dropzone:focus-within {
  border-color: var(--accent);
}
.dropzone strong {
  color: var(--accent);
}
.dropzone input[type='file'] {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}
.options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.4rem;
  margin: 1rem 0;
  padding: 0;
  border: 0;
}
.options legend {
  font-weight: 600;
  margin-bottom: 0.3rem;
  padding: 0;
}
.options label {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}
select,
input[type='text'],
input[type='email'],
textarea {
  font: inherit;
  color: var(--fg);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.35rem 0.5rem;
}
textarea {
  width: 100%;
  min-height: 14rem;
  resize: vertical;
  line-height: 1.45;
  font-family: var(--mono);
  font-size: 0.88rem;
  white-space: pre;
  overflow-wrap: normal;
  overflow: auto;
}
.btn,
button {
  font: inherit;
  font-weight: 600;
  border-radius: 8px;
  padding: 0.55rem 1rem;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--accent-fg);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
.btn.secondary,
button.secondary {
  background: transparent;
  color: var(--accent);
}
button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  align-items: center;
  margin: 0.8rem 0;
}
.status {
  min-height: 1.6em;
  margin: 0.5rem 0;
}
.status.error {
  color: var(--danger);
  font-weight: 600;
}
.status.ok {
  color: var(--ok);
}

.io-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}
.io-grid > div {
  min-width: 0;
}
.io-grid label {
  font-weight: 600;
  display: block;
  margin-bottom: 0.3rem;
}
@media (max-width: 760px) {
  .io-grid {
    grid-template-columns: 1fr;
  }
}

.segmented {
  display: inline-flex;
  border: 1px solid var(--accent);
  border-radius: 8px;
  overflow: hidden;
}
.segmented button {
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--accent);
}
.segmented button[aria-pressed='true'] {
  background: var(--accent);
  color: var(--accent-fg);
}

/* File results */
.results {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}
.result {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.8rem 1rem;
  margin-bottom: 0.8rem;
  background: var(--bg);
}
.result h3 {
  margin: 0 0 0.3rem;
  font-size: 1rem;
  overflow-wrap: anywhere;
}
.result .meta {
  color: var(--muted);
  font-size: 0.9rem;
}
.result.error {
  border-color: var(--danger);
}
.found {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
  margin: 0.5rem 0;
}
.found th,
.found td {
  text-align: left;
  border-bottom: 1px solid var(--line);
  padding: 0.3rem 0.5rem 0.3rem 0;
  vertical-align: top;
  overflow-wrap: anywhere;
}
.found th {
  font-weight: 600;
  width: 38%;
}
.sensitive {
  color: var(--danger);
  font-weight: 600;
}
.pill {
  display: inline-block;
  font-size: 0.8rem;
  border-radius: 999px;
  padding: 0 0.5rem;
  border: 1px solid currentColor;
}
.pill.danger {
  color: var(--danger);
}
.pill.ok {
  color: var(--ok);
}
details summary {
  cursor: pointer;
}

/* Docs */
.doc {
  max-width: 46rem;
}
.doc li {
  margin: 0.3rem 0;
}
.doc table,
.legal table {
  border-collapse: collapse;
  width: 100%;
  margin: 1rem 0;
  font-size: 0.95rem;
  display: block;
  overflow-x: auto;
}
.doc th,
.doc td,
.legal th,
.legal td {
  overflow-wrap: anywhere;
  hyphens: auto;
  border: 1px solid var(--line);
  padding: 0.4rem 0.6rem;
  text-align: left;
  vertical-align: top;
}
.faq dt {
  font-weight: 600;
  margin-top: 1rem;
}
.faq dd {
  margin: 0.2rem 0 0;
}
.toc {
  font-size: 0.95rem;
}

/* Legal pages */
.legal {
  max-width: 46rem;
}
.legal address {
  font-style: normal;
}
.legal dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 0.3rem 1rem;
}
.legal dt {
  font-weight: 600;
}
.legal dd {
  margin: 0;
}
@media (max-width: 560px) {
  .legal dl {
    grid-template-columns: 1fr;
  }
  .legal dd {
    margin-bottom: 0.5rem;
  }
}

/* Catalog: status badges, prices, notices */
.badge {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--muted);
  background: var(--code-bg);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.2rem 0.75rem;
}
.price {
  font-weight: 600;
}
.card-price,
.card-status,
.card-links {
  margin: 0.6rem 0 0;
}
.card-links {
  position: relative;
}
.vat-note {
  color: var(--muted);
  font-size: 0.9rem;
}
.notice {
  margin: 0;
  padding: 0.6rem 0.9rem;
  border-left: 3px solid var(--warm);
  background: var(--surface);
}
.product-image {
  border-radius: var(--radius);
  border: 1px solid var(--line);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--surface);
  color: var(--muted);
  font-size: 0.9rem;
  padding: 1.5rem 0 2rem;
}
.site-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1.2rem;
  list-style: none;
  padding: 0;
  margin: 0 0 0.8rem;
}
.site-footer a {
  color: var(--muted);
}
.ai-disclosure {
  margin: 0.4rem 0 0;
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
@media print {
  .site-header,
  .site-footer,
  .tool {
    display: none;
  }
}

/* Image redaction tool: the overlay canvas sits exactly on top of the image. */
.redact-stage {
  position: relative;
  margin: 0.8rem 0;
  max-width: 100%;
  line-height: 0;
  background: repeating-conic-gradient(var(--line) 0 25%, transparent 0 50%) 0 0 / 16px 16px;
}
.redact-stage canvas {
  display: block;
  width: 100%;
  height: auto;
}
.redact-stage #overlay {
  position: absolute;
  inset: 0;
  height: 100%;
  cursor: crosshair;
  touch-action: none;
}
.redact-stage #overlay:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
.muted {
  opacity: 0.55;
}
.first-col-nowrap td:first-child {
  white-space: nowrap;
}
.notice {
  margin: 0.6rem 0;
  padding: 0.5rem 0.8rem;
  border-left: 4px solid var(--warn);
  background: var(--bg);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.notice p,
.notice ul {
  margin: 0.2rem 0;
}

/* Text compare */
.diff-result {
  margin-top: 1rem;
  overflow-x: auto;
}
table.diff {
  width: 100%;
  table-layout: fixed;
  border-collapse: collapse;
  font: 0.88rem/1.45 var(--mono);
}
table.diff td {
  padding: 0.05rem 0.4rem;
  vertical-align: top;
  border: 0;
}
table.diff td.code {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
table.diff col.num {
  width: 3.4em;
}
table.diff col.sign {
  width: 1.6em;
}
table.diff td.num,
table.diff td.sign {
  text-align: right;
  color: var(--muted);
  user-select: none;
}
table.diff td.sign {
  text-align: center;
}
table.diff tr.delete td.code,
table.diff tr.change td.old {
  background: rgba(200, 40, 30, 0.12);
}
table.diff tr.insert td.code,
table.diff tr.change td.new {
  background: rgba(40, 150, 60, 0.14);
}
table.diff tr td.code.empty {
  background: repeating-linear-gradient(135deg, transparent 0 6px, var(--line) 6px 7px);
}
table.diff del {
  text-decoration: line-through;
  background: rgba(200, 40, 30, 0.3);
  color: inherit;
}
table.diff ins {
  text-decoration: none;
  background: rgba(40, 150, 60, 0.32);
  color: inherit;
}

/* JPG to PDF page list */
.page-item {
  display: grid;
  grid-template-columns: 64px 1fr auto;
  gap: 0.4rem 0.9rem;
  align-items: center;
}
.page-item img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 6px;
}
.page-item .btn-row {
  margin: 0;
}
.page-item button {
  padding: 0.35rem 0.7rem;
}
@media (max-width: 560px) {
  .page-item {
    grid-template-columns: 64px 1fr;
  }
  .page-item .btn-row {
    grid-column: 1 / -1;
  }
}

/* Withdrawal form (/withdrawal/, /de/widerruf/) */
.withdrawal-form {
  max-width: 34rem;
  margin: 1.2rem 0 1.6rem;
}
.withdrawal-form .field label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.withdrawal-form .field input {
  width: 100%;
  box-sizing: border-box;
}
.withdrawal-form .hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.footer-withdraw {
  font-weight: 600;
}
