:root {
  color-scheme: light;
  --bg: #f3f6f8; --card: #fff; --text: #182c3c; --muted: #607484;
  --border: #dce5eb; --accent: #087e83; --accent-text: #fff;
  --mine: #def2ef; --theirs: #fff; --read: #087e83; --danger: #b42318;
  --hover: #eef5f6; --shadow: 0 12px 40px rgb(23 44 60 / 9%); --flash: #fff0bf;
}
@media (prefers-color-scheme: dark) {
  :root { color-scheme: dark; --bg: #101c26; --card: #172733; --text: #e4edf3;
    --muted: #a1b4c2; --border: #2d4352; --accent: #65d4c8; --accent-text: #102c30;
    --mine: #204641; --theirs: #1c303e; --read: #65d4c8; --danger: #ff9c91;
    --hover: #213845; --shadow: 0 12px 40px rgb(0 0 0 / 20%); --flash: #51451e; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.6 system-ui, -apple-system, 'Segoe UI', sans-serif; }
a { color: var(--accent); text-underline-offset: 3px; }
button, input, textarea { font: inherit; }
button, a, input, textarea { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
[hidden] { display: none !important; }
.brand { display: inline-flex; align-items: center; gap: 11px; color: var(--text); text-decoration: none; font-size: 19px; font-weight: 750; letter-spacing: -.6px; }
.brand-mark { display: inline-grid; place-items: center; width: 37px; height: 37px; border-radius: 11px; background: #087e83; color: white; font-size: 21px; font-weight: 750; letter-spacing: -2px; padding-right: 2px; }
.eyebrow { margin: 0 0 12px; color: var(--accent); font-size: 11px; font-weight: 750; text-transform: uppercase; letter-spacing: .14em; }
.muted { color: var(--muted); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 17px; border: 1px solid var(--border); border-radius: 9px; background: var(--card); color: var(--text); font: inherit; font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--hover); }
.btn.primary, .btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.primary:hover, .btn-primary:hover { filter: brightness(1.08); }
.workspace-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 20px; padding: 20px max(24px, calc((100vw - 1120px) / 2)); background: var(--card); border-bottom: 1px solid var(--border); }
.workspace-nav, .user { display: flex; align-items: center; gap: 24px; }
.workspace-nav a { color: var(--muted); font-size: 14px; font-weight: 600; text-decoration: none; }
.workspace-nav a[aria-current] { color: var(--accent); }
.user { gap: 14px; font-size: 13px; color: var(--muted); }
.user span { overflow-wrap: anywhere; }
.user form { margin: 0; }
.dashboard { max-width: 1120px; margin: auto; padding: 52px 24px 32px; }
.welcome { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.welcome h1 { margin: 0 0 9px; font-size: clamp(28px, 4vw, 38px); line-height: 1.2; letter-spacing: -1.3px; }
.welcome p:last-child { margin: 0; color: var(--muted); }
.workspace-label { border: 1px solid var(--border); border-radius: 30px; padding: 7px 13px; font-size: 12px; white-space: nowrap; background: var(--card); }
.workspace-label::before { content: ''; display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; background: var(--accent); }
.dashboard-grid { display: grid; grid-template-columns: 1.65fr 1fr; gap: 24px; }
.feature-card { position: relative; overflow: hidden; padding: 34px; border-radius: 18px; background: #173b4a; color: #fff; }
.feature-card .eyebrow { color: #9be0d7; }
.feature-card h2 { max-width: 330px; margin: 22px 0 12px; font-size: 30px; line-height: 1.25; letter-spacing: -.8px; }
.feature-card p { max-width: 350px; color: #c0d3da; }
.feature-card .btn { margin-top: 18px; background: #d4f4ec; color: #16483f; border-color: transparent; }
.feature-icon { display: grid; place-items: center; width: 52px; height: 52px; border: 1px solid #54727b; border-radius: 15px; color: #b9eee4; }
.feature-icon svg { width: 26px; height: 26px; }
.quick-card { padding: 28px; border: 1px solid var(--border); border-radius: 18px; background: var(--card); }
.quick-card h2 { margin: 0 0 22px; font-size: 17px; }
.quick-link { display: flex; align-items: center; gap: 14px; padding: 18px 0; border-bottom: 1px solid var(--border); color: var(--text); text-decoration: none; }
.quick-link:last-child { border: 0; }
.quick-link:hover strong { color: var(--accent); }
.quick-link strong, .quick-link small { display: block; }
.quick-link small { margin-top: 3px; color: var(--muted); font-size: 12px; }
.quick-link > span:first-child { display: grid; place-items: center; flex: none; width: 38px; height: 38px; border-radius: 10px; background: var(--hover); color: var(--accent); font-size: 19px; }
.quick-link > span:last-child { margin-left: auto; color: var(--muted); }
.workspace-note { margin-top: 26px; padding: 20px 24px; display: flex; align-items: center; gap: 18px; border: 1px solid var(--border); border-radius: 12px; }
.workspace-note strong { font-size: 14px; }
.workspace-note p { margin: 3px 0 0; color: var(--muted); font-size: 13px; }
.workspace-footer { margin-top: 32px; font-size: 12px; color: var(--muted); }
.auth-layout { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-story { display: flex; flex-direction: column; align-items: flex-start; padding: 42px clamp(32px, 6vw, 100px); background: #173b4a; color: white; }
.auth-story .brand { color: white; }
.auth-story .brand-mark { background: #b9eee4; color: #173b4a; }
.auth-story-copy { margin: auto 0; padding: 64px 0; max-width: 440px; }
.auth-story-copy .eyebrow { color: #9be0d7; }
.auth-story h2 { font-size: clamp(32px, 3.6vw, 46px); line-height: 1.15; font-weight: 650; letter-spacing: -1.6px; margin: 20px 0; }
.auth-story p { color: #c0d3da; }
.auth-story-foot { font-size: 12px; color: #c0d3da; }
.auth-main { display: grid; place-items: center; padding: 40px 24px; }
.auth-card { width: 100%; max-width: 380px; }
.auth-card h1 { font-size: 30px; letter-spacing: -1px; margin: 0 0 8px; }
.auth-card .muted { margin: 0 0 28px; }
.auth-card label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 7px; }
.auth-card input[type=email], .auth-card input[type=password], .auth-card input[type=text] { width: 100%; padding: 12px 14px; margin-bottom: 20px; border: 1px solid var(--border); border-radius: 8px; background: var(--card); color: var(--text); }
.auth-card .btn { width: 100%; margin-bottom: 10px; padding: 12px; }
.auth-card .row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-bottom: 22px; font-size: 13px; }
.auth-card .row label { display: inline; font-weight: 400; }
.auth-card .errors { padding: 12px 16px; border-left: 3px solid var(--danger); color: var(--danger); font-size: 13px; list-style: none; background: var(--card); }
@media (max-width: 800px) {
  .workspace-header { padding: 16px 20px; }
  .workspace-nav { display: none; }
  .dashboard { padding-top: 32px; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .welcome { flex-direction: column; }
  .feature-card { padding: 28px; }
  .auth-layout { grid-template-columns: 1fr; }
  .auth-story { padding: 22px 24px; }
  .auth-story-copy, .auth-story-foot { display: none; }
  .auth-main { padding: 40px 24px; }
}
@media (max-width: 480px) {
  .workspace-header .user { width: 100%; justify-content: space-between; }
  .workspace-note { align-items: flex-start; padding: 18px; }
}

.quick-link svg { width: 20px; height: 20px; }

.notification-toasts { position: fixed; right: 22px; bottom: 22px; z-index: 100; display: grid; gap: 10px; width: min(360px, calc(100vw - 32px)); }
.notification-toast { display: flex; align-items: flex-start; gap: 12px; padding: 16px; background: var(--card); border: 1px solid var(--border); border-left: 4px solid var(--accent); border-radius: 12px; box-shadow: var(--shadow); }
.notification-toast a { flex: 1; min-width: 0; text-decoration: none; color: var(--text); overflow-wrap: anywhere; }
.notification-toast strong, .notification-toast span { display: block; }
.notification-toast strong { font-size: 14px; }
.notification-toast span { color: var(--muted); font-size: 13px; margin-top: 4px; }
.notification-toast button { background: transparent; border: 0; color: var(--muted); font-size: 22px; cursor: pointer; min-width: 28px; }
.notification-settings h2 { font-size: 22px; margin: 0 0 12px; letter-spacing: -.5px; }
.notification-settings > p { font-size: 13px; }
@media (max-width: 720px) { .notification-toasts { right: 16px; bottom: 88px; } }
