:root {
  --bg: #050506;
  --panel: #101113;
  --panel-soft: #17191d;
  --text: #f4f4f1;
  --muted: #a3a6ad;
  --soft: #747982;
  --line: rgba(255, 255, 255, 0.1);
  --line-strong: rgba(255, 255, 255, 0.18);
  --silver: #d7dde1;
  --gold: #d6ad52;
  --green: #3fd278;
  --red: #ff6363;
  --blue: #65a9ff;
  color-scheme: dark;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.025) 1px, transparent 1px),
    var(--bg);
  background-size: 44px 44px;
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.5;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
  text-decoration: none;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 70px;
  padding: 12px max(28px, env(safe-area-inset-left)) 12px max(28px, env(safe-area-inset-right));
  background: rgba(5, 5, 6, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  min-width: 0;
}

.brand img {
  flex: 0 0 auto;
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.brand span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.nav a {
  flex: 0 0 auto;
  border-radius: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
  padding: 9px 12px;
}

.nav a:hover {
  background: var(--panel-soft);
  color: var(--text);
}

main {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 390px;
  align-items: center;
  gap: 32px;
  min-height: calc(100vh - 70px);
  padding: 44px 0;
}

.hero-copy {
  max-width: 700px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

h1,
h2 {
  margin: 0;
  line-height: 1.05;
}

h1 {
  max-width: 760px;
  font-size: 58px;
  font-weight: 800;
}

h2 {
  font-size: 25px;
  font-weight: 800;
}

.lead {
  max-width: 620px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 18px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.button,
.small-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  min-height: 42px;
  padding: 0 16px;
  font-weight: 800;
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
}

.button:hover,
.small-button:hover {
  transform: translateY(-1px);
}

.button-primary {
  border-color: transparent;
  background: linear-gradient(135deg, var(--silver), var(--gold));
  color: #080808;
}

.button-secondary {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.full {
  width: 100%;
}

.small-button {
  min-height: 34px;
  padding: 0 12px;
  background: var(--panel-soft);
  color: var(--text);
  font-size: 13px;
}

.summary-panel,
.panel {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 17, 19, 0.86);
  box-shadow: 0 22px 70px rgba(0, 0, 0, 0.28);
}

.summary-panel {
  padding: 22px;
}

.coin-art {
  display: block;
  width: min(260px, 74%);
  margin: 4px auto 20px;
  object-fit: contain;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.summary-grid div,
.metric-list div {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  padding: 14px;
}

.summary-grid span,
.metric-list span,
.quote span,
.address-box span,
.progress-label span {
  display: block;
  color: var(--soft);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.summary-grid strong,
.metric-list strong,
.quote strong {
  display: block;
  margin-top: 4px;
  overflow-wrap: anywhere;
  color: var(--text);
  font-size: 18px;
}

.layout {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(0, 1fr);
  gap: 18px;
  margin-bottom: 18px;
}

.panel {
  padding: 20px;
}

.buy-panel {
  grid-row: span 2;
  border-color: rgba(214, 173, 82, 0.34);
}

.section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

.pill {
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  padding: 6px 10px;
  white-space: nowrap;
}

.pill.live {
  border-color: rgba(63, 210, 120, 0.28);
  background: rgba(63, 210, 120, 0.09);
  color: var(--green);
}

.field {
  display: grid;
  gap: 8px;
}

.field label {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.amount-row {
  display: grid;
  grid-template-columns: 1fr auto;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--panel-soft);
}

.amount-row:focus-within {
  border-color: rgba(214, 173, 82, 0.58);
}

.amount-row input {
  width: 100%;
  min-height: 54px;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--text);
  font-size: 24px;
  font-weight: 800;
  padding: 0 14px;
}

.amount-row .small-button {
  align-self: stretch;
  border-top: 0;
  border-right: 0;
  border-bottom: 0;
  border-radius: 0;
}

.quote {
  display: grid;
  gap: 10px;
  margin: 16px 0;
}

.quote div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}

.quote div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.quote strong {
  color: var(--gold);
  text-align: right;
}

.note {
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.note.error {
  color: var(--red);
}

.note.success {
  color: var(--green);
}

.metric-list {
  display: grid;
  gap: 10px;
}

.metric-list.compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 14px;
}

.progress-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.progress-bar {
  overflow: hidden;
  height: 10px;
  border-radius: 999px;
  background: var(--panel-soft);
}

.progress-bar span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--gold));
  transition: width 260ms ease;
}

