@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@500;600;700;800&display=swap');

:root { --ink:#0b0d10; --panel:#111419; --panel-2:#171b21; --line:#292e36; --muted:#8f97a4; --paper:#f2f0ea; --white:#fff; --accent:#d7ff45; --accent-dark:#bce22e; --danger:#ff655f; }
* { box-sizing:border-box; }
html, body { margin:0; min-height:100%; background:var(--ink); color:var(--white); font-family:'DM Sans',sans-serif; }
button, input { font:inherit; }
button { color:inherit; }
svg { width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.svg-defs { position:absolute; width:0; height:0; overflow:hidden; }
.hidden { display:none !important; }
.theme-toggle { width:40px; height:40px; display:grid; place-items:center; border:1px solid transparent; border-radius:9px; color:inherit; background:transparent; cursor:pointer; transition:background .18s,border-color .18s,transform .18s; }
.theme-toggle:hover { transform:translateY(-1px); }
.landing-theme { position:fixed; z-index:10; top:26px; right:28px; color:#5f665f; border-color:#d5d2ca; background:rgba(242,240,234,.82); backdrop-filter:blur(10px); }
.landing-theme:hover { color:var(--ink); background:white; }
.landing { min-height:100vh; display:grid; grid-template-columns:minmax(380px,44%) 1fr; }
.brand-panel { position:relative; min-height:100vh; overflow:hidden; padding:38px 44px; display:flex; flex-direction:column; background:#0c0f13; border-right:1px solid #22262d; }
.brand-panel::before { content:''; position:absolute; inset:0; opacity:.32; background-image:linear-gradient(rgba(255,255,255,.035) 1px,transparent 1px),linear-gradient(90deg,rgba(255,255,255,.035) 1px,transparent 1px); background-size:64px 64px; mask-image:linear-gradient(to bottom,black,transparent 88%); }
.brand-panel::after { content:''; position:absolute; width:580px; height:580px; left:-260px; bottom:-250px; border:1px solid rgba(215,255,69,.3); border-radius:50%; box-shadow:0 0 90px rgba(215,255,69,.06),0 0 0 80px rgba(215,255,69,.018),0 0 0 160px rgba(215,255,69,.012); }
.brand { position:relative; z-index:2; display:flex; align-items:center; gap:13px; width:max-content; color:white; text-decoration:none; font:800 16px 'Manrope'; letter-spacing:.06em; }
.brand-mark { width:38px; height:38px; display:grid; place-items:center; color:var(--ink); background:var(--accent); border-radius:9px; transform:rotate(-3deg); }
.brand-mark svg { width:21px; }
.brand-muted { color:#69717d; }
.signal-art { position:absolute; z-index:0; right:-20%; top:9%; width:80%; aspect-ratio:1; border-radius:50%; border:1px solid rgba(215,255,69,.16); display:grid; place-items:center; }
.signal-art span { position:absolute; border-radius:50%; border:1px solid rgba(215,255,69,.12); }
.signal-art span:nth-child(1){inset:15%}.signal-art span:nth-child(2){inset:30%}.signal-art span:nth-child(3){inset:44%;background:var(--accent);border:0;box-shadow:0 0 45px rgba(215,255,69,.4)}.signal-art span:nth-child(4){width:7px;height:7px;background:white;border:0}
.brand-copy { position:relative; z-index:1; margin:auto 0; max-width:580px; padding:90px 0 70px; }
.eyebrow, .section-index { margin:0 0 16px; color:var(--accent); font:700 11px 'Manrope'; letter-spacing:.19em; }
.brand-copy h1 { margin:0; font:700 clamp(54px,6vw,88px)/.98 'Manrope'; letter-spacing:-.065em; }
.brand-copy h1 em { color:var(--accent); font-style:normal; }
.brand-copy > p:last-child { max-width:440px; margin:30px 0 0; color:#9ca3ad; font-size:17px; line-height:1.65; }
.privacy-note { position:relative; z-index:2; display:flex; align-items:center; gap:10px; color:#7d8591; font-size:12px; letter-spacing:.02em; }
.status-dot { flex:none; width:8px; height:8px; border-radius:50%; background:var(--accent); box-shadow:0 0 0 4px rgba(215,255,69,.1); }
.entry-panel { min-height:100vh; display:grid; grid-template-columns:minmax(0,1fr); place-items:center; background:var(--paper); color:var(--ink); padding:50px; }
.entry-wrap { width:100%; max-width:460px; min-width:0; }
.mobile-brand { display:none; }
.section-index { color:#818774; }
.entry-wrap h2 { margin:0; font:700 clamp(34px,4vw,50px)/1.08 'Manrope'; letter-spacing:-.045em; }
.entry-subtitle { margin:14px 0 38px; color:#6f746e; line-height:1.6; }
label { display:block; margin:0 0 9px; font:700 11px 'Manrope'; letter-spacing:.1em; text-transform:uppercase; }
.field { position:relative; margin-bottom:22px; }
.field input { width:100%; height:56px; border:1px solid #d2d0c9; border-radius:8px; padding:0 17px; color:var(--ink); background:#faf9f5; outline:none; transition:.18s; }
.field input::placeholder { color:#a6aaa4; }
.field input:focus { border-color:#7d882e; box-shadow:0 0 0 3px rgba(142,158,45,.12); background:white; }
.token-field input { padding-right:50px; text-transform:uppercase; letter-spacing:.13em; font-weight:700; }
.token-field svg { position:absolute; right:17px; top:18px; color:#7c827a; }
.form-error { min-height:18px; margin:-8px 0 10px; color:#ba3936; font-size:13px; }
.primary-button { width:100%; height:58px; border:0; border-radius:8px; background:var(--ink); color:white; display:flex; align-items:center; justify-content:space-between; padding:0 18px 0 22px; cursor:pointer; font-weight:700; transition:.18s; }
.primary-button:hover { transform:translateY(-1px); background:#20242a; box-shadow:0 8px 24px rgba(11,13,16,.13); }
.primary-button:disabled { opacity:.55; cursor:wait; transform:none; }
.primary-button svg { color:var(--accent); }
.or { display:flex; align-items:center; gap:13px; margin:25px 0; color:#a2a49e; font-size:9px; letter-spacing:.15em; }
.or span { height:1px; flex:1; background:#d8d6d0; }
.secondary-button { width:100%; display:flex; align-items:center; gap:15px; text-align:left; padding:15px; border:1px solid #d2d0c9; border-radius:8px; background:transparent; color:var(--ink); cursor:pointer; transition:.18s; }
.secondary-button:hover { background:#e9e7df; border-color:#bdbbb4; }
.secondary-button > svg { width:23px; height:23px; margin:0 5px; }
.secondary-button span { display:flex; flex-direction:column; gap:3px; }
.secondary-button strong { font-size:14px; }
.secondary-button small { color:#7f837d; font-size:12px; }

.room { height:100vh; min-height:620px; display:grid; grid-template-columns:250px 1fr; background:var(--ink); overflow:hidden; }
.room-sidebar { min-width:0; padding:24px 18px 17px; display:flex; flex-direction:column; border-right:1px solid var(--line); background:#0e1115; }
.brand.compact { margin-left:4px; font-size:13px; }
.brand.compact .brand-mark { width:32px; height:32px; border-radius:8px; }
.brand.compact .brand-mark svg { width:18px; }
.sidebar-section { margin-top:50px; min-height:0; flex:1; }
.sidebar-heading { display:flex; justify-content:space-between; padding:0 7px 12px; color:#6f7782; font:700 10px 'Manrope'; letter-spacing:.14em; }
.sidebar-heading span:last-child { color:#a3abb5; }
.people-list { display:flex; flex-direction:column; gap:3px; overflow:auto; }
.person { min-width:0; display:flex; align-items:center; gap:10px; padding:9px 8px; border-radius:7px; }
.person.sharing { background:#191e22; }
.avatar { position:relative; flex:none; width:31px; height:31px; border-radius:9px; display:grid; place-items:center; color:#d6d9dc; background:#252b33; font:700 12px 'Manrope'; text-transform:uppercase; }
.person.sharing .avatar { color:var(--ink); background:var(--accent); }
.person-info { min-width:0; display:flex; flex-direction:column; }
.person-info strong { overflow:hidden; white-space:nowrap; text-overflow:ellipsis; font-size:13px; font-weight:600; }
.person-info small { color:#6f7782; font-size:10px; }
.person.sharing .person-info small { color:#aebd6b; }
.sidebar-bottom { display:flex; align-items:center; gap:8px; padding:14px 7px 0; border-top:1px solid #242930; }
.connection { min-width:0; flex:1; display:flex; align-items:center; gap:10px; }
.connection > span:last-child { min-width:0; display:flex; flex-direction:column; }
.connection strong { overflow:hidden; text-overflow:ellipsis; font-size:12px; }
.connection small { margin-top:2px; color:#69717c; font-size:10px; }
.connection .status-dot { width:7px; height:7px; }
.icon-button, .dock-icon, .dialog-close { border:0; background:transparent; cursor:pointer; }
.icon-button { width:34px; height:34px; display:grid; place-items:center; color:#777f8a; border-radius:7px; }
.icon-button:hover { color:white; background:#242930; }
.icon-button svg { width:17px; }
.stage-shell { position:relative; min-width:0; min-height:0; display:grid; grid-template-rows:auto minmax(0,1fr) auto; background:radial-gradient(circle at 50% 25%,#191d23 0,#101318 58%,#0d0f13 100%); }
.room-header { height:82px; display:flex; align-items:center; justify-content:space-between; gap:20px; padding:0 28px; border-bottom:1px solid var(--line); background:rgba(12,15,19,.8); backdrop-filter:blur(12px); }
.room-header .eyebrow { margin-bottom:4px; color:#69717b; font-size:8px; }
.room-header h2 { margin:0; font:700 17px 'Manrope'; letter-spacing:-.02em; }
.header-actions { display:flex; align-items:center; gap:9px; }
.room-theme { color:#858e99; border-color:#2b3038; background:#15191e; }
.room-theme:hover { color:white; background:#20252c; }
.room-token { display:flex; align-items:center; gap:12px; height:42px; padding:0 5px 0 15px; border:1px solid #2b3038; border-radius:8px; background:#15191e; }
.room-token > span { color:#626a74; font:700 8px 'Manrope'; letter-spacing:.16em; }
.room-token strong { font:700 12px 'Manrope'; letter-spacing:.14em; }
.stage { min-width:0; min-height:0; position:relative; overflow:auto; padding:25px 27px; display:grid; place-items:center; }
.empty-state { color:#747d88; text-align:center; }
.empty-icon { position:relative; width:80px; height:80px; margin:0 auto 24px; display:grid; place-items:center; border:1px solid #343a43; border-radius:22px; background:#171b20; transform:rotate(-3deg); }
.empty-icon svg { width:34px; height:34px; color:#79828d; }
.empty-icon i { position:absolute; right:-2px; bottom:-2px; width:17px; height:17px; border:4px solid #12151a; border-radius:50%; background:#4f5660; }
.empty-state h3 { margin:0 0 8px; color:#c5c9ce; font:600 19px 'Manrope'; }
.empty-state p { margin:0; font-size:13px; }
.video-grid { width:100%; height:100%; min-width:0; min-height:0; display:grid; grid-template-columns:repeat(auto-fit,minmax(min(460px,100%),1fr)); grid-auto-rows:minmax(220px,1fr); align-content:center; gap:15px; }
.video-tile { position:relative; min-width:0; min-height:0; overflow:hidden; contain:layout paint; border:1px solid #303640; border-radius:12px; background:#080a0c; box-shadow:0 20px 50px rgba(0,0,0,.2); }
.video-tile video { width:100%; height:100%; display:block; object-fit:contain; background:#060708; }
.video-tile:fullscreen { width:100vw; height:100vh; border:0; border-radius:0; contain:none; }
.video-tile:fullscreen .fullscreen-button { position:fixed; z-index:2; top:18px; right:18px; }
.video-meta { position:absolute; left:12px; bottom:12px; display:flex; align-items:center; gap:8px; padding:7px 10px; border:1px solid rgba(255,255,255,.1); border-radius:7px; background:rgba(8,10,12,.8); backdrop-filter:blur(8px); font-size:11px; }
.video-meta .status-dot { width:6px; height:6px; }
.fullscreen-button { position:absolute; right:12px; top:12px; width:36px; height:36px; display:grid; place-items:center; border:1px solid rgba(255,255,255,.1); border-radius:7px; color:#c6cbd1; background:rgba(8,10,12,.78); cursor:pointer; }
.fullscreen-button:hover { color:white; background:#1c2026; }
.control-dock { justify-self:center; margin:0 20px 20px; height:64px; display:flex; align-items:center; gap:8px; padding:7px; border:1px solid #30353d; border-radius:12px; background:rgba(24,28,34,.95); box-shadow:0 18px 50px rgba(0,0,0,.35); backdrop-filter:blur(15px); }
.quality-summary { min-width:112px; display:flex; justify-content:center; align-items:center; gap:7px; color:#79818b; font:700 9px 'Manrope'; letter-spacing:.05em; }
.quality-summary i { width:3px; height:3px; border-radius:50%; background:#4e555e; }
.share-button { height:48px; min-width:190px; padding:0 23px; display:flex; align-items:center; justify-content:center; gap:10px; border:0; border-radius:8px; color:var(--ink); background:var(--accent); cursor:pointer; font-weight:700; transition:.18s; }
.share-button:hover { background:#e1ff70; transform:translateY(-1px); }
.share-button.live { color:white; background:#ba403d; }
.share-button.live:hover { background:#ce4a46; }
.dock-icon { width:48px; height:48px; display:grid; place-items:center; border-radius:8px; color:#8b939d; }
.dock-icon:hover { color:white; background:#292e35; }
.settings-dialog { width:min(500px,calc(100% - 30px)); padding:0; border:1px solid #343a43; border-radius:14px; color:white; background:#15191e; box-shadow:0 28px 100px rgba(0,0,0,.6); }
.settings-dialog::backdrop { background:rgba(4,5,7,.72); backdrop-filter:blur(4px); }
.settings-dialog form { padding:26px; }
.dialog-head { display:flex; align-items:flex-start; justify-content:space-between; margin-bottom:26px; }
.dialog-head .eyebrow { margin-bottom:6px; color:#77808b; font-size:8px; }
.dialog-head h3 { margin:0; font:700 24px 'Manrope'; letter-spacing:-.035em; }
.dialog-close { color:#7e8791; font-size:27px; line-height:1; }
.dialog-close:hover { color:white; }
fieldset { margin:0 0 24px; padding:0; border:0; }
legend { margin-bottom:10px; color:#8e96a0; font:700 10px 'Manrope'; letter-spacing:.1em; text-transform:uppercase; }
.option-grid { display:grid; gap:8px; }
.resolution-options { grid-template-columns:repeat(3,1fr); }
.fps-options { grid-template-columns:repeat(2,1fr); }
.option-grid label { margin:0; text-transform:none; letter-spacing:0; cursor:pointer; }
.option-grid input { position:absolute; opacity:0; pointer-events:none; }
.option-grid label span { min-height:68px; display:flex; flex-direction:column; justify-content:center; padding:0 13px; border:1px solid #30363e; border-radius:8px; background:#1a1f25; transition:.15s; }
.option-grid label:hover span { border-color:#535b65; }
.option-grid input:checked + span { border-color:var(--accent); background:rgba(215,255,69,.07); box-shadow:inset 0 0 0 1px var(--accent); }
.option-grid strong { font-size:13px; }
.option-grid small { margin-top:3px; color:#747d87; font-size:10px; font-weight:500; }
.option-grid input:checked + span small { color:#a6b268; }
.audio-option { margin:2px 0 25px; display:flex; align-items:center; text-transform:none; letter-spacing:0; cursor:pointer; }
.audio-option > span { flex:1; display:flex; flex-direction:column; }
.audio-option strong { font-size:13px; }
.audio-option small { margin-top:4px; color:#747d87; font-size:10px; font-weight:500; }
.audio-option input { display:none; }
.audio-option i { position:relative; width:40px; height:22px; border-radius:20px; background:#353b44; transition:.18s; }
.audio-option i::after { content:''; position:absolute; top:3px; left:3px; width:16px; height:16px; border-radius:50%; background:#8c949e; transition:.18s; }
.audio-option input:checked + i { background:var(--accent); }
.audio-option input:checked + i::after { left:21px; background:#15191e; }
.settings-dialog .primary-button { background:var(--accent); color:var(--ink); }
.settings-dialog .primary-button svg { color:var(--ink); }
.toast { position:fixed; z-index:50; left:50%; bottom:28px; transform:translate(-50%,20px); display:flex; align-items:center; gap:10px; padding:11px 15px; border:1px solid #3a414a; border-radius:8px; background:#20252b; opacity:0; pointer-events:none; transition:.22s; box-shadow:0 14px 35px rgba(0,0,0,.35); font-size:12px; }
.toast.show { opacity:1; transform:translate(-50%,0); }
.toast svg { width:15px; color:var(--accent); }
.session-overlay { position:fixed; z-index:100; inset:0; display:grid; place-items:center; padding:24px; color:white; background:rgba(8,10,13,.88); backdrop-filter:blur(18px); }
.session-card { width:min(430px,100%); padding:38px; text-align:center; border:1px solid #30363e; border-radius:16px; background:#15191e; box-shadow:0 30px 100px rgba(0,0,0,.5); }
.session-card .brand-mark { margin:0 auto 26px; }
.session-card .eyebrow { margin-bottom:9px; color:#808993; }
.session-card h2 { margin:0; font:700 27px/1.15 'Manrope'; letter-spacing:-.04em; }
.session-card > p:not(.eyebrow) { margin:13px auto 24px; color:#8c949e; font-size:13px; line-height:1.6; }
.session-loader { display:block; width:28px; height:28px; margin:5px auto 0; border:2px solid #343a42; border-top-color:var(--accent); border-radius:50%; animation:session-spin .8s linear infinite; }
.session-card .primary-button { margin-top:24px; color:var(--ink); background:var(--accent); }
@keyframes session-spin { to { transform:rotate(360deg); } }

html[data-theme="dark"] .entry-panel { color:#f5f6f7; background:#101318; }
html[data-theme="dark"] .entry-panel .section-index { color:#879064; }
html[data-theme="dark"] .entry-subtitle, html[data-theme="dark"] .secondary-button small { color:#858d96; }
html[data-theme="dark"] .field input { color:#f2f4f5; border-color:#30363e; background:#171b21; }
html[data-theme="dark"] .field input:focus { border-color:var(--accent); background:#1b2026; box-shadow:0 0 0 3px rgba(215,255,69,.1); }
html[data-theme="dark"] .field input::placeholder { color:#69717b; }
html[data-theme="dark"] .primary-button { color:var(--ink); background:var(--accent); }
html[data-theme="dark"] .primary-button svg { color:var(--ink); }
html[data-theme="dark"] .primary-button:hover { background:#e1ff70; }
html[data-theme="dark"] .secondary-button { color:#f3f5f6; border-color:#30363e; }
html[data-theme="dark"] .secondary-button:hover { background:#1a1f25; border-color:#4a525d; }
html[data-theme="dark"] .or span { background:#30363e; }
html[data-theme="dark"] .landing-theme { color:#a4acb5; border-color:#30363e; background:rgba(23,27,33,.86); }
html[data-theme="dark"] .landing-theme:hover { color:white; background:#242a31; }

html[data-theme="light"] .room { color:#171a1e; background:#e8e7e2; }
html[data-theme="light"] .room-sidebar { border-color:#d3d3ce; background:#f2f1ed; }
html[data-theme="light"] .room-sidebar .brand { color:#15181c; }
html[data-theme="light"] .sidebar-heading, html[data-theme="light"] .person-info small { color:#747a80; }
html[data-theme="light"] .person.sharing { background:#e1e3da; }
html[data-theme="light"] .avatar { color:#525961; background:#dfe1df; }
html[data-theme="light"] .sidebar-bottom { border-color:#d7d7d2; }
html[data-theme="light"] .icon-button:hover { color:#15181c; background:#dedfdb; }
html[data-theme="light"] .stage-shell { background:radial-gradient(circle at 50% 25%,#f5f4f0 0,#e9e8e3 64%,#dfded8 100%); }
html[data-theme="light"] .room-header { border-color:#d4d4cf; background:rgba(244,243,239,.86); }
html[data-theme="light"] .room-header .eyebrow { color:#777e83; }
html[data-theme="light"] .room-theme, html[data-theme="light"] .room-token { color:#60676e; border-color:#d0d1cd; background:#ebeae6; }
html[data-theme="light"] .room-theme:hover { color:#121519; background:#dedfdb; }
html[data-theme="light"] .room-token strong { color:#202328; }
html[data-theme="light"] .empty-icon { border-color:#c7cac8; background:#ecece8; }
html[data-theme="light"] .empty-icon i { border-color:#e8e7e2; }
html[data-theme="light"] .empty-state h3 { color:#44494e; }
html[data-theme="light"] .empty-state { color:#747b81; }
html[data-theme="light"] .control-dock { border-color:#cbccc8; background:rgba(246,245,241,.95); box-shadow:0 18px 50px rgba(45,48,43,.16); }
html[data-theme="light"] .dock-icon { color:#737a80; }
html[data-theme="light"] .dock-icon:hover { color:#15181c; background:#e2e2dd; }
html[data-theme="light"] .settings-dialog { color:#171a1e; border-color:#c9cac6; background:#f4f3ef; }
html[data-theme="light"] .dialog-close { color:#666d73; }
html[data-theme="light"] .option-grid label span { border-color:#ced0cc; background:#e9e9e5; }
html[data-theme="light"] .audio-option small, html[data-theme="light"] .option-grid small { color:#71777b; }
html[data-theme="light"] .session-overlay { color:#171a1e; background:rgba(230,229,224,.9); }
html[data-theme="light"] .session-card { border-color:#cbccc8; background:#f5f4f0; box-shadow:0 30px 100px rgba(45,48,43,.2); }
html[data-theme="light"] .session-card > p:not(.eyebrow) { color:#6f767c; }

@media (max-width:800px) {
  .landing { display:block; }
  .brand-panel { display:none; }
  .entry-panel { padding:28px 22px; }
  .entry-wrap { overflow:hidden; }
  .mobile-brand { margin-bottom:60px; display:flex; align-items:center; gap:10px; font:800 13px 'Manrope'; letter-spacing:.06em; }
  .mobile-brand .brand-mark { width:32px; height:32px; }
  .room { min-height:100dvh; height:100dvh; display:block; }
  .room-sidebar { position:fixed; z-index:20; left:0; right:0; bottom:0; height:66px; padding:8px 13px; display:block; border:0; border-top:1px solid var(--line); }
  .room-sidebar .brand, .sidebar-section { display:none; }
  .sidebar-bottom { height:100%; padding:0; border:0; }
  .stage-shell { height:calc(100dvh - 66px); grid-template-rows:auto 1fr auto; }
  .room-header { height:68px; padding:0 15px; }
  .room-header > div:first-child .eyebrow { display:none; }
  .room-header h2 { font-size:15px; }
  .room-token { gap:7px; height:38px; padding-left:10px; }
  .room-theme { width:38px; height:38px; }
  .room-token > span { display:none; }
  .room-token strong { font-size:10px; }
  .stage { padding:12px; }
  .video-grid { grid-template-columns:1fr; grid-auto-rows:minmax(190px,1fr); }
  .control-dock { width:calc(100% - 24px); height:60px; margin:0 12px 12px; }
  .quality-summary { display:none; }
  .share-button { min-width:0; flex:1; height:46px; }
  .dock-icon { height:46px; }
  .resolution-options { grid-template-columns:1fr; }
  .resolution-options label span { min-height:58px; }
}
