/* floating. brand — tokens and type from flt.pt */
@font-face {
  font-family: "Inter"; font-style: normal; font-weight: 400 600; font-display: swap;
  src: url(/static/fonts/inter-latin.woff2) format("woff2");
}
@font-face {
  font-family: "JetBrains Mono"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(/static/fonts/jetbrains-mono-latin-400.woff2) format("woff2");
}

:root {
  --paper:    #f5f3ee;
  --mist:     #e8e5dd;
  --fog:      #6f6c76;
  --ink-soft: #2a2730;
  --ink:      #15141a;
  --rule:      rgba(20, 20, 26, 0.10);
  --rule-soft: rgba(20, 20, 26, 0.06);
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --gutter: clamp(16px, 3vw, 40px);
  color-scheme: light;
  font-family: var(--sans);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--paper); color: var(--ink); letter-spacing: -0.005em; }
::selection { background: var(--ink); color: var(--paper); }
a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--rule); transition: border-color 150ms var(--ease); }
a:hover { border-color: var(--ink); }
.hidden { display: none !important; }

/* ------------------------------------------------------------- header */
header {
  position: sticky; top: 0; z-index: 5; height: 64px;
  display: flex; align-items: center; gap: 28px; padding: 0 var(--gutter);
  background: var(--paper); border-bottom: 1px solid var(--rule);
}
.lockup { display: flex; align-items: baseline; gap: 14px; border: 0; white-space: nowrap; }
.lockup .word { font-size: 22px; font-weight: 600; letter-spacing: -0.038em; line-height: 1; }
.lockup .product { font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--fog); }
nav { display: flex; gap: 22px; flex: 1; }
button.tab { background: none; border: 0; padding: 4px 0; color: var(--ink-soft); font-size: 14px; border-bottom: 1px solid transparent; border-radius: 0; }
button.tab:hover { color: var(--ink); }
button.tab.active { color: var(--ink); border-bottom-color: var(--ink); }

/* ------------------------------------------------------------ buttons */
button, .button {
  font: inherit; font-size: 13px; font-weight: 500; display: inline-flex; align-items: center; gap: 10px;
  background: var(--ink); color: var(--paper); border: 1px solid var(--ink); border-radius: 3px;
  padding: 7px 12px; cursor: pointer; transition: opacity 150ms var(--ease), border-color 150ms var(--ease);
}
button:hover, .button:hover { opacity: .86; }
button .dot, .button .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; transition: transform 150ms var(--ease); }
button:hover .dot, .button:hover .dot { transform: translateX(3px); }
button.ghost, .button.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
button.ghost:hover, .button.ghost:hover { border-color: var(--ink); opacity: 1; }
button:disabled { opacity: .4; cursor: default; }

/* ------------------------------------------------------------- labels */
.label, legend, th, .filters label, .eyebrow {
  font-family: var(--mono); font-size: 10.5px; font-weight: 400; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fog);
}
.pill { font-family: var(--mono); font-size: 11px; letter-spacing: 0.06em; color: var(--ink-soft); white-space: nowrap; display: inline-flex; align-items: center; gap: 8px; }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--ink); }
.pill.warn::before { background: transparent; border: 1px solid var(--ink); }
.pill.bad::before { background: transparent; border: 1px dashed var(--fog); }

/* --------------------------------------------------------------- page */
main { padding: 28px var(--gutter) 40px; }
.page-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.page-head h2 { font-size: 34px; font-weight: 600; letter-spacing: -0.03em; line-height: 1.05; margin: 6px 0 0; }
.page-head p { margin: 8px 0 0; color: var(--ink-soft); max-width: 62ch; }
h3 { font-size: 15px; font-weight: 600; letter-spacing: -0.015em; margin: 28px 0 10px; }
.muted { color: var(--fog); }

