:root {
  --blue: #1a73e8; --blue-hover: #1765cc; --blue-light: #8ab4f8;
  --red: #ea4335; --text: #202124; --muted: #5f6368; --line: #dadce0;
  --bg: #fff; --meet-bg: #202124; --tile: #3c4043; --btn: #3c4043; --btn-hover: #4a4e51;
  --panel: #fff; --panel-text: #202124;
}
@media (prefers-color-scheme: dark) {
  :root { --text: #e8eaed; --muted: #9aa0a6; --line: #3c4043; --bg: #202124; --panel: #2d2e31; --panel-text: #e8eaed; }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: "Google Sans", Roboto, -apple-system, system-ui, sans-serif; color: var(--text); background: var(--bg); }
button { font: inherit; cursor: pointer; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.ms { font-family: "Material Symbols Outlined"; font-weight: normal; font-style: normal; font-size: 24px; line-height: 1;
  letter-spacing: normal; text-transform: none; white-space: nowrap; direction: ltr; -webkit-font-smoothing: antialiased; user-select: none; }
.ms.big { font-size: 96px; color: var(--blue); }
.view { min-height: 100%; }

/* top bar */
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; }
.brand { display: flex; align-items: center; gap: 8px; font-size: 22px; }
.brand b { font-weight: 500; }
.logo { width: 32px; height: 32px; border-radius: 9px; background: var(--blue); color: #fff; display: grid; place-items: center; }
.logo .ms { font-size: 20px; font-variation-settings: "FILL" 1; }
.brand.plain { color: inherit; text-decoration: none; }
.clock { color: var(--muted); font-size: 18px; }

/* buttons */
.btn { text-decoration: none; display: inline-flex; align-items: center; gap: 8px; border: 0; border-radius: 4px; padding: 0 20px; height: 44px;
  font-weight: 500; font-size: 15px; background: none; color: var(--blue); transition: background .15s, box-shadow .15s; }
.btn.primary { background: var(--blue); color: #fff; }
.btn.primary:hover { background: var(--blue-hover); box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.btn.text:hover:not(:disabled) { background: rgba(26,115,232,.08); }
.btn.outline { border: 1px solid var(--line); }
.btn:disabled { color: var(--muted); opacity: .6; cursor: default; }
.btn.pill { border-radius: 24px; height: 48px; padding: 0 32px; }
.btn.small { height: 32px; font-size: 13px; padding: 0 10px; }
.icon-btn { border: 0; background: none; color: inherit; width: 40px; height: 40px; border-radius: 50%; position: relative;
  display: inline-flex; align-items: center; justify-content: center; }
.icon-btn:hover { background: rgba(128,128,128,.15); }
.icon-btn.light { color: #e8eaed; width: 48px; height: 48px; }
.icon-btn.light.on { color: var(--blue-light); }

/* home */
.hero { display: flex; align-items: center; justify-content: space-between; gap: 48px; padding: 6vh 6vw; flex-wrap: wrap; }
.hero-text { max-width: 600px; flex: 1 1 420px; }
.hero h1 { font-size: clamp(32px, 4vw, 44px); font-weight: 400; line-height: 1.2; margin: 0 0 16px; }
.hero p { font-size: 18px; line-height: 1.5; }
.hero-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 40px 0 32px; }
.code-input { display: flex; align-items: center; gap: 12px; border: 1px solid var(--muted); border-radius: 4px; padding: 0 14px; height: 48px; flex: 1 1 220px; max-width: 280px; }
.code-input:focus-within { border: 2px solid var(--blue); padding: 0 13px; }
.code-input input { border: 0; outline: 0; font: inherit; font-size: 16px; background: none; color: var(--text); width: 100%; }
.code-input .ms { color: var(--muted); }
hr { border: 0; border-top: 1px solid var(--line); margin: 0 0 20px; }
.hero-art { flex: 0 1 360px; text-align: center; }
.art-circle { width: 260px; height: 260px; border-radius: 50%; margin: 0 auto 24px; display: grid; place-items: center; background: rgba(26,115,232,.08); }
.hero-art h3 { font-weight: 400; font-size: 24px; margin: 0 0 8px; }

/* lobby */
.lobby { display: flex; align-items: center; justify-content: center; gap: 48px; padding: 4vh 24px; flex-wrap: wrap; }
.preview { position: relative; width: min(740px, 100%); aspect-ratio: 16/9; background: var(--meet-bg); border-radius: 8px; overflow: hidden; }
.preview video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.preview-off { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; font-size: 22px; }
.preview-name { position: absolute; top: 14px; left: 16px; color: #fff; font-size: 15px; text-shadow: 0 1px 2px #000; }
.preview-controls { position: absolute; bottom: 16px; left: 0; right: 0; display: flex; justify-content: center; gap: 24px; }
.preview .round { width: 56px; height: 56px; border: 1px solid #fff; background: transparent; }
.preview .round.off { background: var(--red); border-color: var(--red); }
.device-error { position: absolute; top: 40%; left: 10%; right: 10%; text-align: center; color: #fff; background: rgba(0,0,0,.6); padding: 12px; border-radius: 8px; font-size: 14px; }
.lobby-side { width: 320px; max-width: 100%; text-align: center; display: flex; flex-direction: column; gap: 16px; align-items: center; }
.lobby-side h2 { font-weight: 400; font-size: 28px; margin: 0; }
.field { width: 100%; height: 52px; border: 1px solid var(--muted); border-radius: 4px; padding: 0 14px; font: inherit; font-size: 16px; background: none; color: var(--text); }
.field:focus { outline: 2px solid var(--blue); border-color: transparent; }
.device-row { display: flex; flex-direction: column; gap: 8px; width: 100%; }
.device-row label { display: flex; align-items: center; gap: 8px; color: var(--muted); }
.device-row select { flex: 1; min-width: 0; height: 36px; border: 1px solid var(--line); border-radius: 18px; padding: 0 10px; background: none; color: var(--text); font: inherit; font-size: 13px; }

.center-msg { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; padding: 24px; min-height: 100vh; }
.center-msg h2 { font-weight: 400; font-size: 32px; margin: 0; }
.row { display: flex; gap: 12px; flex-wrap: wrap; justify-content: center; margin-top: 16px; }
.spinner { width: 40px; height: 40px; border: 4px solid var(--line); border-top-color: var(--blue); border-radius: 50%; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* meeting */
#meeting { position: fixed; inset: 0; background: var(--meet-bg); color: #e8eaed; display: grid;
  grid-template-columns: 1fr auto; grid-template-rows: 1fr 80px; }
.stage { position: relative; grid-column: 1; grid-row: 1; padding: 16px 16px 0; min-height: 0; overflow: hidden; }
.grid { height: 100%; display: grid; gap: 10px; place-content: center;
  grid-template-columns: repeat(var(--cols, 1), minmax(0, 1fr)); grid-auto-rows: minmax(0, 1fr); }
.grid.speaker { grid-template-columns: 1fr 220px; grid-template-rows: repeat(var(--side, 1), minmax(0, 1fr)); }
.grid.speaker .tile.main { grid-column: 1; grid-row: 1 / -1; }
.grid.speaker .tile:not(.main) { grid-column: 2; }
.tile { position: relative; background: var(--tile); border-radius: 8px; overflow: hidden; min-height: 0; aspect-ratio: 16/9;
  max-height: 100%; width: 100%; transition: box-shadow .15s; }
.grid.speaker .tile { aspect-ratio: auto; }
.tile video { width: 100%; height: 100%; object-fit: cover; display: block; }
.tile.local.mirror video { transform: scaleX(-1); }
.tile.screen video { object-fit: contain; background: #000; }
.tile.speaking { box-shadow: inset 0 0 0 3px var(--blue-light); }
.avatar { position: absolute; inset: 0; display: grid; place-items: center; }
.avatar span { width: clamp(56px, 22%, 140px); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; font-size: clamp(22px, 4vw, 52px); color: #fff; }
.tile .name { position: absolute; left: 12px; bottom: 10px; font-size: 14px; text-shadow: 0 1px 2px rgba(0,0,0,.8); display: flex; gap: 6px; align-items: center; }
.tile .badges { position: absolute; right: 10px; top: 10px; display: flex; gap: 6px; }
.tile .badges .ms { font-size: 18px; width: 28px; height: 28px; display: grid; place-items: center; border-radius: 50%; background: rgba(32,33,36,.7); }
.tile .badges .hand { background: #fff; color: #202124; }
.tile .badges .net-bad { color: #fbbc04; }
.tile .pin { position: absolute; inset: 0; margin: auto; width: 48px; height: 48px; border-radius: 50%; border: 0; background: rgba(32,33,36,.7); color: #fff; opacity: 0; transition: opacity .15s; }
.tile:hover .pin { opacity: 1; }

.controlbar { grid-column: 1 / -1; grid-row: 2; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 0 16px; gap: 8px; }
.cb-left { font-size: 16px; display: flex; gap: 10px; white-space: nowrap; overflow: hidden; }
.cb-left .sep { color: #5f6368; }
.cb-center { display: flex; gap: 10px; align-items: center; }
.cb-right { display: flex; justify-content: flex-end; }
.round { width: 48px; height: 48px; border-radius: 50%; border: 0; background: var(--btn); color: #e8eaed; display: grid; place-items: center; transition: background .15s, border-radius .2s; }
.round:hover { background: var(--btn-hover); }
.round.off { background: var(--red); color: #fff; }
.round.on { background: #8ab4f8; color: #202124; }
.hangup { width: 64px; height: 48px; border-radius: 24px; border: 0; background: var(--red); color: #fff; display: grid; place-items: center; }
.hangup:hover { background: #d93025; }
.badge { position: absolute; top: 4px; right: 2px; background: #5f6368; color: #fff; font: 500 11px Roboto, sans-serif; border-radius: 9px; min-width: 18px; height: 18px; padding: 0 4px; display: grid; place-items: center; }
.dot { position: absolute; top: 10px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--blue-light); }

.emoji-wrap { position: relative; }
.emoji-pop, .menu { position: absolute; bottom: 60px; left: 50%; transform: translateX(-50%); background: #3c4043; border-radius: 24px; padding: 6px; display: flex; gap: 2px; box-shadow: 0 4px 12px rgba(0,0,0,.4); z-index: 20; }
.emoji-pop button { border: 0; background: none; font-size: 26px; width: 44px; height: 44px; border-radius: 50%; }
.emoji-pop button:hover { background: rgba(255,255,255,.12); transform: scale(1.15); }
.menu { flex-direction: column; border-radius: 6px; padding: 8px 0; min-width: 240px; background: #fff; color: #202124; }
.menu button { border: 0; background: none; display: flex; gap: 16px; align-items: center; padding: 10px 16px; text-align: left; font-size: 14px; color: inherit; }
.menu button:hover { background: #f1f3f4; }
.menu .ms { color: #5f6368; font-size: 20px; }

.panel { grid-column: 2; grid-row: 1; width: 360px; margin: 16px 16px 0 0; background: var(--panel); color: var(--panel-text);
  border-radius: 8px; display: flex; flex-direction: column; min-height: 0; animation: slidein .2s ease-out; }
@keyframes slidein { from { transform: translateX(24px); opacity: 0; } }
.panel-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 12px 4px 24px; }
.panel-head h3 { font-weight: 400; font-size: 18px; margin: 0; }
.panel-body { flex: 1; min-height: 0; overflow-y: auto; padding: 8px 24px 16px; display: flex; flex-direction: column; gap: 8px; }
#panelChat, #panelAI { padding-bottom: 0; }
.section-label { font-size: 12px; text-transform: uppercase; letter-spacing: .6px; color: var(--muted); margin: 12px 0 4px; }
.person { display: flex; align-items: center; gap: 12px; padding: 6px 0; }
.person .av { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 14px; flex: none; }
.person .pname { flex: 1; min-width: 0; font-size: 14px; }
.person .pname small { display: block; color: var(--muted); font-size: 12px; }
.person .ms { font-size: 20px; color: var(--muted); }
.person .icon-btn { width: 32px; height: 32px; }
.host-tools { display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; }
.toggle { display: flex; justify-content: space-between; align-items: center; font-size: 14px; padding: 4px 0; }
.toggle input { width: 36px; height: 20px; accent-color: var(--blue); }
.info-box { background: rgba(128,128,128,.12); border-radius: 8px; padding: 12px; font-size: 12px; line-height: 1.5; margin: 0; color: var(--muted); }
.info-box.ai { display: flex; gap: 8px; }
.info-box.ai .ms { color: var(--blue); font-size: 20px; }
.chat-list { flex: 1; display: flex; flex-direction: column; gap: 14px; padding: 8px 0; }
.msg .meta { font-size: 13px; font-weight: 500; }
.msg .meta time { font-weight: 400; color: var(--muted); margin-left: 8px; font-size: 12px; }
.msg .body { font-size: 14px; line-height: 1.5; margin-top: 2px; word-wrap: break-word; white-space: pre-wrap; }
.msg.ai .body { white-space: normal; background: rgba(26,115,232,.07); padding: 10px 12px; border-radius: 8px; }
.msg.ai .body p { margin: 4px 0; } .msg.ai .body ul { margin: 4px 0; padding-left: 18px; } .msg.ai .body h4 { margin: 8px 0 2px; font-size: 13px; }
.msg.ai .ts { color: var(--blue); font-weight: 500; }
.msg.err .body { color: var(--red); }
.chat-form { position: sticky; bottom: 0; display: flex; align-items: center; background: rgba(128,128,128,.12); border-radius: 24px; padding: 4px 4px 4px 16px; margin: 8px 0 16px; }
.chat-form input { flex: 1; border: 0; background: none; outline: 0; font: inherit; font-size: 14px; color: var(--panel-text); height: 40px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { border: 1px solid var(--line); background: none; color: var(--panel-text); border-radius: 8px; font-size: 12px; padding: 6px 10px; }
.chip:hover { background: rgba(26,115,232,.08); border-color: var(--blue); }
.link-text { font-size: 14px; word-break: break-all; }
.shortcuts { padding-left: 0; list-style: none; font-size: 13px; line-height: 2; }
kbd { border: 1px solid var(--line); border-radius: 4px; padding: 1px 5px; font: 12px Roboto, monospace; }

.captions { position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%); width: min(820px, 92%); background: rgba(0,0,0,.75); border-radius: 8px; padding: 10px 16px; font-size: 18px; line-height: 1.4; z-index: 5; }
.captions .cap { margin: 2px 0; }
.captions .cap b { color: #8ab4f8; font-weight: 500; margin-right: 8px; }
.captions .cap.interim span { opacity: .7; }
.notice { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); z-index: 6; background: #fff; color: #202124; border-radius: 8px; padding: 6px 6px 6px 14px; display: flex; gap: 10px; align-items: center; font-size: 14px; box-shadow: 0 2px 8px rgba(0,0,0,.4); max-width: 92%; }
.notice .ms { color: var(--blue); }
.reactions-layer { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.floater { position: absolute; bottom: 0; font-size: 40px; animation: floatup 3.2s ease-out forwards; text-align: center; }
.floater small { display: block; font-size: 11px; background: rgba(32,33,36,.8); color: #fff; border-radius: 8px; padding: 1px 6px; margin-top: 2px; }
@keyframes floatup { 0% { transform: translateY(0); opacity: 0; } 10% { opacity: 1; } 100% { transform: translateY(-70vh); opacity: 0; } }
.toast { position: fixed; left: 24px; bottom: 96px; background: #323232; color: #fff; padding: 14px 20px; border-radius: 4px; font-size: 14px; z-index: 50; box-shadow: 0 3px 8px rgba(0,0,0,.4); max-width: calc(100% - 48px); }

@media (max-width: 800px) {
  #meeting { grid-template-columns: 1fr; grid-template-rows: 1fr auto; }
  .panel { position: fixed; inset: 0 0 80px 0; width: auto; margin: 0; border-radius: 0; z-index: 30; }
  .controlbar { grid-template-columns: 1fr; padding: 8px; }
  .cb-left { display: none; } .cb-center { justify-content: center; gap: 6px; flex-wrap: wrap; }
  .cb-right { justify-content: center; }
  .round { width: 42px; height: 42px; } .hangup { width: 54px; height: 42px; }
  #shareBtn { display: none; }
  .grid { grid-template-columns: repeat(min(var(--cols, 1), 2), minmax(0, 1fr)); }
  .grid.speaker { grid-template-columns: 1fr; } .grid.speaker .tile:not(.main) { display: none; }
  .tile { aspect-ratio: auto; }
  .stage { padding: 8px 8px 0; }
}

/* nav + plans */
.nav { display: flex; align-items: center; gap: 12px; }
.nav a { text-decoration: none; }
.plan-chip { font-size: 12px; font-weight: 500; border: 1px solid var(--line); border-radius: 12px; padding: 3px 10px; color: var(--muted); }
.plan-chip:empty { display: none; }
.pricing { max-width: 1200px; margin: 0 auto; padding: 24px 24px 64px; text-align: center; }
.pricing h1 { font-weight: 400; font-size: clamp(28px, 4vw, 40px); margin: 16px 0 8px; }
.billing-toggle { display: inline-flex; border: 1px solid var(--line); border-radius: 20px; padding: 3px; margin: 20px 0; }
.billing-toggle button { border: 0; background: none; color: var(--text); padding: 6px 16px; border-radius: 16px; font-size: 14px; }
.billing-toggle button.on { background: rgba(26,115,232,.12); color: var(--blue); font-weight: 500; }
.billing-toggle small { color: #188038; margin-left: 4px; }
.test-banner { display: flex; gap: 10px; align-items: center; text-align: left; max-width: 720px; margin: 0 auto 20px; padding: 10px 14px; border-radius: 8px; background: rgba(249,171,0,.12); font-size: 13px; }
.test-banner .ms { color: #e37400; }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; text-align: left; }
.plan { border: 1px solid var(--line); border-radius: 12px; padding: 24px; display: flex; flex-direction: column; gap: 12px; position: relative; }
.plan.highlight { border: 2px solid var(--blue); }
.plan .tag { position: absolute; top: -11px; left: 20px; background: var(--blue); color: #fff; font-size: 11px; font-weight: 500; padding: 3px 10px; border-radius: 10px; }
.plan h3 { margin: 0; font-weight: 500; font-size: 20px; }
.plan .tagline { color: var(--muted); font-size: 14px; margin: 0; min-height: 40px; }
.plan .price { font-size: 36px; } .plan .price small { font-size: 13px; color: var(--muted); margin-left: 4px; }
.plan ul { list-style: none; padding: 0; margin: 4px 0 0; display: flex; flex-direction: column; gap: 9px; font-size: 14px; }
.plan li { display: flex; gap: 8px; align-items: flex-start; }
.plan li .ms { font-size: 18px; color: #188038; }
.plan li.off { color: var(--muted); } .plan li.off .ms { color: var(--muted); }
.soon { font-size: 10px; font-weight: 500; text-transform: uppercase; letter-spacing: .4px; border: 1px solid var(--line); border-radius: 8px; padding: 1px 6px; white-space: nowrap; color: var(--muted); }
.plan .btn { justify-content: center; }
.plan .tagline { min-height: 40px; }
.plan .btn.current { border: 1px solid var(--line); color: var(--muted); cursor: default; }
.center { text-align: center; margin-top: 24px; }

a { color: var(--blue); }
@media (prefers-color-scheme: dark) { a { color: var(--blue-light); } }

/* Phone visitors see a focused desktop-only message while desktop behavior remains unchanged. */
.mobile-gate { display: none; }
@media (max-width: 767px) {
  .mobile-gate {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: #050505;
    color: #fff;
    text-align: center;
  }
  .mobile-gate-card {
    width: min(100%, 360px);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 28px;
  }
  .mobile-gate-icon {
    display: block;
    width: min(78vw, 300px);
    height: auto;
    border-radius: 10px;
  }
  .mobile-gate-card h1 {
    max-width: 320px;
    margin: 0;
    font: 500 clamp(24px, 7vw, 34px)/1.15 Inter, Arial, sans-serif;
    letter-spacing: -.02em;
  }
}
