/* ============================================================
   VPN MCP — Clean White Minimal
   ============================================================ */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg-primary:    #ffffff;
  --bg-secondary:  #f8fafc;
  --bg-card:       #ffffff;
  --bg-code:       #1e293b;
  --border:        #e2e8f0;
  --text-primary:  #0f172a;
  --text-secondary:#64748b;
  --text-muted:    #94a3b8;
  --accent:        #0d9488;
  --accent-hover:  #0f766e;
  --accent-light:  rgba(13, 148, 136, 0.06);
  --accent-red:    #dc2626;
  --font:          'Instrument Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --mono:          'JetBrains Mono', 'Fira Code', 'SF Mono', 'Cascadia Code', 'Consolas', monospace;
  --radius:        8px;
  --radius-lg:     12px;
  --transition:    0.2s ease;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: var(--font);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  min-height: 100vh;
  overflow-x: hidden;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font);
  color: var(--text-primary);
  line-height: 1.3;
}

h1 { font-size: 2.8rem; font-weight: 700; letter-spacing: -0.03em; }
h2 { font-size: 1.8rem; font-weight: 600; letter-spacing: -0.02em; margin-bottom: 1rem; }
h3 { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.5rem; }

p { color: var(--text-primary); }
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-hover); }

code, .mono { font-family: var(--mono); }

/* --- Layout --- */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

section {
  padding: 5rem 0;
}

/* --- Navigation --- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0.75rem 0;
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-family: var(--mono);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--accent);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.nav-brand .prompt {
  color: var(--text-muted);
  font-weight: 400;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.75rem;
  list-style: none;
}

.nav-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.3rem 0;
  position: relative;
  transition: color var(--transition);
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width var(--transition);
}

.nav-links a:hover { color: var(--accent); }
.nav-links a:hover::after { width: 100%; }
.nav-links a.active { color: var(--accent); }
.nav-links a.active::after { width: 100%; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 0.7rem 1.4rem;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--accent);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #ffffff;
}

.btn-secondary {
  background: transparent;
  color: var(--accent);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  border-color: var(--accent);
  background: var(--accent-light);
  color: var(--accent);
}

.btn-sm {
  padding: 0.5rem 1.1rem;
  font-size: 0.85rem;
  box-shadow: 0 1px 4px rgba(13, 148, 136, 0.25);
}

.btn-copy {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.3rem 0.6rem;
  font-size: 0.75rem;
  font-family: var(--mono);
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition);
}

.btn-copy:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-copy.copied {
  border-color: var(--accent);
  color: var(--accent);
}

/* --- Cards --- */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  transition: border-color var(--transition);
}

.card:hover {
  border-color: #cbd5e1;
}

/* --- Terminal Block --- */
.terminal {
  background: var(--bg-code);
  border-radius: var(--radius);
  overflow: hidden;
}

