/* Bank-QR-Generator (geteilt) — CSS abgeleitet von qr-rechnung-erstellen.html,
   alle Selektoren mit .bqg gescoped (keine Kollision mit dem Seiten-CSS der Bankseiten).
   Variablen-Fallbacks stammen aus dem :root der Money Page. */
.bqg {
  --bg-body: #f8fafc;
  --bg-hover: #f1f5f9;
  --bg-surface: #ffffff;
  --border-color: #e2e8f0;
  --ease-elastic: cubic-bezier(0.34, 1.56, 0.64, 1);
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --primary-light: #e0e7ff;
  --radius-full: 9999px;
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-xl: 24px;
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
  --shadow-xl: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
  --success: #10b981;
  --success-bg: #d1fae5;
  --text-muted: #5c6978;
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --transition-base: 0.2s ease;
}
@media (prefers-color-scheme: dark) {
  .bqg {
    --bg-body: #0b1120;
    --bg-hover: #334155;
    --bg-surface: #1e293b;
    --border-color: #334155;
    --primary: #818cf8;
    --primary-hover: #a5b4fc;
    --primary-light: rgba(99, 102, 241, 0.2);
    --text-muted: #94a3b8;
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
  }
}

/* Selbstversorgend in beiden Modi: explizite Farben aus den gescopten Variablen
   (nicht vom Seiten-CSS erben — Bankseiten stylen h3/p/label anders als die Money Page) */
.bqg .generator-section { background: transparent; }
.bqg h2, .bqg h3 { color: var(--text-primary); }
.bqg .section-header p, .bqg .form-section-header p, .bqg label { color: var(--text-secondary); }
.bqg .form-hint, .bqg .form-disclaimer { color: var(--text-muted); }
.bqg input, .bqg textarea { color: var(--text-primary); background: var(--bg-surface); border-color: var(--border-color); }
.bqg input::placeholder, .bqg textarea::placeholder { color: var(--text-muted); }
.bqg .currency-prefix, .bqg .amount-currency { color: var(--text-muted); }

