/* Comet — dark looking-glass design system */
:root {
  color-scheme: dark;
  --bg: #08070c;
  --bg-deep: #050409;
  --surface: rgba(27, 24, 34, .72);
  --surface2: rgba(255, 255, 255, .045);
  --surface3: rgba(255, 255, 255, .07);
  --ink: #f7f3f6;
  --muted: #a69da6;
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --pink: #f0a5c6;
  --pink2: #dc76a5;
  --pink-deep: #b95383;
  --pink-glow: rgba(222, 112, 163, .22);
  --lavender: #a993ef;
  --lavender-soft: rgba(169, 147, 239, .14);
  --blue: #79bef7;
  --blue-soft: rgba(121, 190, 247, .14);
  --green: #70d5aa;
  --green-soft: rgba(112, 213, 170, .13);
  --amber: #efbb70;
  --amber-soft: rgba(239, 187, 112, .13);
  --red: #ef8295;
  --red-soft: rgba(239, 130, 149, .13);
  --shadow: 0 22px 60px rgba(0, 0, 0, .28), 0 2px 12px rgba(0, 0, 0, .20), inset 0 1px 0 rgba(255, 255, 255, .055);
  --shadow-raised: 0 28px 74px rgba(0, 0, 0, .38), 0 0 0 1px rgba(255, 255, 255, .035), inset 0 1px 0 rgba(255, 255, 255, .08);
  --ease: cubic-bezier(.16, 1, .3, 1);
  --motion-fast: .16s;
  --motion-medium: .26s;
  --motion-slow: .42s;
}

html { overflow-x: hidden; background: var(--bg-deep); color-scheme: dark; }

body {
  background:
    radial-gradient(850px 620px at 18% -14%, rgba(218, 99, 157, .18), transparent 66%),
    radial-gradient(740px 560px at 104% 8%, rgba(91, 152, 226, .12), transparent 66%),
    radial-gradient(820px 600px at 56% 110%, rgba(142, 107, 213, .11), transparent 66%),
    linear-gradient(145deg, #0d0b12 0%, #08070c 55%, #0b0910 100%);
  background-attachment: fixed;
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI Variable", "Segoe UI", Inter, sans-serif;
  letter-spacing: -.012em;
}

.noise { opacity: .13; mix-blend-mode: soft-light; }
.hidden { display: none !important; }

button,
input,
select { min-height: 44px; }

button {
  cursor: pointer;
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), background-color .22s ease,
    border-color .22s ease, color .22s ease, opacity .22s ease;
  touch-action: manipulation;
}

button:active:not(:disabled) { transform: scale(.98); }
button:disabled { cursor: not-allowed; opacity: .42; transform: none !important; }

button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(240, 165, 198, .28);
  outline-offset: 2px;
}

.shell { grid-template-columns: 258px minmax(0, 1fr); }
.shell .active-page { transition: opacity .22s ease; }

aside {
  position: sticky;
  top: 0;
  z-index: 20;
  height: 100vh;
  padding: 28px 20px 22px;
  background: linear-gradient(180deg, rgba(20, 17, 25, .88), rgba(13, 11, 17, .80));
  border-right: 1px solid rgba(255, 255, 255, .07);
  box-shadow: 18px 0 54px rgba(0, 0, 0, .16), inset -1px 0 0 rgba(255,255,255,.018);
  backdrop-filter: blur(28px) saturate(125%);
}

.brand { gap: 12px; padding: 1px 7px 34px; }

.brand-mark,
.mark {
  width: 43px;
  height: 43px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 14px;
  background:
    linear-gradient(145deg, rgba(255,255,255,.23), transparent 44%),
    linear-gradient(145deg, #ef9cc1 0%, #c2578a 68%, #93446c 100%);
  color: #fff;
  box-shadow: 0 13px 30px rgba(198, 76, 134, .28), inset 0 1px 0 rgba(255, 255, 255, .36);
}

.brand b { color: #fff; font-size: 17px; font-weight: 700; letter-spacing: -.025em; }
.brand small { color: #8f858e; font-size: 11px; letter-spacing: .035em; }

nav { display: grid; gap: 5px; }

.nav {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 46px;
  margin: 0;
  padding: 11px 13px;
  border: 1px solid transparent;
  border-radius: 13px;
  background: transparent;
  color: #948b94;
  font-size: 13px;
  font-weight: 620;
}

.nav svg { width: 18px; height: 18px; flex: none; opacity: .72; transition: opacity .2s ease; }
.nav:hover { color: #eee8ed; background: rgba(255, 255, 255, .045); border-color: rgba(255, 255, 255, .035); }

.nav.active {
  color: #ffd9e9;
  background:
    linear-gradient(135deg, rgba(224, 116, 166, .18), rgba(179, 88, 134, .10));
  border-color: rgba(236, 151, 191, .22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), 0 8px 24px rgba(182, 65, 121, .10);
}

.nav.active svg { color: var(--pink); opacity: 1; }

aside .socket-card {
  align-items: center;
  min-height: 58px;
  margin-top: auto;
  padding: 12px 14px;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 14px;
  background: rgba(255, 255, 255, .04);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04), 0 12px 28px rgba(0,0,0,.16);
  backdrop-filter: blur(16px);
}

aside .socket-card > div { display: grid; align-content: center; min-width: 0; min-height: 12px; }
aside .socket-card b { display: block; color: #e9e4e8; font-size: 12px; font-weight: 650; line-height: 1; }
aside .socket-card small { color: #7f767e; font-size: 10px; }
aside .socket-card .dot { width: 8px; height: 8px; flex: 0 0 8px; margin-left: auto; background: #7c7078; box-shadow: 0 0 0 5px rgba(255,255,255,.035); }
aside .socket-card .dot.on { background: var(--green); box-shadow: 0 0 0 5px rgba(112, 213, 170, .10), 0 0 18px rgba(112, 213, 170, .34); }
.profile-avatar { position: relative; display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 34px; overflow: hidden; border: 1px solid rgba(255,255,255,.10); border-radius: 11px; background: linear-gradient(145deg, rgba(240,165,198,.22), rgba(169,147,239,.18)); color: #f5eaf0; font-size: 12px; font-weight: 780; }
.profile-avatar #profileInitial { display: grid; place-items: center; }
.profile-avatar #profileInitial svg { width: 17px; height: 17px; }
.profile-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .18s ease; }
.profile-avatar.has-image img { opacity: 1; }

main { max-width: 1540px; padding: 34px 42px 72px; }

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 68px;
  margin-bottom: 25px;
  gap: 24px;
}

header h1 { margin: 0; color: #faf7f9; font-size: clamp(29px, 3vw, 37px); font-weight: 710; line-height: 1.06; letter-spacing: -.045em; }

.header-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 10px;
}

.eyebrow {
  margin-bottom: 7px;
  color: var(--pink);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .18em;
}

.header-pill,
.badge {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, .045);
  color: var(--muted);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.045);
  backdrop-filter: blur(14px);
}

.header-pill {
  display: flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 9px 14px;
  white-space: nowrap;
}

.header-pill::before { content: ""; width: 7px; height: 7px; border-radius: 99px; background: var(--green); box-shadow: 0 0 0 4px var(--green-soft), 0 0 14px rgba(112,213,170,.38); }
.header-pill span { color: #f5eff3; font-weight: 750; font-variant-numeric: tabular-nums; }
.badge { color: #e7c4d5; font-size: 11px; font-weight: 700; }

.ghost.is-loading { display: inline-flex; align-items: center; gap: 8px; cursor: wait; opacity: .78; }
.ghost.is-loading::before { content: ""; width: 14px; height: 14px; flex: 0 0 14px; border: 2px solid rgba(255,255,255,.18); border-top-color: var(--pink); border-radius: 50%; animation: refresh-spin .72s linear infinite; }

.card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 25px;
  border: 1px solid var(--line);
  border-radius: 19px;
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .060), rgba(255, 255, 255, .025));
  box-shadow: var(--shadow);
  transition: border-color .25s ease, box-shadow .25s var(--ease), transform .25s var(--ease), opacity .22s ease;
}

.card::before {
  content: "";
  position: absolute;
  z-index: -1;
  width: 300px;
  height: 210px;
  right: -150px;
  top: -140px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(240, 165, 198, .13), transparent 68%);
  filter: blur(3px);
  pointer-events: none;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  background: linear-gradient(115deg, rgba(255,255,255,.035), transparent 27%, transparent 76%, rgba(255,255,255,.015));
  pointer-events: none;
}

.card:hover { border-color: rgba(255, 255, 255, .14); box-shadow: var(--shadow-raised); }

.hero {
  min-height: 126px;
  margin-bottom: 18px;
  padding: 26px 28px;
  background:
    radial-gradient(560px 260px at 91% -18%, rgba(224, 112, 166, .24), transparent 70%),
    linear-gradient(120deg, rgba(255,255,255,.060), rgba(210,95,151,.055));
  border-color: rgba(236, 151, 191, .15);
}

.hero h2 { margin: 0; font-size: 30px; font-weight: 680; letter-spacing: -.04em; }
.hero label { width: min(280px, 42%); margin: 0; }

.grid { gap: 18px; }
.grid.two { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); margin-bottom: 18px; }

