/* ══════════════════════════════════════════════════════
   TASTE ENGINE — acid-pop visual system
   Vivid, chunky, full-bleed. Per-section accent is the
   voice (set at runtime by _applyTheme). Display = Unbounded,
   body = Hanken Grotesk. Motion: subtle & refined.
   ══════════════════════════════════════════════════════ */
@import url('https://fonts.googleapis.com/css2?family=Unbounded:wght@500;600;700;800&family=Hanken+Grotesk:wght@400;500;600;700&display=swap');

:root {
  /* Neutral hub palette (the landing). Instances override via _applyTheme. */
  --bg:          #0D0B11;
  --surface:     #16121C;
  --surface2:    #211A29;
  --border:      #4A3F58;
  --accent:      #FF5C9A;
  --accent2:     #2EC5FF;
  --on-accent:   #1A0710;
  --on-accent2:  #04121A;
  --accent-dim:  rgba(255,92,154,0.16);
  --accent-soft: rgba(255,92,154,0.42);
  --accent2-dim: rgba(46,197,255,0.16);
  --accent2-soft:rgba(46,197,255,0.42);
  --text:        #F4EEF3;
  --text-muted:  #BBB0C4;
  --text-dim:    #7E7389;
  --footer-bg:   rgba(13,11,17,0.86);

  /* ── Typography scale ── */
  --display: 'Unbounded', system-ui, sans-serif;
  --body: 'Hanken Grotesk', system-ui, sans-serif;
  --fz-xs:      12px;                     /* meta / tiny labels */
  --fz-sm:      13.5px;                   /* small UI text */
  --fz-body:    clamp(15px, 1.05vw, 17px);/* default body copy */
  --fz-body-lg: clamp(16px, 1.4vw, 19px); /* prominent body */
  --fz-lead:    clamp(17px, 1.6vw, 21px); /* hero subtitle / manifesto lead */
  --fw-body:      500;                    /* body weight — a touch bold for legibility on the textured bg */
  --fw-semibold:  600;
  --fw-bold:      700;
  --lh-body:      1.6;

  /* ── Space · radius · motion ── */
  --gutter: clamp(20px, 5vw, 96px);
  --radius: 0;        /* cards, panels, inputs, buttons, media tiles = square corners */
  --r-pill: 0;        /* fully geometric: corners square everywhere (circular avatars are the one exception) */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

/* Smooth colour wash from the neutral default into each section's accent.
   Transitions never fire on first paint, so this only animates the
   slate → domain change applied by the engine (_applyTheme). */
* {
  transition: background-color 0.45s var(--ease), border-color 0.45s var(--ease), color 0.45s var(--ease);
}

html { background: var(--bg); }

body {
  font-family: var(--body);
  font-size: var(--fz-body);
  font-weight: var(--fw-body);
  line-height: var(--lh-body);
  background: transparent;
  color: var(--text);
  min-height: 100vh;
  margin: 0;
  -webkit-font-smoothing: antialiased;
}

/* ── GENERATIVE BACKDROP (Quiet Currents) ── */
#te-backdrop { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 0; pointer-events: none; }
/* Second-hue wash so the surface is never one tone */
body::before {
  content: ''; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: radial-gradient(70% 55% at 88% -5%, var(--accent2-dim), transparent 65%);
}
/* Readability scrim: recesses the generative pattern so it reads as texture,
   never as foreground competing with copy. Sits above the backdrop, below content. */
body::after {
  content: ''; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: rgba(7, 5, 11, 0.22);
}
.te-screen, .te-hero, .te-domain-grid { position: relative; z-index: 1; }

/* Solid surface for reading blocks so text never sits on the raw backdrop. */
.te-panel { background: var(--surface); border: 1.5px solid var(--border); padding: clamp(20px, 3vw, 40px); }

/* ── TOP NAV ── */
.te-topnav {
  position: sticky; top: 0; z-index: 200;
  background: var(--footer-bg); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.te-topnav-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 14px var(--gutter);
}
.te-topnav-logo {
  font-family: var(--display); font-weight: 800; font-size: 16px;
  color: var(--text); text-decoration: none; white-space: nowrap; letter-spacing: -0.02em;
}
.te-topnav-logo:hover { color: var(--accent); }
.te-topnav-links { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.te-topnav-links a {
  font-family: var(--body); font-weight: 600; font-size: 13px; color: var(--text-muted);
  text-decoration: none; padding: 7px 12px; border-radius: 0;
  transition: color 0.15s, background 0.15s;
}
.te-topnav-links a:hover { color: var(--text); background: var(--surface2); }
.te-topnav-links a.on { color: var(--on-accent); background: var(--accent); }

/* ── SCREENS ── */
.te-screen { display: none; min-height: 100vh; padding: clamp(30px, 5vw, 64px) var(--gutter) 168px; }
.te-screen.active { display: block; animation: te-rise 0.55s var(--ease) both; }

@keyframes te-rise { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: none; } }

/* ── TYPE ── */
.te-eyebrow {
  display: inline-block; font-family: var(--body); font-weight: 700;
  font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--on-accent); background: var(--accent);
  padding: 5px 11px; border-radius: 0; margin-bottom: 18px;
}
.te-display {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(2.6rem, 7vw, 5.8rem); line-height: 0.96; letter-spacing: -0.035em;
  color: var(--text); margin-bottom: 16px; text-wrap: balance;
}
.te-display em { font-style: normal; color: var(--accent); }
.te-subtitle {
  font-size: clamp(19px, 2vw, 27px); font-weight: var(--fw-semibold); color: var(--text); line-height: 1.4;
  margin-bottom: 28px; max-width: 50ch;
}
.te-back {
  display: inline-flex; align-items: center; gap: 6px; font-family: var(--body);
  font-size: 13px; font-weight: 600; color: var(--accent); background: none;
  border: none; cursor: pointer; padding: 6px 0; margin-bottom: 22px;
}
.te-back:hover { gap: 10px; }

