@font-face {
  font-family: Geist;
  src: url('/fonts/geist-sans.woff2') format('woff2');
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: 'Geist Mono';
  src: url('/fonts/geist-mono.woff2') format('woff2');
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: 'Geist Serif';
  src: url('/fonts/geist-serif.woff2') format('woff2');
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #000;
  --surface: #0a0a0a;
  --surface-2: #111;
  --surface-3: #1a1a1a;
  --line: #222;
  --line-strong: #333;
  --text: #fafafa;
  --text-2: #d4d4d4;
  --muted: #a1a1a1;
  --faint: #737373;
  --accent: #f5f5f5;
  --accent-ink: #0a0a0a;
  --green: #22c55e;
  --green-deep: #15803d;
  --blue: #60a5fa;
  --amber: #f59e0b;
  --red: #f87171;
  --radius-sm: 7px;
  --radius: 10px;
  --radius-lg: 16px;
  --sans: Geist, ui-sans-serif, system-ui, sans-serif;
  --serif: 'Geist Serif', Georgia, serif;
  --mono: 'Geist Mono', ui-monospace, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --ease-out: cubic-bezier(.16, 1, .3, 1);
  --nav-h: 68px;
  --sidebar-w: 268px;
  --gutter: clamp(18px, 5vw, 56px);
  --fs-xs: 12px;
  --fs-sm: 13px;
  --fs-base: 15px;
  --fs-md: 16px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
  scrollbar-width: none;
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  display: none;
}

* {
  scrollbar-width: none;
}

*::-webkit-scrollbar {
  width: 0;
  height: 0;
}

body {
  margin: 0;
}

.app-body {
  min-height: 100svh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: var(--fs-base);
  line-height: 1.6;
  letter-spacing: -.011em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.app-body.no-scroll,
.app-body.no-scroll-sheet {
  overflow: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

img,
svg {
  display: block;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: default;
}

::selection {
  background: #fafafa;
  color: #000;
}

:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 3px;
  border-radius: 4px;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 600;
  letter-spacing: -.045em;
  line-height: 1.08;
  text-wrap: balance;
}

p {
  margin: 0;
  text-wrap: pretty;
}

em {
  font-family: var(--serif);
  font-style: normal;
  font-weight: 400;
  letter-spacing: -.04em;
  color: var(--text-2);
}

code,
kbd,
pre {
  font-family: var(--mono);
}

[hidden] {
  display: none !important;
}

.icon {
  width: 18px;
  height: 18px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 300;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--accent-ink);
  font-size: var(--fs-sm);
  font-weight: 600;
  transform: translateY(-160%);
  transition: transform .2s var(--ease-out);
}

.skip-link:focus {
  transform: none;
}

.site-container,
.site-nav-inner {
  width: min(100% - var(--gutter) * 2, 1240px);
  margin-inline: auto;
}

.section-label,
.eyebrow,
.form-kicker,
.panel-count,
.legal-number,
.error-code {
  font: 500 11px/1.5 var(--mono);
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 19px;
  font-weight: 650;
  letter-spacing: -.06em;
}

.brand-mark {
  width: 32px;
  height: 32px;
  border-radius: 9px;
  transition: transform .5s var(--ease-out);
}

.brand:hover .brand-mark {
  transform: rotate(-8deg) scale(1.06);
}

.brand-dot {
  color: var(--faint);
}

.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--nav-h);
  border-bottom: 1px solid transparent;
  background: rgba(0, 0, 0, .72);
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  transition: border-color .3s, background .3s;
}

.site-nav.is-scrolled {
  border-bottom-color: var(--line);
  background: rgba(0, 0, 0, .86);
}

.site-nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: 24px;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: var(--fs-sm);
  font-weight: 550;
  transition: background .2s, border-color .2s;
}

.nav-link:hover {
  border-color: #555;
  background: var(--surface-2);
}

.nav-link .icon {
  width: 16px;
  height: 16px;
}

.nav-link-ghost {
  border-color: transparent;
  color: var(--muted);
}

.nav-link-ghost:hover {
  border-color: transparent;
  color: var(--text);
}

.nav-avatar {
  border-radius: 50%;
  transition: transform .25s var(--ease-out);
}

.nav-avatar:hover {
  transform: scale(1.06);
}

.nav-progress,
.topbar-progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: linear-gradient(90deg, #8a8a8a, #fafafa);
  transform: scaleX(var(--progress, 0));
  transform-origin: left;
  pointer-events: none;
  transition: opacity .3s;
}

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px 24px;
  padding: 28px 0 36px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: var(--fs-sm);
}

.site-footer.is-compact {
  margin-top: 64px;
  padding-bottom: 8px;
}

.landing-body .site-footer {
  padding-bottom: 96px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.footer-brand .brand-mark {
  width: 22px;
  height: 22px;
  border-radius: 6px;
  opacity: .8;
}

.site-footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
}

.site-footer-links a {
  color: var(--muted);
  transition: color .2s;
}

.site-footer-links a:hover,
.site-footer-links a[aria-current='page'] {
  color: var(--text);
}

.button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  transition: background .2s, border-color .2s, color .2s, transform .15s var(--ease), box-shadow .25s, opacity .2s;
}

.button:active:not(:disabled) {
  transform: scale(.97);
}

.button .icon {
  width: 16px;
  height: 16px;
}

.button-primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.button-primary:hover {
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .09);
}

.button-secondary {
  border-color: var(--line-strong);
  background: var(--surface);
  color: var(--text);
}

.button-secondary:hover {
  border-color: #555;
  background: var(--surface-2);
}

.button-danger {
  background: #dc2626;
  color: #fff;
}

.button-danger:hover {
  background: #ef4444;
  box-shadow: 0 0 0 4px rgba(239, 68, 68, .16);
}

.button.is-loading,
.button:disabled {
  opacity: .75;
  pointer-events: none;
}

.button-arrow {
  display: inline-block;
  font-size: 17px;
  transition: transform .25s var(--ease-out);
}

.button:hover .button-arrow {
  transform: translateX(3px);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--text-2);
  font-size: 14px;
  font-weight: 550;
  transition: color .2s;
}

.text-link:hover {
  color: var(--text);
}

.text-link span {
  transition: transform .25s var(--ease-out);
}

.text-link:hover span {
  transform: translate(2px, -2px);
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--muted);
  transition: background .2s, color .2s, border-color .2s, transform .15s;
}

.icon-button:hover {
  border-color: var(--line);
  background: var(--surface-2);
  color: var(--text);
}

.icon-button:active {
  transform: scale(.94);
}

.spinner {
  width: 15px;
  height: 15px;
  flex: none;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}

.is-spinning .icon {
  animation: spin .8s linear infinite;
}

.avatar {
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(140deg, #2a2a2a, #121212);
  color: var(--text);
  font-size: 14px;
  font-weight: 650;
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .08);
}

.avatar img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity .4s var(--ease);
}

.avatar.has-photo img {
  opacity: 1;
}

.avatar.has-photo .avatar-initial {
  visibility: hidden;
}

.avatar-sm { width: 32px; height: 32px; font-size: 12px; }
.avatar-md { width: 44px; height: 44px; font-size: 16px; }
.avatar-lg { width: 72px; height: 72px; font-size: 26px; }

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 24px;
  padding: 0 9px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--text-2);
  font-size: 11px;
  font-weight: 550;
  white-space: nowrap;
}

.badge-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--faint);
  animation: pulse-soft 1.6s var(--ease) infinite;
}

