/* The look the PC app, the phone app and the payment page share. It is emulatorstudio.app's look: the same tokens,
   cut-glass panels, octagon controls and status marks (its site.css is the source of the shapes below). */

@font-face { font-family: "Bricolage Grotesque"; font-weight: 500 800; font-display: swap; src: url(fonts/bricolage-grotesque-latin.woff2) format("woff2"); }
@font-face { font-family: "Onest"; font-weight: 400 700; font-display: swap; src: url(fonts/onest-latin-ext.woff2) format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Onest"; font-weight: 400 700; font-display: swap; src: url(fonts/onest-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "JetBrains Mono"; font-weight: 400 600; font-display: swap; src: url(fonts/jetbrains-mono-latin.woff2) format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root { --inset-top: env(safe-area-inset-top, 0px); --inset-bottom: env(safe-area-inset-bottom, 0px); }

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--frame1); scrollbar-color: var(--line-2) transparent; -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; color: var(--ink); font: 400 .9375rem/1.5 var(--f-ui); -webkit-font-smoothing: antialiased; }
::selection { background: var(--acc-soft); }
a { color: inherit; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3 { text-wrap: balance; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { cursor: default; }
img, svg, video { display: block; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* ---- the ground ---- */
.atmo {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(78% 62% at 62% 6%, var(--pool-a), transparent 72%),
    radial-gradient(52% 44% at 98% 22%, var(--pool-b), transparent 70%),
    radial-gradient(64% 54% at 8% 78%, var(--pool-c), transparent 72%),
    linear-gradient(124deg, transparent 4%, var(--fan-a) 11%, transparent 18%, var(--fan-b) 25%, transparent 32%, var(--fan-c) 38%, transparent 45%),
    radial-gradient(135% 105% at 50% 32%, transparent 50%, var(--frame2) 100%),
    linear-gradient(var(--frame1), var(--frame2));
}

/* ---- the mark and icons ---- */
.sp0 { stop-color: var(--spec-0); } .sp1 { stop-color: var(--spec-1); } .sp2 { stop-color: var(--spec-2); } .sp3 { stop-color: var(--spec-3); }
.tl0 { stop-color: var(--mk-t0); } .tl1 { stop-color: var(--mk-t1); }
.rm0 { stop-color: var(--mk-r0); } .rm1 { stop-color: var(--mk-r1); } .rm2 { stop-color: var(--mk-r2); }
.mark { width: 28px; height: 28px; flex: none; overflow: visible; }
.mk-tile { fill: url(#es-tile); stroke: url(#es-rim); stroke-width: 1; }
.mk-glint { fill: none; stroke: url(#es-spec); stroke-width: 1.6; stroke-linecap: round; }
.mk-cell { fill: none; stroke: var(--mk-ring); stroke-width: 1.2; }
.mk-live { fill: url(#es-spec); }
.defs { position: absolute; width: 0; height: 0; }
.ico { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.ico.solid { fill: currentColor; stroke: none; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font: 700 1.125rem/1 var(--f-dsp); letter-spacing: -.015em; white-space: nowrap; }

/* ---- panels, cut at the top-left and bottom-right ---- */
.glass { position: relative; isolation: isolate; }
.glass::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  clip-path: var(--cutp); border: 1px solid transparent; border-image: var(--facet-panel) 13 / 13px stretch;
  background: linear-gradient(var(--sheen), transparent 2.75rem), linear-gradient(var(--glass1), var(--glass2));
}
.glass.pop::before { border-image-source: var(--facet-pop); background: linear-gradient(var(--sheen), transparent 2.75rem), linear-gradient(var(--pop1), var(--pop2)); }

/* ---- controls, an octagon cut on every corner ---- */
.btn {
  position: relative; isolation: isolate; display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 40px; padding: 0 16px; border: 0; background: transparent; color: var(--ink);
  font: 600 .875rem/1 var(--f-ui); text-decoration: none; cursor: pointer; white-space: nowrap; -webkit-tap-highlight-color: transparent;
}
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  clip-path: var(--oct); border: 1px solid transparent; border-image: var(--facet-ctl) 6 / 6px stretch;
  background: linear-gradient(var(--ctl1), var(--ctl2));
}
.btn:hover:not(:disabled)::before { background: linear-gradient(var(--ctl-h1), var(--ctl-h2)); }
.btn:active:not(:disabled)::before { filter: brightness(.92); }
.btn:disabled { opacity: .55; }
.btn:focus-visible { outline: 2px solid transparent; }
.btn:focus-visible::before { box-shadow: inset 0 0 0 2px var(--focus); }
.btn.pri { color: var(--on-acc); }
.btn.pri::before { border-image-source: var(--facet-pri); background: var(--pri); }
.btn.pri:hover:not(:disabled)::before { background: var(--pri-h); }
.btn.pri:focus-visible::before { box-shadow: inset 0 0 0 2px var(--on-acc); }
.btn.ghost::before { background: transparent; border-image: none; }
.btn.ghost:hover:not(:disabled)::before { background: var(--well-2); }
.btn.danger { color: var(--enemy-text); }
.btn.sm { min-height: 34px; padding: 0 12px; font-size: .8125rem; }
.btn.lg { min-height: 48px; padding: 0 22px; font-size: .9375rem; }
.btn.wide { width: 100%; }
.btn.sq { width: 40px; padding: 0; }
.btn.sq.sm { width: 34px; }
.link { padding: 0; border: 0; background: none; color: var(--acc-text); font-size: inherit; text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }

/* ---- type ---- */
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font: 500 .75rem/1.2 var(--f-lab); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.eyebrow::before { content: ""; width: 20px; height: 2px; background: var(--spec-line); flex: none; }
.title { font: 700 1.875rem/1.08 var(--f-dsp); letter-spacing: -.026em; }
.h2 { font: 650 1.1875rem/1.2 var(--f-dsp); letter-spacing: -.012em; }
.lab { font: 500 .6875rem/1.2 var(--f-lab); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-3); }
.tag { font: 500 .6875rem/1 var(--f-lab); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-2); padding: 5px 7px; border-radius: var(--r-tag); background: var(--well-2); white-space: nowrap; }
.tag.acc { color: var(--on-acc); background: var(--acc); }
.tag.warn { color: var(--busy-text); background: var(--busy-soft); }
.copy { color: var(--ink-2); overflow-wrap: anywhere; }
.fine { font-size: .8125rem; line-height: 1.5; color: var(--ink-3); }
.error { color: var(--enemy-text); font-size: .875rem; }
.num { font-variant-numeric: tabular-nums; }
.mono { font-family: var(--f-xy); }

/* ---- status marks: their shapes differ, so state never rests on colour alone ---- */
.gem { width: 10px; height: 10px; display: inline-block; flex: none; border-radius: 50%; }
.gem.running { box-shadow: inset 0 0 0 1.5px var(--good-text); background: radial-gradient(circle, var(--good-text) 0 2.4px, transparent 2.9px); }
.gem.starting, .gem.stopping { box-shadow: inset 0 0 0 1.5px var(--busy-text); background: linear-gradient(90deg, var(--busy-text) 50%, transparent 50%); }
.gem.stopped { width: 8px; height: 8px; border-radius: 1px; background: var(--ink-3); }
.gem.missing { width: 9px; height: 9px; border-radius: 1px; box-shadow: inset 0 0 0 1.5px var(--enemy-text); }
.dot { width: 7px; height: 7px; border-radius: 50%; display: inline-block; flex: none; background: var(--ink-3); }
.dot.on { background: var(--good-text); }
.dot.busy { background: var(--busy-text); }

/* ---- fields ---- */
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field > span, .field-label { font-size: .875rem; font-weight: 600; color: var(--ink); }
.input { height: 44px; width: 100%; min-width: 0; padding: 0 12px; border: 1px solid var(--line-2); border-radius: var(--r-ctl); background: var(--field); color: var(--ink); font-size: .9375rem; }
.input::placeholder { color: var(--ink-3); }
.input:focus { outline: 2px solid var(--focus); outline-offset: -1px; border-color: transparent; }
.input.code { height: 56px; text-align: center; font: 500 1.5rem/1 var(--f-xy); letter-spacing: .22em; text-indent: .22em; text-transform: uppercase; }
select.input { appearance: none; padding-right: 34px; background-image: linear-gradient(45deg, transparent 50%, var(--ink-2) 50%), linear-gradient(135deg, var(--ink-2) 50%, transparent 50%); background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px; background-size: 5px 5px; background-repeat: no-repeat; }
input[type="checkbox"] { appearance: none; display: grid; place-items: center; width: 20px; height: 20px; flex: none; margin: 0; border: 1px solid var(--line-2); border-radius: var(--r-ctl); background: var(--field); }
input[type="checkbox"]:checked { border-color: transparent; background: var(--acc); }
input[type="checkbox"]:checked::after { content: ""; width: 5px; height: 10px; margin-top: -2px; border: solid var(--on-acc); border-width: 0 2px 2px 0; transform: rotate(45deg); }
select.input option { background: var(--bg-2); color: var(--ink); }

.switch { position: relative; width: 44px; height: 26px; flex: none; padding: 0; border: 0; border-radius: 13px; background: var(--well-2); box-shadow: inset 0 0 0 1px var(--line-2); transition: background var(--t-med) var(--ease); }
.switch::after { content: ""; position: absolute; left: 4px; top: 4px; width: 18px; height: 18px; border-radius: 50%; background: var(--ink-2); transition: transform var(--t-med) var(--ease), background var(--t-med); }
.switch[aria-checked="true"] { background: var(--acc); box-shadow: none; }
.switch[aria-checked="true"]::after { transform: translateX(18px); background: var(--on-acc); }
.switch:disabled { opacity: .55; }

.seg { display: inline-flex; gap: 2px; padding: 3px; background: var(--well); clip-path: var(--oct); }
.seg button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; background: transparent; color: var(--ink-2); font: 600 .8125rem/1 var(--f-ui); padding: 10px 14px; clip-path: var(--oct-s); }
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--acc-soft); color: var(--acc-text); }
.seg button:focus-visible { outline-offset: -2px; }

.ticks { display: flex; flex-direction: column; gap: 12px; }
.ticks li { display: grid; grid-template-columns: 18px minmax(0, 1fr); gap: 10px; color: var(--ink-2); }
.ticks .ico { margin-top: 2px; color: var(--acc-text); }

.rows { display: flex; flex-direction: column; }
.line { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px; padding: 10px 0; border-top: 1px solid var(--hair); }
.line:first-child { border-top: 0; }
.line > span:first-child { min-width: 0; }
.line b { display: block; font-weight: 600; overflow-wrap: anywhere; }
.line small { display: block; font-size: .8125rem; color: var(--ink-3); }
.line .num { flex: none; text-align: right; }

/* ---- choosing a plan (the PC app and the phone app) ---- */
.picker { container: picker / inline-size; display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; align-items: start; }
.picker-choose, .picker-sum, .payments { display: flex; flex-direction: column; gap: 16px; padding: 22px 24px 24px; min-width: 0; }
.ladder { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.rung { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; min-height: 74px; padding: 8px 4px; border: 1px solid var(--line); border-radius: var(--r-card); background: var(--well); color: var(--ink); }
.rung b { font: 700 1.375rem/1 var(--f-dsp); }
.rung span { font-size: .8125rem; line-height: 1; color: var(--ink-2); }
.rung:hover:not(:disabled) { border-color: var(--line-2); background: var(--well-2); }
.rung[aria-pressed="true"] { border-color: var(--acc-line); background: var(--acc-soft); box-shadow: inset 0 0 0 1px var(--acc-line); }
.rung[aria-pressed="true"] b { color: var(--acc-text); }
.rung:disabled { opacity: .42; }
.anynum { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.anynum .input { width: 112px; text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.sums { display: flex; flex-direction: column; gap: 10px; }
.sums > div { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; color: var(--ink-2); }
.sums dt small { display: block; font-size: .8125rem; line-height: 1.4; color: var(--ink-3); }
.sums dd { color: var(--ink); font-variant-numeric: tabular-nums; }
.sums .total { padding-top: 14px; border-top: 1px solid var(--hair); align-items: center; }
.sums .total dt { color: var(--ink); font-weight: 600; }
.sums .total dd { font: 700 1.875rem/1 var(--f-dsp); letter-spacing: -.02em; }

/* ---- signing in (the PC app and the web app) ---- */
.gbtn .gmark { width: 18px; height: 18px; flex: none; }
.or { display: flex; align-items: center; gap: 12px; font-size: .8125rem; color: var(--ink-3); }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--hair); }
.secret { position: relative; display: block; font-weight: 400; }
.secret .input { padding-right: 64px; }
.secret .link { position: absolute; right: 12px; top: 0; height: 44px; font-size: .8125rem; font-weight: 400; }
.ways-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 16px; font-size: .9375rem; }
.ways-in .link { min-height: 32px; }

/* ---- cloud emulators (the PC app and the web app) ---- */
.cloud { display: flex; flex-direction: column; padding: 8px 8px 10px; }
.cloud-intro { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; padding: 16px 14px 12px; }
.cloud-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; padding: 8px 8px 8px 14px; border-radius: var(--r-chip); background: var(--well); }
.cloud-head .copy { font-size: .875rem; line-height: 1.35; }
.cloud-note { padding: 14px 14px 8px; color: var(--ink-2); }
.cloud-note b { color: var(--ink); font-weight: 600; }
.cloud-note .btn { margin: 10px 0 4px; display: flex; width: fit-content; }
.cloud-row { border-top: 1px solid var(--hair); }
.cloud-row:first-child { border-top: 0; }
.cloud-line { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "n a" "s a"; align-items: center; column-gap: 12px; row-gap: 4px; padding: 12px 6px 12px 14px; }
.cloud-n { grid-area: n; font: 600 1rem/1.25 var(--f-xy); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cloud-s { grid-area: s; display: inline-flex; align-items: center; gap: 8px; font-size: .8125rem; line-height: 1.2; color: var(--ink-2); }
.cloud-s .spinner { width: 11px; height: 11px; border-width: 1.5px; }
.cloud-acts { grid-area: a; display: inline-flex; align-items: center; gap: 4px; }
.cloud-acts .btn:not(.sq, .ghost) { min-width: 76px; }
.cloud-ask { display: flex; flex-direction: column; gap: 14px; padding: 12px 14px 16px; }
.cloud-ask p { color: var(--ink-2); }
.cloud-ask p b { display: block; color: var(--ink); font-weight: 600; }
.cloud-many { display: flex; align-items: center; gap: 8px; }
.cloud-many span { margin-right: auto; font-size: .875rem; font-weight: 600; }
.cloud-many b { min-width: 2.2em; text-align: center; font: 700 1.125rem/1 var(--f-dsp); font-variant-numeric: tabular-nums; }
.cloud-buttons { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---- overlays ---- */
.toast { position: fixed; z-index: 90; right: 24px; bottom: 24px; max-width: min(420px, calc(100vw - 32px)); display: flex; align-items: center; gap: 12px; padding: 14px 18px; filter: drop-shadow(0 16px 34px rgba(0, 0, 0, .45)); animation: rise .22s var(--ease); }
.toast .ico { color: var(--good-text); }
.toast.bad .ico { color: var(--enemy-text); }
@keyframes rise { from { transform: translateY(10px); opacity: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
.spinner { width: 18px; height: 18px; flex: none; border-radius: 50%; border: 2px solid var(--line-2); border-top-color: var(--acc); animation: spin .8s linear infinite; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition: none !important; }
  .spinner { animation-duration: 2s !important; animation-iteration-count: infinite !important; }
}
