﻿/* ==========================================================================
   0-4-1 (صفرچهلویک) | Next-Gen Enterprise Infrastructure Stylesheet
   Designed to compete with Telco & Cloud Giants (Asiatech, ArvanCloud, etc.)
   Features: Dual Theme (Dark/Light), Terminal CLI, Live Speedometer,
   Comparison Matrix, Mega Menu, Glassmorphism & High-tech Glow.
   ========================================================================== */

@import url('https://cdn.jsdelivr.net/gh/rastikerdar/vazirmatn@v33.003/Vazirmatn-font-face.css');

:root {
  /* Default Light Theme */
  --primary: #1d4ed8;
  --primary-hover: #1e40af;
  --primary-light: #eff6ff;
  --primary-gradient: linear-gradient(135deg, #1d4ed8 0%, #2563eb 50%, #0284c7 100%);
  --cyan-glow: #06b6d4;
  --accent-cyan: #0284c7;
  --accent-emerald: #059669;
  --accent-emerald-light: #ecfdf5;
  --accent-purple: #7c3aed;
  
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --bg-subtle: #f1f5f9;
  --bg-header: rgba(255, 255, 255, 0.92);
  --border-subtle: #e2e8f0;
  --border-focus: #bfdbfe;
  
  --text-main: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  
  --shadow-xs: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-sm: 0 2px 4px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 4px 14px -2px rgba(15, 23, 42, 0.07), 0 2px 6px -2px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 12px 28px -6px rgba(15, 23, 42, 0.09), 0 4px 10px -3px rgba(15, 23, 42, 0.04);
  --shadow-xl: 0 22px 45px -12px rgba(15, 23, 42, 0.14);
  --shadow-primary: 0 8px 20px -4px rgba(29, 78, 216, 0.28);
  
  --terminal-bg: #090d16;
  --terminal-header: #131b2e;
  --terminal-text: #e2e8f0;
  --terminal-border: #1e293b;
  
  --container-max: 1260px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
}

/* Dark Theme Variables (Enabled via [data-theme="dark"]) */
[data-theme="dark"] {
  --primary: #3b82f6;
  --primary-hover: #60a5fa;
  --primary-light: rgba(59, 130, 246, 0.15);
  --primary-gradient: linear-gradient(135deg, #2563eb 0%, #3b82f6 50%, #06b6d4 100%);
  --cyan-glow: #22d3ee;
  --accent-cyan: #38bdf8;
  --accent-emerald: #10b981;
  --accent-emerald-light: rgba(16, 185, 129, 0.15);
  --accent-purple: #a855f7;
  
  --bg-main: #07090e;
  --bg-card: #0d121d;
  --bg-subtle: #131a29;
  --bg-header: rgba(7, 9, 14, 0.88);
  --border-subtle: #1e293b;
  --border-focus: #3b82f6;
  
  --text-main: #f8fafc;
  --text-secondary: #cbd5e1;
  --text-muted: #94a3b8;
  --text-light: #64748b;
  
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-sm: 0 2px 6px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 6px 16px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 14px 32px rgba(0, 0, 0, 0.6);
  --shadow-xl: 0 25px 50px rgba(0, 0, 0, 0.7);
  --shadow-primary: 0 8px 25px -4px rgba(59, 130, 246, 0.35);
  
  --terminal-bg: #030508;
  --terminal-header: #0d121d;
  --terminal-border: #1e293b;
}

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

html {
  font-family: 'Vazirmatn', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  font-size: 16px;
  scroll-behavior: smooth;
  direction: rtl;
  text-align: right;
  background-color: var(--bg-main);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--transition-normal), color var(--transition-normal);
}

body {
  line-height: 1.65;
  overflow-x: hidden;
  position: relative;
  background-color: var(--bg-main);
}

/* High-Tech Background Mesh */
.bg-grid-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 850px;
  background-image: radial-gradient(rgba(59, 130, 246, 0.12) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 40%, rgba(0,0,0,0));
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 40%, rgba(0,0,0,0));
  pointer-events: none;
  z-index: 0;
}

.glowing-orb {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 700px;
  height: 450px;
  background: radial-gradient(ellipse at center, rgba(37, 99, 235, 0.16) 0%, rgba(6, 182, 212, 0.08) 50%, transparent 75%);
  filter: blur(60px);
  pointer-events: none;
  z-index: 0;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all var(--transition-fast);
}

ul {
  list-style: none;
}

img, svg {
  display: block;
  max-width: 100%;
}

button, input, select {
  font-family: inherit;
  font-size: inherit;
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  position: relative;
  z-index: 1;
}