h1, h2, h3, p { margin-top: 0; }
h2 { margin-bottom: 8px; color: #f7f3f6; font-size: 26px; line-height: 1.15; letter-spacing: -.035em; }
h3 { color: #f2edf1; font-size: 18px; line-height: 1.3; letter-spacing: -.02em; }
.lede { max-width: 760px; color: var(--muted); line-height: 1.6; }
.card-title { margin-bottom: 21px; }
.metric { color: var(--pink); font-size: 40px; font-weight: 680; letter-spacing: -.055em; text-shadow: 0 0 28px rgba(240,165,198,.20); }

label { color: #aaa0a8; font-size: 12px; font-weight: 650; }

input,
select {
  min-width: 0;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 11px;
  background: rgba(4, 3, 8, .33);
  color: #f2edf1;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, .18), inset 0 1px 0 rgba(255,255,255,.015);
  transition: background-color .2s ease, border-color .2s ease, box-shadow .2s ease;
}

input::placeholder { color: #716871; }
input:hover, select:hover { border-color: rgba(255, 255, 255, .15); }
input:focus, select:focus { border-color: rgba(240, 165, 198, .62); background: rgba(8, 6, 12, .56); box-shadow: 0 0 0 4px rgba(220, 118, 165, .10), inset 0 1px 3px rgba(0,0,0,.18); }
select option { background: #17131c; color: #f5f0f3; }

.native-select-hidden {
  position: fixed !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.glass-select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 46px;
  padding: 11px 13px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 11px;
  background: rgba(4,3,8,.33);
  color: #f2edf1;
  box-shadow: inset 0 1px 3px rgba(0,0,0,.18), inset 0 1px 0 rgba(255,255,255,.015);
  font: inherit;
  text-align: left;
}

.glass-select-trigger:hover { border-color: rgba(240,165,198,.25); background: rgba(13,9,16,.55); }
.glass-select-trigger[aria-expanded="true"] { border-color: rgba(240,165,198,.58); background: rgba(13,9,16,.72); box-shadow: 0 0 0 4px rgba(220,118,165,.10), inset 0 1px 3px rgba(0,0,0,.22); }
.glass-select-trigger:focus-visible { outline: 3px solid rgba(240,165,198,.25); outline-offset: 2px; }
.glass-select-trigger:disabled { opacity: .42; }
.glass-select-value { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.glass-select-chevron { width: 18px; height: 18px; flex: 0 0 18px; color: #968b94; transition: transform .24s var(--ease), color .2s ease; }
.glass-select-trigger[aria-expanded="true"] .glass-select-chevron { transform: rotate(180deg); color: var(--pink); }

.glass-select-menu {
  position: fixed;
  z-index: 1000;
  max-height: 280px;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 6px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 13px;
  background: linear-gradient(145deg, rgba(30,24,34,.985), rgba(16,13,20,.99));
  box-shadow: 0 22px 60px rgba(0,0,0,.48), 0 4px 16px rgba(0,0,0,.34), inset 0 1px 0 rgba(255,255,255,.065);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-5px) scale(.985);
  transform-origin: top center;
  pointer-events: none;
  transition: opacity .16s ease, transform .2s var(--ease), visibility 0s linear .2s;
  scrollbar-width: thin;
  scrollbar-color: rgba(240,165,198,.30) transparent;
}

.glass-select-menu.open { opacity: 1; visibility: visible; transform: translateY(0) scale(1); pointer-events: auto; transition-delay: 0s; }
.glass-select-menu::-webkit-scrollbar { width: 8px; }
.glass-select-menu::-webkit-scrollbar-track { background: transparent; }
.glass-select-menu::-webkit-scrollbar-thumb { border: 2px solid transparent; border-radius: 99px; background: rgba(240,165,198,.28); background-clip: padding-box; }

.glass-select-group { padding: 10px 11px 5px; color: var(--pink); font-size: 9px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.glass-select-group:not(:first-child) { margin-top: 5px; border-top: 1px solid rgba(255,255,255,.065); }

.glass-select-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  min-height: 42px;
  padding: 9px 11px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  color: #bbb1b9;
  font: inherit;
  font-size: 13px;
  text-align: left;
}

.glass-select-option + .glass-select-option { margin-top: 2px; }
.glass-select-option:hover, .glass-select-option:focus-visible { border-color: rgba(240,165,198,.11); background: rgba(240,165,198,.08); color: #fff2f8; outline: none; }
.glass-select-option[aria-selected="true"] { border-color: rgba(240,165,198,.20); background: linear-gradient(135deg, rgba(220,118,165,.20), rgba(169,147,239,.08)); color: #ffd9e9; }
.glass-select-option svg { width: 18px; height: 18px; flex: 0 0 18px; color: var(--pink); }
.glass-select-option:disabled { opacity: .38; }

.section-caption { display: block; margin-top: -3px; color: var(--muted); font-size: 12px; font-weight: 570; letter-spacing: 0; }

.primary,
.command-row button,
.new-session button,
.join-row button {
  min-height: 45px;
  border: 1px solid rgba(255, 255, 255, .12);
  border-radius: 11px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.13), transparent 46%),
    linear-gradient(135deg, #df7dab 0%, #bd5587 100%);
  color: #fff;
  font-weight: 720;
  box-shadow: 0 12px 28px rgba(181, 68, 123, .23), inset 0 1px 0 rgba(255,255,255,.23);
}

.primary { position: relative; overflow: hidden; }
.primary::after { content: ""; position: absolute; top: -80%; bottom: -80%; left: -35%; width: 24%; background: linear-gradient(90deg, transparent, rgba(255,255,255,.24), transparent); transform: translateX(-180%) rotate(14deg); transition: transform .62s var(--ease); pointer-events: none; }
.primary:hover::after { transform: translateX(650%) rotate(14deg); }

.primary:hover,
.command-row button:hover,
.new-session button:hover,
.join-row button:hover { transform: translateY(-1px); box-shadow: 0 16px 34px rgba(181,68,123,.30), inset 0 1px 0 rgba(255,255,255,.28); }
.primary.stop { background: linear-gradient(135deg, #ed899a, #bd5369); box-shadow: 0 12px 28px rgba(189,83,105,.20); }

.ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(255, 255, 255, .045);
  color: #bbb1b9;
  font-weight: 650;
  backdrop-filter: blur(14px);
}
.ghost:hover { color: #fff; border-color: var(--line-strong); background: rgba(255, 255, 255, .075); }

.start-card { border-top-color: rgba(240, 165, 198, .32); }
.status-card { border-top-color: rgba(112, 213, 170, .30); }
.status-card::before { background: radial-gradient(circle, rgba(112,213,170,.12), transparent 68%); }
.commands .card:first-child { border-top-color: rgba(121, 190, 247, .34); }
.commands .card:first-child::before { background: radial-gradient(circle, rgba(121,190,247,.11), transparent 68%); }
.commands .card:last-child { border-top-color: rgba(169, 147, 239, .34); }
.commands .card:last-child::before { background: radial-gradient(circle, rgba(169,147,239,.11), transparent 68%); }

.pc-list { display: grid; gap: 9px; }
.pc-list.empty { padding: 37px 12px; border: 1px dashed rgba(255,255,255,.10); border-radius: 13px; background: rgba(255,255,255,.018); color: #817780; }
.pc { min-height: 60px; padding: 12px 14px; border: 1px solid rgba(255,255,255,.07); border-radius: 12px; background: rgba(255,255,255,.035); box-shadow: inset 0 1px 0 rgba(255,255,255,.025); }
.pc small { color: #8d838b; }
.pc-status { display: flex; align-items: center; gap: 6px; color: var(--green); }
.pc-status::before { content: ""; width: 7px; height: 7px; border-radius: 99px; background: currentColor; box-shadow: 0 0 12px rgba(112,213,170,.36); }

.command-row, .new-session { align-items: stretch; }
.command-row input, .new-session input, .join-row input { min-width: 0; }
.command-row button { flex: 0 0 auto; min-width: 92px; }
.quick-keys { margin-top: 9px; }
.quick-keys button { min-width: 0; background: var(--blue-soft); border-color: rgba(121,190,247,.20); color: #b9ddfb; box-shadow: none; }
.quick-keys button + button { background: var(--lavender-soft); border-color: rgba(169,147,239,.20); color: #d0c2fb; }
.quick-keys button:hover { box-shadow: 0 8px 22px rgba(84,135,181,.12); }

.join-card { border-left-color: rgba(239, 187, 112, .38); }
.join-card::before { background: radial-gradient(circle, rgba(239,187,112,.11), transparent 68%); }
.config-upload-card { display: flex; align-items: center; justify-content: space-between; gap: 28px; margin-bottom: 18px; border-left-color: rgba(211,112,169,.46); }
.config-upload-card > div { min-width: 0; }
.config-upload-card h3 { margin-bottom: 8px; }
.config-upload-card .lede { max-width: 760px; margin-bottom: 0; }
.config-upload-card .primary { flex: 0 0 250px; width: 250px; margin-top: 0; }
.config-upload-card .account-result { margin-bottom: 0; }

.log {
  height: 158px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 12px;
  background: rgba(3, 3, 6, .58);
  color: #dfd7dd;
  box-shadow: inset 0 1px 12px rgba(0,0,0,.28);
}
.log span { color: #746a72; }
.log-line b { color: var(--pink); }

.active-page { animation: page-enter .24s var(--ease) backwards; }
.active-page .card { animation: card-enter .30s var(--ease) backwards; }
.active-page .card:nth-child(2) { animation-delay: 30ms; }
.active-page .card:nth-child(3) { animation-delay: 55ms; }

@keyframes page-enter {
  from { opacity: .45; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes card-enter {
  from { opacity: .32; transform: translateY(8px) scale(.994); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.tabs-ready .active-page,
.tabs-ready .active-page .card { animation: none; }

.shell.is-refreshing .active-page { opacity: .72; pointer-events: none; }
.tabs-ready .shell.is-refreshing .active-page .card { animation: refresh-breathe .8s ease-in-out infinite alternate; }
.tabs-ready .active-page.refresh-settle .card { animation: refresh-settle .36s var(--ease) backwards; }
.tabs-ready .active-page.refresh-settle .card:nth-child(2) { animation-delay: 28ms; }
.tabs-ready .active-page.refresh-settle .card:nth-child(3) { animation-delay: 52ms; }

.log-line { animation: log-enter .20s var(--ease) backwards; }
.value-pop { display: inline-block; animation: value-pop .32s var(--ease) backwards; }

@keyframes refresh-spin { to { transform: rotate(360deg); } }
@keyframes refresh-breathe { from { opacity: .80; } to { opacity: .96; } }
@keyframes refresh-settle { from { opacity: .38; transform: translateY(6px) scale(.997); } to { opacity: 1; transform: translateY(0) scale(1); } }
@keyframes log-enter { from { opacity: 0; transform: translateX(-5px); } to { opacity: 1; transform: translateX(0); } }
@keyframes value-pop { from { opacity: .55; transform: scale(.91); } to { opacity: 1; transform: scale(1); } }

#pageTitle { view-transition-name: panel-title; }
.tabs-ready .page.active-page { view-transition-name: panel-page; }

::view-transition-old(root),
::view-transition-new(root) { animation: none; mix-blend-mode: normal; }

::view-transition-old(panel-page) { animation: tab-page-out .16s ease-in both; }
::view-transition-new(panel-page) { animation: tab-page-in .28s var(--ease) both; }
::view-transition-old(panel-title) { animation: tab-title-out .12s ease-in both; }
::view-transition-new(panel-title) { animation: tab-title-in .22s var(--ease) both; }

@keyframes tab-page-out {
  to { opacity: 0; transform: translateY(-5px) scale(.998); }
}

@keyframes tab-page-in {
  from { opacity: 0; transform: translateY(9px) scale(.996); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes tab-title-out {
  to { opacity: 0; transform: translateX(-5px); }
}

@keyframes tab-title-in {
  from { opacity: 0; transform: translateX(7px); }
  to { opacity: 1; transform: translateX(0); }
}

.session-board { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.session { padding: 18px; border-color: rgba(255,255,255,.075); border-radius: 14px; background: rgba(255,255,255,.032); box-shadow: inset 0 1px 0 rgba(255,255,255,.025); }
.assign-row { border-color: rgba(255,255,255,.07); }
.remove-pc { color: var(--red); }

.launch-settings { gap: 12px; }
.account-list { display: grid; gap: 16px; }
#accounts .account-result:not(:empty) + .account-list { margin-top: 16px; }
.account-pc { overflow: hidden; padding: 18px; border: 1px solid rgba(255,255,255,.075); border-radius: 15px; background: rgba(255,255,255,.03); }
.account-pc-title { margin-bottom: 12px; }
.account-pc-title h3 { min-width: 0; overflow-wrap: anywhere; }
.account-pc-title > div { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 7px; }
.account-pc-title .start-all,
.account-pc-title .danger,
.account-row button { min-height: 38px; margin: 0; padding: 8px 11px; border: 1px solid rgba(255,255,255,.09); border-radius: 9px; color: #fff; }
.account-pc-title .start-all { background: rgba(169,147,239,.22); color: #d9ceff; }
.account-pc-title .danger { background: var(--red-soft); color: #ffb4c0; }
.account-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.45fr) 94px minmax(230px, 1fr) 238px;
  align-items: center;
  gap: 16px;
  min-height: 76px;
  padding: 13px 0;
  border-top: 1px solid rgba(255,255,255,.07);
}
.account-identity { display: flex; align-items: center; gap: 12px; min-width: 0; }
.account-identity > div { min-width: 0; }
.account-identity b { display: block; overflow: hidden; color: #f1ecf0; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.account-identity small { display: block; overflow: hidden; margin-top: 3px; color: #8d838c; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.account-avatar { position: relative; display: grid; place-items: center; overflow: hidden; width: 38px; height: 38px; flex: 0 0 38px; border: 1px solid rgba(240,165,198,.17); border-radius: 12px; background: linear-gradient(145deg, rgba(240,165,198,.17), rgba(169,147,239,.09)); color: #f3b8d2; font-size: 13px; font-weight: 780; box-shadow: inset 0 1px 0 rgba(255,255,255,.06); }
.account-avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; }
.account-avatar.has-image img { opacity: 1; }
.account-avatar.has-image > span { opacity: 0; }
.main-check { display: flex; align-items: center; gap: 8px; min-height: 38px; margin: 0; padding: 6px 9px; border: 1px solid rgba(255,255,255,.07); border-radius: 10px; background: rgba(255,255,255,.025); color: #a89ea6; cursor: pointer; transition: border-color .25s ease, background-color .25s ease, color .25s ease; }
.main-check:has(input:checked) { border-color: rgba(240,165,198,.20); background: rgba(220,118,165,.08); color: #f3c2d7; }
.main-check input[type="checkbox"] { appearance: none; position: relative; width: 40px; min-height: 22px; height: 22px; flex: 0 0 40px; margin: 0; padding: 0; border: 1px solid rgba(255,255,255,.13); border-radius: 99px; background: rgba(255,255,255,.075); box-shadow: inset 0 2px 5px rgba(0,0,0,.22); cursor: pointer; transition: background .34s var(--ease), border-color .3s ease, box-shadow .3s ease; }
.main-check input[type="checkbox"]::after { content: ""; position: absolute; width: 16px; height: 16px; left: 2px; top: 2px; border-radius: 50%; background: linear-gradient(180deg, #bdb5bb, #8e858d); box-shadow: 0 2px 7px rgba(0,0,0,.36), inset 0 1px 0 rgba(255,255,255,.28); transition: transform .38s cubic-bezier(.2, 1.55, .38, 1), background .25s ease, box-shadow .25s ease; }
.main-check input[type="checkbox"]:checked { border-color: rgba(240,165,198,.52); background: linear-gradient(135deg, #e181ae, #ba5183); box-shadow: inset 0 1px 2px rgba(0,0,0,.12), 0 0 0 3px rgba(220,118,165,.07); }
.main-check input[type="checkbox"]:checked::after { transform: translateX(18px); background: linear-gradient(180deg, #fff, #f2eaf0); box-shadow: 0 2px 8px rgba(0,0,0,.32), 0 0 10px rgba(255,255,255,.20); }
.main-check span { font-size: 11px; font-weight: 700; }
.account-state { display: flex; align-items: center; gap: 8px; min-width: 0; }
.account-state small { overflow: hidden; color: #8f858e; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.account-state-dot { width: 7px; height: 7px; flex: 0 0 7px; border-radius: 50%; background: #746b73; box-shadow: 0 0 0 4px rgba(255,255,255,.025); }
.account-state.running .account-state-dot { background: var(--green); box-shadow: 0 0 0 4px var(--green-soft), 0 0 12px rgba(112,213,170,.25); }
.account-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); justify-self: end; gap: 7px; width: 238px; }
.account-actions button { padding-inline: 7px; }
.account-row button { background: rgba(220,118,165,.22); color: #ffcfe3; }
.account-row button.stop { background: var(--red-soft); color: #ffb4c0; }
.account-row .inject { background: var(--lavender-soft); color: #d8ccff; }
.account-row .delete-account { background: var(--red-soft); color: #ffb4c0; }
.account-row button { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-pc-title [data-start-all] { min-width: 126px; }
.account-row button:hover:not(:disabled), .account-pc-title button:hover:not(:disabled) { transform: translateY(-1px); border-color: rgba(255,255,255,.16); box-shadow: inset 0 1px 0 rgba(255,255,255,.07), 0 7px 18px rgba(0,0,0,.16); }

.settings-grid { gap: 13px; }
.settings-grid.single { grid-template-columns: 1fr; margin-top: 18px; }
.setting-toggle {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 62px;
  padding: 13px 14px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 12px;
  background: rgba(255,255,255,.032);
  cursor: pointer;
  transition: border-color .28s ease, background-color .28s ease, box-shadow .28s ease;
}
.setting-toggle:hover { border-color: rgba(255,255,255,.13); background: rgba(255,255,255,.045); }
.setting-toggle:has(input:checked) { border-color: rgba(240,165,198,.19); background: linear-gradient(135deg, rgba(220,118,165,.075), rgba(255,255,255,.025)); box-shadow: inset 0 1px 0 rgba(255,255,255,.035); }
.setting-toggle > span { display: grid; gap: 2px; }
.setting-toggle b { color: #ded7dc; font-size: 12px; }
.setting-toggle small { color: #817780; font-size: 11px; font-weight: 500; }

.setting-toggle input[type="checkbox"] {
  appearance: none;
  position: relative;
  flex: 0 0 auto;
  width: 48px;
  min-height: 28px;
  height: 28px;
  margin: 0;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 99px;
  background: rgba(255,255,255,.075);
  box-shadow: inset 0 1px 3px rgba(0,0,0,.20);
  cursor: pointer;
  transition: background .34s var(--ease), border-color .3s ease, box-shadow .3s ease;
}
.setting-toggle input[type="checkbox"]::after { content: ""; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; border-radius: 50%; background: linear-gradient(180deg, #c1bac0, #918890); box-shadow: 0 2px 8px rgba(0,0,0,.38), inset 0 1px 0 rgba(255,255,255,.30); transition: transform .4s cubic-bezier(.2, 1.55, .38, 1), background .25s ease, box-shadow .25s ease; }
.setting-toggle input[type="checkbox"]:checked { border-color: rgba(240,165,198,.55); background: linear-gradient(135deg, #e584b1, #b94f81); box-shadow: inset 0 1px 2px rgba(0,0,0,.12), 0 0 0 4px rgba(220,118,165,.07), 0 0 20px rgba(220,118,165,.10); }
.setting-toggle input[type="checkbox"]:checked::after { transform: translateX(20px); background: linear-gradient(180deg, #fff, #f1e9ef); box-shadow: 0 2px 9px rgba(0,0,0,.34), 0 0 12px rgba(255,255,255,.22); }
.setting-toggle input[type="checkbox"]:active::after, .main-check input[type="checkbox"]:active::after { transform: scale(.90); }
.setting-toggle input[type="checkbox"]:checked:active::after { transform: translateX(20px) scale(.90); }
.main-check input[type="checkbox"]:checked:active::after { transform: translateX(18px) scale(.90); }

.protection-card { order: 2; border-top-color: rgba(112,213,170,.30); }
.protection-card::before { background: radial-gradient(circle, rgba(112,213,170,.12), transparent 68%); }
.autojoin-card { order: 1; border-top-color: rgba(121,190,247,.32); }
.autojoin-card::before { background: radial-gradient(circle, rgba(121,190,247,.12), transparent 68%); }
.resource-card { order: 1; border-top-color: rgba(169,147,239,.34); }
.resource-card::before { background: radial-gradient(circle, rgba(169,147,239,.13), transparent 68%); }
.resource-card .card-title { align-items: center; margin-bottom: 12px; }
.resource-scope { padding: 7px 10px; border: 1px solid rgba(169,147,239,.22); border-radius: 999px; background: rgba(169,147,239,.10); color: #cfc4f5; font-size: 10px; font-weight: 800; letter-spacing: .08em; }
.resource-toggle-grid { display: grid; grid-template-columns: 1fr; gap: 13px; margin-top: 18px; }
.resource-card .primary { width: 100%; }
#settings > .grid.two { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; }
#settings > .grid.two > .card { height: 100%; }
.settings-tabs { display: inline-flex; gap: 5px; margin-bottom: 22px; padding: 5px; border: 1px solid rgba(255,255,255,.08); border-radius: 13px; background: rgba(255,255,255,.03); }
.settings-tab { min-width: 118px; min-height: 42px; padding: 9px 18px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: #8f858e; font-weight: 730; }
.settings-tab:hover { color: #d9d0d7; background: rgba(255,255,255,.035); }
.settings-tab.active { border-color: rgba(240,165,198,.24); background: linear-gradient(135deg, rgba(220,118,165,.20), rgba(169,147,239,.10)); color: #ffd5e7; box-shadow: inset 0 1px 0 rgba(255,255,255,.07), 0 8px 22px rgba(0,0,0,.15); }
.settings-pane { display: none; }
.settings-pane.active { display: block; animation: page-in .28s var(--ease) backwards; }
.settings-pane > .grid.two { grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: stretch; }
.settings-pane > .grid.two > .card { height: 100%; }
.optimizer-heading { display: flex; align-items: end; justify-content: space-between; gap: 30px; margin: 0 0 20px; }
.optimizer-heading h2 { margin: 3px 0 0; font-size: 25px; }
.optimizer-heading > p { max-width: 600px; margin: 0; color: #8f858e; font-size: 12px; line-height: 1.6; text-align: right; }
.optimizer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.optimizer-grid .resource-card, .optimizer-grid .rendering-card { order: 0; }
.optimizer-grid .card { min-height: 510px; }
.optimizer-grid .setting-toggle { min-height: 48px; padding: 8px 10px 8px 14px; justify-content: space-between; }
.optimizer-grid .setting-toggle > input { order: 2; }
.optimizer-grid .setting-toggle b { font-size: 13px; }
.rendering-card { border-top-color: rgba(240,165,198,.32); }
.rendering-card::before { background: radial-gradient(circle, rgba(220,118,165,.13), transparent 68%); }
.optimizer-result { margin: 16px 2px 0; color: #827981; font-size: 11px; }
.account-result:not(:empty) { display: block; margin: 14px 0 0; padding: 11px 13px; border: 1px solid rgba(169,147,239,.16); border-radius: 11px; background: rgba(169,147,239,.09); color: #d3c7f5; font-size: 12px; line-height: 1.45; animation: notice-enter .28s var(--ease) backwards; }

@keyframes notice-enter {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

.login {
  padding: 28px;
  background:
    radial-gradient(700px 560px at 78% 12%, rgba(218,99,157,.22), transparent 67%),
    radial-gradient(620px 500px at 10% 92%, rgba(121,145,229,.15), transparent 70%),
    linear-gradient(145deg, #0e0b12, #07060a);
}
.login::before { content: "COMET"; position: fixed; left: 4vw; bottom: -5vw; color: rgba(255,255,255,.018); font-size: clamp(130px, 23vw, 360px); line-height: .8; font-weight: 900; letter-spacing: -.08em; pointer-events: none; }
.login-card {
  width: min(420px, calc(100% - 24px));
  padding: 40px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 23px;
  background: linear-gradient(145deg, rgba(255,255,255,.075), rgba(255,255,255,.032));
  box-shadow: 0 38px 90px rgba(0,0,0,.43), inset 0 1px 0 rgba(255,255,255,.085);
  backdrop-filter: blur(28px) saturate(130%);
  animation: login-enter .48s var(--ease) backwards;
}
@keyframes login-enter { from { opacity: 0; transform: translateY(12px) scale(.985); } to { opacity: 1; transform: translateY(0) scale(1); } }
.login-card .mark { margin-bottom: 30px; }
.login-card h1 { margin-bottom: 9px; color: #fff; font-size: 34px; letter-spacing: -.05em; }
.login-card p { color: #9f959d; line-height: 1.55; }
.login-card input { background: rgba(3,3,7,.30); }
.login-card button { min-height: 47px; margin-top: 14px; border: 1px solid rgba(255,255,255,.12); background: linear-gradient(135deg, #e17fab, #b84e81); box-shadow: 0 13px 30px rgba(181,68,123,.25), inset 0 1px 0 rgba(255,255,255,.25); font-weight: 720; }
.login-card button:hover { transform: translateY(-1px); box-shadow: 0 16px 36px rgba(181,68,123,.31), inset 0 1px 0 rgba(255,255,255,.27); }

@media (max-width: 1120px) {
  main { padding-inline: 28px; }
  #settings > .grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .settings-pane > .grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .protection-card { grid-column: 1 / -1; }
  .optimizer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .account-row { grid-template-columns: minmax(190px, 1.2fr) 94px minmax(180px, .8fr) 220px; gap: 11px; }
  .account-actions { width: 220px; }
}

@media (max-width: 900px) {
  .shell { display: block; }
  aside { position: static; width: 100%; height: auto; padding: 17px 20px 13px; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand { padding: 0 4px 13px; }
  nav { display: flex; gap: 7px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; }
  nav::-webkit-scrollbar { display: none; }
  .nav { width: auto; flex: 0 0 auto; padding-inline: 13px; }
  aside .socket-card { position: absolute; top: 17px; right: 20px; min-height: 44px; padding: 9px 12px; }
  aside .socket-card div { display: none; }
  main { padding: 27px 20px 60px; }
}

@media (max-width: 700px) {
  header { align-items: center; gap: 14px; }
  header h1 { font-size: 29px; }
  .header-pill { display: none; }
  .grid.two { grid-template-columns: 1fr; }
  #settings > .grid.two { grid-template-columns: 1fr; }
  .settings-pane > .grid.two { grid-template-columns: 1fr; }
  .protection-card { grid-column: auto; }
  .hero { align-items: stretch; flex-direction: column; }
  .hero label { width: 100%; }
  .config-upload-card { align-items: stretch; flex-direction: column; gap: 16px; }
  .config-upload-card .primary { flex: 0 0 auto; width: 100%; }
  .card { padding: 20px; border-radius: 17px; }
  .command-row, .new-session, .join-row { display: grid; grid-template-columns: 1fr; }
  .command-row button, .new-session button, .join-row button { width: 100%; }
  .quick-keys { grid-template-columns: 1fr 1fr; }
  .settings-grid { grid-template-columns: 1fr; }
  .resource-toggle-grid { grid-template-columns: 1fr; }
  .settings-tabs { display: flex; }
  .settings-tab { min-width: 0; flex: 1; }
  .optimizer-heading { align-items: flex-start; flex-direction: column; gap: 9px; }
  .optimizer-heading > p { text-align: left; }
  .optimizer-grid { grid-template-columns: 1fr; }
  .optimizer-grid .card { min-height: 0; }
  .account-pc-title { align-items: flex-start; flex-direction: column; }
  .account-pc-title > div { justify-content: flex-start; }
  .account-row { grid-template-columns: minmax(0, 1fr) auto; gap: 10px 12px; padding: 15px 0; }
  .account-identity { grid-column: 1 / -1; }
  .account-state { justify-self: end; }
  .account-actions { grid-column: 1 / -1; justify-self: stretch; width: 100%; }
  .account-actions button { flex: 1 1 0; width: auto; }
}

@media (max-width: 520px) {
  aside { padding-inline: 14px; }
  .brand { padding-left: 1px; }
  .brand-mark { width: 40px; height: 40px; }
  aside .socket-card { right: 14px; }
  .nav { min-height: 42px; padding: 9px 11px; font-size: 13px; }
  .nav svg { width: 17px; height: 17px; }
  main { padding-inline: 14px; }
  .header-actions { gap: 7px; }
  .ghost { padding-inline: 12px; }
  .login { padding: 12px; }
  .login-card { padding: 30px 24px; }
  .login-card h1 { font-size: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}

/* SteamRouteTool */
.routes-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin-bottom: 18px; }
.routes-heading h2 { margin-bottom: 8px; }
.routes-heading .lede { max-width: 760px; margin-bottom: 0; line-height: 1.65; }
.route-catalog-status { flex: 0 0 auto; padding: 9px 12px; border: 1px solid rgba(112,213,170,.17); border-radius: 999px; background: rgba(112,213,170,.07); color: #a8dbc5; font-size: 11px; font-weight: 700; }
.route-catalog-status.error { border-color: rgba(255,121,145,.20); background: var(--red-soft); color: #ffb4c0; }
.route-pc-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 16px; margin-top: 18px; }
.route-pc { min-height: 260px; border-top-color: rgba(169,147,239,.30); }
.route-pc::before { background: radial-gradient(circle, rgba(169,147,239,.13), transparent 68%); }
.route-pc.is-blocked { border-top-color: rgba(112,213,170,.34); }
.route-pc.is-blocked::before { background: radial-gradient(circle, rgba(112,213,170,.13), transparent 68%); }
.route-pc-title { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.route-pc-title > div { display: flex; align-items: center; gap: 11px; min-width: 0; }
.route-pc-title h3 { overflow: hidden; margin-bottom: 3px; text-overflow: ellipsis; white-space: nowrap; }
.route-pc-title small { display: block; color: #8f858e; font-size: 11px; line-height: 1.45; }
.route-state-dot { width: 9px; height: 9px; flex: 0 0 9px; border-radius: 50%; background: #746b73; box-shadow: 0 0 0 5px rgba(255,255,255,.03); }
.route-pc.is-blocked .route-state-dot { background: var(--green); box-shadow: 0 0 0 5px var(--green-soft), 0 0 14px rgba(112,213,170,.24); }
.route-state-badge { flex: 0 0 auto; padding: 6px 9px; border: 1px solid rgba(255,255,255,.08); border-radius: 999px; background: rgba(255,255,255,.035); color: #8f858e; font-size: 9px; font-weight: 850; letter-spacing: .10em; }
.route-pc.is-blocked .route-state-badge { border-color: rgba(112,213,170,.18); background: rgba(112,213,170,.08); color: #9bd6bd; }
.route-pc label { margin-top: 0; }
.route-actions { display: grid; grid-template-columns: 1.3fr 1fr; gap: 9px; margin-top: 19px; }
.route-actions button { min-height: 44px; border: 1px solid rgba(255,255,255,.10); border-radius: 11px; color: #fff; font-weight: 740; cursor: pointer; transition: transform .22s var(--ease), border-color .22s ease, box-shadow .22s ease, opacity .22s ease; }
.route-actions button:hover:not(:disabled) { transform: translateY(-1px); border-color: rgba(255,255,255,.18); box-shadow: 0 10px 24px rgba(0,0,0,.18), inset 0 1px 0 rgba(255,255,255,.08); }
.route-actions button:focus-visible { outline: 2px solid #ef9fc3; outline-offset: 3px; }
.route-actions button:disabled { opacity: .45; cursor: not-allowed; }
.route-block { background: linear-gradient(135deg, #d975a3, #a84d7a); }
.route-unblock { background: rgba(255,255,255,.055); color: #bbb2b9 !important; }
.route-empty { grid-column: 1 / -1; min-height: 170px; display: grid; place-content: center; text-align: center; }
.route-empty p { margin: 8px 0 0; }

@media (max-width: 700px) {
  .routes-heading { align-items: flex-start; flex-direction: column; gap: 13px; }
  .route-pc-list { grid-template-columns: 1fr; }
}

@media (max-width: 420px) {
  .route-actions { grid-template-columns: 1fr; }
}

/* Lobby builder */
.lobby-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 28px; margin-bottom: 18px; }
.lobby-heading h2 { margin-bottom: 8px; }
.lobby-heading .lede { max-width: 760px; margin-bottom: 0; }
.lobby-count { flex: 0 0 auto; padding: 9px 12px; border: 1px solid rgba(169,147,239,.20); border-radius: 999px; background: var(--lavender-soft); color: #d3c8f7; font-size: 11px; font-weight: 760; }
.lobby-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(330px, .75fr); align-items: start; gap: 18px; }
.lobby-picker { border-top-color: rgba(169,147,239,.32); }
.lobby-picker::before { background: radial-gradient(circle, rgba(169,147,239,.13), transparent 68%); }
.lobby-ready-key { display: inline-flex; align-items: center; gap: 7px; color: #a8a0a7; font-size: 10px; font-weight: 760; letter-spacing: .04em; text-transform: uppercase; }
.lobby-ready-key i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px var(--green-soft); }
.lobby-account-list { display: grid; gap: 9px; }
.lobby-account-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: stretch; gap: 9px; }
.lobby-account-choice { display: grid; grid-template-columns: auto auto minmax(0, 1fr) auto; align-items: center; gap: 11px; min-height: 64px; margin: 0; padding: 10px 12px; border: 1px solid rgba(255,255,255,.075); border-radius: 13px; background: rgba(255,255,255,.028); cursor: pointer; transition: border-color .22s ease, background-color .22s ease, transform .22s var(--ease), opacity .22s ease; }
.lobby-account-choice:hover { border-color: rgba(255,255,255,.14); background: rgba(255,255,255,.045); transform: translateY(-1px); }
.lobby-account-choice.selected { border-color: rgba(240,165,198,.24); background: linear-gradient(135deg, rgba(220,118,165,.10), rgba(169,147,239,.055)); }
.lobby-account-choice.unavailable { opacity: .48; cursor: not-allowed; }
.lobby-account-choice.unavailable:hover { border-color: rgba(255,255,255,.075); background: rgba(255,255,255,.028); transform: none; }
.lobby-account-choice input { appearance: none; display: grid; place-content: center; width: 20px; height: 20px; min-height: 20px; margin: 0; padding: 0; border: 1px solid rgba(255,255,255,.18); border-radius: 6px; background: rgba(0,0,0,.16); cursor: pointer; }
.lobby-account-choice input::after { content: ""; width: 9px; height: 5px; border-left: 2px solid #fff; border-bottom: 2px solid #fff; opacity: 0; transform: translateY(-1px) rotate(-45deg) scale(.5); transition: opacity .16s ease, transform .2s var(--ease); }
.lobby-account-choice input:checked { border-color: rgba(240,165,198,.62); background: linear-gradient(135deg, #e382af, #b85081); box-shadow: 0 0 0 3px rgba(220,118,165,.09); }
.lobby-account-choice input:checked::after { opacity: 1; transform: translateY(-1px) rotate(-45deg) scale(1); }
.lobby-account-choice input:focus-visible { outline: 2px solid #ef9fc3; outline-offset: 3px; }
.lobby-account-copy { min-width: 0; }
.lobby-account-copy b, .lobby-account-copy small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lobby-account-copy b { color: #e9e2e7; font-size: 13px; }
.lobby-account-copy small { margin-top: 3px; color: #817881; font-size: 10px; font-weight: 580; }
.lobby-account-state { display: inline-flex; align-items: center; gap: 6px; color: #8c838b; font-size: 10px; font-weight: 720; white-space: nowrap; }
.lobby-account-state::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #756d74; }
.lobby-account-state.ready { color: #9ed8bf; }
.lobby-account-state.ready::before { background: var(--green); box-shadow: 0 0 0 4px var(--green-soft); }
.lobby-leader-pick { min-width: 88px; min-height: 44px; padding: 8px 12px; border: 1px solid rgba(255,255,255,.09); border-radius: 11px; background: rgba(255,255,255,.04); color: #9c929a; font-size: 11px; font-weight: 740; cursor: pointer; }
.lobby-leader-pick:hover:not(:disabled) { border-color: rgba(240,165,198,.24); background: rgba(220,118,165,.09); color: #f2c3d7; }
.lobby-leader-pick.active { border-color: rgba(239,187,112,.24); background: var(--amber-soft); color: #f2cd97; }
.lobby-leader-pick:focus-visible { outline: 2px solid #ef9fc3; outline-offset: 3px; }
.lobby-help { min-height: 18px; margin: 13px 2px 0; color: #8d848c; font-size: 11px; line-height: 1.5; }
.lobby-empty { display: grid; place-items: center; min-height: 210px; padding: 26px; border: 1px dashed rgba(255,255,255,.10); border-radius: 13px; color: #8d848c; font-size: 12px; line-height: 1.6; text-align: center; }
.lobby-control { position: sticky; top: 24px; border-top-color: rgba(240,165,198,.32); }
.lobby-control::before { background: radial-gradient(circle, rgba(220,118,165,.13), transparent 68%); }
.lobby-control > div:first-child .lede { margin: 7px 0 0; font-size: 12px; }
.lobby-leader-summary { display: flex; align-items: center; gap: 11px; min-height: 68px; margin-top: 20px; padding: 11px 12px; border: 1px solid rgba(239,187,112,.14); border-radius: 13px; background: var(--amber-soft); }
.lobby-leader-summary .account-avatar { width: 42px; height: 42px; flex-basis: 42px; }
.lobby-leader-summary b, .lobby-leader-summary small { display: block; }
.lobby-leader-summary b { overflow: hidden; max-width: 220px; color: #f0e7ec; font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.lobby-leader-summary small { margin-top: 3px; color: #a7988b; font-size: 10px; font-weight: 650; }
.lobby-create, .lobby-search, .lobby-join { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 46px; margin-top: 12px; padding: 11px 14px; border: 1px solid rgba(255,255,255,.11); border-radius: 11px; color: #fff; font-weight: 750; cursor: pointer; transition: transform .22s var(--ease), border-color .22s ease, box-shadow .22s ease, opacity .22s ease; }
.lobby-create { background: linear-gradient(135deg, #df7eab, #ab4a78); box-shadow: 0 10px 25px rgba(171,74,120,.18); }
.lobby-create svg { width: 19px; height: 19px; }
.lobby-search { background: linear-gradient(135deg, #8f7bd7, #6958af); }
.lobby-join { justify-content: center; background: rgba(121,190,247,.10); color: #bfe1fb; }
.lobby-create:hover:not(:disabled), .lobby-search:hover:not(:disabled), .lobby-join:hover:not(:disabled) { transform: translateY(-1px); border-color: rgba(255,255,255,.19); box-shadow: 0 13px 28px rgba(0,0,0,.20), inset 0 1px 0 rgba(255,255,255,.10); }
.lobby-create:focus-visible, .lobby-search:focus-visible, .lobby-join:focus-visible { outline: 2px solid #ef9fc3; outline-offset: 3px; }
.lobby-queue-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 8px; }
.lobby-queue-grid label { min-width: 0; }
.lobby-control .account-result:not(:empty) { margin-top: 13px; }

@media (max-width: 1080px) {
  .lobby-layout { grid-template-columns: 1fr; }
  .lobby-control { position: static; }
}

@media (max-width: 700px) {
  .lobby-heading { align-items: flex-start; flex-direction: column; gap: 13px; }
  .lobby-account-choice { grid-template-columns: auto auto minmax(0, 1fr); }
  .lobby-account-state { grid-column: 2 / -1; }
}

@media (max-width: 460px) {
  .lobby-account-row { grid-template-columns: 1fr; }
  .lobby-leader-pick { width: 100%; }
  .lobby-queue-grid { grid-template-columns: 1fr; }
}

/* Apple-inspired restrained product UI */
:root {
  --bg: #0b0a0e;
  --bg-deep: #08070a;
  --surface: rgba(27, 25, 31, .88);
  --surface2: rgba(255, 255, 255, .045);
  --surface3: rgba(255, 255, 255, .07);
  --ink: #f5f2f5;
  --muted: #a9a2aa;
  --line: rgba(255, 255, 255, .09);
  --line-strong: rgba(255, 255, 255, .16);
  --pink: #f2a1c5;
  --pink2: #dd78a5;
  --pink-deep: #b85482;
  --pink-glow: rgba(226, 112, 165, .15);
  --shadow: 0 18px 48px rgba(0, 0, 0, .22), inset 0 1px 0 rgba(255, 255, 255, .045);
  --shadow-raised: 0 22px 58px rgba(0, 0, 0, .29), inset 0 1px 0 rgba(255, 255, 255, .065);
  --ease: cubic-bezier(.2, .8, .2, 1);
}

html { background: var(--bg-deep); }
body {
  background:
    radial-gradient(900px 620px at 102% -12%, rgba(200, 94, 145, .12), transparent 68%),
    radial-gradient(720px 560px at -12% 110%, rgba(127, 105, 169, .07), transparent 70%),
    linear-gradient(145deg, #0d0b10 0%, #09080c 54%, #0c0a0e 100%);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Segoe UI Variable", "Segoe UI", sans-serif;
  font-optical-sizing: auto;
  letter-spacing: 0;
}

.noise { opacity: .045; mix-blend-mode: soft-light; }

aside {
  background: rgba(15, 13, 18, .82);
  border-right-color: rgba(255,255,255,.075);
  box-shadow: 16px 0 48px rgba(0,0,0,.15), inset -1px 0 rgba(255,255,255,.018);
  backdrop-filter: blur(30px) saturate(128%);
}

.brand-mark,
.mark {
  border-radius: 13px;
  background:
    linear-gradient(145deg, rgba(255,255,255,.22), transparent 46%),
    linear-gradient(145deg, #ef9fc2, #bd5685);
  color: #fff;
  box-shadow: 0 9px 24px rgba(190,78,132,.20), inset 0 1px 0 rgba(255,255,255,.30);
  font-size: 17px;
  font-weight: 760;
}
.brand b { font-family: inherit; font-size: 17px; font-weight: 720; letter-spacing: -.025em; }
.brand small { color: #8d858d; letter-spacing: .035em; text-transform: none; }

.nav { border-radius: 12px; }
.nav::after {
  left: 3px;
  bottom: 50%;
  width: 3px;
  height: 20px;
  border-radius: 99px;
  background: var(--pink);
  transform: translate(-5px, 50%) scaleY(.55);
}
.nav.active::after { transform: translate(0, 50%) scaleY(1); }
.nav.active {
  background: linear-gradient(100deg, rgba(229,126,174,.13), rgba(255,255,255,.025));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.045);
}

main { max-width: 1540px; padding: 36px 44px 80px; }
header { min-height: 70px; margin-bottom: 26px; }
header h1 {
  font-family: inherit;
  font-size: clamp(30px, 3vw, 38px);
  font-weight: 720;
  line-height: 1.08;
  letter-spacing: -.042em;
}
.eyebrow { color: var(--pink); font-size: 9px; letter-spacing: .18em; }

button {
  border-radius: 12px;
  transition: transform 180ms var(--ease), box-shadow 220ms var(--ease), background-color 180ms ease,
    border-color 180ms ease, color 180ms ease, opacity 180ms ease;
}
button:active:not(:disabled) { transform: scale(.975); transition-duration: 80ms; }

.header-pill,
.badge { border-radius: 999px; }
.ghost { border-radius: 12px; backdrop-filter: blur(18px) saturate(120%); }

.card,
.account-pc {
  --spot-x: 82%;
  --spot-y: 0px;
  border-color: var(--line);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(31,28,35,.92), rgba(21,19,24,.88));
  box-shadow: var(--shadow);
}
.card { padding: 25px; }
.card::before,
.account-pc::before {
  opacity: .18;
  background: radial-gradient(300px circle at var(--spot-x) var(--spot-y), rgba(242,161,197,.15), transparent 70%);
}
.card.is-spotlit::before,
.account-pc.is-spotlit::before { opacity: .46; }
.card::after,
.account-pc::after { background: linear-gradient(125deg, rgba(255,255,255,.025), transparent 32%, transparent 78%); }
.card:hover,
.account-pc:hover {
  border-color: rgba(255,255,255,.14);
  box-shadow: var(--shadow-raised);
}

.hero {
  min-height: 132px;
  padding: 27px 29px;
  border-color: rgba(239,153,193,.15);
  background:
    radial-gradient(520px 220px at 92% -25%, rgba(222,112,165,.16), transparent 70%),
    linear-gradient(120deg, rgba(34,30,38,.96), rgba(24,20,28,.91));
}
.hero h2,
.page > .card > h2,
.optimizer-heading h2,
.lobby-heading h2,
.routes-heading h2 {
  font-family: inherit;
  font-weight: 710;
  letter-spacing: -.035em;
}
.hero h2 { font-size: clamp(28px, 3vw, 34px); }
h2 { font-size: 25px; }
h3 { font-weight: 680; letter-spacing: -.018em; }
.lede { color: var(--muted); letter-spacing: 0; }

input,
select,
.glass-select-trigger {
  min-height: 46px;
  border-radius: 12px;
  background: rgba(7,6,9,.46);
}
.glass-select-menu {
  border-radius: 14px;
  background: rgba(27,23,30,.985);
  box-shadow: 0 22px 54px rgba(0,0,0,.42), inset 0 1px 0 rgba(255,255,255,.06);
  backdrop-filter: blur(26px) saturate(135%);
}
.glass-select-option { border-radius: 9px; }

.primary,
.command-row button,
.new-session button,
.join-row button,
.lobby-create,
.lobby-search,
.lobby-join,
.route-actions button,
.account-actions button,
.account-pc-title button {
  border-radius: 13px;
}
.primary,
.lobby-create {
  background: linear-gradient(180deg, #efa0c3 0%, #da73a2 100%);
  color: #190d13;
  box-shadow: 0 9px 24px rgba(202,83,139,.20), inset 0 1px 0 rgba(255,255,255,.30);
}
.primary:hover,
.lobby-create:hover:not(:disabled) {
  box-shadow: 0 12px 30px rgba(202,83,139,.27), inset 0 1px 0 rgba(255,255,255,.34);
}
.primary::after { opacity: .62; }

.pc,
.setting-toggle,
.lobby-account-choice,
.lobby-leader-summary { border-radius: 14px; }
.settings-tabs { border-radius: 14px; }
.settings-tab { border-radius: 10px; }
.metric {
  font-family: inherit;
  color: var(--pink);
  text-decoration: none;
  font-weight: 710;
}

.active-page { animation: apple-page-in .30s var(--ease) backwards; }
.active-page .card { animation: apple-card-in .34s var(--ease) backwards; }
.active-page .card:nth-child(2) { animation-delay: 28ms; }
.active-page .card:nth-child(3) { animation-delay: 48ms; }

@keyframes apple-page-in {
  from { opacity: .32; transform: translate3d(0,7px,0); }
  to { opacity: 1; transform: translate3d(0,0,0); }
}
@keyframes apple-card-in {
  from { opacity: .18; transform: translate3d(0,9px,0) scale(.996); }
  to { opacity: 1; transform: translate3d(0,0,0) scale(1); }
}

::view-transition-old(panel-page) { animation: tab-page-out .13s ease-in both; }
::view-transition-new(panel-page) { animation: apple-page-in .30s var(--ease) both; }
::view-transition-new(panel-title) { animation: tab-title-in .24s var(--ease) both; }

.login {
  background:
    radial-gradient(760px 560px at 84% 8%, rgba(213,100,153,.16), transparent 68%),
    linear-gradient(145deg, rgba(14,12,17,.98), rgba(8,7,10,.98));
}
.login-card {
  border-radius: 22px;
  background: rgba(29,26,33,.86);
  box-shadow: 0 30px 80px rgba(0,0,0,.40), inset 0 1px 0 rgba(255,255,255,.065);
  backdrop-filter: blur(28px) saturate(125%);
}
.login-card h1 { font-family: inherit; font-weight: 720; }
.login-card button {
  border-radius: 13px;
  color: #190d13;
  background: linear-gradient(180deg, #efa0c3, #da73a2);
}

@media (max-width: 1120px) {
  main { padding-inline: 30px; }
}
@media (max-width: 900px) {
  body { overflow-x: hidden; }
  .shell > aside { overflow: hidden; }
  .shell > aside nav { width: 100%; max-width: 100%; }
  main { padding: 28px 20px 64px; }
}
@media (max-width: 700px) {
  header { min-height: 62px; margin-bottom: 21px; }
  header h1 { font-size: 28px; }
  .card { padding: 21px; border-radius: 18px; }
  .hero { min-height: 0; padding: 23px; }
  .account-pc { border-radius: 18px; }
}

@media (prefers-reduced-transparency: reduce) {
  aside,
  .ghost,
  .glass-select-menu,
  .login-card { background: #19161d; backdrop-filter: none; }
}
@media (prefers-contrast: more) {
  :root { --line: rgba(255,255,255,.22); --line-strong: rgba(255,255,255,.34); }
  .card, .account-pc, input, select, .glass-select-trigger { background: #17141b; }
}
@media (prefers-reduced-motion: reduce) {
  .active-page,
  .active-page .card { animation: none !important; transform: none !important; }
}
