@import url('https://fonts.googleapis.com/css2?family=Inter:opsz,wght@14..32,400..700&display=swap');

/*
 * Tip 009: five overlays on a team's members page, from the lightest to the
 * heaviest, with Lumno's controls (buttons with a slight sheen, its tooltip,
 * toggle) on a quiet workspace layout.
 *
 * The page is laid out at a desktop browser's real size, 1280 wide, and
 * drawn at 0.8 on a panel that runs off the stage's right and bottom edges;
 * the tour zooms in to read the details.
 * Spacing runs on a 4px grid. Corners come from one scale of rounded
 * rectangles, larger for larger surfaces: drawer and dialog 12, popovers 10,
 * buttons and fields 8, list rows and tooltips 6, badges 4. Only avatars,
 * dots and the toggle are round.
 * Type: body 14, controls 13, secondary text 12, meta 11.
 */

.tip-stage {
  --font: 'Inter', -apple-system, 'Helvetica Neue', sans-serif;
  --ink: #18181b;
  --text: #3f3f46;
  --muted: #71717a;
  --faint: #a1a1aa;
  --line: rgba(15, 23, 42, 0.09);
  --line-soft: rgba(15, 23, 42, 0.06);
  --fill: #f2f2f3;
  --fill-hover: #e9e9eb;
  --r-panel: 12px;
  --r-popover: 10px;
  --r-control: 8px;
  --r-item: 6px;
  --r-badge: 4px;
  --primary: linear-gradient(180deg, #404859 0%, #273042 100%);
  --primary-hover: linear-gradient(180deg, #4a5467 0%, #2f3a4f 100%);
  --danger: linear-gradient(180deg, #ea5a5f 0%, #cf3a3f 100%);
  --danger-hover: linear-gradient(180deg, #ef6a6f 0%, #d8454a 100%);
  --red: #dc2626;
  --blue: #2563eb;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  /* Lumno's secondary control and primary sheen. */
  --shadow-secondary:
    0 2px 2px rgba(15, 23, 42, 0.025),
    0 1px 1px rgba(15, 23, 42, 0.035),
    0 0 1px rgba(15, 23, 42, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.75);
  --shadow-primary:
    0 1px 2px rgba(15, 23, 42, 0.18),
    0 3px 6px -2px rgba(15, 23, 42, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.18),
    inset 0 1px 3px rgba(255, 255, 255, 0.1),
    inset 0 -1px 0 rgba(0, 0, 0, 0.22);
  --shadow-primary-pressed: 0 1px 1px rgba(15, 23, 42, 0.14), inset 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-popover: 0 0 0 1px rgba(15, 23, 42, 0.07), 0 8px 24px rgba(15, 23, 42, 0.12);
  background: #cfe6f7 url('./media/backdrop-aqua.jpg') center / cover;
  font-family: var(--font);
  font-feature-settings: 'cv11', 'tnum';
}

.tip-stage:has(> .tip-credit) { padding: 0; }

button { font: inherit; }

/* ---------- The five kinds ---------- */

/*
 * Frosted glass over the gradient: it takes the backdrop's color, with a
 * bright rim on top and a blue-tinted shadow, so it sits in the light rather
 * than on it.
 */
.kinds {
  position: absolute;
  top: 180px;
  left: 50%;
  display: flex;
  gap: 2px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.42) 0%, rgba(255, 255, 255, 0.22) 100%);
  -webkit-backdrop-filter: blur(24px) saturate(1.6);
  backdrop-filter: blur(24px) saturate(1.6);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.7),
    inset 0 -1px 0 rgba(120, 170, 220, 0.18),
    0 12px 32px -16px rgba(24, 92, 170, 0.35);
  translate: -50% 0;
}

/* Placed on the current tab by overlays.js. */
.kinds-pill {
  position: absolute;
  top: 4px;
  left: 0;
  height: calc(100% - 8px);
  border-radius: 13px;
  background: linear-gradient(180deg, #ffffff 0%, rgba(255, 255, 255, 0.9) 100%);
  box-shadow:
    0 1px 2px rgba(24, 72, 130, 0.12),
    0 6px 16px -8px rgba(24, 92, 170, 0.35);
}

.kind {
  position: relative;
  cursor: pointer;
  padding: 13px 22px;
  color: rgba(18, 52, 96, 0.55);
  font: 600 21px/1 var(--font);
  letter-spacing: -0.01em;
  text-align: center;
  white-space: nowrap;
  transition: color 200ms ease;
}

.kind.is-on { color: #0f2744; }

/* ---------- The panel and its view ---------- */

/* Only the top-left corner shows; the rest runs off the stage. */
.app {
  position: absolute;
  top: 270px;
  left: 56px;
  width: 1024px;
  height: 1170px;
  overflow: hidden;
  border-radius: 28px 0 0 0;
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.6), 0 40px 90px -30px rgba(16, 72, 150, 0.4);
  color: var(--ink);
}

/* The page at its real size; overlays.js scales it into the panel. */
.camera {
  position: absolute;
  top: 0;
  left: 0;
  width: 1280px;
  height: 1463px;
  transform-origin: 0 0;
}

.app svg {
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Sidebar ---------- */

.side {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 232px;
  padding: 16px 12px;
  border-right: 1px solid var(--line-soft);
  background: #fafafa;
}

.workspace {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  padding: 0 6px;
  font: 600 14px/1 var(--font);
  letter-spacing: -0.01em;
}

.workspace svg { width: 14px; height: 14px; margin-left: auto; color: var(--muted); }

/* The app icon carries its own rounded square. */
.logo { width: 22px; height: 22px; }

.command {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  margin: 10px 0 14px;
  padding: 0 6px 0 10px;
  border-radius: var(--r-control);
  background: var(--fill);
  color: var(--faint);
  font: 500 13px/1 var(--font);
}

.command svg { width: 14px; height: 14px; color: var(--muted); }

kbd {
  margin-left: auto;
  padding: 3px 5px;
  border-radius: var(--r-badge);
  background: #ffffff;
  color: var(--muted);
  font: 500 11px/1 var(--tip-font-mono);
  box-shadow: 0 0 0 1px var(--line);
}

.nav { display: grid; gap: 1px; }

.nav span {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 32px;
  padding: 0 8px;
  border-radius: var(--r-item);
  color: var(--text);
  font: 500 14px/1 var(--font);
}

.nav svg { width: 18px; height: 18px; color: var(--muted); }

.nav em {
  margin-left: auto;
  color: var(--muted);
  font: 500 11px/1 var(--tip-font-mono);
  font-style: normal;
}

.nav .is-on { background: var(--fill-hover); color: var(--ink); font-weight: 600; }
.nav .is-on svg { color: var(--ink); }

.side-label {
  margin: 18px 8px 6px;
  color: var(--faint);
  font: 600 11px/1 var(--font);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* ---------- Members ---------- */

.main {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 232px;
}

.head,
.bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 24px;
  border-bottom: 1px solid var(--line-soft);
}

.head { height: 52px; }
.bar { height: 48px; }

.crumbs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 auto 0 0;
  font: 500 14px/1 var(--font);
}

.crumbs svg { width: 16px; height: 16px; color: var(--muted); }
.crumbs .dim { color: var(--muted); }
.crumbs i { color: #d4d4d8; font-style: normal; }
.crumbs b { font-weight: 600; }

.stack { display: flex; margin-right: 8px; }

.stack { align-items: center; }

.stack .avatar,
.stack em {
  width: 26px;
  height: 26px;
  margin-left: -2px;
  box-shadow: 0 0 0 2px #ffffff;
  font-size: 9px;
}

/* The rest of the team, as one more circle. */
.stack em {
  display: grid;
  place-items: center;
  border-radius: 50%;
  --lumno-corner-shape: round;
  background: var(--fill);
  color: var(--muted);
  font: 600 9px/1 var(--font);
  font-style: normal;
}

/* A segmented control: the current view lifts out of the gray track. */
.views {
  display: flex;
  gap: 2px;
  margin-right: auto;
  padding: 2px;
  border-radius: var(--r-control);
  background: var(--fill);
}

.views span {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 26px;
  padding: 0 10px;
  border-radius: var(--r-item);
  color: var(--muted);
  font: 500 13px/1 var(--font);
}

.views .is-on {
  background: #ffffff;
  color: var(--ink);
  font-weight: 600;
  box-shadow: var(--shadow-secondary), 0 0 0 1px var(--line-soft);
}

.views em,
.group em {
  padding: 2px 4px;
  border-radius: var(--r-badge);
  background: rgba(15, 23, 42, 0.06);
  color: var(--muted);
  font: 500 11px/1 var(--tip-font-mono);
  font-style: normal;
}

.icon-tools { display: flex; gap: 2px; }

/* ---------- Overview ---------- */

.overview { display: grid; gap: 12px; padding: 16px 24px 0; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.stat,
.chart {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--r-popover);
}

.stat { height: 120px; padding: 16px 18px; }

.stat p,
.chart p {
  margin: 0;
  color: var(--muted);
  font: 500 13px/1 var(--font);
}

/* The figure, at display size. */
.stat b {
  display: block;
  margin: 12px 0 10px;
  font: 600 36px/1 var(--font);
  letter-spacing: -0.025em;
}

.stat small { color: var(--faint); font-size: 20px; font-weight: 500; letter-spacing: -0.01em; }
.stat > span:not(.viz) { display: flex; align-items: center; gap: 6px; color: var(--muted); font: 500 13px/1 var(--font); }

.delta {
  padding: 3px 6px;
  border-radius: var(--r-badge);
  background: #ecfdf3;
  color: #15803d;
  font: 600 12px/1 var(--font);
  font-style: normal;
}

/* Each figure's small chart, the same height at the card's right. */
/* Each figure's small chart: the same height, its foot on the card's
   bottom padding. */
.stat .viz {
  position: absolute;
  right: 18px;
  bottom: 16px;
  height: 64px;
}

.stat .spark { width: 160px; overflow: visible; }
.stat .spark .area { fill: url(#spark-fill); stroke: none; }
.stat .spark .line { stroke: url(#spark-line); stroke-width: 2.5; }
.stat .spark .halo { fill: rgba(37, 99, 235, 0.16); stroke: none; }
.stat .spark .end { fill: #ffffff; stroke: var(--blue); stroke-width: 2; }

/* Seven days to today, each bar over its weekday. */
.stat .bars { display: flex; gap: 6px; }

.stat .viz.bars { right: 16px; }

.stat .day {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  width: 14px;
}

.stat .day i {
  width: 100%;
  border-radius: 4px;
  background: linear-gradient(180deg, #c7d8fb 0%, #e3ecfd 100%);
}

.stat .day em {
  color: var(--faint);
  font: 600 10px/1 var(--font);
  font-style: normal;
}

.stat .day.is-today i {
  position: relative;
  background: linear-gradient(180deg, #3b82f6 0%, #1d4ed8 100%);
  box-shadow: 0 4px 10px -4px rgba(29, 78, 216, 0.6);
}

/* Today's count, over its bar. */
.stat .day.is-today i::before {
  content: "14";
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  color: var(--blue);
  font: 700 11px/1 var(--font);
  translate: -50% 0;
}

.stat .day.is-today em { color: var(--blue); }

/* As tall as the text beside it: from the label's top to the caption's foot. */
.stat .viz.ring { top: 16px; bottom: 16px; display: grid; place-items: center; width: 88px; height: auto; }
.stat .ring svg { position: absolute; inset: 0; width: 88px; height: 88px; rotate: -90deg; }
.stat .ring circle { fill: none; stroke-width: 6.5; }
.stat .ring .track { stroke: #e7eeec; }
.stat .ring .arc { stroke: url(#ring-arc); stroke-linecap: round; }
.stat .ring b { position: relative; margin: 0; color: #0f766e; font: 700 17px/1 var(--font); letter-spacing: -0.01em; }

.chart { padding: 14px 16px 10px; }

.chart header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 10px;
}

.chart p b { display: block; margin-bottom: 5px; color: var(--ink); font-size: 13px; font-weight: 600; }

.legend {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--muted);
  font: 500 12px/1 var(--font);
}

.legend i { width: 10px; height: 2px; border-radius: 1px; background: var(--blue); }

.plot { display: block; width: 100%; height: 148px; overflow: visible; }
.plot .grid { stroke: var(--line-soft); stroke-width: 1; }
/* Text takes no stroke from the icon rule above. */
.plot .axis { fill: var(--faint); stroke: none; font: 500 11px/1 var(--font); }
.plot .area { fill: url(#plot-fill); stroke: none; }
.plot .line { fill: none; stroke: var(--blue); stroke-width: 2; stroke-linejoin: round; }

/* Where the pointer is, snapped to the nearest week. */
.plot .guide { stroke: rgba(37, 99, 235, 0.35); stroke-width: 1; stroke-dasharray: 3 3; opacity: 0; }
.plot .dot { fill: #ffffff; stroke: var(--blue); stroke-width: 2; opacity: 0; }
.plot.is-hovered :is(.guide, .dot) { opacity: 1; }

.table { padding: 8px 24px 0; }

/* Columns: name, role, team, last active, the row's tools. */
.cols,
.row {
  display: grid;
  grid-template-columns: 200px 96px 180px 1fr 28px;
  align-items: center;
  gap: 0 16px;
  padding: 0 12px;
}

.cols {
  height: 32px;
  color: var(--muted);
  font: 500 12px/1 var(--font);
}

.group {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 36px;
  margin: 12px 0 4px;
  padding: 0 12px;
  border-radius: var(--r-control);
  background: var(--tint);
}

.cols + .group { margin-top: 4px; }

.group i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  --lumno-corner-shape: round;
  background: var(--dot);
}

.group b { font: 500 12px/1 var(--tip-font-mono); }
.group em { background: #ffffff; box-shadow: 0 0 0 1px var(--line); }
.group svg { width: 16px; height: 16px; margin-left: auto; color: var(--muted); }

.row {
  position: relative;
  height: 44px;
  border-radius: var(--r-item);
  font: 500 14px/1.3 var(--font);
  transition: background 160ms ease, box-shadow 160ms ease;
}

.row[data-state],
.row.is-asking { background: #fafafa; box-shadow: inset 0 0 0 1px var(--line); }
.row.is-flash { background: #eef4ff; box-shadow: none; }

.who { display: flex; align-items: center; gap: 10px; min-width: 0; }

/* People are round, in one flat color each. */
.avatar {
  display: grid;
  flex: none;
  place-items: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  --lumno-corner-shape: round;
  background: var(--c);
  color: #ffffff;
  font: 600 10px/1 var(--font);
  font-style: normal;
}

.avatar.is-pending {
  border: 1px dashed #d4d4d8;
  background: #ffffff;
  color: var(--muted);
}

.avatar.is-large { width: 36px; height: 36px; font-size: 13px; }

.name,
.team span {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.name { min-width: 0; }

.team {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  color: var(--text);
  font-size: 13px;
}

.team svg { width: 14px; height: 14px; color: var(--muted); }

.active { color: var(--muted); font-size: 13px; white-space: nowrap; }

/* Roles as outlined badges, like a status. */
.role {
  justify-self: start;
  padding: 3px 6px;
  border: 1px solid #e4e4e7;
  border-radius: var(--r-badge);
  background: #fafafa;
  color: #52525b;
  font: 600 12px/1 var(--font);
  transition: background 200ms ease, color 200ms ease, border-color 200ms ease;
}

.role[data-role="Admin"] { border-color: #bfdbfe; background: #eff6ff; color: #1d4ed8; }
.role[data-role="Viewer"] { border-style: dashed; background: #ffffff; }
.role[data-role="Invited"] { border-color: #fed7aa; background: #fff7ed; color: #c2410c; }

/* Shown on the row the pointer is on. */
.row-tools { justify-self: end; opacity: 0; transition: opacity 120ms ease; }
.row[data-state] .row-tools,
.row.is-asking .row-tools { opacity: 1; }

.pager {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 16px 12px 0;
  color: var(--muted);
  font: 500 12px/1 var(--font);
}

.pager b { margin-right: auto; color: var(--text); font-weight: 600; }

/* ---------- Buttons ---------- */

/*
 * Primary carries Lumno's sheen. Most actions sit on a gray fill or show
 * only on hover; white with a hairline is kept for form controls. Pressing
 * changes the fill or sinks the shadow, never the button's size or place.
 */
.btn,
.icon-btn {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  gap: 6px;
  height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--r-control);
  background: var(--fill);
  color: var(--ink);
  font: 600 13px/1 var(--font);
  white-space: nowrap;
  transition: background 160ms ease, box-shadow 120ms ease, color 160ms ease;
}

.btn svg { width: 14px; height: 14px; }
.btn b { font-weight: 600; }

.btn[data-state] { background: var(--fill-hover); }
.btn[data-state="pressed"] { background: #e2e2e5; }

.icon-btn {
  width: 32px;
  padding: 0;
  background: transparent;
  color: var(--muted);
}

.icon-btn svg { width: 16px; height: 16px; }
.icon-btn[data-state] { background: var(--fill); color: var(--ink); }
.icon-btn[data-state="pressed"] { background: var(--fill-hover); }

.btn.is-primary,
.btn.is-danger {
  background: var(--primary);
  color: #ffffff;
  box-shadow: inset 0 0 0 1px #12161f, var(--shadow-primary);
}

.btn.is-primary[data-state] { background: var(--primary-hover); }

.btn.is-danger { background: var(--danger); box-shadow: inset 0 0 0 1px #9f2a2e, var(--shadow-primary); }
.btn.is-danger[data-state] { background: var(--danger-hover); }

.btn.is-primary[data-state="pressed"],
.btn.is-danger[data-state="pressed"] { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.3), var(--shadow-primary-pressed); }

/* A destructive action that still waits for a confirmation. */
.btn.is-red { color: var(--red); }
.btn.is-red[data-state] { background: #fde8e8; }
.btn.is-red[data-state="pressed"] { background: #fbdcdc; }

/* Inside a popover, one step smaller. */
.btn.is-small { height: 28px; padding: 0 10px; border-radius: var(--r-item); font-size: 12px; }
.icon-btn.is-small { width: 28px; height: 28px; border-radius: var(--r-item); }
.icon-btn.is-red[data-state] { background: #fef2f2; color: var(--red); }

/* ---------- Tooltip (Lumno's shared tooltip) ---------- */

.tooltip {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 8;
  padding: 6px 9px;
  border: 1px solid rgba(214, 219, 227, 0.95);
  border-radius: var(--r-item);
  background: linear-gradient(180deg, #ffffff 0%, #f7f9fc 100%);
  color: #556070;
  font: 500 12px/1.35 var(--font);
  white-space: nowrap;
  box-shadow: 0 8px 20px rgba(17, 24, 39, 0.08), 0 2px 6px rgba(17, 24, 39, 0.05);
  pointer-events: none;
  opacity: 0;
  translate: 0 4px;
  transition: opacity 120ms ease, translate 120ms ease;
}

.tooltip[data-visible] { opacity: 1; translate: 0 0; }

/* The one beside the pointer: a value, then what it is. */
.tooltip.is-cursor { width: max-content; max-width: 260px; white-space: normal; }
.tooltip.is-cursor b { display: block; margin-bottom: 2px; color: var(--ink); font-weight: 600; }

/* ---------- Confirm in place ---------- */

.confirm-wrap { position: relative; }

/* Grows from the button's corner, down and to the left. */
.confirm {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 3;
  width: 232px;
  padding: 12px;
  border-radius: var(--r-popover);
  background: #ffffff;
  box-shadow: var(--shadow-popover);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px) scale(0.98);
  transform-origin: top right;
  transition: opacity 160ms ease, transform 180ms ease, visibility 0s linear 180ms;
}

.confirm[data-open] {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition-delay: 0s;
}

.confirm p {
  margin: 0;
  color: var(--muted);
  font: 500 12px/1.45 var(--font);
}

.confirm p b {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
}

/* Two equal buttons on the same edges as the text. */
.confirm footer {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 12px;
}

/* ---------- Scrims ---------- */

.scrim {
  position: absolute;
  inset: 0;
  z-index: 4;
  background: rgba(15, 23, 42, 0.05);
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}

.scrim.is-dim { background: rgba(15, 23, 42, 0.16); transition-duration: 170ms; }
.scrim[data-open] { opacity: 1; }

/* The page softens behind the dialog. */
.app :is(.side, .main, .drawer) { transition: filter 170ms ease; }
.app[data-modal] :is(.side, .main, .drawer) { filter: blur(2px); }

/* ---------- Drawer ---------- */

.drawer {
  position: absolute;
  top: 8px;
  right: 8px;
  bottom: 8px;
  z-index: 5;
  display: flex;
  flex-direction: column;
  width: 400px;
  border-radius: var(--r-panel);
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.07), 0 20px 48px -12px rgba(15, 23, 42, 0.22);
  translate: calc(100% + 24px) 0;
  transition: translate 200ms cubic-bezier(0.4, 0, 1, 1);
}

.drawer[data-open] {
  translate: 0 0;
  transition: translate 340ms var(--ease-out);
}

.drawer-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border-bottom: 1px solid var(--line-soft);
}

.drawer-who { flex: 1; min-width: 0; }
.drawer-who b { display: block; font: 600 15px/1.25 var(--font); }
.drawer-who span { display: block; margin-top: 3px; color: var(--muted); font: 500 12px/1.2 var(--tip-font-mono); }

.drawer-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 20px;
  padding: 16px;
}

.field-label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  color: var(--text);
  font: 600 12px/1 var(--font);
}

.field-label em { color: var(--muted); font: 500 11px/1 var(--tip-font-mono); font-style: normal; }

.choices { display: grid; gap: 6px; }

.choice {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--r-control);
  color: var(--muted);
  font: 500 12px/1.4 var(--font);
  transition: background 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.choice b { display: block; margin-bottom: 1px; color: var(--ink); font-size: 13px; font-weight: 600; }
.choice[data-state] { background: #fafafa; }

.radio {
  flex: none;
  width: 14px;
  height: 14px;
  margin-top: 2px;
  border: 1.5px solid #d4d4d8;
  border-radius: 50%;
  --lumno-corner-shape: round;
  background: #ffffff;
  box-sizing: border-box;
  transition: border 160ms ease;
}

/* Picked: a solid blue edge, drawn inside so the card keeps its size. */
.choice.is-on {
  border-color: var(--blue);
  background: #f5f9ff;
  box-shadow: inset 0 0 0 0.5px var(--blue);
}

.choice.is-on .radio { border: 4.5px solid var(--blue); }

.tokens {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: var(--r-control);
}

.token {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 24px;
  padding: 0 4px 0 8px;
  border-radius: var(--r-badge);
  background: var(--fill);
  color: var(--text);
  font: 500 12px/1 var(--font);
}

.token svg { width: 12px; height: 12px; color: var(--muted); }
.token-input { padding: 0 6px; color: var(--faint); font: 500 12px/1 var(--font); }

.access { border: 1px solid var(--line); border-radius: var(--r-control); }

.access-row {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 6px 0 12px;
  color: var(--text);
  font: 500 13px/1 var(--font);
}

.access-row + .access-row { border-top: 1px solid var(--line-soft); }

.access-row i {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  background: var(--c);
}

.access-row > span:first-of-type { flex: 1; }

/* A form control: white with a hairline. */
.select {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 26px;
  padding: 0 4px 0 8px;
  border-radius: var(--r-item);
  background: #ffffff;
  color: #1f2937;
  font: 500 12px/1 var(--font);
  box-shadow: var(--shadow-secondary), 0 0 0 1px var(--line);
}

.select svg { width: 12px; height: 12px; color: var(--muted); }

.switch-row,
.danger {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font: 500 12px/1.4 var(--font);
}

.switch-row span,
.danger span { flex: 1; }

.switch-row b,
.danger b { display: block; margin-bottom: 1px; color: var(--ink); font-size: 13px; font-weight: 600; }

/* Set apart by a rule, not a box. */
.danger { padding-top: 20px; border-top: 1px solid var(--line-soft); }

/* Lumno's toggle, on. */
.toggle {
  position: relative;
  flex: none;
  width: 32px;
  height: 20px;
  border-radius: 999px;
  --lumno-corner-shape: round;
  background: linear-gradient(180deg, #4d7dcb 0%, #3462ad 100%);
  box-shadow: inset 0 1px 2px rgba(12, 32, 72, 0.3);
}

.toggle::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  --lumno-corner-shape: round;
  background: #ffffff;
  box-shadow: 0 0 0 0.5px rgba(15, 23, 42, 0.06), 0 1px 1px rgba(15, 23, 42, 0.06), 0 2px 5px rgba(15, 23, 42, 0.14);
}

.drawer-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px 16px;
  border-top: 1px solid var(--line-soft);
  color: var(--muted);
  font: 500 12px/1 var(--font);
}

/* ---------- Dialog ---------- */

/* Who, what happens to their work, what it costs, then the choice. */
.dialog {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 6;
  width: 400px;
  margin: -150px 0 0 -200px;
  overflow: hidden;
  border-radius: var(--r-panel);
  background: #ffffff;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.07), 0 20px 48px -12px rgba(15, 23, 42, 0.26);
  opacity: 0;
  visibility: hidden;
  transform: scale(0.97);
  transition: opacity 170ms ease, transform 170ms ease, visibility 0s linear 170ms;
}

.dialog[data-open] {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 170ms ease, transform 260ms var(--ease-out), visibility 0s;
}

.dialog-body { padding: 20px; }

.dialog h3 { margin: 0; font: 600 15px/1.3 var(--font); }

.who-card {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding: 10px 12px;
  border-radius: var(--r-control);
  background: #f7f7f8;
}

.who-card .avatar { width: 32px; height: 32px; font-size: 11px; }
.who-card span { flex: 1; min-width: 0; color: var(--muted); font: 500 12px/1.3 var(--font); }
.who-card b { display: block; margin-bottom: 2px; color: var(--ink); font: 600 13px/1.3 var(--font); }

.dialog-field {
  display: grid;
  gap: 6px;
  margin-top: 16px;
  color: var(--text);
  font: 600 12px/1 var(--font);
}

.dialog-field .select { height: 32px; padding: 0 8px 0 10px; border-radius: var(--r-control); font-size: 13px; }
.dialog-field .select svg { margin-left: auto; }

/* What it costs, right above the buttons; the red is left to the button. */
.warn {
  margin: 14px 0 0;
  color: var(--muted);
  font: 500 12px/1.5 var(--font);
}

.dialog-foot {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 20px;
  border-top: 1px solid var(--line-soft);
  background: #fafafa;
}

/* ---------- Notes ---------- */

.notes { position: absolute; inset: 0; z-index: 7; pointer-events: none; }

/* Set straight on the gradient above the tabs, in the tabs' ink. */
.note {
  position: absolute;
  margin: 0;
  text-align: center;
  opacity: 0;
}

.note-title {
  margin: 0;
  color: #0f2744;
  font: 650 44px/1.15 var(--font);
  letter-spacing: -0.02em;
  white-space: nowrap;
}

.note-sub {
  margin: 12px 0 0;
  color: rgba(15, 39, 68, 0.6);
  font: 500 25px/1.35 var(--font);
  letter-spacing: -0.01em;
  white-space: nowrap;
}

/* The pointer's name tag steps aside for the tooltip that follows it. */
.tip-pointer-label { transition: opacity 120ms ease; }

/* Faint text over the panel, no backing. The handle keeps the series' face
   and size, so it matches the wordmark beside it. */
.tip-credit {
  right: auto;
  left: 50%;
  bottom: 30px;
  z-index: 9;
  color: rgba(15, 39, 68, 0.32);
  font-family: var(--tip-font-sans);
  translate: -50% 0;
}

.tip-credit img { filter: brightness(0); opacity: 0.32; }