/* Top Announcement Bar */
.announcement-bar {
  background: #090d16;
  color: #f8fafc;
  padding: 0.55rem 1rem;
  font-size: 0.82rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  z-index: 50;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.announcement-bar .badge {
  background: rgba(37, 99, 235, 0.35);
  color: #60a5fa;
  border: 1px solid rgba(96, 165, 250, 0.35);
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  margin-left: 0.5rem;
}

.announcement-bar .support-phone {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #cbd5e1;
  font-weight: 600;
  direction: ltr;
}

.announcement-bar .support-phone:hover {
  color: #38bdf8;
}

/* Site Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--bg-header);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--transition-normal);
}

.site-header.scrolled {
  box-shadow: var(--shadow-sm);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
}

/* Brand Logo */
.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  text-decoration: none;
}

.brand-icon-box {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 900;
  font-size: 1.15rem;
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.35);
  letter-spacing: -0.5px;
  position: relative;
  overflow: hidden;
}

.brand-icon-box::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.3) 50%, transparent 60%);
  animation: shine 4s infinite;
}

@keyframes shine {
  0% { transform: translateY(-100%); }
  30%, 100% { transform: translateY(100%); }
}

.brand-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.brand-subtitle {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Nav Menu */
.nav-menu {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}

.nav-link {
  font-size: 0.94rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 0.5rem 0.25rem;
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.nav-link:hover {
  color: var(--primary);
}

.badge-hot {
  font-size: 0.65rem;
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.25);
  padding: 0.1rem 0.45rem;
  border-radius: var(--radius-full);
  font-weight: 700;
}

.badge-telco {
  font-size: 0.65rem;
  background: rgba(6, 182, 212, 0.15);
  color: #0284c7;
  border: 1px solid rgba(6, 182, 212, 0.25);
  padding: 0.1rem 0.45rem;
  border-radius: var(--radius-full);
  font-weight: 700;
}

/* Header Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Theme Switcher Button */
.theme-toggle-btn {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.theme-toggle-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--bg-subtle);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  padding: 0.65rem 1.25rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  border: 1px solid transparent;
  font-size: 0.92rem;
  line-height: 1.2;
}

.btn-primary {
  background: var(--primary-gradient);
  color: #ffffff;
  box-shadow: var(--shadow-primary);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px -4px rgba(37, 99, 235, 0.45);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-secondary);
  border-color: var(--border-subtle);
  box-shadow: var(--shadow-xs);
}

.btn-secondary:hover {
  background: var(--bg-subtle);
  color: var(--text-main);
  border-color: #94a3b8;
}

.mobile-toggle {
  display: none;
  background: transparent;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-main);
}

/* Hero Section */
.hero-section {
  padding: 4.5rem 0 3.5rem;
  position: relative;
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 3.5rem;
  align-items: center;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 0.35rem 0.95rem 0.35rem 0.5rem;
  border-radius: var(--radius-full);
  box-shadow: var(--shadow-xs);
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 1.25rem;
}

.hero-pill-badge {
  background: var(--accent-emerald-light);
  color: var(--accent-emerald);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.15rem 0.55rem;
  border-radius: var(--radius-full);
}

.hero-title {
  font-size: 3.1rem;
  font-weight: 900;
  line-height: 1.25;
  color: var(--text-main);
  letter-spacing: -0.025em;
  margin-bottom: 1.25rem;
}

.hero-title .highlight {
  background: linear-gradient(135deg, #2563eb, #06b6d4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: 1.12rem;
  color: var(--text-secondary);
  line-height: 1.85;
  margin-bottom: 2rem;
  max-width: 600px;
}

.hero-buttons {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.75rem;
}

.hero-stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
}

.hero-stat-item .stat-num {
  font-size: 1.85rem;
  font-weight: 900;
  color: var(--text-main);
  display: flex;
  align-items: baseline;
  gap: 0.2rem;
}

.hero-stat-item .stat-num span {
  color: var(--primary);
  font-size: 1.4rem;
}

.hero-stat-item .stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 600;
}

