/**
 * /start page only — force light contrast so headings never blend with background.
 * Loaded AFTER setup-wizard.css. Does not change the in-admin wizard.
 */
.aispap-start-wizard-page,
.aispap-start-wizard-page[data-theme],
html.aispap-start-html,
html.aispap-start-html[data-theme],
html.aispap-start-html[data-theme="dark"],
html.aispap-start-html[data-theme="light"] {
    --sw-blue: #0052FF !important;
    --sw-blue-hover: #0041CC !important;
    --sw-bg: #f8fafc !important;
    --sw-card: #ffffff !important;
    --sw-border: #e2e8f0 !important;
    --sw-border-hover: #cbd5e1 !important;
    --sw-text: #0f172a !important;
    --sw-muted: #475569 !important;
    --sw-light: #f1f5f9 !important;
    --sw-red: #ef4444 !important;
    --sw-green: #00c853 !important;
    --clr-bg: #f8fafc !important;
    --bg-page: #f8fafc !important;
    --clr-text: #0f172a !important;
    --clr-muted: #475569 !important;
    --clr-border: #e2e8f0 !important;
    --clr-card: #ffffff !important;
    --clr-input-bg: #ffffff !important;
    --clr-surface-alt: #f1f5f9 !important;
    --clr-accent: #0052FF !important;
    --clr-primary: #0052FF !important;
    --text-primary: #0f172a !important;
    --text-secondary: #475569 !important;
    --bg-subtle: #f1f5f9 !important;
    --bg-surface: #ffffff !important;
    color-scheme: light !important;
}

/* Kill dark-theme token remap on the start page overlay */
html[data-theme="dark"] .aispap-start-wizard-page .setup-wizard-overlay,
html[data-theme="dark"] .aispap-start-wizard-page .setup-wizard-dialog-overlay,
[data-theme="dark"] .aispap-start-wizard-page .setup-wizard-overlay,
[data-theme="dark"] .aispap-start-wizard-page .setup-wizard-dialog-overlay,
.aispap-start-wizard-page .setup-wizard-overlay,
.aispap-start-wizard-page .setup-wizard-dialog-overlay {
    --sw-bg: #f8fafc !important;
    --sw-card: #ffffff !important;
    --sw-border: #e2e8f0 !important;
    --sw-border-hover: #cbd5e1 !important;
    --sw-text: #0f172a !important;
    --sw-muted: #475569 !important;
    --sw-light: #f1f5f9 !important;
    background: #f8fafc !important;
    color: #0f172a !important;
}

html.aispap-start-html,
body.aispap-start-wizard-page {
    margin: 0 !important;
    padding: 0 !important;
    min-height: 100% !important;
    background: #f8fafc !important;
    color: #0f172a !important;
    font-family: Inter, system-ui, sans-serif !important;
}

.aispap-start-wizard-page .setup-wizard-overlay {
    position: fixed !important;
    inset: 0 !important;
}

/* Headings & body copy — never white on light */
.aispap-start-wizard-page .setup-wizard-overlay h1,
.aispap-start-wizard-page .setup-wizard-overlay h2,
.aispap-start-wizard-page .setup-wizard-overlay h3,
.aispap-start-wizard-page .setup-wizard-overlay h4,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-step h2,
.aispap-start-wizard-page .setup-wizard-overlay .setup-wizard-welcome-title,
.aispap-start-wizard-page .setup-wizard-overlay .setup-wizard-logo,
.aispap-start-wizard-page .setup-wizard-overlay .setup-wizard-logo span,
.aispap-start-wizard-page .setup-wizard-overlay .goal-content h3,
.aispap-start-wizard-page .setup-wizard-overlay .channel-header h3,
.aispap-start-wizard-page .setup-wizard-overlay .ds-section-title,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-tariff-card h4,
.aispap-start-wizard-page .setup-wizard-overlay .wt-price,
.aispap-start-wizard-page .setup-wizard-overlay #wizardTariffOptions > h4,
.aispap-start-wizard-page .setup-wizard-overlay #wizardSuccessView h2,
.aispap-start-wizard-page .setup-wizard-overlay .summary-box,
.aispap-start-wizard-page .setup-wizard-overlay .summary-line,
.aispap-start-wizard-page .setup-wizard-overlay .summary-line strong {
    color: #0f172a !important;
}