/* ── HOME CARDS ── */
.te-home-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr)); gap: 16px; }
.te-card {
  border: 1.5px solid var(--border); border-radius: var(--radius);
  padding: 22px; background: var(--surface); cursor: pointer;
  transition: border-color 0.18s, background 0.18s, box-shadow 0.18s, transform 0.14s var(--ease);
}
.te-card:hover {
  border-color: var(--accent); background: var(--surface2);
  transform: translate(-5px, -5px); box-shadow: 11px 11px 0 0 var(--accent);
}
.te-card.featured {
  border-color: var(--accent); grid-column: 1 / -1;
  background: linear-gradient(135deg, var(--accent-dim), var(--surface) 60%);
}
.te-card-top { display: flex; align-items: center; gap: 13px; margin-bottom: 8px; }
.te-card-icon {
  width: 42px; height: 42px; border-radius: 0; background: var(--accent);
  display: flex; align-items: center; justify-content: center; font-size: 19px; flex-shrink: 0;
}
.te-card-name { font-family: var(--display); font-weight: 700; font-size: 18px; color: var(--text); letter-spacing: -0.02em; }
.te-card-desc { font-size: var(--fz-body); font-weight: var(--fw-body); color: var(--text-muted); line-height: 1.5; }

/* ── SEARCH + FILTERS (one attached block) ── */
.te-search-block {
  border: 1.5px solid var(--border); background: var(--surface2);
  margin-bottom: 22px; transition: border-color 0.14s;
}
.te-search-block:focus-within { border-color: var(--accent); }

.te-search-wrap { position: relative; width: 100%; }
.te-search {
  width: 100%; background: transparent; border: none;
  border-radius: 0; padding: 15px 16px 15px 44px; font-size: 15px;
  color: var(--text); font-family: var(--body); outline: none;
}
.te-search::placeholder { color: var(--text-dim); }
.te-search-icon { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); color: var(--text-dim); font-size: 14px; pointer-events: none; }

