* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  background: #020617;
  color: #e5e7eb;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Header */

.site-header {
  border-bottom: 1px solid #111827;
  background: radial-gradient(circle at top left, #111827 0, #020617 65%);
  padding: 12px 24px;
}

.site-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.site-title {
  font-size: 22px;
  font-weight: 600;
  margin: 0 0 4px;
  display: block;
}

.site-subtitle {
  font-size: 13px;
  color: #9ca3af;
  margin: 0;
  line-height: 1.4;
}

.site-header-extra {
  min-width: 120px;
  text-align: right;
  font-size: 12px;
  color: #6b7280;
}

.site-header-extra {
  min-width: 120px;
  text-align: right;
  font-size: 12px;
  color: #6b7280;
}

/* Layout: Main + Sidebar */
.layout {
  flex: 1;
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
  align-items: start;
}

/* Main Column & Sidebar */
.main-column {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0; /* Prevent grid blowout */
}

.sidebar-column {
  display: flex;
  flex-direction: column;
  gap: 24px;
  min-width: 0;
}

/* Dashboard Card (Unified Control + Canvas) */
.dashboard-card {
  background: rgba(15, 23, 42, 0.6);
  border: 1px solid #1e293b;
  border-radius: 24px;
  padding: 24px;
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Dashboard Header: Controls & Info */
.dashboard-header {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  align-items: flex-start;
  justify-content: space-between;
  border-bottom: 1px solid #1e293b;
  padding-bottom: 20px;
}

.control-group {
  flex: 1;
  min-width: 280px;
}

.control-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #94a3b8;
  margin-bottom: 8px;
  font-weight: 600;
}

.info-group {
  flex: 1;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Dashboard Visualizer */
.dashboard-visualizer {
  position: relative;
  width: 100%;
}

.canvas-wrapper {
  width: 100%;
  max-width: 100%; /* Fill container */
  margin: 0;
  background: radial-gradient(circle at center, #0b1120 0, #020617 70%);
  border-radius: 16px;
  border: 1px solid #1e293b;
  overflow: hidden;
  aspect-ratio: 16 / 9; /* Wider aspect ratio */
  position: relative;
  box-shadow: inset 0 0 40px rgba(0,0,0,0.5);
}

/* Dashboard Footer: Launch & Timeline */
.dashboard-footer {
  display: flex;
  flex-direction: column;
  gap: 20px;
  border-top: 1px solid #1e293b;
  padding-top: 20px;
}

.launch-wrapper {
  display: flex;
  justify-content: center;
}

.timeline-wrapper {
  width: 100%;
}

.dashboard-note {
  font-size: 11px;
  color: #475569;
  text-align: center;
  margin-top: -10px;
}

/* Form & text basics */

label {
  display: block;
  font-size: 13px;
  margin-bottom: 6px;
  color: #e5e7eb;
}

select {
  width: 100%;
  padding: 8px 10px;
  border-radius: 6px;
  border: 1px solid #4b5563;
  background: #020617;
  color: #e5e7eb;
  font-size: 14px;
  outline: none;
}

select:focus {
  border-color: #60a5fa;
}

.profile-title {
  margin-top: 4px;
  font-weight: 600;
  font-size: 14px;
}

.profile-desc {
  font-size: 12px;
  color: #9ca3af;
  margin-top: 4px;
  line-height: 1.5;
}

/* Timeline Itinerary */
.timeline {
  position: relative;
  padding-left: 16px; /* Space for the line */
  margin-top: 10px;
  border-left: 2px solid #374151; /* The vertical line */
}

.timeline-item {
  position: relative;
  margin-bottom: 20px;
  padding-left: 16px;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-interval {
  padding-left: 16px;
  margin-bottom: 20px;
  color: #6b7280;
  font-size: 11px;
  font-style: italic;
  display: flex;
  align-items: center;
}

.timeline-interval::before {
  content: "";
  position: absolute;
  left: -4px; /* Center on the 2px border */
  width: 6px;
  height: 6px;
  background: #111827; /* Match bg to hide line segment if needed, or just let line show */
  /* Actually, let's just keep the line. */
  display: none; 
}

.timeline-marker {
  position: absolute;
  left: -22px; /* (16px padding + 2px border + 4px extra offset to center on line) */
  top: 4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #60a5fa; /* Blue dot */
  border: 2px solid #020617; /* Gap from line */
  z-index: 1;
  transition: background 0.3s ease, transform 0.3s ease;
}

.timeline-item.completed .timeline-marker {
  background: #10b981; /* Green dot */
  transform: scale(1.2);
}

.timeline-item.completed .timeline-label {
  color: #10b981; /* Green text */
}

.timeline-content {
  display: flex;
  flex-direction: column;
}

.timeline-label {
  font-size: 14px;
  font-weight: 600;
  color: #e5e7eb;
  margin-bottom: 0;
}

/* .timeline-date removed */

.timeline-duration {
  margin-top: 24px;
  padding-top: 12px;
  border-top: 1px dashed #374151;
  font-size: 13px;
  color: #e5e7eb;
  font-weight: 500;
}

.note {
  font-size: 11px;
  color: #6b7280;
  border-top: 1px solid #111827;
  padding-top: 8px;
  line-height: 1.4;
}

/* Center panel: canvas + key-node panel + explanatory text */

/* Center panel removed, styles merged into dashboard */
.center-panel {
  display: contents;
}

/* Canvas wrapper style updated in dashboard section */

.canvas-wrapper canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.space-legend {
  position: absolute;
  top: 10px;
  right: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.88);
  border: 1px solid #1f2937;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  font-size: 11px;
  color: #e5e7eb;
  display: grid;
  row-gap: 6px;
  z-index: 10;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: inline-block;
}

/* Key-node panel: below the canvas */

.key-node-overlay {
  margin-top: 8px;
  display: none;
}

.key-node-overlay.visible {
  display: block;
}

.key-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(15, 23, 42, 0.95);
  border: 1px solid #3b82f6;
  padding: 24px;
  border-radius: 12px;
  text-align: center;
  max-width: 320px;
  box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
  z-index: 20;
}

.key-node-card {
  background: rgba(15, 23, 42, 0.96);
  border-radius: 12px;
  padding: 10px 14px 12px;
  border: 1px solid #4b5563;
  max-width: 680px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.6);
}

.key-node-title {
  font-size: 14px;
  font-weight: 600;
  margin: 0 0 4px;
}

.key-node-body {
  font-size: 12px;
  color: #d1d5db;
  line-height: 1.5;
  margin: 0 0 10px;
}

.key-node-button {
  border: none;
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  background: #3b82f6;
  color: #f9fafb;
  transition: background 0.15s ease, transform 0.1s ease;
}

.key-node-button:hover {
  background: #2563eb;
  transform: translateY(-0.5px);
}

.key-node-button:active {
  transform: translateY(0.5px);
}

/* Content Cards (Unified Style) */
.content-card {
  margin-top: 16px;
  padding: 20px 24px;
  background: rgba(17, 24, 39, 0.7);
  border: 1px solid #1f2937;
  border-radius: 16px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.content-card:hover {
  border-color: #374151;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}

.content-card h1,
.content-card h2,
.content-card h3 {
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 600;
  color: #f3f4f6;
  letter-spacing: -0.01em;
}

.content-card p {
  margin: 0 0 12px;
  color: #9ca3af;
  font-size: 14px;
  line-height: 1.6;
}

.content-card p:last-child {
  margin-bottom: 0;
}

/* Specific adjustments for lists inside cards */
.content-card ul {
  margin: 8px 0 12px 20px;
  padding-left: 0;
  color: #d1d5db;
  font-size: 14px;
  line-height: 1.6;
}

.content-card li {
  margin-bottom: 6px;
}

.content-card strong {
  color: #e5e7eb;
  font-weight: 600;
}

/* FAQ Container adjustments for inside card */
.content-card .faq-container {
  gap: 8px;
}

.content-card .faq-item {
  background: rgba(31, 41, 55, 0.4);
  border: 1px solid rgba(55, 65, 81, 0.5);
  border-radius: 8px;
}

.content-card .faq-item:hover {
  background: rgba(55, 65, 81, 0.4);
  border-color: #4b5563;
}

.content-card .faq-question {
  padding: 10px 14px;
  font-size: 13px;
}

.content-card .faq-answer {
  padding: 0 14px 12px;
  font-size: 13px;
  color: #9ca3af;
  border-top-color: rgba(55, 65, 81, 0.5);
}

.keyword-hero {
  margin-top: 0;
}

/* Right panel: ad + related content */

/* Right panel removed, styles merged into sidebar */
.right-panel {
  display: contents;
}

.ad-slot {
  margin-bottom: 20px;
}


.ad-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #9ca3af;
  margin-bottom: 4px;
}

.ad-text {
  font-size: 12px;
  color: #9ca3af;
  line-height: 1.5;
  margin: 0;
}

.side-title {
  font-size: 15px;
  font-weight: 600;
  color: #f3f4f6;
  margin: 0 0 16px;
  text-align: center;
  letter-spacing: -0.01em;
}

.side-list {
  list-style: disc;
  padding-left: 18px;
  margin: 0;
  font-size: 12px;
  color: #9ca3af;
}

.side-list li {
  margin-bottom: 3px;
}

/* Delta-v Calculator */
.deltav-module {
  background: rgba(17, 24, 39, 0.6);
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  backdrop-filter: blur(4px);
}

.formula-box {
  background: #0f172a;
  padding: 12px;
  border-radius: 8px;
  margin-bottom: 20px;
  border: 1px solid #1e293b;
  box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.3);
}

.formula {
  font-family: "JetBrains Mono", "Fira Code", monospace;
  font-size: 13px;
  color: #34d399; /* Emerald 400 */
  margin: 0 0 6px;
  text-align: center;
  text-shadow: 0 0 5px rgba(52, 211, 153, 0.3);
}

.formula-desc {
  font-size: 11px;
  color: #94a3b8;
  margin: 0;
  text-align: center;
  font-style: italic;
}

.calc-group {
  margin-bottom: 16px;
}

.calc-group label {
  display: block;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #9ca3af;
  margin-bottom: 6px;
  font-weight: 600;
}

.calc-group select,
.calc-group input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid #374151;
  background: #1f2937;
  color: #f3f4f6;
  font-size: 13px;
  outline: none;
  transition: all 0.2s ease;
}

