:root {
  color-scheme: dark;
  --bg: #081018;
  --bg-2: #0c1724;
  --panel: rgba(12, 23, 36, 0.82);
  --panel-border: rgba(198, 216, 230, 0.14);
  --text: #f3f7fb;
  --muted: #9fb1c7;
  --soft: #c6d4e2;
  --accent: #ffb347;
  --accent-2: #4fd1c5;
  --accent-3: #7dd3fc;
  --danger: #ff6b6b;
  --shadow: 0 28px 70px rgba(0, 0, 0, 0.38);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
  background:
    radial-gradient(circle at top left, rgba(255, 179, 71, 0.16), transparent 26%),
    radial-gradient(circle at right 15%, rgba(79, 209, 197, 0.15), transparent 22%),
    linear-gradient(180deg, #07101a 0%, #0a1420 45%, #09131d 100%);
  color: var(--text);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.85), transparent 95%);
}

.bg-orbit {
  position: fixed;
  border-radius: 999px;
  filter: blur(32px);
  opacity: 0.55;
  pointer-events: none;
}

.bg-orbit-a {
  width: 18rem;
  height: 18rem;
  top: -4rem;
  left: -5rem;
  background: rgba(255, 179, 71, 0.18);
}

.bg-orbit-b {
  width: 24rem;
  height: 24rem;
  right: -8rem;
  top: 12rem;
  background: rgba(79, 209, 197, 0.12);
}

.shell {
  position: relative;
  z-index: 1;
  width: min(1160px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 28px;
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  align-items: stretch;
}

.hero-copy,
.hero-panel,
.app-shell,
.footer-strip {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(16px);
}

.hero-copy {
  padding: 34px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.76rem;
  color: var(--accent-3);
  margin-bottom: 16px;
}

h1,
h2,
h3,
.panel-title,
.panel-badge,
.metric-card strong,
.section-note,
.foot-label,
.command-card h3 {
  font-family: "Space Grotesk", "Segoe UI", sans-serif;
}

h1 {
  margin: 0;
  font-size: clamp(2.8rem, 6vw, 5.1rem);
  line-height: 0.95;
  letter-spacing: -0.06em;
  max-width: 12ch;
}

.lede {
  margin: 20px 0 0;
  max-width: 58ch;
  font-size: 1.07rem;
  line-height: 1.75;
  color: var(--soft);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

button {
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  padding: 14px 20px;
  cursor: pointer;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

button:hover {
  transform: translateY(-1px);
}

.primary-btn {
  color: #081018;
  background: linear-gradient(135deg, #ffcf86 0%, #ffb347 45%, #ff9966 100%);
  box-shadow: 0 16px 32px rgba(255, 179, 71, 0.22);
}

.secondary-btn {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.status-line {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.05);
  color: var(--soft);
  font-size: 0.9rem;
}

.pill-neutral {
  color: #d8e2eb;
}

.pill-soft {
  color: #dffbf7;
  border-color: rgba(79, 209, 197, 0.22);
  background: rgba(79, 209, 197, 0.08);
}

.auth-message {
  margin: 18px 0 0;
  color: var(--muted);
  max-width: 54ch;
  line-height: 1.7;
}

.hero-panel {
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.panel-top,
.section-head,
.footer-strip {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}

.panel-label,
.foot-label {
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
}

.panel-title {
  margin-top: 4px;
  font-size: 1.3rem;
}

.panel-badge,
.section-note {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(79, 209, 197, 0.12);
  color: #c7f4ef;
  border: 1px solid rgba(79, 209, 197, 0.16);
  font-size: 0.88rem;
}

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

.metric-card,
.workflow-card,
.command-card {
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.04);
}

.metric-card {
  padding: 18px;
  min-height: 132px;
}

.metric-card span,
.metric-card small {
  display: block;
}

.metric-card span {
  color: var(--muted);
  font-size: 0.86rem;
  margin-bottom: 10px;
}

.metric-card strong {
  display: block;
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  letter-spacing: -0.05em;
}

.metric-card small {
  margin-top: 8px;
  line-height: 1.5;
  color: var(--soft);
}

.workflow-card {
  padding: 20px;
}

.workflow-title {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.workflow-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--soft);
  line-height: 1.7;
}

.app-shell {
  margin-top: 24px;
  padding: 24px;
}

.app-shell h2 {
  margin: 6px 0 0;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  letter-spacing: -0.04em;
}

.command-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin-top: 18px;
}

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

.ops-card {
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.04);
  padding: 18px;
}

.ops-card h3 {
  margin: 0;
  font-size: 1.08rem;
}

.ops-card p {
  margin: 8px 0 0;
  color: var(--soft);
  line-height: 1.6;
}

.ops-card-wide {
  grid-column: 1 / -1;
}

.quick-actions {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.quick-action {
  display: block;
  text-decoration: none;
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  transition: background 160ms ease, transform 160ms ease, border-color 160ms ease;
}

.quick-action:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(125, 211, 252, 0.38);
  transform: translateY(-1px);
}

.checklist {
  margin-top: 14px;
  display: grid;
  gap: 10px;
}

.checklist label {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--soft);
}

