:root {
    color-scheme: light;
    --navy: #0c1c48;
    --blue: #2446ac;
    --bg: #fff;
    --bg2: #f3f6fc;
    --text: #13234b;
    --muted: #526080;
    --primary: #2446ac;
    --pink: #2446ac;
    --panel: #fff;
    --panel-solid: #fff;
    --border: #d7dfef;
    --danger: #b62346;
    --success: #16623f;
    --warn: #7a5200;
    --grad: linear-gradient(120deg, #173584, #2446ac);
    --shadow: 0 16px 42px -24px #13234b30;
    --font: 'DM Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-d: 'Manrope', 'DM Sans', system-ui, sans-serif;
    --header-height: 84px;
    --radius: 16px;
}

html { scroll-padding-top: calc(var(--header-height) + 24px); }
body { background: #fff; color: var(--text); font-size: 14px; -webkit-font-smoothing: antialiased; }
.container { width: min(1240px, calc(100% - 64px)); }
.page { padding-bottom: 0; }
h1, h2, h3, h4 { letter-spacing: -.035em; }
button, input, select, textarea { font-family: var(--font); }
:focus-visible { outline: 3px solid #2446ac; outline-offset: 3px; }
::selection { background: #dbe5ff; color: var(--navy); }
.bg-orbs { display: none; }
.grad-text { background: none; color: #b6ccff; }
.eyebrow { color: var(--blue); font-size: .68rem; letter-spacing: 1.7px; }

.topbar, .topbar.scrolled, .workspace-page .topbar, .workspace-page .topbar.scrolled {
    color: var(--text);
    background: #fffffff5;
    border-bottom: 1px solid #dce3f0;
    box-shadow: 0 4px 20px #13234b08;
    backdrop-filter: blur(18px);
}
.topbar-inner { width: min(1440px, calc(100% - 64px)); gap: 24px; }
.brand { gap: 14px; }
.brand-mark img { width: 86px; height: 40px; padding: 0; border-radius: 0; background: #fff; box-shadow: none; }
.brand-text { padding-left: 14px; border-left: 1px solid #d5deef; }
.brand-name { color: var(--text); background: none; animation: none; font-size: 1.4rem; letter-spacing: -.8px; }
.brand-tag { color: var(--muted); font-size: .6rem; margin-top: 6px; }
.header-search { width: min(480px, 38vw); background: #f3f6fc; border: 1px solid var(--border); border-radius: 10px; }
.header-search:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px #2446ac12; }
.header-search input { color: var(--text); font-size: .8rem; }
.header-search input::placeholder { color: #657393; }
.header-search button { color: var(--blue); }
.bell, .user-chip { background: #f3f6fc; color: var(--blue); border-color: var(--border); border-radius: 11px; }
.bell:hover, .user-chip:hover { background: #e8efff; }
.user-chip { background: #fff; padding: 4px 12px 4px 4px; }
.user-chip-name { color: var(--text); font-size: .8rem; }
.user-chip-name small { color: var(--muted); font-size: .66rem; }
.user-chip .avatar { width: 34px; height: 34px; border-radius: 9px; }
.count-badge, .rail-count { background: var(--blue); color: #fff; }

.workspace-page { background: #f3f6fc; color: var(--text); }
.workspace-shell { align-items: stretch; min-height: calc(100dvh - var(--header-height)); background: #f3f6fc; }
.workspace-rail {
    position: sticky;
    top: var(--header-height);
    align-self: flex-start;
    flex: 0 0 208px;
    height: calc(100dvh - var(--header-height));
    overflow-y: auto;
    gap: 6px;
    padding: 28px 14px 16px;
    background: var(--navy);
    color: #ccd6ef;
}
.workspace-rail > a, .workspace-rail button {
    position: relative;
    flex-direction: row;
    justify-content: flex-start;
    gap: 12px;
    min-height: 45px;
    padding: 11px 14px;
    border: 1px solid transparent;
    border-radius: 9px;
    font-size: .8rem;
    text-align: left;
}
.workspace-rail > a > span, .workspace-rail button > span { font-size: 1.1rem; }
.workspace-rail > a:hover, .workspace-rail .selected { color: #fff; background: #ffffff10; box-shadow: none; }
.workspace-rail .selected { background: var(--blue); }
.workspace-rail form { margin-top: auto; padding-top: 10px; border-top: 1px solid #ffffff1a; }
.rail-count { margin-left: auto; background: #ffffff26; }
.workspace-content {
    position: relative;
    min-width: 0;
    padding: 30px clamp(20px, 3vw, 48px) 72px;
    background: #f3f6fc;
    --text: #13234b;
    --muted: #526080;
    --panel: #fff;
    --panel-solid: #fff;
    --border: #d7dfef;
    --shadow: 0 14px 40px -24px #13234b26;
    color-scheme: light;
}
.workspace-content h1, .workspace-content h2, .workspace-content h3 { color: var(--text); }
.workspace-content h1 { font-size: clamp(1.6rem, 2.3vw, 2rem); }
.workspace-content .muted { color: var(--muted); }
.workspace-content .panel,
.workspace-content .person-card,
.workspace-content .stat,
.workspace-content .list-card,
.workspace-content .table-wrap {
    border: 1px solid var(--border);
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 8px 0 -5px #e3e9f6, 0 14px 30px -24px #13234b35;
}
.workspace-content .panel { padding: clamp(18px, 2vw, 26px); }
.workspace-content .input, .workspace-content select.input {
    color: var(--text);
    background: #fbfcff;
    border-color: #cdd7eb;
    border-radius: 9px;
}
.workspace-content .input:focus { border-color: var(--blue); box-shadow: 0 0 0 3px #2446ac18; }
.workspace-content select.input option { color: var(--text); background: #fff; }
.workspace-content label.lbl { color: #293d68; }

.btn, .workspace-content .btn {
    min-height: 42px;
    padding: 10px 18px;
    border: 1px solid #ced9ef;
    border-radius: 9px;
    color: #173584;
    background: #eef3ff;
    font-size: .82rem;
    box-shadow: none;
    transition: background .2s, box-shadow .2s, transform .2s;
}
.btn:hover, .workspace-content .btn:hover { background: #e2eafe; box-shadow: 0 5px 16px #13234b12; transform: translateY(-1px); }
.btn-glow, .workspace-content .btn-glow { color: #fff; background: var(--blue); border-color: var(--blue); box-shadow: 0 6px 16px #2446ac20; }
.btn-glow:hover, .workspace-content .btn-glow:hover { color: #fff; background: #173584; }
.btn-ghost, .workspace-content .btn-ghost { background: transparent; color: #173584; border-color: #ced9ef; }
.btn-danger, .workspace-content .btn-danger { background: #fff0f3; color: #9b1f3c; border-color: #efc3cf; }
.btn-success, .workspace-content .btn-success { background: #e6f5ed; color: #16623f; border-color: #b4ddc6; }
.btn-sm { min-height: 38px; padding: 8px 16px; }
.workspace-content .eyebrow { color: var(--blue); }
.workspace-content .badge { background: #eaf2fe; color: #235a9c; }
.workspace-content .badge-live { background: #d5f3e5; color: #16623f; animation: none; }
.workspace-content .flash-success { color: #16623f; background: #e6f5ed; border-color: #b4ddc6; }
.workspace-content .flash-error, .workspace-content .errors { color: #922a43; background: #fff0f3; border-color: #efc3cf; }
.workspace-content .flash-info { color: #173584; background: #eef3ff; border-color: #bfceef; }
.workspace-content .flash-warn { color: #7a5200; background: #fff6e5; border-color: #f3cf87; }
.workspace-content .tbl th { color: #526080; background: #f1f5fc; font-size: .66rem; }
.workspace-content .tbl td { border-color: #e5eaf4; }
.workspace-content .tbl tr:hover td { background: #f6f8fe; }
.workspace-content .tabs { border-color: var(--border); }
.workspace-content .tab { color: var(--muted); font-size: .85rem; }
.workspace-content .tab.active { color: var(--blue); border-bottom-color: var(--blue); }
.workspace-content .status-todo { background: #edf1f6; color: #43566e; }
.workspace-content .status-in_progress { background: #e1efff; color: #1d58a6; }
.workspace-content .status-done { background: #dcf4e8; color: #16623f; }
.workspace-content .tag { background: #eaf2fe; color: #235a9c; }
.workspace-content .ticket-key, .workspace-content .link-btn { color: #1d5da9; }
.workspace-content .summary-link { color: var(--text); }
.workspace-content .empty-state { background: #f8faff; border-color: #ccd7ec; color: var(--muted); }
.workspace-content .checkbox-grid { border-color: var(--border); background: #fbfcff; }
.workspace-content .checkbox-grid label:hover { background: #edf2ff; }
.workspace-content input[type="checkbox"], .workspace-content input[type="radio"] { accent-color: var(--blue); }

.workspace-content .view-heading,
.workspace-content .page-heading,
.workspace-content .dash-head {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    margin: -2px 0 27px;
    padding: 27px clamp(20px, 3vw, 34px) 38px;
    border: 0;
    border-radius: 16px 16px 0 0;
    color: #fff;
    background: radial-gradient(ellipse at 90% 30%, #2446ac, transparent 70%), #0c1c48;
    box-shadow: none;
}
.workspace-content .view-heading > *,
.workspace-content .page-heading > *,
.workspace-content .dash-head > * { position: relative; z-index: 2; }
.workspace-content .view-heading::before,
.workspace-content .page-heading::before,
.workspace-content .dash-head::before {
    content: none;
}
.workspace-content .view-heading::after,
.workspace-content .page-heading::after,
.workspace-content .dash-head::after {
    position: absolute;
    z-index: 1;
    right: -2px;
    bottom: -2px;
    left: -2px;
    width: calc(100% + 4px);
    height: 45px;
    background: var(--wave-color, #f3f6fc);
    clip-path: none;
    -webkit-mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    content: "";
    pointer-events: none;
}
.workspace-content .view-heading h1,
.workspace-content .page-heading h1,
.workspace-content .dash-head h1,
.workspace-content .view-heading h2,
.workspace-content .page-heading h2,
.workspace-content .dash-head h2 { color: #fff; }
.workspace-content .view-heading p,
.workspace-content .page-heading p,
.workspace-content .dash-head p { color: #d2e4f8; }
.workspace-content .view-heading .eyebrow,
.workspace-content .page-heading .eyebrow,
.workspace-content .dash-head .eyebrow { color: #b8d9fb; }
.workspace-content .view-heading .btn:not(.btn-glow),
.workspace-content .page-heading .btn:not(.btn-glow),
.workspace-content .dash-head .btn:not(.btn-glow) { color: #fff; background: #ffffff1a; border-color: #deefff47; }
.workspace-content .view-heading .btn:not(.btn-glow):hover,
.workspace-content .page-heading .btn:not(.btn-glow):hover,
.workspace-content .dash-head .btn:not(.btn-glow):hover { background: #ffffff30; }
.workspace-content .view-heading .muted,
.workspace-content .page-heading .muted,
.workspace-content .dash-head .muted { color: #d2e4f8; }

.hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 78px 0 105px;
    color: #fff;
    background: radial-gradient(ellipse at 82% 28%, #25488e, transparent 62%), #0c1c48;
}
.hero::before {
    position: absolute;
    z-index: -1;
    top: -250px;
    right: -200px;
    bottom: auto;
    left: auto;
    width: 750px;
    height: 750px;
    background: none;
    border: 1px solid #ffffff13;
    border-radius: 36%;
    rotate: 28deg;
    box-shadow: 0 0 0 45px #ffffff03, 0 0 0 90px #ffffff02;
    content: "";
    mask-image: none;
    pointer-events: none;
}
.wave-panel { position: relative; isolation: isolate; overflow: hidden; }
.wave-panel::after {
    position: absolute;
    z-index: -1;
    right: -2px;
    bottom: -2px;
    left: -2px;
    width: calc(100% + 4px);
    height: 65px;
    background: var(--wave-color, #fff);
    clip-path: none;
    -webkit-mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    content: "";
    pointer-events: none;
}
.hero.wave-panel { --wave-color: #fff; }
.hero h1 { font-size: clamp(2.6rem, 4.7vw, 4.4rem); line-height: 1.08; letter-spacing: -.055em; }
.hero p.lead { color: #c6d7ea; line-height: 1.85; font-size: 1rem; }
.hero .btn-glow { color: #173584; background: #fff; border-color: #fff; }
.hero .btn-glow:hover { color: #173584; background: #e9efff; }
.hero-eyebrow { color: #d7e8fb; background: #ffffff14; border-color: #ffffff30; }
.hero-stats { gap: 0; }
.hero-stats > div { padding: 0 24px; border-right: 1px solid #ffffff2b; }
.hero-stats > div:first-child { padding-left: 0; }
.hero-stats > div:last-child { border-right: 0; }
.hero-stats b { color: #fff; }
.hero-stats span { color: #b8cce4; }
.hero-geometry { display: none; }
.hv-main { grid-template-rows: none; border: 1px solid #ffffff80; border-radius: 15px; color: var(--text); background: #fff; box-shadow: 12px 15px 0 -5px #ffffff0d, 0 30px 60px #03102b45; transform: rotate(-2deg); animation: none; }
.hv-main::before { content: none; }
.hv-col { min-width: 0; background: #f1f5fd; }
.hv-col small { color: var(--muted); }
.hv-col i { background: #fff; border-left-color: var(--blue); overflow-wrap: anywhere; }
.hv-col i.hot { background: #fff6e5; border-left-color: #ad7000; }
.hv-col i.done { background: #e6f5ed; border-left-color: #16623f; opacity: 1; }
.hv-chip { color: #526080; background: #fff; border-color: #d7dfef; border-radius: 12px; box-shadow: 0 14px 35px #06152f30; }
.section-cross { margin: 0; padding: 55px 0 100px; color: var(--text); background: #fff; }
.section-cross::before, .section-cross::after { content: none; }
.section-cross .eyebrow { color: #205eb0; }
.section-cross .stat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.section-cross .stat { padding: 30px; background: #fff; border: 1px solid #ccd7ed; border-radius: 15px 40px 15px 15px; box-shadow: 0 10px 0 -6px #e4ebfa, 0 18px 40px -25px #13234b25; }
.section-cross .stat b { font-size: 1.2rem; }
.section-cross .stat span { color: #4a6382; }
.section-cross .stat::after { display: none; }
.section-cross .stat .ic { display: inline-grid; place-items: center; width: 48px; height: 48px; margin-bottom: 12px; border: 1px solid #d6e8ff; border-radius: 13px; background: #eaf3ff; }

.auth-layout { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); flex: 1; min-height: 640px; }
.auth-story {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: center;
    overflow: hidden;
    padding: 70px clamp(32px, 7vw, 104px);
    color: #fff;
    background: radial-gradient(ellipse at 80% 25%, #2446ac, transparent 75%), var(--navy);
}
.auth-story::before {
    position: absolute;
    z-index: -1;
    top: -250px;
    right: -200px;
    width: 750px;
    height: 750px;
    border: 1px solid #ffffff13;
    border-radius: 36%;
    rotate: 28deg;
    box-shadow: 0 0 0 45px #ffffff03, 0 0 0 90px #ffffff02;
    content: "";
}
.auth-story::after {
    position: absolute;
    z-index: 1;
    right: -2px;
    bottom: -2px;
    left: -2px;
    width: calc(100% + 4px);
    height: 50px;
    background: #fff;
    -webkit-mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    content: "";
    pointer-events: none;
}
.auth-story-content { max-width: 470px; }
.auth-kicker { display: inline-flex; align-items: center; gap: 10px; color: #c1d3ff; font-size: .63rem; font-weight: 700; letter-spacing: 1.8px; }
.auth-kicker span { width: 7px; height: 7px; border-radius: 50%; background: #b6ccff; box-shadow: 0 0 0 5px #ffffff0d; }
.auth-story h1 { margin: 22px 0; color: #fff; font-size: clamp(2.4rem, 4vw, 3.8rem); line-height: 1.15; }
.auth-story h1 em { color: #b6ccff; font-style: normal; }
.auth-story-content > p:not(.auth-kicker) { max-width: 410px; color: #c4d2ec; font-size: .94rem; line-height: 1.85; }
.auth-highlights { display: grid; gap: 16px; margin: 34px 0 38px; }
.auth-highlights span { display: flex; align-items: center; gap: 14px; color: #e1eaff; font-size: .82rem; }
.auth-highlights b { color: #b6ccff; font-size: .68rem; letter-spacing: 1px; }
.auth-story-content > small { color: #b1c3e6; font-size: .68rem; }
.auth-wrap { display: grid; place-items: center; padding: 55px 35px 75px; background: #fff; }
.auth-card .panel { border: 1px solid #d7dfef; border-radius: 16px; background: #fff; box-shadow: 0 18px 50px -30px #13234b66; }
.auth-card .panel h1 { color: var(--text); }
.auth-card .panel .sub { color: var(--muted); }
.auth-card .panel .lbl { color: #293d68; }
.auth-card .panel .input { color: var(--text); background: #fbfcff; border-color: #cdd7eb; }
.auth-card .panel .input::placeholder { color: #657393; }
.auth-card .grad-text { color: var(--blue); }
.auth-card .btn-glow { color: #fff; }

.meeting-footer {
    position: relative;
    margin-top: 0;
    padding-top: 0;
    color: #526080;
    background: #fff;
}
.meeting-footer::before { content: none; }
.storyboard-footer-wave {
    height: 32px;
    background: #f3f6fc;
    -webkit-mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    mask: url('../img/section-wave.svg?v=2') center / 100% 100% no-repeat;
    transform: rotate(180deg);
}
.meeting-footer .footer-bottom { margin-top: 0; padding: 32px 0; border: 0; align-items: center; gap: 24px; }
.meeting-footer .brand-name { color: #13234b; font-size: 1.3rem; }
.meeting-footer .brand-text { border-color: #d5deef; }
.meeting-footer .brand-tag { color: #526080; }
.footer-copy { color: #526080; font-size: .75rem; line-height: 1.9; }
.footer-copy small { font-size: .64rem; }
.footer-link { color: #2446ac; font-size: .75rem; font-weight: 700; border-bottom: 1px solid #ced9ef; padding: 6px 0; }
.footer-link:hover { border-color: #2446ac; }
.copyright-watermark { display: none; }
.connection-notice { background: #8d2541; }

@media (max-width: 1180px) {
    .workspace-rail { flex-basis: 180px; padding-right: 10px; padding-left: 10px; }
    .topbar-inner { width: calc(100% - 40px); gap: 16px; }
    .user-chip-name { max-width: 100px; overflow-wrap: anywhere; }
}
@media (max-width: 980px) {
    .hero-grid { grid-template-columns: 1fr; gap: 42px; }
    .hero-grid > :first-child { max-width: 700px; }
    .hero-visual { width: min(100%, 580px); justify-self: center; }
}
@media (max-width: 760px) {
    :root { --header-height: 76px; }
    .container { width: calc(100% - 32px); }
    .topbar .container { width: calc(100% - 28px); }
    .topbar-inner { gap: 12px; }
    .topbar .brand-mark img { width: 64px; height: 32px; }
    .topbar .brand-name { font-size: 1.17rem; }
    .topbar .brand-tag { font-size: .5rem; }
    .brand { gap: 10px; }
    .brand-text { padding-left: 10px; }
    .workspace-page { --header-height: 130px; }
    .workspace-page .topbar-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: 65px 55px; gap: 0 10px; }
    .header-actions { justify-self: end; gap: 8px; }
    .workspace-page .header-search { display: flex; grid-column: 1 / -1; grid-row: 2; width: 100%; align-self: start; }
    .workspace-page .header-search input { padding: 11px 12px; }
    .topbar .user-chip { border-radius: 10px; padding: 3px; }
    .topbar .user-chip-name { display: none; }
    .workspace-shell { flex-direction: column; }
    .workspace-rail { position: sticky; top: var(--header-height); z-index: 35; width: 100%; height: auto; flex: 0 0 auto; flex-direction: row; align-self: stretch; gap: 4px; padding: 8px; overflow-x: auto; overflow-y: hidden; }
    .workspace-rail > a, .workspace-rail button { flex: 0 0 auto; flex-direction: column; justify-content: center; min-width: 64px; min-height: 48px; padding: 8px; gap: 5px; font-size: .59rem; }
    .workspace-rail form { flex: 0 0 auto; margin: 0; padding: 0; border: 0; }
    .rail-count { position: absolute; top: 1px; right: 2px; min-width: 14px; padding: 0 4px; color: var(--blue); background: #fff; font-size: .55rem; }
    .workspace-content { padding: 20px 16px 45px; }
    .workspace-content .panel { padding: 20px; }
    .workspace-content .view-heading, .workspace-content .page-heading, .workspace-content .dash-head { padding: 22px 18px 32px; }
    .workspace-content .view-heading h1, .workspace-content .page-heading h1, .workspace-content .dash-head h1 { font-size: 1.65rem; }
    .heading-actions { gap: 8px; }
    .heading-actions .btn { font-size: .8rem; padding: 8px 12px; }
    .hero { padding: 55px 0 72px; }
    .hero h1 { font-size: clamp(2.4rem, 9vw, 3.6rem); }
    .hero-visual { height: 340px; }
    .hero-stats > div { padding: 0 14px; }
    .section-cross { padding: 68px 0; }
    .section-cross .stat-grid { grid-template-columns: 1fr; gap: 22px; }
    .section-cross .stat { padding: 26px; }
    .stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .stat { padding: 16px; }
    .stat b { font-size: 1.65rem; }
    .meeting-footer .footer-bottom { padding: 26px 0; gap: 22px; }
    .footer-copy { width: 100%; }
    .auth-layout { grid-template-columns: 1fr; min-height: 0; }
    .auth-story { padding: 42px 25px 62px; }
    .auth-story::after { height: 30px; }
    .auth-story h1 { font-size: 2.25rem; margin: 18px 0; }
    .auth-highlights, .auth-story-content > small { display: none; }
    .auth-story-content > p:not(.auth-kicker) { margin-bottom: 0; }
    .auth-wrap { padding: 30px 20px 55px; }
}
@media (max-width: 420px) {
    .topbar .brand-tag { display: none; }
    .topbar .brand-mark img { width: 55px; }
    .topbar .brand-name { font-size: 1.05rem; }
    .hero-visual { height: 290px; }
    .hero-stats { flex-wrap: wrap; row-gap: 12px; }
    .hero-stats > div { padding: 0 10px; }
    .stat-grid { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .btn:hover, .stat:hover { transform: none; }
}
