/* 🎯 Onboarding Wizard — full-screen modal with RADIM brand */

.ow-overlay {
    position: fixed;
    inset: 0;
    background: color-mix(in srgb, var(--radim-primary-deep) 72%, transparent);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 9800;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.25s ease-out;
}
.ow-overlay.ow-visible { opacity: 1; }

.ow-panel {
    background: #fff;
    border-radius: 24px;
    max-width: 640px;
    width: 100%;
    max-height: 92vh;
    overflow-y: auto;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    transform: scale(0.96) translateY(12px);
    transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.ow-overlay.ow-visible .ow-panel {
    transform: scale(1) translateY(0);
}

/* ═══ Header ═══ */
.ow-header {
    padding: 20px 28px 16px;
    border-bottom: 1px solid #edf2f7;
    background: linear-gradient(180deg, #fff 0%, #f7fafa 100%);
    border-radius: 24px 24px 0 0;
}

.ow-header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.ow-brand {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: Georgia, serif;
    font-size: 1.1rem;
    color: #1a4a44;
}
.ow-brand-mark { font-size: 1.3rem; }

.ow-skip {
    background: transparent;
    border: none;
    color: #718096;
    cursor: pointer;
    font-size: 0.88rem;
    padding: 6px 10px;
    border-radius: 8px;
    transition: background 0.15s;
}
.ow-skip:hover { background: #edf2f7; color: #2d3748; }

/* Progress dots */
.ow-progress {
    display: flex;
    align-items: center;
    gap: 4px;
}
.ow-dot {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
    transition: transform 0.2s;
}
.ow-dot > span {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #edf2f7;
    color: #a0aec0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.92rem;
    transition: all 0.2s;
}
.ow-dot small {
    font-size: 0.7rem;
    color: #a0aec0;
    letter-spacing: 0.02em;
}
.ow-dot-done > span {
    background: #48bb78;
    color: #fff;
}
.ow-dot-done small { color: #48bb78; font-weight: 600; }
.ow-dot-active > span {
    background: var(--radim-primary);
    color: #fff;
    transform: scale(1.15);
    box-shadow: 0 4px 12px color-mix(in srgb, var(--radim-primary) 40%, transparent);
}
.ow-dot-active small { color: var(--radim-primary); font-weight: 700; }
.ow-dot-line {
    flex: 1;
    height: 2px;
    background: #edf2f7;
    margin: 0 2px;
    margin-bottom: 14px;
}

/* ═══ Body ═══ */
.ow-body {
    padding: 24px 28px 20px;
    flex: 1;
}

.ow-step-icon {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: color-mix(in srgb, var(--radim-primary) 12%, transparent);
    color: var(--radim-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.3rem;
    margin-bottom: 16px;
}

.ow-body h1 {
    font-family: Georgia, serif;
    font-size: 1.8rem;
    color: #1a4a44;
    margin: 0 0 10px;
    line-height: 1.25;
}

.ow-lead {
    color: #4a5568;
    font-size: 1.02rem;
    line-height: 1.6;
    margin: 0 0 20px;
}

/* Forms */
.ow-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 20px;
}
.ow-form label {
    display: block;
    font-weight: 600;
    color: #2d3748;
    font-size: 0.92rem;
}
.ow-form input:not([type="checkbox"]),
.ow-form select,
.ow-form textarea {
    width: 100%;
    padding: 12px 14px;
    font-family: inherit;
    font-size: 1rem;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    background: #fff;
    color: #2d3748;
    margin-top: 6px;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.ow-form input:focus,
.ow-form select:focus,
.ow-form textarea:focus {
    outline: none;
    border-color: var(--radim-primary);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--radim-primary) 15%, transparent);
}

.ow-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
@media (max-width: 520px) {
    .ow-row { grid-template-columns: 1fr; }
}

.ow-check {
    display: flex !important;
    align-items: center;
    gap: 10px;
    font-weight: 400 !important;
    cursor: pointer;
    padding: 8px 12px;
    border-radius: 8px;
    transition: background 0.12s;
}
.ow-check:hover { background: #f7fafa; }
.ow-check input[type="checkbox"] {
    width: auto !important;
    margin: 0 !important;
}

.ow-hint {
    background: color-mix(in srgb, var(--radim-primary) 8%, transparent);
    border-left: 3px solid var(--radim-primary);
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 0.88rem;
    color: #2d6b65;
    margin: 16px 0 0;
    line-height: 1.5;
}

.ow-small-feedback {
    min-height: 24px;
    font-size: 0.88rem;
    padding: 4px 0;
}

.ow-list {
    list-style: none;
    padding: 0;
    margin: 0 0 16px;
}
.ow-list li {
    padding: 10px 0;
    border-bottom: 1px solid #edf2f7;
    color: #4a5568;
    line-height: 1.5;
}
.ow-list li:last-child { border-bottom: none; }

/* Festive preview */
.ow-preview {
    background: linear-gradient(135deg, color-mix(in srgb, var(--radim-primary) 12%, #fff) 0%, color-mix(in srgb, var(--radim-primary) 6%, #fff) 100%);
    border-radius: 14px;
    padding: 18px 20px;
    font-family: Georgia, serif;
    font-size: 1.1rem;
    color: #1a4a44;
    line-height: 1.4;
    margin: 20px 0;
    border: 1.5px solid color-mix(in srgb, var(--radim-primary) 25%, transparent);
    min-height: 60px;
}

/* SOS preview illustration */
.ow-sos-preview {
    margin: 20px 0 24px;
    display: flex;
    justify-content: center;
}
.ow-sos-demo { width: 100%; max-width: 220px; }
.ow-sos-phone {
    background: linear-gradient(160deg, #2d3748 0%, #1a202c 100%);
    border-radius: 28px;
    padding: 8px;
    aspect-ratio: 9 / 16;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    margin-bottom: 10px;
}
.ow-sos-phone-inner {
    background: linear-gradient(180deg, #fff 0%, #f7fafa 100%);
    border-radius: 22px;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 20px;
    position: relative;
}
.ow-sos-phone-text {
    color: #a0aec0;
    font-size: 0.8rem;
    position: absolute;
    top: 14px;
}
.ow-sos-btn-demo {
    width: 90px;
    height: 90px;
    border-radius: 50%;
    background: #e53e3e;
    color: #fff;
    font-size: 2.6rem;
    display: grid;
    place-items: center;
    box-shadow: 0 12px 30px rgba(229, 62, 62, 0.45);
}
.ow-sos-btn-demo.pulse {
    animation: ow-sos-pulse 2.2s ease-in-out infinite;
}
@keyframes ow-sos-pulse {
    0%, 100% { box-shadow: 0 12px 30px rgba(229, 62, 62, 0.45), 0 0 0 0 rgba(229, 62, 62, 0.5); }
    50%      { box-shadow: 0 12px 30px rgba(229, 62, 62, 0.6),  0 0 0 22px rgba(229, 62, 62, 0); }
}

/* Actions */
.ow-actions {
    margin-top: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.ow-actions-row {
    flex-direction: row;
    flex-wrap: wrap;
}

.ow-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 14px 22px;
    border-radius: 12px;
    font-family: inherit;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    border: 1.5px solid transparent;
    transition: all 0.18s;
    min-height: 48px;
}
.ow-btn-primary {
    background: var(--radim-primary);
    color: #fff;
}
.ow-btn-primary:hover {
    background: var(--radim-primary-deep);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px color-mix(in srgb, var(--radim-primary) 30%, transparent);
}
.ow-btn-ghost {
    background: transparent;
    color: #2d3748;
    border-color: #e2e8f0;
}
.ow-btn-ghost:hover {
    border-color: var(--radim-primary);
    color: var(--radim-primary);
}
.ow-btn-text {
    background: transparent;
    color: #a0aec0;
    border: none;
    padding: 8px 12px;
    font-weight: 500;
    min-height: auto;
}
.ow-btn-text:hover { color: #4a5568; }
.ow-btn-big {
    padding: 18px 32px;
    font-size: 1.1rem;
}

/* Footer */
.ow-footer {
    padding: 16px 28px 20px;
    border-top: 1px solid #edf2f7;
    background: #f7fafa;
    border-radius: 0 0 24px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}
.ow-footer-right { display: flex; gap: 8px; }

/* ═══ Finale ═══ */
.ow-finale {
    padding: 60px 40px 48px;
    text-align: center;
}
.ow-finale-icon {
    font-size: 4.5rem;
    margin-bottom: 16px;
    animation: ow-finale-pop 0.7s ease-out;
}
@keyframes ow-finale-pop {
    0% { transform: scale(0) rotate(-20deg); opacity: 0; }
    60% { transform: scale(1.15) rotate(0); opacity: 1; }
    100% { transform: scale(1); }
}
.ow-finale h1 {
    font-family: Georgia, serif;
    color: #1a4a44;
    font-size: 2rem;
    margin: 0 0 14px;
}
.ow-finale .ow-lead {
    font-size: 1.08rem;
    margin-bottom: 28px;
}

/* Mobile tweaks */
@media (max-width: 520px) {
    .ow-overlay { padding: 0; }
    .ow-panel {
        border-radius: 0;
        max-width: 100%;
        max-height: 100vh;
        height: 100vh;
    }
    .ow-header { padding: 16px 18px 14px; border-radius: 0; }
    .ow-body { padding: 18px 20px; }
    .ow-footer { padding: 14px 18px 18px; border-radius: 0; }
    .ow-body h1 { font-size: 1.5rem; }
    .ow-dot small { display: none; }
    .ow-finale { padding: 40px 24px; }
}