/* lower compartment: toggle row, divided from the search field */
.te-picker-tools {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  margin: 0; padding: 11px 14px; border-top: 1.5px solid var(--border);
}
.te-filters-toggle {
  font-family: var(--body); font-size: 13px; font-weight: 600; color: var(--text-muted);
  background: var(--surface); border: 1.5px solid var(--border); border-radius: 0;
  padding: 7px 14px; cursor: pointer; transition: all 0.14s;
}
.te-filters-toggle:hover { color: var(--accent); border-color: var(--accent); }

/* expandable filter groups, inside the same block */
.te-filters { padding: 2px 16px 18px; }
.te-filter-group { margin-bottom: 14px; }
.te-filter-group:last-child { margin-bottom: 0; }
.te-filter-label { font-family: var(--body); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); margin-bottom: 7px; }
.te-filter-options { display: flex; flex-wrap: wrap; gap: 7px; }
.te-filter-chip {
  padding: 6px 13px; border-radius: 0; font-size: 12px; font-weight: 600;
  border: 1.5px solid var(--border); background: var(--surface); color: var(--text-muted);
  cursor: pointer; transition: all 0.14s; font-family: var(--body);
}
.te-filter-chip:hover { border-color: var(--text-dim); color: var(--text); }
.te-filter-chip.on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

/* ── ITEM LIST ── */
.te-item-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(248px, 100%), 1fr)); gap: 8px; }
.te-item {
  display: flex; align-items: center; gap: 13px; padding: 11px 14px;
  border-radius: 0; cursor: pointer; border: 1.5px solid var(--border);
  background: var(--surface); transition: background 0.14s, border-color 0.14s, transform 0.12s;
}
.te-item:hover { background: var(--surface2); transform: translateY(-2px); }
.te-item.on { background: var(--surface2); border-color: var(--accent); }
.te-item-text { flex: 1; min-width: 0; }
.te-item-name { font-size: 14px; font-weight: 600; color: var(--text); }
.te-item-meta { font-size: 11px; color: var(--text-dim); margin-top: 2px; }
.te-item-check {
  width: 24px; height: 24px; border-radius: 0; border: 1.5px solid var(--border);
  flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  font-size: 13px; color: transparent; transition: all 0.14s;
}
.te-item.on .te-item-check { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

/* ── AVATARS ── */
.te-avatar {
  border-radius: 50%; flex-shrink: 0; overflow: hidden;
  background-color: var(--surface2); border: 1.5px solid var(--border);
  background-size: cover; background-position: center top;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--display); color: var(--text-dim); font-weight: 700;
}
.te-avatar.has-img { border-color: var(--accent-soft); }
.te-avatar.has-img span { display: none; }
.te-avatar-sm { width: 40px; height: 40px; font-size: 12px; }
.te-avatar-md { width: 54px; height: 54px; font-size: 16px; }
/* Posters / cover art — portrait, rounded-rect instead of circle */
.te-avatar--poster { border-radius: 0; background-position: center; }
.te-avatar--poster.te-avatar-sm { width: 42px; height: 58px; }
.te-avatar--poster.te-avatar-md { width: 58px; height: 80px; }
.te-rec-name-wrap { display: flex; align-items: center; gap: 13px; min-width: 0; }
.te-rec-name-wrap .te-rec-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; }

/* ── ADD INLINE ── */
.te-add-inline { border: 1.5px dashed var(--border); border-radius: 0; padding: 16px 18px; margin-top: 14px; background: var(--surface); }
.te-add-inline-label { font-size: 13px; color: var(--text-muted); margin-bottom: 10px; }
.te-add-inline-label span { color: var(--accent); font-weight: 700; }
.te-add-btn {
  width: 100%; padding: 11px; background: var(--accent); border: none; border-radius: 0;
  color: var(--on-accent); font-size: 13px; font-weight: 700; font-family: var(--body);
  cursor: pointer; transition: transform 0.12s, filter 0.15s;
}
.te-add-btn:hover { transform: translateY(-1px); filter: brightness(1.08); }
.te-add-btn:disabled { opacity: 0.4; cursor: default; }

