/* ECHIVO /oradea — finish.css · OWNER: FX (V11 art direction, "Oradea, la ora de aur").
   The finish layer = the LIGHT of the pages: the lit window in every card, the breath behind the stars, the lamp (Ask),
   the sentence illumination of AI answers, the three lights that go out, the lamplight behind each heading, the night
   that deepens at the foot. It decorates hub.css / venue.css / assistant.css; it never lays out or colours content.
   Rules: transform/opacity only on anything that moves; nothing loops on content; phones (html.lp) get static paint;
   reduced motion = final state. Everything motion-related is gated by html.ox-fin (added by finish.js), so a page without
   the script is simply the page without the finish. Hooks: see /home/claude/ws/notes/FX.md §6. */

/* ============================================================ 0 · TOKENS */
.ox { --ox-gold-rgb: 245, 200, 130; --ox-amber-rgb: 212, 165, 96; --ox-terra-rgb: 255, 138, 91; }

/* ============================================================ 1 · THE LIT WINDOW (hub cards)
   hub.css paints the warm light inside every card (.ox-card__link::before, at --x/--y). The finish makes it follow the
   hand: finish.js writes --x/--y on the link, one CSS-var write per pointermove, fine pointers only. Nothing to paint here.
   If a card ever carries a photo, it is a window at night: dimmed at rest, lit when the light reaches it (opacity veil). */
.ox .ox-card__media { position: relative; isolation: isolate; }
.ox .ox-card__media:has(img)::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none;
  background: linear-gradient(180deg, rgba(5,7,13,.28) 0%, rgba(5,7,13,.42) 55%, rgba(5,7,13,.72) 100%);
  opacity: 1; transition: opacity .6s var(--ease-out); }
.ox-fin .ox .ox-card.is-fx .ox-card__media::after { opacity: .78; }
.ox-fin:not(.lp) .ox .ox-card:hover .ox-card__media::after, .ox .ox-card:focus-within .ox-card__media::after { opacity: .45; }
.ox .ox-card__media img { filter: saturate(.85); }
/* ============================================================ 2 · THE BREATH BEHIND THE STARS (venue hero + hub cards)
   When the stars settle, one gold breath: a radial glow behind the star row, opacity 0 → .55 → 0 over 1.4 s, once.
   Then the disclosure fades in under it (the breath is what makes the disclosure read as proof, not as small print). */
.ox .ox-stars { position: relative; isolation: isolate; }
.ox .ox-stars::before { content: ""; position: absolute; left: 50%; top: 50%; width: 140%; height: 320%; z-index: -1; border-radius: 50%; pointer-events: none;
  translate: -50% -50%; opacity: 0; transform: scale(.7);
  background: radial-gradient(closest-side, rgba(var(--ox-gold-rgb), .42), rgba(var(--ox-gold-rgb), .12) 48%, rgba(var(--ox-gold-rgb), 0) 72%); }
.ox-fin .ox .ox-stars.is-breathed::before { animation: ox-breath 1.4s var(--ease-out) 1 both; }
@keyframes ox-breath { 0% { opacity: 0; transform: scale(.7); } 35% { opacity: .55; transform: scale(1.05); } 100% { opacity: 0; transform: scale(1.3); } }
.reduced-motion .ox .ox-stars::before, .lp .ox .ox-card .ox-stars::before { animation: none !important; } /* hub cards: hero row only on phones */
.ox .ox-disclosure { color: var(--text-3); font-size: var(--t-small); }
.ox .ox-disclosure a { color: var(--text-2); text-decoration: underline; text-decoration-color: rgba(255,255,255,.22); text-underline-offset: .18em; transition: color .25s, text-decoration-color .25s; }
.ox .ox-disclosure a:hover { color: var(--gold); text-decoration-color: rgba(var(--ox-gold-rgb), .6); }