#tab-opps { display: grid; grid-template-columns: 270px 1fr; gap: 28px; align-items: start; }
.filters {
  position: sticky; top: 88px; max-height: calc(100vh - 108px); overflow: auto; padding-right: 12px;
  scrollbar-width: thin; scrollbar-color: var(--rule) transparent; scrollbar-gutter: stable;
}
.filters label { display: block; margin: 12px 0; }
/* the search section reads like the fieldsets below: label, rule, then the reset on the right */
.filters-head { display: flex; align-items: center; gap: 8px; }
.filters-head::after { content: ""; flex: 1; order: 1; border-top: 1px solid var(--rule); }
.filters .filters-head label { margin: 0; }
.filters-head button {
  order: 2; background: none; border: 0; border-radius: 0; padding: 0;
  font-family: var(--mono); font-size: 10.5px; font-weight: 400; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fog);
}
.filters-head button:hover { color: var(--ink); opacity: 1; }
.filters-head + input { margin-top: 12px; }
.filters label.check {
  display: flex; gap: 8px; align-items: center; font-family: var(--sans); font-size: 13.5px;
  letter-spacing: 0; text-transform: none; color: var(--ink);
}
input:not([type=checkbox]):not([type=radio]), select {
  display: block; width: 100%; margin-top: 6px; font: inherit; font-size: 13.5px; letter-spacing: 0; text-transform: none;
  color: var(--ink); background: transparent; padding: 7px 9px; border: 1px solid var(--rule); border-radius: 3px;
  transition: border-color 150ms var(--ease);
}
input:not([type=checkbox]):not([type=radio]):focus, select:focus { outline: none; border-color: var(--ink); }
input[type=checkbox], input[type=radio] { accent-color: var(--ink); width: 14px; height: 14px; margin: 0; }
fieldset { border: 0; border-top: 1px solid var(--rule); padding: 14px 0 0; margin: 16px 0 0; }
legend { padding: 0 8px 0 0; }
/* even columns; when two do not fit side by side, each preset takes a full row instead of wrapping raggedly */
.filters fieldset > select { margin-top: 10px; }
.inline-filters { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.inline-filters input, .inline-filters select { width: auto; display: inline-block; margin: 0; }
.inline-filters label.check { display: inline-flex; gap: 8px; align-items: center; font-size: 13.5px; }

/* ------------------------------------------------------------ profile */
.profile-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 0; border-top: 1px solid var(--ink); }
.chips, .views { display: flex; gap: 6px; flex-wrap: wrap; }
.chip {
  background: transparent; color: var(--ink); border: 1px solid var(--rule); border-radius: 999px;
  padding: 5px 12px; font-size: 12.5px; font-weight: 500;
}
.chip:hover { border-color: var(--ink); opacity: 1; }
.chip.active { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.chip.active::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--paper); }
#profile-new { padding: 5px 12px; font-size: 12.5px; border-radius: 999px; }
.profile-summary { margin: 0 0 18px; color: var(--ink-soft); font-size: 13px; }
.views { margin: 10px 0 12px; }
.views .muted { font-size: 12.5px; line-height: 1.4; }
.view { display: inline-flex; align-items: center; }
.view .x { background: none; border: 0; color: var(--fog); padding: 2px 6px; font-size: 14px; }
.view .x:hover { color: var(--ink); }
.why { color: var(--ink); }
td.why-cell { max-width: 320px; }
.for-you { border-top: 1px solid var(--ink); padding: 12px 0 4px; margin-bottom: 8px; }
.for-you .eyebrow { margin-bottom: 8px; }
.for-you ul { margin: 8px 0 12px; }
.profile-form { border-top: 1px solid var(--ink); padding-top: 6px; max-width: 460px; }
.profile-form > label { display: block; margin: 14px 0; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fog); }
.profile-form label.check { display: flex; gap: 8px; align-items: center; margin: 8px 0; font-size: 13.5px; color: var(--ink); }
.profile-form .hint { margin: -8px 0 10px; font-size: 12px; color: var(--fog); }
.profile-form #profile-error { color: var(--ink); margin: 8px 0; }
.form-actions { display: flex; gap: 10px; margin-top: 18px; }

/* -------------------------------------------------------------- table */
.results-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; }
#count, #plan-count { font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fog); }
table { width: 100%; border-collapse: collapse; border-top: 1px solid var(--ink); }
th, td { padding: 11px 10px; text-align: left; border-bottom: 1px solid var(--rule); vertical-align: top; }
th { position: sticky; top: 64px; background: var(--paper); z-index: 1; padding-top: 12px; padding-bottom: 10px; }
td { font-size: 13.5px; line-height: 1.4; }
td:first-child, th:first-child { padding-left: 0; }
tbody tr { transition: background 120ms var(--ease); }
tbody tr:hover { background: var(--mist); cursor: pointer; }
td.num, th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
td .sub { color: var(--fog); font-size: 12px; margin-top: 2px; }
td .id { font-family: var(--mono); font-size: 11px; color: var(--fog); margin-top: 3px; }
.date { font-variant-numeric: tabular-nums; white-space: nowrap; }
.days { display: block; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.06em; color: var(--fog); margin-top: 2px; }
.days.urgent { color: var(--ink); }
.days.urgent::before { content: "● "; }

/* yes / no / unknown, in the dot language: filled, empty, outlined-dashed */
.badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink-soft); white-space: nowrap; }
.badge::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1px solid var(--ink); }
.badge.yes::before { background: var(--ink); }
.badge.no { color: var(--fog); }
.badge.no::before { border-color: var(--fog); }
.badge.unknown::before { border-style: dashed; border-color: var(--fog); }
.sme { font-size: 11px; letter-spacing: 3px; color: var(--ink); white-space: nowrap; }
.pager { display: flex; gap: 14px; align-items: center; justify-content: center; margin: 18px 0; font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; color: var(--fog); }

/* ------------------------------------------------------------- drawer */
.drawer { position: fixed; inset: 0; background: rgba(21, 20, 26, 0.28); display: flex; justify-content: flex-end; z-index: 10; }
.drawer-body { width: min(720px, 100%); height: 100%; overflow: auto; background: var(--paper); padding: 28px 32px; position: relative; border-left: 1px solid var(--rule); }
.drawer .close { position: absolute; right: 22px; top: 22px; padding: 4px 9px; }
.drawer h2 { font-size: 22px; font-weight: 600; letter-spacing: -0.025em; line-height: 1.2; margin: 6px 56px 20px 0; }
.drawer dl { display: grid; grid-template-columns: 150px 1fr; gap: 9px 14px; margin: 0 0 20px; padding-top: 14px; border-top: 1px solid var(--ink); }
.drawer dt { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fog); padding-top: 2px; }
.drawer dd { margin: 0; overflow-wrap: anywhere; font-size: 13.5px; }
.drawer ul { padding-left: 18px; }
.drawer .desc { white-space: pre-wrap; line-height: 1.55; color: var(--ink-soft); border-top: 1px solid var(--rule); padding-top: 16px; max-width: 68ch; }

/* ------------------------------------------------------------- footer */
footer {
  display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap;
  padding: 22px var(--gutter) 28px; border-top: 1px solid var(--rule);
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fog);
}
footer a { color: var(--fog); }
.pipeline-actions { margin: 8px 0 14px; }

@media (max-width: 900px) {
  #tab-opps { grid-template-columns: 1fr; }
  .filters { position: static; max-height: none; }
  .lockup .product { display: none; }
  nav { gap: 14px; }
}
