.signup-shell { max-width: 1100px; margin: 0 auto; padding: 1.25rem 1rem 2.5rem; }
.signup-steps { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.75rem; }
.signup-steps .step {
    display: inline-flex; align-items: center; gap: 0.5rem;
    padding: 0.4rem 0.85rem; border-radius: 999px; font-size: 0.82rem;
    background: #e2e8f0; color: #475569; font-weight: 500;
}
.signup-steps .step-num {
    width: 1.35rem; height: 1.35rem; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 0.75rem; background: rgba(255,255,255,.65);
}
.signup-steps .step.active { background: #4f46e5; color: #fff; }
.signup-steps .step.active .step-num { background: rgba(255,255,255,.25); color: #fff; }
.signup-steps .step.done { background: #dcfce7; color: #166534; }

.signup-layout { display: grid; grid-template-columns: 1fr min(340px, 100%); gap: 1.5rem; align-items: start; }
@media (max-width: 900px) {
    .signup-layout { grid-template-columns: 1fr; }
    .order-cart { order: -1; }
    .signup-submit-mobile { display: block !important; margin-top: 0.75rem; }
    .order-cart .cart-actions { display: none; }
}
.signup-submit-mobile { display: none; margin-top: 0.5rem; }
.signup-header h2 { margin: 0 0 0.35rem; font-size: 1.5rem; }
.signup-header .subtitle { color: #64748b; margin: 0 0 1.25rem; max-width: 42rem; }

.billing-cycle-bar {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem;
    padding: 1rem 1.15rem; margin-bottom: 1.25rem;
    background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 100%);
    border: 1px solid #e2e8f0; border-radius: 14px;
}
.billing-cycle-label { font-weight: 600; color: #334155; font-size: 0.95rem; }
.billing-toggle { display: inline-flex; background: #fff; border-radius: 12px; padding: 4px; box-shadow: 0 1px 3px rgba(15,23,42,.08); }
.cycle-btn {
    border: 0; background: transparent; padding: 0.55rem 1.1rem; border-radius: 9px;
    cursor: pointer; font-size: 0.9rem; color: #64748b; display: inline-flex; align-items: center; gap: 0.35rem;
}
.cycle-btn.active { background: #4f46e5; color: #fff; font-weight: 600; box-shadow: 0 4px 12px rgba(79,70,229,.35); }
.cycle-badge { font-size: 0.65rem; text-transform: uppercase; letter-spacing: .04em; background: rgba(255,255,255,.2); padding: 0.15rem 0.4rem; border-radius: 4px; }
.cycle-btn:not(.active) .cycle-badge { background: #dcfce7; color: #166534; }

.plan-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.plan-card { position: relative; display: block; }
.plan-card input { position: absolute; opacity: 0; pointer-events: none; }
.plan-card-inner {
    border: 2px solid #e2e8f0; border-radius: 16px; padding: 1.25rem 1.35rem; height: 100%;
    cursor: pointer; transition: border-color .2s, box-shadow .2s, transform .15s; background: #fff;
}
.plan-card input:checked + .plan-card-inner {
    border-color: #4f46e5; box-shadow: 0 12px 32px rgba(79,70,229,.12); transform: translateY(-2px);
}
.plan-card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.5rem; }
.plan-card h3 { margin: 0; font-size: 1.1rem; }
.plan-save { font-size: 0.7rem; font-weight: 600; color: #059669; background: #ecfdf5; padding: 0.2rem 0.45rem; border-radius: 6px; white-space: nowrap; }
.plan-desc { color: #64748b; font-size: 0.88rem; margin: 0.5rem 0 0.75rem; min-height: 2.5em; }
.plan-price { font-size: 1.4rem; margin: 0.5rem 0 0.85rem; color: #0f172a; }
.plan-limits { margin: 0; padding: 0; list-style: none; color: #475569; font-size: 0.88rem; }
.plan-limits li { display: flex; align-items: center; gap: 0.5rem; padding: 0.25rem 0; }
.plan-icon { width: 1.15rem; height: 1.15rem; flex-shrink: 0; color: #6366f1; }
.plan-icon.inline { vertical-align: -0.2em; margin-right: 0.35rem; }

.order-cart { position: sticky; top: 1rem; }
.order-cart-inner {
    background: #fff; border: 1px solid #e2e8f0; border-radius: 16px; padding: 1.35rem;
    box-shadow: 0 8px 24px rgba(15,23,42,.06);
}
.order-cart-inner h3 { margin: 0 0 0.5rem; font-size: 1.05rem; }
.cart-hint { font-size: 0.82rem; color: #64748b; margin: 0 0 1rem; line-height: 1.45; }
.cart-lines { margin: 0 0 1rem; }
.cart-lines > div { display: flex; justify-content: space-between; gap: 1rem; padding: 0.4rem 0; font-size: 0.92rem; }
.cart-lines dt { margin: 0; color: #64748b; font-weight: 500; }
.cart-lines dd { margin: 0; font-weight: 600; text-align: right; }
.cart-total { border-top: 1px solid #e2e8f0; margin-top: 0.35rem; padding-top: 0.75rem !important; font-size: 1.05rem !important; }
.cart-trust { margin: 0 0 1.15rem; padding-left: 1.1rem; font-size: 0.8rem; color: #64748b; line-height: 1.5; }
.cart-product { display: flex; gap: 0.85rem; align-items: flex-start; margin-bottom: 1rem; padding-bottom: 1rem; border-bottom: 1px solid #f1f5f9; }
.cart-product-icon {
    width: 2.5rem; height: 2.5rem; border-radius: 10px; background: #eef2ff; color: #4f46e5;
    display: flex; align-items: center; justify-content: center;
}
.cart-product-icon svg { width: 1.35rem; height: 1.35rem; }
.cart-footnote { font-size: 0.75rem; color: #94a3b8; margin: 0 0 1rem; }
.btn-block { display: block; width: 100%; text-align: center; }
.plan-trial-badge {
    font-size: 0.7rem; font-weight: 600; color: #1d4ed8; background: #eff6ff;
    padding: 0.25rem 0.5rem; border-radius: 6px; white-space: nowrap; border: 1px solid #bfdbfe;
}
.cart-trial-row { color: #1d4ed8; }
.cart-trial-row dd { font-weight: 600; }
.cart-actions { display: flex; flex-direction: column; gap: 0.5rem; }
.cart-actions .btn-lg { margin-top: 0; }

.section-title { display: flex; align-items: center; font-size: 1rem; margin: 1.5rem 0 0.75rem; }
.bank-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 0.75rem; margin-bottom: 0.5rem; }
.bank-card { border: 1px solid #e2e8f0; border-radius: 14px; padding: 1rem 1.1rem; background: #fafafa; }
.bank-card .iban { display: block; margin-top: 0.5rem; font-size: 0.85rem; word-break: break-all; background: #fff; padding: 0.35rem 0.5rem; border-radius: 6px; }
.bank-meta { color: #64748b; font-size: 0.88rem; margin-top: 0.25rem; }
.payment-notify-form { background: #fff; border: 1px solid #e2e8f0; border-radius: 14px; padding: 1.25rem 1.35rem; margin-top: 0.5rem; }
.btn-lg { width: 100%; padding: 0.85rem; margin-top: 0.65rem; }
.pending-flow { text-align: center; padding: 3rem 1rem; }
.pending-icon { font-size: 3rem; margin-bottom: 1rem; }

/* —— Billing / payment-required (logged-in tenant) —— */
body:has(.payment-shell) {
    background: linear-gradient(180deg, #f1f5f9 0%, #eef2ff 45%, #f8fafc 100%);
    min-height: 100vh;
}
.payment-shell { min-height: 100vh; }
.payment-topbar {
    display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
    max-width: 1100px; margin: 0 auto; padding: 1rem 1rem 0.5rem;
}
.payment-brand { display: inline-flex; align-items: center; }
.payment-brand img { display: block; height: auto; max-height: 28px; }
.payment-topbar-actions { display: flex; align-items: center; gap: 0.75rem; flex-wrap: wrap; }
.payment-topbar-hint { font-size: 0.82rem; color: #64748b; }
.btn-sm { padding: 0.45rem 0.85rem; font-size: 0.82rem; }

.payment-page { padding-top: 0.75rem; }
.payment-status {
    display: flex; align-items: flex-start; gap: 1rem;
    padding: 1.15rem 1.25rem; border-radius: 16px; margin-bottom: 1.25rem;
    border: 1px solid transparent;
}
.payment-status h1 { margin: 0 0 0.35rem; font-size: 1.35rem; line-height: 1.25; }
.payment-status p { margin: 0; color: #475569; font-size: 0.92rem; line-height: 1.55; max-width: 44rem; }
.payment-status-icon {
    width: 2.75rem; height: 2.75rem; border-radius: 12px; flex-shrink: 0;
    display: flex; align-items: center; justify-content: center;
}
.payment-status-icon svg { width: 1.45rem; height: 1.45rem; }
.payment-status--info {
    background: linear-gradient(135deg, #eff6ff 0%, #eef2ff 100%);
    border-color: #bfdbfe;
}
.payment-status--info .payment-status-icon { background: #dbeafe; color: #1d4ed8; }
.payment-status--warn {
    background: linear-gradient(135deg, #fff7ed 0%, #fef3c7 100%);
    border-color: #fcd34d;
}
.payment-status--warn .payment-status-icon { background: #fde68a; color: #b45309; }
.payment-status--trial {
    background: linear-gradient(135deg, #ecfdf5 0%, #eff6ff 100%);
    border-color: #a7f3d0;
}
.payment-status--trial .payment-status-icon { background: #d1fae5; color: #047857; }

.payment-continue-trial {
    display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
    margin-bottom: 1rem; padding: 0.85rem 1rem; border-radius: 12px;
    background: #fff; border: 1px dashed #a7f3d0;
}
.payment-continue-trial p { margin: 0; color: #047857; font-size: 0.88rem; font-weight: 500; }

.payment-steps {
    display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.5rem;
}
.payment-step {
    display: inline-flex; align-items: center; gap: 0.45rem;
    padding: 0.38rem 0.8rem; border-radius: 999px; font-size: 0.8rem;
    background: #e2e8f0; color: #64748b; font-weight: 500;
}
.payment-step-num {
    width: 1.25rem; height: 1.25rem; border-radius: 50%;
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 0.72rem; background: rgba(255,255,255,.7);
}
.payment-step.active { background: #4f46e5; color: #fff; }
.payment-step.active .payment-step-num { background: rgba(255,255,255,.22); color: #fff; }

.payment-layout { margin-top: 0; }
.payment-section { margin-bottom: 0.25rem; }
.payment-section-lead {
    margin: -0.35rem 0 1rem; color: #64748b; font-size: 0.88rem; line-height: 1.55; max-width: 42rem;
}
.payment-alert { margin-bottom: 1rem; }
.payment-bank-card { background: #fff; }
.payment-bank-head { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; }
.payment-iban-row {
    display: flex; align-items: center; gap: 0.5rem; margin-top: 0.65rem; flex-wrap: wrap;
}
.payment-iban-row .iban { flex: 1; margin-top: 0; min-width: 0; }
.payment-copy { flex-shrink: 0; }
.payment-form-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 0.85rem 1rem;
}
.payment-cart .cart-trust {
    margin: 0; padding-left: 1.1rem; font-size: 0.8rem; color: #64748b; line-height: 1.55;
}

@media (max-width: 900px) {
    .payment-topbar { padding-top: 0.75rem; }
    .payment-topbar-hint { width: 100%; order: 3; }
    .payment-status { flex-direction: column; }
}
