:root {
  --bg: #7243e8;
  --card: #ffffff;
  --card-subtle: #f9f9fb;
  --muted: #737373;
  --text: #0a0a0a;
  --border: #e8e8ec;
  --primary: #0a0a0a;
  --primary-hover: #262626;
  --accent-purple: #7243e8;
  --accent-light: #f0ebff;
  --success-bg: #f0fdf4;
  --font-sans: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08), 0 2px 4px rgba(0, 0, 0, 0.04);
}
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  min-height: 100%;
}
body {
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  /* background:
      radial-gradient(
          1200px 700px at 20% -10%,
          rgba(114, 67, 232, 0.18) 0%,
          rgba(15, 14, 18, 0) 55%
        ),
      radial-gradient(
        900px 600px at 90% 10%,
        rgba(247, 59, 101, 0.12) 0%,
        rgba(15, 14, 18, 0) 55%
      ),
      #0f0e12; */
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(
      ellipse 80% 60% at 10% 0%,
      rgba(255, 255, 255, 0.12) 0%,
      transparent 60%
    ),
    radial-gradient(
      ellipse 60% 80% at 90% 100%,
      rgba(0, 0, 0, 0.15) 0%,
      transparent 60%
    );

  /* background:
      radial-gradient(
          1200px 700px at 20% -10%,
          rgba(114, 67, 232, 0.18) 0%,
          rgba(15, 14, 18, 0) 55%
        ),
      radial-gradient(
        900px 600px at 90% 10%,
        rgba(247, 59, 101, 0.12) 0%,
        rgba(15, 14, 18, 0) 55%
      ), 
      #0f0e12; */
  pointer-events: none;
  z-index: 0;
}

/* ── Topbar ── */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: rgba(114, 67, 232, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 32px;
  z-index: 100;
}
.topbar .topbar-left {
  display: flex;
  align-items: center;
  gap: 10px;
  justify-self: start;
}
.topbar .topbar-left .topbar-logo {
  height: 24px;
  width: auto;
}
/* Inner glass pills — sit inside the larger glass topbar */
.topbar-back,
.topbar-secure {
  position: relative;
  isolation: isolate;
  border-radius: 100px;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow:
    inset -1px 1px 6px -1px rgba(255, 255, 255, 0.35),
    inset 0 1px 6px -2px rgba(255, 255, 255, 0.25);
  transition: background 0.2s, border-color 0.2s;
}
.dark-mode .topbar-back,
.dark-mode .topbar-secure {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow:
    inset -1px 1px 6px -1px rgba(255, 255, 255, 0.14),
    inset 0 1px 6px -2px rgba(255, 255, 255, 0.08);
}

.topbar-back {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  color: var(--text);
  text-decoration: none;
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}
.topbar-back:hover {
  background: rgba(0, 0, 0, 0.08);
  border-color: rgba(0, 0, 0, 0.18);
}
.dark-mode .topbar-back:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.3);
}
.topbar-back svg {
  width: 14px;
  height: 14px;
  display: block;
}
.topbar-secure {
  font-size: 12px;
  color: var(--text);
  font-weight: 500;
  justify-self: end;
}

/* ── Topbar (Liquid glass) ── */
.topbar {
  position: fixed;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 99;
  width: calc(100% - 24px);
  max-width: 1200px;
  border-radius: 100px;
  isolation: isolate;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(18px) saturate(160%);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow:
    inset -1.5px 1.5px 12px -2px rgba(255, 255, 255, 0.45),
    inset 5px 5px 3px -4px rgba(255, 255, 255, 0.3),
    inset -5px -5px 3px -5px rgba(255, 255, 255, 0.22),
    inset 0 1px 12px -5px rgba(255, 255, 255, 0.35),
    0 8px 32px rgba(15, 23, 42, 0.12),
    0 2px 6px rgba(15, 23, 42, 0.06);
  padding: 10px 18px;
  min-height: 56px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
}
.dark-mode .topbar {
  background: rgba(28, 26, 36, 0.55);
  border-color: rgba(255, 255, 255, 0.12);
  box-shadow:
    inset -1.5px 1.5px 12px -2px rgba(255, 255, 255, 0.18),
    inset 5px 5px 3px -4px rgba(255, 255, 255, 0.1),
    inset -5px -5px 3px -5px rgba(255, 255, 255, 0.08),
    inset 0 1px 12px -5px rgba(255, 255, 255, 0.12),
    0 8px 32px rgba(0, 0, 0, 0.45),
    0 2px 6px rgba(0, 0, 0, 0.25);
}
/* Offer page: progress-steps inside topbar needs more vertical space */
.topbar:has(.progress-steps) {
  padding: 14px 22px;
  min-height: 72px;
}
.topbar-logo { height: 24px; width: auto; display: block; }
.topbar-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  justify-self: center;
}
.topbar-nav-link {
  font-size: 13px;
  font-weight: 600;
  color: rgba(0, 0, 0, 0.7);
  text-decoration: none;
  padding: 7px 14px;
  border-radius: 100px;
  transition: background 0.15s, color 0.15s;
}
.topbar-nav-link:hover {
  color: var(--text);
  background: rgba(0, 0, 0, 0.08);
}
.dark-mode .topbar-nav-link {
  color: rgba(255, 255, 255, 0.78);
}
.dark-mode .topbar-nav-link:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.18);
}
@media (max-width: 720px) {
  .topbar-nav { display: none; }
}
.topbar-logo-dark { display: none; }
.dark-mode .topbar-logo-light { display: none; }
.dark-mode .topbar-logo-dark { display: block; }
.progress-steps {
  display: flex;
  align-items: center;
  height: 52px;
  justify-content: center;
}
.progress-step {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.72);
  transition: color 0.2s ease;
}
.progress-step.active {
  color: #fff;
  font-weight: 600;
}
.progress-step.done {
  color: rgba(255, 255, 255, 0.92);
}
.step-num {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.32);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.progress-step.active .step-num {
  background: #fff;
  color: var(--accent-purple);
  border-color: #fff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.2);
}
.progress-step.done .step-num {
  background: rgba(255, 255, 255, 0.85);
  color: var(--accent-purple);
  border-color: rgba(255, 255, 255, 0.85);
}
.progress-step.clickable {
  cursor: pointer;
}
.progress-step.clickable:hover {
  opacity: 0.85;
}
.step-divider {
  flex: 1;
  max-width: 60px;
  height: 1px;
  background: rgba(255, 255, 255, 0.28);
  margin: 0 12px;
}

