@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --mint: #81D8D0;
  --mint-2: #BDF1EC;
  --gray-1: #8E9492;
  --gray-2: #65696A;
  --ink: #1B2120;
  --paper: #F3F5F4;
  --paper-2: #FBFCFC;
  --line: rgba(27, 33, 32, 0.10);
  --shadow: 0 18px 54px rgba(27, 33, 32, 0.10);
  --shadow-soft: 0 10px 28px rgba(27, 33, 32, 0.06);
  --radius: 24px;
  --radius-sm: 16px;
  --max: 1240px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; min-height: 100%; }
body {
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1200px 500px at 85% 5%, rgba(129, 216, 208, 0.18), transparent 60%),
    radial-gradient(900px 500px at -10% 95%, rgba(129, 216, 208, 0.14), transparent 60%),
    linear-gradient(180deg, #F8FAF9 0%, #EFF3F2 100%);
  overflow-x: hidden;
}

body::before,
body::after {
  content: "";
  position: fixed;
  pointer-events: none;
  z-index: -1;
  filter: blur(8px);
}
body::before {
  width: 420px; height: 420px;
  right: -120px; top: -80px;
  border-radius: 42% 58% 63% 37% / 39% 31% 69% 61%;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,255,255,0.92), rgba(255,255,255,0.28) 35%, rgba(129,216,208,0.28) 60%, rgba(255,255,255,0) 80%),
    linear-gradient(135deg, rgba(255,255,255,0.75), rgba(129,216,208,0.25));
  box-shadow:
    inset 0 0 26px rgba(255,255,255,0.8),
    inset -20px -20px 45px rgba(27,33,32,0.08),
    0 20px 70px rgba(27,33,32,0.10);
}
body::after {
  width: 360px; height: 360px;
  left: -110px; bottom: -100px;
  border-radius: 57% 43% 31% 69% / 50% 36% 64% 50%;
  background:
    radial-gradient(circle at 55% 45%, rgba(189,241,236,0.75), rgba(255,255,255,0.18) 50%, rgba(255,255,255,0) 78%),
    linear-gradient(135deg, rgba(255,255,255,0.65), rgba(129,216,208,0.22));
  box-shadow:
    inset 0 0 26px rgba(255,255,255,0.8),
    inset 10px 10px 45px rgba(27,33,32,0.06),
    0 20px 70px rgba(27,33,32,0.08);
}

a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }

.page-shell {
  width: min(calc(100% - 32px), var(--max));
  margin: 24px auto 48px;
}

.topbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  padding: 18px 22px;
  border: 1px solid rgba(255,255,255,0.72);
  background: rgba(255,255,255,0.68);
  backdrop-filter: blur(18px) saturate(135%);
  border-radius: 26px;
  box-shadow: var(--shadow-soft);
}
.brand {
  display: flex; align-items: center; gap: 14px;
  font-weight: 800;
  letter-spacing: -0.04em;
}
.brand-mark {
  width: 38px; height: 38px; border-radius: 50%;
  background:
    radial-gradient(circle at 32% 32%, #ffffff 0 18%, transparent 19%),
    radial-gradient(circle at 62% 62%, rgba(129,216,208,0.95) 0 24%, rgba(129,216,208,0.18) 25%, transparent 55%),
    linear-gradient(145deg, rgba(255,255,255,0.88), rgba(129,216,208,0.35));
  box-shadow:
    inset 0 0 12px rgba(255,255,255,0.9),
    inset -8px -10px 18px rgba(27,33,32,0.10),
    0 8px 24px rgba(27,33,32,0.10);
  position: relative;
}
.brand-mark::after {
  content: "";
  position: absolute; inset: 4px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.65);
}
.brand-lockup {
  display: flex; flex-direction: column; line-height: 1;
}
.brand-top { font-size: 12px; color: var(--gray-2); font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; }
.brand-main { font-size: 24px; }
.brand-main small { font-size: 20px; font-weight: 700; color: var(--gray-2); }

