/* pilot/reworked/assets/app.css — WEVA-W-041 round 2
 * Page-level layout for the consolidated prototype. Tokens, glass, the
 * side rail, motion/transparency fallbacks all live in glass.css. Every
 * card/panel here is .surface (opaque) — restraint rule, glass stays on
 * the rail/popovers/marquee band only. */

.eyebrow { margin: 0 0 6px; font-size: 13px; }
.eyebrow a { color: var(--text2); text-decoration: none; }
.eyebrow a:hover { color: var(--text); }

.page-head { margin-bottom: 18px; }
.page-head h1 { margin: 0 0 6px; font-size: clamp(24px, 3vw, 32px); font-weight: 600; letter-spacing: -0.01em; color: var(--primary); }
.page-head .lead { margin: 0; color: var(--text2); font-size: 14.5px; max-width: 62ch; }

.rule { border: none; border-top: 1px solid var(--border); margin: 26px 0; }

.variant-banner {
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 18px; padding: 10px 16px; border-radius: 999px;
  font-size: 13px; font-weight: 600;
  background: color-mix(in srgb, var(--accent) 14%, var(--surface));
  border: 1px solid var(--border); color: var(--text);
}

/* ======================================================== top glass band === */
.top-band {
  position: relative;
  margin: 14px 0 0;
  min-height: 104px;
  padding-block: 14px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
}
/* Round 6 criterion 1: the caption ("Weaving Skills together") and the
   landing page's "Welcome to Weva" heading now sit below and outside the
   glass band, on the plain page background — the band shrank back down
   (its height no longer needs to fit the caption inside it) once
   .brand-mark went horizontal too (criterion 3). */
.top-caption {
  margin: 12px 0 22px;
  text-align: center;
  font-size: 11px; font-weight: 700; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--text2);
}
.welcome-heading {
  margin: 10px 0 30px;
  text-align: center;
  font-size: clamp(19px, 2.6vw, 25px); font-weight: 700; letter-spacing: 0.05em;
  text-transform: uppercase; color: var(--primary);
}
/* Round 4 criterion 4: the band grew taller to fit the brand mark's new
   wordmark/caption underneath the orb — .marquee itself now centers its
   track vertically (the track has no fixed height of its own), so the
   30px logos land mid-band rather than pinned to the top. */
.marquee { position: absolute; inset: 0; overflow: hidden; display: flex; align-items: center; }
.marquee-track {
  display: flex; align-items: center; gap: 46px;
  width: max-content;
  padding-inline: 23px;
  animation: marquee-scroll 32s linear infinite;
}
@keyframes marquee-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}
.marquee-logo { display: flex; align-items: center; gap: 8px; color: var(--text2); opacity: 0.55; flex-shrink: 0; }
.marquee-logo img { width: 30px; height: 30px; display: block; }
.marquee-logo span { font-size: 13px; font-weight: 600; white-space: nowrap; }

/* Round 4 criterion 5: near-opaque (max 5% see-through) so the mark reads
   clearly over the moving band, sourced from the existing Indigo-Tuch
   surface-2 token rather than the ~20%-transparent glass-ring look round 2
   shipped — no new hex. color-mix keeps it token-based rather than a raw
   hex at a fixed alpha.
   Round 6.1: the near-opaque backdrop moved from here to the wrapping
   .brand-mark below, so it now occludes the wordmark too, not just this
   circle — .brand-orb itself no longer carries its own separate glass
   layer (avoids nesting glass on glass; the restraint rule both the round-1
   and round-4 research sections already name). */
