:root {
  font-family: "DM Sans", sans-serif;
  color-scheme: dark;
  color: #f1efff;
  background: #080811;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  --blue: #7657ff;
  --blue-dark: #6243e8;
  --ink: #f1efff;
  --muted: #a19db8;
  --line: #242238;
  --surface: #11111d;
  --green: #15936b;
  --red: #d65b65;
  --shadow: 0 8px 26px rgba(0, 0, 0, .2);
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
.app-shell { min-height: 100vh; }
.sidebar { position: fixed; inset: 0 auto 0 0; width: 248px; display: flex; flex-direction: column; padding: 27px 16px 18px; background: #fff; border-right: 1px solid var(--line); z-index: 3; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); padding: 0 8px; }
.brand-image { display: block; width: 202px; height: auto; }
.brand-mark { width: 34px; height: 34px; display: grid; place-items: center; background: var(--blue); color: #fff; border-radius: 10px; font: 800 17px Manrope, sans-serif; letter-spacing: -1px; }
.brand-mark span { color: #b6e4ff; }
.brand-name { font: 800 17px Manrope, sans-serif; letter-spacing: -.5px; }
.brand-name b { color: var(--blue); font-size: 11px; letter-spacing: 1px; margin-left: 2px; }
.workspace-label { margin: 47px 8px 14px; color: #a0aaba; font-size: 10px; font-weight: 700; letter-spacing: 1.4px; }
.main-nav { display: grid; gap: 5px; }
.nav-item { width: 100%; display: flex; align-items: center; gap: 13px; padding: 11px 12px; border: 0; border-radius: 8px; background: transparent; color: #728096; text-align: left; font-weight: 600; font-size: 13px; transition: .15s ease; }
.nav-item:hover { background: #f5f8fc; color: var(--ink); }
.nav-item.active { background: #edf5fc; color: var(--blue); }
.nav-icon { width: 19px; text-align: center; font-size: 17px; }
.sidebar-bottom { margin-top: auto; }
.privacy-note { display: flex; align-items: flex-start; gap: 10px; padding: 12px 10px; margin-bottom: 15px; border: 1px solid #e8eff7; border-radius: 9px; background: #f9fbfd; }
.privacy-icon { color: var(--blue); font-size: 15px; }
.privacy-note b, .privacy-note small { display: block; }
.privacy-note b { font-size: 11px; margin: 1px 0 4px; }
.privacy-note small { color: var(--muted); font-size: 10px; line-height: 1.45; }
.user-row { display: flex; align-items: center; gap: 9px; padding: 13px 3px 0; border-top: 1px solid var(--line); }
.avatar { flex: 0 0 33px; height: 33px; display: grid; place-items: center; border-radius: 50%; color: var(--blue); background: #e8f3fc; font-weight: 700; font-size: 11px; }
.user-details { min-width: 0; flex: 1; }
.user-details b, .user-details small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-details b { font-size: 11px; font-weight: 600; }
.user-details small { color: var(--muted); font-size: 10px; margin-top: 3px; }
.icon-button { border: 0; background: transparent; color: #8996a9; border-radius: 6px; padding: 6px; }
.icon-button:hover { background: #f1f5f9; color: var(--blue); }
.main-content { min-height: 100vh; margin-left: 248px; display: flex; flex-direction: column; padding: 0 42px; }
.topbar { height: 76px; flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.breadcrumb { display: flex; align-items: center; gap: 10px; color: #8995a8; font-size: 12px; }
.breadcrumb b { color: var(--ink); font-weight: 600; }
.crumb-sep { color: #c0c9d4; }
.topbar-actions { display: flex; align-items: center; gap: 18px; }
.today-label { color: #8d98a9; font-size: 11px; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: 6px; border: 1px solid transparent; border-radius: 7px; padding: 10px 14px; font-size: 12px; font-weight: 700; transition: .15s ease; }
.button-primary { background: var(--blue); color: #fff; box-shadow: 0 3px 8px #035ba423; }
.button-primary:hover { background: var(--blue-dark); transform: translateY(-1px); }
.button-secondary { border-color: var(--line); background: #fff; color: #506078; }
.button-secondary:hover { border-color: #cbd9e7; color: var(--blue); }
.button-danger { color: var(--red); border-color: #f3dfe1; background: #fff; }
.view-root { width: 100%; max-width: 1360px; margin: 0 auto; padding: 31px 0 42px; flex: 1; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 18px; margin-bottom: 24px; }
.page-heading h1 { margin: 0; font: 800 25px Manrope, sans-serif; letter-spacing: -.7px; }
.page-heading p { margin: 7px 0 0; color: var(--muted); font-size: 12px; }
.eyebrow { color: var(--blue); font-size: 10px; font-weight: 700; letter-spacing: 1.25px; }
.muted { color: var(--muted); }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 19px; }
.stat-card, .panel, .project-card, .report-card { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; box-shadow: var(--shadow); }
.stat-card { min-height: 123px; padding: 17px 18px; }
.stat-top { display: flex; align-items: center; justify-content: space-between; color: #78869a; font-size: 11px; font-weight: 600; }
.stat-icon { width: 28px; height: 28px; display: grid; place-items: center; border-radius: 8px; background: #edf5fc; color: var(--blue); font-size: 14px; }
.stat-value { display: block; margin-top: 13px; font: 800 22px Manrope, sans-serif; letter-spacing: -.5px; }
.stat-note { margin-top: 3px; color: #9aa5b4; font-size: 10px; }
.overview-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(270px, .85fr); gap: 16px; }
.panel { overflow: hidden; }
.panel-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; border-bottom: 1px solid #f0f3f7; }
.panel-header h2 { margin: 0; font: 700 13px Manrope, sans-serif; }
.panel-header p { margin: 4px 0 0; color: #9aa5b4; font-size: 10px; }
.inline-link { padding: 4px 0; border: 0; background: none; color: var(--blue); font-size: 10px; font-weight: 700; }
.project-list { display: grid; }
.project-row { display: flex; gap: 12px; align-items: center; padding: 14px 18px; border-bottom: 1px solid #f1f3f6; }
.project-row:last-child { border-bottom: 0; }
.project-color { width: 34px; height: 34px; flex: 0 0 34px; display: grid; place-items: center; border-radius: 9px; color: var(--blue); background: #edf5fc; font-size: 14px; font-weight: 700; }
.project-row-main { min-width: 0; flex: 1; }
.project-row-title { display: flex; justify-content: space-between; gap: 8px; }
.project-row-title b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11px; }
.project-row-title span { flex: 0 0 auto; color: #8a96a7; font-size: 9px; }
.progress-track { height: 4px; overflow: hidden; margin-top: 9px; border-radius: 5px; background: #edf1f5; }
.progress-track span { display: block; height: 100%; border-radius: inherit; background: #3586c5; }
.task-list { padding: 2px 17px 10px; }
.task-row { display: flex; align-items: flex-start; gap: 9px; padding: 11px 0; border-bottom: 1px solid #f1f3f6; }
.task-row:last-child { border-bottom: 0; }
.task-check { width: 15px; height: 15px; flex: 0 0 15px; margin-top: 1px; accent-color: var(--blue); cursor: pointer; }
.task-main { min-width: 0; flex: 1; }
.task-main b { display: block; overflow-wrap: anywhere; font-size: 10px; font-weight: 600; }
.task-main small { display: block; margin-top: 4px; color: #98a3b2; font-size: 9px; }
.task-date { flex: 0 0 auto; color: #8793a4; font-size: 9px; white-space: nowrap; }
.task-date.overdue { color: var(--red); }
.activity-panel { margin-top: 16px; }
.activity-items { display: flex; gap: 12px; padding: 15px 18px; align-items: center; color: #8995a6; font-size: 10px; }
.activity-dot { width: 6px; height: 6px; background: #60a6da; border-radius: 50%; }
.empty-state { padding: 29px 18px; text-align: center; color: #929eae; font-size: 11px; }
.empty-state b { display: block; margin-bottom: 5px; color: #596980; font-size: 12px; }
.section-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin: 0 0 16px; }
.search-input { min-width: 210px; flex: 1; border: 1px solid var(--line); border-radius: 7px; padding: 9px 11px; outline: 0; background: #fff; font-size: 11px; }
.search-input:focus, input:focus, select:focus, textarea:focus { border-color: #91b9d8; box-shadow: 0 0 0 3px #dcecf8; outline: 0; }
.filter-select { border: 1px solid var(--line); border-radius: 7px; padding: 9px 11px; background: #fff; color: #637187; font-size: 11px; }
.cards-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.project-card { padding: 17px; }
.card-top { display: flex; justify-content: space-between; align-items: center; }
.card-title-wrap { min-width: 0; display: flex; align-items: center; gap: 10px; }
.card-title-wrap h3 { margin: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 700 13px Manrope, sans-serif; }
.status-pill, .priority-pill { display: inline-flex; align-items: center; gap: 4px; border-radius: 20px; padding: 4px 7px; background: #f1f4f7; color: #6f7c8e; font-size: 9px; font-weight: 600; white-space: nowrap; }
.status-in-progress, .status-planning { background: #eaf4fb; color: #2874aa; }
.status-completed { background: #e8f7f1; color: #16835d; }
.status-on-hold { background: #fff5e7; color: #aa781f; }
.status-cancelled { background: #fceef0; color: #ba5660; }
.project-description { min-height: 30px; margin: 14px 0 16px; color: #8793a4; font-size: 10px; line-height: 1.55; }
.card-metrics { display: flex; gap: 20px; margin: 14px 0 15px; }
.card-metrics span { color: #98a3b1; font-size: 9px; }
.card-metrics b { display: block; margin-top: 5px; color: #40516a; font-size: 11px; font-weight: 600; }
.card-actions { display: flex; align-items: center; gap: 7px; margin-top: 13px; padding-top: 12px; border-top: 1px solid #f0f3f6; }
.small-button { border: 0; border-radius: 5px; padding: 6px 8px; background: #f5f8fb; color: #5e6f84; font-size: 9px; font-weight: 600; }
.small-button:hover { color: var(--blue); background: #edf5fc; }
.small-button.delete:hover { color: var(--red); background: #fff2f2; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 10px; background: #fff; box-shadow: var(--shadow); }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 12px 16px; background: #fafbfd; border-bottom: 1px solid var(--line); color: #909bad; font-size: 9px; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; }
td { padding: 13px 16px; border-bottom: 1px solid #f0f3f7; color: #596980; font-size: 10px; }
tr:last-child td { border-bottom: 0; }
td strong { color: #30425a; font-size: 10px; }
.amount-positive { color: var(--green); font-weight: 700; }
.amount-negative { color: var(--red); font-weight: 700; }
.table-actions { display: flex; gap: 5px; }
.summary-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.summary-box { padding: 15px 17px; background: #fff; border: 1px solid var(--line); border-radius: 9px; }
.summary-box span { color: #8995a5; font-size: 10px; }
.summary-box b { display: block; margin-top: 8px; font: 700 18px Manrope, sans-serif; }
.report-layout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(270px, .8fr); gap: 15px; }
.bar-chart { display: flex; gap: 11px; align-items: flex-end; height: 180px; padding: 16px 18px 0; }
.bar-month { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: flex-end; gap: 8px; height: 100%; }
.bar-pair { display: flex; align-items: flex-end; gap: 3px; width: 100%; max-width: 34px; height: 135px; }
.bar { min-width: 6px; flex: 1; border-radius: 4px 4px 0 0; background: #4a96cf; }
.bar.expense { background: #d6e2ec; }
.bar-label { color: #9aa5b3; font-size: 8px; }
.chart-legend { display: flex; justify-content: center; gap: 16px; padding: 13px 10px 16px; color: #8793a4; font-size: 9px; }
.legend-key { display: inline-flex; align-items: center; gap: 5px; }
.legend-dot { width: 7px; height: 7px; border-radius: 2px; background: #4a96cf; }
.legend-dot.expense { background: #d6e2ec; }
.report-project-row { padding: 12px 17px; border-bottom: 1px solid #f1f3f6; }
.report-project-row:last-child { border-bottom: 0; }
.report-project-row div { display: flex; justify-content: space-between; gap: 8px; color: #596980; font-size: 10px; }
.report-project-row b { font-weight: 600; }
.report-project-row small { display: block; margin-top: 5px; color: #9aa5b3; font-size: 9px; }
.app-footer { padding: 14px 0 18px; color: #a1aab8; font-size: 9px; }
.app-footer span { margin: 0 5px; color: #c7ced7; }
.notice { position: fixed; top: 88px; right: 36px; z-index: 5; max-width: 380px; padding: 12px 16px; border: 1px solid #d5ecdf; border-radius: 8px; background: #f1fbf5; color: #24744d; font-size: 11px; box-shadow: var(--shadow); }
.notice.error { border-color: #f1d9dc; background: #fff6f6; color: #a8404b; }
.auth-screen { min-height: 100vh; display: grid; grid-template-columns: minmax(370px, .9fr) minmax(400px, 1.1fr); background: #fff; }
.auth-card { width: min(390px, calc(100% - 48px)); align-self: center; justify-self: center; }
.auth-brand { padding: 0; margin-bottom: 52px; }
.auth-brand .brand-image { width: 245px; max-width: 100%; }
.auth-card .eyebrow { margin-bottom: 12px; }
.auth-card h1 { margin: 0; font: 800 28px Manrope, sans-serif; letter-spacing: -.8px; }
.auth-card > .muted { margin: 9px 0 26px; font-size: 12px; }
.stack-form { display: grid; gap: 15px; }
.stack-form label, .record-form label { display: grid; gap: 7px; color: #53637a; font-size: 10px; font-weight: 700; }
.stack-form input, .record-form input, .record-form select, .record-form textarea { width: 100%; padding: 11px 12px; border: 1px solid #e2e8ef; border-radius: 7px; background: #fff; color: var(--ink); font-size: 11px; }
.button-wide { width: 100%; margin-top: 4px; padding: 12px; }
.text-button { display: block; margin: 18px auto 0; border: 0; background: none; color: var(--blue); font-size: 10px; font-weight: 600; }
.form-error { min-height: 15px; margin: 12px 0 0; color: var(--red); font-size: 10px; }
.auth-aside { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: center; padding: 70px 12%; background: #080811; }
.auth-aside::before { position: absolute; content: ""; width: 440px; height: 440px; top: -160px; right: -120px; border: 1px solid #27203f; border-radius: 50%; box-shadow: 0 0 0 45px #080811, 0 0 0 46px #27203f, 0 0 0 105px #080811, 0 0 0 106px #27203f; }
.brand-banner { position: relative; display: block; width: min(100%, 560px); height: auto; margin: 0 0 25px -10px; }
.auth-aside > *:not(.aside-orb) { position: relative; }
.auth-aside h2 { margin: 10px 0 13px; color: #f1edff; font: 800 clamp(30px, 4vw, 46px) Manrope, sans-serif; line-height: 1.15; letter-spacing: -1.5px; }
.auth-aside > p:not(.eyebrow) { max-width: 340px; color: #aaa5c4; font-size: 13px; line-height: 1.7; }
.aside-foot { display: flex; align-items: center; gap: 8px; margin-top: 48px; color: #aaa5c4; font-size: 10px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: #36ae7d; box-shadow: 0 0 0 4px #15392e; }
.record-dialog { width: min(480px, calc(100% - 32px)); max-height: min(90vh, 760px); padding: 0; border: 0; border-radius: 12px; color: var(--ink); box-shadow: 0 24px 80px #10243b38; }
.record-dialog::backdrop { background: #14243a80; backdrop-filter: blur(2px); }
.dialog-header { display: flex; justify-content: space-between; align-items: center; padding: 19px 22px; border-bottom: 1px solid var(--line); }
.dialog-header h2 { margin: 0; font: 800 17px Manrope, sans-serif; }
.dialog-close { border: 0; background: none; color: #8995a5; font-size: 20px; }
.record-form { display: grid; gap: 13px; max-height: calc(90vh - 70px); overflow: auto; padding: 18px 22px 22px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.record-form textarea { min-height: 76px; resize: vertical; }
.form-hint { color: #95a0ae; font-size: 9px; font-weight: 400; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 5px; }
.dialog-error { color: var(--red); font-size: 10px; }
@media (max-width: 1050px) {
  .main-content { padding: 0 25px; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .cards-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .sidebar { position: fixed; inset: auto 0 0; width: auto; height: 65px; padding: 5px 8px; border: 0; border-top: 1px solid var(--line); }
  .sidebar > .brand, .workspace-label, .sidebar-bottom { display: none; }
  .main-nav { height: 100%; display: flex; justify-content: space-around; gap: 2px; }
  .nav-item { width: auto; min-width: 53px; padding: 6px 8px; flex-direction: column; justify-content: center; gap: 2px; font-size: 8px; }
  .nav-icon { font-size: 15px; }
  .main-content { margin: 0; padding: 0 17px 66px; }
  .topbar { height: 62px; }
  .today-label { display: none; }
  .topbar-actions { gap: 0; }
  .button { padding: 9px 10px; }
  .view-root { padding-top: 24px; }
  .overview-grid, .report-layout { grid-template-columns: 1fr; }
  .cards-grid { grid-template-columns: 1fr; }
  .auth-screen { grid-template-columns: 1fr; }
  .auth-card { padding: 45px 0; }
  .auth-brand { margin-bottom: 40px; }
  .auth-aside { display: none; }
  .notice { top: 68px; right: 14px; left: 14px; max-width: unset; }
}
@media (max-width: 440px) {
  .stats-grid { gap: 8px; }
  .stat-card { min-height: 110px; padding: 13px; }
  .stat-value { font-size: 18px; }
  .page-heading h1 { font-size: 22px; }
  .summary-strip { gap: 6px; }
  .summary-box { padding: 11px; }
  .summary-box b { font-size: 14px; }
  .form-grid { grid-template-columns: 1fr; }
}

/* iHoldX brand palette: midnight surfaces with electric violet and lavender accents. */
.sidebar { background: #0c0b16; border-color: #242238; }
.nav-item { color: #a7a2bc; }
.nav-item:hover { background: #181629; color: #f1efff; }
.nav-item.active { background: #241d42; color: #b7a5ff; }
.privacy-note { background: #11111d; border-color: #29253f; }
.privacy-note b { color: #e6e2f5; }
.avatar { color: #c1b2ff; background: #241d42; }
.icon-button:hover { background: #1c1a2c; color: #b7a5ff; }
.button-primary { box-shadow: 0 3px 12px #7657ff36; }
.button-secondary { border-color: #302d45; background: #151421; color: #c4bfd5; }
.button-secondary:hover { border-color: #7660d1; color: #c3b4ff; }
.nav-icon, .stat-icon, .project-color { color: #b9a8ff; }
.stat-icon, .project-color { background: #211b3c; }
.panel-header { border-color: #242238; }
.project-row, .task-row, .report-project-row { border-color: #242238; }
.project-row-title span, .task-date { color: #a09bb3; }
.progress-track { background: #26243a; }
.progress-track span { background: linear-gradient(90deg, #6748ed, #a487ff); }
.task-date.overdue { color: #ff8994; }
.activity-dot { background: #9c7cff; }
.activity-items { color: #aaa5bd; }
.empty-state { color: #aaa5bd; }
.empty-state b { color: #e0dcf0; }
.search-input, .filter-select,
.stack-form input, .record-form input, .record-form select, .record-form textarea {
  border-color: #302d45;
  background: #11111d;
  color: #eeebfa;
}
.search-input::placeholder, .stack-form input::placeholder,
.record-form input::placeholder, .record-form textarea::placeholder { color: #77728c; }
.search-input:focus, input:focus, select:focus, textarea:focus {
  border-color: #8065f4;
  box-shadow: 0 0 0 3px #7657ff2b;
}
.filter-select { color: #c0bbd2; }
.status-pill, .priority-pill { background: #242236; color: #bbb6cc; }
.status-in-progress, .status-planning { background: #241d42; color: #c2b4ff; }
.status-completed { background: #14352c; color: #70d6ad; }
.status-on-hold { background: #3a2f1e; color: #e7c479; }
.status-cancelled { background: #3a2029; color: #f193a1; }
.card-actions { border-color: #242238; }
.small-button { background: #211f31; color: #c3bfd1; }
.small-button:hover { color: #c7b9ff; background: #2b244a; }
.small-button.delete:hover { color: #ff98a1; background: #3a2029; }
.table-wrap, .summary-box { border-color: #27253b; background: #11111d; }
th { background: #151421; border-color: #29273d; color: #a49fb6; }
td { border-color: #242238; color: #bbb6ca; }
td strong { color: #e4e0f0; }
.amount-positive { color: #66d2a6; }
.amount-negative { color: #ff8994; }
.bar { background: #8d6dff; }
.bar.expense { background: #45415c; }
.legend-dot { background: #8d6dff; }
.legend-dot.expense { background: #45415c; }
.app-footer { color: #817c96; }
.app-footer span { color: #514d63; }
.notice { border-color: #28513f; background: #13261f; color: #7ce0b2; }
.notice.error { border-color: #56303b; background: #2a171f; color: #ff9aa4; }
.auth-screen { background: #080811; }
.auth-aside { background: #080811; }
.auth-aside::before { border-color: #292344; box-shadow: 0 0 0 45px #080811, 0 0 0 46px #292344, 0 0 0 105px #080811, 0 0 0 106px #292344; }
.auth-aside .eyebrow, .eyebrow { color: #a58aff; }
.form-error, .dialog-error { color: #ff8994; }
.text-button, .inline-link { color: #b19dff; }
.record-dialog { background: #11111d; }
.dialog-header { border-color: #29273d; }
.dialog-close { color: #a39eb5; }
.form-hint { color: #928da5; }
.record-dialog::backdrop { background: #05040dcc; }
.stack-form label, .record-form label { color: #c4bfd5; }
.stat-top { color: #aaa5bd; }
.card-metrics b { color: #e4e0f0; }
.button-danger { border-color: #56303b; background: #2a171f; color: #ff9aa4; }
.button-danger:hover { border-color: #81404d; background: #3a2029; }
.button-google { border-color: #302d45; background: #f1efff; color: #242136; }
.button-google:hover { border-color: #b6a5ff; background: #fff; }
.google-g { color: #4285f4; font: 800 17px Arial, sans-serif; }
.auth-divider { display: flex; align-items: center; gap: 12px; margin: 17px 0; color: #817c96; font-size: 10px; }
.auth-divider::before, .auth-divider::after { content: ""; height: 1px; flex: 1; background: #29263d; }
.form-success { color: #70d6ad; }
