/* Not Fungible Avatars site: layout and sections, shared by every page (home, play, collection).
   Colours, font and sticker components come from brand.css (shared with the game). */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; color: #f3f6ff; font-family: var(--nfa-font);
  background: radial-gradient(120% 60% at 50% 0%, var(--nfa-deep) 0%, var(--nfa-night) 62%) fixed, var(--nfa-night);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; }
img, canvas { display: block; max-width: 100%; }
.wrap { width: min(1120px, 100% - 32px); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 3px solid var(--nfa-tram); outline-offset: 3px; }
.nfa-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; min-height: 48px; transition: transform .12s ease; }
.nfa-btn:hover { transform: rotate(-2deg) scale(1.04); }
.nfa-btn[aria-disabled="true"] { opacity: .55; pointer-events: none; }
.nfa-btn--ghost { background: transparent; color: #fff; border-color: #fff; box-shadow: 0 4px 0 rgba(255,255,255,.35); }

/* ---------- nav ---------- */
.nav { position: sticky; top: 0; z-index: 10; background: rgba(15,27,61,.94); border-bottom: 2px solid rgba(255,255,255,.08); }
.nav .wrap { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 900; letter-spacing: .04em; text-decoration: none; margin-right: auto; }
.brand img { width: 38px; height: 38px; border-radius: 50%; border: 2px solid var(--nfa-ink); }
.brand span b { color: var(--nfa-tram); }
.nav-links { display: flex; gap: 18px; font-weight: 800; font-size: 14px; }
.nav-links a { text-decoration: none; opacity: .85; }
.nav-links a:hover { opacity: 1; color: var(--nfa-tram); }
.nav .nfa-btn { min-height: 40px; padding: 8px 14px; font-size: 14px; }

/* ---------- hero ---------- */
.hero { padding: 44px 0 28px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 32px; align-items: center; }
.chip { display: inline-flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; font-weight: 900; font-size: 12px; letter-spacing: .08em; color: var(--nfa-ink); background: var(--nfa-tram); border: var(--nfa-outline); border-radius: 999px; padding: 6px 14px; box-shadow: 0 3px 0 var(--nfa-ink); }
.nfa-headline { margin: 18px 0 14px; }
.nfa-headline .l { display: inline-block; animation: hop .6s cubic-bezier(.3,1.6,.5,1) both; }
.nfa-headline .accent { color: var(--nfa-tram); }
@keyframes hop { from { transform: translateY(-40px) scale(.6) rotate(-8deg); opacity: 0; } to { transform: none; opacity: 1; } }
.lead { font-size: clamp(17px, 2.2vw, 21px); line-height: 1.45; max-width: 36ch; margin: 0 0 22px; color: #e7edff; }
.ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.stats { display: flex; flex-wrap: wrap; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.stats li { background: rgba(255,255,255,.08); border: 2px solid rgba(255,255,255,.14); border-radius: 14px; padding: 8px 12px; font-size: 13px; font-weight: 700; color: #c9d5f5; }
.stats b { display: block; font-size: 20px; color: #fff; }
.stage { position: relative; margin: 0; border: var(--nfa-outline); border-radius: 28px; overflow: hidden; box-shadow: 0 10px 0 var(--nfa-ink), 0 30px 80px rgba(31,95,191,.45); aspect-ratio: 1 / 1; background: var(--nfa-day); cursor: pointer; }
.stage canvas { width: 100%; height: 100%; }
.stage figcaption { position: absolute; left: 12px; bottom: 12px; font-size: 12px; font-weight: 900; letter-spacing: .06em; background: var(--nfa-ink); color: var(--nfa-tram); border-radius: 999px; padding: 6px 12px; pointer-events: none; }

/* ---------- event ticker ---------- */
.ticker { overflow: hidden; background: var(--nfa-tram); color: var(--nfa-ink); border-block: var(--nfa-outline); transform: rotate(-1.2deg); margin: 8px -10px; }
.ticker div { display: flex; width: max-content; animation: roll 28s linear infinite; }
.ticker span { font-weight: 900; font-size: 20px; letter-spacing: .06em; padding: 12px 18px; white-space: nowrap; }
.ticker span::after { content: "✦"; margin-left: 36px; color: var(--nfa-terracotta); }
@keyframes roll { to { transform: translateX(-50%); } }

/* ---------- sections ---------- */
section { padding: 64px 0; scroll-margin-top: 64px; }
.eyebrow { font-size: 13px; font-weight: 900; letter-spacing: .14em; color: var(--nfa-tram); margin: 0 0 8px; }
h2 { font-size: clamp(28px, 4.4vw, 48px); line-height: 1.05; margin: 0 0 14px; color: #fff; text-shadow: 3px 3px 0 var(--nfa-terracotta); }
.section-lead { font-size: 18px; line-height: 1.5; max-width: 62ch; color: #dfe7ff; margin: 0 0 28px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.card { background: var(--nfa-cream); color: var(--nfa-ink); border: var(--nfa-outline); border-radius: var(--nfa-radius); box-shadow: var(--nfa-sticker-shadow); padding: 20px; }
.card h3 { margin: 6px 0 8px; font-size: 22px; }
.card p { margin: 0; line-height: 1.45; }
.card ul { margin: 10px 0 0; padding-left: 18px; line-height: 1.5; }
.step-n { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: var(--nfa-outline); font-weight: 900; font-size: 18px; }
.s1 { background: var(--nfa-tram); } .s2 { background: var(--nfa-sky); } .s3 { background: var(--nfa-terracotta); color: #fff; }

/* pop-in on scroll */
.reveal { opacity: 0; transform: translateY(24px) scale(.96); transition: opacity .5s ease, transform .5s cubic-bezier(.3,1.5,.5,1); }
.reveal.in { opacity: 1; transform: none; }

/* tiles of live canvases (moments, people, props) */
.tiles-grid { display: grid; gap: 16px; }
.levels-grid { display: grid; gap: 12px; grid-template-columns: repeat(6, minmax(0, 1fr)); }
.level { margin: 0; min-width: 0; }
.level img { display: block; width: 100%; height: auto; border-radius: 12px; border: 3px solid var(--ink, #1b1d3a); image-rendering: pixelated; }
.level figcaption { margin-top: 8px; font-size: 13px; line-height: 1.35; }
.level figcaption b { display: block; }
@media (max-width: 980px) { .levels-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 560px) { .levels-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.moments { grid-template-columns: repeat(3, 1fr); }
.people { grid-template-columns: repeat(4, 1fr); gap: 14px; }
.props { grid-template-columns: repeat(3, 1fr); gap: 12px; }
.tile { background: var(--nfa-cream); color: var(--nfa-ink); border: var(--nfa-outline); border-radius: var(--nfa-radius); box-shadow: var(--nfa-sticker-shadow); overflow: hidden; text-align: center; padding: 0 0 12px; font: inherit; cursor: pointer; transition: transform .14s ease; width: 100%; }
.tile:hover, .tile:focus-visible { transform: translateY(-4px) rotate(-1deg); }
.tile canvas { width: 100%; aspect-ratio: 1 / 1; background: var(--nfa-day); border-bottom: var(--nfa-outline); }
.tile b { display: block; font-size: 18px; margin: 10px 0 2px; letter-spacing: .03em; }
.tile span { display: block; font-size: 14px; line-height: 1.35; padding: 0 12px; color: #4c5272; }
.tile .badge { display: inline-block; margin-top: 6px; font-size: 11px; font-style: normal; font-weight: 900; letter-spacing: .08em; border: 2px solid var(--nfa-ink); border-radius: 999px; padding: 1px 8px; color: var(--nfa-ink); }
.b0 { background: #cfe0ff; } .b1 { background: var(--nfa-tram); } .b2 { background: #ffd0c2; } .b3 { background: #c6f1d8; }
.hint { font-size: 13px; color: #b8c6ea; margin: 14px 0 0; }

/* traits */
.traits-layout { display: grid; grid-template-columns: 1fr 1.25fr; gap: 24px; align-items: start; }
.trait-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.trait-table th, .trait-table td { text-align: left; padding: 10px 6px; border-bottom: 2px dashed #eadbbd; vertical-align: top; }
.trait-table th { width: 30%; }
.trait-table td { color: #4c5272; line-height: 1.4; }
.rarities { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
.rar { margin: 0; border: var(--nfa-outline); border-radius: var(--nfa-radius); overflow: hidden; box-shadow: var(--nfa-sticker-shadow); background: var(--nfa-cream); color: var(--nfa-ink); }
.rar canvas { width: 100%; aspect-ratio: 1 / 1; }
.rar div { padding: 10px 12px; border-top: var(--nfa-outline); }
.rar b { display: inline-block; color: #fff; border: 2px solid var(--nfa-ink); border-radius: 999px; padding: 2px 10px; font-size: 13px; letter-spacing: .06em; }
.rar small { display: block; margin-top: 6px; font-size: 13px; color: #4c5272; line-height: 1.35; }
.r0 { background: var(--nfa-common); } .r1 { background: var(--nfa-rare); } .r2 { background: var(--nfa-epic); } .r3 { background: var(--nfa-legendary); color: var(--nfa-ink) !important; }

/* lisbon */
.azul { height: 44px; border-block: var(--nfa-outline); }
.azul canvas { width: 100%; height: 100%; }
.lisbon .wrap { display: grid; grid-template-columns: 1fr 1.1fr; gap: 28px; align-items: center; }
.wall-credit { display: inline-block; margin-top: 18px; font-weight: 900; font-size: 13px; letter-spacing: .06em; color: var(--nfa-tram); }

/* daily / share */
.daily { background: var(--nfa-day); color: var(--nfa-ink); border-block: var(--nfa-outline); }
.daily .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; }
.daily h2 { color: #fff; text-shadow: 3px 3px 0 var(--nfa-ink); -webkit-text-stroke: 1px var(--nfa-ink); }
.daily p { margin: 0; font-size: 18px; max-width: 52ch; line-height: 1.45; font-weight: 700; }
.tags { font-weight: 900; color: var(--nfa-azulejo); }

/* faq */
.faq { max-width: 820px; }
details { background: var(--nfa-cream); color: var(--nfa-ink); border: var(--nfa-outline); border-radius: 16px; box-shadow: 0 4px 0 var(--nfa-ink); padding: 0 18px; margin: 0 0 12px; }
summary { cursor: pointer; font-weight: 900; font-size: 17px; padding: 16px 0; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 22px; line-height: 1; }
details[open] summary::after { content: "–"; }
details p { margin: 0 0 16px; line-height: 1.5; color: #4c5272; }
code { background: #e7eeff; border-radius: 6px; padding: 1px 6px; font-size: .92em; overflow-wrap: anywhere; }

/* footer */
footer { padding: 36px 0 48px; border-top: 2px solid rgba(255,255,255,.08); font-size: 14px; color: #b8c6ea; }
footer .wrap { display: grid; gap: 14px; }
footer .row { display: flex; flex-wrap: wrap; gap: 10px 20px; align-items: center; }
footer a { font-weight: 800; color: #fff; }
.credit { color: var(--nfa-tram) !important; letter-spacing: .05em; }

/* DOM confetti for buttons */
.confetti { position: fixed; width: 9px; height: 6px; pointer-events: none; z-index: 50; border-radius: 2px; animation: fly .9s ease-out forwards; }
@keyframes fly { to { transform: translate(var(--dx), var(--dy)) rotate(var(--rot)); opacity: 0; } }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero .wrap, .traits-layout, .lisbon .wrap { grid-template-columns: 1fr; }
  .people { grid-template-columns: repeat(2, 1fr); }
  .moments, .grid-3 { grid-template-columns: 1fr 1fr; }
  .nav-links { gap: 12px; font-size: 13px; }
  .nav-links a.sec { display: none; }
  .stage { max-width: 520px; width: 100%; margin-inline: auto; }
}
@media (max-width: 560px) {
  .moments, .grid-3 { grid-template-columns: 1fr; }
  .brand span { display: none; }
  .nav .nfa-btn { display: none; }
  .tile span { font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ticker div, .nfa-headline .l { animation: none; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .tile, .nfa-btn { transition: none; }
}

/* ---------- pages: play, collection ---------- */
.nav-links a[aria-current="page"] { color: var(--nfa-tram); opacity: 1; }
.page-hero { padding: 40px 0 8px; }
.page-hero h1 { margin: 14px 0 12px; }
.play-layout { display: grid; grid-template-columns: minmax(300px, 420px) 1fr; gap: 32px; align-items: start; }
.game-frame { position: relative; border: var(--nfa-outline); border-radius: 28px; overflow: hidden; background: var(--nfa-night);
  box-shadow: 0 10px 0 var(--nfa-ink), 0 30px 80px rgba(31,95,191,.45); aspect-ratio: 9 / 16; width: 100%; }
.game-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.frame-links { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; font-size: 14px; }
.steps { counter-reset: step; list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.steps li { counter-increment: step; position: relative; padding: 16px 16px 16px 66px; }
.steps li::before { content: counter(step); position: absolute; left: 14px; top: 14px; display: grid; place-items: center; width: 38px; height: 38px;
  border-radius: 50%; border: var(--nfa-outline); background: var(--nfa-tram); color: var(--nfa-ink); font-weight: 900; }
.steps li b { display: block; font-size: 17px; margin-bottom: 4px; }
.equation { display: inline-block; margin: 6px 0 18px; padding: 10px 16px; border: var(--nfa-outline); border-radius: 999px; background: var(--nfa-cream);
  color: var(--nfa-ink); font-weight: 900; letter-spacing: .03em; box-shadow: 0 4px 0 var(--nfa-ink); }
.notice { border: 2px dashed rgba(255,255,255,.35); border-radius: 16px; padding: 14px 16px; color: #dfe7ff; line-height: 1.5; }
.tribute { max-width: 760px; }
.tribute p { font-size: 18px; line-height: 1.6; color: #e7edff; margin: 0 0 16px; }
.kpis { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 0; padding: 0; list-style: none; }
.kpis li { background: var(--nfa-cream); color: var(--nfa-ink); border: var(--nfa-outline); border-radius: var(--nfa-radius); box-shadow: var(--nfa-sticker-shadow); padding: 16px; }
.kpis b { display: block; font-size: clamp(22px, 3vw, 30px); line-height: 1.1; margin-bottom: 4px; overflow-wrap: anywhere; }
.kpis span { font-size: 13px; font-weight: 800; color: #4c5272; letter-spacing: .04em; }
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.gallery a { display: block; text-decoration: none; background: var(--nfa-cream); color: var(--nfa-ink); border: var(--nfa-outline); border-radius: 18px; overflow: hidden; box-shadow: var(--nfa-sticker-shadow); }
.gallery img { width: 100%; aspect-ratio: 1 / 1; object-fit: cover; background: var(--nfa-day); border-bottom: var(--nfa-outline); }
.gallery span { display: block; padding: 8px 10px; font-weight: 900; font-size: 14px; }
.gallery small { display: block; padding: 0 10px 10px; color: #4c5272; font-size: 12px; font-weight: 700; }
.updated { font-size: 13px; color: #b8c6ea; margin: 12px 0 0; }
@media (max-width: 900px) {
  .play-layout { grid-template-columns: 1fr; }
  .game-frame { max-width: 420px; margin-inline: auto; }
  .kpis, .gallery { grid-template-columns: 1fr 1fr; }
}

/* ---------- the home as one screen: the game's corridor behind glass, tabs instead of a long page ---------- */
html.app, html.app body { height: 100%; overflow: hidden; }
html.app { scroll-behavior: auto; }
#world { position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; object-fit: cover; object-position: 50% 44%; image-rendering: pixelated; z-index: 0; background: #070510; }
.veil { position: fixed; inset: 0; z-index: 1; pointer-events: none; background: radial-gradient(90% 80% at 50% 45%, rgba(8,5,20,.12), rgba(8,5,20,.66)); }
#door-flash { position: fixed; inset: 0; z-index: 30; background: #fff; opacity: 0; pointer-events: none; }
#door-flash.on { animation: door .42s ease-out; }
@keyframes door { 0% { opacity: 0; } 40% { opacity: .9; } 100% { opacity: 0; } }

.bar { position: fixed; top: 0; left: 0; right: 0; z-index: 20; display: flex; align-items: center; gap: 14px; height: 64px; padding: 0 16px; background: rgba(10,7,26,.9); border-bottom: 3px solid var(--nfa-ink); }
.bar .brand { margin-right: 8px; white-space: nowrap; font-size: 14px; }
.tabs { display: flex; gap: 6px; margin-right: auto; }
.tab { appearance: none; cursor: pointer; font: 900 14px/1 var(--nfa-font); letter-spacing: .03em; color: #e7edff; background: rgba(255,255,255,.08); border: 2px solid rgba(255,255,255,.16); border-radius: 999px; padding: 9px 14px; white-space: nowrap; transition: transform .12s ease; }
.tab:hover { transform: translateY(-2px); }
.tab[aria-selected="true"] { color: var(--nfa-ink); background: var(--nfa-tram); border-color: var(--nfa-ink); box-shadow: 0 3px 0 var(--nfa-ink); }
.bar-link { font-weight: 800; font-size: 14px; text-decoration: none; white-space: nowrap; }
.bar-link:hover { color: var(--nfa-tram); }
.bar-play { min-height: 40px; padding: 8px 14px; font-size: 14px; cursor: pointer; }

.panels { position: fixed; top: 64px; left: 0; right: 0; bottom: 26px; z-index: 10; overflow: hidden auto; overscroll-behavior: contain; padding: 14px 16px 10px; display: flex; flex-direction: column; }
.panel { flex: none; width: min(1040px, 100%); margin: auto; }
.panel > * { animation: enter .34s cubic-bezier(.2,1.2,.4,1); }   /* on the content, so the panel's own size stays exact for fitPanel */
.panel:focus { outline: none; }
.panel[hidden] { display: none; }
@keyframes enter { from { opacity: 0; transform: translateY(16px) scale(.97); } to { opacity: 1; transform: none; } }
.glass { background: rgba(12,8,28,.88); border: 3px solid var(--nfa-ink); border-radius: 22px; box-shadow: 0 8px 0 rgba(0,0,0,.45); padding: clamp(16px, 3vw, 28px); }
.panel h2 { font-size: clamp(22px, min(3.6vw, 5.2vh), 40px); }
.panel .section-lead { font-size: 16px; margin-bottom: 14px; }
.foot { position: fixed; left: 0; right: 0; bottom: 0; z-index: 15; height: 26px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 16px; overflow: hidden; white-space: nowrap; font-size: 11px; font-weight: 700; color: #cfd6f2; background: rgba(10,7,26,.8); }
.foot > * { overflow: hidden; text-overflow: ellipsis; }
html.app .nfa-music { bottom: 2px !important; right: 10px !important; padding: 1px 10px !important; min-height: 0 !important; font-size: 11px !important; box-shadow: none !important; border-width: 2px !important; }
html.app .foot { padding-right: 130px; justify-content: flex-start; }
.foot .credit { letter-spacing: .04em; }

.hero-card { max-width: 640px; }
.hero-card .lead { max-width: none; }
.doors { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 18px; }
.doors button { appearance: none; cursor: pointer; text-align: left; color: #fff; font-family: var(--nfa-font); background: rgba(255,255,255,.07); border: 2px solid rgba(255,255,255,.18); border-radius: 14px; padding: 10px 12px; transition: transform .12s ease, background .12s ease; }
.doors button:hover { transform: translateY(-3px); background: rgba(255,207,31,.18); }
.doors b { display: block; font-size: 15px; }
.doors span { display: block; font-size: 12px; opacity: .85; margin-top: 2px; }
#home .ticker { margin: 16px -8px 0; border-radius: 6px; }

.level-rail { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
.level-rail button { appearance: none; cursor: pointer; position: relative; padding: 0; color: #fff; background: #120a22; border: 3px solid var(--nfa-ink); border-radius: 12px; overflow: hidden; font-family: var(--nfa-font); transition: transform .14s ease; }
.level-rail button:hover { transform: translateY(-3px); }
.level-rail button[aria-selected="true"] { border-color: var(--nfa-tram); box-shadow: 0 0 0 2px var(--nfa-tram); transform: translateY(-3px); }
.level-rail img { width: 100%; height: clamp(54px, 13vh, 118px); object-fit: cover; object-position: 50% 34%; image-rendering: pixelated; }
.level-rail b { position: absolute; left: 6px; top: 4px; font-size: 20px; text-shadow: 2px 2px 0 var(--nfa-ink); }
.level-rail span { display: block; padding: 5px 4px; font-size: 11px; font-weight: 800; line-height: 1.15; min-height: 36px; }
.level-detail { display: grid; grid-template-columns: 1.3fr 1fr; gap: 14px; margin-bottom: 14px; }
.level-detail h3 { margin: 0 0 6px; font-size: 22px; color: var(--nfa-tram); }
.level-detail p { margin: 0 0 6px; line-height: 1.4; }
.dm { margin: 0; align-self: start; background: #1a1526; border: 2px solid #b3262e; border-radius: 12px; padding: 10px 12px; font-size: 16px; font-weight: 700; }
.dm small { display: block; margin-bottom: 4px; font-size: 11px; color: #ff9aa6; letter-spacing: .04em; }
.glass-details, .panel details { margin-top: 10px; }
.glass-details { background: rgba(255,246,229,.97); }

.subtabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.sub { appearance: none; cursor: pointer; font: 800 13px/1 var(--nfa-font); color: #e7edff; background: rgba(255,255,255,.08); border: 2px solid rgba(255,255,255,.16); border-radius: 10px; padding: 8px 12px; }
.sub[aria-selected="true"] { color: var(--nfa-ink); background: #fff6e5; border-color: var(--nfa-ink); }
.subpane[hidden] { display: none; }
.joke { min-height: 22px; margin: 0 0 12px; font-weight: 700; color: #ffe9a0; }
.panel .tiles-grid.people { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 8px; }
.panel .tiles-grid.moments { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.panel .tiles-grid.props { grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 8px; }
.panel .rarities { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.panel .tile { padding-bottom: 8px; }
.panel .tile b { margin-top: 6px; }
.panel .tile b { font-size: 15px; }
.panel .tile span { font-size: 12px; }

.agents-layout { display: grid; grid-template-columns: 1fr 1.15fr; gap: 14px; }
.agents-lead { margin: 0 0 12px; font-size: 14px; line-height: 1.4; color: #dfe7ff; }
.agent-picker { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; margin-bottom: 12px; }
.agent-picker button { appearance: none; cursor: pointer; padding: 0; background: rgba(255,255,255,.08); border: 2px solid rgba(255,255,255,.18); border-radius: 10px; overflow: hidden; }
.agent-picker button[aria-checked="true"] { border-color: var(--nfa-tram); background: rgba(255,207,31,.2); }
.agent-picker canvas { width: 100%; aspect-ratio: 1; }
.agent-who { display: grid; grid-template-columns: 150px 1fr; gap: 12px; align-items: start; }
.agent-who canvas { width: 150px; height: 150px; border-radius: 14px; border: 3px solid var(--nfa-ink); }
.agent-who h3 { margin: 0 0 4px; font-size: 20px; color: var(--nfa-tram); }
.agent-who p { margin: 0 0 6px; font-size: 14px; line-height: 1.35; }
.agent-traits { color: #b8c6ea; font-weight: 700; }
.agent-json { font-size: 12px; font-weight: 800; color: #7fc8ff; }
.chat-log { height: clamp(110px, 26vh, 220px); overflow-y: auto; display: flex; flex-direction: column; gap: 6px; padding: 8px; background: rgba(0,0,0,.28); border-radius: 12px; }
.chat-log p { margin: 0; max-width: 84%; padding: 7px 11px; border-radius: 12px; font-size: 14px; line-height: 1.35; overflow-wrap: anywhere; }
.chat-log .them { align-self: flex-start; background: #2a2144; }
.chat-log .me { align-self: flex-end; background: var(--nfa-tram); color: var(--nfa-ink); font-weight: 700; }
.chat-form { display: flex; gap: 8px; margin-top: 8px; }
.chat-form input { flex: 1; min-width: 0; min-height: 48px; padding: 0 12px; font: 700 15px var(--nfa-font); color: var(--nfa-ink); background: #fff6e5; border: 3px solid var(--nfa-ink); border-radius: 12px; }
.fine { font-size: 12px; color: #b8c6ea; margin: 8px 0 0; line-height: 1.4; }
.agent-result { margin-top: 12px; }
.agent-result p { margin: 0 0 6px; }
.agent-result .big { font-size: 19px; font-weight: 900; color: var(--nfa-tram); }
.agent-result .grid { font-size: 22px; letter-spacing: 2px; }
.agent-how { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.agent-how li { background: rgba(255,255,255,.07); border-radius: 10px; padding: 9px 11px; font-size: 14px; line-height: 1.35; }
.agent-how b { display: block; color: var(--nfa-tram); }
.agent-how em { display: block; margin-top: 3px; font-style: normal; font-size: 12px; color: #9ff0c0; }
.linklike { appearance: none; background: none; border: 0; padding: 0; font: inherit; font-weight: 800; color: inherit; text-decoration: underline; cursor: pointer; }

.play-dialog { width: min(440px, 100vw); height: min(860px, 100dvh); max-width: 100vw; max-height: 100dvh; padding: 0; border: 3px solid var(--nfa-ink); border-radius: 18px; background: #070510; overflow: hidden; }
.play-dialog::backdrop { background: rgba(4,2,12,.82); }
#play-host, #play-host iframe { width: 100%; height: 100%; border: 0; display: block; }
.play-close { position: absolute; right: 8px; top: 8px; z-index: 2; width: 40px; height: 40px; cursor: pointer; font-size: 18px; font-weight: 900; color: #fff; background: rgba(12,8,28,.85); border: 2px solid #fff; border-radius: 50%; }
.toast { position: fixed; left: 50%; bottom: 76px; z-index: 40; transform: translate(-50%, 16px); max-width: min(92vw, 520px); padding: 10px 16px; font-weight: 800; color: #fff; background: #1a1526; border: 2px solid var(--nfa-tram); border-radius: 12px; opacity: 0; pointer-events: none; transition: opacity .18s ease, transform .18s ease; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 900px) {
  .bar-link { display: none; }
  .bar { background: rgba(10,7,26,.94); -webkit-backdrop-filter: none; backdrop-filter: none; }   /* a blur would trap the fixed tabs inside the bar */
  .tabs { position: fixed; left: 0; right: 0; bottom: 0; height: 60px; margin: 0; padding: 8px 10px; overflow-x: auto; background: rgba(10,7,26,.94); border-top: 3px solid var(--nfa-ink); scrollbar-width: none; }
  .tabs::-webkit-scrollbar { display: none; }
  .bar .brand { margin-right: auto; }
  .panels { bottom: 82px; padding: 10px 10px 6px; }
  .foot { bottom: 60px; height: 22px; padding: 0 10px; font-size: 10px; }
  .foot > span { display: none; }
  html.app .nfa-music { top: 15px !important; bottom: auto !important; right: 122px !important; padding: 4px 10px !important; }
  html.app .foot { padding-right: 10px; }
  .agents-layout { grid-template-columns: 1fr; }
  .level-rail { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 5px; }
  .level-rail span { display: none; }
  .level-rail b { font-size: 16px; }
  .level-detail { grid-template-columns: 1fr; gap: 8px; }
  .panel .tiles-grid.people { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
  .panel .tiles-grid.moments { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .panel .tiles-grid.props { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 6px; }
  .panel .rarities { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .panel .tile span { display: none; }
  .panel .tile b { font-size: 12px; margin: 4px 2px 0; }
  .panel .tiles-grid.people .badge { display: none; }
  .panel .tile .badge { font-size: 9px; padding: 0 5px; margin-top: 3px; }
  .panel .tile { padding-bottom: 5px; border-radius: 12px; }
  .agents-lead { display: none; }
  .agent-who { grid-template-columns: 110px 1fr; }
  .agent-who canvas { width: 110px; height: 110px; }
  .play-dialog { width: 100vw; height: 100dvh; border: 0; border-radius: 0; }
}
@media (max-width: 480px) {
  .bar .brand span { font-size: 12px; }
  .doors { gap: 6px; }
  .doors button { padding: 8px; }
  .doors span { display: none; }
  .doors b { font-size: 14px; }
  .stats { gap: 6px; margin-top: 16px; }
  .stats li { flex: 1 1 0; min-width: 0; padding: 6px 7px; font-size: 10px; line-height: 1.2; }
  .stats b { font-size: 16px; }
}
@media (prefers-reduced-motion: reduce) {
  .panel > *, #door-flash.on { animation: none; }
}

/* the letters hop one by one: a word must never break between them */
.nfa-headline .accent { display: inline-block; white-space: nowrap; }

/* ---------- one screen, like an app: every tab fits, nothing scrolls (index.html fitPanel shrinks what is still too tall) ---------- */
.panel .subtabs { margin-bottom: 10px; }
.game-more p { margin: 6px 0 12px; font-size: 17px; line-height: 1.5; color: #e7edff; max-width: 62ch; }
.panel .ctas { margin-top: 4px; }
.panel details { padding: 0 14px; margin: 0 0 8px; }
.panel summary { padding: 11px 0; font-size: 16px; }
.panel details p { margin-bottom: 12px; font-size: 15px; line-height: 1.45; }
.panel .trait-table { font-size: 14px; }
.panel .trait-table th, .panel .trait-table td { padding: 6px 6px; }
.traits-lead { margin: 0 0 8px; font-size: 15px; line-height: 1.45; color: #dfe7ff; }
#mint .trait-table { background: var(--nfa-cream); border-radius: 14px; overflow: hidden; }
#mint .trait-table th { padding-left: 12px; color: var(--nfa-ink); }
.panel .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.panel .kpis li { padding: 12px 14px; }
.panel .gallery { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 10px; }
.panel .gallery span { font-size: 13px; padding: 6px 8px; }
.panel .gallery small { padding: 0 8px 8px; }
.sales-title { margin: 14px 0 8px; }
.col-wall img { display: block; width: 100%; height: auto; max-height: calc(100dvh - 330px); object-fit: contain; image-rendering: pixelated; border-radius: 14px; }
.col-wall .fine { margin-top: 8px; }
#collection .notice { margin: 0; }
.faq-credit { display: none; margin-top: 4px; }
@media (min-width: 901px) {
  .panel .acc:not([hidden]) { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 10px; align-items: start; }
  .panel .acc > p { grid-column: 1 / -1; }
}
@media (max-height: 760px) {
  .panels { padding-top: 10px; }
  .glass { padding: 16px 20px; }
  .panel .nfa-headline { font-size: clamp(30px, 8vh, 60px); margin: 12px 0 10px; }
  .panel .lead { font-size: 17px; margin-bottom: 14px; }
  .stats { margin-top: 14px; }
  .doors { margin-top: 12px; }
  #home .ticker { display: none; }
}
@media (max-width: 900px) {
  .panel .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .panel .kpis li { padding: 8px 10px; }
  .panel .kpis b { font-size: 20px; }
  .panel .gallery { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .col-wall img { max-height: calc(100dvh - 360px); }
  .game-more p { font-size: 16px; }
  .panel .subtabs { gap: 5px; }
  .panel .sub { padding: 7px 9px; font-size: 12px; }
  .panel h2 { font-size: clamp(22px, 6.4vw, 30px); }
  .panel .section-lead { font-size: 14px; line-height: 1.4; }
  .panel summary { font-size: 15px; padding: 10px 0; }
  .panel details p { font-size: 14px; }
  .panel .trait-table { font-size: 12.5px; }
  .chat-log { height: clamp(100px, 22vh, 200px); }
  .agent-who { grid-template-columns: 84px 1fr; }
  .agent-who canvas { width: 84px; height: 84px; }
  .agent-picker { margin-bottom: 8px; }
  .agent-how { gap: 5px; }
  .agent-how li { padding: 6px 9px; font-size: 12.5px; line-height: 1.3; }
  .agent-how em { font-size: 11px; margin-top: 1px; }
  .agent-who p { font-size: 13px; }
  .agent-chat .fine { font-size: 11px; }
}
/* short phones (SE, small Android): thinner bars, no credit strip (it is in the FAQ), every pixel for the content */
@media (max-width: 900px) and (max-height: 720px) {
  .bar { height: 52px; padding: 0 10px; }
  .bar .brand img { width: 32px; height: 32px; }
  .bar-play { min-height: 34px; padding: 6px 12px; }
  html.app .nfa-music { top: 12px !important; }
  .tabs { height: 50px; padding: 6px 8px; }
  .tab { padding: 8px 12px; font-size: 13px; }
  .foot { display: none; }
  .faq-credit { display: block; }
  .panels { top: 52px; bottom: 50px; padding: 8px 8px 6px; }
  .panel .eyebrow { display: none; }
  .glass { padding: 12px 14px; border-radius: 18px; }
  .panel h2 { font-size: 22px; margin-bottom: 8px; }
  .joke { margin-bottom: 8px; }
  .panel .rarities { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
  .panel .rar small { font-size: 11px; }
  .panel .rar div { padding: 6px 7px; }
  .panel .rar b { font-size: 10px; padding: 1px 6px; }
}
/* a phone on its side: one thin bar with the tabs in it, and the wide layouts of the desktop */
@media (orientation: landscape) and (max-height: 500px) {
  .bar { height: 44px; gap: 8px; padding: 0 8px; }
  .bar .brand { margin-right: 0; }
  .bar .brand span { display: none; }
  .bar .brand img { width: 30px; height: 30px; }
  .tabs { position: static; flex: 1; min-width: 0; height: auto; margin: 0; padding: 0; overflow-x: auto; background: none; border: 0; gap: 4px; }
  .tab { padding: 6px 10px; font-size: 12px; }
  .bar-play { min-height: 30px; padding: 4px 10px; font-size: 12px; }
  html.app .nfa-music { display: none !important; }
  .foot { display: none; }
  .faq-credit { display: block; }
  .panels { top: 44px; bottom: 0; padding: 6px 10px; }
  .panel { width: min(1040px, 100%); }
  .panel .eyebrow { display: none; }
  .glass { padding: 10px 14px; border-radius: 16px; }
  .panel h2 { font-size: 20px; margin-bottom: 6px; }
  .panel .section-lead { font-size: 13px; margin-bottom: 8px; }
  .panel .nfa-headline { font-size: 34px; margin: 8px 0 6px; }
  .panel .lead { font-size: 14px; margin-bottom: 8px; }
  .hero-card { max-width: none; }
  .stats { margin-top: 8px; }
  .doors { margin-top: 8px; }
  .doors span { display: none; }
  #home .ticker { display: none; }
  .level-rail { grid-template-columns: repeat(6, minmax(0, 1fr)); margin-bottom: 8px; }
  .level-rail img { height: 54px; }
  .level-rail span { display: none; }
  .level-detail { grid-template-columns: 1.3fr 1fr; }
  .panel .tiles-grid.people { grid-template-columns: repeat(8, minmax(0, 1fr)); }
  .panel .tiles-grid.moments { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .panel .tiles-grid.props { grid-template-columns: repeat(9, minmax(0, 1fr)); }
  .panel .rarities { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .panel .tile span { display: none; }
  .panel .acc:not([hidden]) { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 8px; align-items: start; }
  .panel .acc > p { grid-column: 1 / -1; }
  .panel .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .panel .gallery { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .col-wall img { max-height: calc(100dvh - 170px); }
  .agents-layout { grid-template-columns: 1fr 1.15fr; }
  .agents-lead { display: none; }
  .chat-log { height: 120px; }
}