.badge-muted { color: var(--faint); }
.badge-ok { border-color: rgba(34, 197, 94, .35); color: #86efac; }
.badge-ok .badge-dot { background: var(--green); animation: none; }
.badge-error { border-color: rgba(248, 113, 113, .35); color: #fca5a5; }
.badge-error .badge-dot { background: var(--red); animation: none; }
.badge-warn { border-color: rgba(245, 158, 11, .4); color: #fcd34d; }
.badge-warn .badge-dot { background: var(--amber); animation: none; }
.badge-info { border-color: rgba(96, 165, 250, .4); color: #93c5fd; }

.chip-row {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  padding-bottom: 4px;
  overflow-x: auto;
}

.chip-wrap {
  flex-wrap: wrap;
  overflow: visible;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: var(--fs-sm);
  font-weight: 550;
  transition: background .2s, color .2s, border-color .2s, transform .15s var(--ease);
}

.chip:hover {
  border-color: #555;
  color: var(--text);
}

.chip:active {
  transform: scale(.96);
}

.chip.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
}

.chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.tone-folder { color: #fbbf24; }
.tone-image { color: #a78bfa; }
.tone-video { color: #f472b6; }
.tone-audio { color: #22d3ee; }
.tone-pdf { color: #f87171; }
.tone-sheet { color: #4ade80; }
.tone-slide { color: #fb923c; }
.tone-doc { color: #60a5fa; }
.tone-archive { color: #e5e7eb; }
.tone-other { color: #a1a1a1; }
.tone-bg-folder { background: #fbbf24; }
.tone-bg-image { background: #a78bfa; }
.tone-bg-video { background: #f472b6; }
.tone-bg-audio { background: #22d3ee; }
.tone-bg-pdf { background: #f87171; }
.tone-bg-sheet { background: #4ade80; }
.tone-bg-slide { background: #fb923c; }
.tone-bg-doc { background: #60a5fa; }
.tone-bg-archive { background: #e5e7eb; }
.tone-bg-other { background: #a1a1a1; }

.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
}

.tab {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: none;
  height: 44px;
  padding: 0 14px;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 14px;
  font-weight: 550;
  transition: color .2s;
}

.tab::after {
  content: '';
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: -1px;
  height: 2px;
  border-radius: 2px;
  background: var(--text);
  transform: scaleX(0);
  transition: transform .3s var(--ease-out);
}

.tab:hover {
  color: var(--text);
}

.tab.is-active {
  color: var(--text);
}

.tab.is-active::after {
  transform: scaleX(1);
}

.tab span:empty {
  display: none;
}

.tab span {
  min-width: 20px;
  padding: 1px 7px;
  border-radius: 999px;
  background: var(--surface-3);
  color: var(--muted);
  font: 500 11px var(--mono);
  text-align: center;
}

.segmented {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
}

.segmented button {
  height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 7px;
  background: none;
  color: var(--muted);
  font-size: var(--fs-sm);
  font-weight: 550;
  transition: background .2s, color .2s;
}

.segmented button:hover {
  color: var(--text);
}

.segmented button[aria-checked='true'] {
  background: var(--accent);
  color: var(--accent-ink);
}

.toggle {
  position: relative;
  width: 42px;
  height: 24px;
  flex: none;
  margin: 0;
  border-radius: 999px;
  background: var(--surface-3);
  box-shadow: inset 0 0 0 1px var(--line-strong);
  appearance: none;
  cursor: pointer;
  transition: background .25s var(--ease);
}

.toggle::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--muted);
  transition: transform .3s var(--ease-out), background .25s;
}

.toggle:checked {
  background: var(--green-deep);
  box-shadow: inset 0 0 0 1px var(--green);
}

.toggle:checked::after {
  background: #fff;
  transform: translateX(18px);
}

.meter {
  height: 6px;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
}

.meter span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #8a8a8a, #fafafa);
  transition: width 1s var(--ease-out);
}

.meter.is-high span {
  background: linear-gradient(90deg, #b45309, var(--amber));
}

.skeleton {
  display: inline-block;
  height: 12px;
  border-radius: 4px;
  background: linear-gradient(90deg, #141414 0%, #232323 50%, #141414 100%);
  background-size: 200% 100%;
  animation: shimmer 1.3s linear infinite;
  vertical-align: middle;
}

.skeleton-text { width: 72px; height: 14px; }
.skeleton-wide { width: 60%; height: 14px; }
.skeleton-line { width: 85%; height: 10px; }
.skeleton-display { width: min(280px, 70%); height: clamp(40px, 6vw, 64px); border-radius: 10px; }

.empty-state-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 48px;
  height: 48px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: var(--surface-2);
  color: var(--text);
  transition: background .25s, color .25s;
}

.empty-state {
  display: grid;
  justify-items: center;
  gap: 12px;
  padding: clamp(56px, 9vw, 110px) 24px;
  border-block: 1px solid var(--line);
  text-align: center;
}

.empty-state h3 {
  margin-top: 4px;
  font-size: clamp(24px, 3vw, 32px);
}

.empty-state p {
  max-width: 440px;
  margin-bottom: 8px;
  color: var(--muted);
}

.empty-state .empty-state-icon {
  animation: float 4s var(--ease) infinite;
}

.auth-field input,
.search-field input,
.key-form input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  outline: none;
  background: var(--bg);
  color: var(--text);
  font-size: var(--fs-md);
  transition: border-color .2s, box-shadow .2s;
}

.auth-field input::placeholder,
.search-field input::placeholder {
  color: var(--faint);
}

.auth-field input:hover,
.search-field input:hover {
  border-color: #4a4a4a;
}

.auth-field input:focus,
.search-field input:focus {
  border-color: #8a8a8a;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .07);
}

.search-field {
  position: relative;
  flex: 1;
  min-width: 0;
}

.search-field .icon {
  position: absolute;
  left: 14px;
  top: 50%;
  width: 16px;
  height: 16px;
  color: var(--faint);
  transform: translateY(-50%);
  pointer-events: none;
}

.search-field input {
  padding-left: 40px;
}

.select-field select {
  height: 46px;
  padding: 0 36px 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg);
  font-size: var(--fs-md);
}

.select {
  position: relative;
  min-width: 210px;
}

.select-native {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  pointer-events: none;
}

.select-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  height: 46px;
  padding: 0 12px 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--bg);
  font-size: 14px;
  text-align: left;
  transition: border-color .2s, box-shadow .2s;
}

.select-trigger:hover {
  border-color: #4a4a4a;
}

.select.is-open .select-trigger,
.select-trigger:focus-visible {
  border-color: #8a8a8a;
  outline: none;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .07);
}

.select-value {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.select-chevron {
  width: 16px;
  height: 16px;
  flex: none;
  fill: none;
  stroke: var(--muted);
  stroke-width: 2;
  stroke-linecap: round;
  transition: transform .25s var(--ease-out);
}

.select.is-open .select-chevron {
  transform: rotate(180deg);
}

.select-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 70;
  width: max(100%, 260px);
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: rgba(14, 14, 14, .97);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: pop-in .2s var(--ease-out);
}

.select-panel.is-up {
  top: auto;
  bottom: calc(100% + 6px);
  animation-name: pop-in-up;
}

.select-sheet-head {
  display: none;
}

.select-search {
  width: 100%;
  height: 38px;
  margin-bottom: 6px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 6px;
  outline: none;
  background: var(--bg);
  font-size: var(--fs-sm);
}

.select-list {
  max-height: var(--select-max, 280px);
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
  outline: none;
  overscroll-behavior: contain;
}

.select-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 40px;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--text-2);
  font-size: 14px;
  cursor: pointer;
}

.select-option span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.select-option.is-active {
  background: var(--surface-3);
  color: var(--text);
}

.select-check {
  width: 15px;
  height: 15px;
  flex: none;
  fill: none;
  stroke: var(--text);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0;
}

.select-option[aria-selected='true'] {
  color: var(--text);
  font-weight: 600;
}

.select-option[aria-selected='true'] .select-check {
  opacity: 1;
}

.select-backdrop {
  position: fixed;
  inset: 0;
  z-index: 69;
  background: rgba(0, 0, 0, .6);
  animation: fade-in .2s var(--ease);
}

.menu {
  position: relative;
}

.menu-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 60;
  display: grid;
  min-width: 210px;
  padding: 6px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: rgba(14, 14, 14, .97);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  animation: pop-in .18s var(--ease-out);
}

.menu-panel.is-up {
  top: auto;
  bottom: calc(100% + 6px);
  animation-name: pop-in-up;
}

.menu-panel [role='menuitem'] {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: none;
  color: var(--text-2);
  font-size: 14px;
  text-align: left;
  white-space: nowrap;
  transition: background .15s, color .15s;
}

.menu-panel [role='menuitem'] .icon {
  width: 16px;
  height: 16px;
  color: var(--muted);
}

.menu-panel [role='menuitem']:hover,
.menu-panel [role='menuitem']:focus-visible {
  outline: none;
  background: var(--surface-3);
  color: var(--text);
}

.menu-panel .menu-danger {
  margin-top: 4px;
  border-top: 1px solid var(--line);
  border-radius: 0 0 6px 6px;
  color: #fca5a5;
}

.menu-panel .menu-danger .icon {
  color: #fca5a5;
}

.menu-panel .menu-danger:hover {
  background: rgba(248, 113, 113, .1);
  color: #fecaca;
}

.toast-region {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 200;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  width: min(390px, calc(100vw - 40px));
  pointer-events: none;
}

body:has(#upload-dock:not([hidden])) .toast-region {
  top: calc(var(--nav-h) + 12px);
  bottom: auto;
  flex-direction: column-reverse;
}

.toast {
  position: relative;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 12px;
  width: 100%;
  padding: 14px 12px 16px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: rgba(17, 17, 17, .94);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .6);
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  overflow: hidden;
  pointer-events: auto;
  touch-action: pan-y;
  animation: toast-in .42s var(--ease-out);
  transition: transform .2s, opacity .2s;
}

.toast.is-leaving {
  animation: toast-out .26s var(--ease) forwards;
}

.toast-icon {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface-3);
}

.toast-icon svg,
.toast-close svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.toast-success .toast-icon { background: rgba(34, 197, 94, .16); color: var(--green); }
.toast-error .toast-icon { background: rgba(248, 113, 113, .16); color: var(--red); }

.toast-body {
  min-width: 0;
  padding-top: 2px;
}

.toast-body strong {
  display: block;
  font-size: 14px;
  font-weight: 600;
  overflow-wrap: anywhere;
}

.toast-body p {
  margin-top: 2px;
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.toast-close {
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--faint);
  transition: background .2s, color .2s;
}

.toast-close:hover {
  background: var(--surface-3);
  color: var(--text);
}

.toast-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--text);
  opacity: .5;
  transform-origin: left;
  animation: toast-progress var(--duration, 5000ms) linear forwards;
}

.toast-success .toast-progress { background: var(--green); }
.toast-error .toast-progress { background: var(--red); }
.toast.is-paused .toast-progress { animation-play-state: paused; }

.confirm,
.preview {
  padding: 0;
  border: 1px solid var(--line-strong);
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 40px 120px rgba(0, 0, 0, .7);
}

.confirm::backdrop,
.preview::backdrop {
  background: rgba(0, 0, 0, .72);
  backdrop-filter: blur(4px);
}

.confirm {
  width: min(440px, calc(100% - 32px));
  padding: 28px;
  border-radius: 18px;
}

.confirm[open],
.preview[open] {
  animation: pop-in .26s var(--ease-out);
}

.confirm.is-closing,
.preview.is-closing {
  animation: pop-out .16s var(--ease) forwards;
}

.confirm-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 18px;
  border-radius: 50%;
  background: rgba(239, 68, 68, .12);
  color: var(--red);
}

.confirm-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.confirm h2 {
  font-size: 20px;
  letter-spacing: -.03em;
  overflow-wrap: anywhere;
}

.confirm p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 26px;
}

.preview {
  width: min(1000px, calc(100% - 32px));
  max-height: calc(100svh - 48px);
  border-radius: var(--radius-lg);
}

.preview[open] {
  display: flex;
  flex-direction: column;
}

.preview-head,
.preview-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
}

.preview-head {
  border-bottom: 1px solid var(--line);
}

.preview-head > div {
  min-width: 0;
}

.preview-head h2 {
  margin-top: 4px;
  overflow: hidden;
  font-size: 17px;
  letter-spacing: -.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.preview-body {
  display: grid;
  place-items: center;
  min-height: 320px;
  padding: 20px;
  background: #050505;
  overflow: auto;
}

.preview-body img {
  max-width: 100%;
  max-height: 68svh;
  border-radius: 8px;
  animation: fade-in .3s var(--ease);
}

.preview-body iframe {
  width: 100%;
  height: 70svh;
  border: 0;
  border-radius: 8px;
  background: #fff;
  opacity: 0;
  transition: opacity .3s;
}

.preview-body iframe.is-ready {
  opacity: 1;
}

.preview-body video {
  width: 100%;
  max-height: 68svh;
  border-radius: 8px;
  background: #000;
}

.preview-body audio {
  width: min(100%, 520px);
}

.preview-code {
  width: 100%;
  max-height: 68svh;
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text-2);
  font-size: var(--fs-sm);
  line-height: 1.6;
  white-space: pre-wrap;
  overflow: auto;
  overflow-wrap: anywhere;
  align-self: stretch;
}

.preview-loading,
.preview-message {
  display: grid;
  justify-items: center;
  gap: 14px;
  color: var(--muted);
  text-align: center;
}

.preview-loading {
  display: flex;
  align-items: center;
  gap: 10px;
}

.preview-thumb {
  max-width: min(420px, 100%);
  max-height: 48svh;
  border-radius: 8px;
  box-shadow: 0 0 0 1px var(--line);
}

.preview-foot {
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: var(--fs-sm);
}

.preview-actions {
  display: flex;
  gap: 8px;
}

.preview-actions .button {
  min-height: 38px;
  padding: 0 14px;
  font-size: var(--fs-sm);
}

.preview-delete:hover {
  border-color: rgba(248, 113, 113, .5);
  color: #fecaca;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center;
  gap: clamp(48px, 7vw, 112px);
  min-height: min(840px, calc(100svh - var(--nav-h)));
  padding-block: clamp(64px, 9vw, 130px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-2);
}

.eyebrow-star {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 4px rgba(34, 197, 94, .16);
  animation: pulse 2.4s var(--ease) infinite;
}

.hero h1 {
  margin-top: 24px;
  font-size: clamp(48px, 5.6vw, 92px);
  font-weight: 650;
  letter-spacing: -.07em;
  line-height: .96;
}

.hero-description {
  max-width: 560px;
  margin-top: 28px;
  color: var(--muted);
  font-size: clamp(16px, 1.4vw, 19px);
  line-height: 1.65;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px 24px;
  margin-top: 36px;
}

.hero-note {
  margin-top: 22px;
  color: var(--faint);
  font-size: var(--fs-xs);
}

.hero-visual {
  position: relative;
  padding: 8px 0 8px 36px;
  border-left: 1px solid var(--line);
}

.hero-visual-head {
  display: flex;
  justify-content: space-between;
  color: var(--faint);
  font: 500 10px/1.4 var(--mono);
  letter-spacing: .14em;
}

.hero-visual-free {
  display: block;
  margin: 28px 0 18px;
  font-size: clamp(42px, 5vw, 68px);
  font-weight: 650;
  letter-spacing: -.07em;
  line-height: 1;
}

.hero-visual-bar,
.capacity-bar {
  display: flex;
  gap: 3px;
  height: 12px;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
}

.hero-visual-bar span {
  width: var(--w);
  background: var(--c);
  animation: grow 1.4s .3s var(--ease-out) both;
  transform-origin: left;
}

.hero-visual-list,
.capacity-legend {
  display: grid;
  gap: 0;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.hero-visual-list li,
.capacity-legend li {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  border-top: 1px solid var(--line);
  color: var(--text-2);
  font-size: 14px;
}

.hero-visual-list b,
.legend-value {
  margin-left: auto;
  color: var(--muted);
  font: 500 12px var(--mono);
}

.legend-dot {
  width: 9px;
  height: 9px;
  flex: none;
  border-radius: 3px;
}

.legend-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.hero-visual-upload {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 22px;
  padding: 14px 16px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: rgba(17, 17, 17, .9);
  box-shadow: 0 24px 60px rgba(0, 0, 0, .6);
  animation: float 5s var(--ease) infinite;
}

.hero-visual-upload > div {
  display: grid;
  flex: 1;
  min-width: 0;
  gap: 2px;
}

.hero-visual-upload strong {
  font-size: 14px;
}

.hero-visual-upload small {
  color: var(--faint);
  font-size: var(--fs-xs);
}

.hero-visual-upload .dock-bar span {
  animation: upload-loop 3.2s var(--ease) infinite;
}

.story,
.features,
.faq,
.cta {
  padding-block: clamp(80px, 9vw, 128px);
  border-top: 1px solid var(--line);
}

.story-heading,
.faq-heading {
  max-width: 720px;
}

.story h2,
.features h2,
.faq-heading h2,
.cta h2,
.error-page h1 {
  margin-top: 16px;
  font-size: clamp(38px, 5.4vw, 72px);
  font-weight: 600;
  letter-spacing: -.065em;
  line-height: 1.02;
}

.story-heading > p:last-child {
  max-width: 560px;
  margin-top: 22px;
  color: var(--muted);
  font-size: 17px;
}

.story-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 40px;
  margin-top: 56px;
}

.story-panel {
  padding: 28px 0 8px;
  border-top: 1px solid var(--line-strong);
}

.story-panel h3 {
  margin-top: 48px;
  font-size: 22px;
  letter-spacing: -.04em;
}

.story-panel p {
  margin-top: 10px;
  color: var(--muted);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 56px;
  border-top: 1px solid var(--line);
}

.feature {
  padding: 32px 28px 32px 0;
  border-bottom: 1px solid var(--line);
}

.feature:not(:nth-child(3n + 1)) {
  padding-left: 28px;
  border-left: 1px solid var(--line);
}

.feature .icon {
  width: 22px;
  height: 22px;
  color: var(--text);
  transition: transform .4s var(--ease-out);
}

.feature:hover .icon {
  transform: translateY(-3px) scale(1.08);
}

.feature h3 {
  margin-top: 22px;
  font-size: 19px;
  letter-spacing: -.03em;
}

.feature p {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.faq {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: clamp(32px, 6vw, 96px);
}

.faq-list {
  border-top: 1px solid var(--line);
}

.faq-item {
  border-bottom: 1px solid var(--line);
}

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 0;
  list-style: none;
  cursor: pointer;
  font-size: 17px;
  font-weight: 550;
  letter-spacing: -.02em;
  transition: color .2s;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: '+';
  flex: none;
  color: var(--muted);
  font: 400 20px var(--mono);
  transition: transform .3s var(--ease-out);
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item p {
  padding: 0 40px 24px 0;
  color: var(--muted);
  line-height: 1.7;
}

.faq-item[open] p {
  animation: fade-up .35s var(--ease-out);
}

.cta {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 32px;
}

.cta h2 {
  max-width: 720px;
  margin: 0;
}

.cta .hero-actions {
  margin: 0;
}

.auth-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 440px);
  align-items: center;
  gap: clamp(48px, 9vw, 150px);
  min-height: calc(100svh - var(--nav-h) - 100px);
  padding-block: clamp(40px, 6vw, 80px);
}

.auth-aside h2 {
  margin-top: 22px;
  font-size: clamp(44px, 6vw, 84px);
  letter-spacing: -.07em;
  line-height: .98;
}

.auth-aside > p {
  max-width: 440px;
  margin-top: 26px;
  color: var(--muted);
  font-size: 17px;
}

.auth-aside-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 64px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font: 500 10px var(--mono);
  letter-spacing: .14em;
}

.auth-content h1 {
  margin-top: 12px;
  font-size: clamp(30px, 3.2vw, 38px);
  letter-spacing: -.055em;
}

.auth-intro {
  margin: 10px 0 26px;
  color: var(--muted);
  font-size: 14px;
}

.form-error {
  margin-bottom: 18px;
  padding: 12px 14px;
  border: 1px solid rgba(248, 113, 113, .35);
  border-radius: var(--radius-sm);
  background: rgba(248, 113, 113, .08);
  color: #fecaca;
  font-size: var(--fs-sm);
  animation: shake .4s var(--ease);
}

.google-auth-button {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 50px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  font-size: 14px;
  font-weight: 600;
  transition: background .2s, border-color .2s, transform .15s var(--ease);
}

.google-auth-button:hover {
  border-color: #555;
  background: var(--surface-3);
}

.google-auth-button:active {
  transform: scale(.98);
}

.google-auth-button.is-loading {
  pointer-events: none;
  opacity: .7;
}

.google-auth-icon {
  width: 20px;
  height: 20px;
}

.google-auth-arrow {
  margin-left: auto;
  color: var(--muted);
  transition: transform .25s var(--ease-out);
}

.google-auth-button:hover .google-auth-arrow {
  transform: translateX(3px);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 22px 0;
  color: var(--faint);
  font-size: var(--fs-xs);
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--line);
}

.auth-form {
  display: grid;
  gap: 16px;
}

.auth-field {
  display: grid;
  gap: 7px;
}

.auth-field label {
  color: var(--text-2);
  font-size: var(--fs-sm);
  font-weight: 550;
}

.auth-submit {
  width: 100%;
  margin-top: 6px;
}

.auth-switch {
  margin-top: 20px;
  color: var(--muted);
  font-size: var(--fs-sm);
  text-align: center;
}

.auth-switch a {
  color: var(--text);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.auth-footnote {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: var(--fs-xs);
}

.legal-inline-links {
  display: flex;
  gap: 16px;
  margin-top: 10px;
}

.legal-inline-links a {
  color: var(--muted);
  transition: color .2s;
}

.legal-inline-links a:hover {
  color: var(--text);
}

.legal-main {
  padding-block: clamp(56px, 8vw, 112px);
}

.legal-intro {
  max-width: 820px;
  padding-bottom: 48px;
}

.legal-intro h1 {
  margin-top: 18px;
  font-size: clamp(44px, 6.5vw, 88px);
  letter-spacing: -.07em;
  line-height: .98;
}

.legal-intro p {
  max-width: 620px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 17px;
}

.legal-updated {
  display: inline-block;
  margin-top: 20px;
  color: var(--faint);
  font: 500 11px var(--mono);
  letter-spacing: .06em;
}

.legal-layout {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: clamp(40px, 8vw, 120px);
  padding-top: 40px;
  border-top: 1px solid var(--line);
}

.legal-index {
  position: sticky;
  top: calc(var(--nav-h) + 28px);
  align-self: start;
  display: grid;
  gap: 10px;
}

.legal-index span {
  margin-bottom: 6px;
  color: var(--faint);
  font: 500 10px var(--mono);
  letter-spacing: .14em;
}

.legal-index a {
  color: var(--muted);
  font-size: var(--fs-sm);
  transition: color .2s, transform .25s var(--ease-out);
}

.legal-index a:hover {
  color: var(--text);
  transform: translateX(3px);
}

.legal-content {
  max-width: 740px;
}

.legal-content section {
  padding-bottom: 44px;
}

.legal-content section + section {
  padding-top: 44px;
  border-top: 1px solid var(--line);
}

.legal-content h2 {
  margin: 12px 0 16px;
  font-size: clamp(26px, 3vw, 36px);
  letter-spacing: -.05em;
}

.legal-content p {
  color: var(--muted);
  line-height: 1.75;
}

.legal-content p + p {
  margin-top: 14px;
}

.legal-content a {
  color: var(--text);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.error-page {
  display: grid;
  align-content: center;
  min-height: calc(100svh - var(--nav-h) - 100px);
  padding-block: 96px;
}

.error-page h1 em {
  color: var(--faint);
}

.error-page p {
  max-width: 520px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 17px;
}

.connect-main {
  display: grid;
  justify-items: center;
  gap: 48px;
  padding-block: clamp(32px, 6vw, 72px) 40px;
}

.authorize-card,
.connected-list {
  width: min(100%, 560px);
}

.authorize-logos {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 28px;
}

.authorize-logo {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: var(--surface-2);
  box-shadow: 0 10px 30px rgba(0, 0, 0, .4);
}

.authorize-logo img {
  width: 44px;
  height: 44px;
  border-radius: 11px;
}

.authorize-logo-drive {
  background: #fff;
}

.authorize-logo-drive svg {
  width: 36px;
  height: 32px;
}

.authorize-link {
  display: flex;
  gap: 6px;
}

.authorize-link span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: link-dot 1.4s var(--ease) infinite;
}

.authorize-link span:nth-child(2) { animation-delay: .18s; }
.authorize-link span:nth-child(3) { animation-delay: .36s; }

.authorize-head {
  text-align: center;
}

.authorize-head h1 {
  margin-top: 10px;
  font-size: clamp(28px, 4vw, 36px);
  letter-spacing: -.05em;
}

.authorize-head p {
  max-width: 440px;
  margin: 12px auto 0;
  color: var(--muted);
  font-size: 14px;
}

.authorize-user {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 28px 0 8px;
  padding: 18px 0;
  border-block: 1px solid var(--line);
}

.authorize-user > span:last-child {
  display: grid;
  min-width: 0;
  line-height: 1.3;
}

.authorize-user small {
  color: var(--faint);
  font-size: 11px;
}

.authorize-user strong {
  font-size: 14px;
}

.authorize-user span span {
  overflow: hidden;
  color: var(--muted);
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.permission-group {
  margin-top: 28px;
}

.permission-group h2 {
  margin-bottom: 6px;
  color: var(--faint);
  font: 500 10px var(--mono);
  letter-spacing: .14em;
  text-transform: uppercase;
}

.permission-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.permission-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 0;
}

.permission-list li + li {
  border-top: 1px solid var(--line);
}

.permission-list li > span:last-child {
  display: grid;
  line-height: 1.4;
}

.permission-list strong {
  font-size: 14px;
  font-weight: 550;
}

.permission-list small {
  margin-top: 2px;
  color: var(--faint);
  font-size: var(--fs-xs);
}

.permission-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 22px;
  height: 22px;
  margin-top: 1px;
  border-radius: 50%;
}

.permission-icon svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.permission-icon.is-allowed { background: rgba(34, 197, 94, .14); color: var(--green); }
.permission-icon.is-denied { background: rgba(248, 113, 113, .12); color: var(--red); }

.authorize-details {
  margin-top: 28px;
  border-block: 1px solid var(--line);
}

.authorize-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  list-style: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 550;
}

.authorize-details summary::-webkit-details-marker {
  display: none;
}

.authorize-details summary::after {
  content: '+';
  color: var(--muted);
  font: 400 18px var(--mono);
  transition: transform .3s var(--ease-out);
}

.authorize-details[open] summary::after {
  transform: rotate(45deg);
}

.authorize-steps {
  display: grid;
  gap: 12px;
  margin: 0;
  padding: 0 0 18px;
  list-style: none;
  animation: fade-up .3s var(--ease-out);
}

.authorize-steps li {
  display: flex;
  gap: 12px;
}

.authorize-steps li > span {
  display: grid;
  place-items: center;
  flex: none;
  width: 22px;
  height: 22px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  color: var(--muted);
  font: 500 11px var(--mono);
}

.authorize-steps p {
  color: var(--muted);
  font-size: var(--fs-sm);
}

.authorize-steps strong {
  color: var(--text);
}

.authorize-actions {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 10px;
  margin-top: 24px;
}

.authorize-submit {
  min-height: 50px;
}

.authorize-submit .google-auth-icon {
  padding: 2px;
  border-radius: 50%;
  background: #fff;
}

.authorize-foot {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--faint);
  font-size: var(--fs-xs);
}