/* ── STICKY FOOTER (floating action bar) ── */
.te-footer {
  position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%);
  width: min(560px, calc(100vw - 32px));
  background: var(--footer-bg); backdrop-filter: blur(14px);
  padding: 16px 20px 18px; border: 1.5px solid var(--border);
  border-radius: 0; z-index: 100; box-shadow: 0 20px 60px -20px #000;
}
.te-progress { height: 4px; background: var(--surface2); border-radius: 0; margin-bottom: 13px; overflow: hidden; }
.te-progress-fill { height: 100%; background: linear-gradient(90deg, var(--accent), var(--accent2)); border-radius: 0; transition: width 0.4s var(--ease); }
.te-cta {
  width: 100%; padding: 15px; background: var(--accent); color: var(--on-accent);
  border: none; border-radius: 0; font-size: 15px; font-weight: 700; font-family: var(--display);
  letter-spacing: -0.01em; cursor: pointer; display: flex; align-items: center; justify-content: center;
  gap: 9px; transition: transform 0.12s, filter 0.15s;
}
.te-cta:hover:not(:disabled) { transform: translateY(-1px); filter: brightness(1.08); }
.te-cta:disabled { opacity: 0.32; cursor: default; }
.te-cta-badge { background: rgba(0,0,0,0.22); padding: 2px 9px; border-radius: 0; font-size: 11px; font-weight: 700; }
.te-footer-note { font-size: 12px; color: var(--text-dim); text-align: center; margin-top: 9px; }

/* ── TAGS ── */
.te-tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.te-tag { padding: 6px 13px; border-radius: 0; font-size: 12px; font-weight: 600; font-family: var(--body); }
.te-tag-lg { background: var(--accent); color: var(--on-accent); font-size: 13px; font-weight: 700; padding: 7px 16px; }
.te-tag-md { background: var(--accent2-dim); color: var(--accent2); border: 1.5px solid transparent; font-weight: 600; }
.te-tag-sm { background: transparent; color: var(--text-dim); font-size: 11px; border: 1.5px solid var(--border); }

/* ── RESULTS ── */
.te-divider { height: 1.5px; background: var(--border); margin: 28px 0; border: none; }
.te-result-body { font-size: var(--fz-body-lg); font-weight: var(--fw-body); line-height: 1.7; color: var(--text-muted); margin-bottom: 26px; max-width: 62ch; }
.te-result-body strong { color: var(--text); }
.te-picks-row { display: flex; flex-wrap: wrap; gap: 7px; }
.te-pick-pill { font-size: 12px; font-weight: 600; padding: 6px 12px; border-radius: 0; background: var(--accent); color: var(--on-accent); }

/* ── NUDGE ── */
.te-nudge { border: 1.5px solid var(--border); border-radius: 0; padding: 18px; background: var(--surface); margin-top: 30px; cursor: pointer; transition: border-color 0.18s, transform 0.14s, box-shadow 0.18s; max-width: 540px; }
.te-nudge:hover { border-color: var(--accent); transform: translate(-4px, -4px); box-shadow: 9px 9px 0 0 var(--accent); }
.te-nudge-label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-dim); margin-bottom: 6px; }
.te-nudge-title { font-family: var(--display); font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 3px; }
.te-nudge-sub { font-size: 12px; color: var(--text-muted); }
.te-nudge-arrow { float: right; color: var(--accent2); font-size: 20px; line-height: 1; }

/* ── RADAR ── */
.te-radar-wrap { display: flex; justify-content: center; margin: 10px 0 24px; }