.calc-group select:focus,
.calc-group input:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 2px rgba(96, 165, 250, 0.2);
  background: #374151;
}

.calc-result {
  margin-top: 24px;
  padding: 16px;
  background: linear-gradient(145deg, rgba(16, 185, 129, 0.1), rgba(6, 95, 70, 0.1));
  border: 1px solid rgba(16, 185, 129, 0.2);
  border-radius: 12px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.calc-result::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #10b981, transparent);
  opacity: 0.5;
}

.result-label {
  display: block;
  color: #34d399;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
}

.result-value {
  display: block;
  color: #fff;
  font-weight: 800;
  font-size: 24px;
  text-shadow: 0 2px 10px rgba(16, 185, 129, 0.2);
  font-variant-numeric: tabular-nums;
}

.calc-note {
  font-size: 10px;
  color: #64748b;
  margin-top: 12px;
  text-align: center;
  border-top: 1px solid #1f2937;
  padding-top: 8px;
}

/* Footer */

.site-footer {
  border-top: 1px solid #111827;
  padding: 10px 24px;
  font-size: 11px;
  color: #6b7280;
  text-align: center;
  background: #020617;
}

.site-footer-text {
  margin: 0;
}

/* Responsive */

@media (max-width: 960px) {
  .layout {
    grid-template-columns: 1fr;
    padding: 16px;
    gap: 16px;
  }

  .dashboard-header {
    flex-direction: column;
    gap: 16px;
  }

  .control-group, .info-group {
    width: 100%;
    min-width: 0;
  }

  .canvas-wrapper {
    aspect-ratio: 4 / 3; /* Taller on mobile */
  }


  .canvas-wrapper {
    max-width: 100%;
  }

  .site-header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .site-header-extra {
    text-align: left;
  }
}