.address-box {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 12px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding: 14px 0;
}

.address-box:first-of-type {
  padding-top: 0;
}

.address-box:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.address-box strong {
  overflow-wrap: anywhere;
  color: var(--blue);
  font-size: 13px;
  grid-column: 1 / 2;
}

.address-box .small-button {
  grid-column: 2;
  grid-row: 1 / 3;
}

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

.info-grid p {
  color: var(--muted);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.chips span {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel-soft);
  color: var(--silver);
  font-size: 13px;
  font-weight: 800;
  padding: 7px 10px;
}

.faq {
  margin-bottom: 40px;
}

details {
  border-top: 1px solid var(--line);
  padding: 15px 0;
}

details:last-child {
  padding-bottom: 0;
}

summary {
  cursor: pointer;
  font-size: 16px;
  font-weight: 800;
}

details p {
  margin: 10px 0 0;
  color: var(--muted);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  border-top: 1px solid var(--line);
  color: var(--soft);
  font-size: 13px;
  padding: 22px 28px 28px;
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 30;
  display: none;
  max-width: min(360px, calc(100% - 36px));
  border: 1px solid rgba(214, 173, 82, 0.36);
  border-radius: 8px;
  background: #151515;
  color: var(--text);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.42);
  padding: 12px 14px;
  font-size: 13px;
  font-weight: 700;
}

@media (max-width: 900px) {
  .topbar {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    flex-wrap: wrap;
    gap: 10px 12px;
    padding: 12px 18px;
  }

  .nav {
    grid-column: 1 / -1;
    width: 100%;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
  }

  .nav::-webkit-scrollbar {
    display: none;
  }

  main {
    width: min(100% - 24px, 720px);
  }

  .hero,
  .layout,
  .info-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    gap: 18px;
    padding: 28px 0 16px;
  }

  h1 {
    font-size: 42px;
  }

  .lead {
    font-size: 16px;
  }

  .coin-art {
    width: min(190px, 58%);
    margin-bottom: 16px;
  }

  .buy-panel {
    grid-row: auto;
  }
}

@media (max-width: 560px) {
  body {
    font-size: 14px;
  }

  .topbar {
    gap: 10px;
    min-height: 64px;
    padding: 10px 12px;
  }

  .brand span {
    font-size: 15px;
  }

  .brand img {
    width: 32px;
    height: 32px;
  }

  #connect-btn {
    min-width: 132px;
    padding-inline: 10px;
  }

  .nav {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 6px;
  }

  .nav a {
    min-height: 36px;
    padding: 9px 6px;
    text-align: center;
  }

  h1 {
    font-size: 34px;
  }

  h2 {
    font-size: 22px;
  }

  .hero-actions,
  .section-head,
  .footer {
    flex-direction: column;
    align-items: stretch;
  }

  .metric-list.compact {
    grid-template-columns: 1fr;
  }

  .summary-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .panel,
  .summary-panel {
    padding: 16px;
  }

  .summary-grid div,
  .metric-list div {
    padding: 12px;
  }

  .summary-grid strong,
  .metric-list strong,
  .quote strong {
    font-size: 16px;
  }

  .button {
    min-height: 46px;
  }

  .amount-row {
    grid-template-columns: minmax(0, 1fr) 70px;
  }

  .amount-row input {
    min-height: 50px;
    font-size: 20px;
  }

  .quote div {
    align-items: flex-start;
    flex-direction: column;
  }

  .quote strong {
    text-align: left;
  }

  .address-box {
    grid-template-columns: 1fr;
  }

  .address-box strong,
  .address-box .small-button {
    grid-column: auto;
    grid-row: auto;
  }

  .toast {
    right: 12px;
    bottom: 12px;
    max-width: calc(100% - 24px);
  }
}

@media (max-width: 380px) {
  .brand span {
    max-width: 116px;
  }

  #connect-btn {
    min-width: 118px;
    font-size: 12px;
  }

  h1 {
    font-size: 30px;
  }

  .lead {
    font-size: 15px;
  }

  .summary-grid {
    gap: 8px;
  }

  .summary-grid div {
    padding: 10px;
  }

  .summary-grid strong {
    font-size: 14px;
  }
}