.brand-orb {
  position: relative; z-index: 2;
  width: 56px; height: 56px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.brand-orb img { width: 30px; height: 30px; display: block; }
.brand-orb img.for-light { display: none; }
:root[data-theme="light"] .brand-orb img.for-light { display: block; }
:root[data-theme="light"] .brand-orb img.for-dark { display: none; }

/* Round 4 criteria 5/6: the orb and a visible "WEVA" wordmark, was a single
   screen-reader-only span before (.brand-orb-label at left:-9999px); now
   shown so the combined read is the glyph plus the wordmark, not the glyph
   alone. Round 6 criterion 3: the pair is now a single horizontal line
   (the "W weva" lockup reference) instead of stacked — the caption that
   used to sit under this unit moved out to the plain .top-caption element
   below the whole band (criterion 1), so .brand-mark now holds only the
   glyph + wordmark.
   Round 6.1: .brand-mark carries the near-opaque backdrop itself (the same
   recipe .brand-orb used alone before) so the whole horizontal lockup —
   orb and wordmark together — occludes the marquee behind it, not just
   the circle. The wordmark previously sat directly on the marquee track
   with nothing behind it; at some scroll positions a logo/label showed
   through around and between its letters. */
.brand-mark {
  position: relative; z-index: 2;
  display: flex; flex-direction: row; align-items: center; gap: 12px;
  padding: 8px 24px 8px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--surface-2) 96%, transparent);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(var(--glass-saturate));
  box-shadow: 0 8px 26px rgba(0,0,0,0.22);
}
@media (prefers-reduced-transparency: reduce) {
  .brand-mark { background: var(--surface); backdrop-filter: none; -webkit-backdrop-filter: none; }
}
.brand-orb-label {
  font-size: 20px; font-weight: 800; letter-spacing: 0.03em;
  text-transform: uppercase; color: var(--text);
}

/* ======================================================== hero columns === */
.hero-columns {
  display: grid;
  grid-template-columns: 260px 1fr 260px;
  gap: var(--gap-lg);
  align-items: start;
  padding-block: 4px 30px;
}
.rail-col-title { margin: 0 0 10px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text2); }
.teaser-col { display: flex; flex-direction: column; gap: var(--gap-lg); }
.teaser-card {
  display: flex; align-items: center; gap: 12px; padding: 12px 14px;
}
.teaser-thumb {
  width: 36px; height: 36px; border-radius: var(--radius-sm); flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; color: var(--text);
  background: var(--surface-2);
}
.teaser-card .title { margin: 0; font-size: 13.5px; font-weight: 600; color: var(--text); }
.teaser-card .meta { margin: 2px 0 0; font-size: 11.5px; color: var(--text2); }
.browse-all-link {
  display: block; text-align: center; padding: 10px;
  font-size: 12.5px; font-weight: 600; color: var(--text2); text-decoration: none;
  border-radius: var(--radius-sm);
}
.browse-all-link:hover { color: var(--text); background: var(--surface); }

/* Center hero panel — the single "Explore. Share. Learn." block (criterion
   2: appears exactly once), given a shine/glow treatment for round 2's
   "moodier, more saturated" instruction, built only from tokens already
   in the palette. */
.hero-center { display: flex; flex-direction: column; gap: 12px; }
.hero-glow {
  position: relative;
  overflow: hidden;
  padding: 46px 28px;
  text-align: center;
  background:
    radial-gradient(120% 140% at 50% -10%, color-mix(in srgb, var(--accent) 22%, transparent), transparent 60%),
    linear-gradient(160deg, var(--surface-2), var(--bg) 120%);
  border: 1px solid var(--border);
}
/* Round 6 criterion 2: .hero-glow now also carries .pointer-glass (added
   by shell.js), which owns ::before for its own radial pointer-highlight
   — the diagonal shine below moved to ::after so the two don't collide on
   the same pseudo-element (same specificity, and app.css loads after
   glass.css, so .pointer-glass::before would otherwise win outright and
   this shine would silently stop rendering). */
