:root {
  --bg: #f4f5f3;
  --panel: #ffffff;
  --text: #14171b;
  --muted: #6b7078;
  --accent: #2489ff;
  --accent-secondary: #2cc9cd;
  --accent-light: #e6f5ff;
  --border: rgba(20, 23, 27, 0.08);
  --success: #2e7d32;
  --warning: #b26a00;
  --error: #b3261e;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Inter", "Source Sans 3", "Segoe UI", sans-serif;
  background: radial-gradient(circle at 10% -10%, #e7f4ff, var(--bg) 55%),
    radial-gradient(circle at 90% -20%, rgba(44, 201, 205, 0.2), transparent 60%);
  color: var(--text);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: "Manrope", "Inter", "Source Sans 3", sans-serif;
  margin: 0 0 12px;
  font-weight: 600;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 22px 28px;
  background: rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid rgba(20, 23, 27, 0.06);
  backdrop-filter: blur(12px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand {
  font-weight: 700;
  letter-spacing: 0.5px;
  font-size: 1.1rem;
}

.brand a {
  display: inline-flex;
  align-items: center;
}

.brand img {
  height: 50px;
  width: auto;
  display: block;
}

.public-nav {
  display: flex;
  gap: 22px;
  align-items: center;
  font-size: 0.95rem;
}

.public-nav a {
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
}

.public-nav-group {
  position: relative;
  font-weight: 500;
  color: var(--text);
}

.public-nav-label {
  display: inline-flex;
  gap: 6px;
  align-items: center;
}

.public-nav-sub {
  position: absolute;
  top: 25px;
  left: 0;
  background: var(--panel);
  border: 1px solid rgba(20, 23, 27, 0.08);
  border-radius: 8px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.08);
  padding: 8px;
  display: none;
  min-width: 180px;
  z-index: 20;
}

.public-nav-group:hover .public-nav-sub,
.public-nav-sub:hover {
  display: grid;
  gap: 6px;
}

.public-nav-sub a {
  padding: 6px 8px;
  border-radius: 6px;
}

.public-nav-sub a:hover {
  background: var(--accent-light);
}

.subtle-link {
  color: var(--muted);
  font-weight: 500;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.role-pill {
  background: var(--accent-light);
  color: var(--accent);
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.8rem;
  letter-spacing: 0.5px;
}

.link-button,
.sidebar-nav a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.copy-button {
  background: none;
  border: none;
  color: var(--accent);
  cursor: pointer;
  font-weight: 500;
  padding: 0;
}

.cta-button {
  background: var(--accent);
  color: #fff;
  text-decoration: none;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 600;
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.cta-button:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.2);
}

.nav-toggle {
  display: none;
  background: #f2f4f7;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px 12px;
  font-weight: 600;
}

.app-shell {
  display: grid;
  grid-template-columns: 220px 1fr;
  min-height: calc(100vh - 70px);
}

.app-shell.no-nav {
  grid-template-columns: 1fr;
}

.sidebar {
  padding: 24px 16px;
  border-right: 1px solid var(--border);
  background: #f9fafb;
}

.sidebar-title {
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 1px;
  color: var(--muted);
  margin-bottom: 12px;
}

.sidebar-nav {
  display: grid;
  gap: 10px;
}

.nav-link {
  padding: 8px 10px;
  border-radius: 6px;
}

.nav-link:hover {
  background: var(--accent-light);
}

.content {
  max-width: 1200px;
  margin: 24px auto;
  padding: 0 24px 40px;
  width: 100%;
}

.hero {
  position: relative;
  display: grid;
  gap: 28px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.9fr);
  padding: 48px 0 28px;
  margin-bottom: 28px;
}

.hero h1 {
  font-size: 3rem;
  margin: 0;
}

.hero p {
  max-width: 680px;
  margin: 0;
  color: var(--muted);
  font-size: 1.1rem;
}

.hero-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.hero-accent {
  position: absolute;
  top: -10px;
  left: -40px;
  width: 260px;
  height: 160px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.18), transparent 70%);
  filter: blur(6px);
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-media {
  position: relative;
  z-index: 1;
  margin-top: 12px;
}

