:root {
  color-scheme: dark;
  --bg-0: #030816;
  --bg-1: #071121;
  --bg-2: #0d1b31;
  --bg-3: #132646;
  --surface-0: rgba(7, 17, 33, 0.62);
  --surface-1: rgba(10, 23, 42, 0.72);
  --surface-2: rgba(18, 34, 61, 0.78);
  --surface-3: rgba(24, 44, 78, 0.82);
  --line: rgba(148, 163, 184, 0.18);
  --line-strong: rgba(191, 219, 254, 0.2);
  --text-strong: #f8fbff;
  --text: #d8e5fb;
  --text-muted: #96abc9;
  --text-soft: #6c7f9d;
  --accent: #75a7ff;
  --accent-2: #53d5ff;
  --accent-3: #91f0d0;
  --success: #7df0ca;
  --warning: #ffc96f;
  --danger: #ff8ca3;
  --radius-sm: 0.7rem;
  --radius-md: 1rem;
  --radius-lg: 1.35rem;
  --radius-xl: 1.8rem;
  --shadow-panel: 0 28px 80px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  --shadow-glow: 0 0 0 1px rgba(117, 167, 255, 0.18), 0 25px 70px rgba(41, 106, 223, 0.24);
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  background: var(--bg-0);
}

body {
  min-height: 100vh;
  margin: 0;
  background:
    radial-gradient(circle at 12% 18%, rgba(83, 213, 255, 0.15), transparent 24rem),
    radial-gradient(circle at 84% 10%, rgba(117, 167, 255, 0.18), transparent 30rem),
    radial-gradient(circle at 50% 100%, rgba(26, 72, 150, 0.35), transparent 32rem),
    linear-gradient(180deg, #020611 0%, #05101f 42%, #020713 100%);
  color: var(--text);
  font-family: "Plus Jakarta Sans", ui-sans-serif, system-ui, sans-serif;
  letter-spacing: -0.01em;
  overflow-x: hidden;
  position: relative;
}

body::before {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px);
  background-size: 54px 54px;
  content: "";
  inset: 0;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.8), transparent 85%);
  opacity: 0.5;
  pointer-events: none;
  position: fixed;
  z-index: 0;
}

#app,
#toast-root {
  position: relative;
  z-index: 2;
}

.app-shell {
  position: relative;
}

.ambient-orb,
.ambient-grid {
  pointer-events: none;
  position: fixed;
  z-index: 0;
}

.ambient-orb {
  border-radius: 9999px;
  filter: blur(18px);
  opacity: 0.55;
}

.ambient-orb-a {
  background: radial-gradient(circle, rgba(117, 167, 255, 0.35) 0%, rgba(117, 167, 255, 0) 70%);
  height: 22rem;
  left: -4rem;
  top: 6rem;
  width: 22rem;
  animation: driftA 16s ease-in-out infinite;
}

.ambient-orb-b {
  background: radial-gradient(circle, rgba(83, 213, 255, 0.22) 0%, rgba(83, 213, 255, 0) 70%);
  height: 28rem;
  right: -8rem;
  top: 12rem;
  width: 28rem;
  animation: driftB 18s ease-in-out infinite;
}

.ambient-grid {
  inset: auto 2rem 2rem auto;
  width: min(34vw, 22rem);
  height: min(34vw, 22rem);
  background:
    linear-gradient(rgba(125, 240, 202, 0.08), rgba(125, 240, 202, 0.01)),
    linear-gradient(90deg, rgba(125, 240, 202, 0.1) 1px, transparent 1px),
    linear-gradient(rgba(125, 240, 202, 0.1) 1px, transparent 1px);
  background-size: auto, 1.1rem 1.1rem, 1.1rem 1.1rem;
  border: 1px solid rgba(125, 240, 202, 0.12);
  border-radius: 2rem;
  mask-image: linear-gradient(135deg, rgba(0, 0, 0, 0.2), transparent 80%);
  opacity: 0.3;
  transform: perspective(1000px) rotateX(64deg) rotateZ(-18deg);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 160ms ease, border-color 160ms ease, opacity 160ms ease, transform 160ms ease;
}

::selection {
  background: rgba(117, 167, 255, 0.38);
  color: var(--text-strong);
}

.focus-ring:focus,
.focus-ring:focus-visible,
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid rgba(117, 167, 255, 0.28);
  outline-offset: 2px;
}

.app-header {
  background: rgba(4, 11, 24, 0.58) !important;
  backdrop-filter: blur(24px);
  border-color: rgba(148, 163, 184, 0.1) !important;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.22);
  position: sticky;
  top: 0;
  z-index: 20;
}