/* ── Layout ── */
.wrap {
  position: relative;
  z-index: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 132px 24px 60px;
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
  align-items: start;
}
@media (max-width: 900px) {
  .wrap {
    grid-template-columns: 1fr;
    padding: 132px 16px 120px;
  }
  .right-col {
    order: -1;
    position: relative !important;
    top: 0 !important;
  }
}
.wrap.s3-active {
  grid-template-columns: 1fr;
  max-width: 760px;
}

/* ── Cards ── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 16px;
  transition: box-shadow 0.25s ease;
}
.card:hover {
  box-shadow: var(--shadow-md);
}
.card-header {
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 15px;
  letter-spacing: -0.02em;
}
.card-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

/* ── Loading bar (universal) ── */
@keyframes hh-loading-slide {
  0%   { left: -40%; width: 40%; }
  50%  { left: 30%;  width: 50%; }
  100% { left: 100%; width: 40%; }
}
.hh-loading-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(114, 67, 232, 0.12);
  z-index: 10000;
  overflow: hidden;
  pointer-events: none;
}
.hh-loading-bar::after {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: -40%;
  width: 40%;
  background: linear-gradient(90deg, rgba(114, 67, 232, 0.4), var(--accent-purple), rgba(114, 67, 232, 0.4));
  box-shadow: 0 0 12px var(--accent-purple);
  animation: hh-loading-slide 1.4s cubic-bezier(0.65, 0, 0.35, 1) infinite;
  border-radius: 2px;
}

/* ── Shimmer / Skeleton (universal) ── */
@keyframes hh-shimmer {
  0% { background-position: 180% 0; }
  100% { background-position: -80% 0; }
}
.sk {
  display: inline-block;
  border-radius: 6px;
  background: linear-gradient(90deg, rgba(114, 67, 232, 0.06) 0%, rgba(114, 67, 232, 0.18) 50%, rgba(114, 67, 232, 0.06) 100%);
  background-size: 200% 100%;
  animation: hh-shimmer 1.1s cubic-bezier(0.4, 0, 0.2, 1) infinite;
  vertical-align: middle;
  position: relative;
  overflow: hidden;
}
.dark-mode .sk {
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0%, rgba(255, 255, 255, 0.12) 50%, rgba(255, 255, 255, 0.04) 100%);
}
.sk-block { display: block; }

