/* Assistente AI — pagina wizard v1.x-ai-setup-full-page */
#page-ai-setup { max-width: 920px; margin: 0 auto; padding-bottom: calc(6.5rem + env(safe-area-inset-bottom, 0px)); }
.ais-page { display: flex; flex-direction: column; gap: 1.25rem; }
.ais-hero {
    background: linear-gradient(135deg, #eff6ff 0%, #f0fdf4 55%, #faf5ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: 20px;
    padding: 1.35rem 1.5rem;
}
.ais-hero-title { font-size: 1.65rem; font-weight: 900; color: #0f172a; margin: 0 0 .35rem; line-height: 1.2; }
.ais-hero-sub { color: #475569; font-size: 1rem; margin: 0 0 1rem; line-height: 1.45; }
.ais-reassure {
    background: #fff;
    border: 1px solid #bbf7d0;
    border-radius: 14px;
    padding: .85rem 1rem;
    font-size: .9rem;
    color: #166534;
    margin-bottom: 1rem;
    line-height: 1.45;
}
.ais-status-bar { margin-bottom: 1rem; }
.ais-status-inner {
    display: flex; flex-direction: column; gap: .35rem;
    background: #fff; border: 1px solid #e2e8f0; border-radius: 12px; padding: .65rem .85rem;
}
.ais-status-badge { font-size: .8125rem; font-weight: 700; color: #1e40af; }
.ais-status-badge.is-ai { color: #6d28d9; }
.ais-status-badge.is-rule { color: #0f766e; }
.ais-status-meta { font-size: .75rem; color: #64748b; }
.ais-hero-ctas { display: flex; flex-wrap: wrap; gap: .55rem; }
.ais-hero-ctas .btn { min-height: 48px; font-weight: 700; border-radius: 12px; }
.ais-section-title { font-size: 1.125rem; font-weight: 800; color: #0f172a; margin: 0 0 .65rem; }
.ais-section-sub { font-size: .875rem; color: #64748b; margin: -.35rem 0 .75rem; }
.ais-how-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem; }
@media (min-width: 768px) { .ais-how-grid { grid-template-columns: repeat(4, 1fr); } }
.ais-how-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1rem;
    min-height: 120px;
}
.ais-how-num {
    width: 32px; height: 32px; border-radius: 50%; background: #dbeafe; color: #1d4ed8;
    font-weight: 800; font-size: .875rem; display: flex; align-items: center; justify-content: center; margin-bottom: .5rem;
}
.ais-how-card h3 { font-size: .9375rem; font-weight: 800; color: #0f172a; margin: 0 0 .35rem; }
.ais-how-card p { font-size: .8125rem; color: #64748b; margin: 0; line-height: 1.4; }
.ais-tip-box {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    padding: 1rem 1.1rem;
    font-size: .875rem;
    color: #475569;
    line-height: 1.5;
}
.ais-tip-box strong { color: #0f172a; display: block; margin-bottom: .35rem; }
.ais-example-cards { display: flex; flex-direction: column; gap: .65rem; }
.ais-example-card {
    text-align: left;
    background: #fff;
    border: 2px solid #e2e8f0;
    border-radius: 14px;
    padding: .85rem 1rem;
    cursor: pointer;
    transition: border-color .15s, box-shadow .15s;
    min-height: 44px;
}
.ais-example-card:hover, .ais-example-card:focus { border-color: #3b82f6; box-shadow: 0 4px 16px rgba(59,130,246,.12); outline: none; }
.ais-example-card-title { font-weight: 800; font-size: .9375rem; color: #0f172a; margin-bottom: .25rem; }
.ais-example-card-text { font-size: .8125rem; color: #64748b; line-height: 1.4; margin: 0; }
.ais-wizard-panel {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 18px;
    padding: 1.15rem 1.25rem;
    box-shadow: 0 4px 20px rgba(15,23,42,.04);
}
.ais-progress { display: flex; gap: .5rem; justify-content: center; margin-bottom: 1.15rem; flex-wrap: wrap; }
.ais-progress-dot { width: 10px; height: 10px; border-radius: 50%; background: #cbd5e1; transition: transform .15s, background .15s; }
.ais-progress-dot.is-active { background: #3b82f6; transform: scale(1.25); }
.ais-progress-dot.is-done { background: #22c55e; }
.ais-describe-label { font-weight: 800; font-size: 1rem; color: #0f172a; margin-bottom: .5rem; display: block; }
#aisInputText {
    min-height: 160px;
    font-size: 1rem;
    line-height: 1.45;
    border-radius: 14px;
    border: 2px solid #e2e8f0;
    padding: .85rem 1rem;
}
#aisInputText:focus { border-color: #3b82f6; box-shadow: 0 0 0 3px rgba(59,130,246,.15); }
.ais-hints { margin-top: .75rem; font-size: .8125rem; color: #64748b; line-height: 1.5; }
.ais-hints ul { margin: .35rem 0 0; padding-left: 1.15rem; }
.ais-voice-block {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 1rem 1.1rem;
    margin-top: 1rem;
    transition: box-shadow .25s, border-color .25s;
}
.ais-voice-block.is-recording {
    border-color: #fecaca;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, .12);
}
.ais-voice-block h3 { font-size: 1rem; font-weight: 800; margin: 0 0 .35rem; color: #0f172a; }
.ais-voice-block p { font-size: .8125rem; color: #64748b; margin: 0 0 .75rem; line-height: 1.4; }
.ais-voice-row { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.ais-voice-row .btn { min-height: 48px; font-weight: 700; border-radius: 12px; }
.ais-voice-row .btn:disabled { opacity: .45; cursor: not-allowed; }
.ais-voice-row .btn.ais-voice-recording {
    animation: aisVoicePulse 1.4s ease-out infinite;
}
@keyframes aisVoicePulse {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, .35); }
    70% { box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
    100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}
.ais-voice-status { font-size: .875rem; color: #64748b; min-height: 1.4em; flex: 1 1 100%; margin-top: .5rem; display: block; }
.ais-voice-status.is-listening { color: #b91c1c; font-weight: 700; }
.ais-voice-status.is-transcribing { color: #4338ca; font-weight: 700; }
.ais-voice-status.is-done { color: #15803d; font-weight: 600; }
.ais-voice-status.is-error { color: #b91c1c; }
.ais-step-section { scroll-margin-top: 1rem; }
.ais-step-section.is-hidden { display: none !important; }
.ais-questions-intro { font-weight: 700; color: #0f172a; margin-bottom: .85rem; }
.ais-question-item { margin-bottom: .85rem; }
.ais-question-label {
    display: block;
    font-weight: 700;
    font-size: .9375rem;
    color: #0f172a;
    margin-bottom: .4rem;
    line-height: 1.45;
}
#aisQuestions .form-control { border-radius: 12px; min-height: 44px; }
.ais-questions-actions { margin-top: 1rem; }
.ais-questions-actions .btn { min-height: 48px; font-weight: 800; border-radius: 12px; width: 100%; max-width: 280px; }
.ais-summary-block { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 12px; padding: .85rem 1rem; margin-bottom: .65rem; }
.ais-summary-block h6 { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: #64748b; margin-bottom: .35rem; font-weight: 800; }
#aisMapPreview { width: 100%; height: auto; min-height: 200px; max-height: 360px; border: 1px solid #e2e8f0; border-radius: 14px; background: #fff; }
.ais-map-hint { font-size: .8125rem; color: #64748b; margin-top: .5rem; }
.ais-replace-confirm { background: #fef2f2; border: 1px solid #fecaca; border-radius: 14px; padding: .85rem 1rem; margin-top: .75rem; }
.ais-presets-grid { display: flex; flex-direction: column; gap: .65rem; }
.ais-preset-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: .85rem 1rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: .65rem;
}
.ais-preset-card-main { flex: 1; min-width: 0; }
.ais-preset-card-name { font-weight: 800; color: #0f172a; font-size: .9375rem; }
.ais-preset-card-meta { font-size: .75rem; color: #64748b; margin-top: .15rem; }
.ais-preset-card-actions { display: flex; flex-wrap: wrap; gap: .35rem; }
.ais-preset-card-actions .btn { min-height: 40px; font-weight: 700; font-size: .8125rem; }
.ais-page-footer {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 1040;
    background: #fff;
    border-top: 1px solid #e2e8f0;
    padding: .75rem 1rem calc(.75rem + env(safe-area-inset-bottom, 0px));
    display: none;
    box-shadow: 0 -8px 24px rgba(15,23,42,.08);
}
#page-ai-setup.is-active-page .ais-page-footer { display: flex; }
.ais-page-footer-inner { max-width: 920px; margin: 0 auto; width: 100%; display: flex; gap: .55rem; justify-content: flex-end; }
.ais-page-footer .btn { min-height: 48px; font-weight: 800; border-radius: 12px; flex: 1; max-width: 200px; }
.ais-page-footer .btn-primary { max-width: none; flex: 1.5; }
.ais-premium-card {
    background: linear-gradient(135deg, #eff6ff 0%, #f0fdf4 100%);
    border: 1px solid #bfdbfe;
    border-radius: 16px;
    padding: 1.1rem 1.25rem;
    margin-bottom: 1rem;
}
.ais-premium-card h5 { font-weight: 700; margin-bottom: .35rem; color: #0f172a; }
.ais-premium-card p { color: #475569; margin-bottom: .75rem; font-size: .95rem; }
.sidebar .nav-link-ais .nav-link-sub { display: block; font-size: .68rem; color: #64748b; font-weight: 500; margin-top: .1rem; line-height: 1.2; }
.sidebar a.active.nav-link-ais .nav-link-sub { color: #93c5fd; }
@media (max-width: 767.98px) {
    .ais-hero-title { font-size: 1.35rem; }
    .ais-how-grid { grid-template-columns: 1fr; }
    .ais-hero-ctas .btn { width: 100%; }
    .ais-voice-row .btn { flex: 1 1 calc(50% - .25rem); }
    .ais-page-footer .btn { max-width: none; }
    #aisInputText { min-height: 140px; font-size: 16px; }
    #aisMapPreview { min-height: 160px; max-height: 240px; }
}
.ais-wizard-overlay .ais-wizard-modal { max-width: 720px; width: calc(100% - 1.5rem); max-height: min(92vh, 880px); overflow: auto; }
.ais-wiz-progress { display: flex; gap: .45rem; justify-content: center; margin: .75rem 0 1rem; }
.ais-wiz-step-dot { width: 10px; height: 10px; border-radius: 50%; background: #cbd5e1; }
.ais-wiz-step-dot.is-active { background: #2563eb; transform: scale(1.2); }
.ais-wiz-step-dot.is-done { background: #22c55e; }
.ais-wiz-room-card { border: 1px solid #e2e8f0; border-radius: 12px; padding: .85rem; margin-bottom: .65rem; background: #f8fafc; }
.ais-wiz-room-card-title { font-weight: 800; font-size: .9rem; margin-bottom: .5rem; color: #0f172a; }
.ais-wiz-preview-svg { width: 100%; min-height: 220px; max-height: 320px; border: 1px dashed #cbd5e1; border-radius: 12px; background: #fff; }
.ais-wiz-summary { background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 12px; padding: 1rem; }
.ais-wiz-footer { position: sticky; bottom: 0; background: #fff; }
