/* BlogWebkatalog – Eintragsassistent */
html:not(.js) .js-only { display: none !important; }
.link-btn { background: none; border: 0; padding: 0; font: inherit; color: var(--brand-ink); text-decoration: underline; cursor: pointer; }
.req { color: var(--brand); }
.wiz-page-head { margin-bottom: 18px; }
.wizard { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: clamp(18px, 3.5vw, 36px); scroll-margin-top: 80px; }
.wizard fieldset { border: 0; background: none; padding: 0; margin: 0 0 16px; }
.wizard .wiz-step + .wiz-step { margin-top: 36px; padding-top: 28px; border-top: 1px solid var(--line); }
.wizard.is-wizard .wiz-step + .wiz-step { margin-top: 0; padding-top: 0; border-top: 0; }
.wiz-head { margin-bottom: 20px; }
.wiz-head h2 { font-family: var(--font-serif); font-size: clamp(1.35rem, 1.1rem + 1vw, 1.75rem); outline: none; }
.wiz-kicker { font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand); margin: 0 0 4px; }

/* Fortschritt */
.wiz-progress { margin: -4px 0 28px; position: relative; }
.wiz-progress ol { list-style: none; margin: 0; padding: 0; display: flex; justify-content: space-between; position: relative; z-index: 1; }
.wiz-progress button { display: flex; flex-direction: column; align-items: center; gap: 6px; background: none; border: 0; padding: 0; font: inherit; color: var(--muted); cursor: pointer; min-width: 56px; }
.wiz-progress button:disabled { cursor: default; }
.wiz-dot { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--surface); border: 2px solid var(--line); font-weight: 700; font-size: .9rem; transition: background .2s, border-color .2s, color .2s; }
.wiz-label { font-size: .8rem; font-weight: 600; }
.wiz-progress .is-done .wiz-dot { background: var(--brand-soft); border-color: var(--brand); color: var(--brand-ink); font-size: 0; }
.wiz-progress .is-done .wiz-dot::after { content: "✓"; font-size: .95rem; }
.wiz-progress .is-current .wiz-dot { background: var(--brand); border-color: var(--brand); color: #fff; font-size: .9rem; box-shadow: 0 0 0 4px var(--brand-soft); }
.wiz-progress .is-current .wiz-dot::after { content: none; }
.wiz-progress .is-current .wiz-label { color: var(--text); }
.wiz-progress button:not(:disabled):hover .wiz-label { color: var(--brand-ink); }
.wiz-bar { position: absolute; left: 28px; right: 28px; top: 16px; height: 2px; background: var(--line); }
.wiz-bar span { display: block; height: 100%; width: 0; background: var(--brand); transition: width .3s ease; }

.wiz-errors ul { margin: 8px 0 0; padding-left: 18px; }
.wiz-errors a { color: inherit; font-weight: 600; }

/* Schritt 1 */
.url-row { display: flex; gap: 8px; }
.url-row input { flex: 1; min-width: 0; font-size: 1.08rem; padding: 12px 14px; }
.url-check { margin-top: 10px; padding: 10px 14px; border-radius: var(--radius-sm); font-size: .93rem; line-height: 1.5; }
.url-check-loading { background: var(--surface-2); color: var(--muted); }
.url-check-ok { background: var(--ok-soft); color: var(--ok); }
.url-check-warn { background: var(--warn-soft); color: var(--warn); }
.url-check-error { background: var(--err-soft); color: var(--err); }
.spinner { display: inline-block; width: 14px; height: 14px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; vertical-align: -2px; margin-right: 4px; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.auto-badge { display: inline-block; font-size: .72rem; font-weight: 600; padding: 1px 8px; border-radius: 999px; background: var(--ok-soft); color: var(--ok); margin-left: 4px; vertical-align: 1px; }
.field-more { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px; margin: 0 0 16px; }
.field-more summary { cursor: pointer; font-weight: 600; }
.field-more[open] summary { margin-bottom: 10px; }
.field-more .field { margin-bottom: 4px; }
.wiz-howto { margin-top: 26px; padding: 16px 18px; border-radius: var(--radius); background: var(--surface-2); }
.wiz-howto h3 { font-size: .95rem; margin-bottom: 6px; }
.wiz-howto ol { margin: 0 0 6px; padding-left: 20px; }
.wiz-howto li { margin: 3px 0; }

/* Schritt 2 */
.cat-picker legend { font-weight: 600; margin-bottom: 8px; padding: 0; }
.cat-options { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; }
.cat-picker .cat-option { position: relative; display: flex; font-weight: 400; margin: 0; flex-direction: column; gap: 2px; padding: 11px 14px 11px 40px; border: 1.5px solid var(--line); border-radius: var(--radius-sm); cursor: pointer; background: var(--bg); transition: border-color .15s, background .15s; }
.cat-option:hover { border-color: var(--muted); }
.cat-option input { position: absolute; left: 14px; top: 14px; width: 16px; height: 16px; accent-color: var(--brand); margin: 0; }
.cat-option:has(input:checked) { border-color: var(--brand); background: var(--brand-soft); }
.cat-option:has(input:focus-visible) { outline: 3px solid var(--brand); outline-offset: 2px; }
.cat-name { font-weight: 600; }
.cat-hint { font-size: .8rem; color: var(--muted); line-height: 1.35; }
.cat-picker.has-error .cat-option { border-color: var(--err); }

.tag-ui { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 6px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--bg); }
.tag-ui:focus-within { outline: 3px solid var(--brand); outline-offset: 1px; }
.field:has(#err-tags:not([hidden])) .tag-ui { border-color: var(--err); }
.tag-chips { display: contents; list-style: none; }
.tag-chips li { display: inline-flex; align-items: center; gap: 2px; padding: 4px 4px 4px 11px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-ink); font-weight: 600; font-size: .9rem; }
.tag-chips button { border: 0; background: none; color: inherit; font-size: 1.05rem; line-height: 1; width: 24px; height: 24px; border-radius: 50%; cursor: pointer; }
.tag-chips button:hover { background: rgba(0, 0, 0, .08); }
.field .tag-entry { flex: 1 1 180px; width: auto; min-width: 120px; border: 0; outline: none; background: transparent; padding: 6px; }
.tag-suggest { flex-basis: 100%; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; padding: 4px 2px 2px; }
.tag-suggest:empty { display: none; }
.tag-suggest button { border: 1px dashed var(--line); background: var(--surface); color: var(--text); border-radius: 999px; padding: 3px 10px; font: inherit; font-size: .84rem; cursor: pointer; }
.tag-suggest button:hover { border-color: var(--brand); color: var(--brand-ink); }
[data-tags-hint].is-ok { color: var(--ok); }

/* Schritt 3 */
.wiz-split { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 28px; align-items: start; }
.wiz-preview { position: sticky; top: 90px; }
.wiz-preview-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; margin-bottom: 8px; }
.wiz-preview .card { pointer-events: none; }
.wiz-preview .card:hover { transform: none; box-shadow: none; }
.wiz-preview .card-text { overflow-wrap: anywhere; }
.meter { margin-top: 6px; }
.meter-track { position: relative; height: 6px; border-radius: 6px; background: var(--surface-2); overflow: hidden; }
.meter-fill { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: var(--warn); border-radius: 6px; transition: width .15s, background .15s; }
.meter[data-state="ok"] .meter-fill { background: var(--ok); }
.meter-min { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--muted); opacity: .45; z-index: 1; }
.meter-text { font-size: .82rem; color: var(--muted); margin-top: 4px; font-variant-numeric: tabular-nums; }
.meter[data-state="low"] .meter-text { color: var(--warn); }
.meter[data-state="ok"] .meter-text { color: var(--ok); }
.tips { margin-top: 12px; font-size: .92rem; }
.tips summary { cursor: pointer; color: var(--brand-ink); font-weight: 600; }
.tips ul { margin: 8px 0 0; padding-left: 20px; }
.tips li { margin: 4px 0; }

