@font-face {
  font-family: "Google Sans";
  src: url("/assets/ghostincimgs/GoogleSans-Regular.ttf") format("truetype");
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --white: #ffffff;
  --black: #0b0c0e;
  --black-2: #15171a;
  --text: #111317;
  --text-soft: #50555d;
  --muted: #737983;
  --line: #e1e4e8;
  --line-strong: #cfd4da;
  --blue: #6574ff;
  --blue-soft: #eef0ff;
  --blue-pale: #f6f7ff;
  --sidebar-width: 216px;
  --radius: 12px;
  --radius-small: 10px;
  --radius-large: 16px;
  --shell-radius: 18px;
  --surface-soft: #f7f8fa;
  --surface-muted: #f1f3f6;
  --content-inline: clamp(24px, 4vw, 56px);
  --font: "Google Sans", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; background: var(--white); }
body {
  color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body.dialog-open { overflow: hidden; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .46; }
a { color: inherit; }
img, svg { display: block; }
.hidden { display: none !important; }
.mobile-only { display: none !important; }
::selection { background: var(--blue-soft); color: var(--black); }

.button,
.mini-button,
.icon-button,
.text-button,
.sidebar-action {
  appearance: none;
  border-radius: var(--radius);
  font-family: var(--font);
  transition: background-color .14s ease, border-color .14s ease, color .14s ease, opacity .14s ease, box-shadow .14s ease, transform .14s ease;
}
.button {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 9px 15px;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 1px 1px rgba(15, 18, 24, .04);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}
.button.primary { background: var(--black); color: var(--white); border-color: var(--black); }
.button.primary:hover { background: var(--black); }
.button.secondary { background: var(--white); color: var(--text); border-color: var(--line-strong); }
.button.secondary:hover { background: var(--white); border-color: var(--line-strong); }
.button.blue { background: var(--blue); color: var(--white); border-color: var(--blue); }
.button.blue:hover { background: var(--blue); }
.button.quiet { background: transparent; color: var(--text-soft); border-color: transparent; }
.button.quiet:hover { background: #f7f7f8; color: var(--text); }
.button.block { width: 100%; }
.button:focus-visible, .mini-button:focus-visible, .text-button:focus-visible { outline: 3px solid rgba(101, 116, 255, .2); outline-offset: 2px; }
.text-button,
.sidebar-action {
  border: 0;
  background: transparent;
  color: var(--text-soft);
  padding: 0;
  text-align: left;
  font-size: 13px;
}
.text-button { min-height: 32px; display: inline-flex; align-items: center; justify-content: center; padding: 6px 9px; border-radius: var(--radius-small); text-decoration: none; font-weight: 600; }
.text-button:hover { background: var(--surface-soft); color: var(--text); }
.icon-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--text);
  padding: 0;
}
.icon-button:hover { border-color: var(--line-strong); background: #fafafa; }
.icon-button.plain {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 25px;
  font-weight: 300;
  line-height: 1;
}
.icon-button.plain:hover { background: transparent; color: var(--blue); }
.mini-button {
  min-height: 32px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-small);
  background: var(--white);
  color: var(--text);
  padding: 6px 10px;
  font-size: 12px;
  font-weight: 600;
}
.mini-button:hover { background: #fafafa; border-color: #bfc5cc; }
.mini-button.quiet { border-color: transparent; color: var(--text-soft); }

label { display: grid; gap: 7px; color: var(--text-soft); font-size: 13px; }
input, textarea, select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background-color: var(--white);
  color: var(--text);
  padding: 10px 12px;
  outline: none;
  transition: border-color .14s ease, box-shadow .14s ease;
}
textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
input:focus, textarea:focus, select:focus {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(101, 116, 255, .13);
}
select {
  appearance: none;
  padding-right: 38px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2350555d' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
}
input[type="checkbox"] {
  width: 18px;
  height: 18px;
  min-height: 18px;
  padding: 0;
  accent-color: var(--blue);
}
input[type="range"] {
  min-height: 22px;
  padding: 0;
  border: 0;
  box-shadow: none;
  accent-color: var(--blue);
}
.field-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.form-stack { display: grid; gap: 16px; }
.help-text { margin: 0; color: var(--muted); font-size: 12px; line-height: 1.5; }

.toast {
  position: fixed;
  top: 18px;
  right: 18px;
  z-index: 500;
  max-width: min(380px, calc(100vw - 36px));
  padding: 12px 14px;
  border: 1px solid #26292e;
  border-radius: var(--radius);
  background: var(--black);
  color: var(--white);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-6px);
  transition: opacity .14s ease, transform .14s ease;
  font-size: 13px;
  line-height: 1.4;
}
.toast.show { opacity: 1; transform: translateY(0); }
.toast.error { border-color: var(--blue); }

.auth-body { min-height: 100dvh; background: var(--white); }
.auth-layout { min-height: 100dvh; display: grid; grid-template-columns: minmax(340px, .9fr) minmax(520px, 1.1fr); }
.auth-brand-panel {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: clamp(34px, 5vw, 72px);
  background: #eef6ff;
  color: var(--text);
}
.auth-brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
  font-size: 25px;
  font-weight: 700;
  letter-spacing: -.8px;
}
.auth-brand img { width: 38px; height: 38px; border-radius: 10px; }
.auth-brand-copy { max-width: 450px; margin-block: auto; }
.auth-brand-copy h1 { margin: 0 0 16px; font-size: clamp(42px, 5vw, 72px); line-height: .98; letter-spacing: -2.8px; font-weight: 600; }
.auth-brand-copy p { margin: 0; max-width: 420px; color: var(--text-soft); font-size: 16px; line-height: 1.58; }
.auth-brand-foot { color: var(--muted); font-size: 12px; }
.auth-form-panel { min-height: 100dvh; display: grid; place-items: center; padding: 40px; background: var(--white); }
.auth-form-wrap { width: min(420px, 100%); }
.auth-mobile-brand { display: none; margin-bottom: 42px; }
.auth-heading { margin-bottom: 28px; }
.auth-heading h2 { margin: 0 0 8px; font-size: 34px; line-height: 1.05; letter-spacing: -1.4px; font-weight: 600; }
.auth-heading p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.auth-form { display: grid; gap: 17px; }
.auth-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.auth-switch { margin: 22px 0 0; color: var(--muted); font-size: 13px; }
.auth-switch a, .auth-link { color: var(--text); font-weight: 600; text-underline-offset: 3px; }
.verification-actions { display: grid; gap: 10px; }