.nav {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.nav a, .chip {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid rgba(27,33,32,0.06);
  color: var(--gray-2);
  background: rgba(255,255,255,0.66);
}
.nav a.is-active, .chip.is-active {
  color: var(--ink);
  background: rgba(129,216,208,0.22);
  border-color: rgba(129,216,208,0.45);
}

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 44px; padding: 0 18px;
  border-radius: 14px; border: 1px solid transparent;
  font-weight: 700; cursor: pointer; transition: transform 120ms ease, box-shadow 120ms ease, background 120ms ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary {
  background: linear-gradient(180deg, var(--mint) 0%, #72d2c8 100%);
  color: var(--ink);
  box-shadow: 0 10px 26px rgba(129,216,208,0.28);
}
.btn-secondary {
  background: rgba(255,255,255,0.76);
  border-color: rgba(27,33,32,0.08);
  color: var(--ink);
}
.btn-dark {
  background: var(--ink);
  color: white;
}
.btn-danger {
  background: linear-gradient(180deg, #ffdfdf 0%, #ffc9c9 100%);
  color: #8b1717;
  border-color: rgba(139, 23, 23, 0.12);
}
.btn-ghost {
  background: transparent;
  color: var(--gray-2);
  border-color: rgba(27,33,32,0.10);
}

.hero {
  margin-top: 24px;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 18px;
}
.hero-card, .panel, .card {
  position: relative;
  border-radius: 28px;
  border: 1px solid rgba(255,255,255,0.72);
  /* background:
    linear-gradient(180deg, rgba(255,255,255,0.88), rgba(255,255,255,0.74)),
    linear-gradient(135deg, rgba(129,216,208,0.12), rgba(255,255,255,0.12)); */
  backdrop-filter: blur(16px) saturate(130%);
  box-shadow: var(--shadow);
}
.hero-card { padding: 38px; overflow: hidden; min-height: 360px; }
.hero-card::after {
  content: "";
  position: absolute; right: -80px; bottom: -110px;
  width: 360px; height: 360px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 40% 40%, rgba(255,255,255,0.9), rgba(129,216,208,0.38) 45%, rgba(255,255,255,0.0) 72%),
    linear-gradient(145deg, rgba(255,255,255,0.85), rgba(129,216,208,0.24));
  box-shadow:
    inset 0 0 24px rgba(255,255,255,0.9),
    inset -14px -14px 34px rgba(27,33,32,0.10),
    0 20px 60px rgba(27,33,32,0.10);
}
.hero-kicker {
  font-size: 12px; text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--gray-2); font-weight: 700;
}
.hero h1, .headline {
  margin: 12px 0 12px;
  font-size: clamp(38px, 5vw, 68px);
  line-height: 0.95; letter-spacing: -0.06em;
}
.hero p.lead {
  max-width: 640px;
  color: var(--gray-2);
  font-size: 20px;
  line-height: 1.45;
}
.hero-orbit {
  position: absolute;
  right: 48px; top: 48px;
  width: 260px; height: 260px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, rgba(255,255,255,0.92) 0 20%, rgba(129,216,208,0.34) 35%, rgba(255,255,255,0) 58%),
    conic-gradient(from 0deg, rgba(129,216,208,0.8), rgba(255,255,255,0.12), rgba(129,216,208,0.7), rgba(255,255,255,0.12), rgba(129,216,208,0.8));
  box-shadow:
    inset 0 0 20px rgba(255,255,255,0.9),
    inset -14px -14px 36px rgba(27,33,32,0.10);
  filter: saturate(1.05);
}
.hero-orbit::before,
.hero-orbit::after {
  content: "";
  position: absolute; inset: 28px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.8);
}
.hero-orbit::after { inset: 80px; }