.hero-glow::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(120deg, transparent 30%, color-mix(in srgb, var(--text) 10%, transparent) 50%, transparent 70%);
  pointer-events: none;
}
.hero-glow h1 {
  position: relative; z-index: 1;
  margin: 0; font-size: clamp(30px, 4.6vw, 48px); font-weight: 700; line-height: 1.14;
  color: var(--text);
}
/* WEVA-W-235 round 4: the principle pill sits above the diagonal shine too,
   like the heading and the buttons; under it, the shine lightened Deep
   Purple to 4.24:1 against its Lilac White label (4.91:1 without). */
.hero-glow .principle { position: relative; z-index: 1; }
.hero-glow .cta-row { position: relative; z-index: 1; margin-top: 20px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.cta {
  display: inline-flex; align-items: center; padding: 10px 20px; border-radius: 999px;
  font-size: 14px; font-weight: 600; text-decoration: none; border: 1px solid var(--border);
}
.cta.primary { background: var(--primary); color: var(--bg); border-color: transparent; }
.cta.secondary { background: var(--surface); color: var(--text); }

.featured-strip { display: flex; align-items: center; gap: 10px; padding: 12px 16px; }
.glow-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex-shrink: 0; }
.featured-strip .name { margin: 0; font-size: 12.5px; font-weight: 700; color: var(--text); }
.featured-strip .meta { margin: 1px 0 0; font-size: 11.5px; color: var(--text2); }
.growth-chip {
  margin-left: auto; font-size: 12px; font-weight: 700; color: var(--on-accent);
  background: var(--accent); padding: 4px 10px; border-radius: 999px; flex-shrink: 0;
}

/* ======================================================== dashboard === */
.dash-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap-lg); }
.dash-card { padding: 18px; text-decoration: none; display: block; }
.dash-card h4 { margin: 0 0 6px; font-size: 13px; font-weight: 600; color: var(--text2); text-transform: uppercase; letter-spacing: 0.03em; }
.dash-card .count { margin: 0; font-size: 26px; font-weight: 700; color: var(--primary); }
.dash-card .meta { display: block; margin-top: 4px; font-size: 12px; color: var(--text2); }

/* ======================================================== discover split === */
.discover-split { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap-lg); }
.discover-block { padding: 20px; }
.discover-block h3 { margin: 0 0 4px; font-size: 17px; font-weight: 600; color: var(--text); }
.discover-block .sub { margin: 0 0 14px; font-size: 13px; color: var(--text2); }
.discover-mini-grid { display: flex; flex-direction: column; gap: var(--gap-lg); margin-bottom: 12px; }
.discover-mini-row {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px;
  border-radius: var(--radius-sm); background: var(--surface-2);
}
.discover-mini-row .title { margin: 0; font-size: 13px; font-weight: 600; color: var(--text); }
.discover-mini-row .meta { margin: 1px 0 0; font-size: 11px; color: var(--text2); }

/* ======================================================== forms === */
.field-form { display: flex; flex-direction: column; gap: 10px; }
.field-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; }
.field {
  display: flex; flex-direction: column; gap: 4px; flex: 1; min-width: 160px;
}
.field-label { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--text2); }
/* WEVA-W-073: `type="search"` added to this list - app_admin.html's filter
   input is the first `.field` control of that type; every earlier page
   restyled onto this vocabulary only ever needed text/file/select/textarea.
   Reusing the existing scoped rule rather than adding a new class, per that
   order's own file-list note. */
.field input[type="text"], .field input[type="file"], .field input[type="search"],
.field select, .field textarea {
  font-family: inherit; font-size: 14px; color: var(--text);
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 9px 12px;
}
.field textarea { resize: vertical; }
.readonly-slug {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 13px; color: var(--text2);
  background: var(--surface-2); border: 1px dashed var(--border);
  border-radius: var(--radius-sm); padding: 9px 12px;
}
.btn {
  font-family: inherit; font-size: 13.5px; font-weight: 600; cursor: pointer;
  border-radius: 999px; padding: 9px 18px; border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text);
}
.btn.primary { background: var(--primary); color: var(--bg); border-color: transparent; }
.btn.danger { background: transparent; color: var(--brand-error-text); border-color: color-mix(in srgb, var(--brand-error) 50%, var(--border)); }
.btn.small { padding: 6px 12px; font-size: 12.5px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.form-status { font-size: 13px; color: var(--text2); min-height: 1em; }

/* ======================================================== grids/cards === */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: var(--gap-lg); }
.card-link { text-decoration: none; display: block; }