/* CLI Interactive Terminal Widget */
.terminal-card {
  background: var(--terminal-bg);
  border: 1px solid var(--terminal-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.terminal-header {
  background: var(--terminal-header);
  padding: 0.75rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--terminal-border);
}

.terminal-dots {
  display: flex;
  gap: 6px;
}

.t-dot {
  width: 11px;
  height: 11px;
  border-radius: 50%;
}
.t-dot.red { background: #ef4444; }
.t-dot.yellow { background: #eab308; }
.t-dot.green { background: #10b981; }

.terminal-title {
  color: #94a3b8;
  font-size: 0.78rem;
  direction: ltr;
}

.terminal-tabs {
  display: flex;
  gap: 0.5rem;
}

.t-tab {
  background: transparent;
  border: none;
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
}
.t-tab.active {
  color: #38bdf8;
  background: rgba(56, 189, 248, 0.12);
}

.terminal-body {
  padding: 1.25rem;
  color: #f1f5f9;
  font-size: 0.86rem;
  line-height: 1.7;
  direction: ltr;
  text-align: left;
  min-height: 200px;
}

.terminal-line {
  margin-bottom: 0.4rem;
}

.terminal-prompt {
  color: #10b981;
  font-weight: 700;
  margin-right: 0.5rem;
}

.terminal-cmd {
  color: #f8fafc;
}

.terminal-output {
  color: #94a3b8;
  padding-left: 1rem;
}

.terminal-success {
  color: #34d399;
  font-weight: 700;
}

.terminal-highlight {
  color: #38bdf8;
}

/* Giant Comparison Matrix (رقابت با آسیاتک و ابر آروان) */
.comparison-section {
  padding: 5rem 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.comparison-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  background: var(--bg-main);
  box-shadow: var(--shadow-md);
}

.comparison-table {
  width: 100%;
  border-collapse: collapse;
  text-align: right;
  min-width: 720px;
}

.comparison-table th, .comparison-table td {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
}

.comparison-table th {
  background: var(--bg-subtle);
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
}

.comparison-table th.brand-col {
  background: var(--primary-light);
  color: var(--primary);
  border-left: 2px solid var(--primary);
  border-right: 2px solid var(--primary);
}

.comparison-table td.brand-col {
  background: rgba(37, 99, 235, 0.04);
  font-weight: 700;
  color: var(--primary);
  border-left: 2px solid var(--primary);
  border-right: 2px solid var(--primary);
}

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

.comparison-feature-name {
  font-weight: 700;
  color: var(--text-main);
  display: block;
}

.comparison-feature-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.badge-win {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: var(--accent-emerald);
  font-weight: 800;
}

.badge-lose {
  color: var(--text-light);
}

/* Speedometer / Datacenter Speed Test Section */
.speedtest-section {
  padding: 5rem 0;
  position: relative;
}

.speedtest-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.75rem;
  box-shadow: var(--shadow-lg);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.speed-gauge-wrap {
  text-align: center;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.speed-dial {
  width: 240px;
  height: 240px;
  border-radius: 50%;
  border: 10px solid var(--border-subtle);
  border-top-color: var(--primary);
  border-right-color: var(--cyan-glow);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 30px rgba(37, 99, 235, 0.15);
  animation: rotate-subtle 8s linear infinite;
  margin-bottom: 1.5rem;
}

@keyframes rotate-subtle {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.speed-inner-content {
  transform: rotate(0deg); /* counter parent rotation via JS or container */
  text-align: center;
}

.speed-val-display {
  font-size: 3rem;
  font-weight: 900;
  color: var(--text-main);
  line-height: 1;
}

.speed-unit {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: 0.5px;
}

.speed-metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  width: 100%;
}

.speed-metric-item {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.85rem;
  text-align: center;
}

.speed-metric-item .lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.speed-metric-item .val {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
}

.download-files-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.dl-file-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.75rem 0.5rem;
  text-align: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.dl-file-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* Domain Search Section */
.domain-section {
  padding: 3rem 0 4.5rem;
}

.domain-search-box {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
}

.domain-search-header {
  text-align: center;
  max-width: 650px;
  margin: 0 auto 2rem;
}

.domain-search-header h3 {
  font-size: 1.85rem;
  font-weight: 900;
  color: var(--text-main);
  margin-bottom: 0.5rem;
}

.domain-input-group {
  display: flex;
  gap: 0.5rem;
  background: var(--bg-subtle);
  border: 2px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.35rem;
  transition: border-color var(--transition-fast);
}

.domain-input-group:focus-within {
  border-color: var(--primary);
  background: var(--bg-card);
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.domain-input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0.85rem 1.25rem;
  font-size: 1.1rem;
  color: var(--text-main);
  outline: none;
  direction: ltr;
  text-align: right;
}

.domain-tld-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.85rem;
  margin-top: 1.75rem;
}

.tld-pill {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-full);
  padding: 0.45rem 1.15rem;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.tld-pill:hover, .tld-pill.active {
  background: var(--bg-card);
  border-color: var(--primary);
  color: var(--primary);
  box-shadow: var(--shadow-xs);
}

.tld-pill .tld-name {
  font-weight: 800;
  direction: ltr;
}

.tld-pill .tld-badge {
  background: rgba(239, 68, 68, 0.15);
  color: #ef4444;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: var(--radius-full);
}

.domain-result-box {
  margin-top: 1.5rem;
  display: none;
  border-radius: var(--radius-md);
  padding: 1.2rem 1.5rem;
  font-weight: 700;
  font-size: 0.95rem;
}

.domain-result-box.available {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--accent-emerald-light);
  color: var(--accent-emerald);
  border: 1px solid var(--accent-emerald);
}

/* Interactive Cloud VPS Configurator */
.calculator-section {
  padding: 5rem 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.section-head {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3.5rem;
}

.section-tag {
  color: var(--primary);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  margin-bottom: 0.65rem;
  display: inline-block;
  background: var(--primary-light);
  padding: 0.25rem 0.85rem;
  border-radius: var(--radius-full);
}

.section-title {
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--text-main);
  letter-spacing: -0.02em;
  margin-bottom: 0.85rem;
}

.section-desc {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

.calculator-card {
  background: var(--bg-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.75rem;
  box-shadow: var(--shadow-md);
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 3rem;
}

.calc-slider-group {
  margin-bottom: 2rem;
}

.calc-slider-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
}

.calc-label {
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.calc-val-display {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--primary);
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  padding: 0.25rem 0.85rem;
  border-radius: var(--radius-sm);
}

.calc-range {
  width: 100%;
  height: 8px;
  -webkit-appearance: none;
  appearance: none;
  background: #cbd5e1;
  border-radius: var(--radius-full);
  outline: none;
  cursor: pointer;
}

[data-theme="dark"] .calc-range {
  background: #1e293b;
}

.calc-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--primary);
  border: 3px solid #ffffff;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.4);
  cursor: pointer;
  transition: transform var(--transition-fast);
}

.calc-range::-webkit-slider-thumb:hover {
  transform: scale(1.18);
}

.location-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.85rem;
}

.loc-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.loc-btn:hover, .loc-btn.active {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.calc-summary {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 2.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: var(--shadow-md);
}

.summary-title {
  font-size: 1.3rem;
  font-weight: 900;
  color: var(--text-main);
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-subtle);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.65rem 0;
  font-size: 0.94rem;
  color: var(--text-secondary);
  border-bottom: 1px dashed var(--border-subtle);
}

.summary-row:last-child {
  border-bottom: none;
}

.summary-row span:last-child {
  font-weight: 800;
  color: var(--text-main);
}

.calc-price-box {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.35rem;
  text-align: center;
  margin-bottom: 1.35rem;
}

.calc-price-monthly {
  font-size: 2.1rem;
  font-weight: 900;
  color: var(--primary);
}

.calc-price-monthly span {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-muted);
}