/* ── Universal Pill ── */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 9px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.6;
  white-space: nowrap;
}
.pill-icon { font-size: 12px; line-height: 1; }
.pill-neutral { background: var(--card-subtle); color: var(--muted); border: 1px solid var(--border); }
.pill-success { background: #dcfce7; color: #166534; }
.pill-warning { background: #fef3c7; color: #92400e; }
.pill-danger  { background: #fee2e2; color: #991b1b; }
.pill-accent  { background: var(--accent-light); color: var(--accent-purple); }
.pill-info    { background: #dbeafe; color: #1e40af; }
.pill-muted   { background: rgba(0, 0, 0, 0.06); color: rgba(0, 0, 0, 0.55); }

.dark-mode .pill-neutral { background: rgba(255, 255, 255, 0.06); color: rgba(255, 255, 255, 0.7); border-color: rgba(255, 255, 255, 0.12); }
.dark-mode .pill-success { background: rgba(22, 163, 74, 0.18); color: #4ade80; }
.dark-mode .pill-warning { background: rgba(251, 191, 36, 0.18); color: #fbbf24; }
.dark-mode .pill-danger  { background: rgba(220, 38, 38, 0.18); color: #fca5a5; }
.dark-mode .pill-accent  { background: rgba(114, 67, 232, 0.22); color: #c4b5fd; }
.dark-mode .pill-info    { background: rgba(59, 130, 246, 0.18); color: #93c5fd; }
.dark-mode .pill-muted   { background: rgba(255, 255, 255, 0.08); color: rgba(255, 255, 255, 0.65); }

/* ── Universal Status Badge (with leading dot) ── */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 100px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.status-badge-dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status-badge-neutral { background: #f3f4f6; color: #374151; }
.status-badge-success { background: #dcfce7; color: #166534; }
.status-badge-warning { background: #fef3c7; color: #92400e; }
.status-badge-danger  { background: #fee2e2; color: #991b1b; }
.status-badge-info    { background: #dbeafe; color: #1e40af; }
.status-badge-accent  { background: #ede9fe; color: #5b21b6; }

.dark-mode .status-badge-neutral { background: rgba(255, 255, 255, 0.06); color: rgba(255, 255, 255, 0.75); }
.dark-mode .status-badge-success { background: rgba(22, 163, 74, 0.18); color: #4ade80; }
.dark-mode .status-badge-warning { background: rgba(251, 191, 36, 0.18); color: #fbbf24; }
.dark-mode .status-badge-danger  { background: rgba(220, 38, 38, 0.18); color: #fca5a5; }
.dark-mode .status-badge-info    { background: rgba(59, 130, 246, 0.18); color: #93c5fd; }
.dark-mode .status-badge-accent  { background: rgba(114, 67, 232, 0.22); color: #c4b5fd; }

/* ── Leistungen ── */
.leistungen-section {
  padding: 16px 24px 16px;
}
.leistungen-section-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 10px;
}
.leistung-month-header {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 10px 0 6px;
  margin-top: 6px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.leistung-month-header:first-child {
  margin-top: 0;
  padding-top: 0;
}
.s3-leistung-month-header {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  padding: 12px 0 6px;
  margin-bottom: 4px;
  border-bottom: 1px solid var(--border);
}
.s3-leistung-month-header:first-child {
  padding-top: 0;
}
.acc-month-header {
  padding: 6px 20px 4px 28px;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  background: var(--card-subtle);
  border-bottom: 1px dashed var(--border);
}
.leistung-item {
  padding: 14px 16px;
  margin-bottom: 8px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  align-items: start;
  background: var(--card-subtle);
  transition:
    border-color 0.15s ease,
    background 0.15s ease;
}
.leistung-item:last-of-type {
  margin-bottom: 0;
}
.leistung-item:hover {
  background: white;
  border-color: var(--accent-purple);
}
.leistung-item-clickable {
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 16px;
}
.leistung-item-clickable > :first-child {
  flex: 1;
  min-width: 0;
}
.leistung-item-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex-shrink: 0;
}
.leistung-item-chevron {
  flex-shrink: 0;
  width: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  line-height: 1;
  color: var(--muted);
  transition: transform 0.15s, color 0.15s;
}
.leistung-item-clickable:hover .leistung-item-chevron {
  color: var(--accent-purple);
  transform: translateX(2px);
}
.dark-mode .leistung-item:hover { background: rgba(255, 255, 255, 0.04); border-color: var(--accent-purple); }
.empty-row-soft {
  padding: 14px 16px;
  margin-bottom: 0;
  font-size: 13px;
  color: var(--muted);
  font-style: italic;
  background: var(--card-subtle);
  border: 1px dashed var(--border);
  border-radius: 12px;
}
.leistung-name {
  font-weight: 600;
  font-size: 15px;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.chip {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 100px;
  background: var(--accent-light);
  color: var(--accent-purple);
  letter-spacing: 0.01em;
}
.leistung-meta {
  font-size: 13px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 2px;
}
.leistung-price {
  font-size: 17px;
  font-weight: 700;
  text-align: right;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.leistung-price-label {
  font-size: 11px;
  color: var(--muted);
  font-weight: 400;
  text-align: right;
  margin-top: 2px;
}

.total-row {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--card-subtle);
  border-top: 2px solid var(--border);
}
.total-label {
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
}
.total-amount {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.total-note {
  padding: 10px 24px;
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--border);
  background: var(--card-subtle);
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── Forms ── */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  padding: 20px 24px;
}
@media (max-width: 600px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
}
.field-label {
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}
.input,
textarea,
select {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background: white;
  font-family: var(--font-sans);
  font-size: 14px;
  color: var(--text);
  transition:
    border-color 0.15s ease,
    box-shadow 0.15s ease;
}
.input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--accent-purple);
  box-shadow: 0 0 0 3px rgba(114, 67, 232, 0.1);
}
.input::placeholder {
  color: #bababa;
}

/* ── AGB ── */
.agb-scroll {
  max-height: 280px;
  overflow-y: auto;
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.agb-scroll::-webkit-scrollbar {
  width: 4px;
}
.agb-scroll::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}
.agb-item {
  margin-bottom: 16px;
}
.agb-item:last-child {
  margin-bottom: 0;
}
.agb-item h4 {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 3px;
}
.agb-item p {
  font-size: 13px;
  color: var(--muted);
  line-height: 1.5;
}

.accept-row {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.accept-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-purple);
  margin-top: 1px;
  flex-shrink: 0;
  cursor: pointer;
}
.accept-row label {
  font-size: 14px;
  color: var(--muted);
  cursor: pointer;
  line-height: 1.5;
}
.accept-row label strong {
  color: var(--text);
}

/* ── Buttons ── */
.actions {
  padding: 16px 24px;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  border-top: 1px solid var(--border);
  background: var(--card-subtle);
}
.btn {
  appearance: none;
  border: none;
  cursor: pointer;
  padding: 12px 28px;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-weight: 700;
  font-size: 14px;
  background: var(--primary);
  color: white;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn:hover {
  background: var(--accent-purple);
  box-shadow: 0 4px 16px rgba(114, 67, 232, 0.3);
  transform: translateY(-1px);
}
.btn:active {
  transform: scale(0.98) translateY(0);
}
.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  pointer-events: none;
}
.btn-secondary {
  appearance: none;
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border);
  padding: 11px 24px;
  border-radius: 100px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn-secondary:hover {
  background: var(--card-subtle);
  border-color: #b0b0b0;
}

/* ── Animations ── */
@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }
  20% {
    transform: translateX(-6px);
  }
  40% {
    transform: translateX(6px);
  }
  60% {
    transform: translateX(-4px);
  }
  80% {
    transform: translateX(4px);
  }
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.slide-in {
  animation: slideIn 0.35s ease forwards;
}
.hidden {
  display: none !important;
}

/* ── Highlight Banner ── */
.highlight-banner {
  background: linear-gradient(135deg, var(--accent-purple), #5b21b6);
  color: white;
  padding: 16px 24px;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}
.highlight-banner-icon {
  font-size: 24px;
  flex-shrink: 0;
}
.highlight-banner-text h3 {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
}
.highlight-banner-text p {
  font-size: 13px;
  opacity: 0.8;
  line-height: 1.4;
}

/* ── Signature ── */
.signature-area {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  background: var(--card-subtle);
}
.signature-area p {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}
.signature-area strong {
  color: var(--text);
}

/* ── Sidebar ── */
.right-col {
  position: sticky;
  top: 120px;
}
.summary-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}
.summary-header {
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border);
}
.summary-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}
.brand-avatar {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 15px;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--border);
}
.brand-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.brand-name {
  font-weight: 700;
  font-size: 16px;
  letter-spacing: -0.02em;
}
.brand-sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 100px;
  background: #fef9c3;
  color: #854d0e;
  border: 1px solid #fde68a;
}
.status-badge .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #d97706;
}
.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 20px;
  font-size: 13px;
  border-bottom: 1px dashed var(--border);
}
.summary-row:last-child {
  border-bottom: none;
}
.summary-row .key {
  color: var(--muted);
}
.summary-row .val {
  font-weight: 500;
  text-align: right;
  max-width: 200px;
  word-break: break-word;
}

/* ── Sidebar Leistungen accordion ── */
.summary-row.accordion-trigger {
  cursor: pointer;
  user-select: none;
}
.summary-row.accordion-trigger:hover {
  background: var(--card-subtle);
}
.accordion-chevron {
  transition: transform 0.2s ease;
  flex-shrink: 0;
}
.accordion-chevron.open {
  transform: rotate(180deg);
}
.leistungen-accordion-body {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.25s ease;
}
.leistungen-accordion-body.open {
  max-height: 600px;
}
.leistungen-acc-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 8px 20px 8px 28px;
  font-size: 12px;
  gap: 8px;
  border-bottom: 1px dashed var(--border);
}
.leistungen-acc-item:last-child {
  border-bottom: none;
}
.leistungen-acc-item .acc-name {
  color: var(--text);
  font-weight: 500;
  flex: 1;
}
.leistungen-acc-item .acc-date {
  color: var(--muted);
  font-size: 11px;
  margin-top: 2px;
}
.leistungen-acc-item .acc-price {
  color: var(--text);
  font-weight: 600;
  white-space: nowrap;
}
.summary-total {
  padding: 16px 20px;
  background: var(--card-subtle);
  border-top: 2px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}
.summary-total .key {
  font-size: 13px;
  color: var(--muted);
  font-weight: 500;
}
.summary-total .val {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.03em;
}
.summary-cta {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
}
.summary-cta .btn {
  width: 100%;
  justify-content: center;
}
.trust-strip {
  padding: 14px 20px;
  background: var(--success-bg);
  border-top: 1px solid #bbf7d0;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #166534;
  font-weight: 500;
}

/* ── Mobile CTA ── */
.mobile-cta {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid var(--border);
  padding: 16px 24px;
  z-index: 90;
  box-shadow: 0 -8px 24px rgba(0, 0, 0, 0.08);
}
.mobile-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.mobile-cta .total-label {
  font-size: 12px;
  color: var(--muted);
}
.mobile-cta .total-amount {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.02em;
}
@media (max-width: 900px) {
  .mobile-cta {
    display: block;
  }
  .summary-cta {
    display: none;
  }
}

/* ── Spinner ── */
.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}
.spinner-dark {
  width: 14px;
  height: 14px;
  border: 2px solid #d1d5db;
  border-top-color: #6b7280;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
  flex-shrink: 0;
}

/* ── Address Modal ── */
.addr-modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(10, 10, 10, 0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.addr-modal-backdrop.open {
  display: flex;
}
.addr-modal-box {
  background: #fff;
  border-radius: 20px;
  max-width: 520px;
  width: 100%;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  animation: slideIn 0.3s ease;
}

/* ── Required star ── */
.req-star {
  color: #dc2626;
  font-weight: 700;
}

/* ── Dark mode ── */
.dark-mode {
  --card: rgba(255, 255, 255, 0.02);
  --card-subtle: rgba(255, 255, 255, 0.04);
  --border: rgba(242, 241, 255, 0.12);
  --text: #f2f1ff;
  --muted: rgba(242, 241, 255, 0.6);
  --primary: #f2f1ff;
  --primary-hover: #d0ceee;
  --accent-light: rgba(114, 67, 232, 0.18);
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
}
.dark-mode body {
  background: #0f0e12;
}
.dark-mode body::before {
  background:
    radial-gradient(
      1200px 700px at 20% -10%,
      rgba(114, 67, 232, 0.18) 0%,
      rgba(15, 14, 18, 0) 55%
    ),
    radial-gradient(
      900px 600px at 90% 10%,
      rgba(247, 59, 101, 0.12) 0%,
      rgba(15, 14, 18, 0) 55%
    );
}
.dark-mode .card,
.dark-mode .summary-card,
.dark-mode .s3-card {
  background: rgba(255, 255, 255, 0.02) !important;
}
.dark-mode .input {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  border-color: var(--border);
}
.dark-mode .input::placeholder {
  color: rgba(242, 241, 255, 0.35);
}
.dark-mode .input:focus {
  background: rgba(255, 255, 255, 0.06);
}
.dark-mode .s3-leistung-row:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--accent-purple);
}
.dark-mode .s3-total-bar {
  background: rgba(255, 255, 255, 0.04);
}
.dark-mode .addr-modal-box,
.dark-mode .addr-modal-box .addr-modal-box {
  background: #1a1820 !important;
}
.dark-mode .btn {
  background: var(--accent-purple);
  color: #fff;
}
.dark-mode .btn:hover {
  background: #5b30c2;
}
.dark-mode .btn-secondary {
  background: transparent;
  border-color: rgba(242, 241, 255, 0.2);
  color: var(--text);
}
.dark-mode .btn-secondary:hover {
  background: rgba(255, 255, 255, 0.06);
}
.dark-mode .auslagen-note {
  background: rgba(255, 255, 255, 0.04);
}
.dark-mode .auslagen-info-box {
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.10);
}
/* Leistungs-item hover */
.dark-mode .leistung-item:hover {
  background: rgba(255, 255, 255, 0.06);
}
.dark-mode .chip {
  background: rgba(114, 67, 232, 0.25);
}
/* AGB Modal */
.dark-mode .agb-modal-box {
  background: #1a1820;
}
.dark-mode .agb-item h4 {
  color: var(--text);
}
/* Sichere Übertragung */
.dark-mode .trust-strip {
  background: rgba(16, 185, 129, 0.08);
  border-color: rgba(16, 185, 129, 0.18);
  color: #34d399;
}
/* Mobile CTA */
.dark-mode .mobile-cta {
  background: #1a1820;
  border-color: rgba(242, 241, 255, 0.1);
}
.dark-mode .s3-save-btn {
  background: var(--accent-purple);
  color: white;
}
.dark-mode .s3-save-btn:hover {
  background: #5b30c2;
}
.dark-mode .s3-addr-feedback.ok,
.dark-mode .s3-inline-feedback.ok {
  background: rgba(21, 128, 61, 0.15);
  color: #86efac;
  border-color: rgba(21, 128, 61, 0.3);
}
.dark-mode .s3-addr-feedback.err,
.dark-mode .s3-inline-feedback.err {
  background: rgba(190, 18, 60, 0.15);
  color: #fca5a5;
  border-color: rgba(190, 18, 60, 0.3);
}

/* topbar-secure — base box already gets liquid-glass treatment above */
.topbar-secure {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
}
/* ── Theme Toggle ── */
.theme-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 22px;
  border-radius: 100px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
  flex-shrink: 0;
  color: var(--text);
}
.theme-toggle:hover {
  background: rgba(0, 0, 0, 0.08);
}
.dark-mode .theme-toggle:hover {
  background: rgba(255, 255, 255, 0.18);
}
.theme-toggle-icon {
  font-size: 15px;
  line-height: 1;
  transition: opacity 0.2s;
}

/* ── Language Switcher ── */
.lang-switcher {
  display: flex;
  align-items: center;
  gap: 1px;
  border-left: 1px solid rgba(0, 0, 0, 0.18);
  padding-left: 7px;
}
.dark-mode .lang-switcher {
  border-left-color: rgba(255, 255, 255, 0.22);
}
.lang-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: rgba(0, 0, 0, 0.6);
  font-size: 13px;
  font-weight: 600;
  padding: 4px 9px;
  border-radius: 20px;
  font-family: var(--font-sans);
  transition: all 0.15s ease;
  line-height: 1;
}
.lang-btn.active {
  color: var(--text);
  background: rgba(0, 0, 0, 0.1);
}
.lang-btn:hover:not(.active) {
  color: var(--text);
}
.dark-mode .lang-btn {
  color: rgba(255, 255, 255, 0.7);
}
.dark-mode .lang-btn.active {
  color: #fff;
  background: rgba(255, 255, 255, 0.22);
}
.dark-mode .lang-btn:hover:not(.active) {
  color: #fff;
}

/* ── AGB Modal ── */
.agb-modal-box {
  background: #fff;
  border-radius: 20px;
  max-width: 640px;
  width: 100%;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  animation: slideIn 0.3s ease;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
}
.agb-modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.agb-modal-body::-webkit-scrollbar {
  width: 4px;
}
.agb-modal-body::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

/* ── VAT section ── */
.vat-section {
  border-top: 1px solid var(--border);
  padding: 16px 24px;
}
.vat-toggle-row {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  margin: 0;
}
.vat-toggle-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-purple);
  flex-shrink: 0;
  cursor: pointer;
}
.vat-toggle-row span {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
}

/* ── Accept row in step 2 ── */
.accept-row-submit {
  padding: 16px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  gap: 16px;
  background: var(--card-subtle);
  justify-content: space-between;
}
.accept-row-submit input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--accent-purple);
  margin-top: 2px;
  flex-shrink: 0;
  cursor: pointer;
}
.accept-row-submit label {
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
  line-height: 1.55;
}
.accept-row-submit label strong {
  color: var(--text);
}
.accept-row-submit label a {
  color: var(--accent-purple);
  text-decoration: underline;
  cursor: pointer;
}