/* Schritt 4 */
.privacy-note { display: flex; gap: 6px; align-items: baseline; }
.email-suggest { margin: 6px 0 0; font-size: .9rem; color: var(--warn); }

/* Schritt 5 */
.wiz-summary dl { margin: 0 0 20px; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.wiz-summary dl > div { display: grid; grid-template-columns: 120px minmax(0, 1fr) auto; gap: 4px 14px; padding: 12px 16px; border-bottom: 1px solid var(--line); align-items: start; }
.wiz-summary dl > div:last-child { border-bottom: 0; }
.wiz-summary dl > div.has-error { background: var(--err-soft); }
.wiz-summary dt { font-weight: 700; font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding-top: 3px; }
.wiz-summary dd { margin: 0; overflow-wrap: anywhere; }
.copy-row { display: flex; gap: 8px; align-items: center; margin-bottom: 12px; }
.copy-row .code-snippet { flex: 1; margin: 0; display: block; }
.wiz-next-info { margin-top: 8px; padding: 14px 16px; border-radius: var(--radius-sm); background: var(--info-soft); font-size: .93rem; }
.wiz-next-info strong { display: block; margin-bottom: 2px; }

/* Navigation */
.wiz-nav { display: flex; gap: 10px; justify-content: flex-end; align-items: center; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }
.wiz-nav [data-prev] { margin-right: auto; }
.wizard.is-wizard .wiz-required-note { display: none; }

@media (max-width: 760px) {
  .wizard { scroll-margin-top: 150px; }
  .wiz-label { display: none; }
  .wiz-progress button { min-width: 0; }
  .wiz-bar { left: 17px; right: 17px; }
  .wiz-split { grid-template-columns: 1fr; }
  .wiz-preview { position: static; order: -1; max-width: 260px; }
  .wiz-summary dl > div { grid-template-columns: 1fr auto; }
  .wiz-summary dd { grid-column: 1 / -1; grid-row: 2; }
  .url-row { flex-direction: column; }
  .wiz-nav { position: sticky; bottom: 0; z-index: 2; background: var(--surface); margin: 28px -18px -18px; padding: 12px 18px; border-radius: 0 0 18px 18px; box-shadow: 0 -4px 12px rgba(0, 0, 0, .06); }
  .wiz-nav .btn-lg { flex: 1; }
}