.authorize-foot span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.authorize-foot .icon {
  width: 14px;
  height: 14px;
}

.authorize-legal {
  margin-top: 12px;
  color: var(--faint);
  font-size: 11px;
  text-align: center;
}

.authorize-legal a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.connected-list h2 {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 16px;
  letter-spacing: -.02em;
}

.connected-list h2 span {
  padding: 1px 8px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--muted);
  font: 500 11px var(--mono);
}

.connected-grid {
  display: grid;
  border-top: 1px solid var(--line);
}

.connected-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  transition: padding .3s var(--ease-out);
}

.connected-item:hover {
  padding-left: 6px;
}

.connected-text {
  display: grid;
  flex: 1;
  min-width: 0;
  line-height: 1.3;
}

.connected-text strong {
  font-size: 14px;
}

.connected-text small,
.connected-date {
  overflow: hidden;
  color: var(--faint);
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.settings-main,
.account-main {
  padding-block: clamp(32px, 5vw, 56px) 24px;
}

.settings-hero,
.account-hero {
  display: flex;
  align-items: center;
  gap: 22px;
  padding-bottom: 32px;
  border-bottom: 1px solid var(--line);
}

.settings-hero h1,
.account-hero h1 {
  margin-top: 6px;
  font-size: clamp(32px, 4.4vw, 56px);
  letter-spacing: -.06em;
}

.settings-hero p,
.account-hero p {
  margin-top: 4px;
  color: var(--muted);
}

.settings-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: clamp(32px, 6vw, 80px);
  padding-top: 36px;
}

