/* ============================================================
   ChannelCraft workspace — routed view styles
   ============================================================ */

/* ---------- account menu / mobile menu ---------- */
.menu-btn { display: none; margin-right: auto; }
.account-wrap { position: relative; }
.account-menu { position: absolute; right: 0; top: 50px; width: 248px; background: #110f1b; border: 1px solid var(--border-strong); border-radius: 14px; padding: 8px; box-shadow: 0 24px 60px -20px rgba(0,0,0,0.75); display: none; z-index: 60; }
.account-menu.open { display: block; }
.am-head { display: flex; align-items: center; gap: 10px; padding: 10px; border-bottom: 1px solid var(--border); margin-bottom: 6px; }
.am-id { display: flex; flex-direction: column; min-width: 0; }
.am-id b { font-size: 0.92rem; }
.am-id span { font-size: 0.78rem; color: var(--text-faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.am-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px; border: 0; background: none; color: var(--text-dim); font-size: 0.9rem; font-weight: 500; border-radius: 9px; cursor: pointer; text-align: left; }
.am-item:hover { background: var(--surface-2); color: var(--text); }
.am-item svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- page head ---------- */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; max-width: var(--page-max); margin: 0 auto 26px; padding-top: 22px; flex-wrap: wrap; }
.page-title { font-family: var(--font-display); font-weight: 700; font-size: clamp(1.6rem, 3vw, 2.2rem); letter-spacing: -0.02em; display: inline-flex; align-items: center; gap: 12px; }
.page-sub { color: var(--text-dim); margin-top: 6px; max-width: 640px; }
.ph-ico { width: 38px; height: 38px; border-radius: 11px; display: inline-grid; place-items: center; font-size: 1.15rem; color: var(--text); background: var(--surface-3); border: 1px solid var(--border); }
.ph-ico svg { width: 20px; height: 20px; }
.ph-cost { font-family: var(--font-mono); font-size: 0.82rem; color: var(--violet-bright); border: 1px solid rgba(168,88,247,0.35); background: rgba(168,88,247,0.1); padding: 7px 13px; border-radius: 999px; white-space: nowrap; }

/* ---------- studio workspace ---------- */
.studio { max-width: var(--page-max); margin: 0 auto; }
.studio-box { border-radius: 18px; margin-bottom: 22px; }
.pb-note { font-size: 0.8rem; color: var(--text-faint); }
.r-area { max-width: var(--page-max); margin: 0 auto; min-height: 200px; }
.r-placeholder { border: 1.5px dashed var(--border-strong); border-radius: 18px; padding: 30px 22px; text-align: center; color: var(--text-faint); }
.r-placeholder p { max-width: 360px; margin: 0 auto; }
.r-loading { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 70px; color: var(--text-dim); }
.spinner { width: 20px; height: 20px; border-radius: 50%; border: 2.5px solid rgba(168,88,247,0.3); border-top-color: var(--violet-bright); animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.r-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
.r-head b { font-family: var(--font-display); font-size: 1.1rem; }
.r-cohesive { font-size: 0.74rem; font-weight: 600; color: var(--mint); border: 1px solid rgba(0,255,163,0.35); background: rgba(0,255,163,0.1); padding: 5px 11px; border-radius: 999px; }
.r-reveal { animation: rin 0.5s cubic-bezier(.22,1,.36,1) both; }
@keyframes rin { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.r-actions { display: flex; align-items: center; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
.r-credit { margin-left: auto; font-family: var(--font-mono); font-size: 0.8rem; color: var(--text-faint); }

/* kit result */
.r-kit { display: grid; grid-template-columns: 0.8fr 1.1fr 1fr; gap: 0; border: 1px solid var(--border); border-radius: 18px; overflow: hidden; background: var(--surface); }
.r-col { padding: 20px; border-right: 1px solid var(--border); }
.r-col:last-child { border-right: 0; }
.r-lbl { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint); margin-bottom: 12px; }
.r-logo { aspect-ratio: 1; border-radius: 16px; display: grid; place-items: center; position: relative; overflow: hidden; box-shadow: 0 10px 30px -12px var(--k1); }
.r-logo::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 30% 25%, rgba(255,255,255,0.35), transparent 55%); }
.r-mono { font-family: var(--font-display); font-weight: 800; font-size: clamp(2rem,7vw,3rem); color: #fff; position: relative; z-index: 1; }
.r-spark { position: absolute; top: 12px; right: 14px; color: rgba(255,255,255,0.85); z-index: 1; }
.r-emotes { display: flex; gap: 8px; }
.r-emote { flex: 1; aspect-ratio: 1; border-radius: 11px; display: grid; place-items: center; font-weight: 700; border: 1px solid rgba(255,255,255,0.18); }
.r-overlay { aspect-ratio: 16/10; border-radius: 14px; padding: 9px; position: relative; display: grid; grid-template-columns: 1.6fr 1fr; grid-template-rows: 1fr auto; gap: 7px; overflow: hidden;
  background: linear-gradient(180deg,rgba(0,0,0,.5),rgba(0,0,0,.8)), radial-gradient(circle at 80% 10%, color-mix(in srgb,var(--k2) 50%,transparent),transparent 55%), var(--k4); border: 1.5px solid color-mix(in srgb,var(--k1) 60%, transparent); }
.ro-cam { border-radius: 9px; border: 1.5px solid color-mix(in srgb,var(--k1) 70%, white 10%); background: linear-gradient(160deg, color-mix(in srgb,var(--k1) 35%,#000), color-mix(in srgb,var(--k2) 30%,#000)); display: grid; place-items: center; position: relative; }
.ro-live { position: absolute; top: 6px; left: 6px; font-size: 0.52rem; font-weight: 700; background: #ff2d55; color: #fff; padding: 2px 6px; border-radius: 4px; }
.ro-mono { font-family: var(--font-display); font-weight: 800; font-size: 1.5rem; color: rgba(255,255,255,0.92); }
.ro-chat { border-radius: 9px; background: rgba(0,0,0,0.45); border: 1px solid rgba(255,255,255,0.1); padding: 7px; display: flex; flex-direction: column; gap: 5px; }
.ro-msg { font-size: 0.56rem; color: rgba(255,255,255,0.82); }
.ro-alert { grid-column: 1/-1; border-radius: 8px; padding: 6px 10px; font-size: 0.62rem; font-weight: 700; color: #fff; background: linear-gradient(90deg,var(--k1),var(--k2)); }
.r-persona { font-style: italic; font-size: 0.92rem; border-left: 2px solid var(--k1); padding-left: 11px; margin-bottom: 14px; }
.r-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.r-tag { font-size: 0.72rem; padding: 4px 9px; border-radius: 999px; border: 1px solid var(--border); color: var(--text-dim); background: var(--surface-2); }
.r-pal { display: flex; gap: 7px; }
.r-sw { flex: 1; text-align: center; }
.r-sw-c { height: 34px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.14); }
.r-sw span { font-family: var(--font-mono); font-size: 0.56rem; color: var(--text-faint); }

/* generic result grids */
.r-grid { display: grid; gap: 16px; }
.r-grid.emotes { grid-template-columns: repeat(6, 1fr); }
.r-grid.two { grid-template-columns: 1fr 1fr; }
.r-grid.three { grid-template-columns: repeat(3, 1fr); }
.r-grid.emotes .r-emote { border-radius: 16px; font-size: 1.4rem; }
.r-thumb { aspect-ratio: 16/9; border-radius: 14px; display: grid; place-items: center; position: relative; overflow: hidden; border: 1px solid var(--border); }
.r-thumb::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 25% 20%, rgba(255,255,255,0.25), transparent 55%); }
.rt-text { font-family: var(--font-display); font-weight: 800; color: #fff; font-size: 1.1rem; text-align: center; padding: 12px; position: relative; z-index: 1; text-shadow: 0 2px 12px rgba(0,0,0,0.5); }
.r-vt { aspect-ratio: 3/4; border-radius: 14px; display: grid; place-items: center; border: 1px solid var(--border); }
.r-vt span { font-family: var(--font-display); font-weight: 800; font-size: 3rem; color: rgba(255,255,255,0.92); }
.r-alerts { display: flex; flex-direction: column; gap: 12px; }
.r-alert { padding: 16px 20px; border-radius: 12px; color: #fff; font-weight: 700; }

/* live-backend result */
.r-cohesive.api { color: #7dd3fc; border-color: rgba(125,211,252,0.4); background: rgba(125,211,252,0.12); }
.api-note { background: rgba(245,158,11,0.12); border: 1px solid rgba(245,158,11,0.4); color: #fcd34d; font-size: 0.84rem; padding: 11px 14px; border-radius: 10px; margin-bottom: 16px; }
.api-note code { font-family: var(--font-mono); font-size: 0.82em; background: rgba(0,0,0,0.32); padding: 1px 6px; border-radius: 5px; }
.r-apikit { display: grid; grid-template-columns: 1.3fr 1fr; gap: 22px; align-items: start; }
.r-assets { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.ins-result { margin-bottom: 22px; }
.ins-result:empty { display: none; }
.ins-result .r-assets { grid-template-columns: repeat(4, 1fr); }
.ins-result .r-asset img { aspect-ratio: 1; object-fit: cover; }
@media (max-width: 760px) { .ins-result .r-assets { grid-template-columns: repeat(2, 1fr); } }
.r-asset img { width: 100%; border-radius: 12px; border: 1px solid var(--border); background: var(--surface-2); display: block; }
.r-asset figcaption { font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-faint); margin-top: 7px; text-transform: uppercase; letter-spacing: 0.04em; }
.r-dna .r-persona { font-style: italic; font-size: 0.95rem; border-left: 2px solid var(--violet); padding-left: 12px; margin-bottom: 14px; }
.r-tag.mood2 { color: var(--violet-bright); border-color: rgba(168,88,247,0.35); background: rgba(168,88,247,0.1); }
@media (max-width: 860px) { .r-apikit { grid-template-columns: 1fr; } }

/* ---------- studios grid ---------- */
.studios-grid { max-width: var(--page-max); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.studio-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 22px; transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s; }
.studio-card:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: 0 18px 44px -26px rgba(168,88,247,0.5); }
.sc-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.sc-ico { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 1.3rem; color: #fff; background: linear-gradient(135deg, var(--a), var(--b)); }
.sc-ico svg { width: 24px; height: 24px; }
.studio-card h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.15rem; }
.studio-card p { color: var(--text-dim); font-size: 0.9rem; margin-top: 5px; }
.badge { font-size: 0.64rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; padding: 4px 9px; border-radius: 999px; color: var(--text-faint); border: 1px solid var(--border); background: var(--surface-2); }
.badge-live { color: var(--mint); border-color: rgba(0,255,163,0.4); background: rgba(0,255,163,0.1); }
.badge-beta, .badge-new { color: #7dd3fc; border-color: rgba(125,211,252,0.4); background: rgba(125,211,252,0.1); }

/* ---------- chips + template/asset grids ---------- */
.chips2 { max-width: var(--page-max); margin: 0 auto 20px; display: flex; flex-wrap: wrap; gap: 8px; }
.chip2 { padding: 8px 16px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-dim); font-size: 0.86rem; font-weight: 500; cursor: pointer; transition: all 0.15s; }
.chip2:hover { color: #fff; }
.chip2.active { color: #fff; background: rgba(168,88,247,0.18); border-color: var(--violet); }
.tpl2-grid { max-width: var(--page-max); margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.tpl2 { cursor: pointer; }
.tpl2 .tpl-art { height: 150px; border-radius: 14px; border: 1px solid var(--border); position: relative; overflow: hidden; background: linear-gradient(135deg, color-mix(in srgb,var(--a) 70%,#0a0813), color-mix(in srgb,var(--b) 55%,#0a0813)); transition: transform 0.2s; }
.tpl2 .tpl-art::after { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at 25% 18%, rgba(255,255,255,0.22), transparent 55%); }
.tpl2:hover .tpl-art { transform: translateY(-3px); }
.tpl2 h4 { font-size: 0.92rem; font-weight: 500; margin-top: 10px; }
.tpl2-c { font-size: 0.78rem; color: var(--text-faint); }

/* ---------- search ---------- */
.searchbox { max-width: var(--page-max-narrow); margin: 0 auto 16px; display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--border-strong); color: var(--text-faint); }
.searchbox input { flex: 1; background: none; border: 0; outline: none; color: var(--text); font-size: 1.05rem; }
.search-chips { max-width: var(--page-max-narrow); margin: 0 auto 26px; display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- community ---------- */
.comm-grid { max-width: var(--page-max); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.comm-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 16px; transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s; }
.comm-card:hover { transform: translateY(-3px); border-color: var(--border-strong); box-shadow: 0 18px 44px -26px rgba(168,88,247,0.5); }
.comm-art { height: 150px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px; }
.comm-art span { font-family: var(--font-display); font-weight: 800; font-size: 2.4rem; color: #fff; }
.comm-meta { display: flex; flex-direction: column; margin-bottom: 14px; }
.comm-meta b { font-family: var(--font-display); }
.comm-meta span { font-size: 0.82rem; color: var(--text-faint); }

/* ---------- brand manager ---------- */
.brand-grid { max-width: var(--page-max); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.brand-card { text-align: left; background: radial-gradient(130% 90% at 0% 0%, color-mix(in srgb, var(--k1, #8a3ffc) 9%, var(--surface)), var(--surface)); border: 1px solid var(--border); border-radius: 16px; padding: 18px; cursor: pointer; transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s; }
.brand-card:hover { transform: translateY(-3px); border-color: color-mix(in srgb, var(--k1, #8a3ffc) 45%, var(--border)); box-shadow: 0 16px 40px -28px rgba(0,0,0,0.8); }
.brand-card.active { border-color: var(--violet); box-shadow: 0 0 0 1px var(--violet), 0 18px 40px -24px rgba(168,88,247,0.6); }
.brand-top { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.brand-logo { width: 42px; height: 42px; flex: none; border-radius: 12px; display: grid; place-items: center; font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; background: var(--surface-3); border: 1px solid color-mix(in srgb, var(--k1, #8a3ffc) 38%, transparent); color: color-mix(in srgb, var(--k1, #8a3ffc) 68%, #ffffff); }
.brand-id { min-width: 0; }
.brand-top b { font-family: var(--font-display); display: block; }
.brand-top span { font-size: 0.8rem; color: var(--text-faint); }
.brand-active { margin-left: auto; align-self: flex-start; font-size: 0.66rem; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--mint); border: 1px solid rgba(0,255,163,0.4); background: rgba(0,255,163,0.1); padding: 4px 9px; border-radius: 999px; }
.brand-persona { font-style: italic; font-size: 0.88rem; color: var(--text-dim); line-height: 1.5; margin-bottom: 16px; }
.brand-pal { display: flex; gap: 6px; }
.brand-pal span { flex: 1; height: 26px; border-radius: 8px; border: 1px solid rgba(255,255,255,0.07); box-shadow: inset 0 1px 0 rgba(255,255,255,0.12); }

/* single unified Brand DNA hero */
.brand-hero { max-width: var(--page-max); margin: 0 auto; display: flex; gap: 26px; align-items: flex-start; background: radial-gradient(130% 90% at 0% 0%, color-mix(in srgb, var(--k1, #8a3ffc) 13%, var(--surface)), var(--surface)); border: 1px solid color-mix(in srgb, var(--k1, #8a3ffc) 30%, var(--border)); border-radius: 22px; padding: 30px; box-shadow: 0 0 0 1px var(--violet), 0 26px 64px -34px rgba(168,88,247,0.5); }
.bh-logo { width: 80px; height: 80px; flex: none; border-radius: 20px; display: grid; place-items: center; font-family: var(--font-display); font-weight: 800; font-size: 2.1rem; background: var(--surface-3); border: 1px solid color-mix(in srgb, var(--k1, #8a3ffc) 42%, transparent); color: color-mix(in srgb, var(--k1, #8a3ffc) 70%, #ffffff); }
.bh-main { flex: 1; min-width: 0; }
.bh-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.bh-name { font-family: var(--font-display); font-size: 1.7rem; margin: 0; }
.bh-head .brand-active { margin-left: 0; }
.bh-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 16px; }
.bh-tags span { font-size: 0.74rem; font-weight: 600; color: var(--text-dim); background: var(--surface-3); border: 1px solid var(--border); padding: 4px 12px; border-radius: 999px; text-transform: capitalize; }
.brand-hero .brand-persona { font-size: 1rem; max-width: 660px; }
.brand-hero .brand-pal { max-width: 440px; margin-bottom: 14px; }
.bh-moods { font-size: 0.8rem; color: var(--text-faint); text-transform: capitalize; }
@media (max-width: 640px){ .brand-hero { flex-direction: column; gap: 18px; } }

/* ---------- settings / empty / upscale ---------- */
.settings { max-width: var(--page-max-narrow); margin: 0 auto; }
.set-row { display: flex; justify-content: space-between; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--border); }
.set-row span { color: var(--text-dim); }
.settings .btn { margin-top: 22px; }
.set-edit .btn { margin-top: 0; }
.empty { max-width: 560px; margin: 30px auto; text-align: center; border: 1.5px dashed var(--border-strong); border-radius: 18px; padding: 50px 24px; }
.empty-ico { margin-bottom: 14px; color: var(--text-faint); line-height: 0; }
.empty-ico svg { width: 44px; height: 44px; }
.empty h3 { font-family: var(--font-display); font-size: 1.3rem; margin-bottom: 8px; }
.empty p { color: var(--text-dim); max-width: 380px; margin: 0 auto 20px; }
.upscale { max-width: var(--page-max-narrow); margin: 0 auto; }
.dropzone { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 50px; border: 1.5px dashed var(--border-strong); border-radius: 18px; cursor: pointer; text-align: center; margin-bottom: 22px; }
.dropzone:hover { border-color: var(--violet); }
.dz-ico { font-size: 2rem; margin-bottom: 8px; }
.dropzone span { color: var(--text-faint); font-size: 0.85rem; }
.muted { color: var(--text-faint); }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .studios-grid, .comm-grid, .brand-grid, .tpl2-grid { grid-template-columns: repeat(2, 1fr); }
  .r-kit { grid-template-columns: 1fr; } .r-col { border-right: 0; border-bottom: 1px solid var(--border); }
  .r-grid.emotes { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 860px) { .menu-btn { display: grid; } }
@media (max-width: 620px) {
  .studios-grid, .comm-grid, .brand-grid, .tpl2-grid { grid-template-columns: 1fr; }
  .r-grid.two, .r-grid.three { grid-template-columns: 1fr; }
}

/* ---------- Studio option controls ---------- */
.opts-bar { max-width: var(--page-max); margin: 0 auto 18px; display: flex; flex-wrap: wrap; gap: 20px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; }
.opt { display: flex; align-items: center; gap: 10px; }
.opt-l { font-size: 0.8rem; color: var(--text-faint); font-weight: 600; white-space: nowrap; }
.opt-seg { display: inline-flex; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 3px; }
.opt-b { padding: 5px 13px; border: 0; background: none; color: var(--text-dim); font-size: 0.82rem; font-weight: 600; border-radius: 999px; cursor: pointer; }
.opt-b.active { background: var(--violet); color: #fff; }
.opt-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.opt-c { padding: 6px 12px; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-dim); font-size: 0.8rem; cursor: pointer; transition: all 0.15s; }
.opt-c:hover { color: #fff; }
.opt-c.active { color: #fff; background: rgba(168,88,247,0.18); border-color: var(--violet); }
.opt-text { flex: 1; min-width: 220px; }
.opt-input { flex: 1; padding: 8px 12px; border-radius: 9px; border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); outline: none; font-size: 0.88rem; }
.opt-input:focus { border-color: var(--violet); }

/* example prompt chips (empty state) */
.ex-chips { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 20px; }
.ex-l { font-size: 0.82rem; color: var(--text-faint); align-self: center; }
.ex-chip { font-size: 0.82rem; color: var(--text-dim); background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 6px 13px; cursor: pointer; transition: all 0.15s; }
.ex-chip:hover { color: #fff; border-color: var(--violet); background: rgba(168,88,247,0.16); }

/* per-tile download + variations */
.r-tilewrap { position: relative; }
.tile-dl { position: absolute; top: 8px; right: 8px; width: 30px; height: 30px; border-radius: 8px; border: 0; background: rgba(0,0,0,0.55); color: #fff; cursor: pointer; opacity: 0; transition: opacity 0.15s; backdrop-filter: blur(4px); font-size: 0.95rem; }
.r-tilewrap:hover .tile-dl { opacity: 1; }
.r-grid.one { grid-template-columns: minmax(0, 520px); }
.r-vt { position: relative; }
.r-vt-exp { position: absolute; bottom: 8px; left: 0; right: 0; text-align: center; font-size: 0.7rem; color: rgba(255,255,255,0.92); font-weight: 600; }
.r-overlay.scene { grid-template-columns: 1fr; grid-template-rows: 1fr; }
.ro-scene { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; gap: 6px; position: relative; }
.ro-big { font-family: var(--font-display); font-weight: 800; font-size: 1.6rem; color: #fff; text-shadow: 0 2px 14px rgba(0,0,0,0.5); }
.ro-sub { font-size: 0.72rem; color: rgba(255,255,255,0.85); }

/* ---------- dashboard polish: notifications, settings, mobile, empty ---------- */
.notif-wrap, #bellBtn { position: relative; }
.notif-dot { position: absolute; top: 7px; right: 7px; width: 8px; height: 8px; border-radius: 50%; background: #ec4899; box-shadow: 0 0 0 2px #07060f; }
.notif-dot.seen { display: none; }
.notif-menu { position: fixed; top: 60px; right: 20px; width: 320px; background: #110f1b; border: 1px solid var(--border-strong); border-radius: 14px; padding: 8px; box-shadow: 0 24px 60px -20px rgba(0,0,0,0.75); display: none; z-index: 60; }
.notif-menu.open { display: block; }
.nm-head { font-family: var(--font-display); font-weight: 600; font-size: 0.92rem; padding: 8px 10px; }
.nm-item { display: flex; gap: 11px; padding: 10px; border-radius: 10px; cursor: default; }
.nm-item:hover { background: var(--surface-2); }
.nm-item b { font-size: 0.88rem; display: block; }
.nm-item span:not(.nm-dot) { font-size: 0.78rem; color: var(--text-faint); }
.nm-dot { flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%; margin-top: 6px; background: var(--text-faint); }
.nm-dot.live { background: var(--mint); } .nm-dot.deal { background: #f59e0b; }

.set-edit { display: flex; gap: 10px; align-items: center; }
.set-edit .opt-input { max-width: 240px; }
.set-link { color: var(--violet-bright); font-weight: 600; }
.set-link:hover { text-decoration: underline; }

.grid-empty { max-width: var(--page-max); margin: 8px auto 0; color: var(--text-faint); text-align: center; padding: 30px; }

.side-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,0.55); backdrop-filter: blur(2px); opacity: 0; pointer-events: none; transition: opacity 0.2s; z-index: 70; }
.side-backdrop.show { opacity: 1; pointer-events: auto; }
@media (min-width: 861px) { .side-backdrop { display: none; } }

/* Thumbnail & VTuber results use showcase portfolio art as cover */
.r-thumb .tpl-img, .r-vt .tpl-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.r-thumb::after { z-index: 1; }
.r-cover-scrim { position: absolute; inset: 0; z-index: 1; background: linear-gradient(180deg, rgba(0,0,0,0.12), rgba(0,0,0,0.62)); }
.r-thumb .rt-text { z-index: 2; }
.r-vt .r-vt-exp { z-index: 2; }

/* ---------- Admin · Model Inventory ---------- */
.admin-keyrow { max-width: var(--page-max); margin: 0 auto 18px; display: flex; align-items: center; gap: 10px; }
.admin-keyrow .opt-input { flex: 1; max-width: 460px; }
.admin-keyrow .tp-lbl { white-space: nowrap; }
.adm-group { max-width: var(--page-max); margin: 0 auto 26px; }
.adm-h { font-family: var(--font-display); font-size: 1.05rem; text-transform: capitalize; margin: 0 0 12px; }
/* Admin control-center KPI cards */
.adm-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 4px 0 14px; }
.adm-kpi { background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 14px; padding: 16px 18px; display: flex; flex-direction: column; gap: 5px; }
.adm-kpi-l { font-size: 0.8rem; color: var(--text-dim); }
.adm-kpi-v { font-family: var(--font-display); font-weight: 700; font-size: 1.75rem; line-height: 1; }
.adm-kpi-s { font-size: 0.78rem; color: var(--text-faint); }
.adm-meta { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 6px; }
.adm-plans { display: flex; gap: 8px; flex-wrap: wrap; }
.adm-planpill { background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 5px 11px; font-size: 0.8rem; color: var(--text-dim); }
.adm-bill { font-size: 0.82rem; color: var(--text-dim); }
.adm-bill.on b { color: var(--mint); }
.adm-bill.off b { color: #fbbf24; }
@media (max-width: 900px) { .adm-kpis { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .adm-kpis { grid-template-columns: 1fr; } }
.adm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.adm-card { background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 15px; display: flex; flex-direction: column; gap: 7px; }
.adm-card.adm-off { opacity: 0.6; }
.adm-top { display: flex; align-items: center; gap: 8px; }
.adm-top b { font-size: 0.98rem; }
.adm-slug { font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-faint); word-break: break-all; }
.adm-desc { font-size: 0.82rem; color: var(--text-dim); line-height: 1.45; margin: 2px 0 4px; flex: 1; }
.adm-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid var(--border); padding-top: 10px; }
.adm-status { font-size: 0.74rem; font-weight: 600; }
.adm-status.on { color: var(--mint); }
.adm-status.off { color: var(--text-faint); }
.adm-toggle { display: inline-flex; align-items: center; gap: 6px; font-size: 0.78rem; color: var(--text-dim); cursor: pointer; }
.adm-toggle input { accent-color: var(--violet); width: 15px; height: 15px; }
.adm-add { max-width: var(--page-max); margin: 6px auto 0; background: var(--surface); border: 1px solid var(--border); border-radius: 14px; padding: 16px; }
.adm-addrow { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.adm-addrow .opt-input { flex: 1; min-width: 200px; }
.adm-addrow .opt-kind { flex: 0 0 110px; min-width: 0; }
.api-note { max-width: var(--page-max); margin: 0 auto 18px; background: rgba(125,211,252,0.1); border: 1px solid rgba(125,211,252,0.3); color: #cfeffb; border-radius: 12px; padding: 11px 14px; font-size: 0.85rem; }
.api-note code { font-family: var(--font-mono); background: rgba(255,255,255,0.08); padding: 1px 5px; border-radius: 5px; }
.btn-sm { padding: 8px 14px; font-size: 0.85rem; }

.r-loading-sub { font-size: 0.8rem; color: var(--text-faint); }

/* ---------- Pricing page ---------- */
.pricing { max-width: var(--page-max); margin: 0 auto; }
.pr-toggle { display: inline-flex; gap: 4px; margin: 0 auto 26px; padding: 4px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; }
.pricing .pr-toggle { display: flex; width: fit-content; }
.pr-tg { display: inline-flex; align-items: center; gap: 7px; padding: 8px 18px; border: 0; border-radius: 999px; background: transparent; color: var(--text-dim); font: inherit; font-size: 0.88rem; font-weight: 600; cursor: pointer; transition: background 0.15s, color 0.15s; }
.pr-tg.on { background: var(--violet); color: #fff; }
.pr-tg i { font-style: normal; font-size: 0.7rem; font-weight: 700; color: #34d399; }
.pr-tg.on i { color: #d1fae5; }
.pr-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; align-items: stretch; }
.pr-card { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: 18px; padding: 22px 18px; transition: border-color 0.18s, transform 0.18s, box-shadow 0.18s; }
.pr-card:hover { transform: translateY(-3px); border-color: var(--border-strong); }
.pr-best { border-color: var(--violet); box-shadow: 0 0 0 1px var(--violet), 0 24px 60px -30px rgba(138,63,252,0.7); }
.pr-current { box-shadow: inset 0 0 0 1px rgba(255,255,255,0.18); }
.pr-badge { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); font-size: 0.64rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #fff; background: linear-gradient(135deg, #b14bff, #ff2d9b); padding: 4px 12px; border-radius: 999px; }
.pr-name { font-family: var(--font-display); font-size: 1.15rem; font-weight: 800; margin: 0 0 8px; }
.pr-price { font-size: 2.1rem; font-weight: 800; letter-spacing: -0.02em; color: #fff; line-height: 1; }
.pr-price span { font-size: 0.9rem; font-weight: 500; color: var(--text-faint); }
.pr-sub { font-size: 0.74rem; color: var(--text-faint); margin-top: 6px; min-height: 16px; }
.pr-credits { margin-top: 12px; font-size: 0.85rem; font-weight: 600; color: var(--violet-bright); }
.pr-cta { width: 100%; justify-content: center; margin-top: 14px; }
.pr-feats { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.pr-feats li { position: relative; padding-left: 22px; font-size: 0.82rem; color: var(--text-dim); line-height: 1.4; }
.pr-feats li::before { content: "✓"; position: absolute; left: 0; top: 0; color: #34d399; font-weight: 800; }
.pr-packs-wrap { margin-top: 34px; text-align: center; }
.pr-h { font-size: 1rem; font-weight: 700; margin: 0 0 14px; }
.pr-packs { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.pr-pack { display: inline-flex; align-items: center; gap: 10px; background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 14px; padding: 12px 18px; color: var(--text); font: inherit; cursor: pointer; transition: border-color 0.15s, background 0.15s, transform 0.15s; }
.pr-pack:hover { border-color: var(--violet); background: var(--surface-3); transform: translateY(-2px); }
.pr-pack b { font-weight: 600; font-size: 0.9rem; }
.pr-pack-price { font-weight: 800; color: #fff; }
.pr-pack i { font-style: normal; font-size: 0.68rem; font-weight: 700; color: #34d399; background: rgba(52,211,153,0.14); padding: 2px 7px; border-radius: 999px; }
.pr-fine { margin-top: 18px; font-size: 0.78rem; color: var(--text-faint); }
.pr-tagline { font-size: 0.78rem; color: var(--text-faint); margin: 2px 0 10px; }
.pr-output { font-size: 0.78rem; color: var(--text-dim); margin-top: 4px; }
.pr-inherit { font-size: 0.78rem; font-weight: 700; color: var(--text); margin: 16px 0 2px; }
.pr-includes { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px 18px; margin: 26px auto 0; max-width: var(--page-max); padding: 16px; background: var(--surface-2); border-radius: 14px; }
.pr-includes-l { font-size: 0.74rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; color: var(--text-faint); }
.pr-inc { font-size: 0.84rem; color: var(--text-dim); }
.pr-faq { max-width: var(--page-max-narrow); margin: 36px auto 0; }
.pr-faq-q { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 13px 16px; margin-bottom: 10px; }
.pr-faq-q summary { cursor: pointer; font-weight: 600; color: var(--text); font-size: 0.9rem; }
.pr-faq-q p { color: var(--text-dim); margin: 10px 0 0; font-size: 0.86rem; line-height: 1.5; }
/* checkout journey modal */
.co-box { width: 440px; text-align: center; }
.co-box .modal-head { text-align: left; }
.co-price { margin-top: 4px; }
.co-amt { font-size: 2.6rem; font-weight: 800; color: #fff; letter-spacing: -0.02em; }
.co-per { font-size: 1rem; color: var(--text-faint); }
.co-billed { font-size: 0.82rem; color: var(--text-faint); margin-top: 2px; }
.co-cyc { display: inline-flex; gap: 4px; margin: 16px auto 0; padding: 4px; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; }
/* "what you get" — left-aligned block, divided from the price/cycle zone above */
.co-what { text-align: left; border-top: 1px solid var(--border); margin-top: 18px; padding-top: 16px; }
.co-credits { font-size: 0.95rem; font-weight: 700; color: var(--violet-bright); }
.co-output { font-size: 0.8rem; color: var(--text-faint); margin-top: 2px; }
.co-inherit { font-size: 0.78rem; font-weight: 700; color: var(--text); margin: 14px 0 8px; }
.co-feats { margin: 8px 0 0; }
.co-go { width: 100%; justify-content: center; margin-top: 18px; }
.co-trust { font-size: 0.72rem; color: var(--text-faint); margin-top: 12px; }
@media (max-width: 900px) { .pr-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .pr-grid { grid-template-columns: 1fr; } }

/* ---------- Refer & earn / Partner ---------- */
.ref-wrap { max-width: var(--page-max-narrow); margin: 0 auto; display: flex; flex-direction: column; gap: 16px; }
.ref-card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 20px; }
.ref-lead { font-size: 0.92rem; color: var(--text-dim); line-height: 1.5; margin: 0 0 14px; }
.ref-lead b { color: #fff; }
.ref-linkrow { display: flex; gap: 8px; }
.ref-linkrow .opt-input { flex: 1; font-family: var(--font-mono); font-size: 0.82rem; }
.ref-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 16px; }
.ref-stat { background: var(--surface-2); border-radius: 12px; padding: 14px; text-align: center; }
.ref-stat b { display: block; font-size: 1.5rem; font-weight: 800; color: #fff; }
.ref-stat span { font-size: 0.74rem; color: var(--text-faint); }
.ref-partner { border-color: rgba(245,200,66,0.4); box-shadow: inset 0 0 0 1px rgba(245,200,66,0.25); }
.ref-partner-cta { border-style: dashed; }
.ref-partner-h { font-family: var(--font-display); font-size: 1.05rem; font-weight: 800; margin-bottom: 8px; }
.linklike { background: none; border: 0; color: var(--violet-bright); font: inherit; cursor: pointer; padding: 0; }
.linklike:hover { text-decoration: underline; }
.adm-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.tf-badge.partner { background: rgba(245,200,66,0.18); color: #f5c842; border-color: rgba(245,200,66,0.4); }
@media (max-width: 620px) { .ref-linkrow { flex-direction: column; } }