.hero-media img {
  width: 100%;
  height: auto;
  border-radius: 18px;
  display: block;
}

.section {
  margin-bottom: 24px;
}

.section-title {
  font-size: 1.4rem;
  margin-bottom: 8px;
}

.list-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.numbered-steps {
  display: grid;
  gap: 12px;
}

.step {
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fbfbfb;
}

.flow {
  display: grid;
  gap: 12px;
}

.flow-step {
  display: flex;
  gap: 16px;
  align-items: center;
  font-size: 1.05rem;
}

.flow-num {
  font-size: 1.8rem;
  font-weight: 600;
  color: var(--accent);
  min-width: 28px;
}

.chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  padding: 8px 12px;
  background: rgba(20, 23, 27, 0.04);
  border-radius: 10px;
  font-size: 0.95rem;
}

.split {
  display: grid;
  gap: 24px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr);
  align-items: center;
}

.section-media img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  display: block;
}

.section-media.small {
  max-width: 360px;
}

.who-wrap {
  display: grid;
  gap: 20px;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.7fr);
  align-items: center;
}

.callout {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
  border-top: 1px solid rgba(20, 23, 27, 0.08);
  border-bottom: 1px solid rgba(20, 23, 27, 0.08);
}

.callout-title {
  font-size: 1.6rem;
}

.footer {
  border-top: 1px solid var(--border);
  padding: 24px 0 40px;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.panel {
  background: var(--panel);
  border: none;
  border-radius: 14px;
  padding: 20px;
  margin-bottom: 20px;
  box-shadow: 0 12px 30px rgba(20, 23, 27, 0.08);
}

.surface {
  background: var(--panel);
  border-radius: 12px;
  padding: 18px;
  box-shadow: 0 10px 30px rgba(20, 23, 27, 0.06);
}

.is-hidden {
  display: none;
}

.surface + .surface {
  margin-top: 16px;
}

.grid .surface + .surface {
  margin-top: 0;
}

.stat-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  margin-bottom: 16px;
}

.stat {
  padding: 16px;
  border-radius: 12px;
  background: rgba(20, 23, 27, 0.03);
}

.stat-title {
  font-size: 0.85rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.stat-value {
  font-size: 1.6rem;
  font-weight: 600;
}

.section form.stack {
  max-width: 520px;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 16px;
  gap: 16px;
}

.page-header .page-title {
  font-size: 1.9rem;
  margin-bottom: 4px;
}

.page-header .page-description {
  color: var(--muted);
  margin: 0;
}

.page-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.page-actions.align-right {
  margin-left: auto;
  justify-content: flex-end;
}

.button-secondary {
  background: #f2f4f7;
  color: var(--text);
  border: 1px solid var(--border);
}

.button-danger {
  background: #fdecea;
  color: var(--error);
  border: 1px solid #f2c9c5;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}

.surface + .grid,
.grid + .surface {
  margin-top: 16px;
}

.stack {
  display: grid;
  gap: 10px;
}

.inline-form {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.inline-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
}

.form-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.form-actions-right {
  display: flex;
  justify-content: flex-end;
}

.text-right {
  text-align: right;
}

.text-center {
  text-align: center;
}

.row-canceled {
  background: #fff4f4;
  color: #7d2b2b;
}

.row-covered {
  background: #fff7e6;
  color: #7a4a00;
}

.info-tip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.info-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1px solid currentColor;
  font-size: 11px;
  line-height: 1;
  font-weight: 600;
}

.info-tooltip {
  position: absolute;
  left: 0;
  top: 100%;
  margin-top: 6px;
  padding: 6px 8px;
  background: #1f1f1f;
  color: #fff;
  border-radius: 6px;
  font-size: 12px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transform: translateY(-4px);
  transition: opacity 150ms ease, transform 150ms ease;
  z-index: 2;
}

.info-tip:hover .info-tooltip {
  opacity: 1;
  transform: translateY(0);
}

label {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
}

input, select, button, textarea {
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px solid var(--border);
  font-size: 0.95rem;
}

label.checkbox-field {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.95rem;
}

input[type="checkbox"] {
  appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  border: 1px solid var(--border);
  background: #fff;
  display: inline-block;
  position: relative;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

input[type="checkbox"]:checked {
  background: var(--accent);
  border-color: var(--accent);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 10'%3E%3Cpath fill='white' d='M4.2 7.2L1.5 4.5L0.4 5.6L4.2 9.4L11.6 2L10.5 0.9Z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 12px 10px;
}

input[type="checkbox"]:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(36, 137, 255, 0.2);
}

.password-field {
  position: relative;
  display: flex;
  align-items: center;
}

.password-field input {
  width: 100%;
  padding-right: 40px;
}

.password-toggle {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: transparent;
  padding: 4px;
  color: var(--muted);
  cursor: pointer;
}

.password-toggle:hover {
  color: var(--text);
}

.password-toggle svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  display: block;
}