.settings-tabs {
  position: sticky;
  top: calc(var(--nav-h) + 24px);
  align-self: start;
  display: grid;
  gap: 2px;
}

.settings-tab {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 44px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  color: var(--muted);
  font-size: 14px;
  font-weight: 550;
  text-align: left;
  transition: background .2s, color .2s;
}

.settings-tab:hover {
  background: var(--surface-2);
  color: var(--text);
}

.settings-tab.is-active {
  background: var(--surface-3);
  color: var(--text);
}

.settings-panel h2 {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  font-size: 26px;
  letter-spacing: -.04em;
}

.settings-empty {
  display: grid;
  justify-items: start;
  gap: 10px;
  padding: 40px 0;
}

.settings-empty strong {
  margin-top: 6px;
  font-size: 18px;
}

.settings-empty p {
  max-width: 420px;
  color: var(--muted);
}

.workspace-shell {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr);
  min-height: 100svh;
}

.sidebar {
  position: sticky;
  top: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  gap: 18px;
  height: 100svh;
  padding: 18px 14px;
  border-right: 1px solid var(--line);
  background: var(--surface);
  overflow-y: auto;
}

.sidebar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 8px 0;
}

.sidebar-close {
  display: none;
}

.sidebar-upload {
  width: 100%;
}

.sidebar-nav {
  display: grid;
  gap: 2px;
}

.sidebar-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  height: 42px;
  padding: 0 12px;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 14px;
  font-weight: 550;
  transition: background .2s, color .2s;
}

.sidebar-link::before {
  content: '';
  position: absolute;
  left: -14px;
  top: 11px;
  bottom: 11px;
  width: 2px;
  border-radius: 2px;
  background: var(--text);
  transform: scaleY(0);
  transition: transform .3s var(--ease-out);
}

.sidebar-link:hover {
  background: var(--surface-2);
  color: var(--text);
}

.sidebar-link.is-active {
  background: var(--surface-3);
  color: var(--text);
}

.sidebar-link.is-active::before {
  transform: scaleY(1);
}

.sidebar-count {
  margin-left: auto;
  min-width: 22px;
  padding: 1px 7px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  color: var(--muted);
  font: 500 11px var(--mono);
  text-align: center;
}

.sidebar-connect {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 42px;
  padding: 0 12px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-sm);
  color: var(--text-2);
  font-size: var(--fs-sm);
  font-weight: 550;
  transition: border-color .2s, background .2s, color .2s;
}

.sidebar-connect:hover {
  border-color: #666;
  background: var(--surface-2);
  color: var(--text);
}

.sidebar-foot {
  display: grid;
  gap: 4px;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-sm);
  color: var(--muted);
  transition: background .2s, color .2s;
}

.sidebar-user:hover {
  background: var(--surface-2);
  color: var(--text);
}

.sidebar-user .icon {
  width: 16px;
  height: 16px;
  transition: transform .5s var(--ease-out);
}

.sidebar-user:hover .icon {
  transform: rotate(60deg);
}

.sidebar-user-text {
  display: grid;
  flex: 1;
  min-width: 0;
  line-height: 1.3;
}

.sidebar-user-text strong,
.sidebar-user-text small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.sidebar-user-text strong {
  color: var(--text);
  font-size: var(--fs-sm);
}

.sidebar-user-text small {
  font-size: 11px;
}

.sidebar-logout button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  height: 38px;
  padding: 0 12px;
  border: 0;
  border-radius: var(--radius-sm);
  background: none;
  color: var(--faint);
  font-size: var(--fs-sm);
  transition: background .2s, color .2s;
}

.sidebar-logout button:hover {
  background: var(--surface-2);
  color: var(--text);
}

.sidebar-backdrop {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: rgba(0, 0, 0, .6);
  backdrop-filter: blur(2px);
  animation: fade-in .2s var(--ease);
}

.workspace-main {
  min-width: 0;
  padding: 0 clamp(18px, 3.4vw, 52px) 96px;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 420px) minmax(0, 1fr);
  align-items: center;
  gap: 18px;
  height: var(--nav-h);
  margin: 0 calc(clamp(18px, 3.4vw, 52px) * -1);
  padding: 0 clamp(18px, 3.4vw, 52px);
  border-bottom: 1px solid var(--line);
  background: rgba(0, 0, 0, .8);
  backdrop-filter: saturate(160%) blur(16px);
  -webkit-backdrop-filter: saturate(160%) blur(16px);
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.sidebar-toggle {
  display: none;
}

.topbar-title {
  display: grid;
  min-width: 0;
  line-height: 1.15;
}

.topbar-crumb {
  color: var(--faint);
  font-size: var(--fs-xs);
}

.topbar-title h1 {
  overflow: hidden;
  font-size: 18px;
  letter-spacing: -.03em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.topbar-search {
  position: relative;
  display: flex;
  align-items: center;
}

.topbar-search .icon {
  position: absolute;
  left: 12px;
  width: 16px;
  height: 16px;
  color: var(--faint);
  pointer-events: none;
}

.topbar-search input {
  width: 100%;
  height: 40px;
  padding: 0 40px 0 38px;
  border: 1px solid var(--line);
  border-radius: 999px;
  outline: none;
  background: var(--surface);
  font-size: 14px;
  transition: border-color .2s, background .2s, box-shadow .2s;
}

.topbar-search input::placeholder {
  color: var(--faint);
}

.topbar-search input:focus {
  border-color: #6a6a6a;
  background: var(--bg);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .06);
}

