/* ============================================
   WhalesNode – Casper Network Validator
   Theme: Crypto Light
   ============================================ */

:root {
  --primary: #1a73e8;
  --primary-dark: #0d5bc9;
  --accent: #00c9a7;
  --accent-dark: #00a88c;
  --bg: #f0f4ff;
  --bg-card: #ffffff;
  --bg-alt: #e8eef8;
  --text: #0d1b2a;
  --text-muted: #5a6a80;
  --border: #d4dff0;
  --shadow: 0 4px 24px rgba(26, 115, 232, 0.10);
  --shadow-lg: 0 8px 48px rgba(26, 115, 232, 0.18);
  --radius: 16px;
  --radius-sm: 8px;
  --font: 'Inter', 'Segoe UI', sans-serif;
  --gradient: linear-gradient(135deg, #1a73e8 0%, #00c9a7 100%);
  --gradient-bg: linear-gradient(160deg, #eaf1ff 0%, #f0fff9 100%);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

/* ---- Scrollbar ---- */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--primary); border-radius: 3px; }

/* ---- Selection ---- */
::selection { background: var(--primary); color: #fff; }

/* ============ NAVBAR ============ */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 0 5%;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow 0.3s;
}
.navbar.scrolled { box-shadow: var(--shadow); }

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}
.nav-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: contain;
  border: 2px solid var(--border);
  background: #fff;
}
.nav-name {
  font-size: 1.2rem;
  font-weight: 700;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  text-decoration: none;
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--primary); }

.btn-delegate-nav {
  background: var(--gradient);
  color: #fff !important;
  padding: 10px 22px;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem !important;
  transition: opacity 0.2s, transform 0.2s !important;
  box-shadow: 0 2px 12px rgba(26,115,232,0.3);
}
.btn-delegate-nav:hover { opacity: 0.9; transform: translateY(-1px); }

.nav-hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.nav-hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: all 0.3s;
}

/* ============ HERO ============ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 100px 5% 60px;
  background: var(--gradient-bg);
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  width: 600px; height: 600px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(26,115,232,0.08) 0%, transparent 70%);
  top: -150px; right: -100px;
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  width: 400px; height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(0,201,167,0.08) 0%, transparent 70%);
  bottom: -100px; left: -80px;
  pointer-events: none;
}

.hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  width: 100%;
  position: relative;
  z-index: 1;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(26,115,232,0.08);
  border: 1px solid rgba(26,115,232,0.2);
  color: var(--primary);
  padding: 6px 14px;
  border-radius: 50px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 20px;
}
.hero-badge .dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.4); opacity: 0.6; }
}

.hero-title {
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 800;
  line-height: 1.15;
  color: var(--text);
  margin-bottom: 20px;
}
.hero-title .highlight {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 520px;
  margin-bottom: 36px;
  line-height: 1.75;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--gradient);
  color: #fff;
  padding: 15px 32px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 4px 20px rgba(26,115,232,0.35);
  transition: transform 0.2s, box-shadow 0.2s;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(26,115,232,0.45);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  color: var(--primary);
  padding: 15px 32px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  border: 2px solid var(--border);
  transition: border-color 0.2s, transform 0.2s;
}
.btn-secondary:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
}

.hero-stats {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
}
.hero-stat { display: flex; flex-direction: column; }
.hero-stat .value {
  font-size: 1.6rem;
  font-weight: 800;
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero-stat .label {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Hero Visual */
.hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

.hero-card {
  background: var(--bg-card);
  border-radius: 24px;
  padding: 36px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  width: 100%;
  max-width: 400px;
  position: relative;
  z-index: 2;
}

.hero-card-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}
.hero-card-logo img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: contain;
  border: 2px solid var(--border);
}
.hero-card-logo-text .name {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--text);
}
.hero-card-logo-text .network {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.metric-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
.metric {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  border: 1px solid var(--border);
}
.metric .m-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}
.metric .m-value {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}
.metric .m-value.green { color: var(--accent-dark); }