/* ── Auslagen note ── */
.auslagen-note {
  margin: 0 24px 16px;
  padding: 10px 14px;
  background: #f9f9fb;
  border: 1.5px dashed var(--border);
  border-radius: 10px;
  font-size: 13px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ── Instagram chip ── */
.chip-ig {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: linear-gradient(135deg, #f9ce34, #ee2a7b, #6228d7);
  color: #fff;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 9px 2px 5px;
  vertical-align: middle;
}
.chip-ig svg {
  flex-shrink: 0;
}

/* ── Auslagen section within card ── */
.auslagen-section {
    border-top: 1px solid var(--border);
    padding: 16px 24px 20px;
    display: flex;
    gap: 16px;
    flex-flow: column;
}
.auslagen-section-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 10px;
}
.auslagen-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  margin-bottom: 6px;
  font-size: 13px;
  color: var(--text);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  background: var(--card-subtle);
}
.auslagen-item:last-child {
  margin-bottom: 0;
}
.auslagen-item-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}

.auslagen-item-name {
  font-weight: 600;
  font-size: 13px;
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Info boxes for Auslagen/Reisekosten agreements */
.auslagen-info-box {
  margin: 0 24px;
  padding: 12px 14px;
  background: var(--card-subtle);
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--text);
}
.auslagen-info-box + .auslagen-info-box { margin-top: 8px; }
.auslagen-info-box-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--muted);
  margin-bottom: 5px;
}