.topbar-search kbd {
  position: absolute;
  right: 10px;
  padding: 1px 7px;
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  color: var(--faint);
  font-size: 11px;
  pointer-events: none;
}

.topbar-search input:focus + kbd {
  opacity: 0;
}

.topbar-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.topbar-upload {
  min-height: 38px;
  padding: 0 14px;
}

.topbar-avatar {
  border-radius: 50%;
  transition: transform .25s var(--ease-out), box-shadow .25s;
}

.topbar-avatar:hover {
  transform: scale(1.06);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, .12);
}

.view {
  padding-top: 36px;
}

.view-enter {
  animation: fade-up .45s var(--ease-out);
}

.view-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}

.view-head h2 {
  margin-top: 8px;
  font-size: clamp(30px, 3.4vw, 44px);
  letter-spacing: -.055em;
}

.view-meta {
  color: var(--faint);
  font: 500 12px var(--mono);
}

.view-note {
  margin-top: 18px;
  color: var(--faint);
  font-size: var(--fs-sm);
  line-height: 1.6;
}

.view-note.is-saved {
  color: #86efac;
}

.view-lead {
  max-width: 640px;
  margin-bottom: 24px;
  color: var(--muted);
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--line);
}

.section-head h3 {
  font-size: 17px;
  letter-spacing: -.03em;
}

.welcome {
  max-width: 820px;
  padding-top: 12px;
}

.welcome h2 {
  margin-top: 16px;
  font-size: clamp(38px, 5vw, 64px);
  letter-spacing: -.065em;
  line-height: 1.02;
}

.welcome > p {
  max-width: 600px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 17px;
}

.welcome-steps {
  display: grid;
  margin: 40px 0 0;
  padding: 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.welcome-steps li {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  animation: fade-up .5s var(--ease-out) both;
}

.welcome-steps li:nth-child(2) { animation-delay: 80ms; }
.welcome-steps li:nth-child(3) { animation-delay: 160ms; }

.welcome-steps li > span {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  font: 500 12px var(--mono);
}

.welcome-steps li > div {
  display: grid;
  flex: 1;
  gap: 2px;
}

.welcome-steps strong {
  color: var(--text-2);
  font-size: 16px;
}

.welcome-steps small {
  font-size: var(--fs-sm);
}

.welcome-steps .is-current > span {
  border-color: var(--text);
  background: var(--text);
  color: var(--accent-ink);
}

.welcome-steps .is-current strong {
  color: var(--text);
}

.capacity {
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
}

.capacity-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 22px;
}

.capacity-head > div {
  display: grid;
}

.capacity-free {
  margin-top: 10px;
  font-size: clamp(44px, 6vw, 80px);
  font-weight: 650;
  letter-spacing: -.07em;
  line-height: 1;
}

.capacity-sub {
  margin-top: 10px;
  color: var(--muted);
}

.capacity-bar span {
  width: 0;
  transition: width 1.2s var(--ease-out);
}

.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
}

.stat {
  padding: 20px;
}

.stat:first-child {
  padding-left: 0;
}

.stat + .stat {
  border-left: 1px solid var(--line);
}

.stat span {
  color: var(--faint);
  font: 500 10px var(--mono);
  letter-spacing: .12em;
  text-transform: uppercase;
}

.stat strong {
  display: block;
  margin-top: 8px;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -.04em;
}

.overview-grid > section {
  min-width: 0;
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 40px;
  margin-top: 40px;
}

.recent-list,
.tip-list,
.key-list {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  margin: 0;
  padding: 0;
  list-style: none;
}

.recent-item,
.key-item {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 62px;
  border-bottom: 1px solid var(--line);
  animation: fade-up .4s var(--ease-out) both;
  animation-delay: calc(var(--row, 0) * 40ms);
}

.recent-body,
.key-body {
  display: grid;
  flex: 1;
  min-width: 0;
  line-height: 1.35;
}

.recent-body strong,
.key-body strong {
  overflow: hidden;
  font-size: 14px;
  font-weight: 550;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-body small,
.key-body small {
  overflow: hidden;
  color: var(--faint);
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.recent-state {
  flex: none;
  color: var(--faint);
  font: 500 11px var(--mono);
}

.state-failed { color: var(--red); }
.state-pending { color: var(--amber); }

.recent-empty {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
  min-height: 62px;
  color: var(--faint);
  font-size: 14px;
}

.recent-empty .icon {
  color: var(--green);
}

.tip-item a {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  border-bottom: 1px solid var(--line);
  color: var(--text-2);
  font-size: 14px;
  transition: padding .3s var(--ease-out), color .2s;
  animation: fade-up .4s var(--ease-out) both;
  animation-delay: calc(var(--row, 0) * 40ms);
}

.tip-item a:hover {
  padding-left: 6px;
  color: var(--text);
}

.tip-item .icon {
  width: 16px;
  height: 16px;
  margin-left: auto;
  color: var(--faint);
}

.tip-text {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tip-dot {
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 50%;
}

.tip-dot.level-high { background: var(--red); box-shadow: 0 0 0 4px rgba(248, 113, 113, .14); }
.tip-dot.level-medium { background: var(--amber); }
.tip-dot.level-low { background: var(--blue); }

.type-section {
  margin-top: 40px;
}

.type-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.type-card {
  display: grid;
  gap: 10px;
  padding: 18px 20px 18px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  text-align: left;
  animation: fade-up .45s var(--ease-out) both;
  animation-delay: calc(var(--row, 0) * 40ms);
  transition: background .2s;
}

button.type-card:hover {
  background: rgba(255, 255, 255, .02);
}

.type-card:not(:nth-child(4n + 1)) {
  padding-left: 20px;
  border-left: 1px solid var(--line);
}

.type-card.is-skeleton {
  min-height: 96px;
  animation: none;
}

.type-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.type-card-head > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-2);
  font-size: var(--fs-sm);
}

.type-card-head strong {
  font-size: 18px;
  letter-spacing: -.03em;
}

.type-card small {
  color: var(--faint);
  font-size: var(--fs-xs);
}

.type-track {
  height: 4px;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
}

.type-track span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  transition: width 1s var(--ease-out);
}

.toolbar {
  display: flex;
  gap: 10px;
  margin-bottom: 14px;
}

.table-card {
  border-top: 1px solid var(--line);
}

.files-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}

.files-table th {
  height: 42px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  color: var(--faint);
  font: 500 10px var(--mono);
  letter-spacing: .12em;
  text-align: left;
  text-transform: uppercase;
}

.files-table td {
  height: 62px;
  padding: 0 14px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: var(--fs-sm);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.files-table th:first-child,
.files-table td:first-child {
  padding-left: 0;
}

.files-table th:last-child,
.files-table td:last-child {
  padding-right: 0;
}

.files-table .col-account { width: 26%; }
.files-table .col-date { width: 14%; }
.files-table .col-size { width: 10%; text-align: right; }
.files-table .col-actions { width: 52px; text-align: right; }

.row-file {
  animation: fade-up .4s var(--ease-out) both;
  animation-delay: calc(var(--row, 0) * 26ms);
  transition: background .15s, opacity .25s, transform .25s;
}

.row-file:hover {
  background: rgba(255, 255, 255, .025);
}

.row-file.is-leaving {
  opacity: 0;
  transform: translateX(16px);
}

.row-delete {
  opacity: 0;
}

.row-file:hover .row-delete,
.row-delete:focus-visible {
  opacity: 1;
}

.row-delete:hover {
  border-color: rgba(248, 113, 113, .35);
  background: rgba(248, 113, 113, .08);
  color: #fca5a5;
}

.row-message td {
  height: 120px;
  color: var(--faint);
  text-align: center;
  white-space: normal;
}

.row-skeleton td {
  height: 62px;
}

.file-name {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  text-align: left;
}

.file-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--surface-2);
  transition: transform .3s var(--ease-out), border-color .2s;
}

.file-icon .icon {
  width: 16px;
  height: 16px;
}

.row-file:hover .file-icon {
  border-color: var(--line-strong);
  transform: scale(1.06);
}

.file-text {
  display: grid;
  min-width: 0;
  line-height: 1.35;
}

.file-title {
  overflow: hidden;
  color: var(--text);
  font-size: 14px;
  font-weight: 550;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-text small {
  display: none;
  overflow: hidden;
  color: var(--faint);
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.load-more {
  display: flex;
  width: 100%;
  margin-top: 14px;
}

.account-list {
  border-top: 1px solid var(--line);
}

.account-row {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(0, 1.1fr) auto;
  align-items: center;
  gap: 16px 40px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  animation: fade-up .45s var(--ease-out) both;
  transition: background .3s;
}

.account-row:nth-child(2) { animation-delay: 60ms; }
.account-row:nth-child(3) { animation-delay: 120ms; }
.account-row:nth-child(4) { animation-delay: 180ms; }

.account-row {
  position: relative;
}

.account-row:has(.menu.is-open) {
  z-index: 20;
}

.account-row.is-moving {
  animation: settle .5s var(--ease-out);
}

.account-id {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  min-width: 0;
}

.account-id > div {
  display: grid;
  gap: 4px;
  min-width: 0;
}

.account-id h3 {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 16px;
  letter-spacing: -.02em;
}

.account-id p {
  overflow: hidden;
  color: var(--faint);
  font-size: var(--fs-sm);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-id .badge-row {
  margin-top: 6px;
}

.pin-mark {
  width: 14px;
  height: 14px;
  color: var(--amber);
}

.account-usage {
  display: grid;
  gap: 10px;
}

.account-usage-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.account-usage-line strong {
  font-size: 24px;
  font-weight: 600;
  letter-spacing: -.05em;
}

.account-usage-line span,
.account-usage small {
  color: var(--faint);
  font-size: var(--fs-xs);
}

.account-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.account-settings-button {
  min-height: 38px;
  padding: 0 14px;
}

.account-add {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  transition: padding .3s var(--ease-out);
}

.account-add > span:last-child {
  display: grid;
}

.account-add small {
  color: var(--faint);
}

.account-add:hover {
  padding-left: 6px;
}

.account-add:hover .empty-state-icon {
  background: var(--accent);
  color: var(--accent-ink);
}

.rec-list {
  border-top: 1px solid var(--line);
}

.rec-item {
  position: relative;
  padding: 22px 0 22px 18px;
  border-bottom: 1px solid var(--line);
  animation: fade-up .45s var(--ease-out) both;
  animation-delay: calc(var(--row, 0) * 45ms);
}

.rec-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 26px;
  bottom: 26px;
  width: 3px;
  border-radius: 3px;
  background: var(--blue);
}

.rec-item.level-high::before { background: var(--red); }
.rec-item.level-medium::before { background: var(--amber); }
.rec-item.is-skeleton { display: grid; gap: 10px; animation: none; }
.rec-item.is-skeleton::before { display: none; }

.rec-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
}

.rec-meta {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

.rec-level,
.rec-category {
  font: 500 10px var(--mono);
  letter-spacing: .12em;
  text-transform: uppercase;
}

.rec-level { color: var(--blue); }
.rec-level.level-high { color: var(--red); }
.rec-level.level-medium { color: var(--amber); }
.rec-category { color: var(--faint); }

.rec-text h3 {
  font-size: 17px;
  letter-spacing: -.025em;
}

.rec-text p {
  max-width: 640px;
  margin-top: 6px;
  color: var(--muted);
  font-size: 14px;
}

.rec-action {
  flex: none;
}

.rec-files {
  margin-top: 14px;
}

.rec-files summary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-2);
  font-size: var(--fs-sm);
  font-weight: 550;
  cursor: pointer;
  list-style: none;
}

