/* ==========================================================================
   WireCode – Lizenzkauf
   ========================================================================== */

.nav-plain { display: flex; align-items: center; gap: 24px; font-size: 15px; }
.nav-plain a { color: var(--ink-2); text-decoration: none; white-space: nowrap; }
.nav-plain a:hover { color: var(--ink); text-decoration: underline; }

.testmode {
  border-bottom: 1px solid var(--rule);
  background: var(--paper-2);
  font-size: 13.5px;
  color: var(--ink-2);
}
.testmode .wrap { display: flex; align-items: center; gap: 10px; padding-top: 9px; padding-bottom: 9px; }
.testmode .wrap::before {
  content: "DEMO";
  flex: none;
  padding: 1px 6px;
  border: 1px solid var(--ink-3);
  border-radius: 3px;
  font-family: var(--f-mono);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: .1em;
  color: var(--ink-2);
}

.checkout { padding-top: clamp(32px, 5vw, 56px); padding-bottom: 96px; }

.co-head { max-width: 720px; margin-bottom: 36px; }
.co-step { margin-bottom: 12px; font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.co-head h1, .done h1 { font-size: clamp(34px, 5vw, 56px); font-weight: 700; }
.co-sub { margin-top: 14px; font-size: 18px; color: var(--ink-2); }

.co-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: clamp(28px, 4vw, 56px);
  align-items: start;
}

/* ---------- Blöcke ---------- */
.block {
  margin: 0 0 20px;
  padding: 26px 28px 28px;
  border: 1px solid var(--rule);
  border-radius: 12px;
  background: var(--card);
  min-width: 0;
}
.block legend {
  float: left;
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
  padding: 0;
  font-family: var(--f-display);
  font-size: 22px;
  font-weight: 600;
}
.block legend + * { clear: both; }
.block-no {
  padding: 2px 7px;
  border: 1px solid var(--ink);
  border-radius: 4px;
  font-family: var(--f-mono);
  font-size: 12px;
  font-weight: 600;
}