/* ── Section mini-header (inside merged card) ── */
.section-mini-header {
  padding: 10px 24px 8px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 7px;
  border-top: 1px solid var(--border);
  background: var(--card-subtle);
}
.section-mini-icon {
  font-size: 14px;
}

/* ── Save data button ── */
.btn-save-data {
  appearance: none;
  background: none;
  border: 1.5px solid var(--border);
  border-radius: 100px;
  padding: 5px 12px;
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.15s ease;
}
.btn-save-data:hover {
  background: var(--card-subtle);
  border-color: #b0b0b0;
  color: var(--text);
}

/* ── Tooltip ── */
.tooltip-wrap {
  position: relative;
  display: inline-flex;
}
.tooltip-trigger {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--card-subtle);
  border: 1.5px solid var(--border);
  cursor: pointer;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  font-family: var(--font-sans);
  appearance: none;
}
.tooltip-box {
  display: none;
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  width: 260px;
  padding: 12px 14px;
  background: #1a1a1a;
  color: white;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.5;
  z-index: 9999;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
  font-weight: 400;
  text-transform: none;
  letter-spacing: 0;
}
/* Allow tooltip to overflow infoCard */
#infoCard {
  overflow: visible;
}
.tooltip-box::after {
  content: "";
  position: absolute;
  top: 100%;
  right: 10px;
  border: 5px solid transparent;
  border-top-color: #1a1a1a;
}
.tooltip-wrap:hover .tooltip-box {
  display: block;
}