/* ============================================================ 3 · THE READING: lamplight behind headings */
/* confidence dots: venue.css paints .ox-aspect__label::before; if W3 renders a .ox-aspect__conf element instead, same colours */
.ox .ox-aspect__conf { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: rgba(var(--ox-gold-rgb), .95); box-shadow: 0 0 10px rgba(var(--ox-gold-rgb), .45); }
.ox .ox-aspect[data-conf="med"] .ox-aspect__conf { background: rgba(var(--ox-amber-rgb), .95); box-shadow: 0 0 8px rgba(var(--ox-amber-rgb), .3); }
.ox .ox-aspect[data-conf="low"] .ox-aspect__conf { background: transparent; box-shadow: inset 0 0 0 1.5px rgba(var(--ox-amber-rgb), .7); }
/* lamplight: a wide, soft warm glow rises behind each section heading as it arrives (opacity once; static on phones) */
.ox .ox-h2, .ox .ox-list__title { position: relative; }
.ox .ox-h2::before, .ox .ox-list__title::before { content: ""; position: absolute; left: -8%; top: -60%; width: 60%; max-width: 520px; height: 220%; z-index: -1; pointer-events: none; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(var(--ox-gold-rgb), .11), rgba(var(--ox-gold-rgb), .04) 50%, rgba(var(--ox-gold-rgb), 0) 75%);
  opacity: 0; transition: opacity 1.8s var(--ease-out) .1s; }
.ox-fin .ox .is-lamp::before, .ox-fin.lp .ox .ox-h2::before, .ox-fin.lp .ox .ox-list__title::before, .reduced-motion .ox .ox-h2::before, .reduced-motion .ox .ox-list__title::before, .no-js .ox .ox-h2::before { opacity: 1; }

/* ============================================================ 4 · THE LAMP (the Ask button)
   assistant.css paints the FAB's warm core (.oxa-fab__core) and venue-ask.css its own; the finish adds only the moments:
   ONE bloom when the page settles (finish.js adds .is-lit ~1.2 s after load) and the press (the ring tightens, 120 ms).
   The venue/hero submit buttons get a pointer core on hover so every "send" feels like turning a lamp up. */
.ox [data-ox-assistant-open] { position: relative; isolation: isolate; }
.ox [data-ox-assistant-open]::after { content: ""; position: absolute; inset: -8px; z-index: -2; border-radius: inherit; pointer-events: none; opacity: 0; transform: scale(.85);
  background: radial-gradient(closest-side, rgba(var(--ox-gold-rgb), .5), rgba(var(--ox-gold-rgb), .14) 55%, rgba(var(--ox-gold-rgb), 0)); }
.ox-fin:not(.reduced-motion) [data-ox-assistant-open].is-lit::after { animation: ox-halo 1.6s var(--ease-out) 1 both; }
@keyframes ox-halo { 0% { opacity: 0; transform: scale(.85); } 30% { opacity: .9; transform: scale(1.1); } 100% { opacity: 0; transform: scale(1.45); } }
.ox [data-ox-assistant-open]:active::after { animation: none; opacity: .5; transform: scale(.96); transition: transform .12s, opacity .12s; }
.ox [data-ox-ask-submit] { position: relative; isolation: isolate; }
.ox [data-ox-ask-submit]::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
  background: radial-gradient(70% 70% at 50% 40%, rgba(255,255,255,.28), rgba(255,255,255,.06) 55%, rgba(255,255,255,0) 100%);
  opacity: 0; transition: opacity .35s var(--ease-out); }
.ox [data-ox-ask-submit]:hover::before, .ox [data-ox-ask-submit]:focus-visible::before { opacity: 1; }
.ox [data-ox-ask-submit] > * { position: relative; z-index: 1; }

/* ============================================================ 5 · THE ANSWER ILLUMINATES, SENTENCE BY SENTENCE
   finish.js wraps each sentence of a new [data-ox-ask-answer] in <span class="ox-s">; they illuminate top→bottom, 80 ms
   apart (opacity + 6 px rise). Reduced motion / phones below the lite tier: the whole answer fades once. */