.bqg .bqg-hint { font-size: 0.85rem; margin-top: 6px; min-height: 1.2em; display: block; }
.bqg .bqg-hint-ok { color: #059669; }
.bqg .bqg-hint-warn { color: #b45309; }
@media (prefers-color-scheme: dark) {
  .bqg .bqg-hint-ok { color: #34d399; }
  .bqg .bqg-hint-warn { color: #fbbf24; }
}
.bqg .btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      gap: 0.5rem;
      padding: 0.75rem 1.25rem;
      border-radius: var(--radius-md);
      font-size: 0.9375rem;
      font-weight: 600;
      text-decoration: none;
      cursor: pointer;
      border: none;
      transition: all var(--transition-base);
    }
.bqg .btn-primary {
      background: var(--primary);
      color: white;
      box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
    }
.bqg .btn-primary:hover {
      background: var(--primary-hover);
      transform: translateY(-2px);
      box-shadow: 0 4px 16px rgba(99, 102, 241, 0.4);
    }
.bqg .btn-secondary {
      background: var(--bg-surface);
      color: var(--text-primary);
      border: 1px solid var(--border-color);
    }
.bqg .btn-secondary:hover {
      border-color: var(--primary);
      color: var(--primary);
    }
.bqg .btn-ghost {
      background: transparent;
      color: var(--text-secondary);
      padding: 0.5rem 1rem;
    }
.bqg .btn-ghost:hover {
      background: var(--bg-hover);
      color: var(--text-primary);
    }
.bqg .btn-large {
      padding: 1rem 2rem;
      font-size: 1rem;
      border-radius: var(--radius-lg);
    }
.bqg .btn-full { width: 100%; }
.bqg .btn-glow { box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4); }
.bqg .btn-glow:hover { box-shadow: 0 6px 30px rgba(99, 102, 241, 0.5); }
.bqg .card {
      background: var(--bg-surface);
      border: 1px solid var(--border-color);
      border-radius: var(--radius-xl);
      box-shadow: var(--shadow-md);
    }
.bqg .generator-section {
      padding: 4rem 0;
    }
.bqg .section-header {
      text-align: center;
      margin-bottom: 3rem;
    }
.bqg .section-header h2 {
      font-size: 2rem;
      font-weight: 700;
      margin-bottom: 0.5rem;
    }
.bqg .section-header p {
      color: var(--text-secondary);
    }
.bqg .generator-wrapper {
      display: grid;
      gap: 2rem;
    }
@media (min-width: 1024px) {
.bqg .generator-wrapper {
        grid-template-columns: 1fr 400px;
      }
}
.bqg .generator-form {
      padding: 2rem;
    }
.bqg .form-section {
      margin-bottom: 2rem;
      padding-bottom: 2rem;
      border-bottom: 1px solid var(--border-color);
    }
.bqg .form-section:last-of-type {
      border-bottom: none;
      margin-bottom: 0;
      padding-bottom: 0;
    }
.bqg .form-section-header {
      display: flex;
      align-items: flex-start;
      gap: 1rem;
      margin-bottom: 1.5rem;
    }
.bqg .form-section-icon {
      width: 44px;
      height: 44px;
      background: var(--primary-light);
      color: var(--primary);
      border-radius: var(--radius-md);
      display: flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
    }
.bqg .form-section-icon.debtor {
      background: #dbeafe;
      color: #2563eb;
    }
.bqg .form-section-icon.amount {
      background: #d1fae5;
      color: #059669;
    }
.bqg .form-section-header h3 {
      font-size: 1.125rem;
      font-weight: 600;
      margin-bottom: 0.25rem;
    }
.bqg .form-section-header p {
      font-size: 0.875rem;
      color: var(--text-muted);
    }
.bqg .form-grid {
      display: grid;
      gap: 1rem;
    }
@media (min-width: 640px) {
.bqg .form-grid {
        grid-template-columns: repeat(2, 1fr);
      }
.bqg .form-group.full-width {
        grid-column: span 2;
      }
}
.bqg .form-group label {
      display: block;
      font-size: 0.875rem;
      font-weight: 500;
      color: var(--text-primary);
      margin-bottom: 0.5rem;
    }
.bqg .form-group input {
      width: 100%;
      padding: 0.75rem 1rem;
      background: var(--bg-body);
      border: 1px solid var(--border-color);
      border-radius: var(--radius-md);
      font-size: 1rem;
      font-family: inherit;
      color: var(--text-primary);
      transition: all var(--transition-base);
    }
.bqg .form-group input:focus {
      outline: none;
      border-color: var(--primary);
      background: var(--bg-surface);
      box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
    }
.bqg .form-group input::placeholder {
      color: var(--text-muted);
    }
.bqg .form-hint {
      display: block;
      font-size: 0.75rem;
      color: var(--text-muted);
      margin-top: 0.375rem;
    }
.bqg .form-actions {
      margin-top: 2rem;
    }
.bqg .form-disclaimer {
      display: flex;
      align-items: center;
      justify-content: center;
      gap: 0.5rem;
      margin-top: 1rem;
      font-size: 0.8125rem;
      color: var(--text-muted);
    }
.bqg .form-disclaimer svg {
      flex-shrink: 0;
    }
.bqg .generator-preview {
      position: sticky;
      top: 6rem;
      height: fit-content;
    }
.bqg .preview-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      padding: 1rem 1.5rem;
      border-bottom: 1px solid var(--border-color);
    }
.bqg .preview-header h3 {
      font-size: 1rem;
      font-weight: 600;
    }
.bqg .preview-badge {
      font-size: 0.75rem;
      font-weight: 500;
      padding: 0.25rem 0.625rem;
      background: var(--success-bg);
      color: #065f46;
      border-radius: var(--radius-full);
    }
.bqg .preview-content {
      padding: 2rem;
      min-height: 400px;
      display: flex;
      align-items: center;
      justify-content: center;
    }
.bqg .qr-preview-placeholder {
      text-align: center;
      color: var(--text-muted);
    }
.bqg .qr-placeholder-icon {
      width: 80px;
      height: 80px;
      margin: 0 auto 1rem;
      background: var(--bg-hover);
      border-radius: var(--radius-lg);
      display: flex;
      align-items: center;
      justify-content: center;
    }
.bqg .qr-placeholder-icon svg {
      opacity: 0.5;
    }
.bqg .qr-preview-placeholder p {
      font-size: 0.875rem;
      line-height: 1.5;
    }
.bqg .cta-card .btn-primary {
      background: white;
      color: var(--primary);
    }
.bqg .cta-card .btn-primary:hover {
      background: #f8fafc;
      transform: translateY(-2px);
    }
.bqg .cta-card .btn-secondary {
      background: transparent;
      color: white;
      border-color: rgba(255, 255, 255, 0.3);
    }
.bqg .cta-card .btn-secondary:hover {
      background: rgba(255, 255, 255, 0.1);
      border-color: rgba(255, 255, 255, 0.5);
    }
.bqg .floating-card.card-1 { top: 20%; left: 10%; animation-delay: 0s; }
.bqg .floating-card.card-2 { top: 60%; right: 15%; animation-delay: 2s; }
.bqg .floating-card.card-3 { bottom: 20%; left: 20%; animation-delay: 4s; }
@media (max-width: 768px) {
.bqg .nav-actions .btn-primary {
        font-size: 0.75rem;
        padding: 0.5rem 0.75rem;
        white-space: nowrap;
      }
.bqg .nav-actions .btn-primary svg {
        display: none;
      }
.bqg .generator-form {
        padding: 1.25rem;
      }
.bqg .form-section-header {
        flex-direction: column;
        gap: 0.75rem;
      }
.bqg .generator-preview {
        display: none;
      }
}
@media (max-width: 640px) {
.bqg .hero-cta .btn {
        width: 100%;
      }
.bqg .section-header h2 {
        font-size: 1.5rem;
      }
}
.bqg .success-modal-overlay {
      position: fixed;
      inset: 0;
      background: rgba(0, 0, 0, 0.6);
      backdrop-filter: blur(8px);
      z-index: 9999;
      display: flex;
      align-items: center;
      justify-content: center;
      padding: 1.5rem;
      opacity: 0;
      visibility: hidden;
      transition: all 0.3s ease;
    }
.bqg .success-modal-overlay.active {
      opacity: 1;
      visibility: visible;
    }
.bqg .success-modal {
      background: var(--bg-surface);
      border-radius: var(--radius-xl);
      max-width: 400px;
      width: 100%;
      max-height: 90vh;
      overflow-y: auto;
      transform: translateY(20px) scale(0.95);
      transition: transform 0.3s var(--ease-elastic);
      box-shadow: var(--shadow-xl);
    }
@media (max-width: 480px) {
.bqg .success-modal {
        max-width: calc(100% - 1.5rem);
        margin: 0.75rem;
      }
.bqg .success-modal-header {
        padding: 1rem;
      }
.bqg .success-modal-header h3 {
        font-size: 1.125rem;
        margin-bottom: 0.25rem;
      }
.bqg .success-modal-header p {
        font-size: 0.8125rem;
      }
.bqg .success-modal-body {
        padding: 0.625rem 1rem;
      }
.bqg .upgrade-intro {
        font-size: 0.8125rem;
        margin-bottom: 0.5rem;
      }
.bqg .upgrade-list li {
        font-size: 0.8125rem;
      }
.bqg .success-modal-footer {
        padding: 0.625rem 1rem 1rem;
        gap: 0.375rem;
      }
.bqg .success-modal-footer .btn-primary {
        padding: 0.625rem 1rem;
        font-size: 0.875rem;
      }
.bqg .success-modal-footer .btn-ghost {
        padding: 0.5rem;
        font-size: 0.75rem;
      }
.bqg .success-icon {
        width: 40px;
        height: 40px;
        margin-bottom: 0.5rem;
      }
.bqg .success-icon svg {
        width: 20px;
        height: 20px;
      }
}
.bqg .success-modal-overlay.active .success-modal {
      transform: translateY(0) scale(1);
    }
.bqg .success-modal-header {
      background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
      padding: 2rem;
      text-align: center;
      color: white;
    }
.bqg .success-icon {
      width: 64px;
      height: 64px;
      background: rgba(255,255,255,0.2);
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
      margin: 0 auto 1rem;
      animation: successPop 0.5s var(--ease-elastic);
    }
.bqg .success-modal-header h3 {
      font-size: 1.5rem;
      font-weight: 700;
      margin-bottom: 0.5rem;
    }
.bqg .success-modal-header p {
      opacity: 0.9;
      font-size: 0.9375rem;
    }
.bqg .success-modal-body {
      padding: 1rem 1.5rem;
    }
.bqg .upgrade-intro {
      font-size: 0.875rem;
      color: var(--text-secondary);
      margin-bottom: 0.75rem;
    }
.bqg .upgrade-list {
      list-style: none;
      padding: 0;
      margin: 0;
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
    }
.bqg .upgrade-list li {
      font-size: 0.875rem;
      color: var(--text-secondary);
      padding-left: 1.25rem;
      position: relative;
    }
.bqg .upgrade-list li::before {
      content: '✓';
      position: absolute;
      left: 0;
      color: var(--success);
      font-weight: 600;
    }
.bqg .upgrade-list strong {
      color: var(--text-primary);
    }
.bqg .success-modal-footer {
      padding: 0.75rem 1.5rem 1.5rem;
      display: flex;
      flex-direction: column;
      gap: 0.5rem;
    }
.bqg .success-modal-footer .btn-primary {
      width: 100%;
    }
.bqg .success-modal-footer .btn-ghost {
      width: 100%;
      text-align: center;
    }
.bqg .legal-modal-footer .btn {
      padding: 0.5rem 1.5rem;
    }