.grid {
  margin-top: 18px;
  display: grid; gap: 18px;
}
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.card, .panel { padding: 22px; }
.card h2, .panel h2 {
  margin: 0 0 12px;
  font-size: 22px;
  letter-spacing: -0.03em;
}
.card h3 { margin: 0 0 10px; }
.muted { color: var(--gray-2); }
.small { font-size: 13px; }
.kpi {
  display: grid; gap: 8px;
}
.kpi-value {
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 800;
  letter-spacing: -0.05em;
}
.status-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 12px; border-radius: 999px; font-weight: 700;
  background: rgba(129,216,208,0.18);
  border: 1px solid rgba(129,216,208,0.42);
}
.status-pill.warn { background: rgba(255, 213, 120, 0.18); border-color: rgba(255, 213, 120, 0.45); }
.status-pill.unsafe { background: rgba(255, 94, 94, 0.14); border-color: rgba(255, 94, 94, 0.35); color: #8a1212; }
.status-pill.unknown { background: rgba(142, 148, 146, 0.14); border-color: rgba(142, 148, 146, 0.35); }

.ring {
  width: 170px; aspect-ratio: 1;
  display: grid; place-items: center;
  margin: 10px auto;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(255,255,255,0.95) 0 49%, transparent 50% 100%),
    conic-gradient(var(--mint) 0deg, var(--mint) calc(var(--pct) * 3.6deg), rgba(27,33,32,0.08) 0);
  box-shadow:
    inset 0 0 20px rgba(255,255,255,0.9),
    0 12px 36px rgba(27,33,32,0.08);
}
.ring-inner {
  width: 126px; aspect-ratio: 1; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255,255,255,0.95);
  box-shadow: inset 0 0 16px rgba(129,216,208,0.15);
}
.ring-value { font-size: 36px; font-weight: 800; letter-spacing: -0.06em; }
.ring-label { font-size: 13px; color: var(--gray-2); font-weight: 700; text-transform: uppercase; letter-spacing: 0.12em; }

.toolbar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.segmented {
  display: inline-flex; padding: 6px; border-radius: 999px;
  background: rgba(255,255,255,0.74);
  border: 1px solid rgba(27,33,32,0.08);
  gap: 6px;
}
.segmented button {
  border: 0; background: transparent; color: var(--gray-2);
  padding: 9px 14px; border-radius: 999px; font-weight: 700; cursor: pointer;
}
.segmented button.active {
  background: rgba(129,216,208,0.22);
  color: var(--ink);
}

.codebox {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px; line-height: 1.6;
  background: rgba(27,33,32,0.95);
  color: #d8fef7;
  border-radius: 18px;
  padding: 18px; overflow: auto;
  border: 1px solid rgba(255,255,255,0.08);
}
pre { margin: 0; white-space: pre-wrap; word-break: break-word; }

.table-wrap {
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid rgba(27,33,32,0.07);
  background: rgba(255,255,255,0.78);
}
table {
  width: 100%; border-collapse: collapse;
}
thead th {
  text-align: left; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--gray-2);
  padding: 14px 16px; background: rgba(248,250,249,0.92);
  border-bottom: 1px solid rgba(27,33,32,0.06);
}
tbody td {
  padding: 14px 16px;
  border-bottom: 1px solid rgba(27,33,32,0.06);
  font-size: 14px;
  vertical-align: top;
}
tbody tr:last-child td { border-bottom: 0; }
.table-emph {
  font-weight: 700; color: var(--ink);
}
.hash {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  color: var(--gray-2);
}
.stack {
  display: grid; gap: 12px;
}
.badge {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(129,216,208,0.18);
  border: 1px solid rgba(129,216,208,0.35);
  font-size: 12px;
  font-weight: 700;
}
.badge.gray {
  background: rgba(142,148,146,0.12);
  border-color: rgba(142,148,146,0.25);
}
.badge.red {
  background: rgba(255, 94, 94, 0.14);
  border-color: rgba(255, 94, 94, 0.24);
  color: #8a1212;
}

.timeline {
  display: grid; gap: 12px;
}
.timeline-item {
  display: grid; grid-template-columns: 10px 1fr; gap: 12px;
}
.timeline-dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--mint); box-shadow: 0 0 0 6px rgba(129,216,208,0.16);
  margin-top: 7px;
}
.timeline-body {
  padding-bottom: 8px; border-bottom: 1px solid rgba(27,33,32,0.06);
}
.timeline-item:last-child .timeline-body { border-bottom: 0; }