.brand-lockup,
.brand-title {
  font-family: "Space Grotesk", "Plus Jakarta Sans", ui-sans-serif, sans-serif;
}

.brand-mark {
  align-items: center;
  background: linear-gradient(145deg, rgba(117, 167, 255, 0.3), rgba(83, 213, 255, 0.12));
  border: 1px solid rgba(191, 219, 254, 0.18);
  border-radius: 1rem;
  box-shadow: var(--shadow-panel);
  display: inline-flex;
  height: 3rem;
  justify-content: center;
  position: relative;
  width: 3rem;
}

.brand-mark::before,
.brand-mark::after,
.brand-mark > span::before,
.brand-mark > span::after {
  background: rgba(226, 239, 255, 0.95);
  border-radius: 9999px;
  box-shadow: 0 0 24px rgba(117, 167, 255, 0.4);
  content: "";
  height: 0.48rem;
  position: absolute;
  width: 0.48rem;
}

.brand-mark::before {
  left: 0.42rem;
  top: 0.46rem;
}

.brand-mark::after {
  bottom: 0.46rem;
  left: 0.42rem;
}

.brand-mark > span::before {
  right: 0.42rem;
  top: 0.46rem;
}

.brand-mark > span::after {
  bottom: 0.46rem;
  right: 0.42rem;
}

.brand-mark > span {
  border: 0.16rem solid rgba(226, 239, 255, 0.9);
  border-left-width: 0.36rem;
  border-right-width: 0.36rem;
  border-radius: 0.72rem;
  display: block;
  height: 1.8rem;
  position: relative;
  width: 2rem;
}

.shell-link {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: 9999px;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  padding: 0.75rem 1rem;
  text-transform: uppercase;
}

.shell-link:hover {
  border-color: rgba(191, 219, 254, 0.24);
  color: var(--text-strong);
  transform: translateY(-1px);
}

.page-band {
  position: relative;
  z-index: 1;
}

.page-band::before {
  background: linear-gradient(90deg, transparent, rgba(117, 167, 255, 0.25), transparent);
  content: "";
  height: 1px;
  left: 1rem;
  opacity: 0.45;
  position: absolute;
  right: 1rem;
  top: 0;
}

.eyebrow {
  color: #8fd4ff;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.eyebrow-danger {
  color: #ff9ab0;
}

.glass-panel {
  background: linear-gradient(180deg, rgba(17, 31, 54, 0.78), rgba(8, 17, 32, 0.7)) !important;
  border: 1px solid rgba(148, 163, 184, 0.14) !important;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-panel);
  position: relative;
  overflow: hidden;
}

.glass-panel::before {
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), transparent 38%);
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.glass-panel-muted {
  background: linear-gradient(180deg, rgba(14, 25, 44, 0.76), rgba(8, 15, 28, 0.68)) !important;
}

.glass-panel-danger {
  background: linear-gradient(180deg, rgba(54, 18, 30, 0.82), rgba(24, 10, 18, 0.76)) !important;
}

.metric-tile,
.feature-tile,
.stack-card,
.hero-card,
.command-panel,
.panel-3d {
  transform-style: preserve-3d;
  transition: transform 240ms ease, border-color 240ms ease, box-shadow 240ms ease;
  will-change: transform;
}

.panel-3d:hover,
.metric-tile:hover,
.feature-tile:hover,
.stack-card:hover,
.hero-card:hover,
.command-panel:hover {
  border-color: rgba(191, 219, 254, 0.24) !important;
  box-shadow: var(--shadow-glow);
}

.hero-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: minmax(0, 1.1fr) minmax(18rem, 0.9fr);
}

.hero-card {
  min-height: 100%;
  padding: 1.75rem;
}

.hero-stage {
  position: relative;
  min-height: 25rem;
}

.hero-stage::before,
.hero-stage::after {
  border-radius: 1.5rem;
  content: "";
  inset: 10%;
  position: absolute;
}

.hero-stage::before {
  background: radial-gradient(circle at 50% 28%, rgba(117, 167, 255, 0.3), transparent 46%);
  filter: blur(12px);
}

.hero-stage::after {
  border: 1px solid rgba(148, 163, 184, 0.12);
  transform: perspective(1000px) rotateX(62deg);
}

.hero-float {
  position: absolute;
  inset: 0;
}

.hero-node {
  position: absolute;
  padding: 1rem 1.1rem;
  width: clamp(10rem, 22vw, 15rem);
}

.hero-node-a {
  left: 5%;
  top: 12%;
  animation: floatNode 9s ease-in-out infinite;
}

.hero-node-b {
  right: 2%;
  top: 34%;
  animation: floatNode 11s ease-in-out infinite reverse;
}

