/* Persona. App shell (sidebar + top bar) like a launchpad; white cards, ink type, one iridescent accent. */
:root {
  --bg: #ffffff; --canvas: #f7f6f3; --well: #f3f1ec; --ink: #0c0c0e; --ink-2: #2d2d33; --muted: #70707a; --faint: #a9a9b2; --line: #eceae5; --line-2: #dedbd3;
  --holo: linear-gradient(120deg, #ffb199 0%, #ff5fa2 28%, #a56bff 58%, #5aa9ff 82%, #6ff0d0 100%);
  --green: #12a05a; --green-soft: #e7f6ee; --red: #ff3b5c;
  --font: "Geist", Inter, system-ui, -apple-system, sans-serif;
  --shadow: 0 1px 2px rgba(12,12,14,.04), 0 18px 44px -24px rgba(12,12,14,.28);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 15px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; color: inherit; }
img { display: block; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.04em; }
.num { font-variant-numeric: tabular-nums; }
.page { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 28px; }
.holo-text { background: var(--holo); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ── shell ── */
.side { position: fixed; inset: 0 auto 0 0; width: 248px; background: var(--canvas); border-right: 1px solid var(--line); display: flex; flex-direction: column; padding: 20px 14px 14px; z-index: 40; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 19px; letter-spacing: -0.04em; padding: 0 8px; }
.brand svg { width: 30px; height: 30px; flex: none; }
.side nav { margin-top: 30px; flex: 1; display: grid; align-content: start; gap: 2px; }
.side nav a, .drawer a { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 12px; border-radius: 12px; font-size: 14.5px; color: var(--ink-2); transition: background .15s, color .15s; }
.side nav a:hover { background: var(--well); color: var(--ink); }
.side nav a.on { background: #fff; color: var(--ink); font-weight: 600; box-shadow: 0 1px 2px rgba(12,12,14,.06); outline: 1px solid var(--line); }
.side nav a svg, .drawer a svg { width: 18px; height: 18px; color: var(--muted); flex: none; }
.side nav a.on svg { color: var(--ink); }
.side nav .n { margin-left: auto; font-size: 12px; font-weight: 600; color: var(--muted); }
.side .acct { border: 1px solid var(--line); background: #fff; border-radius: 18px; padding: 12px; display: flex; align-items: center; gap: 10px; }
.side .acct svg { width: 34px; height: 34px; }
.side .acct b { display: block; font-size: 13.5px; font-weight: 600; }
.side .acct small { font-size: 12px; color: var(--muted); }
.main { margin-left: 248px; min-height: 100vh; display: flex; flex-direction: column; }
.top { position: sticky; top: 0; z-index: 30; height: 64px; display: flex; align-items: center; gap: 12px; padding: 0 24px; background: rgba(255,255,255,.86); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.top.scrolled { border-color: var(--line); }
.top .brand { display: none; padding: 0; }
.search { flex: 1; max-width: 440px; margin: 0 auto; position: relative; }
.search input { width: 100%; height: 42px; border: 1px solid var(--line); background: var(--canvas); border-radius: 14px; padding: 0 14px 0 40px; outline: 0; font-size: 14px; }
.search input:focus { background: #fff; border-color: var(--line-2); box-shadow: 0 0 0 4px rgba(12,12,14,.04); }
.search > svg { position: absolute; left: 13px; top: 12px; width: 18px; height: 18px; color: var(--faint); }
.search .results { position: absolute; left: 0; right: 0; top: 48px; background: #fff; border: 1px solid var(--line); border-radius: 16px; box-shadow: var(--shadow); padding: 6px; display: none; max-height: 360px; overflow: auto; }
.search .results.show { display: block; }
.search .results a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 10px; font-size: 14px; }
.search .results a:hover { background: var(--canvas); }
.search .results small { color: var(--muted); margin-left: auto; }
.search .results .none { padding: 12px; color: var(--muted); font-size: 13.5px; }
.top .right { display: flex; align-items: center; gap: 8px; }
.pill { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 12px; border-radius: 99px; border: 1px solid var(--line); background: #fff; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.pill i { width: 7px; height: 7px; border-radius: 7px; background: var(--green); box-shadow: 0 0 0 3px var(--green-soft); }
.menu-btn { display: none; width: 38px; height: 38px; border-radius: 99px; border: 0; background: none; cursor: pointer; place-items: center; }
.drawer { display: none; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 44px; padding: 0 20px; border-radius: 14px; background: var(--ink); color: #fff; font-weight: 600; font-size: 14.5px; border: 0; cursor: pointer; white-space: nowrap; transition: transform .15s, background .2s; }
.btn:hover { background: #26262c; }
.btn:active { transform: scale(.97); }
.btn.lg { height: 52px; padding: 0 26px; font-size: 16px; }
.btn.sm { height: 36px; padding: 0 15px; font-size: 13.5px; border-radius: 12px; }
.btn.ghost { background: #fff; color: var(--ink); border: 1px solid var(--line-2); }
.btn.ghost:hover { background: var(--well); }
.btn[disabled] { opacity: .45; pointer-events: none; }

/* ── bits used everywhere ── */
.av { position: relative; display: inline-block; border-radius: 50%; flex: none; }
.av img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; object-position: 50% 22%; background: var(--well); }
.av.ring { padding: 3px; background: var(--holo); }
.av.ring img { border: 3px solid var(--bg); }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 99px; background: var(--well); font-size: 12.5px; font-weight: 500; color: var(--ink-2); white-space: nowrap; }
.chip.ai { background: #111114; color: #fff; }
.chip.ai::before { content: ""; width: 7px; height: 7px; border-radius: 7px; background: var(--holo); }
.chip.coin { background: #fff; border: 1px solid var(--line-2); font-weight: 600; }
.chip.ok { background: var(--green-soft); color: var(--green); }
.eyebrow { font-size: 13.5px; font-weight: 600; color: var(--muted); display: inline-flex; align-items: center; gap: 8px; }
.eyebrow::before { content: ""; width: 18px; height: 3px; border-radius: 3px; background: var(--holo); }
.h2 { font-size: clamp(26px, 3vw, 36px); line-height: 1.05; }
.sub { color: var(--muted); font-size: 16px; margin: 10px 0 0; max-width: 560px; }
.empty { text-align: center; color: var(--muted); padding: 60px 20px; }
.reveal { opacity: 0; transform: translateY(14px); transition: opacity .6s ease, transform .6s cubic-bezier(.2,.8,.2,1); }
.reveal.in { opacity: 1; transform: none; }
.tabs { display: inline-flex; gap: 2px; padding: 3px; background: var(--canvas); border: 1px solid var(--line); border-radius: 14px; }
.tabs button { height: 34px; padding: 0 13px; border: 0; background: none; border-radius: 11px; font-size: 13.5px; font-weight: 500; color: var(--muted); cursor: pointer; }
.tabs button.on { background: #fff; color: var(--ink); box-shadow: 0 1px 2px rgba(12,12,14,.08); }

/* ── coin cards: the heart of the site ── */
.coins { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.coin { display: block; background: #fff; border: 1px solid var(--line); border-radius: 22px; padding: 16px; transition: transform .25s, box-shadow .25s, border-color .25s; min-width: 0; }
.coin:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--line-2); }
.coin .hd { display: flex; align-items: center; gap: 13px; min-width: 0; }
.coin .pic { flex: none; width: 54px; height: 54px; border-radius: 16px; overflow: hidden; background: var(--well); }
.coin .pic img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.coin .nm { min-width: 0; flex: 1; }
.coin .nm b { display: block; font-size: 19px; font-weight: 600; letter-spacing: -0.03em; line-height: 1.15; }
.coin .nm small { display: block; color: var(--muted); font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.coin .stats { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 12px; color: var(--muted); }
.coin .stats b { display: block; font-size: 15px; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }

/* ── posts (profile page) ── */
.tile { position: relative; display: block; border-radius: 18px; overflow: hidden; background: var(--well); cursor: pointer; aspect-ratio: 4 / 5; }
.tile img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.tile:hover img { transform: scale(1.03); }
.tile .kind { position: absolute; right: 10px; top: 10px; background: rgba(255,255,255,.9); }
.tile .cap { position: absolute; inset: auto 0 0; padding: 30px 14px 12px; background: linear-gradient(180deg, transparent, rgba(8,8,10,.7)); color: #fff; font-size: 13.5px; opacity: 0; transition: opacity .25s; }
.tile:hover .cap { opacity: 1; }
.tweet { background: #fff; border: 1px solid var(--line); border-radius: 18px; padding: 16px 18px; }
.tweet .hd { display: flex; align-items: center; gap: 10px; font-size: 14px; }
.tweet .hd b { font-weight: 600; }
.tweet .hd small { color: var(--muted); }
.tweet p { margin: 10px 0 0; font-size: 16px; line-height: 1.45; letter-spacing: -0.01em; }
.tweet .ft { margin-top: 12px; display: flex; gap: 16px; font-size: 13px; color: var(--muted); align-items: center; }
.like { display: inline-flex; align-items: center; gap: 6px; border: 0; background: none; cursor: pointer; color: var(--muted); font-size: 13px; padding: 0; }
.like svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.like.on { color: var(--red); }
.like.on svg { fill: var(--red); stroke: var(--red); }
.cash { font-weight: 600; }
.veil { position: fixed; inset: 0; z-index: 80; background: rgba(8,8,10,.72); backdrop-filter: blur(6px); display: none; align-items: center; justify-content: center; padding: 24px; }
.veil.show { display: flex; }
.viewer { display: grid; grid-template-columns: minmax(0, 420px) 340px; background: #fff; border-radius: 26px; overflow: hidden; max-height: 88vh; animation: pop .3s cubic-bezier(.2,.9,.3,1); }
@keyframes pop { from { transform: scale(.95); opacity: 0; } }
.viewer > img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4 / 5; }
.viewer .side2 { padding: 20px; display: flex; flex-direction: column; gap: 14px; }
.viewer .side2 p { margin: 0; font-size: 15.5px; }
.viewer .side2 .note { margin-top: auto; font-size: 12px; color: var(--faint); }
.story { position: relative; width: min(400px, 92vw); aspect-ratio: 9 / 16; max-height: 90vh; border-radius: 26px; overflow: hidden; background: #111; animation: pop .3s cubic-bezier(.2,.9,.3,1); cursor: pointer; }
.story img.bg { width: 100%; height: 100%; object-fit: cover; }
.story .bars { position: absolute; left: 12px; right: 12px; top: 12px; display: flex; gap: 4px; }
.story .bars i { flex: 1; height: 3px; border-radius: 3px; background: rgba(255,255,255,.35); overflow: hidden; }
.story .bars i b { display: block; height: 100%; width: 0; background: #fff; }
.story .bars i.done b { width: 100%; }
.story .bars i.run b { animation: fill 4.5s linear forwards; }
@keyframes fill { to { width: 100%; } }
.story .who { position: absolute; left: 14px; top: 26px; display: flex; align-items: center; gap: 10px; color: #fff; font-size: 14px; font-weight: 600; text-shadow: 0 1px 4px rgba(0,0,0,.4); }
.story .txt { position: absolute; left: 18px; right: 18px; bottom: 26px; color: #fff; font-size: 22px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; text-shadow: 0 2px 10px rgba(0,0,0,.5); }
.x-close { position: fixed; right: 22px; top: 18px; width: 42px; height: 42px; border-radius: 42px; background: rgba(255,255,255,.14); color: #fff; border: 0; font-size: 22px; cursor: pointer; z-index: 81; display: none; }
.veil.show ~ .x-close { display: block; }

.foot { margin-top: auto; border-top: 1px solid var(--line); padding: 26px 0 32px; }
.foot .page { display: flex; justify-content: space-between; gap: 28px; flex-wrap: wrap; align-items: flex-start; }
.foot p { margin: 0; color: var(--faint); font-size: 12.5px; max-width: 640px; }
.foot nav { display: flex; gap: 20px; font-size: 13.5px; color: var(--muted); }
.foot nav a:hover { color: var(--ink); }

@media (max-width: 1080px) {
  .side { display: none; }
  .main { margin-left: 0; }
  .top .brand { display: flex; }
  .search { display: none; }
  .top .right { margin-left: auto; }
  .menu-btn { display: grid; }
  .drawer.open { display: grid; position: fixed; top: 64px; left: 0; right: 0; z-index: 29; background: #fff; border-bottom: 1px solid var(--line); padding: 10px 14px 16px; gap: 2px; box-shadow: var(--shadow); }
  .drawer a.on { background: var(--canvas); font-weight: 600; }
  .coins { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px) {
  .page { padding: 0 16px; }
  .top { padding: 0 14px; }
  .top .pill { display: none; }
  .coins { grid-template-columns: minmax(0, 1fr); }
  .viewer { grid-template-columns: minmax(0, 1fr); overflow: auto; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } .reveal { opacity: 1; transform: none; } }