/* Services Grid */
.services-section {
  padding: 5rem 0;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.85rem;
}

.service-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  transition: all var(--transition-normal);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}

.service-icon-box {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-md);
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.35rem;
}

.service-card h4 {
  font-size: 1.3rem;
  font-weight: 900;
  color: var(--text-main);
  margin-bottom: 0.75rem;
}

.service-card p {
  font-size: 0.93rem;
  color: var(--text-secondary);
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

.service-features-list {
  margin-bottom: 1.5rem;
}

.service-features-list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.86rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.service-features-list li svg {
  color: var(--accent-emerald);
  flex-shrink: 0;
}

.service-link {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.service-link:hover {
  gap: 0.75rem;
}

/* Datacenter Network Grid */
.network-section {
  padding: 5rem 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
}

.network-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

.datacenter-list {
  display: flex;
  flex-direction: column;
  gap: 0.95rem;
}

.dc-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 1.15rem 1.35rem;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.dc-item:hover, .dc-item.active {
  background: var(--bg-card);
  border-color: var(--primary);
  box-shadow: var(--shadow-sm);
}

.dc-info {
  display: flex;
  align-items: center;
  gap: 0.85rem;
}

.dc-name {
  font-weight: 800;
  font-size: 1rem;
  color: var(--text-main);
}

.dc-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.dc-ping {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--accent-emerald);
  background: var(--accent-emerald-light);
  padding: 0.3rem 0.75rem;
  border-radius: var(--radius-full);
  direction: ltr;
}

.network-card {
  background: var(--bg-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  box-shadow: var(--shadow-lg);
}

.uptime-bar {
  display: flex;
  gap: 3px;
  margin: 1.25rem 0;
}

.uptime-block {
  flex: 1;
  height: 28px;
  background: #10b981;
  border-radius: 3px;
  transition: opacity var(--transition-fast);
}

.uptime-block:hover {
  opacity: 0.8;
}

.network-specs-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.75rem;
}

.net-spec {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 0.85rem;
  text-align: center;
}

.net-spec .val {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--text-main);
}

.net-spec .lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Clients */
.clients-section {
  padding: 4rem 0;
  text-align: center;
  border-bottom: 1px solid var(--border-subtle);
}

.clients-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.clients-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2.85rem;
  opacity: 0.85;
}

.client-logo-item {
  font-size: 1.15rem;
  font-weight: 900;
  color: var(--text-muted);
  letter-spacing: -0.5px;
  transition: color var(--transition-fast);
}

.client-logo-item:hover {
  color: var(--text-main);
}

/* Testimonials */
.testimonials-section {
  padding: 5rem 0;
}

.testimonials-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.85rem;
}

.testimonial-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.25rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.testimonial-quote {
  font-size: 0.98rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin-bottom: 1.75rem;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-subtle);
}

