/* ================================================================
   FOCUS-END.CSS — the screen after a chosen concept or graph area ends
   (../practice/focus-end.js, Seth 2026-10-14): learned → keep studying it /
   the AI's next pick / build on it; not ready → a prerequisite / keep at it;
   an area → keep at it / an area you haven't practised.

   A CROSSROADS, IN THE LIST'S VOICE. The head is the concept's name in the
   home's numeral face (--xp-display, Instrument Serif) at display size, its
   meter the "Or choose a concept" list's (concept-choice.css .cc-bar) drawn
   thicker. Below it the ways forward stand side by side as cards — the one
   the model favours (`--lead`) washed and ruled in the accent — and every
   option inside is a ledger row with its own meter, so strength is read the
   same way everywhere on the screen. Tone (data-tone) only tints: cyan for
   learned (`up`), amber for not ready (`wall`), muted for out of questions.

   Token-first, no hex (styles/watch.py).
   ================================================================ */

.fe-screen {
  --fe-tone: var(--xp-to);
  background:
    radial-gradient(120% 70% at 0% 0%, color-mix(in srgb, var(--fe-tone) 13%, transparent) 0%, transparent 55%),
    radial-gradient(80% 60% at 100% 100%, color-mix(in srgb, var(--accent-2) 9%, transparent) 0%, transparent 60%),
    var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: 22px;
  box-shadow: 0 40px 120px -40px rgb(0 0 0 / 0.75);
  color: var(--text);
  max-height: min(92vh, 900px);
  max-width: none;
  overflow: auto;
  padding: 38px 42px 26px;
  width: min(1080px, calc(100vw - 32px));
}
.fe-screen[data-tone="wall"] { --fe-tone: var(--warn); }
.fe-screen[data-tone="out"] { --fe-tone: var(--muted); }
.fe-screen::backdrop {
  backdrop-filter: blur(3px);
  background: rgb(0 0 0 / 0.55);
}
.fe-screen[open] { animation: fe-in 0.36s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
@keyframes fe-in {
  from { opacity: 0; transform: translateY(10px) scale(0.985); }
  to { opacity: 1; transform: none; }
}

/* ---- the head --------------------------------------------------- */
.fe-top { max-width: 760px; }
.fe-eyebrow {
  align-items: center;
  color: var(--fe-tone);
  display: flex;
  font-size: 11px;
  font-weight: 700;
  gap: 10px;
  letter-spacing: 0.14em;
  margin: 0 0 14px;
  text-transform: uppercase;
}
.fe-eyebrow::before {
  background: var(--fe-tone);
  border-radius: 50%;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--fe-tone) 22%, transparent);
  content: "";
  height: 7px;
  width: 7px;
}
.fe-head {
  color: var(--white);
  font-family: var(--xp-display, Georgia, serif);
  font-size: clamp(30px, 4.4vw, 46px);
  font-weight: 400;
  letter-spacing: -0.015em;
  line-height: 1.06;
  margin: 0 0 20px;
  text-wrap: balance;
}
.fe-focus {
  background: linear-gradient(90deg, var(--accent-2) 0%, var(--fe-tone) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  font-style: italic;
}
.fe-lede {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
  margin: 12px 0 0;
}

/* ---- the meter (the list's .cc-bar, with its figure) --------------- */
.fe-meter {
  align-items: center;
  column-gap: 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-top: 10px;
}
.fe-bar {
  background: rgb(var(--tint-rgb) / calc(0.06 * var(--tint-k)));
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  display: block;
  height: 6px;
  overflow: hidden;
}
.fe-bar-fill {
  background: linear-gradient(90deg, var(--accent-2) 0%, var(--xp-to) 100%);
  display: block;
  height: 100%;
  transition: width 0.6s cubic-bezier(0.2, 0.7, 0.2, 1);
  width: var(--fe-pct, 0%);
}
.fe-pct {
  color: var(--muted);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
  min-width: 4ch;
  text-align: right;
}
.fe-meter.is-learned .fe-pct { color: var(--ok); }
.fe-meter--big { max-width: 560px; }
.fe-meter--big .fe-bar { height: 10px; }
.fe-meter--big .fe-pct {
  color: var(--white);
  font-family: var(--xp-display, Georgia, serif);
  font-size: 24px;
  font-variant-numeric: lining-nums tabular-nums;
  line-height: 1;
}
.fe-meter--big.is-learned .fe-pct { color: var(--ok); }

/* ---- the ways forward ------------------------------------------- */
.fe-cards {
  align-items: start;
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 30px;
}
.fe-cards--2 { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }
.fe-card {
  animation: fe-rise 0.42s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  background: rgb(var(--tint-rgb) / calc(0.025 * var(--tint-k)));
  border: 1px solid var(--border);
  border-radius: 16px;
  display: flex;
  flex-direction: column;
  min-width: 0;
  padding: 18px 16px 12px;
  position: relative;
}
.fe-card:nth-child(2) { animation-delay: 70ms; }
.fe-card:nth-child(3) { animation-delay: 140ms; }
@keyframes fe-rise {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}
/* The way the model favours: washed and ruled in the accent. */
.fe-card--lead {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fe-tone) 9%, transparent) 0%, transparent 70%),
    rgb(var(--tint-rgb) / calc(0.035 * var(--tint-k)));
  border-color: color-mix(in srgb, var(--fe-tone) 40%, var(--border));
}
.fe-card--lead::before {
  background: linear-gradient(90deg, var(--accent-2), var(--fe-tone));
  border-radius: 16px 16px 0 0;
  content: "";
  height: 2px;
  left: -1px;
  position: absolute;
  right: -1px;
  top: -1px;
}
.fe-verb {
  color: var(--white);
  font-size: 15px;
  font-weight: 650;
  letter-spacing: -0.005em;
  margin: 0;
  padding: 0 6px;
}
.fe-why {
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.45;
  margin: 4px 0 10px;
  padding: 0 6px;
}
.fe-opts {
  display: flex;
  flex-direction: column;
  margin: 0 -4px;
}
.fe-empty {
  color: var(--muted-dim);
  font-size: 12.5px;
  font-style: italic;
  margin: 6px 10px 10px;
}