/* ── Step 3 – Rich Summary ── */
.s3-card {
  overflow: hidden;
  padding: 0 !important;
}
.s3-success-header {
  background: linear-gradient(135deg, #16a34a 0%, #15803d 100%);
  color: #fff;
  padding: 28px 24px 22px;
  text-align: center;
}
.s3-success-icon {
  font-size: 36px;
  margin-bottom: 8px;
  line-height: 1;
}
.s3-success-title {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 6px;
}
.s3-success-sub {
  font-size: 13px;
  opacity: 0.85;
  margin-bottom: 4px;
}
.s3-success-by {
  font-size: 12px;
  opacity: 0.7;
  margin-top: 6px;
}
.s3-pdf-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 16px;
  padding: 10px 22px;
  border-radius: 100px;
  background: rgba(255,255,255,0.18);
  border: 1.5px solid rgba(255,255,255,0.35);
  color: #fff;
  font-family: inherit;
  font-weight: 700;
  font-size: 13px;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}
.s3-pdf-btn:hover {
  background: rgba(255,255,255,0.28);
  border-color: rgba(255,255,255,0.55);
}

.s3-brand-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  padding: 16px 24px;
}
.s3-brand-info {
  display: flex;
  align-items: center;
  gap: 12px;
}
.s3-brand-avatar {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--accent-purple);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
}
.s3-brand-avatar img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.s3-brand-name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
}
.s3-brand-sub {
  font-size: 12px;
  color: var(--muted);
}
.s3-meta-pills {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.s3-meta-pill {
  background: var(--card-subtle);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 7px 14px;
  text-align: center;
  min-width: 90px;
}
.s3-meta-pill-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 2px;
}
.s3-meta-pill-val {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

/* mini card-header for step 3 sections – mirrors .card-header but scaled down */
.s3-card-header {
  padding: 11px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 9px;
  font-weight: 700;
  font-size: 14px;
  color: var(--text);
}
.s3-card-header.s3-section-major {
  border-top: 2px solid var(--border);
  margin-top: 4px;
}
/* No double border: when card-header is directly followed by s3-section-major, drop card-header's border */
.card-header:has(+ .s3-card-header.s3-section-major) {
  border-bottom: none;
}
.s3-card-icon-mini {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}

.s3-leistungen {
  padding: 0 24px 16px;
}
.s3-leistung-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 12px 14px;
  margin-bottom: 8px;
  gap: 12px;
  background: var(--card-subtle);
  border: 1.5px solid var(--border);
  border-radius: 12px;
  transition:
    border-color 0.15s,
    background 0.15s;
}
.s3-leistung-row:last-child {
  margin-bottom: 0;
}
.s3-leistung-row:hover {
  background: white;
  border-color: var(--accent-purple);
}
.s3-leistung-info {
  flex: 1;
  min-width: 0;
}
.s3-leistung-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}
.s3-leistung-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.s3-leistung-chip {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 100px;
  background: var(--accent-light);
  color: var(--accent-purple);
  letter-spacing: 0.01em;
}
.s3-leistung-date {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 5px;
}
.s3-leistung-price {
  font-size: 16px;
  font-weight: 700;
  white-space: nowrap;
  color: var(--text);
  text-align: right;
}
.s3-leistung-price-label {
  font-size: 11px;
  color: var(--muted);
  font-weight: 400;
  text-align: right;
  margin-top: 2px;
}