.split {
  display: grid; gap: 18px; grid-template-columns: 1fr 1fr;
}
.preview-frame {
  width: 100%;
  min-height: 520px;
  border: 0;
  border-radius: 22px;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(27,33,32,0.07), 0 18px 40px rgba(27,33,32,0.08);
}
.app-shell {
  width: min(calc(100% - 24px), 1200px);
  margin: 20px auto 30px;
}
.app-nav {
  padding: 14px 18px;
  border-radius: 18px;
  display: flex; justify-content: space-between; align-items: center;
  background: rgba(255,255,255,0.78);
  border: 1px solid rgba(27,33,32,0.07);
  box-shadow: var(--shadow-soft);
}
.app-nav .tabs { display: flex; gap: 20px; font-size: 13px; color: var(--gray-2); }
.app-nav .tabs .active { color: var(--ink); font-weight: 700; }
.app-main {
  min-height: calc(100vh - 170px);
  display: grid; place-items: center;
}
.stake-panel {
  width: min(420px, 92vw);
  padding: 22px;
  border-radius: 22px;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(27,33,32,0.07);
  box-shadow: var(--shadow);
}
.tabs-pill {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 6px; padding: 6px;
  background: rgba(129,216,208,0.10);
  border-radius: 999px;
}
.tabs-pill button {
  min-height: 34px; border: 0; border-radius: 999px; background: transparent; color: var(--gray-2);
}
.tabs-pill button.active { background: rgba(129,216,208,0.26); color: var(--ink); font-weight: 700; }
.input-card {
  margin-top: 16px;
  border-radius: 18px;
  padding: 16px;
  background: rgba(248,250,249,0.85);
  border: 1px solid rgba(27,33,32,0.07);
}
.input-row {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
.amount-box {
  margin-top: 8px;
  border-radius: 12px; background: white; border: 1px solid rgba(27,33,32,0.08);
  padding: 12px 14px;
}
.amount-box input {
  width: 100%; border: 0; outline: none; font-size: 20px; background: transparent; color: var(--ink);
}
.quick-actions { display: flex; gap: 6px; font-size: 12px; }
.quick-actions button {
  border: 0; background: transparent; color: var(--gray-2); padding: 0 2px; cursor: pointer;
}
.quick-actions .max {
  background: rgba(27,33,32,0.06);
  border-radius: 999px;
  padding: 4px 8px;
  font-weight: 700;
}
.primary-cta {
  margin-top: 12px; width: 100%; min-height: 44px;
  border: 0; border-radius: 999px; cursor: pointer; font-weight: 800;
  background: linear-gradient(180deg, var(--mint), #77d3ca);
  color: var(--ink);
  box-shadow: 0 10px 22px rgba(129,216,208,0.26);
}
.stat-list { margin-top: 16px; display: grid; gap: 8px; }
.stat-row { display: flex; justify-content: space-between; color: var(--gray-2); font-size: 13px; }
.stat-row strong { color: var(--ink); font-weight: 700; }

.callout {
  position: fixed; right: 30px; bottom: 30px; width: min(280px, calc(100vw - 32px));
  padding: 18px; border-radius: 20px;
  background: rgba(255,255,255,0.92);
  border: 1px solid rgba(27,33,32,0.07);
  box-shadow: var(--shadow);
}
.callout h3 { margin: 0 0 8px; }
.callout p { margin: 0 0 14px; color: var(--gray-2); font-size: 14px; }
.callout .field {
  display: flex; gap: 10px;
  background: rgba(248,250,249,0.9); border: 1px solid rgba(27,33,32,0.07);
  border-radius: 12px; padding: 10px 12px; margin-bottom: 12px;
}
.callout input { border: 0; outline: none; background: transparent; width: 100%; }

.footer-note { margin-top: 8px; color: var(--gray-2); font-size: 12px; }

.empty {
  padding: 22px; text-align: center; color: var(--gray-2);
}

@media (max-width: 1100px) {
  .hero { grid-template-columns: 1fr; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .page-shell { width: min(calc(100% - 18px), var(--max)); margin-top: 14px; }
  .topbar { flex-direction: column; align-items: stretch; }
  .nav { justify-content: center; }
  .hero-card { padding: 24px; min-height: 300px; }
  .hero-orbit { right: 18px; top: 18px; width: 180px; height: 180px; opacity: 0.85; }
  .grid-3, .grid-2, .grid-4 { grid-template-columns: 1fr; }
  .callout { position: static; width: 100%; margin-top: 16px; }
}