.rec-files summary::-webkit-details-marker {
  display: none;
}

.rec-files summary::after {
  content: '›';
  transition: transform .25s var(--ease-out);
}

.rec-files[open] summary::after {
  transform: rotate(90deg);
}

.rec-files ul {
  display: grid;
  max-height: 420px;
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: 10px 0 0;
  padding: 0;
  list-style: none;
  animation: fade-up .3s var(--ease-out);
}

.rec-file {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 42px;
  border-top: 1px solid var(--line);
}

.rec-file input {
  width: 16px;
  height: 16px;
  flex: none;
  accent-color: #fafafa;
}

.rec-file-name {
  min-width: 0;
  overflow: hidden;
  padding: 0;
  border: 0;
  background: none;
  color: var(--text-2);
  font-size: var(--fs-sm);
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rec-file-name:hover {
  color: var(--text);
  text-decoration: underline;
}

.rec-file small {
  margin-left: auto;
  overflow: hidden;
  color: var(--faint);
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rec-empty {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 64px 0;
  color: var(--muted);
  text-align: center;
}

.rec-empty .icon {
  width: 28px;
  height: 28px;
  color: var(--green);
}

.rec-empty strong {
  color: var(--text);
  font-size: 18px;
}

.key-form {
  display: flex;
  gap: 10px;
  max-width: 640px;
}

.key-form .search-field input {
  padding-left: 40px;
}

.key-reveal {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px 16px;
  max-width: 760px;
  margin-top: 18px;
  padding: 18px 0;
  border-block: 1px solid rgba(34, 197, 94, .35);
}

.key-reveal > div {
  display: grid;
  grid-column: 1 / -1;
}

.key-reveal small {
  color: var(--muted);
}

.key-reveal code {
  overflow: hidden;
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: #86efac;
  font-size: var(--fs-sm);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.key-list {
  max-width: 760px;
  margin-top: 24px;
  border-top: 1px solid var(--line);
}

.key-item > .icon {
  color: var(--muted);
}

.key-item .button {
  min-height: 36px;
  padding: 0 12px;
  font-size: var(--fs-sm);
}

.docs {
  max-width: 820px;
  margin-top: 48px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}

.docs h3 {
  font-size: 20px;
  letter-spacing: -.03em;
}

.docs p {
  margin-top: 18px;
  color: var(--muted);
  font-size: 14px;
}

.docs p code,
.endpoint-table code {
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--surface-3);
  color: var(--text-2);
  font-size: var(--fs-xs);
}

.docs pre {
  margin: 10px 0 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--text-2);
  font-size: var(--fs-xs);
  line-height: 1.7;
  overflow-x: auto;
}

.endpoint-table {
  width: 100%;
  margin-top: 28px;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: var(--fs-sm);
}

.endpoint-table th:first-child {
  width: 72px;
}

.endpoint-table td {
  overflow-wrap: anywhere;
}

.endpoint-table th {
  padding: 10px 12px 10px 0;
  border-bottom: 1px solid var(--line);
  color: var(--faint);
  font: 500 10px var(--mono);
  letter-spacing: .12em;
  text-align: left;
  text-transform: uppercase;
}

.endpoint-table td {
  padding: 12px 12px 12px 0;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  vertical-align: top;
}

.method {
  font: 600 11px var(--mono);
  color: var(--green);
}

.drawer {
  position: fixed;
  inset: 0;
  z-index: 120;
  background: rgba(0, 0, 0, 0);
  transition: background .28s var(--ease);
}

.drawer.is-open {
  background: rgba(0, 0, 0, .6);
}

.drawer-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  display: flex;
  flex-direction: column;
  width: min(520px, 100%);
  border-left: 1px solid var(--line-strong);
  background: var(--surface);
  box-shadow: -30px 0 80px rgba(0, 0, 0, .6);
  transform: translateX(100%);
  transition: transform .32s var(--ease-out);
}

.drawer.is-open .drawer-panel {
  transform: none;
}

.drawer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 24px 18px;
}

.drawer-head h2 {
  margin-top: 8px;
  font-size: 24px;
  letter-spacing: -.04em;
}

.drawer-head p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.drawer .tabs {
  margin: 0;
  padding: 0 14px;
}

.drawer-body {
  flex: 1;
  padding: 8px 24px 32px;
  overflow-y: auto;
}

.drawer-body > section {
  display: grid;
  gap: 18px;
  padding-top: 16px;
}

.info-list {
  display: grid;
  margin: 0;
}

.info-list div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.info-list dt {
  color: var(--faint);
  font-size: var(--fs-sm);
}

.info-list dd {
  margin: 0;
  color: var(--text-2);
  font-size: var(--fs-sm);
  text-align: right;
  overflow-wrap: anywhere;
}

.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}

.toggle-row > span,
.setting-block {
  display: grid;
  gap: 3px;
}

.toggle-row strong,
.setting-block > strong {
  font-size: 15px;
  font-weight: 600;
}

.toggle-row small,
.setting-block > small {
  color: var(--faint);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.setting-block {
  gap: 10px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}

.setting-block .chip-row {
  margin: 4px 0 0;
}

.danger-zone {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-top: 12px;
  padding: 18px 0;
  border-block: 1px solid rgba(248, 113, 113, .3);
}

.danger-zone > div {
  display: grid;
  gap: 4px;
}

.danger-zone small {
  color: var(--muted);
  font-size: var(--fs-sm);
}

.upload-dock {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 150;
  width: min(380px, calc(100vw - 40px));
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: rgba(14, 14, 14, .97);
  box-shadow: 0 30px 80px rgba(0, 0, 0, .7);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  overflow: hidden;
  animation: toast-in .35s var(--ease-out);
}

.upload-dock.is-leaving {
  animation: toast-out .22s var(--ease) forwards;
}

.upload-dock header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 10px 10px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.upload-dock ul {
  max-height: 300px;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
}

.upload-dock.is-collapsed ul {
  display: none;
}

.dock-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  animation: fade-up .3s var(--ease-out);
}

.dock-item:last-child {
  border-bottom: 0;
}

.dock-body {
  display: grid;
  flex: 1;
  min-width: 0;
  gap: 2px;
}

.dock-body strong {
  overflow: hidden;
  font-size: var(--fs-sm);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dock-body small {
  overflow: hidden;
  color: var(--faint);
  font-size: var(--fs-xs);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dock-bar {
  display: block;
  height: 3px;
  margin-top: 6px;
  border-radius: 999px;
  background: var(--surface-3);
  overflow: hidden;
}

.dock-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: var(--text);
  transition: width .3s var(--ease);
}

.dock-item[data-state='done'] .dock-bar span { background: var(--green); }
.dock-item[data-state='error'] .dock-bar span { width: 100% !important; background: var(--red); }
.dock-item[data-state='error'] small { color: #fca5a5; }

.drop-overlay {
  position: fixed;
  inset: 0;
  z-index: 250;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, .78);
  backdrop-filter: blur(6px);
  pointer-events: none;
  animation: fade-in .2s var(--ease);
}

.drop-overlay > div {
  display: grid;
  justify-items: center;
  gap: 10px;
  width: min(560px, 100%);
  padding: 56px 24px;
  border: 2px dashed #555;
  border-radius: 20px;
  text-align: center;
  animation: pop-in .3s var(--ease-out);
}

.drop-overlay .icon {
  width: 34px;
  height: 34px;
  animation: float 2s var(--ease) infinite;
}

.drop-overlay strong {
  font-size: 22px;
  letter-spacing: -.03em;
}

.drop-overlay span {
  color: var(--muted);
}

.entry {
  animation: fade-up .8s var(--ease-out) both;
}

.entry-late {
  animation: fade-up .8s .15s var(--ease-out) both;
}

.reveal-ready {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--ease-out), transform .7s var(--ease-out);
  transition-delay: var(--delay, 0ms);
}

.reveal-ready.is-visible {
  opacity: 1;
  transform: none;
}

