[hidden] { display: none !important; }
:root { --ink: #1c1830; --muted: #6d6880; --line: #e6e2ee; --bg: #f6f4fa; --card: #fff; --ok: #19a463; --bad: #d93a5b; }
* { box-sizing: border-box; }
body.admin { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif; }
a { color: color-mix(in srgb, var(--accent) 75%, #000); }
main { max-width: 1180px; margin: 0 auto; padding: 24px; }
h1 { font-size: 24px; margin: 0 0 16px; } h2 { font-size: 19px; margin: 0 0 12px; } h3 { font-size: 16px; margin: 0 0 8px; }
.topbar { display: flex; align-items: center; gap: 16px; padding: 12px 24px; background: #100c24; color: #fff; }
.topbar a { color: #fff; text-decoration: none; }
.brand { font-weight: 800; background: var(--accent); padding: 3px 12px; border-radius: 999px; }
.spacer { flex: 1; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 20px; margin-bottom: 18px; }
.narrow { max-width: 380px; margin: 10vh auto; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 800px) { .grid2, .grid3 { grid-template-columns: 1fr; } }
label { display: block; font-weight: 600; margin-bottom: 12px; }
input:not([type=radio]):not([type=checkbox]):not([type=file]), select, textarea { display: block; width: 100%; margin-top: 4px; padding: 9px 11px; font: inherit; border: 1px solid #cfc9db; border-radius: 9px; background: #fff; }
input[type=file] { margin-top: 6px; }
textarea { resize: vertical; }
.check { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; margin: 0; }
.btn { display: inline-flex; align-items: center; gap: 4px; appearance: none; border: 1px solid #cfc9db; background: #fff; color: var(--ink); padding: 8px 14px; border-radius: 9px; font: inherit; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap; }
.btn:hover { border-color: var(--ink); }
.btn.primary { background: var(--accent); border-color: transparent; color: #fff; }
.btn.danger { color: var(--bad); }
.btn.small { padding: 4px 9px; font-size: 13px; }
.btn.big { padding: 14px 26px; font-size: 18px; }
.btn.ok { background: var(--ok); color: #fff; border-color: transparent; }
.btn:disabled { opacity: .45; cursor: default; }
form.pb { display: inline; margin: 0; }
.row { display: flex; align-items: center; } .gap { gap: 10px; } .wrap { flex-wrap: wrap; } .between { justify-content: space-between; }
.inline-form { display: flex; gap: 8px; align-items: center; margin: 14px 0; flex-wrap: wrap; }
.inline-form input:not([type=file]) { flex: 1; min-width: 200px; margin: 0; }
.inline-form select { width: auto; margin: 0; }
.muted { color: var(--muted); } .small { font-size: 13px; } .right { text-align: right; } .nowrap { white-space: nowrap; }
.alert { background: #fde8ec; color: #8a1a32; padding: 10px 14px; border-radius: 9px; }
.notice { background: #e4f6ec; color: #0e5c37; padding: 10px 14px; border-radius: 9px; }
table.list { width: 100%; border-collapse: collapse; }
table.list td, table.list th { padding: 9px 6px; border-bottom: 1px solid var(--line); vertical-align: middle; text-align: left; }
table.list th { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
table.list td.right, table.list th.right { text-align: right; }
table.list .btn { margin-left: 4px; }
.code { font-family: ui-monospace, Menlo, monospace; letter-spacing: .12em; background: #f0edf6; padding: 1px 6px; border-radius: 5px; color: var(--ink); }
.pill { display: inline-block; background: var(--accent); color: #fff; font-weight: 700; font-size: 12px; padding: 3px 10px; border-radius: 999px; text-transform: uppercase; letter-spacing: .05em; }
details.import summary { list-style: none; } details.import summary::-webkit-details-marker { display: none; }

.round { border-top: 1px solid var(--line); margin-top: 18px; padding-top: 16px; }
.round-head { display: flex; gap: 8px; align-items: center; margin-bottom: 10px; }
.round-head .round-title { font-weight: 700; font-size: 17px; max-width: 420px; margin: 0; }
.qlist { margin: 0 0 12px; padding-left: 22px; }
.qlist li { padding: 8px 0; border-bottom: 1px dashed var(--line); }
.qlist li > * { vertical-align: middle; }
.qlist li { display: list-item; }
.qlist li .qtext { display: inline-block; width: calc(100% - 260px); }
.qlist li .nowrap { float: right; }
.thumb { width: 44px; height: 44px; object-fit: cover; border-radius: 6px; margin-right: 8px; }
@media (max-width: 800px) { .qlist li .qtext { width: 100%; } .qlist li .nowrap { float: none; } }

.seg { display: flex; gap: 8px; margin-bottom: 14px; }
.seg label { margin: 0; border: 1px solid #cfc9db; border-radius: 9px; padding: 8px 14px; cursor: pointer; font-weight: 600; }
.seg label:has(input:checked) { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 10%, #fff); }
fieldset { border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; margin: 0 0 16px; }
legend { font-weight: 700; padding: 0 6px; }
#qform:not([data-type=choice]) .only-choice, #qform:not([data-type=text]) .only-text,
#qform:not([data-type=multi]) .only-multi, #qform:not([data-type=number]) .only-number,
#qform:not([data-media=file]) .only-file, #qform:not([data-media=youtube]) .only-youtube,
#qform[data-media=""] .only-media { display: none; }
.small-seg label { padding: 6px 12px; font-size: 14px; }
.current-media { margin: -4px 0 12px; }
.current-media audio { width: 100%; max-width: 420px; }
.current-media video { max-width: 320px; border-radius: 8px; }
.current-media img { width: 160px; border-radius: 8px; vertical-align: middle; margin-right: 8px; }
.seg { flex-wrap: wrap; }
.media-box { display: flex; gap: 8px; align-items: center; margin: 4px 0 14px; padding: 10px 12px; background: #f3f0f8; border-radius: 10px; }
.media-box strong { margin-right: auto; }
.opt-row { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.opt-row input:not([type=radio]) { margin: 0; flex: 1; }
.opt-letter { width: 30px; height: 30px; flex: none; display: grid; place-items: center; border-radius: 50%; font-weight: 800; color: #14102a; }
.l0 { background: #ff4f7b; } .l1 { background: #3fa9f5; } .l2 { background: #ffc93c; } .l3 { background: #2fd48a; } .l4 { background: #a66cff; } .l5 { background: #ff8c42; }
.current-img { display: flex; gap: 10px; align-items: center; margin: -4px 0 12px; }
.current-img img { max-width: 140px; max-height: 90px; border-radius: 8px; }

/* ---------- Host panel */
.host main.host-grid { max-width: 1400px; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 960px) { .host main.host-grid { grid-template-columns: 1fr; } }
.hostname { opacity: .85; } .hostname .code { background: rgba(255, 255, 255, .15); color: #fff; }
.now h2 { font-size: 22px; margin: 12px 0 6px; min-height: 1.3em; }
.host-answer { font-size: 16px; margin-bottom: 4px; }
.host-answer b { color: var(--ok); }
.stats { display: flex; gap: 16px; margin: 10px 0 16px; font-size: 15px; }
.stats .ok { color: var(--ok); font-weight: 700; } .stats .warn { color: var(--bad); font-weight: 700; }
.controls { display: flex; gap: 10px; align-items: center; }
.controls #next { flex: 1; justify-content: center; }
#nextLabel { margin: 6px 0 12px; min-height: 1.2em; }
.preview .frame { position: relative; width: 100%; aspect-ratio: 16 / 9; margin-top: 10px; border-radius: 10px; overflow: hidden; background: #100c24; }
.preview iframe { position: absolute; top: 0; left: 0; width: 1600px; height: 900px; border: 0; transform-origin: 0 0; pointer-events: none; }
.join-card { display: flex; gap: 16px; align-items: center; }
.join-card p { margin: 4px 0 8px; word-break: break-all; }
.mini-qr { width: 110px; flex: none; } .mini-qr svg { width: 100%; height: auto; display: block; }
.tabs { display: flex; gap: 4px; margin-bottom: -1px; }
.tabs button { appearance: none; border: 1px solid var(--line); border-bottom: 0; background: #ebe7f2; padding: 10px 16px; border-radius: 10px 10px 0 0; font: inherit; font-weight: 600; cursor: pointer; }
.tabs button.on { background: #fff; }
.tab { border-top-left-radius: 0; }
.marking tr.is-right td:first-child strong { color: var(--ok); }
.marking details summary { cursor: pointer; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #c8c3d4; margin-right: 4px; }
.dot.ok { background: var(--ok); }

/* ---------- Accounts, plans, shop, owner */
.topbar { flex-wrap: wrap; }
.mainnav { display: flex; gap: 4px; flex-wrap: wrap; }
.mainnav a { padding: 6px 12px; border-radius: 8px; opacity: .8; }
.mainnav a:hover, .mainnav a.on { background: rgba(255, 255, 255, .12); opacity: 1; }
.topbar .back { opacity: .8; font-size: 14px; }
.plan-badge { display: inline-block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; padding: 3px 10px; border-radius: 999px; border: 1px solid currentColor; opacity: .85; text-decoration: none; }
.topbar .plan-badge { color: #fff; }
.plan-badge.paid { background: #2fd48a; border-color: #2fd48a; color: #08331f !important; opacity: 1; }
button.linkish { background: none; border: 0; color: inherit; font: inherit; cursor: pointer; padding: 0; opacity: .85; }
.topbar .btn.primary { color: #fff; }
.upsell { display: flex; gap: 16px; align-items: center; justify-content: space-between; background: linear-gradient(90deg, color-mix(in srgb, var(--accent) 12%, #fff), #fff); border: 1px solid color-mix(in srgb, var(--accent) 30%, #fff); border-radius: 14px; padding: 14px 18px; margin-bottom: 18px; }
.tag { display: inline-block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; background: #ece8f3; color: #5a5470; padding: 2px 8px; border-radius: 6px; vertical-align: middle; }
.tag.ok { background: #dcf5e8; color: #0e5c37; }
.auth h1 { margin-bottom: 8px; }
.btn.wide { width: 100%; justify-content: center; }
.btn.disabled { opacity: .55; cursor: default; }
.hp { position: absolute; left: -9999px; }
.sitefoot { text-align: center; color: var(--muted); font-size: 13px; padding: 10px 0 30px; }
.sitefoot a { color: var(--muted); }
.current-plan { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; }
.plan-name { font-size: 26px; font-weight: 800; }
.plans { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin: 6px 0 10px; }
@media (max-width: 1000px) { .plans { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .plans { grid-template-columns: 1fr; } }
.plan { position: relative; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px; display: flex; flex-direction: column; }
.plan.featured { border: 2px solid var(--accent); }
.plan.current { background: #faf8fd; }
.plan h3 { margin: 0 0 4px; }
.plan .price { font-size: 24px; font-weight: 800; margin-bottom: 6px; }
.plan .price span { font-size: 13px; font-weight: 500; color: var(--muted); }
.plan ul { padding-left: 18px; margin: 6px 0 14px; flex: 1; font-size: 14px; }
.plan li.no { color: var(--muted); text-decoration: line-through; }
.ribbon { position: absolute; top: -11px; left: 16px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 700; padding: 3px 10px; border-radius: 999px; }
.danger-zone { border-color: #f3c6cf; }
.logo-prev img { max-height: 60px; background: #100c24; padding: 6px; border-radius: 8px; }
.subtabs { display: flex; gap: 6px; margin: -6px 0 18px; }
.subtabs a { padding: 7px 14px; border-radius: 9px; text-decoration: none; color: var(--ink); background: #ebe7f2; font-weight: 600; }
.subtabs a.on { background: var(--ink); color: #fff; }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 12px; margin-bottom: 8px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.stat .n { font-size: 28px; font-weight: 800; }
.stat .l { font-size: 14px; }
.bad { color: var(--bad); }
details.actions { display: inline-block; text-align: left; }
details.actions[open] { display: block; }
details.actions summary { list-style: none; } details.actions summary::-webkit-details-marker { display: none; }
details.actions .inline-form { margin: 8px 0 0; justify-content: flex-end; }
.shop-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 14px; }
.shop-head h1 { margin-bottom: 4px; }
.shop-head p { margin: 0; max-width: 620px; }
.filters { display: flex; gap: 6px; flex-wrap: wrap; }
.chipbtn { border: 1px solid #cfc9db; background: #fff; border-radius: 999px; padding: 6px 14px; font: inherit; font-weight: 600; cursor: pointer; }
.chipbtn.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.sets { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.set { display: flex; flex-direction: column; margin: 0; }
.set h2 { margin: 6px 0 2px; }
.set p { margin: 10px 0; }
.set details { margin: 4px 0 12px; }
.set details summary { cursor: pointer; font-weight: 600; font-size: 14px; }
.set .buy { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; border-top: 1px solid var(--line); padding-top: 12px; flex-wrap: wrap; }
.set .price { font-size: 22px; font-weight: 800; }
.locked-note { background: #faf8fd; border: 1px dashed #cfc9db; border-radius: 9px; padding: 8px 12px; font-size: 14px; }
.set .tag { align-self: flex-start; }