.aispap-start-wizard-page .setup-wizard-overlay p,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-step > p,
.aispap-start-wizard-page .setup-wizard-overlay .ds-section-desc,
.aispap-start-wizard-page .setup-wizard-overlay .wt-features li,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-field-hint,
.aispap-start-wizard-page .setup-wizard-overlay .setup-wizard-field-label,
.aispap-start-wizard-page .setup-wizard-overlay .consent-text,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-consent__text,
.aispap-start-wizard-page .setup-wizard-overlay .summary-line span,
.aispap-start-wizard-page .setup-wizard-overlay #wizardSuccessView p,
.aispap-start-wizard-page .setup-wizard-overlay .goal-content p {
    color: #475569 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay a {
    color: #0052FF !important;
}

/* Cards / surfaces stay light */
.aispap-start-wizard-page .setup-wizard-overlay .goal-content,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-tariff-card,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-volume-card,
.aispap-start-wizard-page .setup-wizard-overlay .summary-box,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-passport-card,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-action-card,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-lead-type-card,
.aispap-start-wizard-page .setup-wizard-overlay #wizardTariffOptions,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-tariff-roles,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-tariff-addons {
    background: #ffffff !important;
    color: #0f172a !important;
    border-color: #e2e8f0 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .goal-card input:checked + .goal-content,
.aispap-start-wizard-page .setup-wizard-overlay .wizard-tariff-card.selected {
    border-color: #0052FF !important;
    background: #ffffff !important;
}

