/* static/css/style.css */

:root {
    color-scheme: dark;
    --ui-bg-page: #0f0f0f;
    --ui-bg-panel: rgba(30, 30, 30, 0.62);
    --ui-bg-sidebar: #0f131c;
    --ui-bg-sidebar-footer: #0d1119;
    --ui-bg-surface: #1a1a1a;
    --ui-border-subtle: #1f2937;
    --ui-border-strong: #334155;
    --ui-text-primary: #e5e7eb;
    --ui-text-muted: #9ca3af;
    --ui-accent: #6366f1;
    --ui-success: #10b981;
    --ui-danger: #ef4444;
    --ui-radius-md: 12px;
    --ui-radius-lg: 16px;
    --ui-space-2: 8px;
    --ui-space-3: 12px;
    --ui-space-4: 16px;
    --axis-surface: var(--bg-surface, #0f172a);
    --axis-surface-2: var(--bg-surface-elevated, #131d33);
    --axis-border: var(--border-subtle, #1e293b);
    --axis-text: var(--text-primary, #f8fafc);
    --axis-muted: var(--text-secondary, #94a3b8);
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

html[data-theme="light"] {
    --ui-bg-page: #f8fafc;
    --ui-bg-sidebar: #e2e8f0;
    --ui-bg-panel: rgba(255, 255, 255, 0.94);
    --ui-bg-surface: #ffffff;
    --ui-text-primary: #0f172a;
    --ui-text-muted: #475569;
    --ui-border-subtle: #cbd5e1;
    --axis-surface: #ffffff;
    --axis-surface-2: #f1f5f9;
    --axis-border: #e2e8f0;
    --axis-text: #0f172a;
    --axis-muted: #475569;
    color-scheme: light;
}

html[data-theme="light"] .app-sidebar {
    background: linear-gradient(180deg, #f8fafc, #e2e8f0);
}

html[data-theme="light"] .text-gray-200,
html[data-theme="light"] .text-white {
    color: #0f172a !important;
}

html[data-reduce-motion="true"] *,
html[data-reduce-motion="true"] *::before,
html[data-reduce-motion="true"] *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
}

:focus-visible {
    outline: 3px solid #a5b4fc;
    outline-offset: 3px;
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--ui-bg-page);
    color: var(--ui-text-primary);
}

a {
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

.app-shell {
    background:
        radial-gradient(circle at top left, rgba(99, 102, 241, 0.14), transparent 28rem),
        radial-gradient(circle at bottom right, rgba(16, 185, 129, 0.08), transparent 26rem),
        var(--ui-bg-page);
}

.app-sidebar {
    background: linear-gradient(180deg, var(--ui-bg-sidebar), #0b0f17);
    border-right: 1px solid rgba(51, 65, 85, 0.78);
}

.app-sidebar-brand h1 {
    background: linear-gradient(90deg, #bfdbfe, #818cf8);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.app-sidebar .nav-item {
    min-height: 48px;
}

.glass-panel {
    background: var(--ui-bg-panel);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.ui-input {
    background-color: var(--ui-bg-surface);
    border-color: var(--ui-border-subtle);
    color: var(--ui-text-primary);
    border: 1px solid var(--ui-border-subtle);
    border-radius: var(--ui-radius-md);
    padding: var(--ui-space-2) var(--ui-space-3);
}

.ui-input:focus {
    background-color: var(--bg-surface, #111827);
    border-color: var(--ui-accent);
    color: var(--ui-text-primary);
    box-shadow: 0 0 0 0.2rem rgba(99, 102, 241, 0.18);
}

.ui-btn {
    border-radius: var(--ui-radius-md);
    padding: var(--ui-space-2) var(--ui-space-4);
    font-weight: 700;
    transition: 180ms ease;
}

.ui-btn-primary {
    background: var(--ui-accent);
    color: #fff;
}

.ui-btn-primary:hover {
    filter: brightness(1.08);
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
}

.editable-time:hover {
    color: #a5b4fc;
    cursor: pointer;
}

.editable-time:disabled {
    color: #9ca3af;
    cursor: not-allowed;
}

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-main, #0f0f0f);
}

::-webkit-scrollbar-thumb {
    background: var(--border-medium, #333);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border-hover, #555);
}

#sidebar.is-collapsed .sidebar-text {
    display: none !important;
}

#sidebar.is-collapsed .nav-item {
    justify-content: center;
    padding-left: 0.75rem;
    padding-right: 0.75rem;
}

#sidebar.is-collapsed .nav-item > span:first-child {
    margin-right: 0;
}

#sidebar.is-collapsed #sidebar-toggle-btn {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
}

#sidebar:not(.is-collapsed) #sidebar-toggle-btn {
    right: 0.75rem;
    left: auto;
    transform: none;
}

#sidebar.is-collapsed #sidebar-profile-row {
    justify-content: center;
}

#sidebar.is-collapsed .app-sidebar-brand h1 {
    justify-content: center;
}

@media (max-width: 767px) {
    body.app-shell {
        overflow: auto !important;
    }

    .app-sidebar {
        width: 5rem !important;
        min-width: 5rem;
    }

    .app-sidebar .sidebar-text {
        display: none !important;
    }

    main > .p-6 {
        padding: 1rem !important;
    }
}

.axis-dashboard { position: relative; }
.axis-dashboard::before { content: ""; position: fixed; width: 32rem; height: 32rem; right: -12rem; top: -14rem; border-radius: 50%; background: rgba(129, 140, 248, .09); filter: blur(70px); pointer-events: none; }
.axis-welcome { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .25rem .15rem; }
.axis-kicker { color: #a5b4fc; font-size: .7rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.axis-welcome h1 { margin-top: .25rem; font-size: clamp(1.7rem, 4vw, 2.35rem); font-weight: 800; letter-spacing: -.035em; }
.axis-welcome h1 span { background: linear-gradient(90deg,#a5b4fc,#818cf8); background-clip: text; color: transparent; }
.axis-welcome > div > p:last-child { color: #64748b; font-size: .85rem; margin-top: .25rem; }
.axis-day-score { --progress: 0%; width: 76px; height: 76px; flex: 0 0 76px; padding: 6px; border-radius: 50%; background: conic-gradient(#818cf8 var(--progress), #1e293b 0); box-shadow: 0 0 30px rgba(129, 140, 248,.18); }
.axis-day-score > div { width: 100%; height: 100%; border-radius: 50%; background: #0f1622; display: grid; place-content: center; text-align: center; }
.axis-day-score strong { font-size: 1rem; }.axis-day-score span { color:#64748b; font-size:.62rem; text-transform:uppercase; }
.axis-hero { position: relative; overflow: hidden; background: linear-gradient(130deg,rgba(30,64,175,.32),rgba(76,29,149,.2) 65%,rgba(15,23,42,.88)); box-shadow: 0 22px 60px rgba(15,23,42,.3), inset 0 1px rgba(255,255,255,.06); }
.axis-hero::after { content:""; position:absolute; width:220px; height:220px; right:-60px; bottom:-110px; background:#4f46e5; filter:blur(80px); opacity:.18; pointer-events:none; }
.axis-hero-icon { width: 48px; height: 48px; display:grid; place-items:center; margin-bottom:1.25rem; border:1px solid rgba(147,197,253,.3); border-radius:15px; color:#bfdbfe; font-size:1.25rem; background:rgba(129, 140, 248,.16); }
.axis-primary-action { position:relative; z-index:1; background:linear-gradient(100deg,#6366f1,#4f46e5); box-shadow:0 10px 28px rgba(99, 102, 241,.28); transition:transform .2s ease,box-shadow .2s ease; }
.axis-primary-action:hover { transform:translateY(-2px); box-shadow:0 14px 34px rgba(79, 70, 229,.32); }
.axis-metric { display:flex; align-items:center; gap:1rem; border:1px solid #273449; transition:transform .2s ease,border-color .2s ease,box-shadow .2s ease; }
.axis-metric:hover { transform:translateY(-3px); box-shadow:0 14px 30px rgba(2,6,23,.3); }
.axis-metric-icon { width:46px; height:46px; flex:0 0 46px; display:grid; place-items:center; border-radius:14px; font-size:1.2rem; }
.axis-metric span { display:block; color:#94a3b8; font-size:.7rem; text-transform:uppercase; letter-spacing:.08em; }.axis-metric strong { display:block; margin-top:.1rem; font-size:1.55rem; }.axis-metric small{color:#64748b;font-size:.7rem;}
.axis-metric-blue:hover{border-color:rgba(129, 140, 248,.55)}.axis-metric-blue .axis-metric-icon{color:#a5b4fc;background:rgba(129, 140, 248,.12)}
.axis-metric-amber:hover{border-color:rgba(245,158,11,.55)}.axis-metric-amber .axis-metric-icon{color:#fbbf24;background:rgba(245,158,11,.12)}
.axis-metric-violet:hover{border-color:rgba(99, 102, 241,.55)}.axis-metric-violet .axis-metric-icon{color:#818cf8;background:rgba(99, 102, 241,.12)}
.axis-mini-progress{height:4px;margin-top:.45rem;overflow:hidden;border-radius:99px;background:#1e293b}.axis-mini-progress i{display:block;height:100%;border-radius:99px;background:linear-gradient(90deg,#6366f1,#a5b4fc)}
.axis-section { box-shadow:0 15px 40px rgba(2,6,23,.2); }.axis-task-row{background:rgba(15,23,42,.58);border:1px solid transparent;transition:.18s ease}.axis-task-row:hover{border-color:#334155;background:rgba(30,41,59,.7)}
.axis-finance { border:1px solid rgba(16,185,129,.2); background:linear-gradient(110deg,rgba(6,78,59,.18),rgba(15,23,42,.8)); transition:.2s ease; }.axis-finance:hover{transform:translateY(-2px);border-color:rgba(52,211,153,.45)}
.axis-finance-icon{width:46px;height:46px;display:grid;place-items:center;border-radius:14px;color:#34d399;background:rgba(16,185,129,.12);font-size:1.2rem}
@media (max-width: 520px){.axis-day-score{width:64px;height:64px;flex-basis:64px}.axis-hero{padding:1.35rem!important}.axis-hero h2{font-size:1.55rem}.axis-metric{padding:1rem}.axis-dashboard::before{display:none}}

/* Axis design system v2 — inherits from axis-theme.css tokens */
:root {
  --axis-bg: var(--bg-main, #090d16); --axis-surface: var(--bg-surface, #0f172a); --axis-surface-2: var(--bg-surface-elevated, #131d33);
  --axis-border: var(--border-subtle, #1e293b); --axis-text: var(--text-primary, #f8fafc); --axis-muted: var(--text-secondary, #94a3b8);
  --axis-primary: #6366f1; --axis-primary-strong: #3f63ef; --axis-success: #35d49a;
  --axis-danger: #fb7185; --axis-radius: 1rem; --axis-shadow: 0 18px 55px rgba(0,0,0,.28);
}
[data-theme="light"] { --axis-bg:#f4f7fb; --axis-surface:#fff; --axis-surface-2:#edf2f8; --axis-border:#d9e1ed; --axis-text:#132036; --axis-muted:#607089; --axis-shadow:0 16px 42px rgba(37,56,88,.12); }
[x-cloak] { display: none !important; }
* { scrollbar-width: thin; scrollbar-color: #334155 transparent; }
*:focus-visible { outline: 3px solid color-mix(in srgb, var(--axis-primary) 70%, white); outline-offset: 3px; }
html[data-reduce-motion="true"] *, html[data-reduce-motion="true"] *::before, html[data-reduce-motion="true"] *::after { animation-duration:.01ms!important; transition-duration:.01ms!important; scroll-behavior:auto!important; }
body.app-shell { margin:0; min-height:100%; overflow:hidden; background:var(--axis-bg); color:var(--axis-text); font-family:Inter,sans-serif; }
.skip-link { position:fixed; left:1rem; top:-5rem; z-index:9999; padding:.75rem 1rem; border-radius:.75rem; color:white; background:var(--axis-primary); }
.skip-link:focus { top:1rem; }
.app-frame { display:flex; height:100dvh; }
.app-sidebar { position:relative; z-index:30; display:flex; width:17rem; flex:0 0 17rem; flex-direction:column; border-right:1px solid var(--axis-border); background:color-mix(in srgb,var(--axis-surface) 94%,transparent); transition:width .25s ease,flex-basis .25s ease; }
.app-sidebar.is-collapsed { width:5.25rem; flex-basis:5.25rem; }
.sidebar-brand { display:flex; min-height:5rem; align-items:center; justify-content:space-between; gap:.75rem; padding:1rem 1.25rem; border-bottom:1px solid var(--axis-border); }
.brand-mark { display:flex; align-items:center; gap:.75rem; color:var(--axis-text); font-size:1.25rem; font-weight:800; text-decoration:none; white-space:nowrap; }
.brand-mark i { display:grid; width:2.5rem; height:2.5rem; place-items:center; border-radius:.8rem; color:#a9b9ff; background:linear-gradient(135deg,#2947a7,#6647bb); }
.icon-button { display:inline-grid; width:2.6rem; height:2.6rem; flex:0 0 auto; place-items:center; border:1px solid var(--axis-border); border-radius:.8rem; color:var(--axis-muted); background:var(--axis-surface-2); cursor:pointer; transition:.18s ease; }
.icon-button:hover { color:var(--axis-text); border-color:var(--axis-primary); }
.icon-button i { pointer-events: none; }
.sidebar-nav { flex:1; overflow-y:auto; padding:1rem .8rem; }
.nav-eyebrow { margin:1.1rem .75rem .45rem; color:var(--axis-muted); font-size:.64rem; font-weight:800; letter-spacing:.14em; text-transform:uppercase; white-space:nowrap; }
.nav-link { display:flex; min-height:2.85rem; align-items:center; gap:.85rem; margin:.2rem 0; padding:.65rem .75rem; border:1px solid transparent; border-radius:.8rem; color:var(--axis-muted); font-size:.84rem; font-weight:600; text-decoration:none; white-space:nowrap; transition:.18s ease; }
.nav-link i { width:1.55rem; flex:0 0 1.55rem; text-align:center; font-size:1.05rem; }
.nav-link:hover { color:var(--axis-text); background:var(--axis-surface-2); }
.nav-link.is-active { color:#dbe4ff; border-color:color-mix(in srgb,var(--axis-primary) 40%,transparent); background:linear-gradient(90deg,color-mix(in srgb,var(--axis-primary) 22%,transparent),transparent); }
.sidebar-footer { border-top:1px solid var(--axis-border); background:color-mix(in srgb,var(--axis-bg) 35%,var(--axis-surface)); }
.sidebar-user { display:flex; align-items:center; gap:.7rem; padding:.8rem; border-top:1px solid var(--axis-border); }
.sidebar-profile-link{display:flex;min-width:0;flex:1;align-items:center;gap:.7rem;color:var(--axis-text);text-decoration:none}.sidebar-profile-link:hover .sidebar-user-copy strong{color:#a9b9ff}
.user-avatar { display:grid; width:2.4rem; height:2.4rem; flex:0 0 2.4rem; place-items:center; border-radius:.75rem; color:#dce4ff; background:#324a98; font-weight:800; }
.sidebar-user-copy { min-width:0; flex:1; display:flex; flex-direction:column; }.sidebar-user-copy strong{overflow:hidden;text-overflow:ellipsis;font-size:.78rem}.sidebar-user-copy small{color:var(--axis-muted);font-size:.65rem}
.app-sidebar.is-collapsed .brand-mark span,.app-sidebar.is-collapsed .nav-link span,.app-sidebar.is-collapsed .nav-eyebrow,.app-sidebar.is-collapsed .sidebar-user-copy { display:none; }
.app-sidebar.is-collapsed .sidebar-brand { flex-direction:column; padding:.8rem; }.app-sidebar.is-collapsed .sidebar-nav{padding:.8rem}.app-sidebar.is-collapsed .nav-link{justify-content:center;padding:.65rem}.app-sidebar.is-collapsed .sidebar-user{padding:.8rem;justify-content:center}.app-sidebar.is-collapsed .sidebar-user form{display:none}
.app-content { min-width:0; flex:1; overflow-y:auto; }
.topbar { position:sticky; top:0; z-index:20; display:flex; min-height:4.5rem; align-items:center; justify-content:space-between; gap:1rem; padding:.75rem clamp(1rem,3vw,2rem); border-bottom:1px solid color-mix(in srgb,var(--axis-border) 75%,transparent); background:color-mix(in srgb,var(--axis-bg) 86%,transparent); backdrop-filter:blur(16px); }
.topbar-search { display:flex; width:min(27rem,48vw); align-items:center; gap:.7rem; padding:.68rem .85rem; border:1px solid var(--axis-border); border-radius:.85rem; color:var(--axis-muted); background:var(--axis-surface); cursor:pointer; }.topbar-search span{flex:1;text-align:left}.topbar-search kbd,.command-search kbd{padding:.2rem .45rem;border:1px solid var(--axis-border);border-radius:.4rem;color:var(--axis-muted);background:var(--axis-bg);font-size:.65rem}.topbar-actions{display:flex;align-items:center;gap:.6rem}
.topbar-level-card{display:flex;min-height:2.6rem;align-items:center;gap:.65rem;padding:.35rem .8rem;border:1px solid #3a4760;border-radius:999px;background:linear-gradient(110deg,rgba(30,41,59,.92),rgba(15,23,42,.82));box-shadow:inset 0 1px rgba(255,255,255,.04)}.topbar-level-number{display:grid;width:2rem;height:2rem;flex:0 0 2rem;place-items:center;border:2px solid #eab308;border-radius:999px;color:#facc15;font-size:.72rem;font-weight:800}.topbar-level-copy{display:flex;min-width:5rem;flex-direction:column;line-height:1.15}.topbar-level-copy strong{font-size:.72rem}.topbar-level-copy small{color:var(--axis-muted);font-size:.62rem}.topbar-level-progress{width:6rem;height:.3rem;overflow:hidden;border-radius:999px;background:#26344c}.topbar-level-progress i{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,#eab308,#facc15)}.topbar-level-percent{color:var(--axis-muted);font-size:.62rem}
.profile-field input,.profile-field textarea{width:100%;border:1px solid var(--axis-border);border-radius:.8rem;padding:.75rem .85rem;color:var(--axis-text);background:var(--axis-bg)}.profile-field input:focus,.profile-field textarea:focus{border-color:var(--axis-primary);outline:none;box-shadow:0 0 0 3px rgba(99, 102, 241,.13)}
.main-content { width:min(100%,96rem); min-height:calc(100dvh - 4.5rem); margin:0 auto; padding:clamp(1rem,3vw,2rem) clamp(1rem,3vw,2rem) 6rem; }
.mobile-nav { display:none; }
.sheet-backdrop,.command-backdrop { position:fixed; inset:0; z-index:100; display:none !important; background:rgba(3,7,18,.72); backdrop-filter:blur(5px); }
.sheet-backdrop[x-cloak],.command-backdrop[x-cloak] { display:none !important; }
.sheet-backdrop:not([style*="display: none"]):not([x-cloak]) { display:flex !important; align-items:flex-end; }
.command-backdrop:not([style*="display: none"]):not([x-cloak]) { display:flex !important; align-items:flex-start; justify-content:center; padding:10vh 1rem 1rem; }.command-panel{width:min(38rem,100%);overflow:hidden;border:1px solid var(--axis-border);border-radius:1.1rem;background:var(--axis-surface);box-shadow:0 30px 90px rgba(0,0,0,.55)}.command-search{display:flex;align-items:center;gap:.8rem;padding:1rem;border-bottom:1px solid var(--axis-border)}.command-search input{min-width:0;flex:1;border:0;outline:0;color:var(--axis-text);background:transparent}.command-results{max-height:24rem;overflow:auto;padding:.55rem}.command-results a{display:flex;align-items:center;gap:.8rem;padding:.75rem;border-radius:.75rem;color:var(--axis-text);text-decoration:none}.command-results a:hover{background:var(--axis-surface-2)}.command-results a>i:first-child{display:grid;width:2.4rem;height:2.4rem;place-items:center;border-radius:.7rem;color:#9fb0ff;background:rgba(99, 102, 241,.12)}.command-results span{display:flex;flex:1;flex-direction:column}.command-results small{color:var(--axis-muted);font-size:.68rem}.command-results a>i:last-child{color:var(--axis-muted)}.command-empty{padding:2rem;text-align:center;color:var(--axis-muted)}
.toast-region{position:fixed;right:1rem;top:5rem;z-index:200;display:grid;width:min(24rem,calc(100vw - 2rem));gap:.6rem}.axis-toast{display:flex;align-items:center;gap:.7rem;padding:.85rem 1rem;transform:translateX(1rem);opacity:0;border:1px solid var(--axis-border);border-left:3px solid var(--axis-success);border-radius:.8rem;background:var(--axis-surface);box-shadow:var(--axis-shadow);transition:.2s ease}.axis-toast.is-visible{transform:none;opacity:1}.axis-toast-error{border-left-color:var(--axis-danger)}.axis-toast-warning{border-left-color:#f59e0b}.axis-toast-info{border-left-color:var(--axis-primary)}.axis-toast span{flex:1;font-size:.8rem}.axis-toast button{border:0;color:var(--axis-muted);background:transparent;cursor:pointer}
.ui-alert{display:flex;align-items:flex-start;gap:.6rem;padding:.8rem 1rem;border:1px solid color-mix(in srgb,var(--axis-primary) 40%,var(--axis-border));border-radius:.8rem;color:#cdd8ff;background:rgba(99, 102, 241,.1);font-size:.8rem}.ui-alert-error,.ui-alert-danger{color:#fecdd3;border-color:rgba(251,113,133,.35);background:rgba(251,113,133,.1)}.ui-alert-success{color:#bbf7d0;border-color:rgba(53,212,154,.35);background:rgba(53,212,154,.1)}.page-messages{display:grid;gap:.5rem;margin-bottom:1rem}

/* Authentication */
body.auth-page { min-height:100%; margin:0; color:var(--axis-text); background:var(--axis-bg); font-family:Inter,sans-serif; }
.auth-layout{display:grid;min-height:100dvh;grid-template-columns:minmax(20rem,1.05fr) minmax(28rem,.95fr)}.auth-story{position:relative;display:flex;overflow:hidden;flex-direction:column;justify-content:space-between;padding:clamp(2rem,5vw,5rem);background:radial-gradient(circle at 20% 15%,rgba(99, 102, 241,.32),transparent 34%),radial-gradient(circle at 80% 90%,rgba(99, 102, 241,.22),transparent 35%),#0a1121}.auth-story::after{content:"";position:absolute;inset:0;opacity:.14;background-image:linear-gradient(rgba(255,255,255,.08) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.08) 1px,transparent 1px);background-size:3rem 3rem;mask-image:linear-gradient(to bottom,black,transparent)}.auth-story>*{position:relative;z-index:1}.auth-brand{display:flex;align-items:center;gap:.7rem;color:white;font-size:1.3rem;font-weight:800;text-decoration:none}.auth-brand i{display:grid;width:2.6rem;height:2.6rem;place-items:center;border-radius:.8rem;background:linear-gradient(135deg,#4567e6,#7754c9)}.auth-story h1{margin:.7rem 0 1rem;font-size:clamp(2.2rem,4.2vw,4.5rem);line-height:1.04;letter-spacing:-.055em}.auth-story h1 span{color:#9aafff}.auth-story>div>p:last-of-type{max-width:36rem;color:#a7b2c6;font-size:1rem;line-height:1.7}.auth-kicker{color:#8da5ff!important;font-size:.68rem!important;font-weight:800;letter-spacing:.16em;text-transform:uppercase}.auth-features{display:flex;flex-wrap:wrap;gap:1rem;margin-top:2rem;color:#cad3e4;font-size:.78rem}.auth-features span{display:flex;align-items:center;gap:.4rem}.auth-features i{color:#6ee7b7}.auth-story>small{color:#64748b}.auth-panel{display:grid;place-items:center;padding:2rem;background:var(--axis-bg)}.auth-card{width:min(27rem,100%)}.auth-heading{margin-bottom:1.8rem}.auth-heading h2,.auth-result h2{margin:.35rem 0 .45rem;font-size:1.8rem;letter-spacing:-.035em}.auth-heading>p:last-child,.auth-result p{color:var(--axis-muted);font-size:.87rem;line-height:1.6}.auth-form{display:grid;gap:1.15rem}.field-group{display:grid;gap:.45rem}.field-group label{font-size:.76rem;font-weight:700}.field-group>small{color:var(--axis-muted);font-size:.67rem;line-height:1.4}.field-label-row{display:flex;justify-content:space-between;align-items:center}.field-label-row a,.auth-switch a{color:#92a8ff;font-size:.72rem;font-weight:600;text-decoration:none}.field-control{display:flex;min-height:3.2rem;align-items:center;gap:.7rem;padding:0 .85rem;border:1px solid var(--axis-border);border-radius:.85rem;background:var(--axis-surface);transition:.18s}.field-control:focus-within{border-color:var(--axis-primary);box-shadow:0 0 0 3px rgba(99, 102, 241,.13)}.field-control.has-error{border-color:var(--axis-danger)}.field-control>i{color:var(--axis-muted)}.field-control input,.field-control select{min-width:0;min-height:3rem;flex:1;border:0;outline:0;color:var(--axis-text);background:transparent}.field-control button{border:0;color:var(--axis-muted);background:transparent;cursor:pointer}.field-error{margin:0;color:#fda4af;font-size:.7rem}.auth-submit{display:flex;min-height:3.15rem;align-items:center;justify-content:center;gap:.5rem;border:0;border-radius:.85rem;color:white;background:linear-gradient(100deg,var(--axis-primary-strong),#7355d9);box-shadow:0 12px 30px rgba(63,99,239,.25);font-size:.85rem;font-weight:800;text-decoration:none;cursor:pointer}.auth-submit:disabled{cursor:wait;opacity:.7}.auth-switch{margin-top:1.5rem;text-align:center;color:var(--axis-muted);font-size:.76rem}.auth-result{text-align:center}.result-icon{display:grid;width:4rem;height:4rem;margin:0 auto 1rem;place-items:center;border-radius:1.2rem;color:#6ee7b7;background:rgba(53,212,154,.12);font-size:1.7rem}.result-icon.is-error{color:#fda4af;background:rgba(251,113,133,.12)}.auth-result .auth-submit{margin-top:1.5rem}.spin{display:inline-block;animation:axis-spin .8s linear infinite}@keyframes axis-spin{to{transform:rotate(360deg)}}

/* Native dialogs replacing Bootstrap */
.axis-dialog{width:min(34rem,calc(100% - 2rem));max-height:calc(100dvh - 2rem);padding:0;overflow:auto;border:1px solid var(--axis-border);border-radius:1.1rem;color:var(--axis-text);background:var(--axis-surface);box-shadow:var(--axis-shadow)}.axis-dialog::backdrop{background:rgba(2,6,16,.76);backdrop-filter:blur(4px)}.axis-dialog-header{display:flex;align-items:center;justify-content:space-between;padding:1rem 1.15rem;border-bottom:1px solid var(--axis-border)}.axis-dialog-header h2{margin:0;font-size:1rem}.axis-dialog-body{padding:1.15rem}.axis-dialog-footer{display:flex;justify-content:flex-end;gap:.6rem;padding:1rem 1.15rem;border-top:1px solid var(--axis-border)}

@media(max-width:767px){
  body.app-shell{overflow:auto}.app-frame{height:auto;min-height:100dvh}.app-sidebar,.topbar{display:none!important}.app-content{overflow:visible}.main-content{min-height:100dvh;padding:1rem 1rem calc(6rem + env(safe-area-inset-bottom))}.mobile-nav{position:fixed;inset:auto .7rem calc(.65rem + env(safe-area-inset-bottom));z-index:50;display:grid;grid-template-columns:repeat(5,1fr);padding:.42rem;border:1px solid var(--axis-border);border-radius:1.15rem;background:color-mix(in srgb,var(--axis-surface) 92%,transparent);box-shadow:0 16px 45px rgba(0,0,0,.4);backdrop-filter:blur(16px)}.mobile-nav a,.mobile-nav button{display:flex;min-width:0;min-height:3.3rem;flex-direction:column;align-items:center;justify-content:center;gap:.2rem;border:0;border-radius:.8rem;color:var(--axis-muted);background:transparent;font-size:.75rem;line-height:1.1;text-decoration:none}.mobile-nav i{font-size:1.1rem}.mobile-nav .is-active{color:#dce4ff;background:rgba(99, 102, 241,.18)}.auth-layout{display:block}.auth-story{display:none}.auth-panel{min-height:100dvh;place-items:start center;padding:4rem 1.25rem 2rem}.auth-card{min-width:0;padding:1.25rem 0}.field-label-row{gap:1rem}.field-label-row a{white-space:nowrap}.toast-region{top:1rem}.mobile-menu-grid{grid-template-columns:repeat(3,1fr)}
}

/* Light theme — final overrides must stay after dark component rules. */
html[data-theme="light"] body.app-shell{background:#f3f6fb;color:#172033}
html[data-theme="light"] .app-sidebar{border-color:#ccd6e5;background:linear-gradient(180deg,#f8fafc,#e7edf6)}
html[data-theme="light"] .sidebar-footer,html[data-theme="light"] .sidebar-user{border-color:#ccd6e5;background:#f8fafc}
html[data-theme="light"] .nav-eyebrow{color:#64748b}
html[data-theme="light"] .nav-link{color:#52637d}
html[data-theme="light"] .nav-link:hover{color:#172033;background:#e3eaf5}
html[data-theme="light"] .nav-link.is-active{color:#2446a8;border-color:#91a9ff;background:linear-gradient(90deg,#dce5ff,#eef3ff)}
html[data-theme="light"] .topbar{border-color:#d7dfeb;background:rgba(248,250,252,.9)}
html[data-theme="light"] .topbar-search,html[data-theme="light"] .icon-button{color:#52637d;border-color:#d2dce9;background:#f8fafc}
html[data-theme="light"] .topbar-search:hover,html[data-theme="light"] .icon-button:hover{color:#2446a8;border-color:#91a9ff;background:#eef3ff}
html[data-theme="light"] .topbar-level-card{color:#f8fafc;border-color:#334155;background:linear-gradient(110deg,#27344a,#1e293b)}
html[data-theme="light"] .topbar-level-copy small,html[data-theme="light"] .topbar-level-percent{color:#cbd5e1}
html[data-theme="light"] .glass-panel,html[data-theme="light"] .axis-section,html[data-theme="light"] .axis-metric{color:#172033;border-color:#d6deea;background:#fff;box-shadow:0 10px 28px rgba(37,56,88,.07)}
html[data-theme="light"] .axis-task-row{color:#172033;border-color:#e1e7f0;background:#f8fafc}
html[data-theme="light"] .axis-task-row:hover{border-color:#c3cfdf;background:#eef3f8}
html[data-theme="light"] .axis-finance{color:#172033;border-color:#a7e4cf;background:linear-gradient(110deg,#ecfdf5,#fff)}
html[data-theme="light"] .axis-day-score>div{background:#fff}
html[data-theme="light"] .axis-dialog{color:#172033;border-color:#ccd6e5;background:#fff}
html[data-theme="light"] .axis-dialog-header,html[data-theme="light"] .axis-dialog-footer{border-color:#d6deea}

/* Loja e mochila */
.shop-page{display:grid;gap:1.5rem}.shop-hero{position:relative;overflow:hidden;display:flex;align-items:flex-end;justify-content:space-between;gap:2rem;padding:2rem;border:1px solid #4b3d1d;border-radius:1.5rem;background:radial-gradient(circle at 85% 15%,rgba(245,158,11,.2),transparent 34%),linear-gradient(135deg,#19170f,#111827 68%)}.shop-hero h1{max-width:42rem;margin:.25rem 0 .65rem;color:#fff;font-size:clamp(1.8rem,4vw,3rem);line-height:1.05}.shop-hero p:not(.shop-kicker){color:#9ca3af}.shop-kicker{color:#fbbf24!important;font-size:.7rem;font-weight:800;letter-spacing:.18em;text-transform:uppercase}.shop-hero-actions{display:flex;align-items:stretch;gap:.75rem}.shop-balance{min-width:10rem;padding:.8rem 1rem;border:1px solid #4b5563;border-radius:1rem;background:#03071280}.shop-balance span,.shop-balance strong{display:block}.shop-balance span{color:#9ca3af;font-size:.7rem}.shop-balance strong{margin-top:.15rem;color:#fbbf24;font-size:1.35rem}.shop-btn-primary,.shop-btn-secondary{display:inline-flex;align-items:center;justify-content:center;gap:.4rem;padding:.75rem 1rem;border-radius:.8rem;font-weight:800;transition:.18s}.shop-btn-primary{color:#fff;background:#6366f1}.shop-btn-primary:hover{background:#818cf8;transform:translateY(-1px)}.shop-btn-primary:disabled{cursor:not-allowed;opacity:.45;transform:none}.shop-btn-secondary{color:#d1d5db;border:1px solid #4b5563;background:transparent}.shop-main-tabs{display:flex;gap:.5rem;padding:.3rem;border:1px solid var(--axis-border);border-radius:1rem;background:var(--axis-surface);width:max-content}.shop-main-tabs button{display:flex;align-items:center;gap:.65rem;padding:.65rem 1rem;color:var(--axis-muted);border-radius:.7rem}.shop-main-tabs button small{padding:.15rem .4rem;border-radius:999px;background:#ffffff12;font-size:.65rem}.shop-main-tabs button.is-active{color:#fff;background:#6366f1}.shop-toolbar{display:grid;grid-template-columns:minmax(14rem,1fr) auto auto;gap:.75rem;margin-bottom:1rem}.shop-toolbar input,.shop-toolbar select,.shop-field input,.shop-field select,.shop-field textarea{width:100%;padding:.72rem .9rem;color:var(--axis-text);border:1px solid var(--axis-border);border-radius:.75rem;background:var(--axis-surface-2);outline:none}.shop-toolbar input:focus,.shop-toolbar select:focus,.shop-field input:focus,.shop-field select:focus,.shop-field textarea:focus{border-color:#6366f1;box-shadow:0 0 0 3px #6366f133}.shop-search{position:relative}.shop-search span{position:absolute;left:.9rem;top:.55rem;color:var(--axis-muted);font-size:1.2rem}.shop-search input{padding-left:2.5rem}.shop-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:1rem}.shop-card{display:flex;min-height:22rem;flex-direction:column;padding:1.15rem;border:1px solid var(--axis-border);border-radius:1.25rem;background:linear-gradient(160deg,var(--axis-surface),var(--axis-surface-2));box-shadow:0 12px 30px #00000020;transition:.2s}.shop-card:hover{border-color:#6366f1;transform:translateY(-3px);box-shadow:0 18px 40px #00000038}.shop-card.is-sold-out{opacity:.7}.shop-card-top{display:flex;align-items:start;justify-content:space-between}.shop-card-icon,.shop-inventory-icon,.shop-reward-preview-icon{display:grid;place-items:center;width:3.4rem;height:3.4rem;border:1px solid #d6a82f55;border-radius:1rem;background:#fbbf2415;font-size:1.8rem}.shop-card-actions{display:flex;gap:.25rem;opacity:.25;transition:.2s}.shop-card:hover .shop-card-actions,.shop-card-actions:focus-within{opacity:1}.shop-card-actions button,.shop-icon-button{display:grid;place-items:center;width:2rem;height:2rem;color:var(--axis-muted);border-radius:.55rem}.shop-card-actions button:hover,.shop-icon-button:hover{color:var(--axis-text);background:#ffffff10}.shop-card-copy{margin:1.2rem 0}.shop-card-copy h2{color:var(--axis-text);font-size:1.15rem}.shop-card-copy p{display:-webkit-box;overflow:hidden;margin-top:.4rem;color:var(--axis-muted);font-size:.82rem;line-height:1.45;-webkit-line-clamp:3;-webkit-box-orient:vertical}.shop-tags{display:flex;flex-wrap:wrap;gap:.35rem}.shop-tags span{padding:.25rem .45rem;color:var(--axis-muted);border:1px solid var(--axis-border);border-radius:999px;font-size:.62rem}.shop-tags .is-danger{color:#fca5a5;border-color:#ef444466}.shop-card-footer{display:flex;align-items:end;justify-content:space-between;gap:.7rem;margin-top:auto;padding-top:1rem;border-top:1px solid var(--axis-border)}.shop-card-footer strong{color:#fbbf24;font-size:1.5rem}.shop-card-footer span{margin-left:.2rem;color:#fbbf24;font-size:.7rem;font-weight:800}.shop-card-footer small{display:block;color:var(--axis-muted);font-size:.65rem}.shop-buy-button,.shop-use-button{padding:.65rem .8rem;color:#fff;border-radius:.7rem;background:#6366f1;font-size:.75rem;font-weight:800}.shop-buy-button:disabled{cursor:not-allowed;color:var(--axis-muted);background:var(--axis-border)}.shop-empty{grid-column:1/-1;display:grid;place-items:center;gap:.5rem;padding:4rem 1rem;text-align:center;color:var(--axis-muted);border:1px dashed var(--axis-border);border-radius:1.2rem}.shop-empty>span{font-size:2.5rem}.shop-empty h1,.shop-empty h2{color:var(--axis-text)}.shop-inventory-heading{display:flex;align-items:end;justify-content:space-between;gap:1rem;margin-bottom:1rem}.shop-inventory-heading h2{color:var(--axis-text);font-size:1.6rem}.shop-inventory-tabs{display:flex;gap:.35rem}.shop-inventory-tabs button{padding:.55rem .75rem;color:var(--axis-muted);border:1px solid transparent;border-radius:.7rem}.shop-inventory-tabs button.is-active{color:#a5b4fc;border-color:#6366f166;background:#6366f114}.shop-inventory-tabs span{font-size:.65rem}.shop-inventory-grid{display:grid;gap:.75rem}.shop-inventory-card{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:1rem;padding:1rem;border:1px solid var(--axis-border);border-radius:1rem;background:var(--axis-surface)}.shop-inventory-copy h3{color:var(--axis-text)}.shop-inventory-copy p{margin:.15rem 0;color:var(--axis-muted);font-size:.8rem}.shop-inventory-copy small{color:var(--axis-muted);font-size:.65rem}.shop-inventory-card.is-used{opacity:.68}.shop-used-badge{color:#86efac;font-size:.75rem;font-weight:800}.shop-modal{width:min(34rem,100%);max-height:calc(100dvh - 2rem);overflow:auto;color:var(--axis-text);border:1px solid var(--axis-border);border-radius:1.25rem;background:var(--axis-surface);box-shadow:0 25px 70px #000b}.shop-modal-header,.shop-modal-footer{display:flex;align-items:center;justify-content:space-between;gap:.75rem;padding:1rem 1.2rem;border-bottom:1px solid var(--axis-border)}.shop-modal-header h3,.shop-purchase-modal h3{font-size:1.25rem}.shop-modal-body{display:grid;gap:.9rem;padding:1.2rem}.shop-modal-footer{justify-content:flex-end;border-top:1px solid var(--axis-border);border-bottom:0}.shop-field{display:grid;gap:.35rem}.shop-field>label{color:var(--axis-muted);font-size:.7rem;font-weight:800;letter-spacing:.08em;text-transform:uppercase}.shop-field small{color:var(--axis-muted);font-size:.65rem}.shop-form-error{color:#fca5a5;font-size:.72rem}.shop-icon-picker{display:grid;grid-template-columns:repeat(5,1fr);gap:.5rem}.shop-icon-option input{position:absolute;opacity:0;pointer-events:none}.shop-icon-option span{display:grid;place-items:center;height:3rem;cursor:pointer;border:1px solid var(--axis-border);border-radius:.75rem;background:var(--axis-surface-2);font-size:1.35rem;transition:.15s}.shop-icon-option input:checked+span{border-color:#6366f1;background:#6366f120;box-shadow:0 0 0 2px #6366f133}.shop-purchase-modal{padding:1.5rem;text-align:center}.shop-purchase-modal .shop-reward-preview-icon{margin:0 auto 1rem}.shop-purchase-description{margin:.5rem auto 1rem;max-width:26rem;color:var(--axis-muted)}.shop-purchase-summary{display:grid;gap:.5rem;margin:1rem 0;text-align:left}.shop-purchase-summary span{display:flex;justify-content:space-between;padding:.7rem;border-radius:.7rem;background:var(--axis-surface-2);font-size:.8rem}.shop-purchase-summary strong{color:#fbbf24}.shop-purchase-summary strong.is-negative{color:#f87171}.shop-purchase-modal .shop-modal-footer{padding:1rem 0 0}
@media(max-width:1100px){.shop-hero{align-items:stretch;flex-direction:column}.shop-hero-actions{align-self:flex-start}.shop-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}@media(max-width:850px){.shop-toolbar{grid-template-columns:1fr}}@media(max-width:700px){.shop-hero{padding:1.25rem}.shop-hero-actions{align-self:stretch;flex-direction:column}.shop-grid{grid-template-columns:1fr}.shop-main-tabs{width:100%}.shop-main-tabs button{justify-content:center;flex:1}.shop-inventory-heading{align-items:stretch;flex-direction:column}.shop-inventory-tabs{display:grid;grid-template-columns:1fr 1fr}.shop-inventory-card{grid-template-columns:auto 1fr}.shop-use-button,.shop-used-badge{grid-column:1/-1;width:100%;text-align:center}.shop-card-actions{opacity:1}}
html[data-theme="light"] .shop-hero{border-color:#e4c66e;background:radial-gradient(circle at 85% 15%,#fef3c7,transparent 35%),linear-gradient(135deg,#fffdf5,#f8fafc)}html[data-theme="light"] .shop-hero h1{color:#172033}html[data-theme="light"] .shop-balance{border-color:#d5c18c;background:#fff}html[data-theme="light"] .shop-modal{background:#fff}html[data-theme="light"] .shop-card{box-shadow:0 10px 25px #25385812}
html[data-theme="light"] .finance-form input,html[data-theme="light"] .finance-form select,html[data-theme="light"] .finance-form textarea,html[data-theme="light"] .profile-field input,html[data-theme="light"] .profile-field textarea{color:#172033;border-color:#c8d3e2;background:#f8fafc}
html[data-theme="light"] .bg-slate-900,html[data-theme="light"] .bg-slate-900\/70{color:#172033!important;background:#f8fafc!important}
html[data-theme="light"] .border-slate-700,html[data-theme="light"] .border-slate-800{border-color:#cbd5e1!important}
html[data-theme="light"] .divide-slate-800>:not(:last-child){border-color:#d7dfeb!important}
html[data-theme="light"] .text-gray-300,html[data-theme="light"] .text-gray-400,html[data-theme="light"] .text-slate-400{color:#52637d!important}
html[data-theme="light"] .text-gray-500,html[data-theme="light"] .text-gray-600,html[data-theme="light"] .text-slate-500{color:#64748b!important}
html[data-theme="light"] .axis-primary-action{color:#fff}
html[data-theme="light"] .axis-hero { color: var(--text-primary); }
html[data-theme="light"] .axis-hero .text-white { color: var(--text-primary); }
html[data-theme="light"] .axis-primary-action .text-white{color:#fff!important}
html[data-theme="light"] input::placeholder,html[data-theme="light"] textarea::placeholder{color:#8492a8}
html[data-theme="light"] .ui-input:focus{color:#172033;background:#fff}
html[data-theme="light"] .habit-modal-card{color:#172033;border-color:#c8d3e2;background:linear-gradient(180deg,#fff,#f4f7fb)}
html[data-theme="light"] .habit-panel{color:#172033;border-color:#d2dce9;background:#f8fafc}
html[data-theme="light"] .habit-modal-title,html[data-theme="light"] .habit-month-title,html[data-theme="light"] .habit-stat-value{color:#172033}
html[data-theme="light"] .habit-nav-btn,html[data-theme="light"] .habit-day-btn,html[data-theme="light"] .habit-year-cell,html[data-theme="light"] .habit-year-cell.level-0,html[data-theme="light"] .habit-year-cell.level-1,html[data-theme="light"] .habit-year-cell.level-2,html[data-theme="light"] .habit-year-cell.level-3{color:#334155;border-color:#c8d3e2;background:#fff}
html[data-theme="light"] .habit-day-btn.done{color:#065f46;border-color:#34d399;background:#d1fae5}
html[data-theme="light"] .habit-stat-line{color:#475569;border-color:#d7dfeb}
html[data-theme="light"] .habit-close-btn{color:#475569;border-color:#c8d3e2;background:#eef2f7}
html[data-theme="light"] .habit-create-button{color:#fff!important;background:#6366f1!important}
html[data-theme="light"] .habit-create-button:hover{background:#4f46e5!important}
html[data-theme="light"] .habit-table-row:hover{background:#f1f5f9!important}
html[data-theme="light"] .habit-info-cell{color:#172033;border-color:#cbd5e1!important;background:#f8fafc!important}
html[data-theme="light"] .habit-day-cell{border-color:#cbd5e1!important;background:#fff!important}
html[data-theme="light"] .habit-title-button{color:#172033!important}
html[data-theme="light"] .habit-title-button:hover{color:#4f46e5!important}
html[data-theme="light"] .habit-check-button.bg-gray-800,html[data-theme="light"] .habit-check-button.bg-slate-900{color:#52637d!important;border:1px solid #cbd5e1;background:#eef2f7!important}
html[data-theme="light"] .habit-check-button.bg-gray-800:hover,html[data-theme="light"] .habit-check-button.bg-slate-900:hover{color:#4f46e5!important;border-color:#93a8c4;background:#e2e8f0!important}
html[data-theme="light"] .habit-check-button.bg-green-500{color:#fff!important;border:1px solid #059669;background:#10b981!important}
html[data-theme="light"] table tbody tr:hover{background:#f1f5f9!important}
html[data-theme="light"] table tbody tr>td{border-color:#cbd5e1!important;background:#fff!important}
html[data-theme="light"] table tbody tr>td:first-child{color:#172033;background:#f8fafc!important}
html[data-theme="light"] table tbody tr>td:first-child button.text-white{color:#172033!important}
html[data-theme="light"] table tbody tr>td:first-child button.text-white:hover{color:#4f46e5!important}

/* Shared utility colors: keep legacy pages readable in light mode. */
html[data-theme="light"] .bg-gray-900,html[data-theme="light"] .bg-gray-900\/70,html[data-theme="light"] .bg-gray-900\/40,html[data-theme="light"] .bg-gray-900\/20{color:#172033!important;background:#f8fafc!important}
html[data-theme="light"] .bg-gray-800,html[data-theme="light"] .bg-gray-800\/80,html[data-theme="light"] .bg-gray-800\/50{color:#334155!important;background:#e8eef6!important}
html[data-theme="light"] .bg-gray-700,html[data-theme="light"] .bg-slate-700{color:#172033!important;background:#dce5f0!important}
html[data-theme="light"] .border-gray-700,html[data-theme="light"] .border-gray-800{border-color:#cbd5e1!important}
html[data-theme="light"] .text-white,html[data-theme="light"] .text-gray-100,html[data-theme="light"] .text-gray-200,html[data-theme="light"] .text-slate-100,html[data-theme="light"] .text-slate-200,html[data-theme="light"] .text-slate-300{color:#172033!important}
html[data-theme="light"] :is(.bg-purple-600,.bg-purple-500,.bg-indigo-600,.bg-indigo-500,.bg-violet-600,.bg-violet-500,.bg-rose-600,.bg-rose-500,.bg-red-600,.bg-red-500,.bg-pink-600,.bg-pink-500,.bg-fuchsia-600,.bg-fuchsia-500,.bg-teal-600,.bg-teal-500,.bg-orange-500,.bg-orange-600) .text-white,html[data-theme="light"] :is(.bg-purple-600,.bg-purple-500,.bg-indigo-600,.bg-indigo-500,.bg-violet-600,.bg-violet-500,.bg-rose-600,.bg-rose-500,.bg-red-600,.bg-red-500,.bg-pink-600,.bg-pink-500,.bg-fuchsia-600,.bg-fuchsia-500,.bg-teal-600,.bg-teal-500,.bg-orange-500,.bg-orange-600).text-white{color:#fff!important}
html[data-theme="light"] .bg-blue-600,html[data-theme="light"] .bg-blue-500,html[data-theme="light"] .bg-cyan-500,html[data-theme="light"] .bg-emerald-500,html[data-theme="light"] .bg-green-500{color:#fff!important}
html[data-theme="light"] .bg-yellow-500,html[data-theme="light"] .bg-amber-500{color:#172033!important}
html[data-theme="light"] .mobile-nav .is-active{color:#2446a8;background:#dce5ff}
html[data-theme="light"] .ui-alert{color:#2446a8;background:#eef3ff}
html[data-theme="light"] .ui-alert-success{color:#065f46;background:#ecfdf5}
html[data-theme="light"] .text-emerald-200,html[data-theme="light"] .text-emerald-300,html[data-theme="light"] .text-emerald-400,html[data-theme="light"] .text-green-300,html[data-theme="light"] .text-green-400{color:#059669!important}
html[data-theme="light"] .text-teal-200,html[data-theme="light"] .text-teal-300,html[data-theme="light"] .text-teal-400{color:#0d9488!important}
html[data-theme="light"] .text-blue-200,html[data-theme="light"] .text-blue-300{color:#6366f1!important}
html[data-theme="light"] .text-amber-300,html[data-theme="light"] .text-yellow-300{color:#d97706!important}
html[data-theme="light"] .text-purple-300,html[data-theme="light"] .text-violet-300{color:#4f46e5!important}
html[data-theme="light"] .text-rose-300,html[data-theme="light"] .text-red-300{color:#e11d48!important}
html[data-theme="light"] [class*="bg-emerald-500/10"],html[data-theme="light"] [class*="bg-emerald-500/15"],html[data-theme="light"] [class*="bg-emerald-500/20"],html[data-theme="light"] [class*="bg-emerald-500/25"]{background-color:#ecfdf5!important;border-color:#a7f3d0!important;color:#065f46!important}
html[data-theme="light"] [class*="bg-emerald-500/15"]:hover,html[data-theme="light"] [class*="bg-emerald-500/20"]:hover,html[data-theme="light"] [class*="bg-emerald-500/25"]:hover{background-color:#d1fae5!important}
html[data-theme="light"] .ui-alert-error,html[data-theme="light"] .ui-alert-danger{color:#9f1239;background:#fff1f2}
html[data-theme="light"] .auth-panel,html[data-theme="light"] .auth-page{color:#172033;background:#f4f7fb}
html[data-theme="light"] .auth-card .field-control{color:#172033;border-color:#cbd5e1;background:#fff}
html[data-theme="light"] .axis-toast{color:#172033;border-color:#cbd5e1;background:#fff}
html[data-theme="light"] .axis-primary-action,html[data-theme="light"] .axis-primary-action .text-white,html[data-theme="light"] .topbar-level-card,html[data-theme="light"] .topbar-level-card .text-white,html[data-theme="light"] .auth-story,html[data-theme="light"] .auth-story .text-white{color:#fff!important}

html[data-theme="light"] .shop-btn-secondary { color: #475569; border-color: #cbd5e1; }
html[data-theme="light"] .axis-mini-progress { background: #e2e8f0; }
html[data-theme="light"] .topbar-level-progress { background: #e2e8f0; }

/* Segmented Controls & Tab Highlights — use inherited text color, not forced white */
.segmented-control button.is-active,
.segmented-control a.is-active {
  color: var(--text-primary) !important;
}

.segmented-control button.is-active *,
.segmented-control a.is-active * {
  color: var(--text-primary) !important;
}

/* When a tab has an explicit bg color class, ensure text is white for contrast */
.segmented-control button[class*="bg-"]:not(.is-active),
.segmented-control a[class*="bg-"]:not(.is-active),
.mode-tab-btn[class*="bg-"] {
  color: #ffffff !important;
}

.segmented-control button[class*="bg-"]:not(.is-active) *,
.segmented-control a[class*="bg-"]:not(.is-active) *,
.mode-tab-btn[class*="bg-"] * {
  color: #ffffff !important;
}

/* Theme Selector Buttons (Profile) */
.theme-choice-btn {
  cursor: pointer;
  border: 1px solid var(--axis-border, #1e293b);
  background-color: var(--axis-surface, #0f172a);
  color: var(--axis-muted, #94a3b8);
  transition: all 0.2s ease;
}

.theme-choice-btn:hover {
  border-color: var(--axis-primary, #818cf8);
  color: var(--axis-text, #f8fafc);
}

.theme-choice-btn.is-active {
  border-color: #818cf8 !important;
  background-color: rgba(129, 140, 248, 0.15) !important;
  color: var(--axis-text, #f8fafc) !important;
  box-shadow: 0 0 0 2px rgba(129, 140, 248, 0.35);
}

html[data-theme="light"] .theme-choice-btn {
  border-color: #e2e8f0;
  background-color: #f8fafc;
  color: #475569;
}

html[data-theme="light"] .theme-choice-btn:hover {
  border-color: #818cf8;
  color: #0f172a;
}

html[data-theme="light"] .theme-choice-btn.is-active {
  border-color: #6366f1 !important;
  background-color: #eff6ff !important;
  color: #4f46e5 !important;
  box-shadow: 0 0 0 2px rgba(99, 102, 241, 0.25);
}


/* ==========================================================================
   TELA HOJE — UMA LISTA, NA ORDEM DA URGÊNCIA
   ==========================================================================
   Fica em style.css de propósito: três frentes estão acrescentando blocos ao
   fim de axis-theme.css ao mesmo tempo, e escrita simultânea no mesmo arquivo
   perde conteúdo.
   ========================================================================== */
.hoje-acoes { display: grid; gap: .5rem; margin: 0 0 1.5rem; padding: 0; list-style: none; }
.hoje-acao {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: .75rem; padding: .85rem 1rem;
  border: 1px solid var(--border-subtle); border-left: 3px solid var(--border-medium);
  border-radius: var(--radius-xl); background: var(--bg-surface);
}
/* A cor da borda é o custo de ignorar: vermelho cobra juros, âmbar cobra prazo. */
.hoje-acao[data-tone="danger"], .hoje-acao[data-tone="critical"] { border-left-color: var(--color-rose-500, #f43f5e); }
.hoje-acao[data-tone="warning"] { border-left-color: var(--color-amber-500, #f59e0b); }
.hoje-acao[data-tone="info"] { border-left-color: var(--color-brand-500, #6366f1); }
.hoje-acao-copy { display: grid; gap: .1rem; min-width: 0; }
.hoje-acao-copy strong { color: var(--text-primary); font-size: .9375rem; font-weight: 600; }
.hoje-acao-copy span { color: var(--text-secondary); font-size: .8125rem; }

.hoje-vazio {
  display: grid; gap: .15rem; margin-bottom: 1.5rem; padding: 1.25rem;
  border: 1px solid color-mix(in srgb, var(--color-emerald-500, #10b981) 30%, var(--border-subtle));
  border-radius: var(--radius-2xl); background: var(--bg-surface);
}
.hoje-vazio strong { color: var(--text-primary); }
.hoje-vazio span { color: var(--text-secondary); font-size: .875rem; }

/* Contexto não compete com o que pede ação: fica embaixo, numa faixa discreta. */
.hoje-resumo { padding-top: 1.25rem; border-top: 1px solid var(--border-subtle); }
.hoje-resumo h2 {
  margin-bottom: .75rem; color: var(--text-tertiary); font-size: .75rem;
  font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
}
.hoje-resumo dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin: 0; }
.hoje-resumo dt { color: var(--text-tertiary); font-size: .75rem; font-weight: 600; }
.hoje-resumo dd { margin: .1rem 0 0; color: var(--text-primary); font-size: 1.25rem; font-weight: 700; }
.hoje-resumo-nota { margin: .15rem 0 0; color: var(--text-tertiary); font-size: .6875rem; }

@media (max-width: 640px) {
  .hoje-resumo dl { gap: .5rem; }
  .hoje-resumo dd { font-size: 1.05rem; }
}

/* Linhas mais baixas: com dados de verdade (7 tarefas atrasadas, 8 hábitos) a
   lista virava uma parede de 14 linhas altas, e quem rola para ler tudo acaba
   não lendo nada. */
.hoje-acao { padding: .65rem .85rem; }
.hoje-acao-copy strong { font-size: .9rem; }
.hoje-acao-copy span { font-size: .75rem; }

/* Hábitos do dia numa linha só: uma ficha por hábito, cada uma com o próprio
   toque. Antes eram oito linhas idênticas dizendo "ainda não foi marcado hoje". */
.hoje-acao.is-grupo { align-items: flex-start; flex-direction: column; gap: .6rem; }
.hoje-habitos { display: flex; flex-wrap: wrap; gap: .4rem; width: 100%; }
.hoje-habito {
  display: inline-flex; align-items: center; gap: .4rem;
  min-height: 32px; padding: .35rem .7rem;
  color: var(--text-secondary); border: 1px solid var(--border-subtle);
  border-radius: 999px; background: var(--bg-surface-elevated);
  font-size: .8125rem; font-weight: 600;
}
.hoje-habito:hover { color: var(--text-primary); border-color: var(--color-brand-500, #6366f1); }
.hoje-habito i { color: var(--text-tertiary); font-size: .8rem; }
.hoje-habito:hover i { color: var(--color-emerald-400, #34d399); }