/* Stacked rows (e.g. the Circles list) that aren't a .grid — round 4
   criterion 10: these had no gap at all between rows (touching), unlike
   .grid's already-set gap. Same uniform scale. */
.row-stack { display: flex; flex-direction: column; gap: var(--gap-lg); }

/* Circle rows — Discourse-style list (criterion 9): name, description,
   member count, member avatars, skills-published count. */
.circle-row {
  display: flex; align-items: center; gap: 14px; padding: 14px 16px;
  text-decoration: none; color: inherit;
}
.circle-row .avatars { display: flex; margin-right: 4px; flex-shrink: 0; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 12px; color: var(--brand-text);
  border: 2px solid var(--surface);
  margin-left: -8px;
}
.avatar:first-child { margin-left: 0; }
/* WEVA-W-235 round 4: five brand hues, each a tint of the card surface
   (30% then 18%) under the brand's text colour - 8.3:1 or more in both
   modes (Lavender, the lightest tint in dark, is the floor). The old fixed
   gradients carried white at 3.4:1 to 4.2:1. */
.avatar--0 { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-surface), var(--brand-blue) 30%), color-mix(in srgb, var(--brand-surface), var(--brand-blue) 18%)); }
.avatar--1 { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-surface), var(--brand-accent) 30%), color-mix(in srgb, var(--brand-surface), var(--brand-accent) 18%)); }
.avatar--2 { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-surface), var(--brand-lavender) 30%), color-mix(in srgb, var(--brand-surface), var(--brand-lavender) 18%)); }
.avatar--3 { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-surface), var(--brand-accent-bright) 30%), color-mix(in srgb, var(--brand-surface), var(--brand-accent-bright) 18%)); }
.avatar--4 { background: linear-gradient(135deg, color-mix(in srgb, var(--brand-surface), var(--brand-accent-fill) 30%), color-mix(in srgb, var(--brand-surface), var(--brand-accent-fill) 18%)); }
.circle-row .body { flex: 1; min-width: 0; }
.circle-row .title { margin: 0; font-size: 15px; font-weight: 600; color: var(--text); }
.circle-row .desc { margin: 2px 0 0; font-size: 12.5px; color: var(--text2); }
.circle-row .stats { display: flex; gap: 14px; flex-shrink: 0; font-size: 12px; color: var(--text2); }
.circle-row .stats strong { color: var(--text); font-weight: 700; }
.circle-row .chev { color: var(--text2); flex-shrink: 0; }

/* Skill cards (criterion 15): name + picture only. */
.skill-card-mini { padding: 16px; text-align: center; }
.skill-card-mini .logo {
  width: 56px; height: 56px; border-radius: var(--radius-md); margin: 0 auto 10px;
  display: flex; align-items: center; justify-content: center;
  background: var(--surface-2); overflow: hidden;
}
.skill-card-mini .logo img { width: 100%; height: 100%; object-fit: cover; }
.skill-card-mini h4 { margin: 0; font-size: 14.5px; font-weight: 600; color: var(--text); }
/* WEVA-W-235 round 4: accent words are the brand's accent (Purple, 4.60:1 on the dark surface), and with no wash under them: any purple wash takes Purple below 4.5:1 in dark. */
.skill-card-mini .mcp-badge { display: inline-block; margin-top: 6px; font-size: 10.5px; font-weight: 700; color: var(--brand-accent); border: 1px solid color-mix(in srgb, var(--brand-accent) 45%, transparent); border-radius: 999px; padding: 2px 7px; }

