.voucher-page {
  background: var(--bg);
}

.voucher-intro {
  padding: 46px 18px 34px;
  border-bottom: 1px solid var(--border);
}

.voucher-intro-inner {
  width: min(100%, 900px);
  margin: 0 auto;
  text-align: center;
}

.voucher-back-link {
  display: inline-block;
  margin-bottom: 28px;
  color: var(--text-muted);
  font-size: 0.82rem;
  text-decoration: none;
}

.voucher-back-link:hover,
.voucher-back-link:focus-visible {
  color: var(--primary);
}

.voucher-kicker,
.voucher-step-label {
  color: var(--secondary);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.voucher-intro h1 {
  margin: 10px 0 14px;
  color: var(--text);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 2.45rem;
  font-weight: 600;
  line-height: 1.05;
}

.voucher-intro h1 em {
  color: var(--primary);
  font-weight: 400;
}

.voucher-lead {
  max-width: 660px;
  margin: 0 auto;
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.7;
}

.voucher-benefits {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 9px 22px;
  margin: 24px 0 0;
  padding: 0;
  color: var(--text);
  font-size: 0.84rem;
  list-style: none;
}

.voucher-benefits li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.voucher-benefits li::before {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--secondary);
  content: '';
}

.voucher-builder {
  padding: 42px 16px 64px;
  background: var(--bg-soft);
}

.voucher-layout {
  display: grid;
  width: min(100%, 1140px);
  margin: 0 auto;
  gap: 30px;
}

.voucher-form,
.voucher-preview-column {
  min-width: 0;
}

.voucher-form {
  padding: 24px 18px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card);
  box-shadow: var(--shadow);
}

.voucher-form-heading,
.voucher-preview-heading {
  margin-bottom: 24px;
}

.voucher-form h2,
.voucher-preview-column h2 {
  margin-top: 6px;
  color: var(--text);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.7rem;
  font-weight: 600;
  line-height: 1.15;
}

.voucher-fieldset {
  min-width: 0;
  margin: 0;
  padding: 0 0 28px;
  border: 0;
  border-bottom: 1px solid var(--border);
}

.voucher-design-fieldset {
  padding-top: 28px;
}

.voucher-fieldset legend,
.field-group label {
  display: block;
  margin-bottom: 10px;
  color: var(--text);
  font-size: 0.9rem;
  font-weight: 700;
}

.amount-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 9px;
}

.amount-option {
  position: relative;
}

.amount-option--custom {
  grid-column: 1 / -1;
}

