:root {
  --bg-void: #040810;
  --bg-deep: #060d1a;
  --bg-surface: #0a1628;
  --bg-panel: #0d1e35;
  --bg-card: #0f2340;
  --bg-elevated: #122848;
  --border-faint: rgba(0, 140, 255, 0.08);
  --border-subtle: rgba(0, 160, 255, 0.15);
  --border-mid: rgba(0, 180, 255, 0.25);
  --border-active: rgba(0, 200, 255, 0.5);
  --accent-primary: #00b4ff;
  --accent-bright: #00d4ff;
  --accent-pulse: #00eeff;
  --accent-amber: #ff8c00;
  --accent-green: #00ff9d;
  --accent-red: #ff3355;
  --accent-purple: #8b5cf6;
  --text-primary: #e8f4ff;
  --text-secondary: #8ab4d4;
  --text-muted: #4a7090;
  --text-disabled: #2a4560;
  --font-display: "Russo One", "Arial Black", Impact, sans-serif;
  --font-mono: "PT Mono", "Cascadia Mono", Consolas, monospace;
  --glow-sm: 0 0 10px rgba(0, 180, 255, 0.3);
  --glow-md: 0 0 20px rgba(0, 180, 255, 0.4), 0 0 40px rgba(0, 120, 255, 0.2);
  --glow-green: 0 0 10px rgba(0, 255, 157, 0.4);
  --glow-amber: 0 0 15px rgba(255, 140, 0, 0.4), 0 0 30px rgba(255, 100, 0, 0.2);
  --radius-sm: 3px;
  --radius-md: 5px;
  --radius-lg: 8px;
  --transition: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --sidebar-width: 276px;
  --right-rail-width: 214px;
  --statusbar-height: 30px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg-void);
  color: var(--text-primary);
  font: 16px/1.5 var(--font-mono);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(0, 140, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(0, 140, 255, 0.03) 1px, transparent 1px);
  background-size: 50px 50px;
}

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

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

button {
  cursor: pointer;
}

form {
  margin: 0;
}

.accent {
  color: var(--accent-bright);
  text-shadow: var(--glow-sm);
}

.muted {
  color: var(--text-muted);
}

.secondary {
  color: var(--text-secondary);
}

.app-container {
  position: relative;
  z-index: 1;
  min-height: 100vh;
}

.app-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 30;
  width: var(--sidebar-width);
  padding: 22px 0 18px;
  border-right: 1px solid var(--border-subtle);
  background: linear-gradient(180deg, rgba(4, 8, 16, 0.98), rgba(6, 13, 26, 0.98));
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.app-brand {
  display: flex;
  align-items: center;
  gap: 13px;
  min-width: 0;
  padding: 0 18px;
}

.radar,
.app-logo-mark {
  position: relative;
  flex: 0 0 44px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1.5px solid rgba(0, 212, 255, 0.52);
  background: radial-gradient(circle at center, rgba(0, 212, 255, 0.18), rgba(4, 8, 16, 0.82) 52%, rgba(4, 8, 16, 0.98) 100%);
  box-shadow: inset 0 0 20px rgba(0, 180, 255, 0.12), 0 0 18px rgba(0, 180, 255, 0.16);
  overflow: hidden;
}

.radar--large {
  flex-basis: 112px;
  width: 112px;
  height: 112px;
}

.ring {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  border: 1.4px solid rgba(0, 212, 255, 0.58);
  transform: translate(-50%, -50%);
}

.r1 { width: 10px; height: 10px; }
.r2 { width: 20px; height: 20px; opacity: 0.85; }
.r3 { width: 32px; height: 32px; opacity: 0.62; border-style: dashed; animation: ring-spin 12s linear infinite; }
.r4 { width: 42px; height: 42px; opacity: 0.46; border-color: rgba(0, 180, 255, 0.4); }
.radar--large .r1 { width: 24px; height: 24px; }
.radar--large .r2 { width: 48px; height: 48px; }
.radar--large .r3 { width: 76px; height: 76px; }
.radar--large .r4 { width: 102px; height: 102px; }