/* ---------- Paketwahl ---------- */
.plan-options { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.plan-opt {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 16px 16px 14px;
  border: 1px solid var(--rule-strong);
  border-radius: 8px;
  background: var(--white);
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s;
}
.plan-opt:hover { border-color: var(--ink-3); }
.plan-opt input { position: absolute; opacity: 0; pointer-events: none; }
.plan-opt:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.plan-opt:has(input:focus-visible) { outline: 2px solid var(--ink); outline-offset: 3px; }
.po-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.po-name { font-family: var(--f-display); font-size: 20px; font-weight: 700; }
.po-type { font-family: var(--f-mono); font-size: 11px; color: var(--ink-3); white-space: nowrap; }
.po-seats { font-size: 14px; color: var(--ink-2); }
.po-price { margin-top: 8px; font-family: var(--f-display); font-size: 22px; font-weight: 600; }
.po-price small { display: block; font-family: var(--f-mono); font-size: 11.5px; font-weight: 400; color: var(--ink-3); }
.po-year { font-family: var(--f-mono); font-size: 12px; color: var(--ink-2); }
.plan-hint { margin-top: 14px; }
.plan-opt::after {
  content: "";
  position: absolute;
  top: 14px; right: 14px;
  width: 8px; height: 8px;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1.5px var(--rule-strong);
}
.plan-opt:has(input:checked)::after {
  background: var(--green);
  box-shadow: 0 0 0 2px rgba(54, 210, 111, .2), 0 0 8px rgba(54, 210, 111, .6);
}
.plan-opt .po-type { margin-right: 16px; }

.extras {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px dashed var(--rule-strong);
}
.extras-title { font-weight: 600; }
.extras.is-disabled .extras-title { color: var(--ink-3); }

.stepper {
  display: inline-flex;
  align-items: stretch;
  flex: none;
  border: 1px solid var(--rule-strong);
  border-radius: 6px;
  background: var(--white);
  overflow: hidden;
}
.stepper button {
  width: 44px; height: 44px;
  border: 0;
  background: transparent;
  font-size: 20px;
  cursor: pointer;
}
.stepper button:hover:not(:disabled) { background: var(--paper-2); }
.stepper button:disabled { color: var(--rule-strong); cursor: not-allowed; }
.stepper output {
  display: grid;
  place-items: center;
  min-width: 52px;
  border-left: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
  font-family: var(--f-mono);
  font-size: 17px;
  font-weight: 600;
}

/* ---------- Felder ---------- */
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 16px; }
.span-2 { grid-column: span 2; }
.fields-sep {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 28px 0 18px;
  font-family: var(--f-mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.fields-sep::after { content: ""; flex: 1; height: 1px; background: var(--rule); }

/* ---------- Zahlung ---------- */
.pay-options { display: grid; gap: 10px; }
.pay-opt {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--rule-strong);
  border-radius: 8px;
  background: var(--white);
  cursor: pointer;
}
.pay-opt:hover { border-color: var(--ink-3); }
.pay-opt:has(input:checked) { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.pay-opt input {
  appearance: none;
  flex: none;
  width: 20px; height: 20px;
  margin: 2px 0 0;
  border: 1px solid var(--rule-strong);
  border-radius: 50%;
  background: var(--white);
  display: grid;
  place-items: center;
}
.pay-opt input:checked { border-color: var(--ink); background: var(--ink); }
.pay-opt input:checked::after {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--green);
}
.pay-opt input:focus-visible { outline: 2px solid var(--ink); outline-offset: 2px; }
.pay-body { display: flex; flex-direction: column; gap: 2px; }
.pay-body span { font-size: 14px; color: var(--ink-3); }
.pay-hint { margin-top: 14px; }

.consent { display: grid; gap: 12px; padding: 4px 4px 0; }
.consent-err { margin-left: 32px; }
.consent.has-error .consent-err { display: block; }

/* ---------- Beleg ---------- */
.co-summary { position: sticky; top: calc(var(--nav-h) + 20px); }
.receipt {
  position: relative;
  padding: 24px 24px 24px;
  border-radius: 4px;
  background: var(--white);
  font-family: var(--f-mono);
  font-size: 13.5px;
  box-shadow: 0 1px 0 rgba(0, 0, 0, .04), 0 20px 40px -30px rgba(20, 22, 26, .4);
  -webkit-mask:
    radial-gradient(circle 6px at 50% 0, transparent 5.5px, #000 6px) 0 0 / 16px 51% repeat-x,
    radial-gradient(circle 6px at 50% 100%, transparent 5.5px, #000 6px) 0 100% / 16px 51% repeat-x;
  mask:
    radial-gradient(circle 6px at 50% 0, transparent 5.5px, #000 6px) 0 0 / 16px 51% repeat-x,
    radial-gradient(circle 6px at 50% 100%, transparent 5.5px, #000 6px) 0 100% / 16px 51% repeat-x;
}
.rc-head {
  display: flex;
  justify-content: space-between;
  padding: 8px 0 14px;
  border-bottom: 1px dashed var(--rule-strong);
  font-size: 12px;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.rc-head span:first-child { font-weight: 600; color: var(--ink); }

.rc-seats {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 18px 0;
  padding: 14px 16px;
  border-radius: 6px;
  background: #0A0B0D;
  color: #A9EFC3;
}
.rc-seg { height: 46px; }
.rc-seats-label { display: block; font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: #6FE79B; }
.rc-seats-sub { display: block; margin-top: 2px; font-size: 12.5px; color: #8E959D; }

.rc-lines div, .rc-total div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 6px 0;
}
.rc-lines dt, .rc-total dt { color: var(--ink-2); }
.rc-lines dd, .rc-total dd { margin: 0; text-align: right; white-space: nowrap; }
.rc-lines dt small { display: block; font-size: 11.5px; color: var(--ink-3); }
.rc-lines { margin: 0 0 6px; padding-bottom: 10px; border-bottom: 1px dashed var(--rule-strong); }
.rc-total { margin: 8px 0 0; }
.rc-grand {
  margin-top: 6px;
  padding-top: 12px !important;
  border-top: 2px solid var(--ink);
  font-size: 15px;
  font-weight: 600;
}
.rc-grand dt { color: var(--ink) !important; }
.rc-grand dd { font-family: var(--f-display); font-size: 26px; font-weight: 700; line-height: 1; }
.rc-note { margin: 16px 0 20px; font-family: var(--f-body); font-size: 13px; line-height: 1.5; color: var(--ink-3); }

/* ---------- Erfolg ---------- */
.done { padding: clamp(48px, 8vw, 96px) var(--gutter) 120px; }
.done-card {
  max-width: 680px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 48px);
  border: 1px solid var(--rule);
  border-radius: 14px;
  background: var(--card);
}
.done-seg {
  display: inline-flex;
  height: 64px;
  margin-bottom: 28px;
  padding: 16px 20px;
  border-radius: 8px;
  background: #0A0B0D;
  box-sizing: content-box;
}
.done-text { margin-top: 14px; font-size: 18px; color: var(--ink-2); }
.done-facts {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 24px;
  margin: 26px 0 30px;
  padding: 18px 0;
  border-top: 1px dashed var(--rule-strong);
  border-bottom: 1px dashed var(--rule-strong);
  font-family: var(--f-mono);
  font-size: 14px;
}
.done-facts dt { color: var(--ink-3); }
.done-facts dd { margin: 0; }
.done-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.done-hint { margin-top: 20px; }

.co-footer { padding: 24px 0 40px; border-top: 1px solid var(--rule); font-size: 14px; color: var(--ink-3); }
.co-footer .wrap { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.co-footer a { color: var(--ink-3); }

/* ---------- Responsive ---------- */
@media (max-width: 1000px) {
  .co-grid { grid-template-columns: 1fr; }
  .co-summary { position: static; max-width: 560px; }
}

@media (max-width: 640px) {
  .hide-sm { display: none; }
  .nav-plain { gap: 16px; font-size: 14px; }
  .block { padding: 20px 18px 22px; }
  .plan-options { grid-template-columns: 1fr; }
  .plan-opt { display: grid; grid-template-columns: 1fr auto; grid-template-areas: "top price" "seats price"; align-items: center; }
  .po-top { grid-area: top; justify-content: flex-start; }
  .po-seats { grid-area: seats; }
  .plan-opt { grid-template-areas: "top price" "seats price" "year price"; }
  .po-price { grid-area: price; margin: 0 22px 0 0; text-align: right; }
  .po-year { grid-area: year; }
  .plan-opt::after { top: 50%; margin-top: -4px; }
  .extras { flex-direction: column; align-items: flex-start; }
  .fields { grid-template-columns: 1fr; }
  .span-2 { grid-column: auto; }
  .done-facts { grid-template-columns: 1fr; gap: 2px; }
  .done-facts dd { margin-bottom: 8px; }
}