.s3-total-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 24px;
  background: var(--card-subtle);
  border-top: 2px solid var(--border);
}
.s3-total-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
}
.s3-total-note {
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}
.s3-total-val {
  font-size: 18px;
  font-weight: 800;
  color: var(--text);
}

.s3-fields-wrap {
  padding: 4px 24px 20px;
}
.s3-sub-section {
  margin-top: 18px;
}
.s3-sub-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.s3-edit-btn {
  display: none !important;

  margin-left: auto;
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 11px;
  border-radius: 100px;
  border: 1.5px solid var(--accent-purple);
  background: transparent;
  color: var(--accent-purple);
  cursor: pointer;
  transition:
    background 0.15s,
    color 0.15s;
}
.s3-edit-btn:hover {
  background: var(--accent-purple);
  color: white;
}
.s3-fields-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
}
@media (max-width: 600px) {
  .s3-fields-grid {
    grid-template-columns: 1fr;
  }
}
.s3-field-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 4px;
}
.s3-field-val {
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  word-break: break-word;
  background: var(--card-subtle);
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 9px 13px;
  min-height: 38px;
}

/* ── Step 3 Edit Mode ── */
.s3-edit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 16px;
  margin-top: 8px;
}
@media (max-width: 600px) {
  .s3-edit-grid {
    grid-template-columns: 1fr;
  }
}
.s3-edit-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 4px;
  grid-column: 1/-1;
}
.s3-save-btn {
  font-size: 13px;
  font-weight: 600;
  padding: 8px 20px;
  border-radius: 8px;
  background: var(--primary);
  color: white;
  border: none;
  cursor: pointer;
  transition: background 0.15s;
}
.s3-save-btn:hover {
  background: var(--primary-hover);
}
.s3-save-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.s3-cancel-btn {
  font-size: 13px;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  border: 1.5px solid var(--border);
  cursor: pointer;
  transition:
    border-color 0.15s,
    color 0.15s;
}
.s3-cancel-btn:hover {
  border-color: var(--text);
  color: var(--text);
}
.s3-inline-feedback {
  font-size: 13px;
  padding: 8px 12px;
  border-radius: 8px;
  grid-column: 1/-1;
  display: none;
}
.s3-inline-feedback.ok {
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}
.s3-inline-feedback.err {
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
}

.s3-sub-section + .s3-sub-section {
  border-top: 1px dashed var(--border);
  padding-top: 16px;
  margin-top: 16px;
}

/* ── Step 3 Address Change Panel ── */

/* ── Toast ── */
.s3-toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: #1b1f2a;
  color: white;
  font-size: 13px;
  font-weight: 600;
  padding: 10px 22px;
  border-radius: 100px;
  opacity: 0;
  transition:
    opacity 0.3s ease,
    transform 0.3s ease;
  pointer-events: none;
  z-index: 9999;
}
.s3-toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.s3-footer-note {
  padding: 14px 24px;
  background: var(--card-subtle);
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}
.s3-agb-link {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 12px 24px;
  border-top: 1px solid var(--border);
  font-size: 13px;
  color: var(--muted);
  cursor: pointer;
  transition:
    color 0.15s,
    background 0.15s;
}
.s3-agb-link:hover {
  color: var(--accent-purple);
  background: var(--accent-light);
}