.sweep {
  position: absolute;
  inset: -6%;
  background: conic-gradient(from 0deg, transparent 0deg, rgba(0, 238, 255, 0) 286deg, rgba(0, 238, 255, 0.16) 314deg, rgba(0, 238, 255, 0.78) 334deg, rgba(0, 238, 255, 0.24) 350deg, rgba(0, 238, 255, 0) 360deg);
  animation: spin 4.5s linear infinite;
  filter: blur(1px);
}

.core {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-pulse);
  transform: translate(-50%, -50%);
  box-shadow: 0 0 12px rgba(0, 238, 255, 0.9), 0 0 24px rgba(0, 180, 255, 0.3);
  animation: pulse-core 2.8s ease-in-out infinite;
}

.app-logo-title,
.auth-name,
.section-title,
.screen-title,
.panel-title,
.card-title,
.metric-value {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.08em;
  line-height: 1.08;
  text-transform: uppercase;
}

.app-logo-title {
  font-size: 20px;
  line-height: 1;
  white-space: nowrap;
}

.app-nav {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  overflow-y: auto;
}

.app-tab,
.settings-tab,
.rail-item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 20px 0 18px;
  border: 0;
  border-left: 3px solid transparent;
  border-bottom: 1px solid rgba(0, 140, 255, 0.06);
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  letter-spacing: 0.08em;
  line-height: 1.25;
  text-align: left;
  text-transform: uppercase;
  transition: var(--transition);
}

.nav-icon,
.rail-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 16px;
  width: 16px;
  height: 16px;
  color: currentColor;
  opacity: 0.72;
}

.nav-icon svg,
.rail-icon svg {
  width: 16px;
  height: 16px;
  display: block;
}

.app-tab:hover,
.settings-tab:hover,
.rail-item:hover {
  color: var(--text-secondary);
  background: rgba(0, 180, 255, 0.03);
}

.app-tab.active,
.settings-tab.active,
.rail-item.active {
  color: var(--accent-bright);
  border-left-color: var(--accent-primary);
  background: rgba(0, 180, 255, 0.06);
}

.app-sidebar-footer {
  padding: 14px 16px 0;
  border-top: 1px solid var(--border-faint);
}

.main-content,
.statusbar {
  margin-left: var(--sidebar-width);
}

.main-content {
  min-height: calc(100vh - var(--statusbar-height));
}

.screen,
.account-screen {
  min-height: calc(100vh - var(--statusbar-height));
}

.settings-screen-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  min-height: 50px;
  padding: 12px 20px 10px;
  border-bottom: 1px solid var(--border-subtle);
}

.screen-title {
  margin: 0;
  font-size: 18px;
}

.screen-kicker,
.tiny-label,
.field-label,
.summary-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.screen-body {
  padding: 28px 40px 70px;
}

.screen-body--dense {
  padding-top: 22px;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(300px, 0.8fr);
  gap: 18px;
  align-items: start;
}

.home-stack {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
  max-width: 1160px;
}

.card,
.panel,
.summary-card,
.state-card,
.tool-card {
  min-width: 0;
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-lg);
  background: rgba(0, 180, 255, 0.04);
  backdrop-filter: blur(10px);
}

.panel,
.card {
  background: linear-gradient(180deg, rgba(13, 30, 53, 0.8), rgba(10, 22, 40, 0.92));
  border-color: var(--border-subtle);
}

.panel {
  padding: 18px;
}

.panel-head,
.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.panel-title,
.section-title {
  margin: 0 0 8px;
  font-size: 24px;
}

.panel-copy,
.section-copy,
.card-copy {
  margin: 0;
  color: var(--text-secondary);
  font-size: 13px;
  line-height: 1.65;
}

.summary-grid,
.tool-grid,
.profile-grid {
  display: grid;
  gap: 16px;
}

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