@keyframes fade-up { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes pop-in { from { opacity: 0; transform: translateY(10px) scale(.98); } }
@keyframes pop-in-up { from { opacity: 0; transform: translateY(-10px) scale(.98); } }
@keyframes pop-out { to { opacity: 0; transform: translateY(6px) scale(.985); } }
@keyframes toast-in { from { opacity: 0; transform: translateY(16px) scale(.96); } }
@keyframes toast-out { to { opacity: 0; transform: translateX(24px) scale(.96); } }
@keyframes toast-in-top { from { opacity: 0; transform: translateY(-16px) scale(.96); } }
@keyframes toast-out-top { to { opacity: 0; transform: translateY(-16px) scale(.96); } }
@keyframes toast-progress { to { transform: scaleX(0); } }
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse { 50% { box-shadow: 0 0 0 7px rgba(34, 197, 94, 0); } }
@keyframes pulse-soft { 50% { opacity: .3; } }
@keyframes float { 50% { transform: translateY(-5px); } }
@keyframes shake { 20%, 60% { transform: translateX(-4px); } 40%, 80% { transform: translateX(4px); } }
@keyframes link-dot { 0%, 100% { opacity: .25; transform: scale(.8); } 50% { opacity: 1; transform: scale(1); } }
@keyframes grow { from { transform: scaleX(0); } }
@keyframes settle { 0% { transform: translateY(-8px); background: rgba(255, 255, 255, .04); } 100% { transform: none; background: transparent; } }
@keyframes upload-loop { 0% { width: 0; } 70% { width: 100%; } 100% { width: 100%; opacity: 0; } }
@keyframes sheet-up { from { transform: translateY(100%); } }

@media (max-width: 1280px) {
  .topbar {
    grid-template-columns: minmax(0, 1fr) minmax(0, 320px) auto;
  }
}

@media (max-width: 1100px) {
  .stat-grid,
  .type-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .stat:nth-child(3) {
    padding-left: 0;
    border-left: 0;
  }

  .stat:nth-child(n + 3) {
    border-top: 1px solid var(--line);
  }

  .type-card:not(:nth-child(4n + 1)) {
    padding-left: 0;
    border-left: 0;
  }

  .type-card:nth-child(2n) {
    padding-left: 20px;
    border-left: 1px solid var(--line);
  }

  .files-table .col-account {
    display: none;
  }

  .file-text small {
    display: block;
  }

  .account-row {
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas: 'id actions' 'usage usage';
  }

  .account-id { grid-area: id; }
  .account-usage { grid-area: usage; }
  .account-actions { grid-area: actions; }

  .feature-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .feature:not(:nth-child(3n + 1)) {
    padding-left: 0;
    border-left: 0;
  }

  .feature:nth-child(2n) {
    padding-left: 28px;
    border-left: 1px solid var(--line);
  }
}

@media (max-width: 1024px) {
  .workspace-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(300px, 86vw);
    transform: translateX(-102%);
    transition: transform .35s var(--ease-out);
    box-shadow: 30px 0 80px rgba(0, 0, 0, .6);
  }

  .sidebar.is-open {
    transform: none;
  }

  .sidebar-close,
  .sidebar-toggle {
    display: inline-grid;
  }

  .sidebar-link::before {
    display: none;
  }

  .topbar {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .topbar-search {
    display: none;
  }

  .hero,
  .auth-layout,
  .faq {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: 0;
  }

  .hero-visual {
    padding: 28px 0 0;
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  .auth-aside-footer {
    display: none;
  }

  .story-grid {
    grid-template-columns: 1fr;
  }

  .story-panel h3 {
    margin-top: 28px;
  }

  .legal-layout,
  .settings-layout {
    grid-template-columns: 1fr;
  }

  .legal-index {
    position: static;
    display: flex;
    flex-wrap: wrap;
    gap: 8px 18px;
  }

  .legal-index span {
    width: 100%;
    margin: 0;
  }

  .settings-tabs {
    position: static;
    display: flex;
    overflow-x: auto;
    border-bottom: 1px solid var(--line);
  }

  .overview-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 760px) {
  :root {
    --nav-h: 62px;
    --fs-xs: 13px;
    --fs-sm: 14px;
    --fs-base: 16px;
    --fs-md: 16px;
  }

  .app-body {
    line-height: 1.65;
  }

  .auth-layout {
    padding-top: 28px;
  }

  .auth-aside {
    display: none;
  }

  .hero h1 {
    font-size: clamp(48px, 14vw, 66px);
  }

  .hero-description,
  .welcome > p,
  .legal-intro p,
  .story-heading > p:last-child {
    font-size: 17px;
  }

  .feature-grid {
    grid-template-columns: 1fr;
  }

  .feature,
  .feature:nth-child(2n) {
    padding: 26px 0;
    border-left: 0;
  }

  .cta {
    flex-direction: column;
    align-items: flex-start;
  }

  .faq-item summary {
    font-size: 16px;
  }

  .faq-item p {
    padding-right: 0;
  }

  .topbar-upload span {
    display: none;
  }

  .topbar-upload {
    width: 40px;
    padding: 0;
  }

  .toolbar,
  .key-form {
    flex-direction: column;
  }

  .select {
    min-width: 0;
  }

  .files-table .col-date {
    display: none;
  }

  .files-table .col-size {
    width: 84px;
  }

  .files-table .col-actions {
    width: 44px;
  }

  .row-delete {
    opacity: 1;
  }

  .stat,
  .stat:nth-child(odd) {
    padding: 16px 12px 16px 0;
  }

  .stat:nth-child(2n) {
    padding-left: 14px;
  }

  .type-grid {
    grid-template-columns: 1fr 1fr;
  }

  .type-card,
  .type-card:nth-child(2n) {
    padding: 14px 12px 14px 0;
  }

  .type-card:nth-child(2n) {
    padding-left: 12px;
  }

  .account-row {
    grid-template-columns: 1fr;
    grid-template-areas: 'id' 'usage' 'actions';
  }

  .account-actions {
    justify-content: space-between;
  }

  .account-settings-button {
    flex: 1;
  }

  .rec-head {
    flex-direction: column;
    gap: 14px;
  }

  .rec-action {
    width: 100%;
  }

  .rec-file small {
    display: none;
  }

  .key-reveal {
    grid-template-columns: 1fr;
  }

  .danger-zone {
    flex-direction: column;
    align-items: flex-start;
  }

  .connected-date {
    display: none;
  }

  .authorize-actions {
    grid-template-columns: 1fr;
  }

  .authorize-actions .button-secondary {
    order: 2;
  }

  .settings-hero,
  .account-hero {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .confirm {
    padding: 22px;
  }

  .confirm-actions {
    flex-direction: column-reverse;
  }

  .confirm-actions .button {
    width: 100%;
  }

  .preview-foot {
    flex-direction: column;
    align-items: stretch;
  }

  .preview-actions .button {
    flex: 1;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .nav-link-ghost span {
    display: none;
  }

  .toast-region,
  .upload-dock {
    right: 12px;
    left: 12px;
    width: auto;
  }

  .toast-region {
    top: 12px;
    bottom: auto;
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .toast {
    animation-name: toast-in-top;
  }

  .toast.is-leaving {
    animation-name: toast-out-top;
  }

  .upload-dock {
    bottom: 12px;
  }

  .select-panel {
    position: fixed;
    top: auto;
    right: 0;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 8px 12px calc(16px + env(safe-area-inset-bottom));
    border-width: 1px 0 0;
    border-radius: 18px 18px 0 0;
    animation: sheet-up .3s var(--ease-out);
  }

  .select-panel.is-up {
    bottom: 0;
    animation-name: sheet-up;
  }

  .select-sheet-head {
    display: block;
    position: relative;
    padding: 18px 4px 12px;
    color: var(--faint);
    font: 500 10px var(--mono);
    letter-spacing: .14em;
    text-transform: uppercase;
  }

  .select-sheet-head::before {
    content: '';
    position: absolute;
    top: 6px;
    left: 50%;
    width: 36px;
    height: 4px;
    border-radius: 999px;
    background: #3a3a3a;
    transform: translateX(-50%);
  }

  .select-list {
    max-height: 55svh;
  }

  .select-option {
    min-height: 50px;
    font-size: 16px;
  }

  .menu-panel [role='menuitem'] {
    height: 46px;
    font-size: 15px;
  }

  .chip {
    height: 40px;
  }

  .sidebar-link,
  .sidebar-connect {
    height: 48px;
    font-size: 15px;
  }

  .drawer-panel {
    width: 100%;
    border-left: 0;
  }
}

.nimbus {
  position: fixed;
  left: 20px;
  bottom: 18px;
  z-index: 140;
  display: grid;
  justify-items: start;
  pointer-events: none;
}

.workspace-body .nimbus {
  left: calc(var(--sidebar-w) + 20px);
}

.nimbus > * {
  pointer-events: auto;
}

.nimbus.is-leaving {
  animation: pop-out .26s var(--ease) forwards;
}

.nimbus-button {
  position: relative;
  width: 78px;
  height: 68px;
  padding: 0;
  border: 0;
  background: none;
  filter: drop-shadow(0 14px 22px rgba(0, 0, 0, .55));
  animation: nimbus-float 4.2s var(--ease) infinite;
}

.nimbus-button svg {
  width: 100%;
  height: 100%;
  overflow: visible;
  transition: transform .3s var(--ease-out);
}

.nimbus-button:hover svg {
  transform: scale(1.08) rotate(-4deg);
}

.nimbus-button:focus-visible {
  outline: 2px solid var(--text);
  outline-offset: 4px;
  border-radius: 20px;
}

.nimbus-eyes {
  transform-origin: 60px 58px;
  animation: nimbus-blink 5s infinite;
}

.nimbus-shadow {
  transform-origin: 60px 98px;
  animation: nimbus-shadow 4.2s var(--ease) infinite;
}

.nimbus.is-bouncing .nimbus-body {
  transform-origin: 60px 84px;
  animation: nimbus-bounce .8s var(--ease-out);
}

.nimbus.is-cheering .nimbus-body {
  transform-origin: 60px 84px;
  animation: nimbus-cheer .9s var(--ease-out);
}

.nimbus-hide {
  position: absolute;
  left: 60px;
  bottom: 52px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 14px;
  line-height: 1;
  opacity: 0;
  transform: scale(.8);
  transition: opacity .2s, transform .2s;
}

.nimbus:hover .nimbus-hide,
.nimbus-hide:focus-visible {
  opacity: 1;
  transform: none;
}

.nimbus-bubble {
  position: relative;
  max-width: min(280px, calc(100vw - 40px));
  margin: 0 0 12px 8px;
  padding: 12px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 16px 16px 16px 4px;
  background: rgba(250, 250, 250, .97);
  color: #0a0a0a;
  font-size: 14px;
  font-weight: 500;
  line-height: 1.45;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .55);
  transform-origin: bottom left;
  animation: nimbus-bubble .35s var(--ease-out);
}

.nimbus-action {
  display: inline-flex;
  align-items: center;
  margin-top: 10px;
  padding: 7px 12px;
  border-radius: 8px;
  background: #0a0a0a;
  color: #fafafa;
  font-size: 13px;
  font-weight: 600;
  transition: transform .15s var(--ease), background .2s;
}

.nimbus-action:hover {
  background: #262626;
}

.nimbus-action:active {
  transform: scale(.96);
}

.nimbus-text {
  display: block;
}

.nimbus-bubble.is-leaving {
  animation: pop-out .22s var(--ease) forwards;
}

.nimbus-bubble.is-typing .nimbus-text::before {
  content: '';
  display: inline-block;
  width: 26px;
  height: 8px;
  background:
    radial-gradient(circle, #555 3px, transparent 3.5px) 0 50% / 9px 8px repeat-x;
  animation: nimbus-typing 1s steps(3) infinite;
}

.nimbus-piece {
  position: absolute;
  left: 38px;
  bottom: 40px;
  width: 10px;
  height: 10px;
  pointer-events: none;
  animation: nimbus-piece .85s var(--ease-out) forwards;
}

.nimbus-piece.is-dot {
  border-radius: 50%;
  background: hsl(var(--h) 90% 70%);
}

.nimbus-piece.is-spark {
  background: hsl(var(--h) 95% 75%);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
}

.nimbus-piece.is-cloud {
  width: 16px;
  height: 10px;
  border-radius: 10px;
  background: #fafafa;
  box-shadow: 4px -4px 0 -1px #fafafa, -3px -3px 0 -2px #fafafa;
}

.nimbus-restore {
  position: fixed;
  left: 20px;
  bottom: 18px;
  z-index: 140;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--muted);
  transition: color .2s, transform .2s;
}

.workspace-body .nimbus-restore {
  left: calc(var(--sidebar-w) + 20px);
}

.nimbus-restore:hover {
  color: var(--text);
  transform: scale(1.08);
}

.nimbus-restore svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
}

@keyframes nimbus-float { 50% { transform: translateY(-7px); } }
@keyframes nimbus-shadow { 50% { transform: scaleX(.8); opacity: .3; } }
@keyframes nimbus-blink { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes nimbus-bounce {
  0% { transform: none; }
  20% { transform: scale(1.18, .78); }
  45% { transform: translateY(-26px) scale(.9, 1.12) rotate(-10deg); }
  70% { transform: translateY(0) scale(1.08, .92) rotate(6deg); }
  100% { transform: none; }
}
@keyframes nimbus-cheer {
  0%, 100% { transform: none; }
  25% { transform: translateY(-14px) rotate(-8deg); }
  50% { transform: translateY(0) rotate(0); }
  75% { transform: translateY(-8px) rotate(8deg); }
}
@keyframes nimbus-bubble { from { transform: translateY(8px) scale(.9); } }
@keyframes nimbus-typing { to { background-position: 27px 50%; } }
@keyframes nimbus-piece {
  from { opacity: 1; transform: translate(0, 0) rotate(0) scale(.6); }
  to { opacity: 0; transform: translate(var(--x), var(--y)) rotate(var(--r)) scale(1.1); }
}

@media (max-width: 1024px) {
  .workspace-body .nimbus,
  .workspace-body .nimbus-restore {
    left: 14px;
  }
}

@media (max-width: 760px) {
  .nimbus,
  .nimbus-restore {
    left: 12px;
    bottom: 12px;
  }

  .nimbus-button {
    width: 60px;
    height: 52px;
  }

  .nimbus-hide {
    left: 46px;
    bottom: 40px;
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }

  .reveal-ready {
    opacity: 1;
    transform: none;
  }
}

.sheet {
  width: min(560px, calc(100% - 32px));
  max-height: calc(100svh - 48px);
  padding: 0;
  overflow: auto;
  border: 1px solid var(--line-strong);
  border-radius: 18px;
  background: var(--surface);
  color: var(--text);
  box-shadow: 0 40px 120px rgba(0, 0, 0, .7);
}

.sheet::backdrop {
  background: rgba(0, 0, 0, .72);
  backdrop-filter: blur(4px);
}

.sheet[open] {
  animation: pop-in .26s var(--ease-out);
}

.sheet.is-closing {
  animation: pop-out .16s var(--ease) forwards;
}

.sheet-head {
  display: grid;
  gap: 8px;
  padding: 28px 28px 6px;
}

.sheet-head .confirm-icon {
  margin-bottom: 6px;
}

.sheet-head h2 {
  font-size: 22px;
  letter-spacing: -.03em;
  overflow-wrap: anywhere;
}

.sheet-head p,
.sheet-note {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
}

.sheet-head p strong {
  color: var(--text);
  overflow-wrap: anywhere;
}

.sheet-body {
  display: grid;
  gap: 16px;
  padding: 18px 28px 4px;
  animation: fade-up .3s var(--ease-out);
}

.sheet-note {
  padding: 14px 28px 0;
  font-size: var(--fs-sm);
}

.sheet-actions {
  position: sticky;
  bottom: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 18px;
  padding: 18px 28px 24px;
  border-top: 1px solid var(--line);
  background: var(--surface);
}

.mode-options {
  display: grid;
  gap: 10px;
}

.mode-option,
.check-row,
.stab-account {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}

.mode-option:hover,
.check-row:hover,
.stab-account:hover {
  border-color: #4a4a4a;
}

.mode-option:has(input:checked),
.stab-account:has(input:checked) {
  border-color: var(--text-2);
  background: var(--surface-2);
}

.mode-option input,
.check-row input,
.stab-account input {
  flex: none;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: #fafafa;
}

.mode-option span,
.check-row span {
  display: grid;
  gap: 4px;
}

.mode-option small,
.check-row small,
.stab-account small {
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.stab-accounts {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.stab-accounts legend {
  margin-bottom: 8px;
  color: var(--muted);
  font: 500 11px var(--mono);
  letter-spacing: .14em;
  text-transform: uppercase;
}

.stab-account {
  align-items: center;
}

.stab-account > span {
  display: grid;
  flex: 1;
  min-width: 0;
  gap: 2px;
}

.stab-account strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.field {
  display: grid;
  gap: 8px;
  font-size: 14px;
  color: var(--text-2);
}

.field strong {
  overflow-wrap: anywhere;
  color: var(--text);
}

.input {
  width: 100%;
  height: 46px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  outline: none;
  background: var(--bg);
  color: var(--text);
  font-size: var(--fs-md);
  transition: border-color .2s, box-shadow .2s;
}

.input:focus {
  border-color: #8a8a8a;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, .07);
}

.plan-summary {
  display: grid;
  gap: 4px;
  padding: 18px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: var(--surface-2);
}

.plan-summary strong {
  font-size: 22px;
  letter-spacing: -.03em;
}

.plan-summary small {
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.plan-accounts {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.plan-account {
  display: grid;
  gap: 8px;
}

.plan-account-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 14px;
}

.plan-account-head span:first-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.plan-account-head span:last-child {
  flex: none;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12px;
}

.level-bar {
  position: relative;
  height: 10px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--surface-3);
}

.level-bar span {
  position: absolute;
  inset: 0 auto 0 0;
  border-radius: inherit;
  transition: width .8s var(--ease-out);
}

.level-bar .is-before {
  background: rgba(255, 255, 255, .22);
}

.level-bar .is-after {
  background: linear-gradient(90deg, #60a5fa, #a78bfa);
}

.stabilize-callout,
.job-panel {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 18px;
  padding: 18px 20px;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  background: linear-gradient(120deg, rgba(96, 165, 250, .08), rgba(167, 139, 250, .06) 60%, transparent);
  animation: fade-up .4s var(--ease-out);
}

.stabilize-callout > div,
.job-main {
  display: grid;
  flex: 1;
  min-width: 0;
  gap: 4px;
}

.stabilize-callout small,
.job-main small {
  color: var(--muted);
  font-size: var(--fs-sm);
  line-height: 1.5;
}

.stabilize-icon {
  display: grid;
  flex: none;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: rgba(96, 165, 250, .14);
  color: var(--blue);
}

.job-host.is-running .stabilize-icon svg {
  animation: sway 1.6s var(--ease) infinite;
}

.job-host.is-done .stabilize-icon {
  background: rgba(34, 197, 94, .14);
  color: var(--green);
}

.job-host.is-failed .stabilize-icon {
  background: rgba(248, 113, 113, .14);
  color: var(--red);
}

.job-progress {
  height: 8px;
  margin-top: 6px;
  overflow: hidden;
  border-radius: 99px;
  background: var(--surface-3);
}

.job-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #60a5fa, #fafafa);
  transition: width .6s var(--ease-out);
}

@keyframes sway {
  0%, 100% { transform: rotate(-8deg); }
  50% { transform: rotate(8deg); }
}

@media (max-width: 640px) {
  .stabilize-callout,
  .job-panel {
    flex-wrap: wrap;
  }

  .stabilize-callout .button,
  .job-panel .button {
    width: 100%;
  }

  .sheet-head,
  .sheet-body,
  .sheet-note,
  .sheet-actions {
    padding-inline: 20px;
  }

  .sheet-actions .button {
    flex: 1 1 auto;
  }
}

.stabilize-icon .icon {
  width: 22px;
  height: 22px;
}

[data-stab-plan] {
  display: grid;
  gap: 20px;
}

.job-host {
  position: relative;
  overflow: hidden;
  transition: border-color .4s var(--ease), box-shadow .4s var(--ease);
}

.job-host > * {
  transition: opacity .2s var(--ease), transform .2s var(--ease), filter .2s var(--ease);
}

.job-host.is-swapping > * {
  opacity: 0;
  transform: translateY(-6px);
  filter: blur(4px);
}

.job-host.is-swapped > * {
  animation: job-in .5s var(--ease-out) both;
}

.job-host.is-swapped > *:nth-child(2) { animation-delay: .05s; }
.job-host.is-swapped > *:nth-child(3) { animation-delay: .1s; }

.job-host.is-running {
  border-color: rgba(96, 165, 250, .45);
  box-shadow: 0 0 0 1px rgba(96, 165, 250, .12), 0 0 40px rgba(96, 165, 250, .08);
}

.job-host.is-running::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, .05) 50%, transparent 70%);
  transform: translateX(-100%);
  animation: job-sheen 2.4s var(--ease) infinite;
  pointer-events: none;
}

.job-host.is-done {
  border-color: rgba(34, 197, 94, .35);
}

.job-progress span {
  background-image: linear-gradient(90deg, #60a5fa, #fafafa), repeating-linear-gradient(45deg, rgba(255, 255, 255, .18) 0 8px, transparent 8px 16px);
  background-blend-mode: overlay;
}

.job-warn {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 4px;
  color: #fbbf24 !important;
}

.job-warn .icon {
  width: 14px;
  height: 14px;
  flex: none;
}

@keyframes job-in {
  from { opacity: 0; transform: translateY(8px); filter: blur(6px); }
  to { opacity: 1; transform: none; filter: none; }
}

@keyframes job-sheen {
  to { transform: translateX(100%); }
}

@media (prefers-reduced-motion: reduce) {
  .job-host.is-running::after,
  .job-host.is-swapped > * {
    animation: none;
  }
}

.plan-account-parts {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .02em;
}

.plan-why {
  display: flex;
  gap: 14px;
  padding: 16px;
  border: 1px solid rgba(251, 191, 36, .35);
  border-radius: 12px;
  background: rgba(251, 191, 36, .06);
}

.plan-why > .icon {
  flex: none;
  width: 20px;
  height: 20px;
  margin-top: 2px;
  color: #fbbf24;
}

.plan-why div {
  display: grid;
  gap: 6px;
}

.plan-why small {
  color: var(--text-2);
  font-size: var(--fs-sm);
  line-height: 1.6;
}
