/* App shell: sidebar + main area (Studio and Billing) */
body.app-body { overflow: hidden; height: 100vh; height: 100dvh; }
.app { display: grid; grid-template-columns: 248px minmax(0, 1fr); height: 100vh; height: 100dvh;
  /* the sidebar is added by shell.js after sign-in is checked: keep its column (and colour) reserved meanwhile */
  background: linear-gradient(90deg, var(--bg-2) 247px, var(--line) 247px 248px, transparent 248px); }
.app > .app-main { grid-column: 2; grid-row: 1; }
.app > .side-nav { grid-column: 1; grid-row: 1; }
.side-nav { display: flex; flex-direction: column; gap: 18px; padding: 16px 12px 12px; background: var(--bg-2); border-right: 1px solid var(--line); overflow-y: auto; }
.side-nav .logo { padding: 4px 8px 6px; font-size: 17px; }
.side-nav nav { display: grid; gap: 2px; }
.side-nav nav a { display: flex; align-items: center; gap: 11px; padding: 9px 10px; border-radius: 10px; text-decoration: none; color: var(--text-2); font-weight: 500; font-size: 14.5px; border: 1px solid transparent; transition: background-color .15s ease, color .15s ease; }
.side-nav nav a .i { color: var(--text-3); transition: color .15s ease; }
@media (hover: hover) { .side-nav nav a:hover { background: var(--surface); color: var(--text); } }
.side-nav nav a.on { color: var(--text); background: var(--surface-2); border-color: var(--line-2); box-shadow: inset 3px 0 0 var(--acc); }
.side-nav nav a.on .i { color: #9fc0ff; }
.plan-card { margin-top: auto; padding: 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); display: grid; gap: 10px; }
.plan-card-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 14px; }
.plan-credits { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; color: var(--text-2); }
.meter { height: 6px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.meter i { display: block; height: 100%; width: 0; border-radius: 99px; background: var(--acc);  transition: width .6s var(--ease-out); }
.plan-sub { font-size: 12.5px; color: var(--text-3); margin-top: -2px; }
.acct { display: flex; align-items: center; gap: 8px; padding: 4px 6px 0; }
.acct-email { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; color: var(--text-3); }
.acct-out { width: 32px; height: 32px; border-radius: 8px; border: 0; background: none; color: var(--text-3); cursor: pointer; display: grid; place-items: center; }
.acct-out:hover { background: var(--surface); color: var(--text); }

.app-main { display: flex; flex-direction: column; min-width: 0; height: 100%; overflow: hidden; }
.app-top { display: flex; align-items: center; gap: 12px; padding: 12px 22px; border-bottom: 1px solid var(--line); background: rgba(8, 9, 13, .6); backdrop-filter: blur(10px); min-height: 60px; }
.app-title { font-size: 16px; font-weight: 600; font-stretch: 100%; letter-spacing: 0; }
.app-top .grow { flex: 1; }
.menu-btn { display: none; width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--text); place-items: center; cursor: pointer; }
.app-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; position: relative; }
.app-scroll::before { content: ""; position: absolute; inset: 0 0 auto; height: 420px; pointer-events: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='34' height='34'%3E%3Cpath d='M0 .5H34M.5 0V34' stroke='%23fff' stroke-opacity='.035'/%3E%3Crect x='9' y='10.5' width='16' height='16' rx='3.5' fill='%23000' fill-opacity='.55'/%3E%3Crect x='9' y='8.5' width='16' height='16' rx='3.5' fill='%23fff' fill-opacity='.055'/%3E%3Cpath d='M12 9.5h10' stroke='%23fff' stroke-opacity='.14' stroke-linecap='round'/%3E%3C/svg%3E"); background-size: 34px 34px; -webkit-mask-image: linear-gradient(#000, transparent); mask-image: linear-gradient(#000, transparent); }
.view { position: relative; width: min(1180px, 100% - 40px); margin: 0 auto; padding: 32px 0 80px; }
.view[hidden] { display: none; }
.view.full { width: 100%; padding: 0; height: 100%; }
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; background: none; }
  .app > .app-main { grid-column: 1; }
  .side-nav { position: fixed; z-index: 120; inset: 0 auto 0 0; width: 268px; transform: translateX(-102%); transition: transform .28s var(--ease-out); box-shadow: var(--shadow-lg); }
  body.nav-open .side-nav { transform: none; }
  .menu-btn { display: grid; }
  .app-top { padding: 10px 14px; gap: 8px; }
}
@media (max-width: 420px) {
  .app-top .btn { display: none; }
  .app-title { font-size: 15px; }
  .create-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .view { width: calc(100% - 28px); padding-top: 22px; }
}