.author-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-subtle);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  color: var(--primary);
  border: 1px solid var(--border-subtle);
}

.author-name {
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--text-main);
}

.author-role {
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* FAQ */
.faq-section {
  padding: 5rem 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
}

.faq-container {
  max-width: 840px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-main);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  margin-bottom: 0.85rem;
  overflow: hidden;
  transition: border-color var(--transition-fast);
}

.faq-item.open {
  border-color: var(--primary);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
}

.faq-header {
  padding: 1.25rem 1.6rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  font-size: 1.08rem;
  font-weight: 800;
  color: var(--text-main);
}

.faq-icon {
  transition: transform var(--transition-normal);
  color: var(--text-muted);
}

.faq-item.open .faq-icon {
  transform: rotate(180deg);
  color: var(--primary);
}

.faq-body {
  padding: 0 1.6rem 1.35rem;
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.85;
  display: none;
}

.faq-item.open .faq-body {
  display: block;
}

/* CTA */
.cta-section {
  padding: 5rem 0;
}

.cta-banner {
  background: linear-gradient(135deg, #090d16 0%, #172554 100%);
  color: #ffffff;
  border-radius: var(--radius-xl);
  padding: 4rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow-xl);
  border: 1px solid rgba(59, 130, 246, 0.3);
}

.cta-title {
  font-size: 2.3rem;
  font-weight: 900;
  margin-bottom: 0.85rem;
}

.cta-desc {
  font-size: 1.1rem;
  color: #94a3b8;
  margin-bottom: 1.75rem;
  line-height: 1.75;
}

.cta-actions {
  display: flex;
  gap: 1rem;
}

/* Footer */
.site-footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border-subtle);
  padding: 5rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 3.5rem;
  margin-bottom: 3.5rem;
}

.footer-col h5 {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 1.35rem;
}

.footer-links li {
  margin-bottom: 0.8rem;
}

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

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

.footer-about p {
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.8;
  margin: 1.2rem 0;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 0.85rem;
}

.footer-contact-item svg {
  margin-top: 0.2rem;
  color: var(--primary);
  flex-shrink: 0;
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--border-subtle);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.trust-badges {
  display: flex;
  gap: 1rem;
  align-items: center;
}

.trust-badge-item {
  border: 1px solid var(--border-subtle);
  padding: 0.35rem 0.75rem;
  border-radius: var(--radius-sm);
  background: var(--bg-subtle);
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-secondary);
}

/* Responsive */
@media (max-width: 1024px) {
  .hero-layout, .speedtest-card, .calculator-card, .network-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  .services-grid, .testimonials-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
  .cta-banner {
    flex-direction: column;
    text-align: center;
    gap: 2rem;
    padding: 3rem 1.5rem;
  }
}

@media (max-width: 768px) {
  .nav-menu {
    display: none;
    position: absolute;
    top: 74px;
    left: 0;
    right: 0;
    background: var(--bg-card);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.5rem;
    box-shadow: var(--shadow-lg);
    border-bottom: 1px solid var(--border-subtle);
  }
  .nav-menu.open { display: flex; }
  .mobile-toggle { display: block; }
  .hero-title { font-size: 2.3rem; }
  .hero-stats-row { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
  .services-grid, .testimonials-grid, .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 1rem; text-align: center; }
  .announcement-bar { display: none; }
}
/* ==========================================================================
   Dedicated Pages Extensions (Breadcrumbs, Plan Grids, Wiki, Looking Glass)
   ========================================================================== */

/* Breadcrumbs */
.breadcrumb-wrap {
  padding: 1.5rem 0 0.5rem;
}

.breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.breadcrumbs a {
  color: var(--text-secondary);
}

.breadcrumbs a:hover {
  color: var(--primary);
}

.breadcrumbs .sep {
  font-size: 0.75rem;
  color: var(--text-light);
}

.breadcrumbs .current {
  color: var(--primary);
  font-weight: 700;
}

/* Page Hero Banner */
.page-hero {
  padding: 3rem 0 3.5rem;
  text-align: center;
  position: relative;
}

.page-hero-title {
  font-size: 2.8rem;
  font-weight: 900;
  color: var(--text-main);
  letter-spacing: -0.025em;
  margin-bottom: 1rem;
}

.page-hero-desc {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 750px;
  margin: 0 auto;
  line-height: 1.8;
}

/* Tiered Pricing Cards */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 2.5rem;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.25rem 1.75rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  transition: all var(--transition-normal);
}

.pricing-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}

.pricing-card.featured {
  border-color: var(--primary);
  box-shadow: var(--shadow-lg);
}

.pricing-card.featured::before {
  content: 'پیشنهاد پرطرفدار';
  position: absolute;
  top: -12px;
  right: 50%;
  transform: translateX(50%);
  background: var(--primary-gradient);
  color: #ffffff;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.2rem 0.85rem;
  border-radius: var(--radius-full);
}

