/* VelvaPod customer area (app.html): dark forest ground, lime action, one panel style. */
:root {
  --bg: #0b170c; --bg-2: #0f1f10; --panel: rgb(22 42 23 / .72); --panel-solid: #162a17; --panel-2: #1d361e;
  --line: rgb(238 243 234 / .10); --line-2: rgb(238 243 234 / .18);
  --ink: #eef3ea; --ink-2: #cfd7cc; --muted: #a3ae9f; --accent: #c6f19d; --accent-ink: #0f1f10;
  --warn: #ffd38f; --bad: #ff9c8a; --good: #9ff0b8;
  --r: 18px; --r-sm: 12px; --r-btn: 12px;
  --font: "Reddit Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --top: 56px; --tabs: calc(64px + env(safe-area-inset-bottom));
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100dvh; background: var(--bg); color: var(--ink); font: 400 15px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
img, video, svg, canvas { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; }
h1 { font-size: clamp(28px, 4vw, 40px); }
h2 { font-size: 20px; letter-spacing: -0.01em; }
p { margin: 0; }
code, kbd { font-family: var(--mono); font-size: .88em; }
:not(pre) > code { padding: 1px 6px; border-radius: 6px; background: rgb(238 243 234 / .08); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
svg { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* the ground: three slow lights drifting behind everything */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; background: radial-gradient(120% 80% at 50% -10%, #173118 0%, var(--bg) 60%); }
.bg i { position: absolute; width: 60vmax; height: 60vmax; border-radius: 50%; filter: blur(80px); opacity: .35; mix-blend-mode: screen; animation: drift 26s ease-in-out infinite alternate; }
.bg i:nth-child(1) { left: -20vmax; top: -25vmax; background: radial-gradient(circle, #3c6b2e, transparent 65%); }
.bg i:nth-child(2) { right: -25vmax; top: 10vmax; background: radial-gradient(circle, #1f5a4a, transparent 65%); animation-duration: 32s; animation-delay: -8s; }
.bg i:nth-child(3) { left: 20vmax; bottom: -35vmax; background: radial-gradient(circle, #6b8f2a, transparent 65%); opacity: .22; animation-duration: 38s; animation-delay: -16s; }
@keyframes drift { to { transform: translate(8vmax, 6vmax) scale(1.15); } }

/* ---------------------------------------------------------------- shell */
.ap { min-height: 100dvh; }
.logo { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 18px; letter-spacing: -0.02em; text-decoration: none; }
.logo__mark { width: 26px; height: 26px; border-radius: 8px; background: var(--accent) radial-gradient(circle at 30% 30%, var(--accent-ink) 0 2.5px, transparent 3px) 0 0 / 9px 9px; box-shadow: 0 0 24px rgb(198 241 157 / .35); }
.side { display: none; }
.top { position: sticky; top: 0; z-index: 20; height: var(--top); display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0 16px; background: rgb(11 23 12 / .78); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.top__plan { display: inline-flex; align-items: center; gap: 8px; height: 32px; padding: 0 12px; border-radius: 99px; background: rgb(238 243 234 / .07); border: 1px solid var(--line); font-size: 13px; text-decoration: none; white-space: nowrap; max-width: 62vw; overflow: hidden; text-overflow: ellipsis; }
.top__plan i { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.top__plan.is-on i { background: var(--accent); box-shadow: 0 0 0 0 rgb(198 241 157 / .6); animation: ping 2.4s infinite; }
@keyframes ping { 70% { box-shadow: 0 0 0 8px rgb(198 241 157 / 0); } 100% { box-shadow: 0 0 0 0 rgb(198 241 157 / 0); } }
.main { width: 100%; padding: 20px 16px calc(var(--tabs) + 28px); max-width: 1240px; margin: 0 auto; outline: none; }
.tabs-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; height: var(--tabs); padding-bottom: env(safe-area-inset-bottom); display: grid; grid-template-columns: repeat(5, 1fr); background: rgb(11 23 12 / .86); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--line); }
.tabs-bar a { display: grid; place-items: center; align-content: center; gap: 3px; font-size: 11px; color: var(--muted); text-decoration: none; transition: color .2s; }
.tabs-bar a svg { width: 22px; height: 22px; transition: transform .25s var(--ease); }
.tabs-bar a.is-on { color: var(--accent); }
.tabs-bar a.is-on svg { transform: translateY(-2px); }
.ap[data-auth="out"] :is(.tabs-bar, .top__plan, .side__nav, .plan-box) { display: none; }
.ap[data-auth="out"] .main { padding-bottom: 32px; }
@media (min-width: 960px) {
  .ap { display: grid; grid-template-columns: 248px minmax(0, 1fr); }
  .top, .tabs-bar { display: none; }
  .side { display: flex; flex-direction: column; gap: 28px; position: sticky; top: 0; height: 100dvh; padding: 24px 16px; border-right: 1px solid var(--line); background: rgb(11 23 12 / .55); backdrop-filter: blur(12px); }
  .side .logo { padding: 0 8px; }
  .side__nav { display: grid; gap: 2px; }
  .side__nav a { display: flex; align-items: center; gap: 12px; height: 42px; padding: 0 12px; border-radius: 10px; color: var(--ink-2); text-decoration: none; transition: background .2s, color .2s; }
  .side__nav a svg { width: 20px; height: 20px; }
  .side__nav a:hover { background: rgb(238 243 234 / .06); color: var(--ink); }
  .side__nav a.is-on { background: rgb(198 241 157 / .12); color: var(--accent); }
  .plan-box { margin-top: auto; display: grid; gap: 2px; padding: 14px; border-radius: var(--r-sm); border: 1px solid var(--line); background: var(--panel); text-decoration: none; }
  .plan-box__label { font-size: 12px; color: var(--muted); }
  .plan-box [data-plan-left] { font-size: 13px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
  .plan-box.is-off [data-plan-left] { color: var(--warn); }
  .main { padding: 40px 48px 64px; }
  .ap[data-auth="out"] { grid-template-columns: minmax(0, 1fr); }
  .ap[data-auth="out"] .side { display: none; }
}
.ap[data-auth="loading"] .main > .view { display: none; }

/* views enter with a short rise */
.view { animation: rise .45s var(--ease) both; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
.view__head { display: grid; gap: 8px; margin-bottom: 20px; }
.view__head p { max-width: 64ch; }

/* ---------------------------------------------------------------- parts */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: 20px; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.card__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 46px; padding: 0 20px; border-radius: var(--r-btn); border: 1px solid transparent; font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap; transition: transform .15s var(--ease), background .2s, box-shadow .2s, opacity .2s; -webkit-tap-highlight-color: transparent; }
.btn svg { width: 18px; height: 18px; }
.btn:active { transform: scale(.97); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.btn--primary { background: var(--accent); color: var(--accent-ink); box-shadow: 0 8px 28px -10px rgb(198 241 157 / .6); }
.btn--primary:hover:not(:disabled) { box-shadow: 0 10px 34px -8px rgb(198 241 157 / .75); transform: translateY(-1px); }
.btn--ghost { background: rgb(238 243 234 / .06); border-color: var(--line-2); color: var(--ink); }
.btn--ghost:hover:not(:disabled) { background: rgb(238 243 234 / .1); }
.btn--danger { background: var(--bad); color: #2a0d07; }
.btn--sm { height: 36px; padding: 0 14px; font-size: 14px; }
.btn--lg { height: 52px; padding: 0 28px; font-size: 16px; }
.btn--wide { width: 100%; }
.btn--icon { width: 46px; padding: 0; }
.btn kbd { font-size: 11px; font-weight: 500; opacity: .6; border: 0; background: none; padding: 0; }
@media (max-width: 640px) { .btn kbd { display: none; } }
.btn.is-busy { position: relative; color: transparent !important; pointer-events: none; }
.btn.is-busy::after { content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--accent-ink); border-right-color: transparent; animation: spin .7s linear infinite; }
.btn--ghost.is-busy::after { border-color: var(--ink); border-right-color: transparent; }
@keyframes spin { to { transform: rotate(360deg); } }
.link { color: var(--accent); text-decoration: none; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .25s var(--ease); }
.link:hover { background-size: 100% 1px; }

.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; font-size: 13px; color: var(--ink-2); }
.field input, textarea, .field select { width: 100%; min-height: 46px; padding: 11px 14px; border-radius: var(--r-sm); border: 1px solid var(--line-2); background: rgb(5 12 6 / .45); color: var(--ink); font-size: 16px; transition: border-color .2s, box-shadow .2s; }
.field input:focus, textarea:focus, .field select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgb(198 241 157 / .18); }
textarea { resize: vertical; line-height: 1.5; }
.form__err { min-height: 0; color: var(--bad); font-size: 14px; }
.form__err:empty { display: none; }
.form__ok { color: var(--good); font-size: 14px; }

.seg { display: grid; grid-template-columns: 1fr 1fr; padding: 4px; border-radius: 12px; background: rgb(5 12 6 / .5); border: 1px solid var(--line); }
.seg button { height: 38px; border: 0; border-radius: 9px; background: none; color: var(--muted); font-weight: 600; cursor: pointer; transition: background .2s, color .2s; }
.seg button[aria-selected="true"] { background: var(--panel-2); color: var(--ink); box-shadow: 0 2px 10px rgb(0 0 0 / .25); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 99px; border: 1px solid var(--line-2); background: rgb(238 243 234 / .04); color: var(--ink-2); font-size: 14px; cursor: pointer; transition: background .2s, border-color .2s, color .2s, transform .15s; }
.chip:hover { border-color: rgb(198 241 157 / .5); }
.chip:active { transform: scale(.96); }
.chip.is-on { background: rgb(198 241 157 / .14); border-color: var(--accent); color: var(--accent); }
.ar { display: inline-block; width: calc(var(--w) * 1px); height: calc(var(--h) * 1px); border: 1.5px solid currentColor; border-radius: 3px; }

.copy { flex: none; display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line-2); background: rgb(238 243 234 / .05); cursor: pointer; transition: background .2s, border-color .2s; }
.copy::before { content: ""; width: 15px; height: 15px; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='9' y='9' width='12' height='12' rx='2'/%3E%3Cpath d='M5 15V5a2 2 0 0 1 2-2h10'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='9' y='9' width='12' height='12' rx='2'/%3E%3Cpath d='M5 15V5a2 2 0 0 1 2-2h10'/%3E%3C/svg%3E") center / contain no-repeat; }
.copy:hover { border-color: var(--accent); }
.copy.is-done { border-color: var(--accent); color: var(--accent); }
.copy.is-done::before { -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12 5 5 9-10'/%3E%3C/svg%3E"); mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 12 5 5 9-10'/%3E%3C/svg%3E"); }

.banner { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; padding: 12px 16px; border-radius: var(--r-sm); border: 1px solid rgb(255 211 143 / .4); background: rgb(255 211 143 / .08); color: var(--warn); font-size: 14px; }
.banner .btn { height: 34px; }

.toasts { position: fixed; z-index: 90; left: 50%; bottom: calc(var(--tabs) + 16px); transform: translateX(-50%); display: grid; gap: 8px; width: min(92vw, 440px); pointer-events: none; }
@media (min-width: 960px) { .toasts { bottom: 28px; } }
.toast { pointer-events: auto; padding: 12px 16px; border-radius: 12px; background: #23402a; border: 1px solid var(--line-2); box-shadow: 0 16px 40px -12px rgb(0 0 0 / .6); font-size: 14px; animation: toast .35s var(--ease) both; }
.toast--bad { background: #432019; border-color: rgb(255 156 138 / .4); }
.toast--good { background: #24451f; border-color: rgb(198 241 157 / .5); }
.toast.is-out { animation: toast-out .3s ease both; }
@keyframes toast { from { opacity: 0; transform: translateY(12px) scale(.98); } }
@keyframes toast-out { to { opacity: 0; transform: translateY(8px); } }

.dlg { padding: 0; border: 0; background: none; color: var(--ink); max-width: min(92vw, 480px); width: 100%; }
.dlg::backdrop { background: rgb(3 8 4 / .7); backdrop-filter: blur(4px); }
.dlg[open] { animation: rise .3s var(--ease); }
.dlg__box { display: grid; gap: 14px; padding: 24px; border-radius: var(--r); border: 1px solid var(--line-2); background: var(--panel-solid); }
.dlg__box h2 { font-size: 22px; }
.dlg__acts { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.keybox { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: var(--r-sm); background: rgb(5 12 6 / .6); border: 1px solid var(--accent); }
.keybox code { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 14px; color: var(--accent); background: none; padding: 0; }
.warn { padding: 12px 14px; border-radius: var(--r-sm); background: rgb(255 211 143 / .08); border: 1px solid rgb(255 211 143 / .35); color: var(--warn); font-size: 14px; }

/* ---------------------------------------------------------------- sign in */
.auth { display: grid; gap: 24px; align-items: center; min-height: calc(100dvh - var(--top) - 72px); }
.auth__show { position: relative; height: 220px; overflow: hidden; border-radius: var(--r); -webkit-mask: linear-gradient(#000 60%, transparent); mask: linear-gradient(#000 60%, transparent); }
.auth__wall { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; animation: wall 40s linear infinite alternate; }
.auth__wall img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 14px; }
.auth__wall img:nth-child(3n+2) { transform: translateY(36px); }
@keyframes wall { to { transform: translateY(-30%); } }
.auth__card { display: grid; gap: 16px; max-width: 460px; width: 100%; justify-self: center; padding: 28px 24px; }
.auth__card h1 { font-size: 30px; }
@media (min-width: 960px) {
  .auth { grid-template-columns: 1.1fr .9fr; gap: 56px; min-height: calc(100dvh - 104px); }
  .auth__show { height: min(640px, 78dvh); }
  .auth__card { padding: 36px 32px; }
  .auth__card h1 { font-size: 38px; }
}

/* ---------------------------------------------------------------- compose */
.compose { display: grid; gap: 14px; margin-bottom: 24px; }
.compose textarea { min-height: 96px; border: 0; background: none; padding: 4px 2px; font-size: 17px; box-shadow: none; }
.compose textarea:focus { box-shadow: none; }
.compose:focus-within { border-color: rgb(198 241 157 / .45); box-shadow: 0 0 0 4px rgb(198 241 157 / .08), 0 30px 60px -30px rgb(0 0 0 / .6); }
.compose { transition: border-color .25s, box-shadow .25s; }
.compose__row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding-top: 14px; border-top: 1px solid var(--line); }
.compose__row--end { justify-content: flex-end; }
.compose__grid { display: grid; gap: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
@media (min-width: 960px) { .compose__grid { grid-template-columns: auto auto 1fr; align-items: start; gap: 28px; } }
.compose__opt { display: grid; gap: 8px; }
.opt-label { font-size: 13px; color: var(--muted); }
@media (max-width: 640px) { .compose__row > .btn { width: 100%; } }
.ideas { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ideas--center { justify-content: center; }
.idea { max-width: 100%; padding: 7px 12px; border-radius: 10px; border: 1px dashed var(--line-2); background: none; color: var(--ink-2); font-size: 13px; text-align: left; cursor: pointer; transition: border-color .2s, color .2s; }
.idea:hover { border-color: var(--accent); color: var(--ink); }
.ref { display: flex; align-items: center; gap: 10px; }
.ref__pick { position: relative; display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; border-radius: 99px; border: 1px dashed var(--line-2); color: var(--ink-2); font-size: 14px; cursor: pointer; }
.ref__pick:hover { border-color: var(--accent); }
.ref__pick input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.ref__pick svg { width: 16px; height: 16px; }
.ref__preview { position: relative; }
.ref__preview img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line-2); }
.ref__x { position: absolute; top: -8px; right: -8px; width: 24px; height: 24px; border-radius: 50%; border: 0; background: var(--ink); color: var(--bg); font-size: 16px; line-height: 1; cursor: pointer; }

.empty { display: grid; justify-items: center; gap: 16px; padding: 40px 16px; text-align: center; color: var(--muted); }
.empty__art { position: relative; width: 150px; height: 100px; }
.empty__art i { position: absolute; width: 70px; height: 90px; border-radius: 12px; border: 1px solid var(--line-2); background: linear-gradient(160deg, rgb(198 241 157 / .16), rgb(31 90 74 / .2)); animation: float 6s ease-in-out infinite; }
.empty__art i:nth-child(1) { left: 0; top: 8px; transform: rotate(-8deg); }
.empty__art i:nth-child(2) { left: 40px; top: 0; z-index: 1; animation-delay: -2s; }
.empty__art i:nth-child(3) { left: 80px; top: 10px; transform: rotate(8deg); animation-delay: -4s; }
.empty__art--video i { height: 56px; width: 90px; top: 20px; }
.empty__art--video i:nth-child(1) { left: -10px; } .empty__art--video i:nth-child(2) { left: 30px; top: 8px; } .empty__art--video i:nth-child(3) { left: 70px; top: 30px; }
@keyframes float { 50% { translate: 0 -8px; } }

/* ---------------------------------------------------------------- image gallery */
.gallery { columns: 2 150px; column-gap: 12px; }
@media (min-width: 720px) { .gallery { columns: 3 200px; column-gap: 16px; } }
@media (min-width: 1200px) { .gallery { columns: 4 220px; } }
.tile { position: relative; break-inside: avoid; margin: 0 0 12px; border-radius: 14px; overflow: hidden; background: var(--panel-solid); border: 1px solid var(--line); animation: pop .5s var(--ease) both; }
@media (min-width: 720px) { .tile { margin-bottom: 16px; } }
@keyframes pop { from { opacity: 0; transform: scale(.96); } }
.tile__media { position: relative; aspect-ratio: var(--ar, 1); overflow: hidden; }
.tile__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); cursor: zoom-in; }
.tile:hover .tile__media img { transform: scale(1.03); }
.tile__media img.is-in { animation: develop 1.1s var(--ease) both; }
@keyframes develop { from { opacity: 0; filter: blur(18px) saturate(1.6); transform: scale(1.06); } }
.tile__body { display: grid; gap: 8px; padding: 10px 12px 12px; }
.tile__prompt { font-size: 13px; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.tile__acts { display: flex; gap: 6px; flex-wrap: wrap; }
.tile__acts :is(a, button) { display: inline-flex; align-items: center; height: 30px; padding: 0 10px; border-radius: 8px; border: 1px solid var(--line-2); background: rgb(238 243 234 / .05); font-size: 12px; text-decoration: none; cursor: pointer; transition: border-color .2s, color .2s; }
.tile__acts :is(a, button):hover { border-color: var(--accent); color: var(--accent); }
.tile__meta { font-size: 12px; color: var(--muted); }
.tile--failed .tile__media { display: grid; place-items: center; padding: 16px; background: rgb(255 156 138 / .06); text-align: center; color: var(--bad); font-size: 13px; }

/* the generating state: a slow aurora, the stage it is at, the time and a bar */
.gen { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: 6px; padding: 16px; text-align: center; overflow: hidden; background: #0e1d0f; }
.gen::before, .gen::after { content: ""; position: absolute; inset: -40%; background: conic-gradient(from 0deg, #c6f19d, #2e6b4c, #0e1d0f, #87c46a, #c6f19d); filter: blur(38px); opacity: .55; animation: aurora 6s linear infinite; }
.gen::after { inset: -20%; background: radial-gradient(circle at 30% 30%, rgb(198 241 157 / .55), transparent 45%), radial-gradient(circle at 70% 70%, rgb(46 107 76 / .7), transparent 50%); animation: aurora 9s linear infinite reverse; opacity: .7; }
@keyframes aurora { to { transform: rotate(360deg); } }
.gen > * { position: relative; z-index: 1; }
.gen__stage { font-weight: 600; font-size: 14px; text-shadow: 0 1px 8px rgb(0 0 0 / .5); }
.gen__time { font: 500 12px var(--mono); color: var(--ink-2); font-variant-numeric: tabular-nums; }
.gen__bar { position: absolute !important; left: 0; right: 0; bottom: 0; height: 3px; background: rgb(0 0 0 / .3); }
.gen__bar b { display: block; height: 100%; width: 0; background: var(--accent); box-shadow: 0 0 12px var(--accent); transition: width .6s linear; }
.gen__grain { position: absolute !important; inset: 0; opacity: .18; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence baseFrequency='.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='120' height='120' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E"); mix-blend-mode: overlay; }

/* ---------------------------------------------------------------- videos */
.vlist { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); align-items: start; }
.vcard { display: grid; grid-template-rows: auto 1fr; border-radius: 16px; overflow: hidden; background: var(--panel-solid); border: 1px solid var(--line); animation: pop .5s var(--ease) both; }
.vcard__media { position: relative; aspect-ratio: var(--ar, 9 / 16); background: #000; overflow: hidden; }
.vcard__media video { width: 100%; height: 100%; object-fit: contain; background: #000; }
.vcard__body { display: grid; gap: 8px; align-content: start; padding: 12px 14px 14px; }
.vcard__row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.status { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 99px; font-size: 12px; font-weight: 600; background: rgb(238 243 234 / .08); color: var(--ink-2); white-space: nowrap; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status--run { color: var(--accent); background: rgb(198 241 157 / .12); }
.status--run::before { animation: blink 1s steps(2) infinite; }
.status--ok { color: var(--good); background: rgb(159 240 184 / .1); }
.status--bad { color: var(--bad); background: rgb(255 156 138 / .1); }
.status--warn { color: var(--warn); background: rgb(255 211 143 / .1); }
@keyframes blink { 50% { opacity: .2; } }

/* ---------------------------------------------------------------- chat */
.view--chat { margin: -20px -16px calc(-1 * (var(--tabs) + 28px)); }
.chat { display: grid; height: calc(100dvh - var(--top) - var(--tabs)); }
.chat__side { position: fixed; z-index: 40; inset: var(--top) auto var(--tabs) 0; width: min(84vw, 300px); display: grid; grid-template-rows: auto 1fr; gap: 12px; padding: 16px; background: var(--panel-solid); border-right: 1px solid var(--line); transform: translateX(-102%); transition: transform .3s var(--ease); }
.chat__side.is-open { transform: none; box-shadow: 30px 0 60px rgb(0 0 0 / .5); }
.chat__list { list-style: none; margin: 0; padding: 0; overflow-y: auto; display: grid; align-content: start; gap: 2px; }
.chat__list li { display: flex; align-items: center; border-radius: 10px; }
.chat__list li.is-on { background: rgb(198 241 157 / .1); }
.chat__list button.open { flex: 1; min-width: 0; text-align: left; padding: 10px 12px; border: 0; background: none; color: var(--ink-2); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; cursor: pointer; }
.chat__list li.is-on button.open { color: var(--ink); }
.chat__list button.del { flex: none; width: 32px; height: 32px; border: 0; border-radius: 8px; background: none; color: var(--muted); cursor: pointer; opacity: .6; }
.chat__list button.del:hover { opacity: 1; color: var(--bad); }
.chat__main { display: grid; grid-template-rows: auto 1fr auto; min-height: 0; }
.chat__bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.chat__title { flex: 1; min-width: 0; text-align: center; font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat__thread { overflow-y: auto; padding: 20px 16px; display: flex; flex-direction: column; gap: 18px; scroll-behavior: smooth; }
.chat__hello { margin: auto; display: grid; justify-items: center; gap: 12px; max-width: 560px; text-align: center; padding: 20px 0; }
.chat__hello h1 { font-size: 30px; }
.orb { width: 84px; height: 84px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #f1ffd9, var(--accent) 30%, #2e6b4c 70%, #0e1d0f); box-shadow: 0 0 60px rgb(198 241 157 / .35); animation: orb 5s ease-in-out infinite; }
@keyframes orb { 50% { transform: scale(1.06) rotate(10deg); box-shadow: 0 0 90px rgb(198 241 157 / .5); } }
.msg { max-width: min(760px, 100%); animation: rise .3s var(--ease) both; }
.msg--me { align-self: flex-end; padding: 10px 14px; border-radius: 16px 16px 4px 16px; background: var(--panel-2); border: 1px solid var(--line); white-space: pre-wrap; overflow-wrap: anywhere; }
.msg--bot { align-self: flex-start; display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 12px; width: 100%; }
.msg--bot::before { content: ""; width: 28px; height: 28px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #f1ffd9, var(--accent) 35%, #2e6b4c); }
.msg--bot.is-live::before { animation: orb 1.6s ease-in-out infinite; }
.msg__err { color: var(--bad); font-size: 14px; }
.md { min-width: 0; overflow-wrap: anywhere; line-height: 1.65; }
.md > * + * { margin-top: .7em; }
.md h3, .md h4 { font-size: 17px; margin-top: 1em; }
.md ul, .md ol { padding-left: 1.4em; margin-block: .4em; }
.md li + li { margin-top: .25em; }
.md a { color: var(--accent); }
.md strong { color: #fff; font-weight: 650; }
.md blockquote { margin: 0; padding-left: 12px; border-left: 3px solid var(--line-2); color: var(--ink-2); }
.md .caret { display: inline-block; width: 8px; height: 1.1em; margin-left: 2px; vertical-align: -.2em; background: var(--accent); animation: blink .9s steps(2) infinite; }
.md-code { position: relative; margin: .8em 0; border-radius: 12px; border: 1px solid var(--line); background: #071108; overflow: hidden; }
.md-code__bar { display: flex; align-items: center; justify-content: space-between; height: 34px; padding: 0 8px 0 14px; border-bottom: 1px solid var(--line); font: 12px var(--mono); color: var(--muted); }
.md-code__bar button { height: 26px; padding: 0 10px; border-radius: 7px; border: 1px solid var(--line-2); background: none; font-size: 12px; cursor: pointer; }
.md-code code { display: block; padding: 12px 14px; overflow-x: auto; font-size: 13px; line-height: 1.55; white-space: pre; }
.chat__compose { display: flex; align-items: flex-end; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); background: rgb(11 23 12 / .6); }
.chat__compose textarea { flex: 1; min-height: 46px; max-height: 200px; resize: none; }
@media (min-width: 960px) {
  .view--chat { margin: -40px -48px -64px; }
  .chat { grid-template-columns: 280px minmax(0, 1fr); height: 100dvh; }
  .chat__side { position: static; transform: none; width: auto; inset: auto; background: rgb(11 23 12 / .35); }
  .chat__hist, .chat__bar [data-chat-new] { display: none; }
  .chat__title { text-align: left; }
  .chat__thread { padding: 32px max(32px, calc(50% - 400px)); }
  .chat__compose { padding: 16px max(32px, calc(50% - 400px)) 24px; }
}

/* ---------------------------------------------------------------- buy a plan */
.step { display: flex; align-items: center; gap: 10px; margin: 8px 0 14px; font-size: 18px; }
.step span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: rgb(198 241 157 / .14); color: var(--accent); font-size: 14px; }
.plans { display: grid; gap: 12px; margin-bottom: 28px; }
@media (min-width: 720px) { .plans { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); } }
.plan { position: relative; display: grid; gap: 10px; text-align: left; padding: 18px; border-radius: var(--r); border: 1px solid var(--line-2); background: var(--panel); cursor: pointer; transition: border-color .2s, transform .2s var(--ease), box-shadow .25s; }
.plan:hover { transform: translateY(-2px); border-color: rgb(198 241 157 / .45); }
.plan.is-on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent), 0 20px 50px -24px rgb(198 241 157 / .45); }
.plan__name { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-weight: 600; font-size: 17px; }
.plan__tick { width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--line-2); transition: background .2s, border-color .2s; }
.plan.is-on .plan__tick { border-color: var(--accent); background: var(--accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%230f1f10' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat; }
.plan__price { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 10px; }
.plan__price b { font-size: 28px; font-weight: 650; letter-spacing: -0.03em; }
.plan__price span { color: var(--muted); font-size: 14px; }
.plan__facts { display: flex; flex-wrap: wrap; gap: 6px; }
.plan__facts span { padding: 3px 9px; border-radius: 99px; background: rgb(238 243 234 / .06); font-size: 12px; color: var(--ink-2); }
.methods { display: grid; gap: 10px; margin-bottom: 20px; }
@media (min-width: 720px) { .methods { grid-template-columns: repeat(3, 1fr); } }
.method { display: grid; grid-template-columns: 40px 1fr; gap: 4px 12px; align-items: center; text-align: left; padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--panel); cursor: pointer; transition: border-color .2s, box-shadow .2s; }
.method:hover:not(:disabled) { border-color: rgb(198 241 157 / .45); }
.method.is-on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.method:disabled { cursor: not-allowed; opacity: .55; }
.method__ic { grid-row: span 2; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center; font: 700 13px var(--font); }
.method__ic--trc20 { background: #e5313a; color: #fff; }
.method__ic--bep20 { background: #f0b90b; color: #1a1300; }
.method__ic--vnd { background: #1d4fd8; color: #fff; }
.method b { font-size: 15px; }
.method span { font-size: 13px; color: var(--muted); }
.buy-go { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
@media (max-width: 640px) { .buy-go .btn { width: 100%; } }

.order { display: grid; gap: 16px; animation: rise .4s var(--ease) both; }
.order__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.order__head h2 { font-size: 22px; }
.order__grid { display: grid; gap: 16px; }
@media (min-width: 900px) { .order__grid { grid-template-columns: 300px minmax(0, 1fr); align-items: start; } }
.qr { position: relative; display: grid; place-items: center; justify-self: center; width: min(100%, 300px); aspect-ratio: 1; padding: 16px; border-radius: 20px; background: #fff; box-shadow: 0 30px 80px -30px rgb(198 241 157 / .5); }
.qr svg, .qr img { width: 100%; height: 100%; }
.qr::after { content: ""; position: absolute; inset: -2px; border-radius: 22px; border: 2px solid var(--accent); opacity: 0; animation: scan 2.6s ease-in-out infinite; pointer-events: none; }
@keyframes scan { 50% { opacity: .9; inset: -8px; border-radius: 26px; } }
.qr__badge { position: absolute; left: 50%; top: 50%; translate: -50% -50%; width: 48px; height: 48px; border-radius: 12px; display: grid; place-items: center; font: 700 12px var(--font); border: 4px solid #fff; }
.pay-rows { display: grid; gap: 2px; }
.pay-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.pay-row:last-child { border-bottom: 0; }
.pay-row dt { grid-column: 1 / -1; font-size: 12px; color: var(--muted); }
.pay-row dd { margin: 0; min-width: 0; font-weight: 600; overflow-wrap: anywhere; }
.pay-row dd.mono { font-family: var(--mono); font-weight: 500; font-size: 14px; }
.pay-amt { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px; border-radius: 16px; background: rgb(198 241 157 / .08); border: 1px solid rgb(198 241 157 / .35); }
.pay-amt__n { display: grid; gap: 2px; min-width: 0; }
.pay-amt__n span { font-size: 12px; color: var(--muted); }
.pay-amt__n b { font: 600 clamp(26px, 6vw, 36px)/1.1 var(--mono); letter-spacing: -0.02em; color: var(--accent); overflow-wrap: anywhere; }
.pay-amt__n b small { font: 600 16px var(--font); color: var(--ink); margin-left: 6px; }
.pay-amt .copy { width: 44px; height: 44px; }
.clock { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 14px; background: rgb(5 12 6 / .5); border: 1px solid var(--line); }
.clock__ring { flex: none; width: 40px; height: 40px; }
.clock__ring circle { fill: none; stroke-width: 4; }
.clock__ring .bgc { stroke: rgb(238 243 234 / .12); }
.clock__ring .fgc { stroke: var(--accent); stroke-linecap: round; transform: rotate(-90deg); transform-origin: center; transition: stroke-dashoffset 1s linear; }
.clock__t { display: grid; }
.clock__t b { font: 600 20px var(--mono); font-variant-numeric: tabular-nums; }
.clock__t span { font-size: 13px; color: var(--muted); }
.done { display: grid; justify-items: center; gap: 14px; padding: 36px 20px; text-align: center; }
.done__tick { width: 88px; height: 88px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--accent-ink); box-shadow: 0 0 0 12px rgb(198 241 157 / .12), 0 0 80px rgb(198 241 157 / .5); animation: tick .7s cubic-bezier(.2, 1.6, .4, 1) both; }
.done__tick svg { width: 44px; height: 44px; stroke-width: 3; stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .5s .35s ease forwards; }
@keyframes tick { from { transform: scale(.3); opacity: 0; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.done h2 { font-size: 28px; }
.confetti { position: fixed; inset: 0; z-index: 100; width: 100vw; height: 100vh; pointer-events: none; }

/* ---------------------------------------------------------------- account */
.acc { display: grid; gap: 16px; }
@media (min-width: 900px) { .acc { grid-template-columns: repeat(2, minmax(0, 1fr)); } .acc__plan, .acc__orders { grid-column: 1 / -1; } }
.acc .card { display: grid; gap: 12px; align-content: start; }
.acc__plan { position: relative; overflow: hidden; }
.acc__plan::before { content: ""; position: absolute; right: -80px; top: -80px; width: 260px; height: 260px; border-radius: 50%; background: radial-gradient(circle, rgb(198 241 157 / .22), transparent 70%); pointer-events: none; }
.plan-now { display: grid; gap: 16px; }
@media (min-width: 720px) { .plan-now { grid-template-columns: 1.2fr 1fr 1fr auto; align-items: end; } }
.plan-now dt { font-size: 12px; color: var(--muted); }
.plan-now dd { margin: 2px 0 0; font-size: 18px; font-weight: 600; }
.plan-now .big { font-size: 26px; letter-spacing: -0.02em; }
.plan-now .left { font-family: var(--mono); font-size: 18px; font-variant-numeric: tabular-nums; }
.keyline { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 14px; border-radius: var(--r-sm); background: rgb(5 12 6 / .5); border: 1px solid var(--line); }
.keyline code { background: none; padding: 0; font-size: 15px; }
.olist { display: grid; }
.orow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 12px; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.orow:last-child { border-bottom: 0; }
.orow b { font-weight: 600; }
.orow small { color: var(--muted); font-size: 12px; }
.orow__r { display: grid; justify-items: end; gap: 4px; }
.orow__amt { font-family: var(--mono); font-size: 14px; }
@media (min-width: 720px) { .orow { grid-template-columns: 1fr 1fr auto auto; } .orow__r { display: contents; } }

/* ---------------------------------------------------------------- docs */
.docs { display: grid; gap: 16px; }
.facts { display: grid; gap: 12px; margin: 0 0 12px; }
.facts div { display: grid; gap: 4px; }
.facts dt { font-size: 12px; color: var(--muted); }
.facts dd { margin: 0; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.facts dd code { font-size: 14px; }
.doc { display: grid; gap: 12px; }
.tabs { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: rgb(5 12 6 / .5); border: 1px solid var(--line); width: max-content; max-width: 100%; overflow-x: auto; }
.tabs button { height: 32px; padding: 0 14px; border: 0; border-radius: 8px; background: none; color: var(--muted); font-size: 13px; font-weight: 600; cursor: pointer; }
.tabs button[aria-selected="true"] { background: var(--panel-2); color: var(--ink); }
pre.code { position: relative; margin: 0; padding: 16px; padding-right: 52px; border-radius: 14px; background: #071108; border: 1px solid var(--line); overflow-x: auto; font: 13px/1.6 var(--mono); color: #dfe8da; }
pre.code .copy { position: absolute; top: 10px; right: 10px; }
.errs { display: grid; gap: 14px; margin: 0; }
.errs div { display: grid; gap: 4px; }
.errs dt code { color: var(--warn); }
.errs dd { margin: 0; color: var(--ink-2); font-size: 14px; }

.lightbox { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 24px; background: rgb(3 8 4 / .9); backdrop-filter: blur(6px); animation: rise .25s var(--ease); }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 12px; box-shadow: 0 40px 120px rgb(0 0 0 / .7); }
.lightbox__x { position: absolute; top: 16px; right: 16px; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-2); background: rgb(11 23 12 / .8); font-size: 26px; cursor: pointer; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