.pubkey-box {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
}
.pubkey-box .pk-label {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}
.pubkey-box .pk-value {
  font-size: 0.72rem;
  font-family: 'Courier New', monospace;
  color: var(--primary);
  word-break: break-all;
  line-height: 1.5;
}

.floating-ring {
  position: absolute;
  border-radius: 50%;
  border: 2px solid rgba(26,115,232,0.12);
  animation: spin 20s linear infinite;
}
.ring1 { width: 320px; height: 320px; top: 50%; left: 50%; transform: translate(-50%,-50%); }
.ring2 { width: 450px; height: 450px; top: 50%; left: 50%; transform: translate(-50%,-50%); animation-duration: 30s; animation-direction: reverse; border-color: rgba(0,201,167,0.1); }

@keyframes spin { to { transform: translate(-50%,-50%) rotate(360deg); } }

/* ============ SECTIONS ============ */
section { padding: 90px 5%; }

.section-inner { max-width: 1200px; margin: 0 auto; }

.section-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  background: rgba(26,115,232,0.08);
  padding: 5px 14px;
  border-radius: 50px;
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.4rem);
  font-weight: 800;
  color: var(--text);
  margin-bottom: 14px;
  line-height: 1.25;
}

.section-desc {
  font-size: 1rem;
  color: var(--text-muted);
  max-width: 600px;
  margin-bottom: 50px;
  line-height: 1.75;
}

/* ============ FEATURES ============ */
.features { background: #fff; }

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: transform 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.feature-icon {
  width: 52px; height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 18px;
}
.icon-blue { background: rgba(26,115,232,0.1); }
.icon-green { background: rgba(0,201,167,0.1); }
.icon-purple { background: rgba(124,77,255,0.1); }
.icon-orange { background: rgba(255,145,0,0.1); }
.icon-red { background: rgba(234,67,53,0.1); }
.icon-teal { background: rgba(0,188,212,0.1); }

.feature-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 10px;
}
.feature-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* ============ NODE INFO ============ */
.node-info { background: var(--gradient-bg); }

.node-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  align-items: start;
}

.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  box-shadow: var(--shadow);
}

.info-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.info-row:last-child { border-bottom: none; }
.info-row .ir-label {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}
.info-row .ir-value {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
  text-align: right;
  max-width: 60%;
  word-break: break-all;
}
.badge-active {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(0,201,167,0.1);
  color: var(--accent-dark);
  padding: 4px 12px;
  border-radius: 50px;
  font-size: 0.78rem;
  font-weight: 600;
}
.badge-active::before {
  content: '';
  width: 7px; height: 7px;
  background: var(--accent);
  border-radius: 50%;
}

.map-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.map-card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
  padding: 20px 24px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}
.map-container {
  position: relative;
  height: 260px;
  background: linear-gradient(135deg, #e8f0fe 0%, #e0f7f4 100%);
  overflow: hidden;
  margin-top: 16px;
}
.map-svg { width: 100%; height: 100%; opacity: 0.5; }

.map-pin {
  position: absolute;
  top: 48%; left: 55%;
  transform: translate(-50%, -50%);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.pin-dot {
  width: 16px; height: 16px;
  background: var(--primary);
  border-radius: 50%;
  border: 3px solid #fff;
  box-shadow: 0 0 0 4px rgba(26,115,232,0.25);
  animation: mapPulse 2s infinite;
}
@keyframes mapPulse {
  0%, 100% { box-shadow: 0 0 0 4px rgba(26,115,232,0.25); }
  50% { box-shadow: 0 0 0 10px rgba(26,115,232,0.1); }
}
.pin-label {
  margin-top: 6px;
  background: var(--primary);
  color: #fff;
  padding: 3px 10px;
  border-radius: 50px;
  font-size: 0.72rem;
  font-weight: 600;
  white-space: nowrap;
}

.map-info {
  padding: 16px 24px 20px;
  display: flex;
  gap: 24px;
}
.map-info-item { display: flex; flex-direction: column; }
.map-info-item .mi-label { font-size: 0.72rem; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
.map-info-item .mi-value { font-size: 0.92rem; font-weight: 600; color: var(--text); }

/* ============ HOW TO DELEGATE ============ */
.delegate-steps { background: #fff; }

.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 50px;
}

.step-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 22px;
  text-align: center;
  position: relative;
  transition: transform 0.25s, box-shadow 0.25s;
}
.step-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.step-num {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  margin: 0 auto 16px;
}

.step-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}
.step-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.6;
}