.pricing-badge {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--primary);
  background: var(--primary-light);
  padding: 0.2rem 0.65rem;
  border-radius: var(--radius-full);
  margin-bottom: 0.75rem;
}

.pricing-name {
  font-size: 1.35rem;
  font-weight: 900;
  color: var(--text-main);
  margin-bottom: 0.35rem;
}

.pricing-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.pricing-price-wrap {
  padding: 1.25rem 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 1.5rem;
  text-align: center;
}

.pricing-hourly {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.25rem;
}

.pricing-monthly {
  font-size: 1.9rem;
  font-weight: 900;
  color: var(--primary);
}

.pricing-monthly span {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
}

.pricing-features {
  margin-bottom: 2rem;
}

.pricing-features li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-bottom: 0.65rem;
}

.pricing-features li svg {
  color: var(--accent-emerald);
  flex-shrink: 0;
}

/* Looking Glass Terminal */
.looking-glass-box {
  background: var(--terminal-bg);
  border: 1px solid var(--terminal-border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  color: #f1f5f9;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  direction: ltr;
  text-align: left;
  margin-top: 2rem;
  box-shadow: var(--shadow-xl);
}

.lg-controls {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.lg-select, .lg-input {
  background: var(--terminal-header);
  border: 1px solid var(--terminal-border);
  color: #ffffff;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-sm);
  font-family: inherit;
  outline: none;
}

.lg-output {
  background: #000000;
  padding: 1.25rem;
  border-radius: var(--radius-sm);
  min-height: 180px;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #38bdf8;
  white-space: pre-wrap;
}

/* Knowledge Base Wiki Cards */
.wiki-search-box {
  max-width: 650px;
  margin: 2rem auto 0;
}

.wiki-categories-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin-top: 3.5rem;
}

.wiki-cat-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2rem;
  transition: all var(--transition-normal);
}

.wiki-cat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.wiki-cat-icon {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 1.25rem;
}

.wiki-articles-list {
  margin-top: 1.25rem;
}

.wiki-articles-list li {
  margin-bottom: 0.65rem;
}

.wiki-articles-list a {
  font-size: 0.92rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.wiki-articles-list a:hover {
  color: var(--primary);
  padding-right: 0.25rem;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .pricing-grid { grid-template-columns: repeat(2, 1fr); }
  .wiki-categories-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .pricing-grid { grid-template-columns: 1fr; }
  .wiki-categories-grid { grid-template-columns: 1fr; }
  .page-hero-title { font-size: 2.1rem; }
}

/* ==========================================================================
   ULTIMATE LEVEL: PRELOADER, ENHANCED HEADER, MAP & FOOTER
   ========================================================================== */

/* --- 1. Site Preloader --- */
.site-preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--bg-main);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s ease, visibility 0.4s ease;
}

.site-preloader.loaded {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.preloader-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.35rem;
  max-width: 380px;
  padding: 2rem;
}

.preloader-logo-box {
  position: relative;
  width: 72px;
  height: 72px;
  border-radius: 20px;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 900;
  font-size: 1.85rem;
  letter-spacing: -1px;
  box-shadow: 0 8px 32px rgba(37, 99, 235, 0.4);
}

.preloader-ring {
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border-radius: 26px;
  border: 2px dashed rgba(59, 130, 246, 0.6);
  animation: preloaderRotate 4s linear infinite;
}

.preloader-ring-pulse {
  position: absolute;
  inset: -6px;
  border-radius: 24px;
  border: 2px solid var(--primary);
  animation: preloaderPulse 1.8s ease-out infinite;
}

@keyframes preloaderRotate {
  100% { transform: rotate(360deg); }
}

@keyframes preloaderPulse {
  0% { transform: scale(0.95); opacity: 0.9; }
  100% { transform: scale(1.22); opacity: 0; }
}

.preloader-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.25rem;
}

.preloader-status {
  font-size: 0.84rem;
  color: var(--text-muted);
  font-family: var(--font-mono);
  direction: ltr;
}

.preloader-bar-wrap {
  width: 220px;
  height: 4px;
  background: rgba(148, 163, 184, 0.2);
  border-radius: 999px;
  overflow: hidden;
  position: relative;
}

.preloader-bar {
  height: 100%;
  width: 0%;
  background: var(--primary-gradient);
  border-radius: 999px;
  animation: preloaderFill 0.85s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes preloaderFill {
  0% { width: 0%; }
  50% { width: 68%; }
  100% { width: 100%; }
}

/* --- 2. Enhanced Header & Status Pill --- */
.header-brand-wrap {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.header-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(16, 185, 129, 0.1);
  border: 1px solid rgba(16, 185, 129, 0.25);
  color: #10b981;
  font-size: 0.78rem;
  font-weight: 700;
  text-decoration: none;
  transition: all var(--transition-fast);
}

.header-status-pill:hover {
  background: rgba(16, 185, 129, 0.18);
  border-color: rgba(16, 185, 129, 0.4);
  transform: translateY(-1px);
}

.status-dot-pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  position: relative;
  box-shadow: 0 0 8px #10b981;
}