.amount-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.amount-option span {
  display: flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 700;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.amount-option input:checked + span {
  border-color: var(--secondary);
  background: var(--info-bg);
  color: var(--secondary);
}

.amount-option input:focus-visible + span {
  outline: 2px solid var(--secondary);
  outline-offset: 3px;
}

.custom-amount {
  margin-top: 16px;
}

.design-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.design-option {
  position: relative;
}

.design-option input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.design-choice {
  display: grid;
  min-height: 104px;
  place-items: center;
  gap: 7px;
  padding: 10px 8px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--bg);
  cursor: pointer;
  text-align: center;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.design-choice > strong {
  color: var(--text-muted);
  font-size: 0.76rem;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.design-option input:checked + .design-choice {
  border-color: var(--secondary);
  background: var(--info-bg);
}

.design-option input:checked + .design-choice > strong {
  color: var(--secondary);
}

.design-option input:focus-visible + .design-choice {
  outline: 2px solid var(--secondary);
  outline-offset: 3px;
}

.design-swatch {
  display: grid;
  width: min(100%, 92px);
  height: auto;
  aspect-ratio: 1.414 / 1;
  place-items: center;
  border: 1px solid currentColor;
  border-radius: 3px;
  background-color: var(--swatch-bg);
  background-image: var(--swatch-image, none);
  background-position: center;
  background-size: 100% 100%;
  color: var(--swatch-border);
  box-shadow: inset 0 0 0 3px var(--swatch-bg), inset 0 0 0 4px currentColor;
}

.design-swatch--dark {
  --swatch-bg: #17101f;
  --swatch-border: #dfbd6d;
  --swatch-text: #f7eedf;
  --swatch-image: url('../assets/img/vouchers/voucher-night-melody.jpg');
}

.design-swatch--rose {
  --swatch-bg: #cc9672;
  --swatch-border: #765040;
  --swatch-text: #26244f;
  --swatch-image: url('../assets/img/vouchers/voucher-gift-ribbon.jpg');
}

.design-swatch--floral {
  --swatch-bg: #fffaf3;
  --swatch-border: #bd7e68;
  --swatch-text: #4c2940;
  --swatch-image: url('../assets/img/vouchers/voucher-floral-rose-light.jpg');
}

.design-swatch--pure {
  --swatch-bg: #fffaf3;
  --swatch-border: #bd7e68;
  --swatch-text: #26244f;
}

.design-swatch--starlight {
  --swatch-bg: #fffaf0;
  --swatch-border: #bf805f;
  --swatch-text: #55364f;
  --swatch-image: url('../assets/img/vouchers/voucher-starlight.jpg');
}

.custom-amount > label {
  display: block;
  margin-bottom: 8px;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 600;
}

.amount-input-wrap {
  position: relative;
}

.amount-input-wrap span {
  position: absolute;
  top: 50%;
  right: 16px;
  color: var(--text-muted);
  transform: translateY(-50%);
}

.voucher-fields {
  display: grid;
  gap: 20px;
  padding: 28px 0;
}

.field-label-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.field-label-row span {
  flex: 0 0 auto;
  color: var(--text-muted);
  font-size: 0.75rem;
}

.voucher-form input[type='text'],
.voucher-form input[type='email'],
.voucher-form input[type='number'],
.voucher-form textarea {
  width: 100%;
  min-height: 48px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: none;
  background: var(--bg);
  color: var(--text);
  font: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.voucher-form textarea {
  min-height: 106px;
  resize: vertical;
  line-height: 1.5;
}

.voucher-form input:focus,
.voucher-form textarea:focus {
  border-color: var(--border-active);
  box-shadow: 0 0 0 3px var(--info-bg);
}

.voucher-form input::placeholder,
.voucher-form textarea::placeholder {
  color: var(--text-muted);
  opacity: 0.72;
}

.field-hint,
.voucher-payment-note {
  margin: 7px 0 0;
  color: var(--text-muted);
  font-size: 0.75rem;
  line-height: 1.45;
}

.recipient-toggle {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--text);
  cursor: pointer;
  font-size: 0.86rem;
  line-height: 1.45;
}

.recipient-toggle input {
  width: 18px;
  height: 18px;
  margin-top: 1px;
  accent-color: var(--primary);
}

.voucher-checkout {
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.voucher-checkout > div:first-child {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.voucher-checkout span {
  color: var(--text-muted);
  font-size: 0.86rem;
}

.voucher-checkout strong {
  color: var(--secondary);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.8rem;
}

.voucher-legal {
  display: grid !important;
  gap: 12px !important;
  margin: 0 0 18px !important;
}

.voucher-legal-option {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 0.78rem;
  line-height: 1.5;
}

.voucher-legal-option input {
  width: 18px;
  height: 18px;
  margin: 1px 0 0;
  flex: 0 0 auto;
  accent-color: var(--secondary);
}

.voucher-legal-option a {
  color: var(--secondary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.voucher-submit {
  width: 100%;
  min-height: 52px;
  padding: 13px 18px;
  border: 1px solid var(--secondary);
  border-radius: 8px;
  background: var(--secondary);
  color: #17101f;
  cursor: pointer;
  font: inherit;
  font-weight: 800;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.voucher-submit:hover {
  border-color: var(--champagne);
  background: var(--champagne);
  transform: translateY(-1px);
}

.voucher-submit:focus-visible {
  outline: 2px solid var(--secondary);
  outline-offset: 4px;
}

.voucher-submit:disabled {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

.voucher-status {
  margin-top: 14px;
  padding: 12px 14px;
  border: 1px solid var(--info-border);
  border-radius: 8px;
  background: var(--info-bg);
  color: var(--text);
  font-size: 0.82rem;
  line-height: 1.5;
}

.voucher-status.is-error {
  border-color: rgba(218, 92, 92, 0.48);
  background: rgba(139, 43, 43, 0.15);
  color: #ffd8d8;
}

.voucher-preview-column {
  align-self: start;
}

.gift-voucher {
  --voucher-bg: #17101f;
  --voucher-bg-image: url('../assets/img/vouchers/voucher-night-melody.jpg');
  --voucher-border: #d6b45f;
  --voucher-inner-border: rgba(223, 189, 109, 0.42);
  --voucher-text: #f7eedf;
  --voucher-accent: #dfbd6d;
  --voucher-label: #dfbd6d;
  --voucher-subtle: #d0c1d2;
  --voucher-small: #cfc2ae;
  --voucher-watermark-opacity: 0;
  position: relative;
  display: flex;
  aspect-ratio: 1.414 / 1;
  min-height: 0;
  flex-direction: column;
  justify-content: space-between;
  overflow: hidden;
  padding: 20px;
  border: 1px solid var(--voucher-border);
  border-radius: 8px;
  background-color: var(--voucher-bg);
  background-image: var(--voucher-bg-image);
  background-position: center;
  background-size: 100% 100%;
  box-shadow: 0 22px 50px rgba(74, 43, 34, 0.24);
  color: var(--voucher-text);
  transition: background 0.22s ease, border-color 0.22s ease, color 0.22s ease;
}

.gift-voucher[data-design='rose'] {
  --voucher-bg: #cc9672;
  --voucher-bg-image: url('../assets/img/vouchers/voucher-gift-ribbon.jpg');
  --voucher-border: #765040;
  --voucher-inner-border: rgba(255, 250, 243, 0.56);
  --voucher-text: #26244f;
  --voucher-accent: #fffaf3;
  --voucher-label: #503343;
  --voucher-subtle: #503b49;
  --voucher-small: #493440;
  --voucher-watermark-opacity: 0;
}

.gift-voucher[data-design='floral'] {
  --voucher-bg: #fffaf3;
  --voucher-bg-image: url('../assets/img/vouchers/voucher-floral-rose-light.jpg');
  --voucher-border: #c98b73;
  --voucher-inner-border: rgba(185, 112, 91, 0.45);
  --voucher-text: #3b2946;
  --voucher-accent: #a85f50;
  --voucher-label: #864a40;
  --voucher-subtle: #654c57;
  --voucher-small: #654c57;
  --voucher-watermark-opacity: 0;
}

.gift-voucher[data-design='pure'] {
  --voucher-bg: #fffaf3;
  --voucher-bg-image: none;
  --voucher-border: #b9785e;
  --voucher-inner-border: rgba(185, 120, 94, 0.44);
  --voucher-text: #26244f;
  --voucher-accent: #7f4757;
  --voucher-label: #744153;
  --voucher-subtle: #654a5b;
  --voucher-small: #654a5b;
  --voucher-watermark-opacity: 0.025;
}

.gift-voucher[data-design='starlight'] {
  --voucher-bg: #fffaf0;
  --voucher-bg-image: url('../assets/img/vouchers/voucher-starlight.jpg');
  --voucher-border: #bf805f;
  --voucher-inner-border: rgba(191, 128, 95, 0.42);
  --voucher-text: #3f2940;
  --voucher-accent: #a9654e;
  --voucher-label: #7f493e;
  --voucher-subtle: #65505a;
  --voucher-small: #65505a;
  --voucher-watermark-opacity: 0;
}

.gift-voucher::before,
.gift-voucher::after {
  position: absolute;
  content: '';
  pointer-events: none;
}

.gift-voucher::before {
  inset: 0;
  background: url('../assets/logo-momentemanufaktur-round-192.png') center / 44% auto no-repeat;
  opacity: var(--voucher-watermark-opacity);
}

.gift-voucher::after {
  inset: 8px;
  border: 1px solid var(--voucher-inner-border);
  border-radius: 4px;
}

.gift-voucher-topline {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  color: var(--voucher-text);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1rem;
  font-weight: 600;
}

.gift-voucher-logo {
  width: 34px;
  height: 34px;
  object-fit: contain;
}

.gift-voucher-brand {
  display: grid;
  gap: 1px;
}

.gift-voucher-brand span {
  color: var(--voucher-text);
  font-size: 1rem;
  line-height: 1;
}

.gift-voucher-brand small {
  color: var(--voucher-subtle);
  font-size: 0.55rem;
  font-style: italic;
  font-weight: 400;
  line-height: 1.1;
}

.gift-voucher-main {
  position: relative;
  z-index: 1;
  text-align: center;
}

.gift-voucher-label {
  display: block;
  margin-bottom: 3px;
  color: var(--voucher-label);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.gift-voucher-value {
  display: block;
  color: var(--voucher-accent);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 2.9rem;
  font-weight: 600;
  line-height: 1;
}

.gift-voucher-recipient {
  margin-top: 8px;
  color: var(--voucher-text);
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 1.15rem;
  font-style: italic;
  font-weight: 600;
}

.gift-voucher-message {
  display: -webkit-box;
  max-width: 80%;
  min-height: 2.7em;
  margin: 6px auto 0;
  overflow: hidden;
  color: var(--voucher-subtle);
  font-size: 0.72rem;
  line-height: 1.35;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.gift-voucher-footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding-top: 12px;
  border-top: 1px solid var(--voucher-inner-border);
}

.gift-voucher-footer > div:last-child {
  text-align: right;
}

.gift-voucher-footer span,
.gift-voucher-footer strong {
  display: block;
}

.gift-voucher-footer span {
  margin-bottom: 2px;
  color: var(--voucher-small);
  font-size: 0.55rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.gift-voucher-footer strong {
  color: var(--voucher-text);
  font-size: 0.68rem;
}

.voucher-preview-details {
  display: grid;
  gap: 0;
  margin-top: 22px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.voucher-preview-details > div {
  display: grid;
  gap: 3px;
  padding: 14px 2px;
  border-bottom: 1px solid var(--border);
}

.voucher-preview-details > div:last-child {
  border-bottom: 0;
}

.voucher-preview-details strong {
  color: var(--text);
  font-size: 0.84rem;
}

.voucher-preview-details span {
  color: var(--text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

[hidden] {
  display: none !important;
}

@media (min-width: 480px) {
  .amount-options {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .amount-option--custom {
    grid-column: 1 / -1;
  }

  .design-options {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .gift-voucher {
    padding: 24px;
  }

  .gift-voucher-value {
    font-size: 3.4rem;
  }

  .gift-voucher-recipient {
    font-size: 1.35rem;
  }

  .gift-voucher-message {
    font-size: 0.8rem;
  }

  .gift-voucher-footer span {
    font-size: 0.6rem;
  }

  .gift-voucher-footer strong {
    font-size: 0.76rem;
  }
}

@media (min-width: 760px) {
  .voucher-intro {
    padding: 62px 24px 44px;
  }

  .voucher-intro h1 {
    font-size: 3.2rem;
  }

  .voucher-builder {
    padding: 58px 24px 80px;
  }

  .voucher-form {
    padding: 30px;
  }
}

@media (min-width: 960px) {
  .voucher-layout {
    grid-template-columns: minmax(0, 0.94fr) minmax(420px, 1.06fr);
    gap: 54px;
  }

  .voucher-preview-column {
    position: sticky;
    top: 90px;
  }

  .gift-voucher {
    padding: 28px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .voucher-submit,
  .amount-option span,
  .voucher-form input,
  .voucher-form textarea {
    transition: none;
  }
}