.delegate-cta {
  background: var(--gradient);
  border-radius: 24px;
  padding: 48px;
  text-align: center;
  color: #fff;
  position: relative;
  overflow: hidden;
}
.delegate-cta::before {
  content: '';
  position: absolute;
  width: 300px; height: 300px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  top: -100px; right: -60px;
}
.delegate-cta::after {
  content: '';
  position: absolute;
  width: 200px; height: 200px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  bottom: -60px; left: -40px;
}
.delegate-cta h2 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 10px;
  position: relative;
  z-index: 1;
}
.delegate-cta p {
  font-size: 1rem;
  opacity: 0.85;
  margin-bottom: 28px;
  position: relative;
  z-index: 1;
}
.btn-white {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  color: var(--primary);
  padding: 15px 36px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 700;
  font-size: 1rem;
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
  z-index: 1;
}
.btn-white:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(0,0,0,0.2); }

/* ============ ABOUT / TRUST ============ */
.about { background: var(--gradient-bg); }

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

.trust-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-top: 24px;
}
.trust-list li {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.trust-icon {
  width: 36px; height: 36px;
  border-radius: 10px;
  background: rgba(26,115,232,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  flex-shrink: 0;
  margin-top: 2px;
}
.trust-text strong {
  display: block;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}
.trust-text span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.about-visual {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.about-stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 20px;
  transition: transform 0.2s;
}
.about-stat-card:hover { transform: translateX(4px); }

.asc-icon {
  width: 48px; height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.asc-content .asc-value {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--text);
}
.asc-content .asc-label {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* ============ FOOTER ============ */
footer {
  background: var(--text);
  color: rgba(255,255,255,0.75);
  padding: 50px 5% 30px;
}

.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-top {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-brand .nav-logo {
  width: 48px; height: 48px;
  margin-bottom: 12px;
}
.footer-brand .brand-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 10px;
}
.footer-brand p {
  font-size: 0.85rem;
  line-height: 1.7;
  max-width: 280px;
}

.footer-col h4 {
  color: #fff;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a {
  color: rgba(255,255,255,0.6);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.2s;
}
.footer-col ul li a:hover { color: var(--accent); }

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.82rem;
  color: rgba(255,255,255,0.4);
}
.footer-bottom a { color: rgba(255,255,255,0.5); text-decoration: none; }
.footer-bottom a:hover { color: var(--accent); }

.social-links {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}
.social-link {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,0.7);
  text-decoration: none;
  font-size: 0.9rem;
  transition: background 0.2s, color 0.2s;
}
.social-link:hover { background: var(--primary); color: #fff; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-top { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; }
  .hero-desc { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-stats { justify-content: center; }
  .hero-visual { display: none; }
  .node-grid { grid-template-columns: 1fr; }
  .about-grid { grid-template-columns: 1fr; }
  .features-grid { grid-template-columns: 1fr; }
  .steps-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; text-align: center; }

  .nav-links {
    display: none;
    position: fixed;
    top: 72px; left: 0; right: 0;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(16px);
    flex-direction: column;
    padding: 24px;
    gap: 16px;
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-lg);
  }
  .nav-links.open { display: flex; }
  .nav-hamburger { display: flex; }
}

/* ============ ANIMATIONS ============ */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============ COPY BTN ============ */
.copy-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--primary);
  font-size: 0.8rem;
  padding: 2px 8px;
  border-radius: 4px;
  transition: background 0.2s;
}
.copy-btn:hover { background: rgba(26,115,232,0.1); }
.copy-btn.copied { color: var(--accent-dark); }