.dashboard-body { height: 100dvh; overflow: hidden; background: var(--black); }
.dashboard-shell {
  height: 100dvh;
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  overflow: hidden;
  background: var(--black);
}
.sidebar {
  min-width: 0;
  height: 100dvh;
  overflow: hidden;
  padding: 20px 14px 14px;
  background: var(--black);
  color: var(--white);
}
.sidebar-inner {
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
}
.sidebar-header { display: flex; align-items: center; justify-content: space-between; padding: 2px 7px 16px; }
.logo { display: inline-flex; align-items: center; gap: 10px; color: var(--white); text-decoration: none; font-size: 23px; font-weight: 700; letter-spacing: -.8px; }
.logo img { width: 32px; height: 32px; border-radius: 9px; }
.nav-list {
  min-height: 0;
  display: grid;
  align-content: start;
  gap: 3px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #2d3035 transparent;
  padding-right: 4px;
  margin-right: -4px;
}
.nav-list a,
.nav-parent-row {
  border-radius: var(--radius);
  color: #aeb3bc;
  font-size: 14px;
  transition: color .14s ease, background-color .14s ease;
}
.nav-list > a,
.nav-parent-link,
.nav-subitem {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 40px;
  padding: 9px 11px;
  color: inherit;
  text-decoration: none;
}
.nav-list > a:hover,
.nav-parent-row:hover { color: var(--white); background: #15171b; }
.nav-list > a.active,
.nav-parent-row.active { color: var(--white); background: #1a1d22; }
.nav-group { min-width: 0; }
.nav-parent-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 36px;
  align-items: stretch;
  overflow: hidden;
}
.nav-parent-link { min-width: 0; border-radius: var(--radius) 0 0 var(--radius); }
.nav-expand-button {
  display: grid;
  place-items: center;
  width: 36px;
  min-height: 40px;
  padding: 0;
  border: 0;
  border-left: 1px solid transparent;
  background: transparent;
  color: inherit;
  cursor: pointer;
  transition: background-color .14s ease, border-color .14s ease;
}
.nav-parent-row:hover .nav-expand-button,
.nav-parent-row.active .nav-expand-button { border-left-color: #2a2d33; }
.nav-expand-button:hover,
.nav-expand-button:focus-visible { background: #24272d; outline: none; }
.nav-chevron {
  width: 7px;
  height: 7px;
  border-right: 1.7px solid currentColor;
  border-bottom: 1.7px solid currentColor;
  transform: rotate(45deg) translate(-1px, -1px);
  transition: transform .16s ease;
}
.nav-group.open .nav-chevron { transform: rotate(225deg) translate(-1px, -1px); }
.nav-sublist {
  max-height: 0;
  margin: 0 0 0 20px;
  padding-left: 12px;
  overflow: hidden;
  border-left: 1px solid transparent;
  opacity: 0;
  transition: max-height .18s ease, margin-top .18s ease, opacity .14s ease, border-color .14s ease;
}
.nav-group.open .nav-sublist {
  max-height: 320px;
  margin-top: 3px;
  border-left-color: #292c31;
  opacity: 1;
}
.nav-subitem { min-height: 37px; padding: 8px 10px; border-radius: var(--radius); }
.nav-subitem:hover { color: var(--white); background: #15171b; }
.nav-subitem.active { color: var(--white); background: #1a1d22; }
.nav-list [data-icon] { width: 19px; height: 19px; display: grid; place-items: center; flex: 0 0 auto; }
.nav-list svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.nav-count {
  margin-left: auto;
  min-width: 12px;
  color: #737984;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.nav-list a.active .nav-count,
.nav-list a:hover .nav-count,
.nav-parent-row:hover .nav-count,
.nav-parent-row.active .nav-count { color: #b9bec7; }
.sidebar-foot {
  display: grid;
  gap: 6px;
  padding: 11px 8px 0;
  border-top: 1px solid #202227;
  background: var(--black);
}
.sidebar-user { display: grid; gap: 2px; min-width: 0; color: #aeb3bc; font-size: 11px; line-height: 1.35; }
.sidebar-user strong { overflow: hidden; color: var(--white); font-size: 12px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-user span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-action { color: #aeb3bc; font-size: 12px; }
.sidebar-action:hover { color: var(--white); }
.sidebar-scrim { display: none; }

.main-frame {
  height: 100dvh;
  min-width: 0;
  overflow: hidden;
  border-radius: var(--shell-radius) 0 0 var(--shell-radius);
  background: var(--white);
}
.main-scroll {
  height: 100%;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  background: var(--white);
}
.dashboard-header {
  position: sticky;
  top: 0;
  z-index: 30;
  min-height: 88px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 20px var(--content-inline);
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(10px);
}
.dashboard-header-left { display: flex; align-items: center; gap: 13px; min-width: 0; }
.dashboard-header h1 { margin: 0; overflow: hidden; font-size: 30px; line-height: 1; letter-spacing: -1px; font-weight: 650; text-overflow: ellipsis; white-space: nowrap; }
.dashboard-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; justify-content: flex-end; }
.dashboard-content { width: min(1220px, 100%); padding: 32px var(--content-inline) 72px; }

.section { padding: 28px 0; border-top: 1px solid var(--line); }
.section:first-child { padding-top: 0; border-top: 0; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 17px; }
.section-head h2 { margin: 0; color: var(--text); font-size: 20px; line-height: 1.2; letter-spacing: -.45px; font-weight: 650; }
.section-head p { margin: 5px 0 0; color: #68707b; font-size: 13px; line-height: 1.45; }
.section-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.split { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(300px, .8fr); gap: 30px; }
.split.equal { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.metric-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0 0 30px; }
.metric { min-width: 0; min-height: 104px; display: flex; flex-direction: column; justify-content: center; padding: 18px 19px; border: 1px solid #e9ecf0; border-radius: var(--radius-large); background: var(--surface-soft); box-shadow: 0 1px 2px rgba(15, 18, 24, .025); }
.metric + .metric { padding-left: 19px; border-left: 1px solid #e9ecf0; }
.metric strong { display: block; font-size: 31px; line-height: 1; letter-spacing: -1.3px; font-weight: 650; font-variant-numeric: tabular-nums; }
.metric span { display: block; margin-top: 8px; color: #68707b; font-size: 12px; font-weight: 550; letter-spacing: .01em; }
.list { border-top: 1px solid var(--line); }
.list-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: center; padding: 15px 0; border-bottom: 1px solid var(--line); }
.list-row-main { min-width: 0; }
.list-row-title { margin: 0 0 4px; overflow-wrap: anywhere; font-size: 15px; font-weight: 600; }
.list-row-meta { color: var(--muted); font-size: 12px; line-height: 1.5; }
.list-row-actions { display: flex; align-items: center; justify-content: flex-end; gap: 7px; flex-wrap: wrap; }
.empty-state { padding: 22px 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.progress { height: 5px; margin-top: 10px; overflow: hidden; border-radius: 3px; background: #eceef1; }
.progress > i { display: block; height: 100%; background: var(--blue); }
.tag { display: inline-flex; align-items: center; min-height: 23px; padding: 3px 7px; border: 1px solid var(--line); border-radius: 5px; background: var(--white); color: var(--text-soft); font-size: 10px; font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.tag.blue { border-color: #ccd1ff; background: var(--blue-soft); color: #4453db; }
.inline-status { display: inline-flex; align-items: center; gap: 7px; color: var(--text-soft); font-size: 12px; }
.inline-status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--blue); }

.today-focus { display: flex; align-items: center; justify-content: space-between; gap: 28px; padding: 2px 0 30px; }
.today-focus-copy { min-width: 0; max-width: 720px; }
.today-focus h2 { margin: 0 0 8px; font-size: 28px; line-height: 1.12; letter-spacing: -.85px; font-weight: 650; }
.today-focus p { margin: 0; color: #68707b; font-size: 13px; line-height: 1.5; }
.today-focus-actions { display: flex; gap: 9px; flex: 0 0 auto; }
.today-focus-actions .button { min-width: 110px; }
body[data-page="today"] .empty-state { padding: 12px 0 4px; border: 0; border-radius: 0; background: transparent; }
.notice-list { display: grid; gap: 10px; }
.notice-row { display: grid; grid-template-columns: 4px minmax(0, 1fr) auto; gap: 13px; align-items: center; overflow: hidden; padding: 14px 14px 14px 0; border: 1px solid var(--line); border-radius: var(--radius-large); background: var(--white); box-shadow: 0 1px 2px rgba(15, 18, 24, .025); }
.notice-row:first-child { border-top: 1px solid var(--line); }
.notice-bar { width: 4px; min-height: 44px; align-self: stretch; border-radius: 0 999px 999px 0; background: var(--blue); }
.notice-row strong { display: block; margin-bottom: 4px; font-size: 14px; font-weight: 650; }
.notice-row p { margin: 0; color: var(--text-soft); font-size: 13px; line-height: 1.45; }

.collection { border-top: 1px solid var(--line); }
.collection-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 22px; padding: 20px 0; border-bottom: 1px solid var(--line); }
.collection-item h3 { margin: 6px 0 6px; font-size: 17px; line-height: 1.25; letter-spacing: -.3px; font-weight: 600; }
.collection-item p { margin: 0; color: var(--text-soft); font-size: 13px; line-height: 1.55; }
.collection-item-side { min-width: 120px; text-align: right; }
.collection-item-side strong { font-size: 24px; letter-spacing: -.7px; }
.collection-item-actions { display: flex; gap: 7px; justify-content: flex-end; flex-wrap: wrap; margin-top: 12px; }
.memory-type { color: #5362eb; font-size: 10px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.proof-metrics { display: grid; gap: 6px; margin-top: 12px; }
.proof-metric { display: flex; justify-content: space-between; gap: 14px; padding-top: 7px; border-top: 1px solid var(--line); color: var(--text-soft); font-size: 12px; }

.upload-area { display: grid; grid-template-columns: minmax(0, .7fr) minmax(420px, 1fr); gap: 48px; align-items: start; }
.upload-area h2 { margin: 0 0 8px; font-size: 21px; font-weight: 600; }
.upload-area p { margin: 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.focus-stage { min-height: 540px; display: grid; place-items: center; text-align: center; }
.focus-clock { margin-bottom: 26px; font-size: clamp(74px, 11vw, 138px); line-height: .9; letter-spacing: -5px; font-weight: 500; }
.focus-actions { display: flex; justify-content: center; gap: 8px; }
.journal-compose { display: grid; gap: 12px; max-width: 760px; margin-bottom: 28px; }
.journal-entry { padding: 20px 0; border-top: 1px solid var(--line); }
.journal-entry h3 { margin: 0 0 8px; font-size: 16px; font-weight: 600; }
.journal-entry p { margin: 0; color: var(--text-soft); white-space: pre-wrap; line-height: 1.6; }
.journal-entry-foot { display: flex; justify-content: space-between; gap: 12px; margin-top: 13px; color: var(--muted); font-size: 12px; }

.settings-profile {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 16px;
  align-items: center;
  padding: 0 0 26px;
  border-bottom: 1px solid var(--line);
}
.settings-avatar {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--black);
  color: var(--white);
  font-size: 22px;
  font-weight: 600;
}
.settings-profile h2 { margin: 0 0 4px; font-size: 21px; letter-spacing: -.4px; font-weight: 600; }
.settings-profile p { margin: 0; color: var(--muted); font-size: 13px; }
.settings-layout { display: grid; grid-template-columns: minmax(190px, .33fr) minmax(0, 1fr); gap: 42px; padding-top: 26px; }
.settings-nav { display: grid; align-content: start; gap: 3px; position: sticky; top: 114px; }
.settings-nav button { min-height: 38px; border: 0; border-radius: var(--radius); background: transparent; color: var(--text-soft); padding: 8px 10px; text-align: left; font-size: 13px; }
.settings-nav button:hover { background: #f8f8f9; color: var(--text); }
.settings-nav button.active { background: var(--blue-soft); color: #4453db; }
.settings-pane { display: none; }
.settings-pane.active { display: block; }
.settings-group { padding: 0 0 28px; }
.settings-group + .settings-group { padding-top: 28px; border-top: 1px solid var(--line); }
.settings-group h3 { margin: 0 0 6px; font-size: 18px; font-weight: 600; }
.settings-group > p { margin: 0 0 18px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.settings-form { display: grid; gap: 16px; max-width: 720px; }
.personality-form { max-width: 860px; }
.personality-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.personality-option { display: block; cursor: pointer; }
.personality-option > input { position: absolute; opacity: 0; pointer-events: none; }
.personality-card-body { display: block; min-height: 96px; padding: 15px 16px; border: 1px solid var(--line); border-radius: 14px; background: #fff; transition: border-color .16s ease, background .16s ease, box-shadow .16s ease, transform .16s ease; }
.personality-card-body strong { display: block; margin-bottom: 6px; color: var(--text); font-size: 14px; font-weight: 650; text-transform: lowercase; }
.personality-card-body > span { display: block; color: var(--muted); font-size: 12px; line-height: 1.45; }
.personality-option:hover .personality-card-body { border-color: #cfd3ff; }
.personality-option > input:focus-visible + .personality-card-body { outline: 3px solid rgba(86, 100, 255, .2); outline-offset: 2px; }
.personality-option > input:checked + .personality-card-body { border-color: #6672f5; background: var(--blue-soft); box-shadow: inset 0 0 0 1px #6672f5; }
.personality-preview { min-height: 20px; margin: 0; color: var(--text-soft); font-size: 13px; line-height: 1.45; }
.preference-list { border-top: 1px solid var(--line); }
.preference-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: center; padding: 15px 0; border-bottom: 1px solid var(--line); }
.preference-row strong { display: block; margin-bottom: 3px; font-size: 14px; font-weight: 600; }
.preference-row span { color: var(--muted); font-size: 12px; line-height: 1.45; }
.connection-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px; align-items: center; padding: 15px 0; border-top: 1px solid var(--line); }
.connection-row:last-child { border-bottom: 1px solid var(--line); }
.connection-row strong { display: block; margin-bottom: 3px; font-size: 14px; }
.connection-row p { margin: 0; color: var(--muted); font-size: 12px; }
.account-actions { display: flex; gap: 8px; flex-wrap: wrap; }

dialog.modal {
  width: min(520px, calc(100vw - 28px));
  max-height: calc(100dvh - 40px);
  margin: auto;
  padding: 0;
  overflow: auto;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: var(--white);
  color: var(--text);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .18);
}
dialog.modal::backdrop { background: rgba(8, 10, 13, .48); }
.modal-form { display: grid; gap: 0; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 22px 14px; }
.modal-head h2 { margin: 0; font-size: 21px; letter-spacing: -.45px; font-weight: 600; }
.modal-body { display: grid; gap: 15px; padding: 0 22px 20px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 22px 20px; border-top: 1px solid var(--line); }
.check-row { display: flex; grid-template-columns: none; align-items: center; gap: 10px; color: var(--text); }
.confirm-copy { margin: 0; color: var(--text-soft); font-size: 14px; line-height: 1.55; }

.onboarding-body { min-height: 100dvh; background: var(--white); }
.onboarding-shell { width: min(880px, calc(100% - 40px)); margin: 0 auto; padding: 34px 0 70px; }
.onboarding-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-bottom: 26px; border-bottom: 1px solid var(--line); }
.onboarding-header .auth-brand img { width: 34px; height: 34px; }
.onboarding-intro { padding: 38px 0 26px; }
.onboarding-intro h1 { margin: 0 0 9px; font-size: 34px; line-height: 1.08; letter-spacing: -1.2px; font-weight: 600; }
.onboarding-intro p { margin: 0; color: var(--muted); font-size: 14px; }
.onboarding-form { display: grid; gap: 18px; max-width: 760px; }

.page-summary {
  max-width: 720px;
  margin: 0 0 28px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}
.button-link { display: grid; place-items: center; text-decoration: none; }
.top-gap-sm { margin-top: 14px; }
.form-action { margin-top: 16px; }
.form-action.compact { margin-top: 14px; }
.list-row-meta.spaced { margin-top: 8px; }

@media (max-width: 980px) {
  :root { --sidebar-width: 204px; }
  .split, .split.equal, .upload-area { grid-template-columns: 1fr; gap: 28px; }
  .settings-layout { grid-template-columns: 1fr; gap: 24px; }
  .personality-grid { grid-template-columns: 1fr; }
  .settings-nav { position: static; display: flex; overflow-x: auto; padding-bottom: 4px; }
  .settings-nav button { flex: 0 0 auto; }
}

@media (max-width: 760px) {
  .auth-layout { display: block; }
  .auth-brand-panel { display: none; }
  .auth-form-panel { min-height: 100dvh; place-items: start stretch; padding: 28px 22px 50px; }
  .auth-form-wrap { width: min(460px, 100%); margin: 0 auto; }
  .auth-mobile-brand { display: block; }
  .dashboard-shell { display: block; }
  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 90;
    width: min(284px, 84vw);
    transform: translateX(-105%);
    transition: transform .18s ease;
  }
  .sidebar.open { transform: translateX(0); }
  .sidebar-scrim {
    position: fixed;
    inset: 0;
    z-index: 80;
    display: block;
    background: rgba(0,0,0,.38);
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease;
  }
  .sidebar.open + .sidebar-scrim { opacity: 1; pointer-events: auto; }
  .main-frame { height: 100dvh; border-radius: 0; }
  .mobile-only { display: grid !important; }
  :root { --content-inline: 18px; }
  .dashboard-header { min-height: 74px; padding: 16px var(--content-inline); }
  .dashboard-header h1 { font-size: 26px; }
  .dashboard-content { padding: 24px var(--content-inline) 58px; }
  .metric-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .today-focus { align-items: flex-start; flex-direction: column; }
  .today-focus-actions { width: 100%; }
  .today-focus-actions .button { flex: 1; }
  .collection-item { grid-template-columns: 1fr; }
  .collection-item-side { min-width: 0; text-align: left; }
  .collection-item-actions { justify-content: flex-start; }
  .settings-profile { grid-template-columns: auto minmax(0, 1fr); }
  .settings-profile > .button { grid-column: 1 / -1; width: 100%; }
  .field-row { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
  .dashboard-actions .button.secondary { display: none; }
  .list-row { grid-template-columns: 1fr; }
  .list-row-actions { justify-content: flex-start; }
  .modal-foot { flex-direction: column-reverse; }
  .modal-foot .button { width: 100%; }
  .focus-clock { font-size: 72px; letter-spacing: -3px; }
}

.ai-usage-line { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 11px 0; border-top: 1px solid var(--line); font-size: 13px; }
.ai-usage-line strong { font-size: 13px; font-weight: 600; text-align: right; }
.ai-usage-track { height: 5px; overflow: hidden; background: #eef4ff; border-radius: 3px; }
.ai-usage-track span { display: block; width: 0; height: 100%; background: var(--blue); transition: width .2s ease; }

.integrations-intro {
  display: flex;
  justify-content: space-between;
  gap: 28px;
  padding: 2px 0 28px;
  border-bottom: 1px solid var(--line);
}
.integrations-intro h2,
.integration-privacy h2 {
  margin: 0 0 8px;
  font-size: 22px;
  line-height: 1.2;
  letter-spacing: -.45px;
  font-weight: 600;
}
.integrations-intro p,
.integration-privacy p {
  max-width: 720px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}
.integration-groups { display: grid; gap: 38px; padding-top: 30px; }
.integration-group { display: grid; gap: 10px; }
.integration-group-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; }
.integration-group-head h2 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: -.25px; }
.integration-list { border-top: 1px solid var(--line); }
.integration-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  gap: 15px;
  align-items: center;
  padding: 17px 0;
  border-bottom: 1px solid var(--line);
}
.integration-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius);
  background: var(--black);
  color: var(--white);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .03em;
}
.integration-copy { min-width: 0; }
.integration-title-row { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.integration-title-row h3 { margin: 0; font-size: 15px; font-weight: 600; }
.integration-copy > p { margin: 4px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }
.integration-account { margin-top: 7px; color: var(--text-soft); font-size: 12px; }
.integration-note { margin-top: 7px; color: var(--text-soft); font-size: 11px; }
.integration-data { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 9px; }
.integration-data span {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text-soft);
  font-size: 10px;
}
.integration-action { min-width: 126px; display: flex; justify-content: flex-end; }
.compact-button { min-width: 118px; min-height: 38px; }
.integration-coming-soon,
.integration-coming-soon:disabled {
  opacity: .58;
  filter: grayscale(1) blur(.22px);
  background: #ededed;
  border-color: #dedede;
  color: #616161;
  box-shadow: none;
  cursor: not-allowed;
  pointer-events: none;
}
.integration-privacy { margin-top: 42px; padding-top: 28px; border-top: 1px solid var(--line); }

@media (max-width: 680px) {
  .integration-card { grid-template-columns: 42px minmax(0, 1fr); align-items: start; }
  .integration-action { grid-column: 1 / -1; justify-content: stretch; min-width: 0; }
  .integration-action .button { width: 100%; }
}

.integration-button-group {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

@media (max-width: 760px) {
  .integration-button-group { width: 100%; }
  .integration-button-group .button { flex: 1 1 120px; }
}


:root {
    --chirp-font: "Google Sans", Arial, sans-serif;
}

html,
body,
button,
input,
textarea,
select {
    font-family: var(--chirp-font);
}

.integration-mark.has-logo {
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--white);
  color: var(--text);
}

.integration-mark.has-logo img {
  width: 28px;
  height: 28px;
  object-fit: contain;
}

.integration-mark.has-logo:hover {
  background: var(--white);
}

.dashboard-body[data-page="chat"] .main-scroll {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dashboard-body[data-page="chat"] .dashboard-content {
  width: 100%;
  max-width: none;
  min-height: 0;
  flex: 1;
  padding: 0;
}

.chat-channel-state {
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
}

.chat-page {
  width: min(920px, 100%);
  height: 100%;
  min-height: 0;
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 56px);
  display: flex;
  flex-direction: column;
}

.chat-messages {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  padding: 26px 0 20px;
}

.chat-loading,
.chat-error,
.chat-empty {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.chat-empty {
  min-height: 55%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 6px;
  text-align: center;
}

.chat-empty strong {
  color: var(--text);
  font-size: 18px;
  font-weight: 600;
  letter-spacing: -.3px;
}

.chat-empty span {
  max-width: 460px;
}

.chat-day-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0 18px;
  color: var(--muted);
  font-size: 11px;
}

.chat-day-divider::before,
.chat-day-divider::after {
  height: 1px;
  flex: 1;
  background: var(--line);
  content: "";
}

.chat-message-row {
  display: flex;
  margin: 0 0 16px;
}

.chat-message-row.user {
  justify-content: flex-end;
}

.chat-message-row.assistant {
  justify-content: flex-start;
}

.chat-message-bubble {
  max-width: min(700px, 84%);
  padding: 11px 14px;
  border-radius: 14px;
  color: var(--text);
  background: #f5f6f7;
}

.chat-message-row.user .chat-message-bubble {
  color: var(--white);
  background: var(--black);
  border-bottom-right-radius: 5px;
}

.chat-message-row.assistant .chat-message-bubble {
  border-bottom-left-radius: 5px;
}

.chat-message-body {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 14px;
  line-height: 1.55;
}

.chat-message-meta {
  margin-top: 6px;
  color: #777d86;
  font-size: 10px;
  line-height: 1.2;
}

.chat-message-row.user .chat-message-meta {
  color: #adb2ba;
  text-align: right;
}

.chat-typing {
  color: var(--muted);
  font-size: 12px;
}

.chat-typing::after {
  display: inline-block;
  width: 14px;
  content: "…";
  animation: chat-pulse 1.1s steps(2, end) infinite;
}

@keyframes chat-pulse {
  50% { opacity: .35; }
}

.chat-error {
  margin: 12px 0;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  color: var(--text);
  background: #fafafa;
}

.chat-composer-area {
  flex: 0 0 auto;
  padding: 14px 0 20px;
  border-top: 1px solid var(--line);
  background: var(--white);
}

.chat-composer {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px;
  align-items: end;
}

.chat-composer textarea {
  min-height: 46px;
  max-height: 180px;
  resize: none;
  padding: 12px 14px;
  line-height: 1.45;
}

.chat-send-button {
  min-width: 68px;
  min-height: 46px;
  padding: 10px 15px;
  border: 1px solid var(--black);
  border-radius: var(--radius);
  color: var(--white);
  background: var(--black);
  font-size: 13px;
  font-weight: 600;
}

.chat-send-button:hover {
  background: var(--black-2);
}

.chat-send-button:disabled {
  opacity: .48;
  cursor: not-allowed;
}

.chat-composer-foot {
  min-height: 24px;
  padding-top: 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: 10px;
}

.chat-phone-option {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text-soft);
  white-space: nowrap;
}

.chat-phone-option input {
  width: 16px;
  height: 16px;
  min-height: 16px;
}

@media (max-width: 760px) {
  .dashboard-body[data-page="chat"] .dashboard-header {
    flex: 0 0 auto;
  }

  .chat-page {
    padding: 0 18px;
  }

  .chat-messages {
    padding-top: 18px;
  }

  .chat-message-bubble {
    max-width: 90%;
  }

  .chat-composer-area {
    padding-bottom: calc(14px + env(safe-area-inset-bottom));
  }

  .chat-composer-foot > span:first-child {
    display: none;
  }

  .chat-composer-foot {
    justify-content: flex-end;
  }
}

@media (max-width: 480px) {
  .chat-channel-state {
    display: none;
  }

  .chat-send-button {
    min-width: 60px;
  }
}


.admin-intro { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; margin-bottom: 18px; padding: 20px; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); }
.admin-intro h2 { margin: 9px 0 6px; font-size: 22px; }
.admin-intro p { margin: 0; max-width: 720px; color: var(--text-soft); }
.admin-intro-note { max-width: 270px; padding: 11px 12px; border-radius: var(--radius); background: #f7f7f8; color: var(--text-soft); font-size: 12px; line-height: 1.45; }
.admin-personality-layout { display: grid; grid-template-columns: minmax(220px, 280px) minmax(0, 1fr); gap: 16px; align-items: start; }
.admin-personality-sidebar { position: sticky; top: 92px; display: grid; gap: 10px; padding: 14px; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); }
.admin-search { display: grid; gap: 6px; font-size: 12px; color: var(--text-soft); }
.admin-personality-list { display: grid; gap: 4px; max-height: calc(100vh - 210px); overflow: auto; }
.admin-personality-item { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 54px; border: 1px solid transparent; border-radius: var(--radius); background: transparent; padding: 9px 10px; text-align: left; color: var(--text); }
.admin-personality-item:hover { background: #f8f8f9; }
.admin-personality-item.active { border-color: #cdd3ff; background: var(--blue-soft); }
.admin-personality-item span:first-child { min-width: 0; display: grid; gap: 2px; }
.admin-personality-item strong { font-size: 13px; text-transform: none; }
.admin-personality-item small { color: var(--text-soft); overflow: hidden; text-overflow: ellipsis; }
.admin-personality-editor { min-width: 0; }
.admin-personality-editor > .empty-state { min-height: 240px; display: grid; place-items: center; border: 1px solid var(--border); border-radius: var(--radius-lg); background: var(--surface); }
.admin-editor-head { align-items: flex-start; }
.admin-editor-head h2 { margin: 9px 0 4px; }
.admin-editor-head p { margin: 0; color: var(--text-soft); font-size: 12px; }
.admin-editor-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.compact-group { margin-bottom: 14px; }
.admin-trait-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.admin-enabled-row { margin-top: 8px; }
.admin-chat-preview { display: grid; gap: 8px; padding: 16px; border: 1px solid var(--border); border-radius: var(--radius-lg); background: #fafafa; }
.admin-preview-user, .admin-preview-assistant { width: fit-content; max-width: min(78%, 620px); padding: 10px 12px; border-radius: 16px; white-space: pre-wrap; font-size: 14px; line-height: 1.4; }
.admin-preview-user { justify-self: end; background: #111; color: #fff; border-bottom-right-radius: 5px; }
.admin-preview-assistant { justify-self: start; background: #ececef; color: #151517; border-bottom-left-radius: 5px; }
.admin-sticky-save { position: sticky; bottom: 12px; z-index: 4; display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 14px; border: 1px solid var(--border); border-radius: var(--radius-lg); background: rgba(255,255,255,.94); box-shadow: 0 10px 30px rgba(20,20,25,.09); backdrop-filter: blur(14px); }
.admin-sticky-save span { color: var(--text-soft); font-size: 12px; }
.not-found-body { min-height: 100vh; margin: 0; display: grid; place-items: center; background: #f7f7f8; color: #111; font-family: "Google Sans", system-ui, sans-serif; padding: 24px; }
.not-found-card { width: min(420px, 100%); display: grid; justify-items: center; gap: 10px; padding: 38px 28px; border: 1px solid #e2e2e5; border-radius: 22px; background: #fff; text-align: center; box-shadow: 0 22px 65px rgba(20,20,25,.08); }
.not-found-card img { width: 48px; height: 48px; }
.not-found-card > span { margin-top: 8px; color: #6b6b72; font-size: 13px; font-weight: 700; letter-spacing: .12em; }
.not-found-card h1 { margin: 0; font-size: 26px; }
.not-found-card p { margin: 0 0 10px; color: #6b6b72; }

@media (max-width: 900px) {
  .admin-intro { display: grid; }
  .admin-intro-note { max-width: none; }
  .admin-personality-layout { grid-template-columns: 1fr; }
  .admin-personality-sidebar { position: static; }
  .admin-personality-list { max-height: 260px; }
  .admin-trait-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  .admin-trait-grid { grid-template-columns: 1fr; }
  .admin-editor-head, .admin-sticky-save { align-items: stretch; }
  .admin-editor-actions, .admin-sticky-save { display: grid; }
  .admin-preview-user, .admin-preview-assistant { max-width: 92%; }
}

.chat-message-stack {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: min(700px, 84%);
}

.chat-message-row.user .chat-message-stack {
  align-items: flex-end;
}

.chat-message-stack .chat-message-bubble {
  max-width: 100%;
}

.chat-report-area {
  width: min(430px, 100%);
  margin-top: 6px;
}

.chat-report-trigger {
  padding: 0;
  border: 0;
  background: transparent;
  color: #858a92;
  font: inherit;
  font-size: 10px;
  line-height: 1.4;
  cursor: pointer;
}

.chat-report-trigger:hover {
  color: var(--text);
  text-decoration: underline;
}

.chat-report-trigger:disabled {
  color: #9ba0a8;
  cursor: default;
  text-decoration: none;
}

.chat-report-form {
  display: grid;
  gap: 8px;
  margin-top: 7px;
  padding: 10px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: var(--white);
  box-shadow: 0 10px 28px rgba(12, 14, 18, .07);
}

.chat-report-form[hidden] {
  display: none;
}

.chat-report-form select,
.chat-report-form textarea {
  width: 100%;
  min-height: 36px;
  padding: 8px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--white);
  color: var(--text);
  font: inherit;
  font-size: 12px;
}

.chat-report-form textarea {
  resize: vertical;
  line-height: 1.45;
}

.chat-report-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.chat-report-actions button {
  min-height: 30px;
  padding: 5px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--white);
  color: var(--text);
  font: inherit;
  font-size: 11px;
  cursor: pointer;
}

.chat-report-actions button[type="submit"] {
  border-color: var(--black);
  background: var(--black);
  color: var(--white);
}

.admin-reports-page {
  width: min(980px, 100%);
  margin: 0 auto;
}

.admin-reports-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.admin-report-filters {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.admin-report-filter {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 34px;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.admin-report-filter span {
  min-width: 18px;
  padding: 1px 5px;
  border-radius: 999px;
  background: #f0f1f3;
  color: #656a72;
  text-align: center;
  font-size: 10px;
}

.admin-report-filter:hover,
.admin-report-filter.active {
  border-color: var(--line-strong);
  background: var(--white);
  color: var(--text);
}

.admin-reports-state {
  padding: 52px 0;
  color: var(--muted);
  text-align: center;
  font-size: 13px;
}

.admin-reports-list {
  display: grid;
  gap: 14px;
}

.admin-report-item {
  padding: 20px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--white);
}

.admin-report-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.admin-report-title {
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
}

.admin-report-meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.admin-report-status {
  padding: 4px 8px;
  border-radius: 999px;
  background: #f0f1f3;
  color: #646970;
  font-size: 10px;
  text-transform: lowercase;
}

.admin-report-status.open {
  background: #eef4ff;
  color: #2557a7;
}

.admin-report-status.reviewing {
  background: #fff5dd;
  color: #8a5a00;
}

.admin-report-status.resolved {
  background: #eaf7ef;
  color: #287447;
}

.admin-report-context {
  display: grid;
  gap: 9px;
  margin-top: 18px;
}

.admin-report-message,
.admin-report-user-note {
  padding: 12px 14px;
  border-radius: 10px;
  background: #f6f7f8;
}

.admin-report-message.user {
  margin-left: 8%;
  background: #111;
  color: #fff;
}

.admin-report-message span,
.admin-report-user-note span {
  display: block;
  margin-bottom: 5px;
  color: #858a92;
  font-size: 9px;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.admin-report-message.user span {
  color: #b7bbc1;
}

.admin-report-message p,
.admin-report-user-note p {
  margin: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 13px;
  line-height: 1.55;
}

.admin-report-user-note {
  margin-top: 9px;
  border: 1px solid #e7e8eb;
  background: #fff;
}

.admin-report-review-form {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) auto;
  align-items: end;
  gap: 10px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.admin-report-review-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 10px;
}

.admin-report-review-form select,
.admin-report-review-form textarea {
  width: 100%;
  min-height: 38px;
  padding: 8px 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--white);
  color: var(--text);
  font: inherit;
  font-size: 12px;
}

.admin-report-review-form textarea {
  resize: vertical;
  line-height: 1.4;
}

@media (max-width: 760px) {
  .chat-message-stack {
    max-width: 88%;
  }

  .admin-reports-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-report-review-form {
    grid-template-columns: 1fr;
  }

  .admin-report-message.user {
    margin-left: 0;
  }
}

.notification-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.chat-checkin-area {
  margin-top: 7px;
}

.chat-checkin-mute {
  appearance: none;
  padding: 0;
  border: 0;
  background: transparent;
  color: #8a8f98;
  font: inherit;
  font-size: 12px;
  cursor: pointer;
}

.chat-checkin-mute:hover:not(:disabled) {
  color: #20242a;
}

.chat-checkin-mute:disabled {
  cursor: default;
  opacity: .72;
}

@media (max-width: 720px) {
  .notification-actions .button {
    width: 100%;
  }
}


:root {
  --radius: 10px;
  --radius-small: 8px;
  --radius-large: 10px;
  --shell-radius: 22px;
  --surface-soft: #f7f7f9;
  --surface-muted: #f1f2f5;
  --content-inline: clamp(30px, 4.2vw, 64px);
}

.dashboard-header {
  min-height: 92px;
  border-bottom: 0;
  background: rgba(255, 255, 255, .98);
  box-shadow: none;
}

.dashboard-content {
  width: min(1320px, 100%);
  padding: 30px var(--content-inline) 76px;
}

.dashboard-header h1 {
  font-size: 30px;
  font-weight: 650;
  letter-spacing: -1.05px;
}

.button {
  --angle: 90deg;
  --show: 0;
  position: relative;
  isolation: isolate;
  min-height: 43px;
  padding: 0 19px;
  overflow: visible;
  border-radius: 999px;
  box-shadow: none;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -.035em;
  transform: none;
  transition: border-color .16s ease, background-color .16s ease, color .16s ease;
}

.button::before {
  content: "";
  position: absolute;
  inset: -1px;
  z-index: 0;
  padding: 2px;
  border-radius: inherit;
  background: conic-gradient(
    from var(--angle),
    #4285f4 0deg,
    #4285f4 82deg,
    #0429fb 172deg,
    #ffffff 230deg,
    #ffffff 288deg,
    #ffffff 326deg,
    #4285f4 360deg
  );
  opacity: var(--show);
  pointer-events: none;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
}

.button > * {
  position: relative;
  z-index: 1;
}

.button.primary,
.button.primary:hover:not(:disabled) {
  border-color: #0b0c0e;
  background: #0b0c0e;
  color: #fff;
  box-shadow: none;
  transform: none;
}

.button.secondary,
.button.secondary:hover:not(:disabled) {
  border-color: #dadce0;
  background: #fff;
  color: #202124;
  box-shadow: none;
  transform: none;
}

.button.blue,
.button.blue:hover:not(:disabled) {
  border-color: #6574ff;
  background: #6574ff;
  color: #fff;
  box-shadow: none;
  transform: none;
}

.button.quiet,
.button.quiet:hover:not(:disabled) {
  border-color: transparent;
  background: transparent;
  color: var(--text-soft);
  box-shadow: none;
  transform: none;
}

.button:active:not(:disabled),
.button:hover:not(:disabled) {
  box-shadow: none;
  transform: none;
}

.mini-button {
  min-height: 31px;
  border-radius: 999px;
  box-shadow: none;
  transform: none;
  transition: border-color .14s ease, background-color .14s ease, color .14s ease;
}

.mini-button:hover:not(:disabled),
.mini-button:active:not(:disabled) {
  border-color: #bfc5cc;
  background: #fafafa;
  box-shadow: none;
  transform: none;
}

.text-button {
  padding-inline: 0;
  background: transparent;
  color: #626871;
  transform: none;
  transition: color .14s ease;
}

.text-button:hover {
  background: transparent;
  color: #171717;
  transform: none;
}

.section,
.dashboard-content > .section,
.dashboard-content > .section + .section {
  margin-top: 0;
  padding: 0;
  border-top: 0;
}

.section-head {
  align-items: flex-start;
  margin-bottom: 19px;
}

.section-head h2 {
  font-size: 20px;
  font-weight: 650;
  letter-spacing: -.5px;
}

.section-head p {
  margin-top: 5px;
  color: #70757e;
  font-size: 13px;
  line-height: 1.45;
}

.page-summary {
  max-width: 760px;
  margin: 0 0 30px;
  color: #70757e;
  font-size: 14px;
  line-height: 1.58;
}

.dashboard-panel {
  min-width: 0;
  padding: 24px;
  border: 1px solid #e2e2e5;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

.dashboard-panel .list {
  min-width: 0;
  border-top: 0;
}

.list {
  border-top: 0;
}

.list-row {
  padding: 15px 0;
  border-bottom: 1px solid #ececef;
}

.list-row:first-child {
  padding-top: 2px;
}

.list-row:last-child {
  padding-bottom: 2px;
  border-bottom: 0;
}

.empty-state {
  padding: 12px 0 4px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #7a7d84;
}

.today-page {
  display: grid;
  gap: 28px;
}

.today-overview {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 30px;
  padding: 16px 0 2px;
}

.today-focus-copy {
  max-width: 760px;
}

.today-overview h2 {
  margin: 0 0 9px;
  font-size: clamp(29px, 3.15vw, 38px);
  line-height: 1.08;
  letter-spacing: -1.35px;
  font-weight: 650;
}

.today-overview p {
  margin: 0;
  color: #70757e;
  font-size: 14px;
  line-height: 1.55;
}

.today-focus-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
}

.today-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 0;
}

.today-metrics .metric {
  min-height: 92px;
  padding: 18px 20px;
  border: 1px solid #e2e2e5;
  border-radius: 10px;
  background: #f7f7f9;
  box-shadow: none;
  transform: none;
  transition: border-color .16s ease;
}

.today-metrics .metric + .metric {
  padding-left: 20px;
  border-left: 1px solid #e2e2e5;
}

.today-metrics .metric:hover {
  border-color: #e2e2e5;
  box-shadow: none;
  transform: none;
}

.today-metrics .metric strong {
  font-size: 31px;
  font-weight: 650;
  letter-spacing: -1.35px;
}

.today-metrics .metric span {
  margin-top: 7px;
  color: #70757e;
  font-size: 12px;
  font-weight: 500;
}

.today-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 14px;
}

.today-panel {
  display: flex;
  min-height: 248px;
  flex-direction: column;
}

.today-panel .section-head {
  min-height: 53px;
}

.today-panel .list {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.today-panel .empty-state {
  display: flex;
  flex: 1;
  align-items: center;
}

.attention-section {
  padding-top: 4px;
}

.notice-list {
  display: grid;
  gap: 18px;
}

.notice-row,
.notice-row:first-child {
  display: grid;
  grid-template-columns: 4px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  min-height: 48px;
  padding: 0;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  transform: none;
  transition: none;
}

.notice-row:hover {
  background: transparent;
  box-shadow: none;
  transform: none;
}

.notice-bar {
  width: 4px;
  min-height: 42px;
  align-self: stretch;
  border-radius: 999px;
  background: linear-gradient(180deg, #4285f4, #6b57ff);
  box-shadow: none;
}

.notice-row strong {
  margin-bottom: 4px;
  font-size: 14px;
  font-weight: 650;
}

.notice-row p {
  max-width: 980px;
  color: #626871;
  font-size: 13px;
  line-height: 1.5;
}

.schedule-page {
  display: grid;
  gap: 14px;
}

.schedule-summary {
  margin-bottom: 14px;
}

.schedule-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
  gap: 14px;
}

.schedule-panel {
  display: flex;
  min-height: 232px;
  flex-direction: column;
}

.schedule-panel .list {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.schedule-panel .empty-state {
  display: flex;
  flex: 1;
  align-items: center;
}

.connected-schedule-panel {
  min-height: 190px;
}

.collection {
  display: grid;
  gap: 10px;
  border-top: 0;
}

.collection-item {
  padding: 20px;
  border: 1px solid #e2e2e5;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

.collection-item:last-child {
  border-bottom: 1px solid #e2e2e5;
}

.journal-compose,
.upload-area,
.settings-profile,
.settings-group,
.admin-intro,
.admin-personality-sidebar,
.admin-personality-editor > .empty-state,
.admin-reports-toolbar,
.admin-reports-state {
  border: 1px solid #e2e2e5;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

.journal-compose {
  max-width: 820px;
  padding: 22px;
  margin-bottom: 14px;
}

.journal-entry {
  margin-top: 10px;
  padding: 20px;
  border: 1px solid #e2e2e5;
  border-radius: 10px;
}

.upload-area {
  padding: 24px;
}

.settings-profile {
  padding: 18px;
  border-bottom: 1px solid #e2e2e5;
}

.settings-layout {
  gap: 24px;
  padding-top: 14px;
}

.settings-group {
  padding: 22px;
}

.settings-group + .settings-group {
  margin-top: 12px;
  padding-top: 22px;
  border-top: 1px solid #e2e2e5;
}

.personality-card-body {
  border-radius: 10px;
  box-shadow: none;
  transform: none;
}

.personality-option:hover .personality-card-body {
  box-shadow: none;
  transform: none;
}

.integrations-intro {
  padding: 2px 0 24px;
  border-bottom: 0;
}

.integration-groups {
  gap: 28px;
  padding-top: 0;
}

.integration-list {
  display: grid;
  gap: 10px;
  border-top: 0;
}

.integration-card {
  padding: 16px;
  border: 1px solid #e2e2e5;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}

.integration-privacy {
  margin-top: 32px;
  padding: 24px;
  border: 1px solid #e2e2e5;
  border-radius: 10px;
}

.integration-mark {
  border-radius: 10px;
}

.focus-stage {
  min-height: min(620px, calc(100dvh - 170px));
}

.admin-intro,
.admin-personality-sidebar,
.admin-reports-toolbar,
.admin-reports-state {
  padding: 18px;
}

@media (max-width: 980px) {
  .today-grid,
  .schedule-grid {
    grid-template-columns: 1fr;
  }

  .today-panel,
  .schedule-panel {
    min-height: 210px;
  }
}

@media (max-width: 760px) {
  :root {
    --content-inline: 18px;
  }

  .dashboard-header {
    min-height: 74px;
  }

  .dashboard-content {
    padding-top: 22px;
  }

  .today-overview {
    flex-direction: column;
    padding-top: 4px;
  }

  .today-focus-actions {
    width: 100%;
  }

  .today-focus-actions .button {
    flex: 1;
  }

  .today-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-panel,
  .collection-item,
  .journal-compose,
  .upload-area,
  .settings-group,
  .integration-card,
  .integration-privacy {
    padding: 18px;
  }

  .notice-row,
  .notice-row:first-child {
    grid-template-columns: 4px minmax(0, 1fr);
  }

  .notice-row .mini-button {
    grid-column: 2;
    justify-self: start;
  }
}

@media (max-width: 520px) {
  .today-metrics {
    grid-template-columns: 1fr 1fr;
  }

  .today-metrics .metric {
    min-height: 84px;
    padding: 15px;
  }

  .today-metrics .metric + .metric {
    padding-left: 15px;
  }

  .today-overview h2 {
    font-size: 29px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .button {
    transition: none;
  }
}

.nav-icon-stack {
  position: relative;
  width: 19px;
  height: 19px;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.nav-icon-stack [data-icon] {
  width: 19px;
  height: 19px;
}

.nav-alert-dot {
  position: absolute;
  top: -2px;
  right: -3px;
  width: 8px;
  height: 8px;
  border: 2px solid var(--black);
  border-radius: 50%;
  background: #ef4444;
}

.nav-alert-dot[hidden] {
  display: none;
}

.notifications-page {
  max-width: 1040px;
}

.notifications-summary {
  max-width: 720px;
  margin-bottom: 24px;
}

.notification-tabs {
  width: fit-content;
  max-width: 100%;
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid #e2e2e5;
  border-radius: 999px;
  background: #f7f7f9;
  overflow-x: auto;
  scrollbar-width: none;
}

.notification-tabs::-webkit-scrollbar {
  display: none;
}

.notification-tab {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 15px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #666b73;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
}

.notification-tab:hover {
  color: var(--text);
}

.notification-tab.active {
  background: #fff;
  color: var(--text);
  box-shadow: inset 0 0 0 1px #dedee3;
}

.notification-tab-count {
  min-width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  padding: 0 5px;
  border-radius: 999px;
  background: #fee2e2;
  color: #b91c1c;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
  line-height: 1;
}

.notification-tab-count[hidden] {
  display: none;
}

.notification-feed {
  margin-top: 36px;
}

.notification-feed-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 14px;
}

.notification-feed-head h2 {
  margin: 0 0 5px;
  font-size: 21px;
  font-weight: 600;
  letter-spacing: -.35px;
}

.notification-feed-head p {
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.notification-feed-list {
  border-top: 1px solid #ececef;
}

.notification-item {
  width: 100%;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: start;
  gap: 14px;
  padding: 18px 4px;
  border: 0;
  border-bottom: 1px solid #ececef;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.notification-item:hover {
  background: #fafafa;
}

.notification-item-mark {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid #e2e2e5;
  border-radius: 50%;
  background: #fff;
  color: #626871;
}

.notification-item-mark [data-icon],
.notification-item-mark svg {
  width: 17px;
  height: 17px;
}

.notification-item-mark svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.notification-item-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.notification-item-copy strong {
  font-size: 14px;
  font-weight: 550;
}

.notification-item.unread .notification-item-copy strong {
  font-weight: 700;
}

.notification-item-copy > span {
  max-width: 760px;
  color: #5f646d;
  font-size: 13px;
  line-height: 1.5;
}

.notification-item-copy small {
  margin-top: 2px;
  color: #8a8f97;
  font-size: 11px;
}

.notification-unread-dot {
  width: 8px;
  height: 8px;
  margin: 7px 4px 0 0;
  border-radius: 50%;
  background: #ef4444;
}

.notification-feed-list .empty-state {
  padding: 28px 4px;
}

@media (max-width: 680px) {
  .notification-tabs {
    width: 100%;
  }

  .notification-tab {
    flex: 0 0 auto;
  }

  .notification-feed {
    margin-top: 28px;
  }

  .notification-item {
    grid-template-columns: 34px minmax(0, 1fr) auto;
    gap: 11px;
    padding: 16px 2px;
  }

  .notification-item-mark {
    width: 34px;
    height: 34px;
  }
}

.dashboard-body[data-page="chat"] {
  background: #090909;
  color-scheme: dark;
}

.dashboard-body[data-page="chat"] .main-frame,
.dashboard-body[data-page="chat"] .main-scroll,
.dashboard-body[data-page="chat"] .dashboard-content,
.dashboard-body[data-page="chat"] .dashboard-header {
  background: #090909;
}

.dashboard-body[data-page="chat"] .dashboard-header {
  min-height: 72px;
  border-bottom: 1px solid #1d1d1f;
  color: #f5f5f7;
}

.dashboard-body[data-page="chat"] .dashboard-header h1 {
  color: #f5f5f7;
  font-size: 24px;
  letter-spacing: -.7px;
}

.dashboard-body[data-page="chat"] .dashboard-header .icon-button {
  border-color: #2c2c2f;
  background: #151516;
  color: #f5f5f7;
}

.dashboard-body[data-page="chat"] .main-scroll {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dashboard-body[data-page="chat"] .dashboard-content {
  width: 100%;
  max-width: none;
  min-height: 0;
  flex: 1;
  padding: 0;
}

.chat-channel-state {
  color: #8e8e93;
  font-size: 12px;
  white-space: nowrap;
}

.chat-page {
  width: min(820px, 100%);
  height: 100%;
  min-height: 0;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  color: #f5f5f7;
}

.chat-messages {
  min-height: 0;
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
  padding: 28px 0 18px;
  scrollbar-color: #2b2b2e transparent;
}

.chat-loading,
.chat-error,
.chat-empty {
  color: #8e8e93;
  font-size: 13px;
  line-height: 1.55;
}

.chat-empty {
  min-height: 60%;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 7px;
  text-align: center;
}

.chat-empty strong {
  color: #f5f5f7;
  font-size: 20px;
  font-weight: 650;
  letter-spacing: -.4px;
}

.chat-empty span {
  max-width: 430px;
}

.chat-day-divider {
  display: block;
  margin: 22px 0 26px;
  color: #74747a;
  font-size: 11px;
  text-align: center;
}

.chat-day-divider::before,
.chat-day-divider::after {
  display: none;
}

.chat-message-row {
  width: 100%;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  margin: 0 0 14px;
}

.chat-message-row.user {
  justify-content: flex-end;
}

.chat-message-row.assistant {
  justify-content: flex-start;
}

.chat-assistant-avatar {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  flex: 0 0 36px;
  overflow: hidden;
  border: 1px solid #303034;
  border-radius: 50%;
  background: #242426;
}

.chat-assistant-avatar img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}

.chat-assistant-avatar.spacer {
  visibility: hidden;
}

.chat-message-stack {
  max-width: min(650px, 76%);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.chat-message-row.user .chat-message-stack {
  align-items: flex-end;
}

.chat-message-bubble,
.chat-message-stack .chat-message-bubble {
  max-width: 100%;
  padding: 12px 16px;
  border: 0;
  border-radius: 24px;
  background: #1e1e20;
  color: #f5f5f7;
}

.chat-message-row.assistant .chat-message-bubble {
  border-bottom-left-radius: 8px;
}

.chat-message-row.user .chat-message-bubble {
  border-bottom-right-radius: 8px;
  background: #2f7df6;
  color: #fff;
}

.chat-message-body {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 15px;
  line-height: 1.48;
}

.chat-message-meta {
  margin-top: 5px;
  padding: 0 7px;
  color: #77777d;
  font-size: 10px;
  line-height: 1.25;
}

.chat-message-row.user .chat-message-meta {
  color: #8d8d93;
  text-align: right;
}

.chat-burst-part {
  margin-bottom: 5px;
}

.chat-burst-last {
  margin-bottom: 14px;
}

.chat-typing {
  color: #a0a0a6;
  font-size: 13px;
}

.chat-error {
  margin: 12px 46px;
  padding: 11px 13px;
  border: 1px solid #5d2a2d;
  border-radius: 14px;
  background: #241517;
  color: #ffb7bc;
}

.chat-composer-area {
  flex: 0 0 auto;
  padding: 14px 0 calc(18px + env(safe-area-inset-bottom));
  border-top: 0;
  background: #090909;
}

.chat-composer {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 40px;
  align-items: end;
  gap: 8px;
  padding: 6px 7px 6px 10px;
  border: 1px solid #343438;
  border-radius: 999px;
  background: #0d0d0e;
}

.chat-composer:focus-within {
  border-color: #4a4a50;
}

.chat-composer-mark {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  align-self: end;
  border-radius: 50%;
  background: #1c1c1e;
}

.chat-composer-mark img {
  width: 21px;
  height: 21px;
  object-fit: contain;
}

.chat-composer textarea {
  width: 100%;
  min-height: 40px;
  max-height: 160px;
  resize: none;
  padding: 10px 4px 8px;
  border: 0;
  outline: 0;
  background: transparent;
  box-shadow: none;
  color: #f5f5f7;
  line-height: 1.42;
}

.chat-composer textarea::placeholder {
  color: #8a8a90;
}

.chat-send-button {
  width: 38px;
  min-width: 38px;
  height: 38px;
  min-height: 38px;
  display: grid;
  place-items: center;
  align-self: end;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #2f7df6;
  color: #fff;
  font-size: 22px;
  font-weight: 600;
  line-height: 1;
}

.chat-send-button:hover {
  background: #2f7df6;
}

.chat-send-button:disabled {
  background: #252528;
  color: #68686d;
  opacity: 1;
}

.chat-composer-foot {
  min-height: 22px;
  padding: 7px 11px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: #66666c;
  font-size: 10px;
}

.chat-phone-option {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #9a9aa0;
  white-space: nowrap;
}

.chat-phone-option input {
  width: 15px;
  height: 15px;
  min-height: 15px;
  accent-color: #2f7df6;
}

.dashboard-body[data-page="chat"] .chat-report-area {
  width: min(430px, 100%);
  margin-top: 6px;
}

.dashboard-body[data-page="chat"] .chat-report-trigger,
.dashboard-body[data-page="chat"] .chat-checkin-mute {
  color: #75757b;
}

.dashboard-body[data-page="chat"] .chat-report-trigger:hover,
.dashboard-body[data-page="chat"] .chat-checkin-mute:hover:not(:disabled) {
  color: #b9b9bf;
}

.dashboard-body[data-page="chat"] .chat-report-form {
  border-color: #313136;
  background: #151516;
  box-shadow: none;
}

.dashboard-body[data-page="chat"] .chat-report-form select,
.dashboard-body[data-page="chat"] .chat-report-form textarea,
.dashboard-body[data-page="chat"] .chat-report-actions button {
  border-color: #343438;
  background: #1d1d1f;
  color: #f5f5f7;
}

.dashboard-body[data-page="chat"] .chat-report-actions button[type="submit"] {
  border-color: #2f7df6;
  background: #2f7df6;
}

.notifications-page {
  width: min(1080px, 100%);
  max-width: none;
}

.notifications-intro {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
}

.notifications-summary {
  max-width: 720px;
  margin: 0;
}

.notifications-unread-summary {
  color: #7a7d84;
  font-size: 12px;
  white-space: nowrap;
}

.notification-tabs-wrap {
  max-width: 100%;
  overflow-x: auto;
  scrollbar-width: none;
}

.notification-tabs-wrap::-webkit-scrollbar {
  display: none;
}

.notification-tabs {
  --notification-tab-left: 4px;
  --notification-tab-width: 58px;
  position: relative;
  isolation: isolate;
  width: max-content;
  max-width: none;
  display: flex;
  align-items: center;
  gap: 2px;
  padding: 4px;
  overflow: visible;
  border: 1px solid #e2e2e5;
  border-radius: 999px;
  background: #f7f7f9;
}

.notification-tab-indicator {
  position: absolute;
  z-index: 0;
  top: 4px;
  left: 0;
  width: var(--notification-tab-width);
  height: calc(100% - 8px);
  transform: translateX(var(--notification-tab-left));
  border: 1px solid #dadce0;
  border-radius: 999px;
  background: #fff;
  transition: width .24s cubic-bezier(.2,.8,.2,1), transform .24s cubic-bezier(.2,.8,.2,1);
  pointer-events: none;
}

.notification-tab {
  position: relative;
  z-index: 1;
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 15px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6d7078;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 600;
}

.notification-tab:hover {
  color: #171717;
  background: transparent;
}

.notification-tab.active {
  color: #171717;
  background: transparent;
}

.notification-tab-count {
  min-width: 18px;
  height: 18px;
  display: inline-grid;
  place-items: center;
  padding: 0 5px;
  border-radius: 999px;
  background: #171717;
  color: #fff;
  font-size: 10px;
  font-variant-numeric: tabular-nums;
}

.notification-tab-count[hidden] {
  display: none;
}

.notification-feed-window {
  overflow: hidden;
}

.notification-feed {
  margin-top: 32px;
  will-change: transform, opacity;
}

.notification-feed-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 8px;
}

.notification-feed-head h2 {
  margin: 0;
  color: #171717;
  font-size: 22px;
  font-weight: 650;
  letter-spacing: -.5px;
}

.notification-feed-head p {
  margin: 5px 0 0;
  color: #74777f;
  font-size: 13px;
}

.notification-feed-list {
  display: grid;
}

.notification-item {
  width: 100%;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: start;
  gap: 13px;
  padding: 18px 2px;
  border: 0;
  border-bottom: 1px solid #ececef;
  border-radius: 0;
  background: transparent;
  color: #171717;
  text-align: left;
}

.notification-item:last-child {
  border-bottom: 0;
}

.notification-item:hover {
  background: #fafafa;
  transform: none;
}

.notification-item-mark {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border: 1px solid #e2e2e5;
  border-radius: 50%;
  background: #fff;
  color: #5f6368;
}

.notification-item-mark [data-icon],
.notification-item-mark svg {
  width: 18px;
  height: 18px;
}

.notification-item-copy {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.notification-item-category {
  width: fit-content;
  color: #7c8088 !important;
  font-size: 10px !important;
  font-weight: 650;
  letter-spacing: .06em;
  line-height: 1.2 !important;
  text-transform: uppercase;
}

.notification-item-copy strong {
  font-size: 14px;
  font-weight: 550;
}

.notification-item.unread .notification-item-copy strong {
  font-weight: 700;
}

.notification-item-copy > span:not(.notification-item-category) {
  max-width: 780px;
  color: #5f646d;
  font-size: 13px;
  line-height: 1.5;
}

.notification-item-copy small {
  margin-top: 2px;
  color: #8a8f97;
  font-size: 11px;
}

.notification-unread-dot {
  width: 8px;
  height: 8px;
  margin: 8px 5px 0 0;
  border-radius: 50%;
  background: #ef4444;
}

.notification-feed-list .empty-state {
  padding: 34px 2px;
  border: 0;
  background: transparent;
}

.nav-group[data-nav-group="notifications"] .nav-icon-stack {
  position: relative;
}

.nav-group[data-nav-group="notifications"] .nav-subitem .nav-count {
  color: #ef6b72;
}

@media (max-width: 760px) {
  .dashboard-body[data-page="chat"] .dashboard-header {
    min-height: 64px;
    padding: 12px 16px;
  }

  .chat-page {
    padding: 0 12px;
  }

  .chat-messages {
    padding-top: 18px;
  }

  .chat-message-stack {
    max-width: 82%;
  }

  .chat-assistant-avatar {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  .chat-assistant-avatar img {
    width: 21px;
    height: 21px;
  }

  .chat-message-bubble,
  .chat-message-stack .chat-message-bubble {
    padding: 11px 14px;
  }

  .chat-message-body {
    font-size: 14px;
  }

  .chat-composer-area {
    padding-top: 10px;
  }

  .chat-composer-foot > span:first-child {
    display: none;
  }

  .chat-composer-foot {
    justify-content: flex-end;
  }

  .notifications-intro {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .notification-feed {
    margin-top: 26px;
  }

  .notification-item {
    grid-template-columns: 36px minmax(0, 1fr) auto;
    gap: 11px;
    padding: 16px 1px;
  }

  .notification-item-mark {
    width: 36px;
    height: 36px;
  }
}

@media (max-width: 480px) {
  .chat-channel-state {
    display: none;
  }

  .chat-page {
    padding: 0 9px;
  }

  .chat-message-row {
    gap: 8px;
  }

  .chat-message-stack {
    max-width: 86%;
  }

  .chat-composer {
    grid-template-columns: 30px minmax(0, 1fr) 38px;
    padding-left: 8px;
  }

  .chat-composer-mark {
    width: 30px;
    height: 30px;
  }

  .notification-tab {
    padding-inline: 13px;
  }
}

.dashboard-body[data-page="chat"] .dashboard-content,
.dashboard-body[data-page="chat"] .dashboard-header {
  background: #fff;
}

.dashboard-body[data-page="chat"] .dashboard-header {
  min-height: 72px;
  border-bottom: 1px solid #ececef;
  color: #171717;
}

.dashboard-body[data-page="chat"] .dashboard-header h1 {
  color: #171717;
}

.dashboard-body[data-page="chat"] .dashboard-header .icon-button {
  border-color: #e2e2e5;
  background: #fff;
  color: #171717;
}

.chat-channel-state {
  color: #777b83;
}

.chat-page {
  width: min(860px, 100%);
  color: #171717;
}

.chat-messages {
  padding: 28px 0 18px;
  scrollbar-color: #d6d8dc transparent;
}

.chat-loading,
.chat-error,
.chat-empty {
  color: #777b83;
}

.chat-empty strong {
  color: #171717;
}

.chat-day-divider {
  color: #8b8f96;
}

.chat-assistant-avatar {
  border-color: #e2e2e5;
  background: #fff;
}

.chat-message-bubble,
.chat-message-stack .chat-message-bubble {
  border-radius: 21px;
  background: #f1f1f3;
  color: #171717;
}

.chat-message-row.assistant .chat-message-bubble {
  border-bottom-left-radius: 7px;
}

.chat-message-row.user .chat-message-bubble {
  border-bottom-right-radius: 7px;
  background: #2f7df6;
  color: #fff;
}

.chat-message-meta,
.chat-message-row.user .chat-message-meta {
  color: #8a8e95;
}

.chat-typing {
  color: #777b83;
}

.chat-error {
  border-color: #f1b8bc;
  background: #fff5f5;
  color: #a21d28;
}

.chat-composer-area {
  padding: 12px 0 calc(18px + env(safe-area-inset-bottom));
  background: #fff;
}

.chat-composer {
  grid-template-columns: minmax(0, 1fr) 40px;
  align-items: end;
  gap: 8px;
  padding: 6px 7px 6px 15px;
  border: 1px solid #d8dadd;
  border-radius: 24px;
  background: #fff;
  transition: border-color .16s ease, box-shadow .16s ease, border-radius .16s ease;
}

.chat-composer.multiline {
  border-radius: 20px;
}

.chat-composer:focus-within {
  border-color: #bfc3c9;
  box-shadow: 0 0 0 3px rgba(47, 125, 246, .08);
}

.chat-composer-mark {
  display: none;
}

.chat-composer textarea {
  min-height: 40px;
  max-height: 88px;
  overflow-y: hidden;
  padding: 10px 2px 8px;
  color: #171717;
  scrollbar-width: thin;
}

.chat-composer textarea::placeholder {
  color: #8a8e95;
}

.chat-send-button {
  width: 38px;
  min-width: 38px;
  height: 38px;
  min-height: 38px;
  border: 0;
  background: #171717;
  color: #fff;
}

.chat-send-button svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chat-send-button:hover {
  background: #171717;
}

.chat-send-button:disabled {
  background: #ececef;
  color: #9a9ea5;
}

.chat-composer-foot {
  color: #8a8e95;
}

.chat-phone-option {
  color: #777b83;
}

.dashboard-body[data-page="chat"] .chat-report-trigger,
.dashboard-body[data-page="chat"] .chat-checkin-mute {
  color: #777b83;
}

.dashboard-body[data-page="chat"] .chat-report-trigger:hover,
.dashboard-body[data-page="chat"] .chat-checkin-mute:hover:not(:disabled) {
  color: #171717;
}

.dashboard-body[data-page="chat"] .chat-report-form {
  border-color: #e2e2e5;
  background: #fff;
}

.dashboard-body[data-page="chat"] .chat-report-form select,
.dashboard-body[data-page="chat"] .chat-report-form textarea,
.dashboard-body[data-page="chat"] .chat-report-actions button {
  border-color: #d8dadd;
  background: #fff;
  color: #171717;
}

.dashboard-body[data-page="chat"] .chat-report-actions button[type="submit"] {
  border-color: #171717;
  background: #171717;
  color: #fff;
}

.notifications-intro {
  min-height: 18px;
  justify-content: flex-end;
  margin-bottom: 14px;
}

.notifications-summary {
  display: none;
}

.notification-tabs {
  --notification-tab-index: 0;
  width: min(620px, 100%);
  min-width: 500px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  padding: 4px;
}

.notification-tab-indicator {
  left: 4px;
  width: calc((100% - 8px) / 4);
  transform: translate3d(calc(var(--notification-tab-index) * 100%), 0, 0);
  transition: transform .32s cubic-bezier(.22, 1, .36, 1);
  will-change: transform;
}

.notification-tab {
  width: 100%;
  gap: 6px;
  padding-inline: 12px;
}

.notification-tab-count {
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  background: #e5484d;
  color: #fff;
}

.notification-item {
  grid-template-columns: 24px minmax(0, 1fr) auto;
  gap: 12px;
}

.notification-item-mark {
  width: 24px;
  height: 24px;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: #61656d;
}

.notification-item-mark [data-icon],
.notification-item-mark svg {
  width: 19px;
  height: 19px;
}

.nav-group[data-nav-group="notifications"] .nav-subitem {
  min-height: 34px;
}

.nav-group[data-nav-group="notifications"] .nav-subitem [data-icon] {
  width: 17px;
  height: 17px;
}

@media (max-width: 700px) {
  .notification-tabs {
    width: 100%;
    min-width: 470px;
  }

  .chat-page {
    padding-inline: 14px;
  }

  .chat-composer {
    padding-left: 13px;
  }
}
.commitments-page { display: grid; gap: 22px; }
.commitment-filter { display: inline-flex; width: fit-content; gap: 4px; padding: 4px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-soft); }
.filter-pill { min-height: 34px; padding: 0 15px; border: 0; border-radius: 999px; background: transparent; color: var(--text-soft); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.filter-pill.active { background: #fff; color: var(--text); box-shadow: 0 1px 3px rgba(15, 18, 24, .08); }
.commitment-item { align-items: flex-start; }
.commitment-title-row { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
.commitment-status { display: inline-flex; align-items: center; min-height: 24px; padding: 0 9px; border-radius: 999px; background: #f1f3f6; color: #626a75; font-size: 11px; font-weight: 650; text-transform: lowercase; }
.commitment-status.completed { background: #ebf8ef; color: #26733f; }
.commitment-status.missed, .commitment-status.cancelled { background: #fff0f0; color: #a63a3a; }
.commitment-timing { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-top: 8px; color: var(--text-soft); font-size: 12px; }
.commitment-note { margin-top: 8px; color: var(--text-soft); font-size: 13px; }

.groups-page {
  display: grid;
  gap: 22px;
}

.groups-head-copy {
  display: grid;
  gap: 12px;
}

.group-privacy-note {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  width: fit-content;
  color: var(--text-soft);
  font-size: 13px;
}

.group-privacy-note [data-icon],
.group-privacy-note svg {
  width: 17px;
  height: 17px;
}

.groups-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 650px;
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
  background: #fff;
}

.groups-list-panel {
  min-width: 0;
  padding: 16px;
  border-right: 1px solid var(--line);
  background: var(--surface-soft);
}

.groups-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 34px;
  color: var(--text-soft);
  font-size: 12px;
}

.groups-panel-head strong {
  color: var(--text);
  font-size: 13px;
  font-weight: 650;
}

.group-connection-state {
  text-transform: lowercase;
}

.groups-list {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.group-list-item {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 56px;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.group-list-item:hover,
.group-list-item.active {
  border-color: var(--line);
  background: #fff;
}

.group-list-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: #545960;
}

.group-list-icon [data-icon],
.group-list-icon svg {
  width: 17px;
  height: 17px;
}

.group-list-copy {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.group-list-copy strong,
.group-list-copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.group-list-copy strong {
  font-size: 13px;
  font-weight: 650;
}

.group-list-copy small {
  color: var(--text-soft);
  font-size: 11px;
}

.group-list-count {
  color: var(--text-soft);
  font-size: 11px;
}

.group-detail-panel {
  min-width: 0;
  background: #fff;
}

.group-empty {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 11px;
  min-height: 650px;
  padding: 40px;
  text-align: center;
}

.group-empty > [data-icon],
.group-empty > svg {
  width: 34px;
  height: 34px;
  color: #747983;
}

.group-empty h2 {
  margin: 4px 0 0;
  font-size: 22px;
}

.group-empty p {
  max-width: 500px;
  margin: 0 0 8px;
  color: var(--text-soft);
  line-height: 1.6;
}

#groupWorkspace {
  padding: 24px;
}

.group-workspace-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.group-workspace-head h2 {
  margin: 4px 0 3px;
  font-size: 24px;
  letter-spacing: -.025em;
}

.group-workspace-head p,
.group-eyebrow {
  margin: 0;
  color: var(--text-soft);
  font-size: 12px;
}

.group-eyebrow {
  font-weight: 650;
  text-transform: lowercase;
}

.group-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.group-error {
  margin-top: 14px;
  padding: 11px 13px;
  border: 1px solid #f0d2d2;
  border-radius: 8px;
  background: #fff8f8;
  color: #963a3a;
  font-size: 12px;
}

.group-mode-strip {
  display: grid;
  grid-template-columns: minmax(180px, 260px) minmax(220px, 1fr);
  gap: 18px;
  align-items: end;
  padding: 18px 0;
}

.group-mode-strip label {
  display: grid;
  gap: 7px;
  color: var(--text-soft);
  font-size: 12px;
}

.group-mode-strip select {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--text);
  font: inherit;
}

.group-memory-toggle {
  grid-template-columns: auto minmax(0, auto) 1fr;
  align-items: center;
  gap: 9px !important;
  min-height: 40px;
}

.group-memory-toggle input {
  width: 17px;
  height: 17px;
}

.group-memory-toggle span {
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
}

.group-memory-toggle small {
  color: var(--text-soft);
  font-size: 11px;
}

.group-workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 18px;
}

.group-transcript-panel,
.group-side-panel {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
}

.group-transcript-panel {
  min-width: 0;
  padding: 15px;
}

.group-transcript {
  display: grid;
  align-content: start;
  gap: 13px;
  height: 440px;
  margin: 8px -2px 14px;
  padding: 10px 2px;
  overflow: auto;
}

.group-transcript-empty,
.group-small-empty {
  color: var(--text-soft);
  font-size: 12px;
}

.group-transcript-empty {
  align-self: center;
  justify-self: center;
  max-width: 330px;
  text-align: center;
  line-height: 1.6;
}

.group-message {
  display: grid;
  gap: 5px;
  width: min(82%, 580px);
}

.group-message.chirp {
  justify-self: end;
}

.group-message-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-soft);
  font-size: 10px;
}

.group-message.chirp .group-message-meta {
  justify-content: flex-end;
}

.group-message-meta strong {
  color: var(--text);
  font-size: 11px;
}

.group-message-body {
  width: fit-content;
  max-width: 100%;
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--surface-soft);
  color: var(--text);
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.group-message.chirp .group-message-body {
  justify-self: end;
  background: #171717;
  color: #fff;
}

.group-simulate-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 9px;
  align-items: end;
}

.group-simulate-form textarea {
  min-height: 46px;
  max-height: 130px;
  resize: vertical;
  padding: 12px 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--text);
  font: inherit;
  line-height: 1.45;
}

.group-form-note {
  margin: 8px 1px 0;
  color: var(--text-soft);
  font-size: 11px;
}

.group-side-stack {
  display: grid;
  align-content: start;
  gap: 12px;
}

.group-side-panel {
  padding: 13px;
}

.group-participant-row,
.group-reminder-row,
.group-memory-row {
  padding: 10px 0;
  border-top: 1px solid #eff0f2;
}

.group-participant-row:first-child,
.group-reminder-row:first-child,
.group-memory-row:first-child {
  border-top: 0;
}

.group-participant-row,
.group-reminder-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.group-participant-row > div,
.group-reminder-row > div {
  display: grid;
  gap: 3px;
}

.group-participant-row > div:last-child {
  justify-items: end;
}

.group-participant-row strong,
.group-reminder-row strong {
  font-size: 12px;
}

.group-participant-row span,
.group-reminder-row span,
.group-memory-row > span {
  color: var(--text-soft);
  font-size: 10px;
}

.group-memory-row > span {
  font-weight: 650;
  text-transform: lowercase;
}

.group-memory-row p {
  margin: 4px 0 0;
  color: var(--text);
  font-size: 12px;
  line-height: 1.45;
}

.group-status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--surface-soft);
}

@media (max-width: 1050px) {
  .groups-layout {
    grid-template-columns: 230px minmax(0, 1fr);
  }

  .group-workspace-grid {
    grid-template-columns: 1fr;
  }

  .group-side-stack {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .groups-layout {
    grid-template-columns: 1fr;
  }

  .groups-list-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .groups-list {
    display: flex;
    overflow-x: auto;
  }

  .group-list-item {
    flex: 0 0 210px;
  }

  #groupWorkspace {
    padding: 17px;
  }

  .group-workspace-head,
  .group-mode-strip {
    grid-template-columns: 1fr;
  }

  .group-workspace-head {
    align-items: stretch;
    flex-direction: column;
  }

  .group-head-actions {
    justify-content: space-between;
  }

  .group-side-stack {
    grid-template-columns: 1fr;
  }

  .group-simulate-form {
    grid-template-columns: 1fr;
  }

  .group-simulate-form .button {
    width: 100%;
  }
}


.scan-page {
  display: grid;
  gap: 18px;
}

.scan-page-summary {
  margin-bottom: 2px;
}

.scan-primary-grid {
  display: grid;
  grid-template-columns: minmax(330px, .72fr) minmax(0, 1.38fr);
  align-items: stretch;
  gap: 16px;
}

.scan-capture-panel,
.scan-output-panel,
.scan-recent-panel {
  padding: 24px;
}

.scan-capture-panel,
.scan-output-panel {
  min-height: 520px;
}

.scan-capture-panel {
  display: flex;
  flex-direction: column;
}

.scan-capture-head,
.scan-output-head,
.scan-recent-head {
  margin-bottom: 18px;
}

.scan-mode-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  margin: 0 0 22px;
  border-bottom: 1px solid var(--line);
}

.scan-mode {
  min-width: 0;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 0 4px 13px;
  border: 0;
  border-bottom: 2px solid transparent;
  border-radius: 0;
  background: transparent;
  color: #777d86;
  text-align: left;
  transition: color .14s ease, border-color .14s ease;
}

.scan-mode + .scan-mode {
  padding-left: 16px;
}

.scan-mode.active {
  border-bottom-color: #111315;
  color: #111315;
}

.scan-mode > span:last-child {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.scan-mode strong {
  font-size: 13px;
  font-weight: 650;
  line-height: 1.25;
}

.scan-mode small {
  color: #8a9098;
  font-size: 10px;
  font-weight: 500;
  line-height: 1.25;
}

.scan-mode svg,
.scan-file-icon svg,
.scan-history-icon svg,
.scan-result-type svg,
.scan-empty-icon svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.scan-create-form {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.scan-file-picker {
  min-height: 142px;
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  padding: 18px;
  border: 1px dashed #d9dce1;
  border-radius: 12px;
  background: #fafafa;
  cursor: pointer;
  transition: border-color .14s ease, background-color .14s ease;
}

.scan-file-picker:hover,
.scan-file-picker.dragging {
  border-color: #bfc4cc;
  background: #f7f7f8;
}

.scan-file-picker input {
  position: absolute;
  width: 1px;
  height: 1px;
  min-height: 1px;
  opacity: 0;
  pointer-events: none;
}

.scan-file-preview {
  width: 88px;
  height: 88px;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px solid #e1e3e7;
  border-radius: 11px;
  background: #fff;
  color: #747a83;
}

.scan-file-preview.has-image {
  background: #eceef1;
}

.scan-file-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.scan-file-copy {
  min-width: 0;
  display: grid;
  gap: 5px;
}

.scan-file-copy strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.35;
}

.scan-file-copy > span {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.scan-file-copy em {
  max-width: 100%;
  overflow: hidden;
  color: #555c65;
  font-size: 11px;
  font-style: normal;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scan-file-action {
  grid-column: 2;
  justify-self: start;
  margin-top: -42px;
  padding-bottom: 1px;
  border-bottom: 1px solid #aeb3bb;
  color: #2d3136;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.2;
}

.scan-caption {
  min-width: 0;
}

.scan-caption > span {
  color: #92969d;
  font-size: 10px;
  font-weight: 500;
}

.scan-submit-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: auto;
  padding-top: 2px;
}

.scan-submit-row .button {
  min-width: 156px;
}

.scan-status {
  min-height: 18px;
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.4;
}

.scan-output-panel {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.scan-output-head {
  align-items: flex-start;
}

.scan-result-meta {
  flex: 0 0 auto;
  min-height: 26px;
  display: inline-flex;
  align-items: center;
  padding: 0 9px;
  border-radius: 999px;
  background: #f1f2f4;
  color: #717781;
  font-size: 10px;
  font-weight: 650;
  white-space: nowrap;
}

.scan-result-panel {
  min-width: 0;
  flex: 1;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.scan-empty {
  min-height: 390px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 32px;
  color: var(--muted);
  text-align: center;
}

.scan-empty[hidden],
#scanResult[hidden] {
  display: none !important;
}

.scan-empty-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  margin-bottom: 13px;
  border: 1px solid #e1e3e7;
  border-radius: 12px;
  background: #fafafa;
  color: #666d76;
}

.scan-empty h2 {
  margin: 0;
  color: #2f3338;
  font-size: 18px;
  font-weight: 650;
  letter-spacing: -.35px;
}

.scan-empty p {
  max-width: 360px;
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.scan-recent-panel {
  min-height: 0;
}

.scan-history {
  border-top: 1px solid var(--line);
}

.scan-history-item {
  width: 100%;
  min-width: 0;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 13px 2px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  text-align: left;
}

.scan-history-item:hover {
  background: transparent;
}

.scan-history-item.active {
  background: transparent;
}

.scan-history-icon {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid #e2e4e8;
  border-radius: 9px;
  background: #fafafa;
  color: #606771;
}

.scan-history-item.active .scan-history-icon {
  border-color: #cfd3d9;
  background: #111315;
  color: #fff;
}

.scan-history-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.scan-history-copy strong {
  overflow: hidden;
  color: var(--text);
  font-size: 13px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scan-history-copy span {
  overflow: hidden;
  color: var(--muted);
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.scan-history-side {
  display: grid;
  justify-items: end;
  gap: 3px;
  color: #858b94;
  font-size: 10px;
  white-space: nowrap;
}

.scan-history-side strong {
  color: #555c65;
  font-size: 10px;
  font-weight: 650;
  text-transform: capitalize;
}

.scan-history-empty {
  min-height: 108px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  padding: 18px 2px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}

.scan-history-empty strong {
  color: #444a52;
  font-size: 13px;
  font-weight: 650;
}

.scan-history-empty span {
  font-size: 11px;
  line-height: 1.45;
}

.scan-result-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

.scan-result-title {
  min-width: 0;
  max-width: 760px;
}

.scan-result-type {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 7px;
  color: #676e78;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.scan-result-type svg {
  width: 14px;
  height: 14px;
}

.scan-result-head h2 {
  margin: 0;
  color: var(--text);
  font-size: 24px;
  font-weight: 650;
  letter-spacing: -.75px;
}

.scan-result-head p {
  margin: 7px 0 0;
  color: var(--text-soft);
  font-size: 12px;
  line-height: 1.55;
}

.scan-result-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 7px;
}

.scan-warning-list {
  display: grid;
  gap: 8px;
  margin: 0 0 20px;
  padding-left: 13px;
  border-left: 2px solid #9aa1aa;
}

.scan-warning-list > div {
  display: block;
}

.scan-warning-list > div > span {
  display: none;
}

.scan-warning-list p {
  margin: 0;
  color: #626871;
  font-size: 11px;
  line-height: 1.5;
}

.scan-nutrition-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0 0 25px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fafafa;
}

.scan-nutrition-grid > div {
  min-width: 0;
  min-height: 86px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 7px;
  padding: 15px 16px;
  border-right: 1px solid var(--line);
}

.scan-nutrition-grid > div:last-child {
  border-right: 0;
}

.scan-nutrition-grid span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.scan-nutrition-grid strong {
  overflow-wrap: anywhere;
  color: var(--text);
  font-size: 21px;
  font-weight: 650;
  letter-spacing: -.6px;
}

.scan-result-section {
  margin-top: 25px;
}

.scan-result-section:first-of-type {
  margin-top: 0;
}

.scan-result-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 11px;
}

.scan-result-section-head h3 {
  margin: 0;
  color: var(--text);
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -.25px;
}

.scan-result-section-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.scan-table-wrap {
  width: 100%;
  overflow-x: auto;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.scan-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}

.scan-table th,
.scan-table td {
  padding: 11px 10px;
  border-bottom: 1px solid #eceef0;
  text-align: left;
  vertical-align: middle;
}

.scan-table tr:last-child td {
  border-bottom: 0;
}

.scan-table th {
  background: #fafafa;
  color: #7b818a;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.scan-table td {
  color: #3b4046;
  font-size: 11px;
}

.scan-table td strong {
  color: var(--text);
  font-weight: 650;
}

.scan-table-empty {
  padding-block: 28px !important;
  color: var(--muted) !important;
  text-align: center !important;
}

.scan-assumption-list {
  display: grid;
  gap: 7px;
  padding-left: 13px;
  border-left: 2px solid #9aa1aa;
}

.scan-assumption-list p {
  margin: 0;
  color: #5f646d;
  font-size: 11px;
  line-height: 1.5;
}

.scan-estimate-note {
  margin: 22px 0 0;
  color: #858a92;
  font-size: 10px;
  line-height: 1.5;
}

.scan-receipt-meta {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(150px, .8fr) minmax(92px, .4fr);
  gap: 12px;
}

.scan-receipt-meta label,
.scan-receipt-totals label {
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 650;
}

.scan-receipt-table td {
  padding: 6px;
}

.scan-receipt-table td:nth-child(1) {
  min-width: 220px;
}

.scan-receipt-table td:nth-child(2),
.scan-receipt-table td:nth-child(3),
.scan-receipt-table td:nth-child(4) {
  min-width: 96px;
}

.scan-receipt-table td:nth-child(5) {
  min-width: 125px;
}

.scan-table input {
  min-height: 34px;
  padding: 7px 8px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  font-size: 11px;
}

.scan-table input:hover,
.scan-table input:focus {
  border-color: #d7dae0;
  background: #fff;
}

.scan-row-remove {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: #8a8f97;
  font-size: 17px;
  line-height: 1;
}

.scan-row-remove:hover {
  background: #f2f3f5;
  color: #25282d;
}

.scan-receipt-summary {
  width: min(420px, 100%);
  margin-left: auto;
}

.scan-receipt-totals {
  display: grid;
  gap: 7px;
}

.scan-receipt-totals label {
  grid-template-columns: minmax(0, 1fr) 140px;
  align-items: center;
}

.scan-receipt-totals input {
  text-align: right;
}

.scan-receipt-totals label:last-child {
  margin-top: 3px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  color: var(--text);
}

.scan-save-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.scan-save-row p {
  margin: 0;
  color: #858a92;
  font-size: 10px;
  line-height: 1.45;
}

@media (max-width: 1080px) {
  .scan-primary-grid {
    grid-template-columns: 1fr;
  }

  .scan-capture-panel,
  .scan-output-panel {
    min-height: 0;
  }

  .scan-empty {
    min-height: 300px;
  }
}

@media (max-width: 760px) {
  .scan-capture-panel,
  .scan-output-panel,
  .scan-recent-panel {
    padding: 20px;
  }

  .scan-output-head,
  .scan-result-head,
  .scan-save-row {
    align-items: stretch;
    flex-direction: column;
  }

  .scan-result-meta {
    align-self: flex-start;
  }

  .scan-file-picker {
    grid-template-columns: 70px minmax(0, 1fr);
    min-height: 116px;
    padding: 14px;
  }

  .scan-file-preview {
    width: 70px;
    height: 70px;
  }

  .scan-file-action {
    display: none;
  }

  .scan-submit-row {
    align-items: stretch;
    flex-direction: column;
  }

  .scan-submit-row .button {
    width: 100%;
    min-width: 0;
  }

  .scan-result-actions {
    justify-content: flex-start;
  }

  .scan-history-item {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .scan-history-side {
    grid-column: 2;
    justify-items: start;
    grid-auto-flow: column;
    justify-content: start;
    gap: 8px;
  }

  .scan-nutrition-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .scan-nutrition-grid > div:nth-child(2) {
    border-right: 0;
  }

  .scan-nutrition-grid > div:nth-child(-n+2) {
    border-bottom: 1px solid var(--line);
  }

  .scan-receipt-meta {
    grid-template-columns: 1fr;
  }

  .scan-save-row .button {
    width: 100%;
  }
}

@media (max-width: 480px) {
  .scan-capture-panel,
  .scan-output-panel,
  .scan-recent-panel {
    padding: 17px;
  }

  .scan-mode + .scan-mode {
    padding-left: 10px;
  }

  .scan-mode {
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 7px;
  }

  .scan-mode small {
    display: none;
  }

  .scan-file-picker {
    grid-template-columns: 58px minmax(0, 1fr);
    min-height: 102px;
    gap: 12px;
    padding: 12px;
  }

  .scan-file-preview {
    width: 58px;
    height: 58px;
  }

  .scan-nutrition-grid > div {
    min-height: 78px;
    padding: 12px;
  }

  .scan-nutrition-grid strong {
    font-size: 18px;
  }

  .scan-result-actions .button {
    flex: 1 1 auto;
  }
}

.settings-group-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.settings-group-heading h3 {
  margin-bottom: 6px;
}

.settings-group-heading p {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.phone-connect-intro {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 20px;
  align-items: center;
  padding: 18px 0 2px;
  border-top: 1px solid var(--line);
}

.phone-connect-intro strong {
  display: block;
  margin-bottom: 5px;
  font-size: 14px;
}

.phone-connect-intro p {
  max-width: 660px;
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.phone-link-panel {
  margin-top: 18px;
  padding: 22px;
  border: 1px solid #dedee4;
  border-radius: 10px;
  background: #f8f8fa;
}

.phone-link-panel[hidden],
#phoneConnectedState[hidden],
#phoneDisconnectedState[hidden] {
  display: none !important;
}

.phone-link-label,
.phone-link-expiry,
.phone-link-status {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.phone-link-code {
  display: block;
  width: 100%;
  margin: 14px 0 12px;
  padding: 18px 20px;
  border: 1px solid #cacbd3;
  border-radius: 9px;
  background: #fff;
  color: var(--text);
  font: inherit;
  font-size: clamp(28px, 5vw, 42px);
  font-weight: 650;
  letter-spacing: .22em;
  text-align: center;
  cursor: copy;
}

.phone-link-code:focus-visible {
  outline: 2px solid #6671ef;
  outline-offset: 2px;
}

.phone-link-status {
  margin-top: 8px;
  color: #4c57d9;
}

.phone-connection-row {
  border-bottom: 1px solid var(--line);
}

@media (max-width: 700px) {
  .settings-group-heading,
  .phone-connect-intro {
    grid-template-columns: 1fr;
    display: grid;
  }

  .settings-group-heading .tag,
  .phone-connect-intro .button {
    justify-self: start;
  }

  .phone-link-code {
    letter-spacing: .14em;
  }
}
