/* Prototype chrome only: the phone frame and the control panel. None of this ships in the app. */
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body {
  background:
    radial-gradient(50% 50% at 85% 10%, rgb(123 92 255 / 0.2), transparent 70%),
    radial-gradient(45% 45% at 10% 90%, rgb(164 205 57 / 0.13), transparent 70%),
    #060608;
  color: #f3f3f1;
  font-family: "Plus Jakarta Sans", Arial, Helvetica, sans-serif;
  display: grid;
  grid-template-columns: 330px 1fr;
  overflow: hidden;
}

#panel { height: 100dvh; overflow-y: auto; padding: 22px 20px 30px; border-right: 1px solid rgb(255 255 255 / 0.1); background: rgb(14 14 18 / 0.85); scrollbar-width: thin; scrollbar-color: #333 transparent; }
#panel h1 { margin: 2px 0 6px; font-family: "Unbounded", "Arial Black", sans-serif; font-weight: 800; font-size: 18px; text-transform: uppercase; line-height: 1.1; }
#panel h2 { margin: 22px 0 8px; font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: rgb(255 255 255 / 0.55); }
#panel h2 span { color: #a4cd39; letter-spacing: 0; }
.panel-eyebrow { margin: 0; font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: #a4cd39; }
.panel-sub { margin: 0; font-size: 13px; line-height: 1.45; color: rgb(255 255 255 / 0.66); }
#panel button { font: inherit; color: inherit; cursor: pointer; }
#panel :focus-visible, #panel-fab:focus-visible { outline: 2px solid #a4cd39; outline-offset: 2px; }
.roles { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.roles button { min-height: 44px; border-radius: 12px; border: 1px solid rgb(255 255 255 / 0.14); background: rgb(255 255 255 / 0.05); font-weight: 800; font-size: 13px; transition: background 0.18s; }
.roles button:hover { background: rgb(255 255 255 / 0.12); }
.roles button.on { background: #a4cd39; color: #0a0a0a; border-color: #a4cd39; }
.demo { display: flex; flex-direction: column; gap: 6px; }
.demo button { min-height: 40px; padding: 6px 12px; text-align: left; border-radius: 10px; border: 1px solid rgb(255 255 255 / 0.12); background: rgb(255 255 255 / 0.04); font-size: 13px; font-weight: 600; display: flex; justify-content: space-between; gap: 8px; align-items: center; transition: background 0.18s; }
.demo button:hover { background: rgb(255 255 255 / 0.11); }
.demo button em { font-style: normal; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 9px; background: rgb(255 255 255 / 0.12); white-space: nowrap; }
.demo button em.on { background: #a4cd39; color: #0a0a0a; }
.index { display: flex; flex-direction: column; }
.index h3 { margin: 12px 0 4px; font-size: 12px; font-weight: 800; color: #2fd6c9; }
.index button { text-align: left; min-height: 32px; padding: 4px 10px; border: 0; border-radius: 8px; background: none; font-size: 13px; font-weight: 500; color: rgb(255 255 255 / 0.8); }
.index button:hover { background: rgb(255 255 255 / 0.08); color: #fff; }
.index button.on { background: rgb(164 205 57 / 0.16); color: #c6f04f; font-weight: 700; }

#stage { height: 100dvh; display: flex; align-items: center; justify-content: center; padding: 20px; min-width: 0; }
.phone {
  position: relative; width: 390px; height: min(844px, calc(100dvh - 40px)); flex: none;
  background: var(--ink); border-radius: 52px; overflow: hidden;
  box-shadow: 0 0 0 2px #2c2c33, 0 0 0 11px #121216, 0 0 0 12.5px #34343c, 0 40px 90px -20px #000;
  display: flex; flex-direction: column;
}
.phone::before { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 0; background: radial-gradient(60% 34% at 100% 0%, rgb(123 92 255 / 0.2), transparent 70%), radial-gradient(60% 30% at 0% 100%, rgb(47 214 201 / 0.1), transparent 70%); }
.phone > * { position: relative; z-index: 1; }
.phone > #sheet { position: absolute; z-index: 40; }
.phone > #toast { position: absolute; z-index: 60; }
.phone > #push { position: absolute; z-index: 70; }
.statusbar { height: 46px; flex: none; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 6px 30px 0; font-size: 14.5px; font-weight: 700; }
.sb-island { width: 104px; height: 28px; border-radius: 16px; background: #000; }
.sb-icons { justify-self: end; display: inline-flex; align-items: center; gap: 6px; font-size: 12px; }
.sb-off { display: none; color: #ffcf3a; }
.is-offline .sb-off { display: inline; } .is-offline .sb-net { display: none; }
.sb-batt { width: 24px; height: 12px; border-radius: 4px; border: 1.5px solid rgb(255 255 255 / 0.6); padding: 1.5px; display: inline-block; }
.sb-batt i { display: block; width: 72%; height: 100%; border-radius: 1.5px; background: #fff; }

#panel-fab { display: none; }

/* Phone-width viewport: the app fills the screen, controls move into a drawer */
@media (max-width: 760px) {
  body { display: block; }
  #stage { padding: 0; }
  .phone { width: 100vw; height: 100dvh; border-radius: 0; box-shadow: none; }
  .sb-island { visibility: hidden; }
  .statusbar { height: 34px; padding: 4px 22px 0; }
  #panel { position: fixed; inset: 0 auto 0 0; width: min(330px, 88vw); z-index: 200; translate: -105% 0; transition: translate 0.3s cubic-bezier(0.22, 1, 0.36, 1); background: #0e0e12; }
  #panel.open { translate: 0 0; box-shadow: 0 0 0 100vmax rgb(0 0 0 / 0.6); }
  #panel-fab { display: block; position: fixed; z-index: 210; right: 0; top: 38%; writing-mode: vertical-rl; padding: 12px 7px; min-height: 44px; border: 0; border-radius: 12px 0 0 12px; background: #7b5cff; color: #fff; font: 800 11px/1 "Plus Jakarta Sans", Arial, sans-serif; letter-spacing: 0.12em; text-transform: uppercase; cursor: pointer; opacity: 0.92; }
}