/* ======================================================== share page === */
/* Round 4 criterion 2: "Share this site" is its own page now, not a rail
   popover — same four channels, same static/disabled convention. */
.share-channel-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: var(--gap-lg); }
.share-channel-card {
  padding: 18px; display: flex; flex-direction: column; gap: 4px;
  text-align: left; font-family: inherit; cursor: pointer;
}
.share-channel-name { font-size: 14.5px; font-weight: 600; color: var(--text); }
.share-channel-blurb { font-size: 12px; color: var(--text2); }

/* ======================================================== chips/labels === */
.chip { font-size: 11px; font-weight: 700; letter-spacing: 0.02em; padding: 3px 9px; border-radius: 999px; border: 1px solid var(--border); color: var(--text2); }
.chip.mcp { color: var(--brand-accent); border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.status-chip { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; padding: 3px 9px; border-radius: 999px; }
/* WEVA-W-235 round 3: W-221's signal tokens, as weva.css's .status-chip
   variants use them - the signal itself as the mark (the outline), its
   text variant for the words. No tinted fill: in light mode any wash of the
   signal under its own text drops below 4.5:1 on the ground (Green text
   4.86:1 on Lilac Mist bare, 4.43:1 under an 8% wash). */
.status-chip.open     { border: 1px solid var(--brand-warn);  color: var(--brand-warn-text); }   /* pending */
.status-chip.approved { border: 1px solid var(--brand-ok);    color: var(--brand-ok-text); }     /* allowed */
.status-chip.rejected { border: 1px solid var(--brand-error); color: var(--brand-error-text); }  /* denied  */
/* .status-chip.no-uppercase (WEVA-W-068/WEVA-233's opt-out for the
   member-role chip) removed by WEVA-W-072: that chip now carries the
   correct class, .role-tag, and never sets .status-chip at all - grepped
   app/ for any other caller of .no-uppercase, found none. See WEVA-233's
   own addendum in tests/defects.json. */

/* ======================================================== circle/skill detail === */
.detail-section { padding: 20px; margin-bottom: 16px; }
.detail-section h2 { margin: 0 0 4px; font-size: 17px; font-weight: 600; color: var(--text); }
.detail-section .sub { margin: 0 0 14px; font-size: 13px; color: var(--text2); }
.picture-upload { display: flex; align-items: center; gap: 14px; }
.picture-upload .preview {
  width: 56px; height: 56px; border-radius: var(--radius-md); flex-shrink: 0;
  background: var(--surface-2); display: flex; align-items: center; justify-content: center;
  font-weight: 700; color: var(--text);
}
.owner-constraint-note { font-size: 12px; color: var(--text2); margin: 6px 0 0; }

/* WEVA-W-069 (WEVA-234): app_circle_detail.html's #invite-result block
   hardcoded four style="..." HTML attributes, each violating the app's
   declared CSP (style-src 'self', no unsafe-inline) on every load. Classes
   replace them one for one. .invite-result-lead is scoped as
   .sub.invite-result-lead — same specificity as .detail-section .sub above
   (two classes) — and placed after it in the file so the cascade's
   source-order tiebreak gives it the override, without an ID selector or
   !important. */
.invite-result-panel { padding: 12px 16px; margin-top: 8px; }
.sub.invite-result-lead { margin: 0 0 8px; }
.invite-url-value { display: block; word-break: break-all; }
.invite-copy-status-inline { display: inline; }

/* WEVA-450 (W-130): a charter's purpose and rules are member-written text, so a long
   unbroken run (a URL, 180 characters of one kind) must wrap instead of pushing the page
   sideways at 375 px. Scoped to the two charter text blocks, not every .detail-section p. */
#charter-purpose-text, #charter-rules-text { overflow-wrap: anywhere; }

.item-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); margin-bottom: 6px; }
.item-row .name { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 600; color: var(--text); }
.item-row .role-tag { font-size: 11px; color: var(--text2); }