.hero-node-c {
  left: 14%;
  bottom: 6%;
  animation: floatNode 10s ease-in-out infinite;
}

.hero-ring {
  position: absolute;
  left: 50%;
  top: 48%;
  width: 12rem;
  height: 12rem;
  border-radius: 9999px;
  border: 1px solid rgba(191, 219, 254, 0.15);
  box-shadow: 0 0 0 1rem rgba(117, 167, 255, 0.03), 0 0 0 2.2rem rgba(83, 213, 255, 0.02);
  transform: translate(-50%, -50%);
}

.hero-beam {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 1px;
  height: 8rem;
  background: linear-gradient(180deg, rgba(83, 213, 255, 0.55), transparent);
  transform-origin: top center;
}

.hero-beam-a {
  transform: translate(-50%, -100%) rotate(18deg);
}

.hero-beam-b {
  transform: translate(-50%, -100%) rotate(132deg);
}

.hero-beam-c {
  transform: translate(-50%, -100%) rotate(252deg);
}

.hero-kpis,
.metrics-grid,
.feature-grid,
.admin-grid,
.candidate-grid {
  display: grid;
  gap: 1rem;
}

.hero-kpis,
.feature-grid {
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
}

.metrics-grid {
  grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr));
}

.admin-grid {
  grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr));
}

.candidate-grid {
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
}

.metric-tile,
.feature-tile,
.stack-card {
  padding: 1.15rem;
}

.floating-badge {
  background: rgba(143, 212, 255, 0.1);
  border: 1px solid rgba(143, 212, 255, 0.18);
  border-radius: 9999px;
  color: #dff4ff;
  display: inline-flex;
  font-size: 0.8rem;
  font-weight: 700;
  gap: 0.45rem;
  padding: 0.6rem 0.9rem;
}

.toast-card {
  backdrop-filter: blur(24px);
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-left-width: 4px;
  border-radius: 1rem;
  box-shadow: var(--shadow-panel);
  color: var(--text-strong);
  max-width: 22rem;
  padding: 0.95rem 1rem;
}