.status-dot-pulse::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1.5px solid #10b981;
  animation: statusPulse 1.8s infinite ease-out;
}

@keyframes statusPulse {
  0% { transform: scale(1); opacity: 0.9; }
  100% { transform: scale(2.4); opacity: 0; }
}

@media (max-width: 991px) {
  .header-status-pill {
    display: none;
  }
}

/* --- 3. Interactive Network & Datacenter Map --- */
.map-section-wrap {
  padding: 5rem 0;
  position: relative;
}

.map-card-container {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.map-card-container::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.08) 0%, transparent 70%);
  pointer-events: none;
}

.map-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  flex-wrap: wrap;
  gap: 1.25rem;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1.25rem;
}

.map-top-bar h3 {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.map-quick-filters {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-node-btn {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-node-btn:hover, .filter-node-btn.active {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

.map-visual-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr;
  gap: 2.5rem;
  align-items: center;
}

@media (max-width: 991px) {
  .map-visual-grid {
    grid-template-columns: 1fr;
  }
}

.svg-canvas-box {
  background: radial-gradient(circle at 40% 40%, rgba(37, 99, 235, 0.05) 0%, rgba(15, 23, 42, 0.02) 100%);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  padding: 1rem;
  position: relative;
  overflow: hidden;
}

.network-svg {
  width: 100%;
  height: auto;
  display: block;
}

.map-conn-line {
  stroke: rgba(59, 130, 246, 0.35);
  stroke-width: 1.75;
  stroke-dasharray: 5 4;
  animation: mapLineFlow 25s linear infinite;
}

.map-conn-active {
  stroke: var(--primary);
  stroke-width: 2.5;
  stroke-dasharray: 8 4;
  animation: mapLineFlow 15s linear infinite;
  filter: drop-shadow(0 0 4px var(--primary));
}

@keyframes mapLineFlow {
  to { stroke-dashoffset: -100; }
}

.map-hub-group {
  cursor: pointer;
  transition: transform 0.2s ease;
}

.map-hub-group:hover {
  transform: scale(1.15);
}

.hub-radar-ring {
  fill: none;
  stroke: var(--primary);
  stroke-width: 1.8;
  animation: radarWave 2.4s cubic-bezier(0.1, 0.8, 0.3, 1) infinite;
}

.hub-radar-ring.core-ring {
  stroke: #10b981;
}

@keyframes radarWave {
  0% { r: 5; opacity: 1; }
  100% { r: 24; opacity: 0; }
}

.hub-dot {
  fill: var(--primary);
  stroke: #ffffff;
  stroke-width: 2;
  filter: drop-shadow(0 2px 6px rgba(37, 99, 235, 0.6));
}

.hub-dot.core-dot {
  fill: #10b981;
  stroke: #ffffff;
  stroke-width: 2.5;
  filter: drop-shadow(0 0 10px rgba(16, 185, 129, 0.8));
}

.hub-text {
  fill: var(--text-main);
  font-size: 11.5px;
  font-weight: 800;
  font-family: inherit;
  filter: drop-shadow(0 1px 3px rgba(0,0,0,0.5));
}

/* Selected Node Details Box */
.node-spec-card {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  transition: all var(--transition-normal);
}

.node-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  padding-bottom: 1rem;
}

.node-city-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
}

.node-badge-type {
  font-size: 0.76rem;
  font-weight: 800;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-sm);
  background: rgba(37, 99, 235, 0.12);
  color: var(--primary);
  border: 1px solid rgba(37, 99, 235, 0.25);
}

.node-badge-type.core {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border-color: rgba(16, 185, 129, 0.3);
}

.node-spec-rows {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.node-spec-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.9rem;
}

.node-spec-label {
  color: var(--text-secondary);
}

.node-spec-val {
  font-weight: 700;
  color: var(--text-main);
  font-family: var(--font-mono);
  direction: ltr;
}

.node-spec-footer {
  border-top: 1px solid var(--border-subtle);
  padding-top: 1rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* --- 4. High-End Enterprise Footer Enhancements --- */
.footer-telemetry-banner {
  background: var(--bg-subtle);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 1.1rem 1.75rem;
  margin-bottom: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.telemetry-live-title {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--text-main);
}

.telemetry-badges-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.telemetry-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.3rem 0.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  color: var(--text-secondary);
  font-family: var(--font-mono);
}

.telemetry-pill strong {
  color: var(--text-main);
}

.telemetry-pill .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
}