/* ======================================================== directory === */
.directory-layout { display: grid; grid-template-columns: 220px 1fr; gap: 24px; align-items: start; }
.category-sidebar { padding: 16px; position: sticky; top: 14px; }
.category-sidebar h3 { margin: 0 0 10px; font-size: 12.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text2); }
.category-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
.category-list button {
  width: 100%; text-align: left; font-family: inherit; font-size: 13.5px;
  padding: 8px 10px; border-radius: var(--radius-sm); border: none; cursor: pointer;
  background: transparent; color: var(--text2);
}
.category-list button:hover { color: var(--text); background: var(--surface-2); }
.category-list button.is-active { color: var(--text); background: var(--surface-2); font-weight: 700; }

.dir-toolbar { padding: 14px 16px; margin-bottom: 16px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.dir-search { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 200px; }
.dir-search input { flex: 1; border: none; background: transparent; font-family: inherit; font-size: 14px; color: var(--text); outline: none; }
.dir-search input::placeholder { color: var(--text2); }
.dir-toggle-row { display: flex; gap: 6px; }
.dir-toggle-row button { font-family: inherit; font-size: 12px; font-weight: 600; padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border); background: transparent; color: var(--text2); cursor: pointer; }
.dir-toggle-row button.is-active { border-color: var(--accent); color: var(--brand-accent); }
.dir-sort select {
  font-family: inherit; font-size: 12.5px; font-weight: 600; color: var(--text);
  background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 7px 10px;
}
.mocked-note { font-size: 11px; color: var(--text2); font-style: italic; }

.skill-card {
  padding: 16px; display: flex; flex-direction: column; gap: 8px;
}
.skill-card .head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.skill-card h4 { margin: 0; font-size: 15px; font-weight: 600; color: var(--text); }
.skill-card p.summary { margin: 0; font-size: 13px; color: var(--text2); }
.skill-card .foot { margin-top: auto; padding-top: 10px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--text2); }
.skill-card .price-tag { font-weight: 700; color: var(--brand-accent); }

/* ======================================================== requests / leaderboard === */
.history-toggle {
  display: flex; align-items: center; gap: 8px; width: 100%;
  font-family: inherit; font-size: 14px; font-weight: 600; color: var(--text);
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-md);
  padding: 12px 16px; cursor: pointer; text-align: left;
}
.history-toggle .caret { margin-left: auto; transition: transform 160ms ease; }
.history-toggle[aria-expanded="true"] .caret { transform: rotate(180deg); }
.history-body { display: none; margin-top: 8px; }
.history-body.is-open { display: block; }

.approve-duration { display: inline-flex; align-items: center; gap: 6px; margin-left: 8px; }
.approve-duration select { font-family: inherit; font-size: 12.5px; background: var(--surface-2); border: 1px solid var(--border); border-radius: var(--radius-sm); color: var(--text); padding: 4px 8px; }

.leaderboard { display: flex; flex-direction: column; gap: var(--gap-lg); }
.leader-row { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: var(--radius-sm); background: var(--surface-2); }
.leader-rank { width: 26px; text-align: center; font-weight: 800; color: var(--text2); font-size: 13px; }
.leader-row:nth-child(1) .leader-rank { color: var(--brand-accent); }
.leader-row .handle { flex: 1; font-size: 13.5px; font-weight: 600; color: var(--text); }
.leader-bar-track { width: 120px; height: 6px; border-radius: 999px; background: var(--border); overflow: hidden; flex-shrink: 0; }
.leader-bar-fill { height: 100%; background: var(--accent); border-radius: 999px; }
.leader-score { width: 34px; text-align: right; font-size: 12.5px; font-weight: 700; color: var(--text2); flex-shrink: 0; }

.plain-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: var(--gap-lg); }
.plain-list li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); font-size: 13.5px; flex-wrap: wrap; }

