:root {
  --purple-950: #1e0b3d;
  --purple-900: #2b1051;
  --purple-800: #3f1678;
  --purple-700: #5b21b6;
  --purple-600: #7435d7;
  --violet-500: #a855f7;
  --lilac-300: #d7b7fb;
  --lilac-100: #f1e8fd;
  --lilac-50: #faf7ff;
  --ink: #21162e;
  --muted: #746d7d;
  --line: #e9e3ef;
  --surface: #ffffff;
  --canvas: #f7f6f9;
  --green: #14805e;
  --green-soft: #e8f7f1;
  --coral: #db5c53;
  --coral-soft: #fff0ed;
  --amber: #9a6700;
  --amber-soft: #fff6df;
  --red: #b42318;
  --red-soft: #fff0ee;
  --shadow-sm: 0 1px 2px rgba(38, 19, 56, .04), 0 8px 24px rgba(38, 19, 56, .045);
  --shadow-lg: 0 24px 70px rgba(46, 22, 72, .18);
  --radius-sm: 14px;
  --radius: 20px;
  --radius-lg: 28px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-width: 320px; background: var(--canvas); scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--canvas); font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; font-size: 16px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
button, input, select { font: inherit; }
button { color: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid rgba(168, 85, 247, .28); outline-offset: 2px; }
[hidden] { display: none !important; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 248px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; height: 100vh; padding: 26px 18px 22px; background: var(--surface); border-right: 1px solid var(--line); display: flex; flex-direction: column; z-index: 20; }
.brand { display: flex; align-items: center; gap: 12px; padding: 0 10px 26px; }
.brand-avatar { width: 46px; height: 46px; flex: 0 0 auto; border-radius: 15px; overflow: hidden; background: var(--purple-700); box-shadow: 0 8px 20px rgba(91, 33, 182, .2); }
.brand-avatar img { width: 62px; height: 62px; object-fit: cover; object-position: center 12%; transform: translate(-8px, -5px) scale(1.15); }
.brand-copy { min-width: 0; display: grid; }
.brand-name { width: fit-content; position: relative; color: var(--purple-950); font-size: 26px; line-height: 1; letter-spacing: -.9px; font-weight: 850; }
.brand-name span { color: var(--violet-500); font-size: 13px; position: absolute; top: -4px; right: -13px; }
.brand-copy small { margin-top: 5px; color: var(--muted); font-size: 12px; white-space: nowrap; }
.side-nav { display: grid; gap: 7px; }
.nav-item { width: 100%; min-height: 48px; border: 0; border-radius: 14px; background: transparent; display: flex; align-items: center; gap: 13px; padding: 0 14px; color: #655d6d; font-size: 14px; font-weight: 700; text-align: left; cursor: pointer; transition: background .18s ease, color .18s ease, transform .18s ease; }
.nav-item:hover { background: var(--lilac-50); color: var(--purple-700); }
.nav-item:active { transform: scale(.985); }
.nav-item.active { background: var(--lilac-100); color: var(--purple-700); }
.nav-item svg, .icon-button svg, .button svg, .bottom-nav svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; flex: 0 0 auto; }
.sidebar-foot { margin-top: auto; display: grid; gap: 14px; }
.privacy-note { margin: 0 10px; padding: 13px 12px; border-radius: 13px; background: #f8f7f9; color: var(--muted); font-size: 11px; line-height: 1.35; display: flex; align-items: center; gap: 8px; }
.privacy-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px rgba(20, 128, 94, .1); flex: 0 0 auto; }