/* ── REC CARDS ── */
.te-rec-empty { border: 1.5px dashed var(--border); background: var(--surface); padding: clamp(20px, 3vw, 32px); display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.te-rec-empty-title { font-family: var(--display); font-weight: 700; font-size: clamp(16px, 1.8vw, 20px); color: var(--text); letter-spacing: -0.01em; }
.te-rec-empty-sub { font-size: var(--fz-body); font-weight: var(--fw-body); color: var(--text-muted); line-height: 1.55; max-width: 52ch; }
.te-rec-retry { margin-top: 6px; font-family: var(--display); font-weight: 700; font-size: 14px; color: var(--on-accent); background: var(--accent); border: none; border-radius: 0; padding: 10px 18px; cursor: pointer; transition: filter 0.14s; }
.te-rec-retry:hover { filter: brightness(1.08); }
.te-rec-card { border: 1.5px solid var(--border); border-radius: 0; padding: 18px; background: var(--surface); transition: border-color 0.18s, transform 0.14s, box-shadow 0.18s; }
.te-rec-card:hover { border-color: var(--accent); transform: translate(-4px, -4px); box-shadow: 9px 9px 0 0 var(--accent); }
.te-rec-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 8px; gap: 10px; }
.te-rec-name { font-family: var(--display); font-weight: 700; font-size: 16px; color: var(--text); letter-spacing: -0.01em; }
.te-match-pill { font-family: var(--display); font-size: 12px; font-weight: 700; color: var(--on-accent); background: var(--accent); padding: 5px 11px; border-radius: 0; white-space: nowrap; flex-shrink: 0; }
.te-rec-reason { font-size: var(--fz-body); font-weight: var(--fw-body); color: var(--text-muted); line-height: 1.6; margin-bottom: 12px; }
.te-rec-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.te-rec-tag { font-size: 11px; font-weight: 500; padding: 4px 10px; border-radius: 0; background: var(--surface2); color: var(--text-muted); border: 1.5px solid var(--border); }
.te-rec-footer { display: flex; align-items: center; justify-content: flex-end; margin-top: 14px; padding-top: 12px; border-top: 1.5px solid var(--border); }
.te-already-btn { font-size: 12px; font-weight: 600; color: var(--text-muted); background: none; border: 1.5px solid var(--border); border-radius: 0; padding: 6px 13px; cursor: pointer; font-family: var(--body); transition: all 0.14s; }
.te-already-btn:hover { border-color: var(--accent); color: var(--accent); }
.te-already-btn.added { color: var(--on-accent); border-color: var(--accent); background: var(--accent); cursor: default; }

/* ── LOADING ── */
.te-loading { display: flex; align-items: center; justify-content: center; gap: 11px; padding: 44px; color: var(--text-muted); font-size: 14px; }
.te-spinner { width: 19px; height: 19px; border: 2.5px solid var(--border); border-top-color: var(--accent); border-radius: 50%; animation: te-spin 0.8s linear infinite; }
@keyframes te-spin { to { transform: rotate(360deg); } }

.te-hidden { display: none !important; }

/* ── EXPORT (save result) ── */
.te-export-btn {
  display: inline-flex; align-items: center; gap: 9px; margin-top: 26px;
  padding: 14px 24px; border: none; border-radius: 0;
  background: var(--accent2); color: var(--on-accent2);
  font-family: var(--display); font-weight: 700; font-size: 14px; letter-spacing: -0.01em;
  cursor: pointer; transition: transform 0.12s, filter 0.15s;
}
.te-export-btn:hover { transform: translateY(-2px); filter: brightness(1.08); }
.te-export-btn:active { transform: translateY(0); }

/* ── ADD SCREEN ── */
.te-add-input { width: 100%; max-width: 520px; background: var(--surface2); border: 1.5px solid var(--border); border-radius: 0; padding: 14px 16px; font-size: 16px; color: var(--text); font-family: var(--body); outline: none; margin-bottom: 12px; }
.te-add-input:focus { border-color: var(--accent); }
.te-add-input::placeholder { color: var(--text-dim); }
.te-outline-btn { display: inline-block; padding: 13px 22px; background: var(--accent); border: none; border-radius: 0; color: var(--on-accent); font-size: 14px; font-weight: 700; font-family: var(--body); cursor: pointer; transition: transform 0.12s, filter 0.15s; }
.te-outline-btn:hover { transform: translateY(-1px); filter: brightness(1.08); }
.te-outline-btn:disabled { opacity: 0.4; cursor: default; }