/* An option: a ledger row (concept-choice.css .cc-row), the meter under it. */
.fe-opt {
  animation: fe-rise 0.36s cubic-bezier(0.2, 0.7, 0.2, 1) both;
  animation-delay: calc(160ms + var(--fe-i, 0) * 45ms);
  background: transparent;
  border: 0;
  border-radius: 11px;
  color: var(--text);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  font: inherit;
  padding: 11px 10px 12px;
  position: relative;
  text-align: left;
  transition: background 0.14s ease, transform 0.14s ease;
  width: 100%;
}
.fe-opt + .fe-opt::before {
  border-top: 1px solid var(--border);
  content: "";
  left: 10px;
  position: absolute;
  right: 10px;
  top: 0;
}
.fe-opt:hover { background: rgb(var(--tint-rgb) / calc(0.06 * var(--tint-k))); }
.fe-opt:hover .fe-name::after { opacity: 1; transform: none; }
.fe-opt:focus-visible { outline: 2px solid var(--xp-to); outline-offset: -2px; }
.fe-opt:disabled { cursor: progress; opacity: 0.55; }
.fe-opt.is-going { opacity: 1; }
.fe-flag {
  color: var(--xp-to);
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1;
  margin-bottom: 6px;
  text-transform: uppercase;
}
.fe-screen[data-tone="wall"] .fe-flag { color: var(--accent-text); }
.fe-name {
  color: var(--white);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.3;
  text-wrap: pretty;
}
.fe-name::after {
  color: var(--fe-tone);
  content: " →";
  display: inline-block;
  opacity: 0;
  transform: translateX(-4px);
  transition: opacity 0.14s ease, transform 0.14s ease;
}
.fe-sub {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
  margin-top: 3px;
}

/* ---- the foot ---------------------------------------------------- */
.fe-foot {
  align-items: center;
  display: flex;
  gap: 16px;
  justify-content: space-between;
  margin-top: 22px;
}
.fe-error {
  color: var(--warn);
  font-size: 12.5px;
  margin: 0;
}
.fe-home {
  background: transparent;
  border: 1px solid var(--border-strong);
  border-radius: 999px;
  color: var(--muted);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  margin-left: auto;
  padding: 8px 16px;
  transition: color 0.14s ease, border-color 0.14s ease;
}
.fe-home:hover { border-color: var(--muted); color: var(--white); }
.fe-home:focus-visible { outline: 2px solid var(--xp-to); outline-offset: 2px; }

/* ---- phone ------------------------------------------------------- */
@media (max-width: 760px) {
  .fe-screen {
    border-radius: 18px;
    max-height: calc(100dvh - 24px);
    padding: 26px 16px 18px;
  }
  .fe-cards,
  .fe-cards--2 { grid-template-columns: minmax(0, 1fr); }
  .fe-card--lead { order: -1; }   /* stacked, the favoured way comes first */
  .fe-foot { flex-direction: column-reverse; align-items: stretch; }
  .fe-home { margin-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .fe-screen[open],
  .fe-card,
  .fe-opt { animation: none; }
  .fe-bar-fill { transition: none; }
}

/* ---- the Knowledge Graph panel's way in (../concept-graph/kg-panel.js) ---- */
.kgp-area-go {
  background: linear-gradient(90deg, var(--accent-2), var(--xp-to));
  border: 0;
  border-radius: 999px;
  color: var(--bg, black);
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
  margin: 14px 0 0;
  padding: 9px 18px;
  transition: filter 0.14s ease, transform 0.14s ease;
}
.kgp-area-go:hover { filter: brightness(1.08); transform: translateY(-1px); }
.kgp-area-go:focus-visible { outline: 2px solid var(--xp-to); outline-offset: 2px; }
.kgp-area-go:disabled { cursor: progress; opacity: 0.6; transform: none; }
.kgp-area-note {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
  margin: 6px 0 4px;
}
.kgp-say {
  color: var(--warn);
  font-size: 12.5px;
  margin: 0 0 10px;
}