.workspace { min-width: 0; }
.workspace-inner { width: min(100%, 1450px); margin: 0 auto; padding: 40px clamp(24px, 4vw, 66px) 72px; }
.mobile-header, .bottom-nav { display: none; }
.view { display: none; animation: viewIn .25s ease; }
.view.active { display: block; }
@keyframes viewIn { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
.page-head { min-height: 78px; margin-bottom: 26px; display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; }
.page-head h1 { margin: 2px 0 5px; font-size: clamp(29px, 3vw, 40px); line-height: 1.08; letter-spacing: -1.4px; font-weight: 800; }
.page-subtitle { margin: 0; color: var(--muted); max-width: 660px; }
.eyebrow, .section-kicker { margin: 0; color: var(--purple-700); font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .105em; }
.overview-head .eyebrow { color: var(--muted); }

.button { min-height: 46px; border: 0; border-radius: 13px; padding: 0 18px; display: inline-flex; align-items: center; justify-content: center; gap: 9px; font-weight: 800; font-size: 14px; cursor: pointer; transition: transform .16s ease, box-shadow .16s ease, background .16s ease; }
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0) scale(.985); }
.button.primary { color: white; background: linear-gradient(135deg, var(--purple-700), #7d3ee2); box-shadow: 0 10px 24px rgba(91, 33, 182, .2); }
.button.primary:hover { box-shadow: 0 13px 28px rgba(91, 33, 182, .27); }
.button.secondary { color: var(--purple-700); background: var(--lilac-100); }
.button.danger { color: white; background: var(--red); }
.button.wide { width: 100%; }
.button svg { width: 18px; height: 18px; }
.icon-button { width: 42px; height: 42px; padding: 0; border: 1px solid var(--line); border-radius: 13px; background: white; display: grid; place-items: center; cursor: pointer; }
.text-button, .insight-action, .text-link, .danger-link { padding: 0; border: 0; background: none; cursor: pointer; font-weight: 800; }
.text-button { color: var(--purple-700); font-size: 13px; white-space: nowrap; }
.text-button span, .insight-action span { margin-left: 4px; transition: margin .15s ease; }
.text-button:hover span, .insight-action:hover span { margin-left: 8px; }

.metric-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.metric-card { min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 19px 19px 18px; box-shadow: var(--shadow-sm); display: grid; }
.metric-top { margin-bottom: 16px; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.metric-icon { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; }
.metric-icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.metric-icon.violet { color: var(--purple-700); background: var(--lilac-100); }
.metric-icon.coral { color: var(--coral); background: var(--coral-soft); }
.metric-icon.mint { color: var(--green); background: var(--green-soft); }
.metric-icon.lilac { color: #7d3ee2; background: #f2eafd; }
.metric-change { padding: 5px 8px; border-radius: 999px; color: var(--muted); background: #f6f4f7; font-size: 11px; font-weight: 800; }
.metric-change.positive { color: var(--green); background: var(--green-soft); }
.metric-change.negative { color: var(--red); background: var(--red-soft); }
.metric-label { color: var(--muted); font-size: 13px; font-weight: 650; }
.metric-value { min-width: 0; margin: 4px 0 1px; font-size: clamp(24px, 2.3vw, 31px); line-height: 1.15; letter-spacing: -1.15px; overflow-wrap: anywhere; }
.metric-card small { color: #938b9b; font-size: 11px; }

.overview-grid { margin-top: 15px; display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(330px, .8fr); gap: 15px; align-items: stretch; }
.surface { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.surface-head { padding: 22px 22px 0; display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; }
.surface-head.compact { align-items: center; }
.surface-head h2, .form-head h2 { margin: 3px 0 2px; font-size: 21px; line-height: 1.15; letter-spacing: -.55px; }
.surface-head p:not(.section-kicker), .form-head p { margin: 0; color: var(--muted); font-size: 13px; }
.chart-surface { min-height: 353px; overflow: hidden; }
.chart-legend { height: 38px; padding: 14px 23px 0; display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 12px; }
.chart-legend span { display: flex; align-items: center; gap: 7px; }
.chart-legend strong { color: var(--green); }
.legend-line { width: 20px; height: 3px; border-radius: 10px; background: var(--violet-500); }
.line-chart { min-height: 230px; padding: 3px 14px 14px; position: relative; }
.line-chart svg { width: 100%; height: 215px; overflow: visible; }
.chart-grid-line { stroke: #ede8f1; stroke-width: 1; stroke-dasharray: 3 5; }
.chart-area { fill: url(#chartFill); }
.chart-line { fill: none; stroke: var(--purple-600); stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.chart-point { fill: white; stroke: var(--purple-600); stroke-width: 2.5; }
.chart-point-label { fill: var(--ink); font-size: 11px; font-weight: 800; text-anchor: middle; }
.chart-month { fill: var(--muted); font-size: 10px; font-weight: 700; text-anchor: middle; text-transform: capitalize; }
.chart-zero { stroke: var(--coral); stroke-width: 1; stroke-dasharray: 4 5; opacity: .55; }
.ysli-insight { min-height: 353px; position: relative; overflow: hidden; isolation: isolate; color: white; background: radial-gradient(circle at 90% 12%, #a765ef 0, transparent 33%), linear-gradient(145deg, #261044, #5b21b6 66%, #7f3ee0); border-color: transparent; }
.insight-copy { position: relative; z-index: 3; width: 68%; padding: 25px 0 24px 24px; }
.assistant-pill { width: fit-content; display: inline-flex; align-items: center; padding: 7px 10px; border-radius: 999px; background: rgba(255,255,255,.13); color: inherit; font-size: 11px; font-weight: 800; letter-spacing: .04em; }
.ysli-insight h2 { margin: 18px 0 8px; font-size: clamp(22px, 2.2vw, 29px); line-height: 1.1; letter-spacing: -.8px; }
.ysli-insight p { margin: 0; color: rgba(255,255,255,.78); font-size: 13px; line-height: 1.55; }
.insight-action { margin-top: 24px; color: white; font-size: 13px; }
.mascot { position: absolute; z-index: 2; width: 190px; height: 245px; object-fit: cover; object-position: 42% center; right: -35px; bottom: -8px; mix-blend-mode: screen; filter: saturate(1.03) contrast(1.02); }
.insight-orbit { position: absolute; border: 1px solid rgba(255,255,255,.12); border-radius: 50%; z-index: 1; }
.orbit-one { width: 260px; height: 260px; right: -70px; bottom: -68px; }
.orbit-two { width: 200px; height: 200px; right: -40px; bottom: -38px; }
.composition-surface { grid-column: 1 / -1; padding-bottom: 21px; }
.stack-bar { height: 13px; margin: 21px 22px 17px; display: flex; overflow: hidden; border-radius: 999px; background: #ece8ef; }
.stack-bar span { min-width: 0; transition: width .45s ease; }
.stack-fixed { background: var(--purple-700); }
.stack-installments { background: var(--violet-500); }
.stack-free { background: #73d7b4; }
.composition-list { padding: 0 22px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.composition-list > div { padding: 13px 14px; border-radius: 14px; background: #faf9fb; display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 13px; }
.composition-list span { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; }
.dot.fixed { background: var(--purple-700); }.dot.installments { background: var(--violet-500); }.dot.free { background: #45bf96; }

.segmented { padding: 4px; border: 1px solid var(--line); border-radius: 13px; background: white; display: flex; gap: 3px; }
.segmented button { min-height: 36px; padding: 0 12px; border: 0; border-radius: 9px; color: var(--muted); background: transparent; font-size: 12px; font-weight: 800; cursor: pointer; }
.segmented button.active { color: white; background: var(--purple-700); }
.future-highlight { margin-bottom: 14px; padding: 22px; display: flex; align-items: center; justify-content: space-between; gap: 22px; background: linear-gradient(135deg, #24103e, var(--purple-700)); color: white; border: 0; }
.future-highlight-copy span { color: #d7b7fb; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.future-highlight-copy h2 { margin: 4px 0; font-size: 26px; letter-spacing: -.7px; }
.future-highlight-copy p { margin: 0; color: rgba(255,255,255,.73); font-size: 13px; }
.future-highlight-value { text-align: right; }
.future-highlight-value strong { display: block; font-size: 30px; letter-spacing: -1px; }
.future-highlight-value small { color: rgba(255,255,255,.7); }
.future-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.month-card { padding: 19px; background: white; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.month-card.current { border-color: #c9a3f5; box-shadow: 0 0 0 2px rgba(168, 85, 247, .08), var(--shadow-sm); }
.month-card-head { margin-bottom: 15px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.month-card h3 { margin: 0; font-size: 16px; text-transform: capitalize; }
.current-badge { padding: 4px 7px; border-radius: 999px; color: var(--purple-700); background: var(--lilac-100); font-size: 10px; font-weight: 800; text-transform: uppercase; }
.month-row { margin: 8px 0; display: flex; justify-content: space-between; gap: 10px; color: var(--muted); font-size: 13px; }
.month-row strong { color: var(--ink); }
.month-free { margin-top: 14px; padding-top: 13px; border-top: 1px dashed var(--line); display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.month-free span { color: var(--muted); font-size: 12px; }
.month-free strong { color: var(--purple-700); font-size: 20px; letter-spacing: -.5px; }
.month-free strong.negative { color: var(--red); }

.commitment-summary { margin-bottom: 14px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.summary-chip { padding: 17px 19px; border: 1px solid var(--line); border-radius: 16px; background: white; box-shadow: var(--shadow-sm); }
.summary-chip span { color: var(--muted); font-size: 12px; }
.summary-chip strong { display: block; margin-top: 4px; font-size: 21px; letter-spacing: -.5px; }
.commitment-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.list-surface { overflow: hidden; }
.add-small { width: 38px; height: 38px; color: var(--purple-700); background: var(--lilac-100); border: 0; font-size: 22px; }
.item-list { padding: 16px 20px 21px; display: grid; gap: 9px; }
.list-item { min-width: 0; padding: 13px; border: 1px solid #eee9f1; border-radius: 15px; display: grid; grid-template-columns: 42px minmax(0, 1fr) auto auto; align-items: center; gap: 11px; }
.list-item-icon { width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center; color: var(--purple-700); background: var(--lilac-100); font-size: 16px; font-weight: 850; }
.list-item-copy { min-width: 0; }
.list-item-copy strong { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 14px; }
.list-item-copy small { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.list-item-value { text-align: right; }
.list-item-value strong { display: block; font-size: 14px; }
.list-item-value small { color: var(--muted); font-size: 10px; }
.delete-item { width: 34px; height: 34px; border: 0; border-radius: 10px; color: #a096aa; background: transparent; cursor: pointer; display: grid; place-items: center; }
.delete-item:hover { color: var(--red); background: var(--red-soft); }
.delete-item svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.empty-list { padding: 24px 14px; color: var(--muted); text-align: center; font-size: 13px; border: 1px dashed #dfd7e6; border-radius: 15px; }
.empty-list button { margin-top: 8px; border: 0; background: none; color: var(--purple-700); font-weight: 800; cursor: pointer; }

.simulator-grid { display: grid; grid-template-columns: minmax(350px, .8fr) minmax(440px, 1.2fr); gap: 15px; align-items: stretch; }
.simulator-form, .profile-form { padding: 25px; }
.form-head { margin-bottom: 23px; display: flex; gap: 13px; align-items: flex-start; }
.form-step { width: 38px; height: 38px; border-radius: 12px; color: var(--purple-700); background: var(--lilac-100); display: grid; place-items: center; font-size: 12px; font-weight: 850; flex: 0 0 auto; }
.field { display: grid; gap: 7px; margin-bottom: 16px; }
.field > span { color: #423849; font-size: 13px; font-weight: 750; }
.field > small { margin-top: -2px; color: var(--muted); font-size: 11px; }
.field input, .field select { width: 100%; height: 48px; padding: 0 13px; border: 1px solid #dcd4e2; border-radius: 12px; color: var(--ink); background: white; outline: 0; transition: border .15s ease, box-shadow .15s ease; }
.field input::placeholder { color: #aaa2b1; }
.field input:focus, .field select:focus { border-color: var(--violet-500); box-shadow: 0 0 0 4px rgba(168, 85, 247, .1); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.money-input { height: 48px; border: 1px solid #dcd4e2; border-radius: 12px; display: flex; align-items: center; overflow: hidden; transition: border .15s ease, box-shadow .15s ease; }
.money-input:focus-within { border-color: var(--violet-500); box-shadow: 0 0 0 4px rgba(168, 85, 247, .1); }
.money-input > span { height: 100%; padding: 0 0 0 13px; color: var(--muted); display: flex; align-items: center; font-size: 13px; }
.money-input input { height: 100%; border: 0; padding-left: 8px; box-shadow: none !important; }
.simulation-result { min-height: 500px; padding: 27px; }
.simulation-result.empty { display: grid; align-content: center; justify-items: center; text-align: center; }
.simulation-result.empty h2 { margin: 18px 0 6px; font-size: 21px; }
.simulation-result.empty p { max-width: 430px; margin: 0; color: var(--muted); font-size: 13px; }
.empty-visual { width: 92px; height: 92px; border-radius: 26px; background: var(--lilac-100); display: grid; place-items: center; }
.empty-visual svg { width: 66px; fill: none; stroke: var(--purple-700); stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.simulation-result:not(.empty) { display: block; }
.result-status { padding: 17px; border-radius: 16px; display: flex; align-items: center; gap: 12px; }
.result-status.good { color: var(--green); background: var(--green-soft); }.result-status.warning { color: var(--amber); background: var(--amber-soft); }.result-status.risk { color: var(--red); background: var(--red-soft); }
.status-icon { width: 38px; height: 38px; border-radius: 12px; background: rgba(255,255,255,.75); display: grid; place-items: center; font-weight: 900; }
.result-status strong { display: block; font-size: 14px; }.result-status small { display: block; margin-top: 2px; color: currentColor; opacity: .82; }
.result-title { margin: 22px 0 4px; font-size: 24px; letter-spacing: -.7px; }.result-sub { margin: 0; color: var(--muted); font-size: 13px; }
.result-kpis { margin: 20px 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px; }
.result-kpi { padding: 15px; border: 1px solid var(--line); border-radius: 15px; background: #fcfbfd; }
.result-kpi span { color: var(--muted); font-size: 11px; }.result-kpi strong { display: block; margin-top: 4px; font-size: 18px; letter-spacing: -.4px; }
.before-after { padding: 17px; border-radius: 16px; background: var(--lilac-50); display: grid; grid-template-columns: 1fr auto 1fr; gap: 13px; align-items: center; }
.before-after > div { display: grid; }.before-after span { color: var(--muted); font-size: 11px; }.before-after strong { margin-top: 3px; font-size: 18px; }.before-after svg { width: 22px; height: 22px; fill: none; stroke: var(--purple-700); stroke-width: 1.8; }
.result-note { margin: 17px 0; color: var(--muted); font-size: 12px; line-height: 1.55; }

.relief-hero { min-height: 190px; margin-bottom: 15px; padding: 29px; border-radius: var(--radius-lg); color: white; background: radial-gradient(circle at 86% 18%, rgba(196, 130, 255, .8), transparent 30%), linear-gradient(145deg, #281046, #5b21b6); box-shadow: 0 18px 45px rgba(64, 24, 112, .18); overflow: hidden; position: relative; }
.relief-hero::after { content: ""; position: absolute; width: 220px; height: 220px; border: 1px solid rgba(255,255,255,.13); border-radius: 50%; right: -55px; top: -60px; }
.relief-hero span { color: #dfc9fa; font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.relief-hero h2 { max-width: 700px; margin: 8px 0 6px; font-size: clamp(27px, 3.2vw, 40px); line-height: 1.08; letter-spacing: -1.3px; }
.relief-hero p { max-width: 640px; margin: 0; color: rgba(255,255,255,.72); }
.timeline-surface { padding-bottom: 10px; }
.timeline { padding: 12px 22px 22px; }
.timeline-event { min-height: 84px; display: grid; grid-template-columns: 100px 28px minmax(0, 1fr) auto; gap: 13px; align-items: center; position: relative; }
.timeline-event:not(:last-child)::after { content: ""; position: absolute; width: 1px; height: calc(100% - 28px); background: #dccfea; left: 113px; top: calc(50% + 14px); }
.timeline-date { color: var(--muted); font-size: 12px; font-weight: 750; text-transform: capitalize; }
.timeline-dot { width: 13px; height: 13px; margin: auto; border-radius: 50%; background: var(--purple-700); box-shadow: 0 0 0 6px var(--lilac-100); z-index: 1; }
.timeline-copy strong { display: block; font-size: 14px; }.timeline-copy small { color: var(--muted); font-size: 11px; }
.timeline-release { color: var(--green); font-size: 14px; font-weight: 850; text-align: right; }

.profile-grid { display: grid; grid-template-columns: minmax(420px, 1fr) minmax(300px, .72fr); gap: 15px; align-items: stretch; }
.profile-form .surface-head { padding: 0 0 23px; }
.data-card { padding: 27px; display: flex; flex-direction: column; align-items: flex-start; }
.data-card img { width: 74px; height: 74px; border-radius: 21px; object-fit: cover; object-position: center 22%; }
.data-card h2 { margin: 20px 0 7px; font-size: 23px; letter-spacing: -.6px; }.data-card p { margin: 0 0 24px; color: var(--muted); font-size: 13px; line-height: 1.6; }
.data-card .button { margin-top: auto; }.danger-link { margin: 15px auto 0; color: var(--red); font-size: 12px; }
.legal-note { max-width: 750px; margin: 18px 4px 0; color: var(--muted); font-size: 11px; }

.modal-layer { position: fixed; inset: 0; z-index: 100; padding: 20px; background: rgba(24, 10, 40, .62); backdrop-filter: blur(8px); display: grid; place-items: center; overflow-y: auto; }
.dialog-card, .onboarding-card { width: min(100%, 500px); max-height: calc(100vh - 40px); overflow-y: auto; position: relative; padding: 29px; border-radius: 25px; background: white; box-shadow: var(--shadow-lg); animation: modalIn .22s ease; }
.onboarding-card { width: min(100%, 560px); padding: 30px 42px 34px; text-align: center; }
@keyframes modalIn { from { opacity: 0; transform: translateY(10px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
.modal-close { position: absolute; top: 15px; right: 15px; z-index: 3; width: 36px; height: 36px; padding: 0; border: 0; border-radius: 11px; background: #f4f1f6; color: #716878; font-size: 24px; line-height: 1; cursor: pointer; }
.onboarding-progress { margin: 0 auto 18px; display: flex; justify-content: center; gap: 6px; }
.onboarding-progress span { width: 23px; height: 4px; border-radius: 999px; background: #e6dfeb; }.onboarding-progress span.active { width: 38px; background: var(--purple-700); }
.onboarding-step { display: none; }.onboarding-step.active { display: block; }
.onboarding-mascot { width: 150px; height: 150px; margin: -8px auto 8px; display: block; border-radius: 36px; object-fit: cover; object-position: 40% center; mix-blend-mode: multiply; }
.onboarding-step .assistant-pill { color: var(--purple-700); background: var(--lilac-100); }
.onboarding-step h2 { margin: 16px auto 8px; max-width: 460px; font-size: 27px; line-height: 1.12; letter-spacing: -.8px; }
.onboarding-step > p { margin: 0 auto 24px; max-width: 440px; color: var(--muted); font-size: 14px; }
.onboarding-step .field { text-align: left; }
.text-link { margin-top: 16px; color: var(--purple-700); font-size: 12px; }
.step-count { display: inline-block; margin: 6px 0 2px; color: var(--purple-700); font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .1em; }
.onboarding-preview { margin: 4px 0 18px; padding: 15px 16px; border-radius: 14px; background: var(--lilac-50); display: flex; align-items: center; justify-content: space-between; gap: 12px; text-align: left; }.onboarding-preview span { color: var(--muted); font-size: 12px; }.onboarding-preview strong { color: var(--purple-700); font-size: 18px; }
.dialog-card > h2 { margin: 4px 0 20px; font-size: 24px; letter-spacing: -.6px; }.dialog-card .eyebrow { margin-top: 3px; }
.type-switch { margin-bottom: 20px; padding: 4px; border-radius: 13px; background: #f3eff6; display: grid; grid-template-columns: 1fr 1fr; gap: 4px; }
.type-switch button { height: 38px; border: 0; border-radius: 10px; color: var(--muted); background: transparent; font-size: 13px; font-weight: 800; cursor: pointer; }.type-switch button.active { color: var(--purple-700); background: white; box-shadow: 0 3px 10px rgba(47, 23, 72, .08); }
.dialog-actions { margin-top: 21px; display: flex; justify-content: flex-end; gap: 9px; }
.compact-dialog { max-width: 420px; text-align: center; }.compact-dialog > h2 { margin: 14px 0 6px; }.compact-dialog > p { margin: 0; color: var(--muted); font-size: 13px; }.compact-dialog .dialog-actions { justify-content: center; }
.warning-icon { width: 50px; height: 50px; margin: 0 auto; border-radius: 16px; color: var(--red); background: var(--red-soft); display: grid; place-items: center; font-size: 22px; font-weight: 900; }
.toast { position: fixed; z-index: 150; left: 50%; bottom: 28px; min-width: 260px; max-width: calc(100vw - 30px); padding: 12px 16px; border-radius: 14px; color: white; background: var(--purple-950); box-shadow: 0 15px 40px rgba(20, 8, 35, .25); display: flex; align-items: center; gap: 10px; transform: translate(-50%, 130%); opacity: 0; pointer-events: none; transition: transform .25s ease, opacity .25s ease; }.toast.show { transform: translate(-50%, 0); opacity: 1; }.toast-icon { width: 22px; height: 22px; border-radius: 50%; background: var(--green); display: grid; place-items: center; font-size: 12px; font-weight: 900; }

.auth-shell { min-height: 100vh; padding: 28px 18px; background: radial-gradient(circle at 15% 12%, rgba(168,85,247,.18), transparent 34%), radial-gradient(circle at 90% 80%, rgba(91,33,182,.13), transparent 36%), #f8f6fb; display: grid; place-items: center; }
.auth-card { width: min(100%, 460px); padding: 31px; border: 1px solid rgba(91,33,182,.12); border-radius: 27px; background: rgba(255,255,255,.96); box-shadow: 0 28px 75px rgba(50,22,78,.14); }
.auth-brand { margin-bottom: 31px; display: flex; align-items: center; gap: 11px; }
.auth-brand img { width: 49px; height: 49px; border-radius: 15px; object-fit: cover; }
.auth-brand strong { display: block; color: var(--purple-950); font-size: 25px; letter-spacing: -.8px; }.auth-brand strong span { color: var(--violet-500); font-size: 10px; vertical-align: super; }.auth-brand small { color: var(--muted); font-size: 11px; }
.auth-state h1 { margin: 7px 0 8px; color: var(--purple-950); font-size: 29px; line-height: 1.08; letter-spacing: -1px; }.auth-state > p { margin: 0 0 23px; color: var(--muted); font-size: 13px; line-height: 1.55; }
.auth-eyebrow { color: var(--purple-700); font-size: 11px; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.auth-link { margin: 14px auto 0; padding: 0; border: 0; color: var(--purple-700); background: none; display: block; font-size: 12px; font-weight: 800; text-decoration: none; cursor: pointer; }
.auth-divider { margin: 19px 0; border-top: 1px solid var(--line); position: relative; text-align: center; }.auth-divider span { padding: 0 10px; color: #9b91a3; background: white; font-size: 10px; position: relative; top: -9px; }
.auth-security { margin: 25px 0 0 !important; padding-top: 17px; border-top: 1px solid var(--line); text-align: center; font-size: 10px !important; }
.auth-message { margin: 17px 0 0 !important; padding: 12px 13px; border-radius: 12px; color: var(--red) !important; background: var(--red-soft); font-weight: 650; }
.auth-message.success { color: var(--green) !important; background: var(--green-soft); }
.auth-loader { width: 43px; height: 43px; margin: 12px 0 22px; border: 4px solid var(--lilac-100); border-top-color: var(--purple-700); border-radius: 50%; animation: authSpin .8s linear infinite; }
@keyframes authSpin { to { transform: rotate(360deg); } }
.access-state { text-align: center; }.access-mascot { width: 132px; height: 132px; margin: -5px auto 13px; border-radius: 31px; object-fit: cover; mix-blend-mode: multiply; }.access-state .button { margin-top: 9px; }.access-state a.button { text-decoration: none; }
.logout-link { margin-top: 14px; }

@media (max-width: 1120px) {
  .app-shell { grid-template-columns: 220px minmax(0, 1fr); }
  .workspace-inner { padding-inline: 26px; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .future-grid { grid-template-columns: repeat(2, 1fr); }
  .overview-grid { grid-template-columns: minmax(0, 1.35fr) minmax(300px, .8fr); }
  .insight-copy { width: 72%; }
  .mascot { right: -50px; }
}

@media (max-width: 860px) {
  .app-shell { display: block; }
  .sidebar { display: none; }
  .workspace-inner { padding: 25px 18px 100px; }
  .mobile-header { height: 66px; padding: max(10px, env(safe-area-inset-top)) 18px 10px; background: rgba(255,255,255,.9); border-bottom: 1px solid var(--line); backdrop-filter: blur(14px); display: flex; align-items: center; justify-content: space-between; position: sticky; top: 0; z-index: 40; }
  .mobile-brand { display: flex; align-items: center; gap: 9px; }.mobile-brand strong { color: var(--purple-950); font-size: 22px; letter-spacing: -.7px; }.mobile-brand strong span { color: var(--violet-500); font-size: 11px; vertical-align: super; }.mobile-logo { width: 36px; height: 36px; border-radius: 12px; color: white; background: var(--purple-700); display: grid; place-items: center; font-weight: 900; }
  .bottom-nav { height: 72px; padding: 7px 12px max(8px, env(safe-area-inset-bottom)); background: rgba(255,255,255,.95); border-top: 1px solid var(--line); backdrop-filter: blur(14px); display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 50; }
  .bottom-nav button { min-width: 0; padding: 4px; border: 0; background: transparent; color: #88808f; display: grid; place-items: center; align-content: center; gap: 2px; font-size: 9px; font-weight: 750; cursor: pointer; }.bottom-nav button.active { color: var(--purple-700); }.bottom-nav svg { width: 21px; height: 21px; }
  .bottom-nav .bottom-add { align-self: start; }.bottom-nav .bottom-add span { width: 48px; height: 48px; margin-top: -23px; border: 5px solid var(--canvas); border-radius: 50%; color: white; background: linear-gradient(135deg, var(--purple-700), var(--violet-500)); box-shadow: 0 8px 18px rgba(91,33,182,.25); display: grid; place-items: center; font-size: 25px; }
  .overview-grid, .simulator-grid, .profile-grid { grid-template-columns: 1fr; }
  .chart-surface { min-height: 335px; }
  .ysli-insight { min-height: 280px; }
  .insight-copy { width: 66%; }
  .commitment-columns { grid-template-columns: 1fr; }
  .simulation-result { min-height: 420px; }
}

@media (max-width: 620px) {
  .auth-shell { padding: 12px; align-items: start; }.auth-card { margin-top: max(12px, env(safe-area-inset-top)); padding: 24px 20px; border-radius: 22px; }.auth-brand { margin-bottom: 25px; }.auth-state h1 { font-size: 26px; }
  .workspace-inner { padding: 20px 12px 96px; }
  .page-head { min-height: 0; margin-bottom: 19px; align-items: flex-start; flex-direction: column; gap: 15px; }
  .page-head h1 { font-size: 29px; letter-spacing: -1px; }
  .page-subtitle { font-size: 13px; }
  .page-head .button { width: 100%; }
  .overview-head .button { display: none; }
  .metric-grid { grid-template-columns: 1fr 1fr; gap: 9px; }
  .metric-card { padding: 14px; border-radius: 17px; }
  .metric-top { margin-bottom: 12px; }.metric-icon { width: 34px; height: 34px; border-radius: 10px; }.metric-change { padding: 4px 6px; font-size: 9px; }
  .metric-label { font-size: 11px; }.metric-value { font-size: clamp(19px, 6.1vw, 25px); letter-spacing: -.8px; }.metric-card small { display: none; }
  .overview-grid { margin-top: 10px; gap: 10px; }
  .surface { border-radius: 18px; }
  .surface-head { padding: 18px 17px 0; }.surface-head h2 { font-size: 19px; }.text-button { font-size: 11px; }
  .chart-legend { padding-inline: 18px; }.line-chart { padding-inline: 4px; overflow: hidden; }.chart-point-label { font-size: 9px; }.chart-month { font-size: 8px; }
  .ysli-insight { min-height: 300px; }.insight-copy { width: 72%; padding: 22px 0 22px 19px; }.ysli-insight h2 { font-size: 23px; }.mascot { width: 175px; right: -52px; }.insight-action { margin-top: 17px; }
  .composition-list { padding: 0 17px; grid-template-columns: 1fr; gap: 7px; }.stack-bar { margin-inline: 17px; }
  .future-highlight { padding: 19px; align-items: flex-start; flex-direction: column; }.future-highlight-value { text-align: left; }.future-grid { grid-template-columns: 1fr; gap: 9px; }
  .commitment-summary { grid-template-columns: 1fr 1fr; gap: 8px; }.summary-chip:last-child { grid-column: 1 / -1; }.summary-chip { padding: 14px; }.summary-chip strong { font-size: 18px; }
  .item-list { padding: 13px; }.list-item { grid-template-columns: 39px minmax(0, 1fr) auto; gap: 9px; }.list-item-icon { width: 39px; height: 39px; }.delete-item { grid-column: 3; grid-row: 1; width: 30px; }.list-item-value { grid-column: 2 / -1; text-align: left; display: flex; gap: 5px; align-items: baseline; }
  .simulator-form, .profile-form, .simulation-result, .data-card { padding: 19px; }.field-row { grid-template-columns: 1fr; gap: 0; }.result-kpis { grid-template-columns: 1fr 1fr; }.result-kpi:last-child { grid-column: 1 / -1; }.before-after { grid-template-columns: 1fr; }.before-after svg { transform: rotate(90deg); justify-self: center; }
  .relief-hero { min-height: 215px; padding: 23px; }.timeline { padding-inline: 14px; }.timeline-event { grid-template-columns: 70px 22px minmax(0, 1fr); gap: 8px; padding: 13px 0; }.timeline-event:not(:last-child)::after { left: 81px; }.timeline-release { grid-column: 3; text-align: left; }
  .onboarding-card, .dialog-card { padding: 25px 20px; border-radius: 22px; }.onboarding-step h2 { font-size: 24px; }.onboarding-mascot { width: 128px; height: 128px; }.dialog-actions { display: grid; grid-template-columns: 1fr 1fr; }.dialog-actions .button { width: 100%; }
  .segmented { width: 100%; }.segmented button { flex: 1; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
