@font-face {
  font-family: "Golos Text";
  src: url("fonts/golos-regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Golos Text";
  src: url("fonts/golos-bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}
:root {
  color-scheme: light;
  --paper: #f6f5f0;
  --surface: #fffefa;
  --panel: #efede5;
  --ink: #292925;
  --muted: #64635c;
  --line: #d4d2c8;
  --accent: #e4512c;
  --accent-ink: #a43518;
  --gutter: clamp(1rem, 4.2vw, 3.5rem);
  font-family: "Golos Text", Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 1.5rem; scrollbar-gutter: stable; }
body { margin: 0; background: var(--paper); color: var(--ink); font-size: 1rem; line-height: 1.5; -webkit-font-smoothing: antialiased; }
h1, h2, p, fieldset { margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
button, select { cursor: pointer; }
button, a { touch-action: manipulation; }
button { padding: 0; background: transparent; border: 0; }
button:disabled { cursor: default; opacity: .45; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }
:where(a, button, input, select, textarea, summary, [tabindex]):focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 4px; }
::selection { background: #f8c6aa; color: var(--ink); }
.shell { width: min(82.5rem, calc(100% - 2 * var(--gutter))); margin-inline: auto; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.skip-link { position: fixed; z-index: 10; top: .75rem; left: .75rem; padding: .6rem 1rem; background: var(--ink); color: var(--surface); transform: translateY(-180%); }
.skip-link:focus { transform: none; }

/* Header and footer follow the Polka catalog. */
.site-header { position: relative; display: flex; align-items: center; gap: clamp(.75rem, 2.3vw, 2.3rem); min-height: 6.25rem; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: .55rem; min-height: 2.75rem; }
.brand img { display: block; }
.brand-word { font-weight: 700; font-size: 2.25rem; line-height: 1; letter-spacing: -.065em; }
.period { color: var(--accent); }
.brand-note { max-width: 8.25rem; border-left: 1px solid var(--line); padding-left: 1.25rem; color: var(--muted); font-size: .8125rem; line-height: 1.45; }
.primary-nav, .languages, .footer-nav { display: flex; align-items: center; }
.primary-nav { gap: clamp(1rem, 2.3vw, 2.5rem); align-self: stretch; margin-left: auto; }
.primary-nav a { display: inline-flex; align-items: center; min-height: 2.75rem; font-size: .875rem; }
.languages { gap: .2rem; }
.languages a { position: relative; display: grid; place-items: center; min-width: 2.3rem; min-height: 2.75rem; color: var(--muted); font-size: .8125rem; }
.languages [aria-current] { color: var(--ink); }
.languages [aria-current]::after { position: absolute; content: ""; left: .5rem; right: .5rem; bottom: .25rem; height: 2px; background: var(--accent); }
.menu-toggle { display: none; min-width: 2.75rem; min-height: 2.75rem; font-size: 1.4rem; }
.site-footer { padding-top: clamp(1rem, 2.5vw, 2.4rem); background: #eae7de; }
.footer-nav { gap: 1.75rem; font-size: .9375rem; }
.footer-nav a { display: inline-flex; align-items: center; min-height: 2.75rem; }
.footer-word { font-weight: 700; font-size: clamp(5rem, 22vw, 20rem); letter-spacing: -.085em; line-height: 1.06; user-select: none; }
.copyright { display: block; margin-top: 1rem; border-top: 1px solid #c9c6ba; padding: 1rem 0; color: var(--muted); font-size: .8125rem; }

.crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .7rem; margin-top: 1.4rem; color: var(--muted); font-size: .8125rem; }
.crumbs a { min-height: 2.75rem; display: inline-flex; align-items: center; gap: .4rem; }
.page-intro { max-width: 51rem; padding: 1.5rem 0 2.25rem; }
.page-intro h1 { font-size: clamp(2.4rem, 5.1vw, 4.9rem); line-height: 1.06; letter-spacing: -.055em; text-wrap: balance; }
.page-intro p { max-width: 43rem; margin-top: 1.1rem; color: var(--muted); font-size: 1.0625rem; line-height: 1.65; }
.notice { padding: 1rem; border: 1px solid var(--line); }
.type-field { padding: 0 0 1.2rem; border: 0; }
.type-field legend { margin-bottom: .65rem; font-size: .8125rem; color: var(--muted); }
.type-options { display: flex; flex-wrap: wrap; gap: .45rem; }
.type-option { position: relative; }
.type-option input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.type-option span { display: grid; place-items: center; min-height: 2.9rem; padding: .65rem 1.4rem; border: 1px solid var(--line); border-radius: .2rem; font-size: .9375rem; cursor: pointer; }
.type-option input:checked + span { border-color: var(--ink); background: var(--ink); color: var(--surface); }
.type-option input:focus-visible + span { outline: 2px solid var(--accent-ink); outline-offset: 3px; }
.workspace { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); align-items: start; gap: clamp(1rem, 3vw, 2.5rem); }
.editor { min-width: 0; border: 1px solid var(--line); border-radius: .25rem; background: var(--surface); padding: clamp(1rem, 2.6vw, 2rem); }
.editor-actions { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .3rem 1rem; margin-bottom: 1rem; }
.underlink { min-height: 2rem; color: var(--accent-ink); text-decoration: underline; text-underline-offset: .22em; font-size: .8125rem; }
.secondary-link { color: var(--muted); }
.content-panel, .subpanel { min-width: 0; padding: 0; border: 0; }
.field { min-width: 0; margin-bottom: 1.05rem; }
.field:last-child { margin-bottom: 0; }
.field > label { display: block; margin-bottom: .5rem; font-weight: 700; font-size: .875rem; }
input:not([type="radio"], [type="checkbox"], [type="file"]), textarea, select { width: 100%; min-height: 3rem; padding: .7rem .8rem; border: 1px solid #bdbbb2; border-radius: .2rem; background: #fff; font-size: 1rem; }
input::placeholder, textarea::placeholder { color: #797870; opacity: 1; }
input[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: #b32418; }
textarea { display: block; resize: vertical; min-height: 8.5rem; line-height: 1.5; }
textarea#text { min-height: 10.5rem; }
select { padding-right: 2rem; }
.hint { margin-top: .55rem; color: var(--muted); font-size: .8125rem; line-height: 1.55; overflow-wrap: anywhere; }
.field-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1rem; }
.field-row .field { margin-bottom: 1.05rem; }
.password-wrap { display: flex; align-items: center; border: 1px solid #bdbbb2; border-radius: .2rem; background: #fff; }
.password-wrap input { border: 0; min-width: 0; background: transparent; }
.password-wrap .underlink { flex: none; padding-inline: .75rem; }
.password-wrap:has([aria-invalid="true"]) { border-color: #b32418; }
.check { display: flex; align-items: center; gap: .6rem; width: fit-content; min-height: 2.75rem; font-size: .875rem; cursor: pointer; }
.check input { width: 1.1rem; height: 1.1rem; accent-color: var(--ink); }
.error-message { margin-top: 1rem; color: #a12317; font-size: .875rem; line-height: 1.55; }
.appearance { margin-top: 1.75rem; padding-top: 1.35rem; border-top: 1px solid var(--line); }
.appearance h2 { margin-bottom: 1.1rem; font-size: 1.125rem; letter-spacing: -.025em; }
.color-field { border: 0; padding: 0; margin-bottom: 1.2rem; }
.color-field legend { margin-bottom: .55rem; font-size: .875rem; font-weight: 700; }
.colors { display: flex; flex-wrap: wrap; gap: .5rem; }
.color-option { display: inline-flex; position: relative; align-items: center; gap: .45rem; min-height: 2.6rem; padding: .4rem .6rem; border: 1px solid var(--line); border-radius: .2rem; cursor: pointer; font-size: .75rem; }
.color-option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.color-option:has(input:checked) { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.color-option:has(input:focus-visible) { outline: 2px solid var(--accent-ink); outline-offset: 3px; }
.color-dot { display: block; width: 1rem; height: 1rem; border-radius: 50%; background: #202124; }
.color-blue .color-dot { background: #193f83; }
.color-purple .color-dot { background: #56337e; }
.color-orange .color-dot { background: #8e341b; }
.size-field { max-width: 18rem; }
details { border-top: 1px solid var(--line); }
summary { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; min-height: 3.25rem; cursor: pointer; font-size: .875rem; list-style: none; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--muted); font-size: 1.25rem; font-weight: 400; }
details[open] > summary::after { content: "−"; }
.advanced-inner { padding: .7rem 0 .25rem; }
input[type="file"] { display: block; width: 100%; max-width: 100%; font-size: .8125rem; }
input[type="file"]::file-selector-button { padding: .65rem .8rem; margin-right: .65rem; border: 1px solid var(--line); border-radius: .2rem; background: var(--panel); font: inherit; cursor: pointer; }
.logo-feedback { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .5rem; align-items: center; margin-top: .5rem; font-size: .8125rem; }
#logo-feedback { overflow-wrap: anywhere; }
#logo-feedback.is-error { color: #a12317; }
.preview { position: sticky; top: 1.5rem; min-width: 0; border: 1px solid #292925; border-radius: .25rem; padding: clamp(1rem, 2.7vw, 2rem); background: #292925; color: #fffefa; }
.preview-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.2rem; }
.preview-heading h2 { font-size: .875rem; font-weight: 400; }
#preview-state { color: #c8c5ba; font-size: .6875rem; }
#preview-state[data-state="ready"] { color: #f6b8a4; }
.qr-frame { display: grid; place-items: center; aspect-ratio: 1; width: min(100%, 22.5rem); margin-inline: auto; overflow: hidden; border-radius: .15rem; background: #fff; color: var(--muted); }
.qr-frame svg { display: block; width: 100%; height: 100%; }
.empty-preview { display: grid; justify-items: center; gap: 1rem; max-width: 13rem; padding: 1rem; text-align: center; font-size: .8125rem; }
.empty-preview img { opacity: .6; }
.encoded-caption { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; margin-top: 1rem; min-height: 1.3rem; color: #e2dfd3; font-size: .8125rem; }
.qr-meta { min-height: 1rem; margin-top: .4rem; color: #bdbbb0; font: .6875rem/1.5 ui-monospace, Consolas, monospace; }
.downloads { display: grid; gap: .65rem; margin-top: 1.3rem; }
.downloads button { min-height: 3rem; padding: .8rem; border-radius: .2rem; font-weight: 700; font-size: .9375rem; }
.download-primary { background: #f08a68; color: #241a16; }
.download-secondary { border: 1px solid #9a988c; color: #fffefa; }
.preview-note { margin-top: 1rem; color: #c8c5ba; font-size: .75rem; line-height: 1.6; }
.download-feedback { font-size: .8125rem; color: #f6b8a4; }
.download-feedback:not(:empty) { margin-top: .75rem; }
.preview-jump { display: none; }
.privacy-line { display: flex; align-items: center; gap: .5rem; margin-top: 1rem; color: var(--muted); font-size: .8125rem; }
.privacy-line > :first-child { color: var(--accent-ink); }
.guide { display: grid; grid-template-columns: minmax(10rem, 1fr) minmax(0, 2fr); gap: 2rem; margin: 3.5rem 0 3.8rem; padding-top: 1.5rem; border-top: 1px solid var(--line); }
.guide h2 { font-size: 1.35rem; letter-spacing: -.03em; }
.guide-items > details:first-child { border-top: 0; }
.guide summary { font-size: .9375rem; font-weight: 700; }
.guide p { color: var(--muted); font-size: .875rem; line-height: 1.7; margin-bottom: 1rem; max-width: 43rem; }
@media (hover: hover) {
  a:hover, .underlink:hover { color: var(--accent-ink); }
  .type-option:hover span { border-color: var(--ink); }
  .download-primary:not(:disabled):hover { background: #faa589; }
  .download-secondary:not(:disabled):hover { background: #43433c; }
}
@media (max-width: 55rem) {
  .site-header { min-height: 4.75rem; gap: .75rem; }
  .brand-note { display: none; }
  .menu-toggle { display: inline-grid; place-items: center; margin-left: auto; }
  .primary-nav { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin-left: auto; }
  .enhanced .primary-nav { position: absolute; z-index: 3; top: 100%; left: 0; right: 0; display: none; margin: 0; padding: .65rem 1rem; border: 1px solid var(--line); border-top: 0; background: var(--surface); }
  .enhanced .primary-nav.is-open { display: flex; flex-direction: column; align-items: stretch; gap: 0; }
  .primary-nav a { min-height: 2.75rem; }
  .workspace { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 1rem; }
  .editor, .preview { padding: 1.2rem; }
  .type-option span { padding-inline: 1rem; }
  .guide { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
}
@media (max-width: 43rem) {
  .page-intro { padding-top: 1rem; padding-bottom: 1.6rem; }
  .page-intro h1 { font-size: clamp(2.1rem, 8vw, 3.5rem); }
  .page-intro p { font-size: .9375rem; margin-top: .8rem; }
  .crumbs { margin-top: .65rem; font-size: .75rem; }
  .workspace { grid-template-columns: minmax(0, 1fr); }
  .preview { position: static; padding: 1.3rem; }
  .type-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .type-option span { padding: .65rem .3rem; font-size: .875rem; }
  .colors { gap: .4rem; }
  .color-option { padding-inline: .45rem; }
  .preview-jump { display: flex; justify-content: center; align-items: center; gap: .4rem; margin-top: 1.3rem; min-height: 2.75rem; border: 1px solid var(--line); font-size: .875rem; }
  .guide { margin-block: 2.5rem; }
  .privacy-line { font-size: .75rem; align-items: start; }
}
@media (max-width: 24rem) {
  .field-row { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .languages a { min-width: 2.1rem; }
  .brand-word { font-size: 2rem; }
  .crumbs > :last-child, .crumbs > [aria-hidden] { display: none; }
}
@media (prefers-reduced-motion: no-preference) {
  button, a { transition: color .15s, background-color .15s; }
}