.tool-grid {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.profile-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.summary-card,
.tool-card,
.state-card {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 16px;
}

.summary-card:hover,
.tool-card:hover {
  border-color: var(--border-active);
  box-shadow: var(--glow-sm);
}

.card-title,
.summary-card h3,
.tool-card h3 {
  margin: 0;
  font-size: 18px;
  overflow-wrap: anywhere;
}

.metric-value {
  margin: 0;
  color: var(--text-primary);
  font-size: 26px;
  overflow-wrap: anywhere;
}

.badge,
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 13px;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  background: rgba(0, 180, 255, 0.04);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.15em;
  line-height: 1.25;
  text-transform: uppercase;
}

.badge::before,
.status-badge::before {
  content: "";
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  border-radius: 50%;
  background: currentColor;
}

.badge-success,
.status-badge.success {
  color: var(--accent-green);
  border-color: rgba(0, 255, 157, 0.25);
  background: rgba(0, 255, 157, 0.07);
}

.badge-success::before,
.status-badge.success::before {
  box-shadow: var(--glow-green);
}

.badge-warning,
.status-badge.warning {
  color: var(--accent-amber);
  border-color: rgba(255, 140, 0, 0.25);
  background: rgba(255, 140, 0, 0.07);
}

.badge-error,
.status-badge.danger,
.status-badge.error {
  color: var(--accent-red);
  border-color: rgba(255, 51, 85, 0.25);
  background: rgba(255, 51, 85, 0.07);
}

.badge-info,
.status-badge.info {
  color: var(--accent-primary);
  border-color: var(--border-mid);
  background: rgba(0, 180, 255, 0.07);
}

.btn,
.primary-button,
.secondary-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 11px 26px;
  border: 1px solid transparent;
  background: rgba(3, 13, 25, 0.72);
  color: var(--text-secondary);
  font-size: 11px;
  letter-spacing: 0.12em;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
  white-space: nowrap;
  transition: var(--transition);
  clip-path: polygon(14px 0, 100% 0, calc(100% - 14px) 100%, 0 100%);
}

.btn-primary,
.primary-button {
  color: var(--accent-bright);
  border-color: var(--border-active);
  background: linear-gradient(180deg, rgba(0, 83, 122, 0.94), rgba(0, 43, 72, 0.98));
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.18) inset, 0 0 22px rgba(0, 180, 255, 0.18);
}

.btn-secondary,
.secondary-button {
  border-color: var(--border-mid);
  background: rgba(0, 180, 255, 0.04);
}

.btn-danger {
  color: var(--accent-red);
  border-color: rgba(255, 51, 85, 0.3);
  background: rgba(255, 51, 85, 0.08);
}

.btn-wide {
  width: 100%;
}

.btn-lg {
  min-height: 54px;
}

.btn:hover,
.primary-button:hover,
.secondary-button:hover,
.btn:focus-visible,
.primary-button:focus-visible,
.secondary-button:focus-visible {
  color: var(--accent-pulse);
  border-color: var(--border-active);
  background: linear-gradient(180deg, rgba(0, 101, 148, 0.98), rgba(0, 52, 86, 0.98));
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.24) inset, 0 0 30px rgba(0, 180, 255, 0.24);
  outline: none;
}

.btn:disabled,
.primary-button:disabled,
.secondary-button:disabled {
  cursor: not-allowed;
  opacity: 0.48;
  box-shadow: none;
}

.btn-icon {
  width: 40px;
  min-width: 40px;
  padding: 0;
  border-radius: var(--radius-md);
  clip-path: none;
}

.inline-form {
  display: inline-flex;
}

.tabs,
.profile-subtabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px;
  border: 1px solid var(--border-mid);
  border-radius: 999px;
  background: rgba(8, 18, 34, 0.52);
}

.tabs--box {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 7px;
  border-radius: 0;
}

.tab,
.account-tab,
.profile-subtab {
  min-height: 34px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--text-muted);
  padding: 9px 14px;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: var(--transition);
}

.tabs--box .tab {
  min-height: 48px;
  border-radius: 0;
  padding: 13px 16px;
  letter-spacing: 0.16em;
}

.tab.active,
.account-tab.is-active,
.profile-subtab.active {
  color: var(--accent-primary);
  border-color: rgba(0, 212, 255, 0.55);
  background: linear-gradient(180deg, rgba(0, 91, 132, 0.42), rgba(0, 34, 58, 0.68));
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.22) inset, 0 0 20px rgba(0, 180, 255, 0.16);
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 16px;
}