.toast-info { background: rgba(10, 20, 37, 0.94); border-left-color: #8fd4ff; }
.toast-success { background: rgba(8, 28, 28, 0.94); border-left-color: #7df0ca; }
.toast-error { background: rgba(40, 14, 23, 0.94); border-left-color: #ff8ca3; }
.toast-warning { background: rgba(38, 25, 8, 0.94); border-left-color: #ffc96f; }

.spinner {
  animation: spin 0.8s linear infinite;
  border: 3px solid rgba(148, 163, 184, 0.18);
  border-radius: 9999px;
  border-top-color: var(--accent-2);
  box-shadow: 0 0 20px rgba(114, 183, 255, 0.18);
  height: 2.6rem;
  width: 2.6rem;
}

.inline-spinner {
  animation: spin 0.8s linear infinite;
  border: 2px solid rgba(255, 255, 255, 0.28);
  border-radius: 9999px;
  border-top-color: #ffffff;
  display: inline-block;
  height: 1rem;
  margin-right: 0.5rem;
  vertical-align: -0.15rem;
  width: 1rem;
}

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

@keyframes driftA {
  50% { transform: translate3d(2rem, 1rem, 0) scale(1.05); }
}

@keyframes driftB {
  50% { transform: translate3d(-2rem, 1.5rem, 0) scale(0.96); }
}

@keyframes floatNode {
  50% { transform: translate3d(0, -10px, 0); }
}

button,
.action-btn,
.interview-btn {
  align-items: center;
  background: linear-gradient(135deg, rgba(89, 130, 255, 0.96), rgba(34, 66, 146, 0.96)) !important;
  border: 1px solid rgba(174, 189, 255, 0.2) !important;
  border-radius: 1rem !important;
  box-shadow: 0 14px 40px rgba(34, 66, 146, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.14);
  color: #ffffff !important;
  display: inline-flex;
  font-weight: 700;
  justify-content: center;
  min-height: 44px;
  padding-inline: 1rem;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease, background 180ms ease, opacity 180ms ease;
}

button:hover,
.action-btn:hover,
.interview-btn:hover {
  background: linear-gradient(135deg, rgba(116, 157, 255, 0.98), rgba(46, 84, 183, 0.98)) !important;
  border-color: rgba(207, 216, 255, 0.34) !important;
  box-shadow: var(--shadow-glow);
  color: #ffffff !important;
  transform: translateY(-1px);
}

button:disabled,
.action-btn:disabled,
.interview-btn:disabled {
  cursor: not-allowed;
  opacity: 0.58;
  transform: none;
}

.interview-btn-danger {
  background: linear-gradient(135deg, rgba(132, 48, 68, 0.96), rgba(89, 27, 49, 0.96)) !important;
}

.interview-btn-primary {
  background: linear-gradient(135deg, rgba(72, 196, 174, 0.96), rgba(23, 113, 114, 0.96)) !important;
}

input,
textarea,
select,
.bg-white,
.bg-zinc-50 {
  background-color: rgba(9, 18, 34, 0.72) !important;
  color: var(--text-strong) !important;
}

input,
textarea,
select {
  border-color: var(--line) !important;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input::placeholder,
textarea::placeholder {
  color: rgba(154, 168, 189, 0.7);
}

input:hover,
textarea:hover,
select:hover {
  border-color: rgba(147, 197, 253, 0.32) !important;
}

input:focus,
textarea:focus,
select:focus {
  background: rgba(8, 18, 35, 0.9) !important;
  border-color: rgba(147, 197, 253, 0.6) !important;
  box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.1), 0 0 28px rgba(99, 102, 241, 0.12);
}

textarea {
  resize: vertical;
}

select option {
  background: #0b1425;
  color: var(--text-strong);
}

summary {
  outline: none;
}

table {
  border-collapse: separate;
  border-spacing: 0;
  color: var(--text);
  overflow: hidden;
  width: 100%;
}

thead {
  background: rgba(117, 167, 255, 0.08);
  color: var(--text-strong);
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 0.85rem 1rem;
  text-align: left;
}

tbody tr {
  transition: background 160ms ease;
}

tbody tr:hover {
  background: rgba(117, 167, 255, 0.05);
}

.rounded-md,
.rounded-lg,
.rounded-xl {
  border-radius: var(--radius-lg) !important;
}

.border-line,
.border {
  border-color: var(--line) !important;
}

.shadow-panel {
  box-shadow: var(--shadow-panel) !important;
}

.bg-zinc-950 {
  background: linear-gradient(180deg, rgba(4, 11, 24, 0.98), rgba(3, 8, 18, 0.98)) !important;
}

.bg-zinc-900 {
  background: linear-gradient(180deg, rgba(17, 29, 51, 0.95), rgba(10, 19, 34, 0.95)) !important;
}

.bg-zinc-300 {
  background: rgba(99, 115, 148, 0.4) !important;
}

.text-ink,
.text-white {
  color: var(--text-strong) !important;
}

.text-zinc-600,
.text-zinc-700,
.text-zinc-500,
.text-zinc-400,
.text-zinc-300 {
  color: var(--text-muted) !important;
}

.text-sky,
.text-blue-700 {
  color: #8fd4ff !important;
}

.text-mint,
.text-emerald-700,
.text-emerald-800 {
  color: var(--success) !important;
}

.text-red-700,
.text-red-800 {
  color: #ffb3c2 !important;
}

.border-mint,
.border-emerald-200 {
  border-color: rgba(125, 240, 202, 0.2) !important;
}

.border-coral,
.border-red-200,
.border-red-300 {
  border-color: rgba(255, 140, 163, 0.22) !important;
}

.bg-emerald-50 {
  background: rgba(10, 39, 36, 0.76) !important;
}

.bg-red-50 {
  background: rgba(51, 16, 26, 0.76) !important;
}

.bg-amber-50 {
  background: rgba(52, 35, 13, 0.76) !important;
}

.bg-red-100 {
  background: rgba(73, 21, 34, 0.86) !important;
}

.ring-1,
.ring-line {
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.14) !important;
}

.transcript-box {
  background:
    linear-gradient(180deg, rgba(9, 18, 34, 0.84), rgba(7, 15, 29, 0.92)),
    radial-gradient(circle at 0 0, rgba(117, 167, 255, 0.1), transparent 30%);
  box-shadow: inset 0 0 0 1px rgba(148, 163, 184, 0.1);
}

.audio-bar {
  background: linear-gradient(90deg, rgba(83, 213, 255, 0.9), rgba(125, 240, 202, 0.9)) !important;
  transform-origin: left center;
}

.job-card {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: inherit !important;
  display: block;
  min-height: 0;
  padding: 0 !important;
  width: 100%;
}

.job-card:hover {
  transform: none;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

.violation-video-popup {
  backdrop-filter: blur(18px);
}

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

  .hero-stage {
    min-height: 22rem;
  }
}

@media (max-width: 768px) {
  .ambient-grid {
    display: none;
  }

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

  .shell-link {
    padding: 0.65rem 0.9rem;
  }

  .hero-stage {
    min-height: 20rem;
  }

  .hero-node {
    width: 10rem;
  }
}
