:root {
  --bg: #f4f6f5;
  --bg2: #ffffff;
  --panel: #ffffff;
  --line: #e3e7e5;
  --ink: #12181a;
  --mute: #5a6568;
  --faint: #8a9497;
  --accent: #3d6b4f;
  --accent2: #1d4ed8;
  --good: #3d6b4f;
  --bad: #c0364a;
  --warn: #b45309;
  --shadow: 0 1px 2px rgba(16, 24, 26, .06), 0 12px 32px rgba(16, 24, 26, .06);
  --radius: 10px;
  --font: "IBM Plex Sans", "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
}
html[data-theme="dark"] {
  --bg: #0f1416;
  --bg2: #161c1f;
  --panel: #1b2226;
  --line: #2a3338;
  --ink: #e8eeef;
  --mute: #8b9699;
  --faint: #667075;
  --accent: #2ec99a;
  --accent2: #7aa2f7;
  --shadow: 0 12px 32px rgba(0,0,0,.35);
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--accent); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
.auth {
  min-height: 100%;
  display: grid;
  place-items: center;
  background: var(--bg);
}
.brand-lockup {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: -.045em;
  white-space: nowrap;
  margin-bottom: 22px;
}
.brand-lockup img { width: 48px; height: 48px; border-radius: 12px; }
.auth-foot { margin: 20px 0 0; font-size: 13px; color: var(--mute); }
.auth-card {
  width: min(400px, calc(100% - 32px));
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 36px 32px;
  box-shadow: var(--shadow);
}
h1 { margin: 0 0 8px; font-size: 24px; font-weight: 600; letter-spacing: -.03em; }
.muted { color: var(--mute); margin: 0 0 22px; }
label { display: block; margin: 0 0 14px; color: var(--mute); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; font-weight: 500; }
input, select, textarea {
  width: 100%;
  margin-top: 6px;
  background: var(--bg2);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 12px;
  outline: none;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(14,143,110,.15); }