.field-input,
.text-input,
input,
textarea,
select {
  width: 100%;
  min-height: 41px;
  padding: 10px 15px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  color: var(--text-primary);
  outline: none;
  transition: var(--transition);
}

.field-input:focus,
.text-input:focus,
input:focus,
textarea:focus,
select:focus {
  border-color: var(--accent-primary);
  background: var(--bg-panel);
  box-shadow: var(--glow-sm);
}

input::placeholder,
textarea::placeholder {
  color: var(--text-disabled);
}

input:disabled,
textarea:disabled,
select:disabled,
button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.text-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.text-input-wrapper .text-input {
  padding-right: 44px;
}

.text-input-wrapper.is-invalid .text-input,
.input-error {
  border-color: rgba(255, 51, 85, 0.55);
  box-shadow: 0 0 0 2px rgba(255, 51, 85, 0.12);
}

.password-toggle {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border-faint);
  border-radius: var(--radius-md);
  background: rgba(0, 180, 255, 0.03);
  color: var(--text-secondary);
  transition: var(--transition);
}

.password-toggle:hover {
  color: var(--accent-pulse);
  border-color: var(--border-active);
  box-shadow: var(--glow-sm);
}

.icon-eye {
  width: 18px;
  height: 18px;
}

.icon-eye-closed {
  display: none;
}

.password-toggle.is-visible .icon-eye-open {
  display: none;
}

.password-toggle.is-visible .icon-eye-closed {
  display: block;
}

.field-error {
  display: none;
  margin: 0;
  color: #ffb8c4;
  font-size: 11px;
  line-height: 1.5;
}

.field-error.is-visible {
  display: block;
}

.field-help,
.hint {
  margin: 0;
  color: var(--text-muted);
  font-size: 10px;
  line-height: 1.55;
}

.flash,
.alert,
.notice {
  padding: 14px 16px;
  border: 1px solid var(--border-mid);
  border-left-width: 3px;
  border-radius: var(--radius-md);
  background: rgba(0, 180, 255, 0.06);
  color: var(--text-primary);
  font-size: 12px;
  line-height: 1.65;
}

.alert strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text-primary);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.flash.success,
.alert.success,
.notice-success {
  border-color: rgba(0, 255, 157, 0.32);
  background: rgba(0, 255, 157, 0.08);
  color: #cbffe8;
}

.flash.warning,
.alert.warning,
.notice-warning {
  border-color: rgba(255, 140, 0, 0.32);
  background: rgba(255, 140, 0, 0.08);
  color: #ffe4b8;
}

.flash.error,
.alert.error {
  border-color: rgba(255, 51, 85, 0.35);
  background: rgba(255, 51, 85, 0.08);
  color: #ffd6de;
}

.statusbar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 25;
  height: var(--statusbar-height);
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 15px;
  border-top: 1px solid var(--border-faint);
  background: var(--bg-void);
}

.statusbar-item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 13px;
  letter-spacing: 0.06em;
}

.statusbar-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-green);
  box-shadow: var(--glow-green);
}

.account-screen {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--right-rail-width);
  grid-template-rows: auto minmax(0, 1fr);
}

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

.account-screen .settings-screen-header {
  grid-column: 1 / -1;
}

.account-content {
  min-width: 0;
  padding: 20px 24px 80px;
  max-width: 1180px;
}

.account-screen--single .account-content {
  width: min(100%, 1180px);
}

.right-rail {
  grid-row: 1 / 3;
  grid-column: 2;
  border-left: 1px solid var(--border-subtle);
  background: rgba(4, 8, 16, 0.98);
  padding: 16px 0 104px;
}

.right-rail .rail-item {
  min-height: 48px;
  padding: 0 16px;
  border-left: 0;
  border-right: 3px solid transparent;
  font-size: 11px;
}

.right-rail .rail-item.active {
  border-right-color: var(--accent-primary);
  border-left-color: transparent;
}