.ox-fin:not(.reduced-motion) .ox-s { display: inline; opacity: 0; transform: translateY(6px); transition: opacity .55s var(--ease-out), transform .55s var(--ease-out); transition-delay: var(--d, 0ms); }
.ox-fin .ox-s.is-on { opacity: 1; transform: none; }
/* venues named in a city answer are gold links; the underline draws left→right on hover */
.ox [data-ox-ask-answer] a { color: var(--gold); text-decoration: none; background-image: linear-gradient(var(--gold), var(--gold)); background-repeat: no-repeat; background-size: 0% 1px; background-position: 0 100%; transition: background-size .35s var(--ease-out); padding-bottom: 1px; }
.ox [data-ox-ask-answer] a:hover, .ox [data-ox-ask-answer] a:focus-visible { background-size: 100% 1px; }
/* the "răspuns recent" pill is quiet */
.ox [data-ox-ask-cached] { color: var(--text-3); font-size: .75rem; letter-spacing: .04em; }

/* ============================================================ 6 · THREE LIGHTS GO OUT (the question budget)
   [data-ox-ask-remaining] holds three <i>: gold dots with a soft bloom. When a question is spent (.is-off), the dot
   dims to an outline with a 500 ms fade; the LAST one to go out breathes once before it dims. The ritual, not an error. */
.ox [data-ox-ask-remaining] { display: inline-flex; gap: 7px; align-items: center; vertical-align: middle; }
.ox [data-ox-ask-remaining] i { display: inline-block; width: 8px; height: 8px; border-radius: 50%; position: relative;
  background: rgba(var(--ox-gold-rgb), .95); box-shadow: 0 0 10px rgba(var(--ox-gold-rgb), .55), 0 0 2px rgba(var(--ox-gold-rgb), .9);
  transition: background .5s var(--ease-out), box-shadow .5s var(--ease-out), transform .4s var(--ease-spring); }
.ox [data-ox-ask-remaining] i.is-off { background: transparent; box-shadow: inset 0 0 0 1.5px rgba(var(--ox-gold-rgb), .35); }
.ox-fin:not(.reduced-motion) [data-ox-ask-remaining] i.is-last { animation: ox-last-light .9s var(--ease-out) 1 both; }
@keyframes ox-last-light { 0% { transform: scale(1); } 40% { transform: scale(1.8); } 100% { transform: scale(1); } }
/* after the third answer: the app line arrives in place (opacity + rise once) */
.ox-fin:not(.reduced-motion) [data-ox-ask-cta] { animation: ox-rise .8s var(--ease-out) 1 both; }
@keyframes ox-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }

/* ============================================================ 7 · THE WAIT (three dots breathing once per cycle)
   W3/W4 render [data-ox-ask-pending]; the finish gives it three dots that rise in sequence, 3 cycles max in CSS,
   then still. Not infinite: an answer or an error always replaces it within the 12 s client timeout. */
.ox [data-ox-ask-pending] { display: inline-flex; gap: 6px; align-items: center; min-height: 1.5em; }
.ox [data-ox-ask-pending]::before, .ox [data-ox-ask-pending]::after, .ox [data-ox-ask-pending] > i { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: rgba(var(--ox-gold-rgb), .85); opacity: .35; }
.ox-fin:not(.reduced-motion) [data-ox-ask-pending]::before { animation: ox-wait 1.2s var(--ease-out) 6 both; }
.ox-fin:not(.reduced-motion) [data-ox-ask-pending] > i { animation: ox-wait 1.2s var(--ease-out) .15s 6 both; }
.ox-fin:not(.reduced-motion) [data-ox-ask-pending]::after { animation: ox-wait 1.2s var(--ease-out) .3s 6 both; }
@keyframes ox-wait { 0%, 100% { opacity: .35; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-4px); } }

/* ============================================================ 8 · PRIMARY CTA FINISH (every .btn-gold on /oradea)
   Specular that follows the pointer on the gold (desktop) and one bloom when the button arrives (every tier but reduced). */