.password-toggle .icon-eye-off {
  display: none;
}

.password-toggle.is-visible .icon-eye {
  display: none;
}

.password-toggle.is-visible .icon-eye-off {
  display: block;
}

button {
  background: var(--accent);
  color: #fff;
  border: none;
  cursor: pointer;
}

button:hover {
  opacity: 0.9;
}

.link-button {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

.muted {
  color: var(--muted);
}

.messages {
  margin-bottom: 16px;
}

.message {
  padding: 10px 12px;
  border-radius: 6px;
  margin-bottom: 8px;
}

.message-success {
  background: #e6f4ea;
  color: var(--success);
}

.message-error {
  background: #fdecea;
  color: var(--error);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-right: 10px;
}

.status-success {
  background: #e6f4ea;
  color: var(--success);
  border: 1px solid #cce8d3;
}

.status-muted {
  background: rgba(15, 23, 42, 0.06);
  color: var(--muted);
  border: 1px solid var(--border);
}

.highlight {
  background: var(--accent-light);
  padding: 12px;
  border-radius: 6px;
}

.feature-list {
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.5;
}

.feature-list li {
  margin: 4px 0;
}

.plan-picker {
  display: grid;
  gap: 12px;
}

.plan-picker-title {
  font-size: 0.9rem;
  font-weight: 600;
}

.plan-scroll {
  overflow-x: auto;
  padding: 8px 8px 14px;
}

.plan-picker .grid {
  display: flex;
  gap: 16px;
  flex-wrap: nowrap;
  overflow: visible;
}

.plan-option {
  display: block;
}

.plan-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.plan-card {
  cursor: pointer;
  min-width: 240px;
  border: 2px solid transparent;
  box-sizing: border-box;
  transition: transform 0.15s ease, box-shadow 0.15s ease, border-color 0.15s ease;
}

.plan-card-title {
  font-size: 1rem;
  font-weight: 600;
}

.plan-card-price {
  margin-top: 6px;
  font-size: 1.1rem;
}

.plan-option input:checked + .plan-card {
  border-color: var(--accent);
  background: var(--accent-light);
  box-shadow: 0 18px 38px rgba(47, 99, 209, 0.24);
  transform: translateY(-2px);
}

.plan-option:hover .plan-card {
  border-color: rgba(47, 99, 209, 0.35);
}

.mono {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.9rem;
  white-space: pre-wrap;
}

table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 10px;
}

table th,
table td {
  border-bottom: 1px solid var(--border);
  padding: 8px;
  text-align: left;
  font-size: 0.9rem;
}

@media (max-width: 720px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: none;
    border-bottom: 1px solid var(--border);
  }

  .content {
    padding: 0 16px 32px;
  }

  .public-nav {
    display: none;
    gap: 10px;
    width: 100%;
    padding: 12px 0;
  }

  .public-nav.is-open {
    display: grid;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  .topbar-meta {
    width: 100%;
    justify-content: space-between;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .public-nav-group {
    width: 100%;
  }

  .public-nav-sub {
    position: static;
    display: grid;
    box-shadow: none;
    border: none;
    padding: 6px 0 0;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .split {
    grid-template-columns: 1fr;
  }

  .who-wrap {
    grid-template-columns: 1fr;
  }
}