.site-branding {
  display: flex;
  align-items: center;
  gap: 16px;
}

.site-logo {
  height: 56px;
  width: auto;
  filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.5));
  flex-shrink: 0;
}

.site-text {
  display: flex;
  flex-direction: column;
}

/* Utilities */
.hidden {
  display: none !important;
}

/* Profile Details */
.profile-details {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid #374151;
  font-size: 13px;
  color: #d1d5db;
  line-height: 1.5;
}

.profile-section {
  margin-bottom: 12px;
}

.profile-label {
  font-weight: 700;
  color: #9ca3af;
  margin-right: 6px;
}

.profile-label.pro {
  color: #34d399; /* Green */
}

.profile-label.con {
  color: #f87171; /* Red */
}

/* FAQ System */
.faq-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

details.faq-item {
  background: rgba(17, 24, 39, 0.6);
  border: 1px solid #374151;
  border-radius: 8px;
  overflow: hidden;
  transition: background 0.2s ease;
}

details.faq-item:hover {
  background: rgba(31, 41, 55, 0.6);
}

summary.faq-question {
  padding: 12px 14px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  color: #e5e7eb;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
}

summary.faq-question::-webkit-details-marker {
  display: none;
}

summary.faq-question::after {
  content: '+';
  font-size: 16px;
  color: #9ca3af;
  font-weight: 400;
  margin-left: 8px;
}