/* Inputs */
.aispap-start-wizard-page .setup-wizard-overlay .input-wrapper {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .input-wrapper .input,
.aispap-start-wizard-page .setup-wizard-overlay input.input,
.aispap-start-wizard-page .setup-wizard-overlay textarea.input,
.aispap-start-wizard-page .setup-wizard-overlay select,
.aispap-start-wizard-page .setup-wizard-overlay .smart-select-native {
    color: #0f172a !important;
    -webkit-text-fill-color: #0f172a !important;
    caret-color: #0f172a !important;
    opacity: 1 !important;
    background: transparent !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .input-wrapper .label,
.aispap-start-wizard-page .setup-wizard-overlay .label {
    color: #64748b !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .input-wrapper:focus-within .label,
.aispap-start-wizard-page .setup-wizard-overlay .input-wrapper .input:not(:placeholder-shown) + .label {
    color: #0052FF !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .smart-select-wrapper {
    color: #0f172a !important;
    background: transparent !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .smart-select-custom {
    background: #ffffff !important;
    border: 1px solid #e2e8f0 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .smart-option {
    color: #0f172a !important;
    background: #ffffff !important;
}

/* Progress: incomplete steps dark number on light; active/completed keep contrast */
.aispap-start-wizard-page .setup-wizard-overlay .progress-step:not(.active):not(.completed):not(.skipped):not(.partial) {
    background: #f1f5f9 !important;
    border-color: #e2e8f0 !important;
    color: #475569 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .progress-step.partial {
    color: #0f172a !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .progress-step.active,
.aispap-start-wizard-page .setup-wizard-overlay .progress-step.completed {
    color: #ffffff !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .progress-step--finish:not(.active):not(.completed) {
    color: #475569 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .progress-step--finish.active,
.aispap-start-wizard-page .setup-wizard-overlay .progress-step--finish.completed {
    color: #ffffff !important;
}

/* Primary buttons: white text on blue is OK */
.aispap-start-wizard-page .setup-wizard-overlay .wizard-btn-primary {
    color: #ffffff !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .wizard-btn-secondary {
    color: #0f172a !important;
    background: #ffffff !important;
    border-color: #e2e8f0 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .modal-close {
    color: #64748b !important;
}

/* /start: no exit via close — progress still autosaves */
.aispap-start-wizard-page #setupWizardCloseBtn {
    display: none !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .wizard-step-eyebrow {
    background: #eef2ff !important;
    color: #475569 !important;
}

.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView:not([hidden]) {
    text-align: center !important;
}

.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView h2 {
    color: #0f172a !important;
}

.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView p,
.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView .wizard-success-delay,
.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView .wizard-success-payhint {
    color: #475569 !important;
}

.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView .wizard-success-lead {
    color: #0f172a !important;
}

.aispap-start-wizard-page #wizard-step-11 #wizardSuccessView .wizard-success-survey .setup-wizard-field-label {
    color: #0f172a !important;
}

.aispap-start-wizard-page #wizard-step-11 #wizardSummaryPaymentView {
    display: none !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .wizard-check__text {
    color: #0f172a;
}

.aispap-start-wizard-page .setup-wizard-overlay .wizard-check__box {
    background: #ffffff !important;
    border-color: #cbd5e1 !important;
}

.aispap-start-wizard-page .setup-wizard-overlay .wizard-check__input:checked + .wizard-check__box {
    background: #0052FF !important;
    border-color: #0052FF !important;
}

/* Avoid flash of step 1 before bootstrap restores progress */
.aispap-start-wizard-page #setupWizardModal.setup-wizard-overlay:not(.is-ready) .setup-wizard-content {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}
.aispap-start-wizard-page #setupWizardModal.setup-wizard-overlay.is-ready .setup-wizard-content {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transition: opacity 0.35s ease;
}

.aispap-start-wizard-page #wizard-step-stroke .wizard-stroke-title {
    margin: 0 0 8px;
    font-size: clamp(1.35rem, 3vw, 1.75rem);
    font-weight: 700;
    color: #0f172a !important;
}

.aispap-start-wizard-page #wizard-step-stroke .wizard-stroke-lead {
    margin: 0 0 12px;
    color: #475569 !important;
}

.aispap-start-wizard-page #wizard-step-stroke .wizard-stroke-inline-host {
    min-height: 360px;
    margin: 8px 0 16px;
    border: 1px solid var(--sw-border, #e2e8f0);
    border-radius: 16px;
    overflow: hidden;
    background: #fff;
}

.aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline {
    position: relative;
    inset: auto;
    z-index: 1;
    min-height: 360px;
    height: 100%;
    background: transparent;
}

.aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline .widget-id-stroke-screen__header {
    display: none;
}

.aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline .widget-id-stroke-screen__stage {
    min-height: 280px;
}

.aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline .widget-id-stroke-screen__percent {
    font-size: clamp(3rem, 16vw, 6rem);
}

@media (max-width: 780px) {
    html.aispap-start-html,
    body.aispap-start-wizard-page {
        min-height: 100dvh !important;
        overflow: hidden !important;
    }

    .aispap-start-wizard-page .setup-wizard-overlay {
        height: 100dvh !important;
        max-height: 100dvh !important;
    }

    .aispap-start-wizard-page .setup-wizard-overlay .setup-wizard-welcome__art {
        display: none !important;
    }

    .aispap-start-wizard-page #wizard-step-stroke .wizard-stroke-title {
        font-size: 1.35rem;
    }

    .aispap-start-wizard-page #wizard-step-stroke .wizard-stroke-lead {
        font-size: 0.95rem;
        margin-bottom: 8px;
    }

    .aispap-start-wizard-page #wizard-step-stroke .wizard-stroke-inline-host,
    .aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline {
        min-height: 220px;
    }

    .aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline .widget-id-stroke-screen__stage {
        min-height: 200px;
    }

    .aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline .widget-id-stroke-screen__percent {
        font-size: clamp(2.2rem, 18vw, 3.6rem);
    }

    .aispap-start-wizard-page #widgetIdStrokeModal.widget-id-stroke-screen--inline .widget-id-stroke-screen__footer {
        padding: 8px 8px 4px;
    }
}