.profile-header {
  margin-bottom: 16px;
}

.profile-subtabs {
  margin-bottom: 20px;
}

.account-panel-card {
  display: none;
}

.account-panel-card.is-active {
  display: block;
}

.account-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
}

.auth-scene {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  position: relative;
  background:
    radial-gradient(circle at top, rgba(0, 186, 255, 0.12), transparent 30%),
    radial-gradient(circle at 80% 20%, rgba(0, 238, 255, 0.08), transparent 18%),
    radial-gradient(circle at 15% 80%, rgba(255, 140, 0, 0.08), transparent 22%),
    linear-gradient(180deg, #050914 0%, var(--bg-deep) 44%, #050a12 100%);
}

.auth-frame {
  position: absolute;
  inset: 6% 9%;
  border: 1px solid rgba(0, 180, 255, 0.08);
  clip-path: polygon(0 18px, 18px 0, calc(100% - 18px) 0, 100% 18px, 100% calc(100% - 18px), calc(100% - 18px) 100%, 18px 100%, 0 calc(100% - 18px));
}

.auth-shell {
  position: relative;
  z-index: 1;
  width: min(1120px, 100%);
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  border: 1px solid var(--border-mid);
  background: linear-gradient(135deg, rgba(6, 13, 26, 0.94), rgba(9, 19, 36, 0.98));
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(18px);
  overflow: hidden;
  clip-path: polygon(0 24px, 24px 0, calc(100% - 24px) 0, 100% 24px, 100% calc(100% - 24px), calc(100% - 24px) 100%, 24px 100%, 0 calc(100% - 24px));
}

.auth-left,
.auth-right {
  min-width: 0;
  position: relative;
}

.auth-left {
  display: flex;
  flex-direction: column;
  padding: 40px;
  border-right: 1px solid rgba(0, 180, 255, 0.2);
  background:
    radial-gradient(circle at 48% 20%, rgba(0, 212, 255, 0.18), transparent 24%),
    linear-gradient(160deg, rgba(12, 28, 50, 0.96), rgba(6, 14, 28, 0.99));
}

.auth-right {
  padding: 30px;
  background: linear-gradient(180deg, rgba(10, 22, 40, 0.99), rgba(5, 12, 25, 0.99));
}

.auth-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  margin-bottom: 24px;
  padding: 7px 14px;
  border: 1px solid rgba(0, 210, 255, 0.45);
  background: rgba(0, 180, 255, 0.06);
  color: var(--accent-bright);
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}

.auth-tag::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-pulse);
  box-shadow: 0 0 10px rgba(0, 212, 255, 0.6);
}

.auth-brand {
  display: flex;
  align-items: center;
  gap: 22px;
  margin-bottom: 28px;
}

.auth-name {
  font-size: clamp(32px, 4vw, 52px);
  text-shadow: 0 0 22px rgba(0, 180, 255, 0.35);
}

.auth-subname {
  margin-top: 10px;
  color: var(--accent-bright);
  font-size: 15px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
}

.auth-title-box {
  position: relative;
  max-width: 560px;
  min-height: 312px;
  margin-bottom: 20px;
  padding: 16px 18px 14px;
  border: 1px solid rgba(0, 180, 255, 0.42);
  background: linear-gradient(180deg, rgba(8, 22, 40, 0.78), rgba(5, 13, 26, 0.92));
  box-shadow: inset 0 0 0 1px rgba(0, 212, 255, 0.05), inset 0 0 36px rgba(0, 180, 255, 0.09), 0 0 28px rgba(0, 180, 255, 0.08);
}

.auth-title-box::before {
  content: "";
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(0, 180, 255, 0.18);
}

.auth-title {
  position: relative;
  z-index: 1;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(30px, 3.2vw, 42px);
  line-height: 1.12;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.auth-copy {
  margin: 0;
  color: var(--text-secondary);
  font-size: 18px;
}

.auth-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.auth-panel {
  margin-top: 24px;
  border: 1px solid rgba(0, 180, 255, 0.34);
  background: linear-gradient(180deg, rgba(14, 31, 55, 0.96), rgba(8, 18, 35, 0.98));
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.05) inset, 0 0 30px rgba(0, 180, 255, 0.11);
}