details.faq-item[open] summary.faq-question::after {
  content: '-';
}

.faq-answer {
  padding: 0 14px 14px;
  font-size: 12px;
  color: #9ca3af;
  line-height: 1.5;
  border-top: 1px solid #374151;
  margin-top: 0;
  padding-top: 10px;
}

/* Launch Button */


.launch-button {
  background: linear-gradient(180deg, #ef4444 0%, #b91c1c 100%);
  color: white;
  font-size: 16px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  padding: 16px 32px;
  border: none;
  border-radius: 50px; /* Pill shape */
  cursor: pointer;
  box-shadow: 
    0 4px 0 #7f1d1d, /* Darker red shadow for 3D effect */
    0 10px 10px rgba(0, 0, 0, 0.4), /* Drop shadow */
    inset 0 1px 0 rgba(255, 255, 255, 0.3); /* Top highlight */
  transition: transform 0.1s, box-shadow 0.1s, filter 0.2s;
  position: relative;
  overflow: hidden;
  width: 100%;
  max-width: 280px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.launch-button::before {
  /* Shine effect */
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 50%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.2) 0%, rgba(255, 255, 255, 0) 100%);
  border-radius: 50px 50px 0 0;
}

.launch-button:hover:not(:disabled) {
  filter: brightness(1.1);
  transform: translateY(-1px);
  box-shadow: 
    0 5px 0 #7f1d1d,
    0 12px 12px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.launch-button:active:not(:disabled) {
  transform: translateY(4px);
  box-shadow: 
    0 0 0 #7f1d1d,
    0 2px 4px rgba(0, 0, 0, 0.4),
    inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.launch-button:disabled {
  background: #374151;
  color: #9ca3af;
  cursor: not-allowed;
  box-shadow: none;
  transform: none;
  filter: none;
}

/* Sidebar Card (Generic) */
.sidebar-card {
  background: rgba(17, 24, 39, 0.6);
  border: 1px solid #374151;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  backdrop-filter: blur(4px);
}

.side-text {
  font-size: 13px;
  color: #d1d5db;
  line-height: 1.5;
  margin: 0 0 12px;
}

.side-note {
  font-size: 11px;
  color: #94a3b8;
  font-style: italic;
  margin: 12px 0 0;
  border-top: 1px solid #374151;
  padding-top: 8px;
  text-align: center;
}
