:root {
	--bg: #0b0b0d;
	--text: #f4f4f5;
	--muted: #a1a1aa;
	--red: #e11d2e;
	--card: rgba(12, 12, 14, .72);
	--line: rgba(255,255,255,.12);
	safe-area-top: env(safe-area-inset-top, 0px);
	safe-area-bottom: env(safe-area-inset-bottom, 0px);
}

[hidden] { display: none !important; }
* { box-sizing: border-box; }
html, body {
	margin: 0;
	min-height: 100%;
	background: var(--bg);
	color: var(--text);
	font-family: Inter, system-ui, -apple-system, Segoe UI, sans-serif;
	overflow-x: hidden;
}
body { padding-bottom: env(safe-area-inset-bottom); }

.stage {
	position: relative;
	width: 100%;
	height: 100dvh;
	background: #000;
	overflow: hidden;
}
.is-embed .stage { height: 100dvh; }
.is-embed .recordings { display: none !important; }

#live-player {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: contain;
	background: #000;
}
.play-error {
	position: absolute;
	left: 50%;
	top: 46%;
	transform: translate(-50%, -50%);
	z-index: 7;
	max-width: 86%;
	padding: 12px 14px;
	border-radius: 12px;
	background: rgba(0,0,0,.72);
	color: #fff;
	font-size: 14px;
	text-align: center;
	line-height: 1.4;
}

.offline {
	position: absolute;
	inset: 0;
	z-index: 2;
	background: #0b0b0d;
}
.offline img,
.offline video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.hud {
	position: absolute;
	inset: 0;
	z-index: 5;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	pointer-events: none;
	padding: calc(10px + env(safe-area-inset-top)) 12px calc(10px + env(safe-area-inset-bottom));
}
.hud-top, .hud-bottom, .composer, .icon-btn, .product, .chat-form { pointer-events: auto; }

.hud-top {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 10px;
}
.brand {
	display: flex;
	flex-direction: column;
	gap: 6px;
	max-width: 78%;
	text-shadow: 0 1px 8px rgba(0,0,0,.7);
}
.brand strong {
	font-size: 16px;
	line-height: 1.25;
	font-weight: 700;
}
.live-pill,
.waiting-pill {
	align-self: flex-start;
	font-size: 11px;
	font-weight: 800;
	letter-spacing: .08em;
	padding: 3px 8px;
	border-radius: 4px;
}
.live-pill { background: var(--red); }
.waiting-pill { background: #3f3f46; color: #e4e4e7; }

.icon-btn {
	width: 40px;
	height: 40px;
	border: 0;
	border-radius: 50%;
	background: rgba(0,0,0,.45);
	color: #fff;
	font-size: 16px;
}

.desc {
	margin: 0;
	max-width: 70%;
	font-size: 13px;
	line-height: 1.35;
	color: #e4e4e7;
	text-shadow: 0 1px 8px rgba(0,0,0,.7);
}

.hud-bottom {
	display: flex;
	flex-direction: column;
	gap: 8px;
	max-width: 560px;
}

.product {
	display: flex;
	align-items: center;
	gap: 10px;
	text-decoration: none;
	color: inherit;
	background: var(--card);
	backdrop-filter: blur(14px);
	border: 1px solid var(--line);
	border-radius: 14px;
	padding: 8px;
}
.product img {
	width: 52px;
	height: 52px;
	border-radius: 8px;
	object-fit: cover;
	background: #18181b;
}
.product-meta { flex: 1; min-width: 0; }
.product-name {
	display: block;
	font-size: 13px;
	font-weight: 650;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}
.product-price {
	display: block;
	margin-top: 2px;
	color: #fbbf24;
	font-size: 13px;
	font-weight: 700;
}
.product-go {
	font-size: 12px;
	font-weight: 700;
	background: #fff;
	color: #111;
	border-radius: 999px;
	padding: 8px 10px;
	white-space: nowrap;
}

.chat {
	max-height: 28dvh;
	overflow: hidden;
	mask-image: linear-gradient(to bottom, transparent, #000 18%);
}
.chat-list {
	display: flex;
	flex-direction: column;
	gap: 6px;
	max-height: 28dvh;
	overflow: auto;
	padding-top: 16px;
	scrollbar-width: none;
}
.chat-list::-webkit-scrollbar { display: none; }
.chat-item {
	align-self: flex-start;
	max-width: 92%;
	background: rgba(0,0,0,.38);
	border-radius: 10px;
	padding: 6px 9px;
	font-size: 13px;
	line-height: 1.35;
	text-shadow: 0 1px 4px rgba(0,0,0,.5);
}
.chat-item b { margin-right: 6px; color: #d4d4d8; }
.chat-item.is-mod {
	background: rgba(225, 29, 46, .88);
	border: 1px solid rgba(255,255,255,.18);
}
.chat-item.is-mod b { color: #fff; }

.composer {
	display: flex;
	gap: 8px;
}
.composer input,
.modal-card input {
	flex: 1;
	height: 44px;
	border: 1px solid var(--line);
	border-radius: 999px;
	background: rgba(0,0,0,.5);
	color: #fff;
	padding: 0 14px;
	font-size: 16px;
}
.composer button,
.modal-card button {
	height: 44px;
	border: 0;
	border-radius: 999px;
	background: #fff;
	color: #111;
	font-weight: 750;
	padding: 0 16px;
}

.unmute-gate {
	position: absolute;
	left: 50%;
	top: 42%;
	transform: translate(-50%, -50%);
	z-index: 8;
	border: 0;
	border-radius: 999px;
	background: #fff;
	color: #111;
	font-weight: 800;
	padding: 12px 18px;
}

.recordings {
	padding: 18px 16px 28px;
}
.recordings h2 { margin: 0 0 12px; font-size: 16px; }
.rec-list { display: grid; gap: 10px; }
.rec-item {
	display: block;
	color: inherit;
	text-decoration: none;
	background: #18181b;
	border-radius: 12px;
	padding: 12px 14px;
	border: 1px solid var(--line);
}

.modal {
	position: fixed;
	inset: 0;
	z-index: 20;
	background: rgba(0,0,0,.62);
	display: flex;
	align-items: flex-end;
	justify-content: center;
	padding: 16px 16px calc(16px + env(safe-area-inset-bottom));
}
.modal[hidden] { display: none; }
.modal-card {
	width: min(100%, 420px);
	background: #18181b;
	border-radius: 18px;
	padding: 18px;
}
.modal-card h3 { margin: 0 0 6px; }
.modal-card p { margin: 0 0 14px; color: var(--muted); font-size: 14px; }
.modal-card input { width: 100%; margin-bottom: 10px; }

@media (min-width: 880px) {
	.stage { height: min(100dvh, 920px); }
	.hud-bottom { max-width: 380px; }
	.chat, .chat-list { max-height: 36dvh; }
	.brand strong { font-size: 20px; }
}