.ox .btn-gold { position: relative; isolation: isolate; }
.ox .btn-gold::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .35s var(--ease-out);
  background: radial-gradient(150px circle at var(--fx, 50%) var(--fy, 35%), rgba(255,255,255,.46), rgba(255,255,255,.12) 38%, rgba(255,255,255,0) 64%); }
.ox-fin:not(.lp) .ox .btn-gold:hover::before, .ox .btn-gold:focus-visible::before { opacity: 1; }
.ox .btn-gold::after { content: ""; position: absolute; inset: -10px; z-index: -2; border-radius: inherit; pointer-events: none; opacity: 0; transform: scale(.82);
  background: radial-gradient(closest-side, rgba(var(--ox-gold-rgb), .6), rgba(var(--ox-gold-rgb), .18) 55%, rgba(var(--ox-gold-rgb), 0)); }
.ox-fin:not(.reduced-motion) .ox .btn-gold.is-lit::after { animation: ox-halo 1.7s var(--ease-out) 1 both; }
.ox .btn-gold:active::after { animation: none; opacity: .5; transform: scale(.96); transition: transform .12s, opacity .12s; }
.ox .btn-gold > * { position: relative; z-index: 1; }
.ox .nav .btn-gold::after { display: none; } /* fixed element: no bloom */

/* ============================================================ 9 · THE HERO QUESTION CYCLES (hub search placeholder)
   finish.js crossfades a ghost label over the empty hub search input through three real questions, 4 s apart; the input's
   own placeholder is emptied while the ghost is active and restored on focus/typing. W4 may opt out with data-ox-cycle="own". */
.ox .ox-ask__ghost { position: absolute; left: var(--ox-ghost-x, 1.25em); top: var(--ox-ghost-y, 50%); translate: 0 -50%; pointer-events: none; color: var(--text-3); white-space: nowrap; overflow: hidden; max-width: calc(100% - var(--ox-ghost-x, 1.25em) - 3.5em); text-overflow: ellipsis;
  opacity: 0; transition: opacity .7s var(--ease-out); }
.ox .ox-ask__ghost.is-on { opacity: 1; }
.reduced-motion .ox .ox-ask__ghost { transition: none; }

/* ============================================================ 10 · THE NIGHT DEEPENS AT THE FOOT
   The one gradient allowed on these pages: night → midnight under the last section, so the page ends like a street does,
   under a warmer sky. Painted once. finish.js appends .ox-foot before </main> if W1 hasn't. */
.ox .ox-foot { position: relative; height: clamp(140px, 22vh, 260px); margin-top: -1px; pointer-events: none;
  background: linear-gradient(180deg, rgba(20,29,51,0) 0%, rgba(20,29,51,.75) 60%, #141d33 100%); }
.ox .ox-foot::after { content: ""; position: absolute; left: 50%; bottom: 0; width: 70%; height: 55%; translate: -50% 0; border-radius: 50% 50% 0 0;
  background: radial-gradient(60% 100% at 50% 100%, rgba(var(--ox-gold-rgb), .16), rgba(var(--ox-gold-rgb), .05) 50%, rgba(var(--ox-gold-rgb), 0) 80%); }

/* ============================================================ 11 · DISCIPLINE */
.ox :focus-visible { outline: 2px solid rgba(var(--ox-gold-rgb), .85); outline-offset: 3px; border-radius: 6px; }
.ox .ox-stars__num, .ox .ox-aspect__score, .ox .ox-card__aspects b { font-variant-numeric: tabular-nums; }
/* phones: the one-shots that are cheap stay (the hero breath, the last light, the wait, the CTA line); the halos go */
.lp .ox .btn-gold.is-lit::after, .lp [data-ox-assistant-open].is-lit::after { animation: none !important; }
@media (prefers-reduced-motion: reduce) {
  .ox *::before, .ox *::after, .ox .ox-s { animation: none !important; transition: none !important; opacity: 1; transform: none; }
  .ox .ox-stars::before, .ox .btn-gold::after, .ox [data-ox-assistant-open]::after, .ox .btn-gold::before { opacity: 0; }
  .ox .ox-h2::before, .ox .ox-list__title::before { opacity: 1; }
}
