* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --blue: #1a4b8c;
  --gold: #e8a820;
  --gray-mid: #94a3b8;
  --gray-dark: #334155;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #fff;
  color: var(--gray-dark);
  margin: 0;
  height: 100vh;
  overflow: hidden;
}

/* ── Top bar ── */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  padding: 0 32px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(26, 75, 140, 0.08);
}

.topbar-brand {
  display: flex;
  align-items: center;
  text-decoration: none;
}

.topbar-logo {
  height: 28px;
  width: auto;
}

.topbar-menu {
  display: flex;
  align-items: center;
  gap: 8px;
}

.topbar-link {
  text-decoration: none;
  color: var(--gray-dark);
  font-size: 13px;
  font-weight: 500;
  padding: 6px 14px;
  border-radius: 6px;
  transition: background 0.2s, color 0.2s;
}

.topbar-link:hover {
  background: rgba(26, 75, 140, 0.06);
  color: var(--blue);
}

.topbar-btn {
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  padding: 7px 18px;
  border-radius: 6px;
  background: var(--blue);
  color: #fff;
  margin-left: 4px;
  transition: background 0.2s, transform 0.15s;
}

.topbar-btn:hover {
  background: #163d73;
  transform: translateY(-1px);
}

.topbar-burger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 28px;
  height: 28px;
  color: var(--gray-dark);
}

/* ── Scene fills entire viewport ── */

.scene {
  position: relative;
  width: 100vw;
  height: 100vh;
}

.scene-rotate {
  position: absolute;
  inset: 0;
  transform: rotate(45deg);
  transform-origin: center center;
}

/* ── Connector lines (CSS cross) ── */

.connector {
  position: absolute;
  z-index: 0;
  pointer-events: none;
}

.connector-v {
  top: calc(50% - 220px);
  left: 50%;
  width: 0;
  height: 440px;
  border-left: 1px dashed rgba(26, 75, 140, 0.18);
}

.connector-h {
  top: 50%;
  left: calc(50% - 220px);
  width: 440px;
  height: 0;
  border-top: 1px dashed rgba(26, 75, 140, 0.18);
}

/* ── Center hub ── */

.hub {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-45deg);
  z-index: 2;
}

.hub-logo {
  width: 120px;
  height: auto;
  display: block;
}

/* ── Tool nodes ── */

.node {
  position: absolute;
  z-index: 3;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: #fff;
  border: 2px solid var(--blue);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  text-decoration: none;
  color: var(--blue);
  transition: all 0.3s ease;
  box-shadow: 0 2px 12px rgba(26, 75, 140, 0.06);
  cursor: pointer;
  transform: translate(-50%, -50%) rotate(-45deg);
}

.node:hover {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 8px 32px rgba(26, 75, 140, 0.2);
  transform: translate(-50%, -50%) rotate(-45deg) scale(1.08);
}

.node-icon {
  width: 32px;
  height: 32px;
}

.node-icon svg {
  width: 100%;
  height: 100%;
}

.node-label {
  font-size: 11px;
  font-weight: 600;
  text-align: center;
  line-height: 1.2;
  padding: 0 6px;
}

/* Positions: place each node relative to viewport center */
/* Using calc(50% +/- offset) so they are always centered around the hub */

.node-1 {
  top: calc(50% - 220px);
  left: 50%;
}

.node-2 {
  top: 50%;
  left: calc(50% + 220px);
}

.node-3 {
  top: calc(50% + 220px);
  left: 50%;
}

.node-4 {
  top: 50%;
  left: calc(50% - 220px);
}

/* Disabled */

.node-disabled {
  border-color: var(--gray-mid);
  color: var(--gray-mid);
  cursor: default;
  opacity: 0.45;
}

.node-disabled:hover {
  background: #fff;
  color: var(--gray-mid);
  box-shadow: 0 2px 12px rgba(26, 75, 140, 0.06);
  transform: translate(-50%, -50%) rotate(-45deg);
}

/* ── Footer ── */

.footer {
  position: fixed;
  bottom: 0;
  width: 100%;
  text-align: center;
  padding: 12px;
  font-size: 11px;
  color: var(--gray-mid);
  z-index: 5;
}

/* ── Animations ── */

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.hub    { animation: fadeIn 0.5s ease both; }
.node-1 { animation: fadeIn 0.4s ease 0.1s both; }
.node-2 { animation: fadeIn 0.4s ease 0.2s both; }
.node-3 { animation: fadeIn 0.4s ease 0.3s both; }
.node-4 { animation: fadeIn 0.4s ease 0.4s both; }

/* ── CTA Bubble ── */

.cta-bubble {
  position: fixed;
  bottom: 48px;
  right: 32px;
  z-index: 50;
  max-width: 340px;
  background: #fff;
  border: 1px solid rgba(26, 75, 140, 0.12);
  border-radius: 16px;
  padding: 20px 24px;
  box-shadow: 0 8px 32px rgba(26, 75, 140, 0.12), 0 2px 8px rgba(0, 0, 0, 0.06);
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.cta-bubble.cta-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.cta-bubble::after {
  content: '';
  position: absolute;
  bottom: -8px;
  right: 28px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-right: 1px solid rgba(26, 75, 140, 0.12);
  border-bottom: 1px solid rgba(26, 75, 140, 0.12);
  transform: rotate(45deg);
}

.cta-close {
  position: absolute;
  top: 8px;
  right: 12px;
  background: none;
  border: none;
  font-size: 20px;
  color: var(--gray-mid);
  cursor: pointer;
  line-height: 1;
  padding: 4px;
  transition: color 0.15s;
}

.cta-close:hover {
  color: var(--gray-dark);
}

.cta-text {
  font-size: 14px;
  line-height: 1.5;
  color: var(--gray-dark);
  margin-bottom: 12px;
}

.cta-text strong {
  font-size: 16px;
  color: var(--blue);
}

.cta-link {
  display: inline-block;
  font-size: 13px;
  font-weight: 600;
  color: #fff;
  background: var(--blue);
  padding: 10px 18px;
  border-radius: 8px;
  text-decoration: none;
  transition: background 0.2s, transform 0.15s;
}

.cta-link:hover {
  background: #163d73;
  transform: translateY(-1px);
}

/* ── Responsive ── */

@media (max-width: 600px) {
  .topbar { padding: 0 14px; height: 48px; }
  .topbar-logo { height: 20px; }
  .topbar-menu { display: none; }
  .topbar-burger { display: block; }

  .hub-logo { width: 80px; }

  .node {
    width: 90px;
    height: 90px;
  }

  .node-icon { width: 24px; height: 24px; }
  .node-label { font-size: 9px; }

  .node-1 { top: calc(50% - 150px); }
  .node-2 { left: calc(50% + 150px); }
  .node-3 { top: calc(50% + 150px); }
  .node-4 { left: calc(50% - 150px); }

  .connector { display: none; }

  .cta-bubble {
    right: 16px;
    left: 16px;
    bottom: 40px;
    max-width: none;
  }
}
