/* Copyshop Briefbogen – Designer. Schrift und Grundfarben kommen vom Theme. */
.csfbb {
	--csfbb-accent: #0072B0;
	--csfbb-ink: #012547;
	--csfbb-muted: #4E5C70;
	--csfbb-line: #DCE2EA;
	--csfbb-blue: #008AD0;
	--csfbb-magenta: #DB0170;
	--csfbb-radius: 6px;
	color: var(--csfbb-ink);
	font-size: 16px;
	line-height: 1.45;
}
.csfbb *, .csfbb *::before, .csfbb *::after { box-sizing: border-box; }
.csfbb-loading { padding: 32px; color: var(--csfbb-muted); }
.csfbb-brand { display: flex; height: 5px; margin: 0 0 20px; border-radius: 3px; overflow: hidden; }
.csfbb-brand span { flex: 1; }
.csfbb-intro { max-width: 760px; margin: 0 0 20px; color: var(--csfbb-muted); font-size: 17px; }

.csfbb-grid { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.csfbb-col { flex: 999 1 480px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.csfbb-side { flex: 1 1 520px; position: sticky; top: 16px; }
@media (max-width: 1080px) { .csfbb-side { position: static; } }

.csfbb-card { background: #FFFFFF; border: 1px solid var(--csfbb-line); border-radius: var(--csfbb-radius); padding: 22px; }
.csfbb-card h3 { margin: 0 0 14px; font-size: 19px; font-weight: 600; line-height: 1.25; color: inherit; }
.csfbb-step { font-family: ui-monospace, Menlo, Consolas, monospace; color: var(--csfbb-accent); font-size: 14px; margin-right: 8px; }
.csfbb-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 10px 0; }
.csfbb-between { justify-content: space-between; margin-top: 0; }
.csfbb-between h3 { margin: 0; }
.csfbb-lbl { font-size: 14px; font-weight: 600; margin: 14px 0 8px; }
.csfbb-row .csfbb-lbl { margin: 0; min-width: 90px; }
.csfbb-muted { color: var(--csfbb-muted); font-size: 14px; margin: 0 0 12px; }
.csfbb-hint { color: var(--csfbb-muted); font-size: 13px; margin: 10px 0 0; }
.csfbb-small { font-size: 13px; }
.csfbb-mono { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 14px; }
.csfbb button { font: inherit; color: inherit; cursor: pointer; }
.csfbb button:focus-visible, .csfbb input:focus-visible, .csfbb select:focus-visible, .csfbb textarea:focus-visible, .csfbb-drag:focus-visible { outline: 2px solid var(--csfbb-accent); outline-offset: 2px; }

/* Papier & Auflage */
.csfbb-papers { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; margin-bottom: 14px; }
.csfbb-paper { display: flex; flex-direction: column; gap: 4px; padding: 8px; border: 2px solid #E1E6EC; border-radius: var(--csfbb-radius); background: #FFFFFF; text-align: left; }
.csfbb-paper.is-on, .csfbb-qty.is-on, .csfbb-pair.is-on { border-color: var(--csfbb-blue); }
.csfbb-swatch { display: block; height: 48px; border: 1px solid #E1E6EC; border-radius: 3px; margin-bottom: 4px; }
.csfbb-paper-n { font-size: 14px; font-weight: 600; padding: 0 2px; }
.csfbb-paper-d { font-size: 12px; color: var(--csfbb-muted); padding: 0 2px 2px; }
.csfbb-tex-gerippt { background-image: repeating-linear-gradient(90deg, rgba(0,0,0,.045) 0 1px, transparent 1px 5px); }
.csfbb-tex-leinen { background-image: repeating-linear-gradient(0deg, rgba(0,0,0,.035) 0 1px, transparent 1px 3px), repeating-linear-gradient(90deg, rgba(0,0,0,.035) 0 1px, transparent 1px 3px); }
.csfbb-qtys { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: 8px; }
.csfbb-qty { display: flex; flex-direction: column; gap: 2px; min-height: 60px; padding: 10px 12px; border: 2px solid #E1E6EC; border-radius: 4px; background: #FFFFFF; text-align: left; }
.csfbb-qty strong { font-size: 16px; font-weight: 600; }
.csfbb-qty span { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 13px; color: var(--csfbb-muted); }

/* Felder */
.csfbb-two { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; }
.csfbb-field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; margin: 0 0 12px; }
.csfbb-two .csfbb-field, .csfbb-contact .csfbb-field, .csfbb-foot .csfbb-field { margin: 0; }
.csfbb-field input, .csfbb-field select, .csfbb-field textarea { min-height: 44px; padding: 8px 12px; border: 1px solid #B4BECB; border-radius: 4px; font: inherit; font-size: 16px; font-weight: 400; background: #FFFFFF; color: var(--csfbb-ink); width: 100%; }
.csfbb-field textarea { resize: vertical; min-height: 84px; line-height: 1.4; }
.csfbb-field [aria-invalid="true"] { border-color: var(--csfbb-magenta); box-shadow: 0 0 0 1px var(--csfbb-magenta); }
.csfbb-opt { font-style: normal; font-weight: 400; color: var(--csfbb-muted); }
.csfbb-check { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding-top: 10px; font-size: 15px; cursor: pointer; }
.csfbb-check input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--csfbb-accent); flex: none; }
.csfbb-check.csfbb-small { padding-top: 0; min-height: 36px; align-items: center; }
.csfbb-foot { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.csfbb-foot textarea { font-size: 14px; }
.csfbb-contact { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; margin-bottom: 6px; }
.csfbb-s2 { grid-column: span 2; } .csfbb-s4 { grid-column: span 4; } .csfbb-s6 { grid-column: span 6; }
@media (max-width: 600px) {
	.csfbb-s2 { grid-column: span 3; } .csfbb-s4 { grid-column: span 6; }
	.csfbb-k-salutation, .csfbb-k-vat_id, .csfbb-k-country { grid-column: span 6; }
	.csfbb-k-zip { grid-column: span 2; } .csfbb-k-city { grid-column: span 4; }
	.csfbb-card { padding: 16px; }
}
.csfbb-subhead { margin: 10px 0 12px; font-size: 16px; font-weight: 600; color: inherit; }
.csfbb-warn { margin: 6px 0 0; padding: 10px 14px; border-radius: var(--csfbb-radius); background: #FCEBEF; border: 1px solid #E8A5B7; color: #7A0F2E; font-size: 14px; }
.csfbb-warn[hidden] { display: none; }

/* Knöpfe */
.csfbb-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.csfbb-pill { min-height: 44px; padding: 8px 16px; border-radius: 999px; border: 1px solid #B4BECB; background: #FFFFFF; font-size: 15px !important; font-weight: 500; line-height: 1.2; }
.csfbb-pill.is-on { background: var(--csfbb-ink); border-color: var(--csfbb-ink); color: #FFFFFF; }
.csfbb-up { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 8px; }
.csfbb-up .csfbb-muted { margin: 0; flex: 1 1 220px; }
.csfbb-btn-ghost { display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border: 1px solid var(--csfbb-ink); border-radius: 4px; background: #FFFFFF; font-weight: 500; cursor: pointer; }
.csfbb-btn-ghost:focus-within { outline: 2px solid var(--csfbb-accent); outline-offset: 2px; }
.csfbb-link { background: none; border: 0; padding: 8px 4px; color: var(--csfbb-accent) !important; text-decoration: underline; }
.csfbb-range-l { display: block; font-size: 14px; font-weight: 600; margin: 14px 0 4px; }
.csfbb-range { display: flex; align-items: center; gap: 10px; }
.csfbb-range input[type=range] { flex: 1; min-width: 0; accent-color: var(--csfbb-accent); height: 28px; }
.csfbb-range output { min-width: 64px; text-align: right; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 14px; }
.csfbb-step-btn { flex: none; width: 44px; height: 44px; border: 1px solid #B4BECB; border-radius: 50%; background: #FFFFFF; font-size: 20px !important; line-height: 1; }

/* Schriften & Farben */
.csfbb-pairs { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; margin-bottom: 14px; }
.csfbb-pair { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px; border: 2px solid #E1E6EC; border-radius: 4px; background: #FFFFFF; text-align: left; overflow: hidden; }
.csfbb-pair-h { font-size: 20px; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.csfbb-pair-b { font-size: 13px; color: var(--csfbb-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.csfbb-colors { display: flex; flex-wrap: wrap; gap: 10px; }
.csfbb-color { width: 44px; height: 44px; border-radius: 50%; border: 2px solid #FFFFFF; box-shadow: 0 0 0 1px #B4BECB; }
.csfbb-color.is-on { box-shadow: 0 0 0 3px var(--csfbb-blue); }

/* Vorschau */
.csfbb-preview-wrap { background: #E6EBF1; border-color: #E6EBF1; }
.csfbb-stage { width: 100%; display: flex; justify-content: center; padding: 4px 0 10px; }
.csfbb-sheet { position: relative; overflow: hidden; color: #1A1A1A; box-shadow: 0 1px 2px rgba(0,0,0,.10), 0 14px 32px rgba(20,24,28,.16); touch-action: none; user-select: none; -webkit-user-select: none; }
.csfbb-t { position: absolute; white-space: nowrap; overflow: visible; }
.csfbb-ph { opacity: .35; }
.csfbb-drag { position: absolute; cursor: move; }
.csfbb-drag:hover { outline: 1px dashed var(--csfbb-blue); outline-offset: 2px; }
.csfbb-headgrp .csfbb-t { pointer-events: none; }
.csfbb-logo img { display: block; width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.csfbb-handle { position: absolute; right: -7px; bottom: -7px; width: 14px; height: 14px; border-radius: 3px; background: var(--csfbb-blue); border: 2px solid #FFFFFF; cursor: nwse-resize; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.csfbb-rule { position: absolute; height: 0; }
.csfbb-mark { position: absolute; border-top: 1px solid #8A8A8A; }
.csfbb-g-trim { position: absolute; border: 1px dashed var(--csfbb-magenta); pointer-events: none; }
.csfbb-g-safe { position: absolute; border: 1px dotted var(--csfbb-accent); pointer-events: none; }
.csfbb-g-addr { position: absolute; border: 1px dashed #7CC4EA; background: rgba(0,138,208,.05); pointer-events: none; }
.csfbb-g-addr span { position: absolute; right: 4px; bottom: 2px; font-size: 10px; color: #2B7DB0; font-family: ui-monospace, Menlo, Consolas, monospace; }
.csfbb-snap { position: absolute; top: 0; bottom: 0; border-left: 1px solid var(--csfbb-magenta); pointer-events: none; }
.csfbb-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 12px; color: #33425A; margin: 8px 0 4px; }
.csfbb-legend span { display: inline-flex; align-items: center; gap: 6px; }
.csfbb-legend i { display: inline-block; width: 16px; height: 0; }
.csfbb-lg-bleed { height: 10px !important; background: rgba(219,1,112,.18); }
.csfbb-lg-trim { border-top: 1px dashed var(--csfbb-magenta); }
.csfbb-lg-safe { border-top: 1px dotted var(--csfbb-accent); }
.csfbb-lg-addr { height: 10px !important; border: 1px dashed #7CC4EA; background: rgba(0,138,208,.05); }
.csfbb-warnings { margin: 8px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; }
.csfbb-warnings li { padding: 8px 12px; border-radius: 4px; background: #FFF4E5; border: 1px solid #F5C58A; color: #6B3200; font-size: 13px; }

/* Bestellung */
.csfbb-sum { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 0 0 16px; font-size: 15px; }
.csfbb-sum dt { color: var(--csfbb-muted); margin: 0; }
.csfbb-sum dd { margin: 0; text-align: right; }
.csfbb-terms { font-size: 14px; }
.csfbb-terms a { color: var(--csfbb-accent); }
.csfbb-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.csfbb-total { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding-top: 14px; margin: 6px 0 14px; border-top: 1px solid var(--csfbb-line); }
.csfbb-total span { color: var(--csfbb-muted); font-size: 15px; }
.csfbb-total strong { font-size: 30px; font-weight: 700; }
.csfbb-submit { width: 100%; min-height: 52px; border: 0; border-radius: 4px; background: var(--csfbb-accent) !important; color: #FFFFFF !important; font-size: 17px !important; font-weight: 600; }
.csfbb-submit:disabled { opacity: .7; cursor: default; }
.csfbb-msg:empty { display: none; }
.csfbb-msg { margin-top: 14px; padding: 14px 16px; border-radius: var(--csfbb-radius); font-size: 14px; }
.csfbb-msg.is-ok { background: #E5F3FB; border: 1px solid #8FCDEE; }
.csfbb-msg.is-err { background: #FCEBEF; border: 1px solid #E8A5B7; color: #7A0F2E; }
.csfbb-msg .csfbb-mono { font-size: 13px; word-break: break-all; }