textarea { min-height: 90px; resize: vertical; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border: 1px solid var(--line); background: var(--bg2);
  border-radius: 8px; padding: 8px 14px; cursor: pointer;
  font-weight: 500; font-size: 13.5px;
}
.btn.primary { background: var(--accent); color: #fff; border-color: transparent; }
html:not([data-theme="dark"]) .btn.primary { color: #fff; }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--bad); }
.btn:hover { filter: brightness(1.04); }
.flash { padding: 10px 12px; border-radius: 8px; margin-bottom: 14px; background: #eef6f2; }
.flash.err { background: #fde8ec; color: var(--bad); }

.app {
  display: grid;
  grid-template-columns: 268px 1fr;
  min-height: 100%;
}
.nav {
  background: var(--panel);
  border-right: 1px solid var(--line);
  padding: 20px 12px;
  display: flex; flex-direction: column; gap: 2px;
}
.nav .brand {
  font-weight: 700; font-size: 18px; padding: 6px 8px 22px;
  letter-spacing: -.045em;
  display: flex; align-items: center; gap: 10px;
  white-space: nowrap;
}
.nav .brand img { width: 42px; height: 42px; border-radius: 10px; }
.nav a {
  color: var(--mute); padding: 8px 10px; border-radius: 8px; display: block;
  font-size: 13.5px; font-weight: 500;
}
.nav a:hover { background: var(--bg); color: var(--ink); }
.nav a.on { background: #e8eee9; color: #2f5340; }
.nav-foot { margin-top: auto; padding: 16px 8px 8px; }
html[data-theme="dark"] .nav a.on { background: #16352c; color: var(--accent); }
.main { display: flex; flex-direction: column; min-width: 0; position: relative; }
.qdrop {
  position: absolute; left: 22px; top: 56px; width: min(520px, calc(100% - 44px));
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  box-shadow: var(--shadow); z-index: 15; max-height: 360px; overflow: auto;
}
.qdrop a { display: block; padding: 8px 12px; color: var(--ink); border-bottom: 1px solid var(--line); }
.qdrop a:hover { background: var(--bg); }
.grid-form { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 16px 0; }
.grid-form textarea, .grid-form button { grid-column: 1 / -1; }
.ev.unread { background: #eef6f2; border-radius: 8px; padding: 8px 10px; }
.code-sample {
  background: var(--bg); border: 1px solid var(--line); border-radius: 8px;
  padding: 12px; font-size: 12px; overflow: auto; font-family: var(--mono);
}
.flash code { word-break: break-all; font-size: 13px; }
.top {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 22px; border-bottom: 1px solid var(--line);
  background: var(--panel);
}
.search {
  flex: 1; max-width: 520px;
  background: var(--bg); border: 1px solid var(--line); border-radius: 8px;
  padding: 8px 12px; display: flex; gap: 8px; align-items: center; color: var(--mute);
  font-size: 13px;
}
.search input { border: 0; background: transparent; padding: 0; outline: none; box-shadow: none; }
.top .who { margin-left: auto; color: var(--mute); display: flex; gap: 10px; align-items: center; font-size: 13px; }
.page { padding: 28px 28px 56px; }
.page h2 { margin: 0 0 4px; font-size: 22px; font-weight: 600; letter-spacing: -.03em; }
.sub { color: var(--mute); margin: 0 0 20px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 16px; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-bottom: 18px; }
.kpi {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 16px;
  border-top: 3px solid var(--accent);
}
.kpis .kpi:nth-child(2) { border-top-color: #1d4ed8; }
.kpis .kpi:nth-child(3) { border-top-color: #64748b; }
.kpis .kpi:nth-child(4) { border-top-color: #3d6b4f; }
.kpis .kpi:nth-child(5) { border-top-color: #b45309; }
.kpis .kpi:nth-child(6) { border-top-color: #c0364a; }
.kpi b { display: block; font-size: 22px; margin-top: 6px; letter-spacing: -.03em; }
.kpi span { color: var(--mute); font-size: 11px; text-transform: uppercase; letter-spacing: .07em; font-weight: 500; }
.grid2 { display: grid; grid-template-columns: 1.4fr .9fr; gap: 14px; }
.card {
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 16px 18px;
}
.card h3 { margin: 0 0 12px; font-size: 11px; color: var(--mute); font-weight: 600; letter-spacing: .07em; text-transform: uppercase; }
table { width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; font-size: 13.5px; }
th { color: var(--mute); font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
tr:hover td { background: #f7faf9; }
html[data-theme="dark"] tr:hover td { background: rgba(255,255,255,.03); }
.pill {
  display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 500;
  background: #eef2ff; color: #1d4ed8;
}
.tag { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 11px; margin-right: 4px; background: var(--bg); border: 1px solid var(--line); }
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(240px, 1fr); gap: 14px; overflow-x: auto; padding: 4px 2px 16px; }
.col {
  --stage: var(--accent);
  background: linear-gradient(180deg, color-mix(in srgb, var(--stage) 8%, var(--bg)) 0%, var(--bg) 48px);
  border: 1px solid var(--line); border-radius: 14px; min-height: 420px;
  padding: 12px; position: relative;
}
.col::before {
  content: ""; position: absolute; left: 12px; right: 12px; top: 0; height: 3px;
  background: var(--stage); border-radius: 0 0 3px 3px;
}
.col h3 {
  margin: 8px 0 12px; font-size: 11px; display: flex; align-items: center; gap: 8px;
  font-weight: 650; color: var(--ink); text-transform: uppercase; letter-spacing: .06em;
}
.col h3 .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--stage); flex: 0 0 auto; }
.col h3 .count {
  margin-left: auto; background: var(--panel); border: 1px solid var(--line);
  border-radius: 99px; padding: 1px 8px; font-size: 11px; color: var(--mute); font-weight: 600;
}
.col h3 .sum { color: var(--mute); font-weight: 500; letter-spacing: 0; text-transform: none; font-size: 12px; }
.col.over { outline: 2px solid var(--stage); outline-offset: -2px; }
.deal {
  background: var(--panel); border: 1px solid var(--line); border-radius: 10px;
  padding: 12px 28px 12px 12px; margin-bottom: 8px; cursor: grab;
  box-shadow: 0 1px 2px rgba(16,24,26,.04);
  position: relative;
}
.deal-del {
  position: absolute; top: 6px; right: 6px;
  width: 22px; height: 22px; border: 0; background: transparent;
  color: var(--faint); cursor: pointer; font-size: 16px; line-height: 1;
  border-radius: 6px; padding: 0;
}
.deal-del:hover { background: #fde8ec; color: var(--bad); }
.deal:hover { border-color: color-mix(in srgb, var(--stage, var(--accent)) 35%, var(--line)); box-shadow: var(--shadow); }
.deal-top { display: flex; justify-content: space-between; gap: 8px; align-items: flex-start; }
.deal b { display: block; margin-bottom: 4px; font-size: 13.5px; }
.deal-val { font-weight: 650; font-size: 13px; white-space: nowrap; color: var(--ink); }
.deal .meta { color: var(--mute); font-size: 12px; }
.deal-date { color: var(--faint); font-size: 11px; margin-top: 6px; font-family: var(--mono); }
.deal-prob { height: 3px; background: var(--bg); border-radius: 99px; margin-top: 10px; overflow: hidden; }
.deal-prob i { display: block; height: 100%; background: var(--stage, var(--accent)); }
.split { display: grid; grid-template-columns: 320px 1fr; gap: 16px; min-height: 70vh; }
.list { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; overflow: auto; max-height: calc(100vh - 140px); }
.list a { display: block; padding: 12px 14px; color: var(--ink); border-bottom: 1px solid var(--line); }
.list a.on, .list a:hover { background: var(--bg); }
.detail { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; padding: 22px; }
.timeline { display: flex; flex-direction: column; gap: 10px; }
.ev { border-left: 2px solid var(--line); padding: 0 0 8px 12px; }
.ev .when { color: var(--faint); font-size: 12px; }
.modal-back {
  position: fixed; inset: 0; background: rgba(16,24,26,.4); display: grid; place-items: center; z-index: 20;
}
.modal {
  width: min(520px, calc(100% - 24px)); background: var(--panel); border: 1px solid var(--line);
  border-radius: 12px; padding: 22px; box-shadow: var(--shadow); max-height: 90vh; overflow: auto;
}
.toast {
  position: fixed; right: 16px; bottom: 16px; background: var(--panel); border: 1px solid var(--line);
  padding: 10px 14px; border-radius: 8px; z-index: 30; box-shadow: var(--shadow);
}
.cmd {
  position: fixed; inset: 12vh 0 auto; margin: auto; width: min(560px, calc(100% - 24px));
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px; z-index: 40;
  box-shadow: var(--shadow); overflow: hidden;
}
.cmd input { border: 0; background: transparent; padding: 14px 16px; box-shadow: none; }
.cmd .hits a { display: block; padding: 8px 16px; color: var(--ink); }
.cmd .hits a:hover { background: var(--bg); }
.bar { height: 6px; background: var(--bg); border-radius: 99px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--accent); }
.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.day { min-height: 88px; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 6px; font-size: 12px; }
.day b { display: block; color: var(--mute); margin-bottom: 4px; }
.chip { display: block; background: var(--bg); border-radius: 4px; padding: 2px 6px; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty { color: var(--mute); padding: 28px 8px; text-align: center; }
.star { color: var(--accent); cursor: pointer; }

.land { background: #fff; color: #12181a; min-height: 100%; }
.land-top {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 40px;
  border-bottom: 1px solid #e3e7e5;
  position: sticky; top: 0; background: rgba(255,255,255,.92); backdrop-filter: blur(10px); z-index: 5;
}
.land-top .brand-lockup { margin: 0; }
.land-top nav { display: flex; gap: 22px; align-items: center; font-size: 14px; }
.land-top nav a { color: #5a6568; font-weight: 500; }
.hero {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: 48px;
  align-items: center;
  max-width: 1120px;
  margin: 0 auto;
  padding: 64px 40px 56px;
}
.hero-copy { max-width: 520px; }
.eyebrow {
  font-family: var(--mono); letter-spacing: .16em; text-transform: uppercase;
  color: var(--accent); font-size: 11px; margin: 0 0 14px; font-weight: 500;
}
.hero h1 { font-size: clamp(36px, 4.6vw, 56px); line-height: 1.05; letter-spacing: -.04em; margin: 0 0 16px; font-weight: 650; }
.lead { color: #5a6568; font-size: 17px; max-width: 28rem; margin: 0 0 24px; line-height: 1.5; }
.hero-acts { display: flex; gap: 10px; flex-wrap: wrap; }
.hero-frame {
  border: 1px solid #e3e7e5;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #f6f3ee;
}
.hero-frame img { display: block; width: 100%; height: auto; }
.product-frame {
  max-width: 1180px;
  margin: 0 auto 64px;
  padding: 0 40px;
}
.board-shot {
  display: grid;
  grid-template-columns: 188px 1fr;
  border: 1px solid #e3e7e5;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 60px rgba(16, 24, 26, .08);
  min-height: 420px;
  background: #fff;
}
.board-side {
  background: #f7f8f7;
  border-right: 1px solid #e3e7e5;
  padding: 18px 12px;
  display: flex; flex-direction: column; gap: 4px;
  font-size: 13px; color: #5a6568; font-weight: 500;
}
.mini-brand {
  display: flex; align-items: center; gap: 8px;
  font-weight: 700; color: #12181a; letter-spacing: -.04em;
  padding: 4px 8px 18px; font-size: 13px;
}
.mini-brand img { width: 28px; height: 28px; border-radius: 7px; }
.board-side span { padding: 7px 10px; border-radius: 8px; }
.board-side .on { background: #e8eee9; color: #2f5340; }
.board-main { background: #f4f6f5; display: flex; flex-direction: column; min-width: 0; }
.board-top {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 16px 18px 8px; font-size: 13px; color: #8a9497;
}
.board-top strong { color: #12181a; font-size: 16px; font-weight: 650; letter-spacing: -.02em; }
.pipeline-preview {
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px;
  padding: 10px 14px 18px; flex: 1;
}
.pipe {
  --stage: #3d6b4f;
  background: #fff;
  border: 1px solid #e3e7e5;
  border-radius: 12px;
  padding: 12px 10px;
  min-height: 280px;
  box-shadow: 0 1px 2px rgba(16,24,26,.04);
  position: relative;
}
.pipe::before {
  content: ""; position: absolute; left: 10px; right: 10px; top: 0; height: 3px;
  background: var(--stage); border-radius: 0 0 3px 3px;
}
.pipe h3 {
  margin: 8px 0 12px; font-size: 11px; text-transform: uppercase; letter-spacing: .06em;
  color: #12181a; display: flex; align-items: center; gap: 7px; font-weight: 650;
}
.pipe h3 i { width: 7px; height: 7px; border-radius: 50%; background: var(--stage); display: inline-block; }
.pipe h3 em { margin-left: auto; font-style: normal; color: #8a9497; font-weight: 600; }
.dropzone {
  border: 1px dashed #d5dbd8; border-radius: 10px; height: 72px; margin-bottom: 8px;
  background: repeating-linear-gradient(-45deg, transparent, transparent 6px, rgba(61,107,79,.03) 6px, rgba(61,107,79,.03) 12px);
}
.dropzone.faint { opacity: .45; height: 56px; }
.features {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 1px; background: #e3e7e5;
  max-width: 1120px; margin: 0 auto 64px;
  border: 1px solid #e3e7e5; border-radius: 12px; overflow: hidden;
}
.features article {
  background: #fff; padding: 28px 24px;
}
.features .num { font-family: var(--mono); font-size: 11px; color: var(--accent); letter-spacing: .08em; margin-bottom: 10px; }
.features h2 { margin: 0 0 8px; font-size: 16px; font-weight: 600; }
.features p { margin: 0; color: #5a6568; font-size: 14px; }
.site-foot {
  border-top: 1px solid var(--line);
  background: var(--panel);
  padding: 28px 40px 20px;
  font-size: 13px;
  color: var(--mute);
}
.site-foot-inner {
  max-width: 1120px; margin: 0 auto;
  display: flex; justify-content: space-between; gap: 32px; flex-wrap: wrap;
}
.site-foot-word { font-weight: 700; color: var(--ink); letter-spacing: -.04em; font-size: 16px; margin-bottom: 6px; }
.site-foot-co { margin: 8px 0 0; font-size: 12.5px; line-height: 1.5; }
.site-foot-links { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; }
.site-foot-links a { color: var(--mute); font-weight: 500; }
.site-foot-links a:hover { color: var(--ink); }
.site-foot-copy { max-width: 1120px; margin: 18px auto 0; font-size: 12px; color: var(--faint); }
.cookie-banner {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 80;
  max-width: 720px; margin: 0 auto;
}
.cookie-banner-inner {
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  box-shadow: var(--shadow); padding: 16px 18px;
  display: flex; gap: 16px; align-items: flex-end; flex-wrap: wrap;
}
.cookie-banner-inner p { margin: 0; flex: 1; min-width: 220px; font-size: 13.5px; color: var(--ink); }
.cookie-banner-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.legal-page .legal-card {
  max-width: 760px; margin: 32px auto 48px; padding: 0 24px;
}
.legal-card h1 { font-size: 32px; margin-bottom: 8px; }
.legal-card h2 { font-size: 16px; margin: 28px 0 8px; }
.legal-card p, .legal-card li { color: var(--mute); line-height: 1.55; }
.legal-card ul { padding-left: 1.2rem; }
.legal-meta { font-size: 13px; }
.pill-legal {
  display: inline-block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent); font-weight: 600; margin-bottom: 8px;
}
.table-wrap { overflow-x: auto; margin: 12px 0 16px; }
.legal-card table { font-size: 13px; }
.app { min-height: calc(100vh - 180px); }
.auth { min-height: auto; padding: 48px 16px 24px; }
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .nav { flex-direction: row; overflow-x: auto; }
  .grid2, .split { grid-template-columns: 1fr; }
  .hero { grid-template-columns: 1fr; padding: 36px 20px; }
  .pipeline-preview { grid-template-columns: 1fr 1fr; }
  .board-shot { grid-template-columns: 1fr; }
  .board-side { display: none; }
  .features { grid-template-columns: 1fr; }
  .land-top, .product-frame, .land-foot { padding-left: 20px; padding-right: 20px; }
}