.auth-panel-head {
  padding: 22px;
  border-bottom: 1px solid rgba(0, 180, 255, 0.16);
}

.auth-panel-head h2 {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.auth-panel-head p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 12px;
  line-height: 1.6;
}

.auth-form,
.stack-form {
  padding: 22px;
}

.auth-form .text-input,
.auth-form .text-input-wrapper .text-input {
  min-height: 46px;
  border-color: rgba(0, 180, 255, 0.28);
  background: rgba(3, 12, 24, 0.96);
  box-shadow: inset 0 0 0 1px rgba(0, 212, 255, 0.03);
}

.auth-form .text-input:focus {
  border-color: rgba(0, 212, 255, 0.72);
  background: rgba(223, 240, 255, 0.96);
  color: #04101e;
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.38), 0 0 24px rgba(0, 180, 255, 0.22);
}

.auth-form .btn-primary {
  margin-top: 4px;
  border-color: rgba(0, 212, 255, 0.72);
  background: linear-gradient(180deg, rgba(0, 84, 124, 0.98), rgba(0, 45, 74, 1));
  box-shadow: 0 0 0 1px rgba(0, 212, 255, 0.24) inset, 0 0 28px rgba(0, 180, 255, 0.18);
}

.auth-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 22px 22px;
  border-top: 1px solid rgba(0, 180, 255, 0.08);
  color: var(--text-muted);
  font-size: 10px;
  text-transform: uppercase;
}

.auth-links {
  display: grid;
  gap: 10px;
  padding: 0 22px 22px;
}

.link-inline {
  color: var(--accent-bright);
  text-shadow: var(--glow-sm);
}

.auth-link-secondary {
  color: var(--text-secondary);
  text-shadow: none;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.home-band {
  display: grid;
  gap: 18px;
}

.mini-map {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.mini-map .state-card {
  min-height: 118px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes ring-spin {
  from { transform: translate(-50%, -50%) rotate(0deg); }
  to { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes pulse-core {
  0%, 100% { opacity: 0.9; transform: translate(-50%, -50%) scale(1); }
  50% { opacity: 1; transform: translate(-50%, -50%) scale(1.18); }
}

@media (max-width: 1100px) {
  .workspace-grid,
  .summary-grid,
  .mini-map,
  .auth-shell,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .auth-left {
    border-right: 0;
    border-bottom: 1px solid var(--border-faint);
  }

  .account-screen {
    grid-template-columns: 1fr;
  }

  .right-rail {
    display: none;
  }
}

@media (max-width: 900px) {
  .app-sidebar {
    position: sticky;
    top: 0;
    width: 100%;
    height: auto;
    padding: 12px 0;
  }

  .app-nav {
    flex-direction: row;
    overflow-x: auto;
  }

  .app-tab {
    min-width: max-content;
    border-left: 0;
    border-bottom: 3px solid transparent;
  }

  .app-tab.active {
    border-bottom-color: var(--accent-primary);
  }

  .app-sidebar-footer {
    display: none;
  }

  .main-content,
  .statusbar {
    margin-left: 0;
  }

  .statusbar {
    position: static;
    height: auto;
    min-height: var(--statusbar-height);
  }

  .screen-body,
  .account-content {
    padding: 18px 14px 48px;
  }
}

@media (max-width: 640px) {
  .auth-scene {
    padding: 0;
  }

  .auth-frame {
    display: none;
  }

  .auth-shell {
    min-height: 100vh;
    clip-path: none;
    border-left: 0;
    border-right: 0;
  }

  .auth-left,
  .auth-right {
    padding-left: 18px;
    padding-right: 18px;
  }

  .auth-brand {
    align-items: flex-start;
  }

  .radar--large {
    flex-basis: 92px;
    width: 92px;
    height: 92px;
  }

  .auth-title-box {
    min-height: 220px;
  }

  .auth-footer {
    flex-direction: column;
  }
}