/* ── RECALC BAR ── */
.te-recalc-bar { background: var(--surface2); border: 1.5px solid var(--accent); border-radius: 0; padding: 12px 18px; margin-bottom: 22px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.te-recalc-label { font-size: 13px; color: var(--text-muted); }
.te-recalc-label span { color: var(--accent); font-weight: 700; }
.te-recalc-btn { font-family: var(--body); font-size: 13px; font-weight: 700; color: var(--on-accent); background: var(--accent); border: none; border-radius: 0; padding: 7px 15px; cursor: pointer; white-space: nowrap; transition: transform 0.12s, filter 0.15s; }
.te-recalc-btn:hover { transform: translateY(-1px); filter: brightness(1.08); }

/* ── REC CARD HEADER (mini radar) ── */
.te-rec-header { display: flex; flex-direction: column; gap: 12px; margin-bottom: 8px; }
.te-rec-header-text { flex: 1; min-width: 0; }
.te-mini-radar-wrap { display: flex; justify-content: center; padding: 4px 0; }
.te-mini-radar-wrap canvas { max-width: 100%; height: auto; }

/* ── SUMMARY ── */
.te-summary-section { margin-bottom: 32px; }
.te-summary-section-title {
  display: inline-block; font-family: var(--body); font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.09em; color: var(--text-muted);
  background: var(--surface); border: 1.5px solid var(--border); border-radius: 0;
  padding: 6px 13px; margin-bottom: 14px;
}
.te-sum-profile-title { font-family: var(--display); font-size: clamp(30px, 5vw, 50px); font-weight: 800; letter-spacing: -0.03em; line-height: 1.0; color: var(--text); margin-bottom: 16px; text-wrap: balance; }
.te-sum-profile-body { font-size: var(--fz-body-lg); font-weight: var(--fw-body); color: var(--text-muted); line-height: 1.7; max-width: 62ch; }

/* Profile block on a solid card so it reads over the geometric backdrop */
.te-profile-card {
  background: var(--surface); border: 1.5px solid var(--border); border-radius: 0;
  padding: clamp(22px, 3vw, 40px); box-shadow: 0 20px 60px -34px #000;
}

/* ── LAYOUT GRIDS (full-bleed, breakpoint-free) ── */
#te-rec-cards, #te-sum-recs { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr)); gap: 16px; align-items: start; }
#te-rec-cards .te-rec-card, #te-sum-recs .te-rec-card { margin-bottom: 0; }

/* ── PICKER-AS-HOME ── */
.te-picker-head { font-size: clamp(2.1rem, 5.2vw, 3.6rem); max-width: 18ch; margin-bottom: 14px; }
.te-picker-hint {
  font-family: var(--body); font-size: 15px; font-weight: 700; color: var(--text-muted);
  margin-bottom: 18px; text-shadow: 0 1px 10px var(--bg), 0 0 2px var(--bg);
}
.te-picker-hint span { color: var(--accent2); }

/* ── GEOMETRIC LOADER ── */
.te-geo-loader { position: relative; width: 56px; height: 56px; }
.te-geo-loader span {
  position: absolute; inset: 0; border: 3px solid var(--accent); border-radius: 0;
  animation: te-geo 1.6s var(--ease) infinite;
}
.te-geo-loader span:nth-child(2) { border-color: var(--accent2); animation-delay: -0.53s; }
.te-geo-loader span:nth-child(3) { border-color: var(--accent); opacity: 0.5; animation-delay: -1.06s; }
@keyframes te-geo {
  0%   { transform: rotate(0deg) scale(0.35); opacity: 0.15; }
  50%  { transform: rotate(180deg) scale(1); opacity: 1; }
  100% { transform: rotate(360deg) scale(0.35); opacity: 0.15; }
}

/* ── RESULT: solid radar card (no busy geometry underneath) ── */
.te-radar-card {
  background: var(--surface); border: 1.5px solid var(--border); border-radius: 0;
  padding: clamp(18px, 2.4vw, 32px); margin: 6px 0 8px;
  display: flex; flex-direction: column; align-items: center; box-shadow: 0 20px 60px -34px #000;
}
.te-radar-card .te-summary-section-title { align-self: flex-start; margin-bottom: 6px; }
.te-radar-card canvas { max-width: 100%; height: auto; display: block; }

/* radar sits on top; the "how to read it" key lives full-width below, in an expando */
.te-radar-canvas-wrap { width: 100%; max-width: 620px; display: flex; justify-content: center; }

.te-radar-explain { width: 100%; margin-top: 18px; border-top: 1.5px solid var(--border); padding-top: 14px; }
.te-radar-explain > summary {
  cursor: pointer; list-style: none; display: flex; align-items: center; gap: 9px;
  font-family: var(--display); font-weight: 700; letter-spacing: -0.01em;
  font-size: clamp(15px, 1.6vw, 18px); color: var(--text);
}
.te-radar-explain > summary::-webkit-details-marker { display: none; }
.te-radar-explain > summary::before {
  content: '▸'; color: var(--accent); display: inline-block; transition: transform 0.15s var(--ease);
}
.te-radar-explain[open] > summary::before { transform: rotate(90deg); }
.te-radar-explain-lead {
  font-size: var(--fz-body); font-weight: var(--fw-body); line-height: 1.55;
  color: var(--text-muted); margin: 12px 0 18px;
}

/* spectrum key: one full-width row per axis — named pole ↔ its opposite */
.te-radar-legend { width: 100%; display: flex; flex-direction: column; gap: 0; }
.te-radar-pole {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: clamp(10px, 3vw, 28px);
  font-size: clamp(13px, 1.3vw, 15px); padding: 11px 0; border-top: 1px solid var(--border);
}
.te-radar-pole:first-child { border-top: none; }
.te-pole-hi { text-align: left; font-family: var(--body); font-weight: 700; color: var(--accent); }
.te-pole-sep { justify-self: center; color: var(--text-dim); }
.te-pole-lo { text-align: right; font-family: var(--body); color: var(--text-muted); }

/* ── RESULT: recommendation "watch the vibe" link ── */
.te-rec-foot { margin-top: 14px; padding-top: 12px; border-top: 1.5px solid var(--border); }
.te-rec-watch {
  display: inline-flex; align-items: center; gap: 7px;
  font-family: var(--body); font-size: 13px; font-weight: 700; text-decoration: none;
  color: var(--on-accent2); background: var(--accent2); padding: 8px 14px; border-radius: 0;
  transition: transform 0.12s, filter 0.15s;
}
.te-rec-watch:hover { transform: translateY(-1px); filter: brightness(1.08); }

/* ── ENTRANCE STAGGER (motion design) ── */
@keyframes te-fade-up { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.te-home-grid > *, #te-rec-cards > *, #te-sum-recs > *, .te-tag-cloud > * {
  animation: te-fade-up 0.5s var(--ease) both;
}
.te-home-grid > :nth-child(1), #te-rec-cards > :nth-child(1), #te-sum-recs > :nth-child(1) { animation-delay: 0.06s; }
.te-home-grid > :nth-child(2), #te-rec-cards > :nth-child(2), #te-sum-recs > :nth-child(2) { animation-delay: 0.13s; }
.te-home-grid > :nth-child(3), #te-rec-cards > :nth-child(3), #te-sum-recs > :nth-child(3) { animation-delay: 0.20s; }
.te-home-grid > :nth-child(4), #te-rec-cards > :nth-child(4), #te-sum-recs > :nth-child(4) { animation-delay: 0.27s; }
.te-home-grid > :nth-child(5) { animation-delay: 0.34s; }
.te-home-grid > :nth-child(6) { animation-delay: 0.41s; }
.te-tag-cloud > :nth-child(1) { animation-delay: 0.05s; }
.te-tag-cloud > :nth-child(2) { animation-delay: 0.10s; }
.te-tag-cloud > :nth-child(3) { animation-delay: 0.15s; }
.te-tag-cloud > :nth-child(4) { animation-delay: 0.20s; }
.te-tag-cloud > :nth-child(5) { animation-delay: 0.25s; }
.te-tag-cloud > :nth-child(n+6) { animation-delay: 0.30s; }

/* ── REDUCED MOTION ── */
@media (prefers-reduced-motion: reduce) {
  * { transition-duration: 0.001ms !important; }
  .te-screen.active, .te-home-grid > *, #te-rec-cards > *, #te-sum-recs > *,
  .te-tag-cloud > *, .te-domain-grid { animation: none !important; }
}