/* ── Secure Pill (fixed bottom-left) ── */
.secure-pill {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 95;
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.55);
  background: rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 100px;
  padding: 6px 12px;
  pointer-events: none;
}

.company-autocomplete {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  z-index: 220;
  display: none;
  background: var(--card);
  border: 1.5px solid var(--border);
  border-radius: 18px;
  box-shadow: var(--shadow-md);
  overflow-y: auto;
  overflow-x: hidden;
  max-height: 320px;
  overscroll-behavior: contain;
}

.company-autocomplete-item {
  width: 100%;
  text-align: left;
  border: none;
  border-bottom: 1px solid var(--border);
  
  cursor: pointer;
  padding: 14px 16px;
  transition:
    background 0.15s ease,
    border-color 0.15s ease;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.company-autocomplete-item{
  background: var(--card);
}

.dark-mode .company-autocomplete-item {
  background: #19171d;
}

.company-autocomplete-item:last-child {
  border-bottom: none;
}

.dark-mode .company-autocomplete-item:hover,
.dark-mode .company-autocomplete-item.active {
  background: rgb(114 67 232);
}

.company-autocomplete-item:hover,
.company-autocomplete-item.active {
  background: var(--accent-light);
}



.company-autocomplete-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.company-autocomplete-meta {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.4;
}

/* ── Mobile Responsiveness ── */
@media (max-width: 900px) {
  .topbar {
    padding: 0 16px;
  }
  .topbar .topbar-left .topbar-logo {
    height: 20px;
  }
  .secure-pill {
    display: none;
  }
  .dark-mode .mobile-cta {
    background: #1a1820;
  }
}
@media (max-width: 600px) {
  /* Progress: hide step labels, keep only numbers */
  .progress-step > span:not(.step-num) {
    display: none;
  }
  .step-divider {
    max-width: 24px;
    margin: 0 8px;
  }
  .topbar .topbar-left .topbar-logo {
    height: 18px;
  }
  /* Reduce top padding for smaller bar */
  .wrap {
    padding-top: 88px;
  }
  /* Cards */
  .card {
    border-radius: 14px;
    margin-bottom: 12px;
  }
  .card-header {
    padding: 14px 16px;
    font-size: 14px;
  }
  .leistungen-section {
    padding: 12px 16px;
  }
  .leistung-item {
    padding: 12px 14px;
  }
  .leistung-name {
    font-size: 14px;
  }
  .total-row {
    padding: 16px;
  }
  .grid-2 {
    padding: 14px 16px;
    gap: 10px;
  }
  /* Step 3 card */
  .s3-card {
    border-radius: 14px;
  }
  .s3-card-header {
    padding: 12px 16px;
  }
  .s3-fields-wrap {
    padding: 4px 16px 16px;
  }
  .s3-fields-grid {
    gap: 10px;
  }
  .s3-section-header {
    padding: 14px 16px;
  }
  .s3-leistungen {
    padding: 0 16px 16px;
  }
  .s3-total-bar {
    padding: 12px 16px;
  }
  .s3-agb-link {
    padding: 12px 16px;
  }
  .s3-footer-note {
    padding: 12px 16px;
  }
  /* Success header */
  .s3-success-header {
    padding: 20px 16px;
  }
  /* Modals: bottom sheet on mobile */
  .addr-modal-backdrop {
    align-items: flex-end;
  }
  .addr-modal-box,
  .agb-modal-box {
    border-radius: 20px 20px 0 0;
    max-height: 92vh;
    width: 100%;
    max-width: 100%;
  }
  /* Submit modal */
  .submit-modal-box {
    border-radius: 20px 20px 0 0;
    max-height: 92vh;
    width: 100%;
    max-width: 100%;
    margin: 0;
  }
  .addr-modal-backdrop.open {
    align-items: flex-end;
  }
  /* Mobile CTA safe area */
  .mobile-cta {
    padding-bottom: max(16px, env(safe-area-inset-bottom));
  }
  /* Banner */
  .banner-card {
    margin-bottom: 12px;
  }
}
@media (max-width: 768px) {
  .topbar-secure {
    gap: 4px;
    padding: 3px 6px;
  }
  .theme-toggle {
    width: 26px;
    height: 19px;
  }
  .theme-toggle-icon {
    font-size: 12px;
  }
  .lang-switcher {
    gap: 0;
    padding-left: 5px;
  }
  .lang-btn {
    padding: 3px 7px;
    font-size: 11px;
  }
}
@media (max-width: 400px) {
  .topbar .topbar-left .topbar-logo {
    display: none;
  }
  .topbar-secure {
    gap: 3px;
    padding: 2px 4px;
  }
  .theme-toggle {
    width: 22px;
    height: 16px;
  }
  .theme-toggle-icon {
    font-size: 10px;
  }
  .lang-switcher {
    gap: 0;
    padding-left: 4px;
  }
  .lang-btn {
    padding: 2px 5px;
    font-size: 10px;
  }
  .wrap {
    padding-left: 10px;
    padding-right: 10px;
  }
}