.terminal-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: rgba(255, 255, 255, 0.04);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.terminal-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.terminal-dot.red    { background: #ff5f57; }
.terminal-dot.yellow { background: #febc2e; }
.terminal-dot.green  { background: #28c840; }

.terminal-title {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: #64748b;
  margin-left: 0.5rem;
}

.terminal-body {
  padding: 1rem 1.25rem;
  font-family: var(--mono);
  font-size: 0.85rem;
  line-height: 1.8;
  overflow-x: auto;
}

.terminal-body .prompt-symbol {
  color: var(--accent);
  user-select: none;
}

.terminal-body .cmd { color: #e2e8f0; }
.terminal-body .output { color: #94a3b8; }
.terminal-body .success { color: #34d399; }
.terminal-body .error { color: #f87171; }
.terminal-body .info { color: #38bdf8; }
.terminal-body .dim { color: #475569; }

/* --- Code Blocks --- */
pre {
  background: var(--bg-code);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  font-family: var(--mono);
  font-size: 0.85rem;
  line-height: 1.7;
  overflow-x: auto;
  color: #cbd5e1;
}

pre .key   { color: #38bdf8; }
pre .str   { color: #34d399; }
pre .punct { color: #64748b; }

code {
  font-size: 0.85em;
  background: var(--accent-light);
  padding: 0.15em 0.4em;
  border-radius: 4px;
  color: var(--accent);
  border: 1px solid var(--border);
}

pre code {
  background: none;
  padding: 0;
  border: none;
  color: inherit;
}

/* --- Tables --- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--bg-card);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

th {
  background: var(--bg-secondary);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
}

td {
  padding: 0.7rem 1rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

tr:last-child td { border-bottom: none; }

tr:hover td {
  background: var(--accent-light);
}

td code {
  font-size: 0.85rem;
  white-space: nowrap;
}

/* --- Comparison Layout --- */
.comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.comparison-panel {
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.comparison-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.comparison-panel.without .comparison-label {
  color: var(--accent-red);
}

.comparison-panel.with .comparison-label {
  color: var(--accent);
}

/* --- Section Headers --- */
.section-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 0.5rem;
  display: block;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
  max-width: 650px;
  margin-bottom: 2rem;
}

/* --- Steps (How It Works) --- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
}

.step {
  position: relative;
}

.step-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: rgba(13, 148, 136, 0.12);
  line-height: 1;
  margin-bottom: 0.75rem;
}

.step h3 {
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.step p {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* --- Node Cards --- */
.nodes-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-top: 2rem;
}

.node-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem 1.5rem;
  text-align: center;
  transition: border-color var(--transition);
}

.node-card:hover {
  border-color: var(--accent);
}

.node-card .node-region {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.node-card .node-type {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.node-icon-symbol {
  font-family: var(--mono);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-light);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  letter-spacing: 0.05em;
}

/* --- Pricing --- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 2rem;
  align-items: start;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  position: relative;
  display: flex;
  flex-direction: column;
}

.pricing-tier-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.pricing-amount {
  font-size: 3rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.pricing-unit {
  font-size: 1rem;
  color: var(--text-secondary);
  font-weight: 400;
}

.pricing-period {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 400;
}

.pricing-details {
  list-style: none;
  margin: 1.5rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.pricing-details li {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.pricing-details li span {
  color: var(--accent);
  font-weight: 600;
  margin-right: 0.3rem;
}

.pricing-cta-area {
  margin-top: auto;
  padding-top: 1rem;
}

.pricing-badge {
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.25rem 1rem;
  border-radius: 0 0 6px 6px;
}

.pricing-card--featured {
  border-color: var(--accent);
  background: linear-gradient(180deg, rgba(13, 148, 136, 0.03) 0%, #ffffff 100%);
  box-shadow: 0 0 0 1px var(--accent), 0 4px 20px rgba(13, 148, 136, 0.08);
}

.pricing-card--featured .pricing-amount {
  color: var(--accent);
}

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0;
  text-align: center;
  background: var(--bg-secondary);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 1rem;
  list-style: none;
}

.footer-links a {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.footer-links a:hover { color: var(--accent); }

.footer-copy {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* --- Setup Page --- */
.setup-content {
  max-width: 800px;
  margin: 0 auto;
}

.setup-section {
  margin-bottom: 3rem;
}

.setup-section h2 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.setup-section h2 .step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--accent);
  color: #ffffff;
  font-size: 0.8rem;
  font-weight: 700;
  flex-shrink: 0;
}

.setup-section p {
  margin-bottom: 1rem;
  color: var(--text-secondary);
}

.install-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: 1rem 0;
}

.install-option label {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 0.3rem;
}

.config-preview {
  position: relative;
}

.config-preview .btn-copy {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
}

/* --- Utility --- */
.text-accent { color: var(--accent); }
.text-muted  { color: var(--text-muted); }
.text-center { text-align: center; }

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* --- Animations --- */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

.reveal {
  opacity: 0;
}

.reveal.visible {
  animation: fadeUp 0.6s ease forwards;
}

.reveal-stagger.visible > *:nth-child(1) { animation: fadeUp 0.6s ease 0s forwards; opacity: 0; }
.reveal-stagger.visible > *:nth-child(2) { animation: fadeUp 0.6s ease 0.1s forwards; opacity: 0; }
.reveal-stagger.visible > *:nth-child(3) { animation: fadeUp 0.6s ease 0.2s forwards; opacity: 0; }
.reveal-stagger.visible > *:nth-child(4) { animation: fadeUp 0.6s ease 0.3s forwards; opacity: 0; }

/* --- Terminal Cursor Blink --- */
.cursor-blink::after {
  content: '\2588';
  animation: blink 1s step-end infinite;
  color: var(--accent);
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* --- API Examples Grid --- */
.api-examples {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin-top: 1.5rem;
}

.api-examples .card {
  margin-top: 0;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.4rem; }
  section { padding: 3.5rem 0; }

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

  .steps {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .nodes-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .install-options {
    grid-template-columns: 1fr;
  }

  .api-examples {
    grid-template-columns: 1fr;
  }

  .nav-links {
    gap: 0.75rem;
  }

  .nav-links a {
    font-size: 0.8rem;
  }

  .pricing-amount {
    font-size: 2.2rem;
  }

  .terminal-body {
    font-size: 0.75rem;
  }

  pre {
    font-size: 0.75rem;
  }
}

@media (max-width: 480px) {
  h1 { font-size: 1.6rem; }

  .container { padding: 0 1rem; }

  .nav-brand .prompt { display: none; }

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

  .pricing-card { padding: 1.5rem; }

  .footer-links { flex-direction: column; gap: 0.75rem; }
}