/* ======================================================== WEVA-W-050 chat === */
/* "Prototype view" mock panel rows (shell.js) — compact, fits the
   240px-min rail popover width. */
.viewmock-list { display: flex; flex-direction: column; gap: 4px; margin-bottom: 6px; }
.viewmock-row { padding: 6px 8px; }
.viewmock-row .name { font-size: 12px; }

/* The chat rail pictogram (chat.js) is a <button>, not an <a> like its
   .rail-link siblings — glass.css's own .rail-link rule assumes an anchor
   and doesn't reset button chrome. */
button.rail-link { border: none; background: transparent; font-family: inherit; padding: 0; }

/* Dashboard hero-slot entry point — same .featured-strip footprint, made
   clickable; repositioned above .hero-glow by chat.js (criterion 3). */
.chat-entry-composer { cursor: pointer; }
.chat-entry-composer:hover { background: color-mix(in srgb, var(--surface) 92%, var(--accent) 8%); }
.chat-entry-input { flex: 1; font-size: 13px; color: var(--text2); }

/* Chat window overlay — liquid-glass, reusing .glass (glass.css), never a
   second visual language (work order acceptance criterion 4). */
.chat-overlay {
  position: fixed; inset: 0; z-index: 500;
  display: flex; align-items: flex-end; justify-content: flex-end;
  padding: 24px; pointer-events: none;
}
.chat-overlay[hidden] { display: none; }
.chat-overlay-backdrop {
  position: absolute; inset: 0; background: rgba(0, 0, 0, 0.35);
  opacity: 0; pointer-events: none; transition: opacity 180ms ease;
}
.chat-overlay.is-open .chat-overlay-backdrop { opacity: 1; pointer-events: auto; }
.chat-window {
  position: relative; z-index: 1;
  width: min(420px, 92vw); height: min(640px, 82vh);
  display: flex; flex-direction: column;
  border-radius: var(--radius-lg); overflow: hidden;
  transform: translateY(16px) scale(0.98); opacity: 0; pointer-events: none;
  transition: transform 200ms ease, opacity 200ms ease;
}
.chat-overlay.is-open .chat-window { transform: translateY(0) scale(1); opacity: 1; pointer-events: auto; }
/* Fullscreen — three layers (research: docs/archive/validation_2026-09-25b.md
   §3). This class is the CSS viewport-fill fallback, applied alongside
   the real Fullscreen API attempt regardless of whether the browser grants
   it — the only reliable path on iPhone Safari, where requestFullscreen()
   silently does nothing for a non-<video> element. */
.chat-window.is-fullscreen {
  position: fixed; inset: 0; width: 100vw; height: 100dvh; border-radius: 0;
}
.chat-window-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; border-bottom: 1px solid var(--glass-border);
  flex-shrink: 0; cursor: pointer;
}
.chat-window-title { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; color: var(--text); }
.chat-header-actions { display: flex; gap: 6px; }
.chat-icon-btn {
  width: 34px; height: 34px; border-radius: 50%; border: none; background: transparent;
  color: var(--text2); display: flex; align-items: center; justify-content: center; cursor: pointer;
}
.chat-icon-btn svg { width: 18px; height: 18px; }
.chat-icon-btn:hover { background: var(--glass-shine); color: var(--text); }
.chat-icon-btn:disabled, .chat-icon-btn.is-unavailable { opacity: 0.4; cursor: not-allowed; }
.chat-icon-btn.is-listening { color: var(--brand-accent); animation: chat-mic-pulse 1s ease-in-out infinite; }
@keyframes chat-mic-pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }

.chat-thread { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 10px; background: var(--surface); }
.chat-msg { max-width: 88%; padding: 10px 12px; border-radius: var(--radius-md); font-size: 13.5px; line-height: 1.5; }
.chat-msg p { margin: 0 0 6px; }
.chat-msg p:last-child { margin-bottom: 0; }
.chat-msg-assistant { align-self: flex-start; background: var(--surface-2); color: var(--text); }
.chat-msg-user { align-self: flex-end; background: color-mix(in srgb, var(--accent) 24%, var(--surface-2)); color: var(--text); }