/* Newsletter radar */
.footer-newsletter-box {
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.08) 0%, rgba(99, 102, 241, 0.04) 100%);
  border: 1px solid rgba(37, 99, 235, 0.2);
  border-radius: var(--radius-lg);
  padding: 1.85rem 2.25rem;
  margin-bottom: 3.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.75rem;
}

.newsletter-texts h4 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--text-main);
  margin-bottom: 0.35rem;
}

.newsletter-texts p {
  font-size: 0.88rem;
  color: var(--text-secondary);
}

.newsletter-form {
  display: flex;
  gap: 0.65rem;
  width: 100%;
  max-width: 440px;
}

.newsletter-input {
  flex: 1;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  padding: 0.75rem 1.1rem;
  color: var(--text-main);
  font-size: 0.9rem;
  outline: none;
  transition: border-color var(--transition-fast);
}

.newsletter-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* Back to top floating button */
.back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 90;
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(37, 99, 235, 0.35);
}

/* Mobile Nav Drawer Enhancements */
@media (max-width: 991px) {
  .nav-menu {
    position: fixed;
    top: 74px;
    right: 0;
    left: 0;
    background: var(--bg-header);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-subtle);
    padding: 1.5rem;
    flex-direction: column;
    align-items: stretch;
    gap: 0.5rem;
    box-shadow: var(--shadow-lg);
    display: none;
    z-index: 50;
  }

  .nav-menu.active {
    display: flex;
  }

  .nav-link {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
  }

  .nav-link:hover {
    background: var(--bg-subtle);
  }
}
/* ==========================================================================
   CLEAN MINIMALIST HEADER & REAL LEAFLET MAP STYLES
   ========================================================================== */

/* Cleaned Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--bg-header);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
  transition: all var(--transition-normal);
}

.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.brand-icon-box {
  width: 40px;
  height: 40px;
  border-radius: 11px;
  background: var(--primary-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 900;
  font-size: 1.1rem;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.35);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.brand-title {
  font-size: 1.22rem;
  font-weight: 800;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.brand-live-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
  display: inline-block;
}

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

.nav-link {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--text-secondary);
  padding: 0.45rem 0.65rem;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
  text-decoration: none;
}

.nav-link:hover {
  color: var(--primary);
  background: var(--bg-subtle);
}

.nav-link.active {
  color: var(--primary);
  font-weight: 700;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Announcement Bar refinement */
.announcement-bar {
  background: var(--bg-subtle);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0.45rem 0;
  font-size: 0.82rem;
}

.announcement-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* --- Real Interactive Leaflet Map Box --- */
.real-map-box {
  width: 100%;
  height: 480px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-subtle);
  overflow: hidden;
  position: relative;
  background: #0f172a;
  z-index: 1;
}

/* Custom Marker Styling */
.map-pulse-marker {
  display: flex;
  align-items: center;
  justify-content: center;
}

.pulse-core-pin {
  width: 22px;
  height: 22px;
  background: #10b981;
  border: 3px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 16px rgba(16, 185, 129, 0.9);
  position: relative;
}

.pulse-core-pin::after {
  content: '';
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  border: 2px solid #10b981;
  animation: pinPulse 2s infinite ease-out;
}

.pulse-edge-pin {
  width: 16px;
  height: 16px;
  background: #3b82f6;
  border: 2.5px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.9);
  position: relative;
}

.pulse-edge-pin::after {
  content: '';
  position: absolute;
  inset: -7px;
  border-radius: 50%;
  border: 2px solid #3b82f6;
  animation: pinPulse 2.2s infinite ease-out;
}

@keyframes pinPulse {
  0% { transform: scale(0.8); opacity: 1; }
  100% { transform: scale(2.4); opacity: 0; }
}

/* Leaflet Popup Customization */
.leaflet-popup-content-wrapper {
  background: var(--bg-card) !important;
  color: var(--text-main) !important;
  border-radius: 12px !important;
  border: 1px solid var(--border-subtle) !important;
  box-shadow: var(--shadow-lg) !important;
  font-family: 'Vazirmatn', sans-serif !important;
  direction: rtl;
  padding: 4px;
}

.leaflet-popup-tip {
  background: var(--bg-card) !important;
}

.popup-title {
  font-size: 0.95rem;
  font-weight: 800;
  margin-bottom: 0.35rem;
  color: var(--text-main);
}

.popup-sub {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.popup-ping-tag {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.2rem 0.6rem;
  border-radius: 6px;
  font-size: 0.76rem;
  font-weight: 800;
  font-family: var(--font-mono);
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
}

.map-control-hint {
  position: absolute;
  bottom: 12px;
  left: 12px;
  z-index: 400;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(8px);
  color: #cbd5e1;
  font-size: 0.75rem;
  padding: 0.3rem 0.75rem;
  border-radius: 6px;
  border: 1px solid rgba(255,255,255,0.1);
  pointer-events: none;
}