.checklist input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #7dd3fc;
}

.notes-box {
  margin-top: 14px;
  width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(0, 0, 0, 0.2);
  color: var(--text);
  padding: 12px;
  resize: vertical;
  font: inherit;
  line-height: 1.6;
}

.notes-actions {
  margin-top: 12px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.command-card {
  padding: 22px;
  min-height: 190px;
}

.command-card h3 {
  margin: 0 0 10px;
  font-size: 1.15rem;
}

.command-card p {
  margin: 0;
  color: var(--soft);
  line-height: 1.75;
}

.accent-a {
  box-shadow: inset 0 1px 0 rgba(255, 179, 71, 0.18);
}

.accent-b {
  box-shadow: inset 0 1px 0 rgba(79, 209, 197, 0.16);
}

.accent-c {
  box-shadow: inset 0 1px 0 rgba(125, 211, 252, 0.16);
}

.footer-strip {
  margin-top: 24px;
  padding: 18px 22px;
  color: var(--soft);
  flex-wrap: wrap;
}

.footer-strip strong {
  display: block;
  margin-top: 6px;
  font-size: 1rem;
  color: var(--text);
}

.hidden {
  display: none !important;
}

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

  .ops-grid,
  .quick-actions {
    grid-template-columns: 1fr;
  }

  .hero-copy,
  .hero-panel,
  .app-shell,
  .footer-strip {
    border-radius: 24px;
  }

  h1 {
    max-width: 14ch;
  }
}

@media (max-width: 640px) {
  .shell {
    width: min(100% - 18px, 1160px);
    padding: 18px 0 22px;
  }

  .hero-copy,
  .hero-panel,
  .app-shell,
  .footer-strip {
    padding: 18px;
  }

  h1 {
    font-size: clamp(2.4rem, 13vw, 3.4rem);
  }

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

  .panel-top,
  .section-head,
  .footer-strip {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Additional accent variants for tool cards */
.accent-d {
  box-shadow: inset 0 1px 0 rgba(167, 139, 250, 0.18);
}

.accent-e {
  box-shadow: inset 0 1px 0 rgba(251, 113, 133, 0.16);
}

.accent-f {
  box-shadow: inset 0 1px 0 rgba(134, 239, 172, 0.16);
}

/* Linked command cards */
a.command-card {
  display: block;
  text-decoration: none;
  color: inherit;
  transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

a.command-card:hover {
  background: rgba(255, 255, 255, 0.07);
  transform: translateY(-2px);
}

a.command-card:hover h3 {
  color: var(--accent-3);
}

/* Tool sub-page navigation */
.tool-nav {
  margin-bottom: 20px;
}

.back-link {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
  letter-spacing: 0.03em;
  transition: color 120ms ease;
}

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

.tool-hero {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-bottom: 24px;
}