/* ---------- create view ---------- */
.create-head { max-width: 980px; margin: 18px auto 20px; display: flex; align-items: center; gap: 16px; }
.create-head .brick { --s: 11px; }
.create-head h1 { font-size: clamp(28px, 3.6vw, 42px); }
.create-head p { color: var(--text-2); margin-top: 4px; }
.prompt-card { max-width: 980px; margin: 0 auto; border-radius: 18px; background: rgba(22, 22, 24, .92); border: 1px solid var(--line-2); box-shadow: 0 4px 0 #050506, var(--shadow-lg); backdrop-filter: blur(8px); }
.tool-tabs { display: flex; gap: 2px; padding: 8px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tool-tabs::-webkit-scrollbar { display: none; }
.tool-tabs button { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border-radius: 9px; border: 1px solid transparent; background: none; color: var(--text-2); font-weight: 500; font-size: 14px; cursor: pointer; white-space: nowrap; transition: background-color .15s ease, color .15s ease; }
.tool-tabs button .i { color: var(--text-3); }
@media (hover: hover) { .tool-tabs button:hover { background: var(--surface-2); color: var(--text); } }
.tool-tabs button.on { background: var(--surface-3); border-color: var(--line-2); color: var(--text); box-shadow: inset 0 -2px 0 var(--tc, var(--acc)); }
.tool-tabs button.on .i { color: var(--tc, var(--acc)); }
.tool-tabs [data-t="thumbnail"] { --tc: #ffcc33; } .tool-tabs [data-t="icon"] { --tc: #e5483b; } .tool-tabs [data-t="ad"] { --tc: #4c9bff; } .tool-tabs [data-t="model"] { --tc: #3fbf6a; } .tool-tabs [data-t="sfx"] { --tc: #b98cff; }
.prompt-body { padding: 14px 16px 0; }
.prompt-body textarea { display: block; width: 100%; min-height: 136px; max-height: min(320px, 45vh); border: 0; background: none; color: var(--text); font: 400 17.5px/1.5 var(--f); resize: none; outline: none; padding: 2px 0; overflow-y: hidden; scrollbar-width: thin; scrollbar-color: #3a3a3f transparent; }
.prompt-body textarea::placeholder { color: #6b7385; }
.suggest { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 0 12px; }
.opt-panel { padding: 12px 16px; border-top: 1px solid var(--line); display: grid; gap: 12px; }
.opt-panel[hidden] { display: none; }
.prompt-foot { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 10px 12px; border-top: 1px solid var(--line); }
.pill-btn { display: inline-flex; align-items: center; gap: 7px; padding: 7px 11px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text-2); font-size: 13.5px; font-weight: 500; cursor: pointer; transition: border-color .15s ease, color .15s ease, background-color .15s ease; }
.pill-btn:hover { color: var(--text); border-color: var(--line-2); }
.pill-btn.on { color: #fff; border-color: rgba(255, 204, 51, .5); background: var(--acc-soft); }
.pill-btn .lock { font-size: 11px; font-weight: 700; color: var(--amber); }
.pill-btn b { font-weight: 600; color: var(--text); }
.mini-seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.mini-seg button { border: 0; background: none; color: var(--text-2); font: 500 13.5px var(--f); padding: 5px 10px; border-radius: 7px; cursor: pointer; }
.mini-seg button.on { background: var(--surface-3); color: var(--text); }
.mini-seg.wrap { flex-wrap: wrap; }
/* see-through game UI pieces sit on a checkerboard, the usual sign for "see-through here" */
.checker { background-color: #e9e9ee; background-image: linear-gradient(45deg, #d4d4dc 25%, transparent 25%), linear-gradient(-45deg, #d4d4dc 25%, transparent 25%), linear-gradient(45deg, transparent 75%, #d4d4dc 75%), linear-gradient(-45deg, transparent 75%, #d4d4dc 75%); background-size: 20px 20px; background-position: 0 0, 0 10px, 10px -10px, -10px 0; }
.res.ui img, .lib-item.ui img, .em-pic.ui img { object-fit: contain; padding: 6%; }
.res.ui.wide { aspect-ratio: 16/9; }
.mini-seg button .lock { margin-left: 4px; font-size: 11px; color: var(--amber); }
.foot-grow { flex: 1; }
.cost-label[hidden] { display: none; }
.cost-label { font-size: 13.5px; color: var(--text-3); display: inline-flex; align-items: center; gap: 6px; font-variant-numeric: tabular-nums; }
.uploads { display: grid; grid-template-columns: repeat(4, 76px); gap: 8px; }
.up-slot { width: 76px; aspect-ratio: 1; border-radius: 11px; border: 1.5px dashed rgba(255, 255, 255, .16); background: var(--surface-2); display: grid; place-items: center; cursor: pointer; color: var(--text-3); position: relative; overflow: hidden; transition: border-color .15s ease; }
.up-slot:hover { border-color: var(--acc); color: var(--text); }
.up-slot img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.up-slot .x { position: absolute; top: 3px; right: 3px; width: 22px; height: 22px; border-radius: 6px; background: rgba(0, 0, 0, .7); color: #fff; display: grid; place-items: center; z-index: 2; }
.looks { display: flex; flex-wrap: wrap; gap: 6px; }
.look { cursor: pointer; padding: 5px 11px; border-radius: 8px; font-weight: 800; font-size: 13px; color: #fff; -webkit-text-stroke: 3px #000; paint-order: stroke fill; border: 1px solid var(--line-2); transition: transform 160ms var(--ease-out); }
.look.on { box-shadow: 0 0 0 2px var(--acc-hi); }
.opt-row { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; }
.opt-row label.lbl, .opt-row span.lbl { font-size: 13px; color: var(--text-3); min-width: 90px; }
.opt-note { font-size: 13px; color: var(--text-3); }

.section-h { display: flex; justify-content: space-between; align-items: end; gap: 12px; margin: 40px 0 14px; }
.section-h h2 { font-size: 19px; font-stretch: 105%; letter-spacing: -0.01em; }
.section-h .muted { font-size: 13.5px; }
.results { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.results.sq { grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); }
.res { position: relative; border-radius: 14px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); aspect-ratio: 16/9; transition: border-color .15s ease, transform 160ms var(--ease-out); }
.res.sq { aspect-ratio: 1; }
@starting-style { .res { opacity: 0; transform: scale(.97); } }
.res { transition: opacity .35s var(--ease-out), transform .35s var(--ease-out), border-color .15s ease; }
.res:hover { border-color: var(--line-2); }
.res img { width: 100%; height: 100%; object-fit: cover; }
.res .lbl { position: absolute; left: 8px; top: 8px; z-index: 2; background: rgba(8, 9, 13, .82); border: 1px solid var(--line-2); font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 7px; }
.res .acts { position: absolute; inset: auto 0 0 0; display: flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; padding: 10px; background: linear-gradient(transparent, rgba(0, 0, 0, .75)); opacity: 0; transition: opacity .18s ease; }
.res:hover .acts, .res:focus-within .acts { opacity: 1; }
@media (hover: none) { .res .acts { opacity: 1; } }
.res.loading { display: grid; place-items: center; }
.res.loading::before { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .05) 50%, transparent 70%); background-size: 250% 100%; animation: shimmer 1.3s linear infinite; }
@keyframes shimmer { from { background-position: 150% 0; } to { background-position: -100% 0; } }
.res.snd { aspect-ratio: auto; grid-column: 1 / -1; display: flex; align-items: center; gap: 14px; padding: 14px 16px; }
.snd .play { flex: none; width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .2); background: var(--acc); color: var(--on-acc); cursor: pointer; display: grid; place-items: center; box-shadow: var(--glow); }
.snd .play .i { fill: currentColor; stroke: none; }
.snd-body { flex: 1; min-width: 0; }
.snd-body b { display: block; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.snd-body small { color: var(--text-3); font-size: 12.5px; }
.wave { display: flex; gap: 3px; align-items: center; height: 24px; margin: 4px 0; }
.wave i { flex: 1; max-width: 5px; border-radius: 3px; background: var(--surface-3); height: 30%; }
.wave i:nth-child(3n) { height: 70%; } .wave i:nth-child(4n+1) { height: 50%; } .wave i:nth-child(5n) { height: 90%; }
.snd.playing .wave i { background: var(--acc-hi); animation: eq .5s ease-in-out infinite alternate; }
.snd.playing .wave i:nth-child(2n) { animation-delay: .15s; } .snd.playing .wave i:nth-child(3n) { animation-delay: .3s; }
@keyframes eq { from { transform: scaleY(.35); } to { transform: scaleY(1); } }
.empty-state { border: 1px dashed var(--line-2); border-radius: 14px; padding: 28px; text-align: center; color: var(--text-3); }

.quick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 1000px) { .quick { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.qcard { text-align: left; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); padding: 0; overflow: hidden; cursor: pointer; color: var(--text); text-decoration: none; transition: border-color .15s ease, transform 160ms var(--ease-out); }
.qcard:active { --lift: 1px; }
@media (hover: hover) { .qcard:hover { border-color: rgba(255, 204, 51, .45); } }
.qcard .qv { aspect-ratio: 16/9; background: var(--bg-2); border-bottom: 1px solid var(--line); position: relative; overflow: hidden; display: grid; place-items: center; color: rgba(0, 0, 0, .72); background: var(--qc); box-shadow: inset 0 -5px 0 rgba(0, 0, 0, .18); }
.qcard:nth-child(1) { --qc: #ffcc33; } .qcard:nth-child(2) { --qc: #4c9bff; } .qcard:nth-child(3) { --qc: #3fbf6a; } .qcard:nth-child(4) { --qc: #e5483b; }
.qcard .qv::before { content: ""; position: absolute; inset: 0; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30'%3E%3Crect x='7' y='9.5' width='16' height='16' rx='3.5' fill='%23000' fill-opacity='.16'/%3E%3Crect x='7' y='7' width='16' height='16' rx='3.5' fill='%23fff' fill-opacity='.2'/%3E%3Cpath d='M10 8h10' stroke='%23fff' stroke-opacity='.45' stroke-linecap='round'/%3E%3C/svg%3E") 0 0 / 30px 30px; transition: transform .6s var(--ease-out); }
@media (hover: hover) { .qcard:hover .qv::before { transform: translateY(-3px); } .qcard:hover .qv .i { transform: translateY(-2px) scale(1.08); } }
.qcard .qv .i { transition: transform .35s var(--ease-out); }
.qcard .qv .i { position: relative; }
.qcard .qv img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .85; }
.qcard .qv .i { width: 34px; height: 34px; stroke-width: 1.6; }
.qcard b { display: block; padding: 12px 14px 2px; font-size: 15px; }
.qcard small { display: block; padding: 0 14px 14px; color: var(--text-3); font-size: 13px; }

/* panels used in game/score/billing views */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 20px; }
.card + .card { margin-top: 14px; }
.card h3 { font-size: 17px; font-stretch: 105%; letter-spacing: -0.01em; margin-bottom: 4px; }
.card > p.muted { margin-bottom: 14px; font-size: 14.5px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 860px) { .grid2 { grid-template-columns: 1fr; } }
.row { display: flex; gap: 8px; align-items: center; }
.row .input { flex: 1; min-width: 0; }
.gcard { margin-top: 14px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px; }
.gtop { display: flex; gap: 12px; align-items: center; }
.gtop img { width: 52px; height: 52px; border-radius: 12px; }
.gtop b { display: block; font-size: 16px; }
.gtop small { color: var(--text-3); font-size: 12.5px; }
.gbtns, .gideas { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }
.kit-colors { display: flex; gap: 8px; margin: 10px 0; }
.kc { width: 40px; height: 40px; border-radius: 10px; border: 2px solid var(--surface); box-shadow: 0 0 0 1px var(--line-2); cursor: pointer; }
.kit-state { font-size: 12px; font-weight: 600; color: var(--green); background: rgba(60, 207, 134, .12); padding: 2px 8px; border-radius: 999px; margin-left: 8px; }

/* 3D model view */
.modelview[hidden] { display: none; }
.mv-stage { position: relative; aspect-ratio: 16/10; border-radius: 16px; overflow: hidden; background: radial-gradient(circle at 50% 40%, #222226, #0d0d0f); border: 1px solid var(--line); display: grid; place-items: center; }
.mv-concept { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; opacity: .35; filter: blur(1px); }
.mv-progress { position: relative; width: min(360px, 80%); text-align: center; background: rgba(18, 21, 28, .9); border: 1px solid var(--line-2); padding: 18px; border-radius: 14px; }
.mv-bar { height: 8px; border-radius: 99px; background: var(--surface-3); overflow: hidden; }
.mv-bar i { display: block; height: 100%; border-radius: 99px; background: var(--acc); transition: width .8s ease; }
.mv-files { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.mv-how { margin-top: 12px; padding: 12px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); color: var(--text-2); font-size: 14.5px; }
model-viewer { width: 100%; height: 100%; display: block; }

/* library */
.lib-filters { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 16px; }
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.lib-item { position: relative; border-radius: 12px; overflow: hidden; background: var(--surface); border: 1px solid var(--line); aspect-ratio: 16/9; cursor: pointer; }
.lib-item.sq { aspect-ratio: auto; }
.lib-item.sq img { aspect-ratio: 16/9; object-fit: contain; background: var(--bg-2); }
.lib-item img { width: 100%; height: 100%; object-fit: cover; }
.lib-item .lbl { position: absolute; left: 8px; bottom: 8px; font-size: 11.5px; font-weight: 600; padding: 2px 7px; border-radius: 6px; background: rgba(8, 9, 13, .85); border: 1px solid var(--line-2); }
.lib-item.snd { display: grid; place-items: center; color: var(--acc); }
.qcard:nth-child(1) { --qc: #ffcc33; } .qcard:nth-child(2) { --qc: #4c9bff; } .qcard:nth-child(3) { --qc: #3fbf6a; } .qcard:nth-child(4) { --qc: #e5483b; }
.qcard .qv .i { position: relative; }

/* billing page */
.credit-box { position: relative; overflow: hidden; isolation: isolate; border-radius: 18px; border: 1px solid var(--line-2); background: var(--surface); padding: 22px; display: grid; gap: 14px; }
.credit-box::before { content: none; }
.credit-box .ct { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.credit-box .big { font-weight: 800; font-stretch: 110%; font-size: 34px; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.credit-box .big small { font-size: 16px; color: var(--text-3); font-weight: 500; }
.credit-box .meter { height: 10px; }
.bill-h { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin: 36px 0 16px; }
.bill-h h2 { font-size: 22px; }

/* modals specific to the app */
.feed-modal .phone { margin-top: 10px; }

/* =====================================================================
   EDITOR
   ===================================================================== */
.ed { display: flex; flex-direction: column; height: 100%; min-height: 560px; position: relative; }
.ed-bar { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 10px 16px; border-bottom: 1px solid var(--line); background: var(--bg-2); }
.ed-group { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.ed-btn, .ed-icon { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 12px; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text); font: 500 14px var(--f); cursor: pointer; transition: background-color .15s ease, border-color .15s ease, transform 160ms var(--ease-out); }
.ed-icon { width: 36px; padding: 0; justify-content: center; }
.ed-btn:active, .ed-icon:active { transform: scale(0.97); }
.ed-btn:hover, .ed-icon:hover { background: var(--surface-3); border-color: var(--line-2); }
.ed-btn.on, .ed-icon.on { background: var(--acc-soft); border-color: rgba(255, 204, 51, .5); }
.ed-btn.primary { background: var(--acc); border-color: rgba(255, 255, 255, .18); color: var(--on-acc); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), var(--glow); }
.ed-btn:disabled, .ed-icon:disabled { opacity: .4; cursor: not-allowed; }
.ed-icon.sm { width: 28px; height: 28px; border: 0; background: none; color: var(--text-3); }
.ed-icon.sm:hover { color: var(--text); background: var(--surface-3); }
.ed-menu-wrap { position: relative; display: inline-flex; }
.ed-menu { position: absolute; top: calc(100% + 6px); left: 0; z-index: 30; min-width: 190px; padding: 6px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: var(--shadow-lg); display: grid; transform-origin: top left; transition: opacity .15s var(--ease-out), transform .15s var(--ease-out); }
@starting-style { .ed-menu { opacity: 0; transform: scale(.97); } }
.ed-menu.right { left: auto; right: 0; transform-origin: top right; }
.ed-menu[hidden] { display: none; }
.ed-menu button { text-align: left; padding: 9px 11px; border-radius: 8px; border: 0; background: none; color: var(--text); font: 500 14px var(--f); cursor: pointer; }
.ed-menu button:hover { background: var(--surface-3); }
.ed-main { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 1fr) 340px; }
.ed-stage-wrap { min-width: 0; overflow: auto; padding: 24px; display: grid; align-content: center; justify-items: center; gap: 14px; background: radial-gradient(circle at 50% 30%, #18181b, #08090d); background-image: radial-gradient(rgba(255, 255, 255, .05) 1px, transparent 1.2px); background-size: 22px 22px; }
.ed-stage { position: relative; width: min(100%, calc((100vh - 260px) * var(--ar, 1.7778))); box-shadow: 0 0 0 1px var(--line-2), var(--shadow-lg); border-radius: 4px; }
.ed-cv { display: block; width: 100%; height: auto; border-radius: 4px; }
.ed-ov { position: absolute; inset: 0; outline: none; touch-action: none; overflow: hidden; border-radius: 4px; }
.ed-ov:focus-visible { box-shadow: inset 0 0 0 2px var(--acc-hi); }
.ed-sel { position: absolute; border: 1.5px solid var(--acc-hi); border-radius: 2px; pointer-events: none; box-shadow: 0 0 0 1px rgba(0, 0, 0, .4); }
.ed-sel i { position: absolute; width: 12px; height: 12px; border-radius: 3px; background: #fff; border: 1.5px solid var(--acc); pointer-events: auto; cursor: nwse-resize; }
.ed-sel i[data-h="nw"] { left: -7px; top: -7px; } .ed-sel i[data-h="ne"] { right: -7px; top: -7px; cursor: nesw-resize; }
.ed-sel i[data-h="sw"] { left: -7px; bottom: -7px; cursor: nesw-resize; } .ed-sel i[data-h="se"] { right: -7px; bottom: -7px; }
.ed-sel i[data-h="rot"] { left: 50%; top: -30px; margin-left: -7px; border-radius: 50%; cursor: grab; }
.ed-sel i[data-h="rot"]::after { content: ""; position: absolute; left: 50%; top: 12px; width: 1.5px; height: 17px; background: var(--acc-hi); }
.ed-guide { position: absolute; background: #ff3fb4; pointer-events: none; }
.ed-guide.v { top: 0; bottom: 0; width: 1px; } .ed-guide.h { left: 0; right: 0; height: 1px; }
.ed-safe { position: absolute; border: 1.5px dashed rgba(255, 255, 255, .55); border-radius: 6px; pointer-events: none; }
.ed-fix { width: min(100%, 860px); padding: 14px; border-radius: 14px; background: var(--surface); border: 1px solid rgba(255, 181, 71, .35); }
.ed-fix p { font-size: 14px; color: var(--text-2); margin-bottom: 10px; }
.ed-fix-row { display: flex; gap: 8px; flex-wrap: wrap; }
.ed-fix-row .input { flex: 1; min-width: 200px; }
.ed-side { border-left: 1px solid var(--line); background: var(--bg-2); overflow-y: auto; display: flex; flex-direction: column; }
.ed-props { padding: 16px; display: grid; gap: 12px; align-content: start; }
.ed-h { font-size: 12.5px; font-weight: 600; color: var(--text-3); letter-spacing: .01em; margin-top: 6px; }
.ed-tip { font-size: 13px; color: var(--text-3); line-height: 1.5; }
.ed-text { min-height: 64px; font-size: 15px; }
.ed-fontbtn { display: flex; justify-content: space-between; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--text); cursor: pointer; text-align: left; }
.ed-fontbtn span { font-size: 19px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ed-fontbtn small { font-family: var(--f); font-size: 12.5px; color: var(--acc-hi); flex: none; }
.ed-fontbtn:hover { border-color: rgba(255, 204, 51, .5); }
.ed-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ed-actions .btn { flex: 1; }
.ed-seg { display: inline-flex; gap: 2px; padding: 3px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.ed-seg.wide { display: flex; }
.ed-seg button { flex: 1; height: 30px; min-width: 34px; display: grid; place-items: center; border: 0; background: none; color: var(--text-2); font: 500 13.5px var(--f); border-radius: 7px; cursor: pointer; }
.ed-seg button.on { background: var(--surface-3); color: var(--text); }
.ed-range { display: grid; gap: 4px; font-size: 13px; color: var(--text-2); }
.ed-range > span { display: flex; justify-content: space-between; }
.ed-range b { font-weight: 500; color: var(--text-3); font-variant-numeric: tabular-nums; }
.ed-field { display: grid; gap: 6px; font-size: 13px; color: var(--text-2); }
.ed-switch { display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14px; color: var(--text); user-select: none; }
.ed-switch input { position: absolute; opacity: 0; pointer-events: none; }
.ed-switch i { width: 34px; height: 20px; border-radius: 99px; background: var(--surface-3); position: relative; transition: background-color .2s ease; flex: none; }
.ed-switch i::after { content: ""; position: absolute; left: 3px; top: 3px; width: 14px; height: 14px; border-radius: 50%; background: #c9d0dc; transition: transform .2s var(--ease-out), background-color .2s ease; }
.ed-switch input:checked + i { background: var(--acc); }
.ed-switch input:checked + i::after { transform: translateX(14px); background: #fff; }
.ed-switch input:focus-visible + i { outline: 2px solid var(--acc-hi); outline-offset: 2px; }
.ed-sec { display: grid; gap: 10px; padding: 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--line); }
.ed-color { display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 10px 0 5px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--text-2); cursor: pointer; font: 500 12.5px var(--f); font-variant-numeric: tabular-nums; text-transform: uppercase; }
.ed-color i { width: 24px; height: 24px; border-radius: 6px; background: var(--c); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.ed-color:hover { border-color: rgba(255, 204, 51, .5); }
.ed-stops { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.ed-stop { position: relative; }
.ed-stop .ed-color span { display: none; }
.ed-stop .ed-color { padding: 0 5px; }
.ed-x { position: absolute; top: -6px; right: -6px; width: 18px; height: 18px; border-radius: 50%; border: 0; background: var(--surface-3); color: var(--text); font-size: 12px; line-height: 1; cursor: pointer; }
.ed-add { height: 34px; padding: 0 10px; border-radius: 9px; border: 1px dashed var(--line-2); background: none; color: var(--text-2); font: 500 12.5px var(--f); cursor: pointer; }
.ed-presets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ed-presets.sm { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.ed-preset { height: 56px; border-radius: 10px; border: 1px solid var(--line); background: #0b0d12; cursor: pointer; display: grid; place-items: center; font-size: 21px; letter-spacing: .02em; text-transform: uppercase; transition: border-color .15s ease, transform 160ms var(--ease-out); overflow: hidden; }
.ed-presets.sm .ed-preset { height: 44px; font-size: 15px; }
.ed-preset:active { transform: scale(0.97); }
.ed-preset:hover { border-color: var(--line-2); }
.ed-preset.on { border-color: var(--acc-hi); box-shadow: 0 0 0 1px var(--acc-hi); }
.ed-layers { border-top: 1px solid var(--line); padding: 14px 12px 16px; margin-top: auto; }
.ed-layers .ed-h { padding: 0 4px; margin: 0 0 8px; }
.ed-layers ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.ed-layers li { display: flex; align-items: center; gap: 2px; border-radius: 9px; padding: 2px 4px 2px 2px; border: 1px solid transparent; }
.ed-layers li.on { background: var(--acc-soft); border-color: rgba(255, 204, 51, .35); }
.ed-layers li.off .ed-lname { opacity: .45; }
.ed-lname { flex: 1; min-width: 0; display: flex; align-items: center; gap: 8px; padding: 6px; border: 0; background: none; color: var(--text); font: 500 13.5px var(--f); text-align: left; cursor: pointer; border-radius: 7px; }
.ed-lname span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ed-lname .i { color: var(--text-3); }
.ed-empty { font-size: 13px; color: var(--text-3); padding: 4px; }
.ed-fonts { position: absolute; z-index: 40; width: 360px; max-height: 460px; display: grid; grid-template-rows: auto auto 1fr; gap: 10px; padding: 12px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: var(--shadow-lg); }
.ed-fonts[hidden] { display: none; }
.ed-font-cats { display: flex; gap: 4px; flex-wrap: wrap; }
.ed-font-cats button { padding: 5px 9px; border-radius: 7px; border: 1px solid var(--line); background: none; color: var(--text-2); font: 500 12.5px var(--f); cursor: pointer; }
.ed-font-cats button.on { background: var(--acc-soft); border-color: rgba(255, 204, 51, .45); color: #fff; }
.ed-font-list { overflow-y: auto; display: grid; gap: 4px; min-height: 0; padding-right: 2px; }
.ed-font-list button { display: grid; gap: 1px; text-align: left; padding: 9px 10px; border-radius: 9px; border: 1px solid transparent; background: var(--surface); color: var(--text); cursor: pointer; }
.ed-font-list button:hover { border-color: var(--line-2); }
.ed-font-list button.on { border-color: var(--acc-hi); }
.ed-font-prev { font-size: 22px; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ed-font-list small { font-size: 11.5px; color: var(--text-3); }
@media (max-width: 1000px) {
  .ed-main { grid-template-columns: 1fr; }
  .ed-side { border-left: 0; border-top: 1px solid var(--line); }
  .ed-stage { width: 100%; }
  .ed-btn span { display: none; }
  .ed-btn { width: 36px; padding: 0; justify-content: center; }
  .ed-btn.primary span { display: inline; } .ed-btn.primary { width: auto; padding: 0 12px; }
  .ed-fonts { width: min(360px, calc(100% - 16px)); left: 8px !important; }
}
.editor-pick { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--line); }
.editor-pick .muted { font-size: 13.5px; margin-right: 4px; }

/* =====================================================================
   COLOUR WHEEL
   ===================================================================== */
.cp { position: fixed; z-index: 500; width: 248px; padding: 14px; border-radius: 16px; background: var(--surface-2); border: 1px solid var(--line-2); box-shadow: var(--shadow-lg); display: none; transform-origin: top left; }
.cp.on { display: grid; grid-template-columns: minmax(0, 1fr); gap: 10px; }
@starting-style { .cp.on { opacity: 0; transform: scale(.97); } }
.cp { transition: opacity .15s var(--ease-out), transform .15s var(--ease-out); }
.cp-wheel { position: relative; width: 220px; height: 220px; margin: 0 auto; touch-action: none; }
.cp-ring { position: absolute; inset: 0; border-radius: 50%; background: conic-gradient(from 0deg, #f00, #ff0, #0f0, #0ff, #00f, #f0f, #f00); -webkit-mask: radial-gradient(circle, transparent 66%, #000 67%); mask: radial-gradient(circle, transparent 66%, #000 67%); cursor: crosshair; }
.cp-hue-knob, .cp-sv-knob { position: absolute; width: 16px; height: 16px; border-radius: 50%; border: 2.5px solid #fff; box-shadow: 0 0 0 1px rgba(0, 0, 0, .5), 0 2px 6px rgba(0, 0, 0, .5); transform: translate(-50%, -50%); pointer-events: none; }
.cp-sq { position: absolute; left: 50%; top: 50%; width: 51%; height: 51%; transform: translate(-50%, -50%); border-radius: 6px; cursor: crosshair; }
.cp-sq-w, .cp-sq-b { position: absolute; inset: 0; border-radius: 6px; }
.cp-sq-w { background: linear-gradient(90deg, #fff, rgba(255, 255, 255, 0)); }
.cp-sq-b { background: linear-gradient(0deg, #000, rgba(0, 0, 0, 0)); }
.cp-row { display: flex; gap: 8px; align-items: center; }
.cp-now { width: 34px; height: 34px; border-radius: 9px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); flex: none; }
.cp-hex { flex: 1; min-width: 0; display: flex; align-items: center; gap: 6px; height: 34px; padding: 0 10px; border-radius: 9px; background: var(--surface); border: 1px solid var(--line-2); font-size: 12.5px; color: var(--text-3); }
.cp-hex input { flex: 1; min-width: 0; border: 0; background: none; color: var(--text); font: 500 14px var(--f); text-transform: uppercase; outline: none; font-variant-numeric: tabular-nums; }
.cp-eye { width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line-2); background: var(--surface); color: var(--text); cursor: pointer; display: grid; place-items: center; }
.cp-eye svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cp-label { font-size: 12px; color: var(--text-3); }
.cp-sw { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 6px; }
.cp-sw button { aspect-ratio: 1; padding: 0; min-width: 0; border-radius: 7px; border: 0; cursor: pointer; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); transition: transform 160ms var(--ease-out); }
.cp-sw button:hover { transform: scale(1.08); }

/* ===== v8: image stepper, picture quick tools, edit modal, watermark badge ===== */
.stepper { display: inline-flex; align-items: center; gap: 2px; padding: 3px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); }
.stepper button { width: 30px; height: 30px; border-radius: 7px; border: 0; background: var(--surface-3); color: var(--text); font: 700 17px/1 var(--f); cursor: pointer; box-shadow: 0 2px 0 #050506; transition: transform 120ms var(--ease-out), background-color .15s ease; }
.stepper button:active { transform: translateY(2px); box-shadow: none; }
.stepper button:disabled { opacity: .35; cursor: default; transform: none; }
@media (hover: hover) { .stepper button:not(:disabled):hover { background: #34343a; } }
.stepper output { min-width: 1.6ch; text-align: center; font-weight: 800; font-size: 15px; font-variant-numeric: tabular-nums; margin-left: 6px; }
.stepper-l { font-size: 13.5px; color: var(--text-2); margin: 0 8px 0 4px; min-width: 6.2ch; }

/* quick tools: illustrations on coloured baseplates */
.qcard .qv.art { background: var(--qc); }
.qcard .qv.art[data-c="yellow"] { --qc: #ffcc33; } .qcard .qv.art[data-c="blue"] { --qc: #4c9bff; } .qcard .qv.art[data-c="green"] { --qc: #3fbf6a; } .qcard .qv.art[data-c="red"] { --qc: #e5483b; }
.qcard .qv.art svg { position: relative; z-index: 1; width: 100%; height: 100%; transition: transform .5s var(--ease-out); }
@media (hover: hover) { .qcard:hover .qv.art svg { transform: scale(1.06) translateY(-2px); } }
.qcard .qv.art g[class^="lib-"], .qcard .qv.art .q-float { transition: transform .45s var(--ease-out); }
@media (hover: hover) { .qcard:hover .q-float { transform: translateY(-5px); } }
.qcard .q-bar { transform-box: fill-box; transform-origin: left; transition: transform .6s var(--ease-out); }
@media (hover: hover) { .qcard:hover .q-bar { transform: scaleX(1.12); } }
@media (hover: hover) { .qcard:hover .lib-a { transform: translate(-8px, -4px); } .qcard:hover .lib-b { transform: translate(8px, -4px); } .qcard:hover .lib-c { transform: translateY(4px); } }
/* (older picture-tile styles kept below for reference) */
.qcard { font: inherit; }
button.qcard { display: flex; flex-direction: column; justify-content: flex-start; align-items: stretch; width: 100%; appearance: none; -webkit-appearance: none; }
.qcard .qv.img { background: #000; }
.qcard .qv.img::before { content: none; }
.qcard .qv.img img { opacity: 1; transition: transform .6s var(--ease-out); }
@media (hover: hover) { .qcard:hover .qv.img img { transform: scale(1.05); } }
.qcard .qv.img::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, rgba(0, 0, 0, .55)); pointer-events: none; }
.qv-text { position: absolute; left: 50%; top: 24%; transform: translate(-50%, -50%) rotate(-4deg); z-index: 1; font: 400 clamp(20px, 2.4vw, 30px)/1 "Luckiest Guy", var(--f); color: #ffe14a; -webkit-text-stroke: 5px #1a1300; paint-order: stroke fill; white-space: nowrap; text-shadow: 0 4px 0 #1a1300; }
.qv-sel { position: absolute; left: 50%; top: 24%; width: 76%; height: 30%; transform: translate(-50%, -50%) rotate(-4deg); border: 1.5px solid #fff; border-radius: 3px; z-index: 1; box-shadow: 0 0 0 1px rgba(0, 0, 0, .4); }
.qv-sel::before, .qv-sel::after { content: ""; position: absolute; width: 8px; height: 8px; border-radius: 2px; background: #fff; top: -5px; left: -5px; }
.qv-sel::after { left: auto; right: -5px; top: auto; bottom: -5px; }
.qv-chip { position: absolute; left: 12px; bottom: 12px; z-index: 2; display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 8px; background: rgba(12, 12, 14, .82); color: #fff; font-size: 13px; font-weight: 700; backdrop-filter: blur(6px); }
.qv-chip .i { width: 15px !important; height: 15px !important; color: var(--acc); stroke-width: 2 !important; }
.qv-score { position: absolute; right: 12px; top: 12px; z-index: 2; width: 62px; height: 62px; border-radius: 50%; display: grid; place-content: center; text-align: center; background: rgba(12, 12, 14, .85); box-shadow: inset 0 0 0 5px #287f46; color: #fff; line-height: 1; }
.qv-score b { font-size: 22px; font-weight: 900; } .qv-score small { font-size: 10px; color: var(--text-2); }
.qcard .qv.stack { background: var(--bg-2); }
.qcard .qv.stack img { width: 64%; height: auto; aspect-ratio: 16/9; inset: auto; left: 18%; top: 22%; border-radius: 8px; border: 2px solid var(--surface); box-shadow: 0 10px 24px -8px rgba(0, 0, 0, .8); }
.qcard .qv.stack img:nth-child(1) { transform: translate(-16%, -12%) rotate(-7deg); }
.qcard .qv.stack img:nth-child(2) { transform: translate(14%, -4%) rotate(5deg); }
.qcard .qv.stack img:nth-child(3) { transform: translate(0, 10%); }
@media (hover: hover) {
  .qcard:hover .qv.stack img:nth-child(1) { transform: translate(-24%, -16%) rotate(-10deg); }
  .qcard:hover .qv.stack img:nth-child(2) { transform: translate(22%, -8%) rotate(8deg); }
  .qcard:hover .qv.stack img:nth-child(3) { transform: translate(0, 12%) scale(1.04); }
}
.qcard .qv.stack::after { content: none; }

/* edit modal */
.modal.edit-modal { width: min(940px, 100%); display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 22px; align-items: start; }
@media (max-width: 760px) { .modal.edit-modal { grid-template-columns: 1fr; } }
.em-pic { position: relative; border-radius: 12px; overflow: hidden; background: var(--bg-2); aspect-ratio: 16/9; }
.em-pic.sq { aspect-ratio: 1; max-width: 420px; }
.em-pic img { width: 100%; height: 100%; object-fit: cover; transition: filter .3s ease; }
.em-pic.busy img { filter: blur(6px) brightness(.6); }
.em-pic.busy::after { content: "Changing your picture…"; position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; color: #fff; }
.em-side { display: grid; gap: 10px; }
.em-side h2 { font-size: 24px; margin-bottom: 6px; }
.em-l { font-size: 13.5px; font-weight: 700; color: var(--text-2); }
.em-side textarea { min-height: 96px; }
.em-cost { display: inline-flex; align-items: center; gap: 5px; margin-left: 8px; padding: 3px 8px; border-radius: 6px; background: rgba(0, 0, 0, .14); font-size: 13px; }
.em-or { display: flex; align-items: center; gap: 10px; color: var(--text-3); font-size: 13px; margin: 4px 0; }
.em-or::before, .em-or::after { content: ""; flex: 1; height: 1px; background: var(--line-2); }

/* editor: watermark badge and picker note */
.ed-wm { align-self: center; font-size: 12px; font-weight: 800; letter-spacing: .02em; padding: 5px 9px; border-radius: 7px; color: var(--acc); border: 1px solid rgba(255, 204, 51, .4); background: var(--acc-soft); white-space: nowrap; }
.editor-pick { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.pick-note { font-size: 13px; }

.prompt-tip { max-width: 980px; margin: 10px auto 0; display: flex; gap: 8px; align-items: flex-start; font-size: 12px; line-height: 1.5; color: var(--text-3); }
.prompt-tip .i { flex: none; width: 14px; height: 14px; margin-top: 1px; color: var(--acc); }

/* ===== v10: studs on the prompt card, pick-up bar ===== */
.prompt-card { position: relative; transition: box-shadow .25s ease, border-color .25s ease; }
.prompt-card:focus-within { border-color: rgba(255, 204, 51, .55); box-shadow: 0 4px 0 #050506, 0 0 0 5px rgba(255, 204, 51, .1), var(--shadow-lg); }
.create-head { margin-bottom: 28px; }
.pickup { position: sticky; bottom: 16px; z-index: 30; max-width: 760px; margin: 28px auto 0; display: flex; align-items: center; gap: 12px; padding: 8px 8px 8px 8px; border-radius: 14px; background: rgba(28, 28, 31, .94); border: 1px solid var(--line-2); box-shadow: 0 3px 0 #050506, 0 24px 50px -20px rgba(0, 0, 0, .9); backdrop-filter: blur(10px); animation: puIn .5s var(--ease-out) both; }
.pickup[hidden] { display: none; }
@keyframes puIn { from { opacity: 0; transform: translateY(16px); } }
.pu-pic { width: 76px; aspect-ratio: 16/9; object-fit: cover; border-radius: 8px; flex: none; }
.pu-pic.sq { width: 44px; aspect-ratio: 1; }
.pu-text { flex: 1; min-width: 0; display: grid; }
.pu-text small { font-size: 12px; color: var(--acc); font-weight: 700; }
.pu-text b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pu-x { width: 32px; height: 32px; flex: none; display: grid; place-items: center; border: 0; border-radius: 8px; background: none; color: var(--text-3); cursor: pointer; }
@media (hover: hover) { .pu-x:hover { background: var(--surface-3); color: var(--text); } }
@media (max-width: 560px) { .pickup [data-lw="remix"] { display: none; } }
@media (prefers-reduced-motion: reduce) { .pickup { animation: none; } }

/* reviews */
.rv-form { display: grid; gap: 8px; }
.rv-form .grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (max-width: 480px) { .rv-form .grid-2 { grid-template-columns: 1fr; } }
.rv-pick { display: flex; gap: 6px; margin-bottom: 6px; }
.rv-pick button { width: 42px; height: 42px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--surface-2); color: var(--text-3); cursor: pointer; display: grid; place-items: center; transition: transform 120ms var(--ease-out), color .15s ease; }
.rv-pick button .i { width: 22px; height: 22px; }
.rv-pick button.on { color: var(--acc); border-color: rgba(255, 204, 51, .5); }
.rv-pick button.on .i { fill: var(--acc); }
.rv-pick button:active { transform: scale(.92); }
.rv-nudge { position: fixed; right: 20px; bottom: 20px; z-index: 300; width: min(340px, calc(100% - 40px)); display: grid; gap: 6px; padding: 16px 18px; border-radius: 14px; background: var(--surface); border: 1px solid rgba(255, 204, 51, .45); box-shadow: 0 4px 0 var(--acc-lo), var(--shadow-lg); animation: lwIn .45s var(--ease-out) both; }
.rv-nudge span { color: var(--text-2); font-size: 14px; }
.rv-nudge div { display: flex; gap: 8px; margin-top: 6px; }


/* prompt clarity hint under the Studio prompt box */
.clarity { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 10px; margin: 8px 0 2px; font-size: 13.5px; color: var(--text-2); }
.clarity-bar { display: inline-flex; gap: 3px; }
.clarity-bar i { width: 18px; height: 6px; border-radius: 2px; background: var(--surface-3); transition: background-color .25s ease; }
.clarity b { font-weight: 800; }
.clarity[data-level="1"] .clarity-bar i:nth-child(-n+1) { background: #e5483b; } .clarity[data-level="1"] b { color: #ff8a7f; }
.clarity[data-level="2"] .clarity-bar i:nth-child(-n+2) { background: #ffcc33; } .clarity[data-level="2"] b { color: #ffd966; }
.clarity[data-level="3"] .clarity-bar i { background: #3fbf6a; } .clarity[data-level="3"] b { color: #6ee7a8; }

/* ===================== v18 (zip 48) ===================== */
/* reference pictures inside the prompt box */
.refs-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 10px 0 2px; }
.refs-strip[hidden] { display: none; }
.refs-list { display: flex; flex-wrap: wrap; gap: 8px; }
.ref-add { width: 56px; height: 56px; flex: none; display: grid; place-items: center; border-radius: 10px; border: 1.5px dashed rgba(255, 255, 255, .18); background: none; color: var(--text-3); cursor: pointer; transition: color .15s ease, border-color .15s ease; }
@media (hover: hover) { .ref-add:hover { color: var(--text); border-color: var(--acc); } }
.refs-note { flex: 1 1 220px; margin: 0; font-size: 13px; line-height: 1.45; color: var(--text-3); }
.prompt-meta { display: flex; align-items: center; gap: 10px; }
.prompt-meta .clarity { flex: 1; }
.char-count { margin-left: auto; padding-top: 8px; font-size: 12.5px; color: var(--text-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.char-count.full { color: var(--amber); font-weight: 700; }
.char-count[hidden] { display: none; }
/* dropping pictures onto the box */
.drop-hint { position: absolute; inset: 0; z-index: 6; display: none; place-content: center; justify-items: center; gap: 6px; padding: 20px; text-align: center; border-radius: inherit; border: 2px dashed var(--acc); background: rgba(12, 12, 14, .93); color: var(--text-2); font-size: 14px; pointer-events: none; }
.drop-hint .i { width: 30px; height: 30px; color: var(--acc); }
.drop-hint b { color: var(--text); font-size: 17px; }
.prompt-card.dragging .drop-hint { display: grid; }
/* "+1,000" next to Invite friends in the sidebar */
.nav-tag { margin-left: auto; font-style: normal; font-size: 11.5px; font-weight: 800; color: #6ee7a8; background: rgba(63, 209, 127, .12); border: 1px solid rgba(63, 209, 127, .3); padding: 1px 6px; border-radius: 6px; }
/* invite card on Plans and credits */
.invite-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px 16px; align-items: start; padding: 20px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line-2); box-shadow: var(--edge); }
.invite-ico { width: 44px; height: 44px; display: grid; place-items: center; border-radius: 11px; background: var(--acc); color: var(--on-acc); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), 0 3px 0 var(--acc-lo); }
.invite-ico .i { width: 22px; height: 22px; }
.invite-copy h3 { margin: 2px 0 4px; }
.invite-copy p { margin: 0; font-size: 14.5px; }
.invite-link { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; }
.invite-link .input { flex: 1 1 260px; min-width: 0; font-variant-numeric: tabular-nums; color: var(--text-2); }
.invite-stats { grid-column: 1 / -1; margin: 0; font-size: 13.5px; color: var(--text-2); }
.invite-stats[hidden] { display: none; }

/* ===================== v19 (zip 58) ===================== */
/* results: Download and Edit are always visible, not only on hover */
.res .acts { opacity: 1; }
/* phones: a full-width Generate button and bigger controls */
@media (max-width: 560px) {
  .prompt-foot #genBtn { flex: 1 1 100%; order: 99; min-height: 46px; justify-content: center; }
  .prompt-foot .mini-seg button, .prompt-foot .stepper button, .prompt-foot .pill-btn { min-height: 40px; }
  .prompt-foot .stepper button { min-width: 40px; }
}
/* Library and Score headings line up with the content under them */
.view:not([data-view="create"]) .create-head { max-width: none; margin-inline: 0; }
@media (max-width: 560px) { .view:not([data-view="create"]) .create-head, .view:not([data-view="create"]) .create-head p { text-align: left; } }
/* text editor on phones and tablets: keep a short label under each tool icon instead of icons alone */
@media (max-width: 1000px) {
  .ed-bar { overflow-x: auto; scrollbar-width: none; }
  .ed-bar::-webkit-scrollbar { display: none; }
  .ed-btn { width: auto; min-width: 50px; height: auto; min-height: 44px; padding: 4px 6px; flex-direction: column; gap: 2px; }
  .ed-btn span { display: block; font-size: 10.5px; line-height: 1.1; white-space: nowrap; }
}

/* ── no credits yet: a promo code box and the starter pack (top of Create) ── */
.free-note { max-width: 980px; margin: 0 auto 16px; padding: 16px 18px 6px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line-2); }
.free-note > p:first-child { margin: 0 0 14px; color: var(--text-2); font-size: 14.5px; line-height: 1.5; }
.free-note > p:first-child b { color: var(--text); }
.free-note .starter { margin-bottom: 10px; }
.free-note .note-promo { margin-bottom: 14px; }
#upPromo { margin-top: 4px; }
.free-note > p.muted { margin: 0 0 10px; font-size: 13.5px; }
/* ── watermarked previews: the line under the prompt and the bar under results ── */
.wm-tip { color: var(--text-2); }
.wm-note { display: flex; align-items: center; gap: 14px; margin-top: 12px; padding: 12px 12px 12px 16px; border-radius: 14px; background: var(--acc-soft); border: 1px solid rgba(255, 204, 51, .4); }
.wm-note p { margin: 0; flex: 1; font-size: 14px; line-height: 1.45; color: var(--text-2); }
.wm-note b { color: var(--text); }
.wm-note .btn { flex: none; }
@media (max-width: 560px) { .wm-note { flex-direction: column; align-items: stretch; } }
.up-marked { display: block; margin: 14px auto 0; }

/* Quick tools: the pictures sit on the site's dark brick surface (one accent colour, like the rest of the site) */
.qcard .qv.art { --qc: #19191c; background: radial-gradient(110% 80% at 50% 115%, rgba(255, 204, 51, .13), transparent 62%), #19191c; box-shadow: inset 0 -4px 0 rgba(0, 0, 0, .35); }
.qcard .qv.art::before { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='30' height='30'%3E%3Crect x='7' y='9.5' width='16' height='16' rx='3.5' fill='%23000' fill-opacity='.35'/%3E%3Crect x='7' y='7' width='16' height='16' rx='3.5' fill='%23fff' fill-opacity='.045'/%3E%3C/svg%3E") 0 0 / 30px 30px; }

/* promo code card on Plans and credits */
.promo-card { margin-top: 14px; max-width: 520px; }
.promo-card .promo-lbl { font-size: 16px; }