.chat-choice-card { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; }
.chat-choice-btn {
  font-family: inherit; font-size: 13px; font-weight: 600; text-align: left;
  padding: 8px 12px; border-radius: var(--radius-sm); border: 1px solid var(--border);
  background: var(--surface); color: var(--text); cursor: pointer;
}
.chat-choice-btn:hover { background: var(--glass-shine); }
.chat-choice-btn.is-chosen { border-color: var(--accent); color: var(--brand-accent); }
.chat-choice-btn:disabled { cursor: not-allowed; opacity: 0.7; }

.chat-attachments-tray { display: flex; flex-wrap: wrap; gap: 8px; padding: 8px 14px 0; }
.chat-attachment-chip { display: flex; align-items: center; gap: 6px; padding: 4px 8px 4px 4px; border-radius: 999px; background: var(--surface-2); font-size: 12px; color: var(--text); }
.chat-attachment-chip img { width: 22px; height: 22px; border-radius: 50%; object-fit: cover; display: block; }
.chat-attachment-remove { border: none; background: transparent; color: var(--text2); cursor: pointer; font-size: 14px; line-height: 1; padding: 0 2px; }
.chat-msg-attachment-chip { display: inline-block; margin-top: 6px; }

.chat-composer { padding: 10px 14px 14px; border-top: 1px solid var(--glass-border); flex-shrink: 0; }
.chat-composer-row { display: flex; align-items: center; gap: 6px; }
.chat-text-input { flex: 1; min-width: 0; font-family: inherit; font-size: 13.5px; color: var(--text); background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 9px 14px; }
.chat-mode-readout { margin: 6px 2px 0; font-size: 11px; color: var(--text2); }
.chat-plus-wrap { position: relative; }
/* Overrides glass.css's .rail-popover positioning (built for the side
   rail, anchored to its right edge) — this popover hangs off the
   composer's own "+" button instead, opening upward-left. */
.chat-plus-menu { display: none; position: absolute; right: auto; bottom: calc(100% + 8px); left: 0; min-width: 240px; max-width: 280px; }
.chat-plus-menu.is-open { display: block; }
.chat-mode-option[aria-pressed="true"] { color: var(--brand-accent); }
.chat-routing-toggle { display: flex; gap: 6px; padding: 2px 0; }
.chat-routing-btn { flex: 1; font-family: inherit; font-size: 12px; font-weight: 700; padding: 7px 8px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text2); cursor: pointer; text-align: center; }
.chat-routing-btn[aria-pressed="true"] { background: color-mix(in srgb, var(--accent) 22%, transparent); color: var(--text); border-color: var(--accent); }
.chat-routing-btn:disabled { opacity: 0.55; cursor: not-allowed; }
.chat-routing-soon { display: block; font-size: 9.5px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }

@media (max-width: 620px) {
  .chat-overlay { padding: 0; justify-content: center; }
  .chat-window { width: 100%; height: 82vh; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
  .chat-plus-menu { left: 0; right: 0; max-width: none; }
}

/* ======================================================== responsive === */
@media (max-width: 980px) {
  .hero-columns { grid-template-columns: 1fr; }
  .dash-grid { grid-template-columns: repeat(2, 1fr); }
  .discover-split { grid-template-columns: 1fr; }
  .directory-layout { grid-template-columns: 1fr; }
  .category-sidebar { position: static; }
}
@media (max-width: 620px) {
  .dash-grid { grid-template-columns: 1fr; }
  .circle-row {
    flex-wrap: wrap;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .circle-row .avatars { margin-right: 0; }
  .circle-row .stats { flex-wrap: wrap; gap: 10px; }
  .circle-row .chev { display: none; }
}
