/* styles.css — "fake unicorn" theme. Looks expensive on purpose. */

/* Dark is the default. The theme is set on <html data-theme="…"> by an inline
   script in index.html (system preference, or a saved choice) before first
   paint, and flipped by the header toggle. Every surface reads from these
   variables so both themes stay in sync. */
:root,
:root[data-theme="dark"] {
  --bg: #0a0a0f;
  --card: rgba(255, 255, 255, 0.04);
  --card-border: rgba(255, 255, 255, 0.10);
  --text: #f4f4f8;
  --ink: #e6e6f0;
  /* body prose */
  --muted: #9a9ab0;
  --accent: #a78bfa;
  --accent-2: #22d3ee;
  --accent-3: #f472b6;
  --good: #34d399;
  --gold: #fbbf24;
  --fill-1: rgba(255, 255, 255, 0.04);
  /* subtle surface */
  --fill-2: rgba(255, 255, 255, 0.06);
  /* button / row */
  --fill-3: rgba(255, 255, 255, 0.12);
  /* hover */
  --elevated: #15151f;
  /* modal */
  --radius: 20px;
  --maxw: 680px;
  /* Fixed brand gradient for buttons/bars (vivid, theme-independent). */
  --grad: linear-gradient(120deg, #a78bfa, #22d3ee);
  /* Gradient used for clipped TEXT — darkened in light mode for contrast. */
  --grad-text: linear-gradient(120deg, #a78bfa, #22d3ee);
  --body-glow-1: rgba(167, 139, 250, 0.18);
  --body-glow-2: rgba(34, 211, 238, 0.14);
}

:root[data-theme="light"] {
  --bg: #f5f6fb;
  --card: #ffffff;
  --card-border: rgba(14, 18, 42, 0.12);
  --text: #14162a;
  --ink: #2a2f45;
  --muted: #5b6275;
  --accent: #7c3aed;
  --accent-2: #0891b2;
  --accent-3: #db2777;
  --good: #059669;
  --gold: #b45309;
  --fill-1: rgba(14, 18, 42, 0.035);
  --fill-2: rgba(14, 18, 42, 0.06);
  --fill-3: rgba(14, 18, 42, 0.11);
  --elevated: #ffffff;
  /* --grad stays vivid (dark text reads on it in both themes); text gradient darkens. */
  --grad-text: linear-gradient(120deg, #7c3aed, #0891b2);
  --body-glow-1: rgba(124, 58, 237, 0.10);
  --body-glow-2: rgba(8, 145, 178, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  overflow-x: hidden;
}

body {
  background:
    radial-gradient(900px 500px at 15% -10%, var(--body-glow-1), transparent 60%),
    radial-gradient(800px 500px at 100% 0%, var(--body-glow-2), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.wrap {
  width: 100%;
  max-width: var(--maxw);
  padding: 28px 20px 90px;
}

.hidden {
  display: none !important;
}

/* ---- header / hero (persistent on every view, divider anchors it on top) ---- */
.masthead {
  text-align: center;
  margin: 0 0 30px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--card-border);
}

.masthead .kicker {
  display: inline-block;
  font-size: 11.5px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-2);
  font-weight: 700;
  margin: 0 0 14px;
  padding: 5px 14px;
  border: 1px solid var(--card-border);
  border-radius: 999px;
  background: var(--fill-1);
}

/* logo lockup: faceted mark + gradient wordmark, as one unit */
.masthead h1.brand-lockup {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(8px, 2vw, 16px);
  margin: 0;
  background: none;
  line-height: 1;
}

.brand-word {
  font-size: clamp(38px, 8.5vw, 66px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 0.95;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.masthead p {
  color: var(--muted);
  margin: 8px 0 0;
  font-size: 15px;
}

/* ---- the pitch card ---- */
.card {
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 28px;
  backdrop-filter: blur(12px);
  box-shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.8), inset 0 1px 0 var(--fill-1);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, var(--fill-1), transparent 30%);
}

.card.flash {
  animation: cardflash 0.5s ease;
}

@keyframes cardflash {
  0% {
    transform: scale(0.985);
    opacity: 0.4;
  }

  100% {
    transform: scale(1);
    opacity: 1;
  }
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 6px;
}

.brand .logo {
  font-size: 40px;
  line-height: 1;
  filter: drop-shadow(0 6px 14px rgba(167, 139, 250, 0.4));
}

.brand .name {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.tagline {
  color: var(--accent-2);
  font-weight: 600;
  margin: 2px 0 14px;
  font-size: 16px;
}

/* ---- budget readout — the raised amount is the hero of the card ---- */
.budget {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  padding: 16px 0 6px;
  margin-bottom: 4px;
  border-top: 1px solid var(--card-border);
}

.budget .amount {
  font-size: clamp(52px, 13vw, 84px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.02em;
  background: linear-gradient(120deg, var(--good), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.budget .amount.bump {
  animation: bump 0.4s ease;
  transform-origin: left center;
}

@keyframes bump {
  0% {
    transform: scale(1);
  }

  40% {
    transform: scale(1.1);
  }

  100% {
    transform: scale(1);
  }
}

.budget .label {
  font-size: 13px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.budget .rank {
  font-size: 13px;
  font-weight: 700;
  color: var(--gold);
  margin-top: 2px;
}

.section-label {
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 18px 0 6px;
}

.section-body {
  margin: 0;
  font-size: 16px;
  color: var(--ink);
}

/* ---- metrics ---- */
.metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 22px 0 6px;
}

.metric {
  background: var(--fill-1);
  border: 1px solid var(--card-border);
  border-radius: 14px;
  padding: 14px 16px;
}

.metric .value {
  font-size: 22px;
  font-weight: 800;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.metric .label {
  font-size: 12px;
  color: var(--muted);
  margin-top: 2px;
}

/* ---- round + quote ---- */
.round {
  margin: 22px 0 0;
  padding: 16px 18px;
  border-radius: 14px;
  background: linear-gradient(120deg, rgba(167, 139, 250, 0.16), rgba(34, 211, 238, 0.10));
  border: 1px solid rgba(167, 139, 250, 0.3);
  font-weight: 700;
  font-size: 17px;
}

.quote {
  margin: 20px 0 0;
  border-left: 3px solid var(--accent-3);
  padding: 4px 0 4px 16px;
}

.quote .q {
  font-style: italic;
  font-size: 16px;
  color: var(--ink);
}

.quote .by {
  color: var(--muted);
  font-size: 13px;
  margin-top: 6px;
}

/* ---- controls ---- */
.controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-top: 26px;
}

button, .btn-primary, .btn-ghost, .btn-fund {
  display: inline-block;
  font: inherit;
  cursor: pointer;
  border: none;
  border-radius: 999px;
  padding: 13px 22px;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  transition: transform 0.08s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  color: var(--text);
}

button:active {
  transform: translateY(1px) scale(0.99);
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* primary CTAs: bigger, white text, and a gentle attention pulse */
.btn-primary,
.btn-fund {
  color: #fff;
  font-size: 17px;
  font-weight: 800;
  padding: 17px 32px;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.32);
  animation: cta-pulse 2.2s ease-in-out infinite;
}

.btn-primary:hover,
.btn-fund:hover {
  animation-play-state: paused;
}

@keyframes cta-pulse {

  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.04);
  }
}

.btn-primary {
  background: var(--grad);
  box-shadow: 0 14px 34px -10px rgba(167, 139, 250, 0.7);
}

.btn-primary:hover:not(:disabled) {
  box-shadow: 0 20px 48px -10px rgba(167, 139, 250, 0.95);
}

.btn-fund {
  background: linear-gradient(120deg, var(--good), #10b981);
  box-shadow: 0 14px 34px -10px rgba(52, 211, 153, 0.65);
}

.btn-fund:hover:not(:disabled) {
  box-shadow: 0 20px 48px -10px rgba(52, 211, 153, 0.9);
}

.btn-ghost {
  background: var(--fill-2);
  border: 1px solid var(--card-border);
}

.btn-ghost:hover {
  background: var(--fill-3);
}

/* ---- build theatre ---- */
.build {
  margin-top: 20px;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  background: #07070d;
  overflow: hidden;
}

.build .progress {
  height: 4px;
  background: var(--fill-2);
}

.build .progress-bar {
  height: 100%;
  width: 0%;
  background: var(--grad);
  transition: width 0.3s ease;
}

.build .log {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  color: #b8f5d8;
  padding: 14px 16px;
  max-height: 200px;
  overflow-y: auto;
}

.build .log-line {
  padding: 2px 0;
  opacity: 0;
  animation: fadein 0.3s ease forwards;
  white-space: pre-wrap;
}

.build .log-line.done {
  color: var(--gold);
  font-weight: 700;
}

@keyframes fadein {
  from {
    opacity: 0;
    transform: translateY(4px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

/* ---- toast ---- */
.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  transform: translateX(-50%) translateY(24px) scale(0.96);
  background: #14141c;
  border: 1px solid rgba(167, 139, 250, 0.45);
  color: #f4f4f8;
  padding: 15px 26px;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.01em;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s cubic-bezier(0.2, 0.9, 0.3, 1.3);
  box-shadow: 0 18px 60px -16px rgba(167, 139, 250, 0.55), 0 12px 34px -12px rgba(0, 0, 0, 0.85);
  max-width: min(90vw, 520px);
  text-align: center;
  z-index: 90;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0) scale(1);
}

/* ---- leaderboard ---- */
.leaderboard {
  margin-top: 40px;
}

.lb-title {
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 12px;
  text-align: center;
}

.lb-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.lb-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  text-align: left;
  background: var(--fill-1);
  border: 1px solid var(--card-border);
  border-radius: 12px;
  padding: 10px 14px;
  color: var(--text);
  font-weight: 600;
}

.lb-row:hover {
  background: var(--fill-2);
}

.lb-row .lb-rank {
  font-size: 13px;
  color: var(--muted);
  width: 28px;
}

.lb-row:nth-child(1) .lb-rank {
  color: var(--gold);
}

.lb-row .lb-logo {
  font-size: 20px;
}

.lb-row .lb-name {
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lb-row .lb-amt {
  font-weight: 800;
  background: linear-gradient(120deg, var(--good), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lb-empty {
  text-align: center;
  color: var(--text);
  font-size: 17px;
  font-weight: 700;
  padding: 28px 18px;
  border: 1px dashed var(--card-border);
  border-radius: 16px;
  background: var(--fill-1);
}

/* ---- footer ---- */
.foot {
  text-align: center;
  color: var(--muted);
  font-size: 12px;
  margin-top: 34px;
}

.foot .disclaimer {
  display: block;
  margin-top: 6px;
  opacity: 0.7;
}

/* ---- mobile ---- */
@media (max-width: 560px) {
  .wrap {
    padding: 20px 16px 80px;
  }

  .masthead .kicker {
    letter-spacing: 0.14em;
    font-size: 10.5px;
    padding: 5px 11px;
  }

  .card {
    padding: 22px;
  }

  .metrics {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .brand .name {
    font-size: 24px;
  }

  .controls button {
    flex: 1 1 auto;
  }
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .build .log-line {
    opacity: 1;
  }
}

/* =====================================================================
   PLATFORM ADDITIONS (top bar, account chip, views, build page, auth)
   ===================================================================== */

/* ---- top bar: nav + account chip ---- */
/* Always two centered rows: menu links on row 1, account/utilities on row 2. */
.topbar {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 26px 0 0;
}

.nav {
  display: flex;
  gap: 4px 6px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: 100%;
}

.nav a {
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
  text-decoration: none;
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid transparent;
  white-space: nowrap;
}

.nav a:hover {
  color: var(--text);
  background: var(--fill-1);
}

.masthead-sub {
  color: var(--muted);
  margin: 16px auto 0;
  font-size: clamp(15px, 2.2vw, 18px);
  line-height: 1.55;
  text-align: center;
  text-wrap: balance;
}

.masthead-sub strong {
  color: var(--text);
  font-weight: 800;
}

.account {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
}

.account .chip-login,
.account .chip-logout {
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border-radius: 999px;
  padding: 7px 14px;
  border: 1px solid var(--card-border);
  background: var(--fill-2);
  color: var(--text);
}

.account .chip-login {
  background: var(--grad);
  color: #0a0a0f;
  border: none;
}

.account .chip-login:hover {
  box-shadow: 0 10px 24px -12px rgba(167, 139, 250, 0.8);
}

.account.is-in {
  background: var(--fill-1);
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 4px 6px 4px 14px;
}

.account .chip-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.account .chip-link:hover .chip-name {
  color: var(--accent-2);
}

.account .chip-name {
  font-weight: 800;
  font-size: 13px;
}

.account .chip-worth {
  font-size: 13px;
  font-weight: 800;
  background: linear-gradient(120deg, var(--good), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.account .chip-logout:hover {
  background: var(--fill-3);
}

/* ---- view sections + titles (centered to match the hero) ---- */
.view-title {
  text-align: center;
  font-size: clamp(22px, 4vw, 28px);
  font-weight: 800;
  margin: 0 0 6px;
  letter-spacing: -0.02em;
}

.view-sub {
  text-align: center;
  color: var(--muted);
  font-size: 15px;
  margin: 0 auto 22px;
  max-width: 520px;
  line-height: 1.5;
  text-wrap: balance;
}

/* ---- ownership badge on the card ---- */
.owner-badge {
  display: inline-block;
  margin: 10px 0 0;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: var(--gold);
  background: rgba(251, 191, 36, 0.10);
  border: 1px solid rgba(251, 191, 36, 0.30);
}

/* ---- build page (full theatre) ---- */
.build-page {
  text-align: center;
  padding: 24px 4px 8px;
}

.build-head {
  margin-bottom: 26px;
}

.build-logo {
  font-size: 60px;
  display: block;
  line-height: 1;
  filter: drop-shadow(0 8px 28px rgba(167, 139, 250, 0.4));
}

.build-name {
  font-size: 28px;
  font-weight: 800;
  margin: 12px 0 2px;
}

.build-sub {
  color: var(--muted);
  margin: 0;
}

.build-phase {
  font-size: 18px;
  font-weight: 700;
  min-height: 26px;
  margin: 10px 0;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.build-pct {
  font-size: 13px;
  color: var(--muted);
  margin-top: 8px;
  font-variant-numeric: tabular-nums;
}

.thinking {
  display: flex;
  gap: 8px;
  justify-content: center;
  height: 14px;
  margin: 8px 0 14px;
}

.thinking span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.4;
  animation: think 1.1s ease-in-out infinite;
}

.thinking span:nth-child(2) {
  animation-delay: 0.18s;
  background: var(--accent-2);
}

.thinking span:nth-child(3) {
  animation-delay: 0.36s;
  background: var(--accent-3);
}

@keyframes think {

  0%,
  80%,
  100% {
    transform: translateY(0);
    opacity: 0.35;
  }

  40% {
    transform: translateY(-8px);
    opacity: 1;
  }
}

.progress.big {
  height: 10px;
  background: var(--fill-2);
  border-radius: 999px;
  overflow: hidden;
  max-width: 460px;
  margin: 10px auto 0;
}

.progress.big .progress-bar {
  height: 100%;
  width: 0%;
  background: var(--grad);
  transition: width 0.4s ease;
  position: relative;
}

.progress.big .progress-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.45), transparent);
  animation: shimmer 1.4s linear infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

.build-page .log {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  color: #b8f5d8;
  text-align: left;
  background: #07070d;
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 14px 16px;
  max-height: 260px;
  overflow-y: auto;
  margin: 20px auto 18px;
  max-width: 520px;
}

.build-page .log-line {
  padding: 2px 0;
  opacity: 0;
  animation: fadein 0.3s ease forwards;
  white-space: pre-wrap;
}

.build-page .log-line.done {
  color: var(--gold);
  font-weight: 700;
}

/* ---- founder profile header — net worth is the hero, big + live ---- */
.founder-head {
  text-align: center;
  margin-bottom: 26px;
}

.founder-worth-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.founder-worth {
  line-height: 1;
  margin: 2px 0 8px;
}

.founder-worth .amount {
  font-size: clamp(56px, 14vw, 92px);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
  background: linear-gradient(120deg, var(--good), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  display: inline-block;
}

.founder-worth .amount.bump {
  animation: bump 0.5s ease;
}

.founder-head .founder-name {
  font-size: clamp(20px, 4vw, 26px);
  font-weight: 800;
  margin: 0;
}

.founder-meta {
  color: var(--muted);
  font-size: 14px;
  margin-top: 6px;
}

.founder-actions {
  margin-top: 16px;
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---- leaderboard rows: owner subline ---- */
.lb-row .lb-name {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.lb-row .lb-name-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.lb-row .lb-owner {
  font-size: 12px;
  font-weight: 500;
  color: var(--muted);
}

/* ---- pagination ---- */
.pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 18px;
}

.pager-btn {
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 8px 16px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: var(--fill-2);
  color: var(--text);
}

.pager-btn:hover:not(:disabled) {
  background: var(--fill-3);
}

.pager-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.pager-label {
  font-size: 13px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
}

/* ---- auth modal ---- */
.auth-overlay {
  position: fixed;
  inset: 0;
  background: rgba(4, 4, 10, 0.72);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  z-index: 100;
  animation: fadein 0.2s ease forwards;
}

.auth-modal {
  position: relative;
  width: 100%;
  max-width: 420px;
  background: var(--elevated);
  border: 1px solid var(--card-border);
  border-radius: 20px;
  padding: 26px 24px 28px;
  box-shadow: 0 40px 120px -30px rgba(0, 0, 0, 0.8);
}

.auth-close {
  position: absolute;
  top: 12px;
  right: 14px;
  background: none;
  border: none;
  color: var(--muted);
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.auth-close:hover {
  color: var(--text);
}

.auth-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 18px;
}

.auth-tabs button {
  flex: 1;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 9px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: var(--fill-1);
  color: var(--muted);
}

.auth-tabs button.active {
  background: var(--grad);
  color: #0a0a0f;
  border: none;
}

.auth-title {
  font-size: 20px;
  font-weight: 800;
  margin: 0 0 6px;
}

.auth-sub {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 16px;
}

.auth-field {
  display: block;
  margin-bottom: 14px;
}

.auth-field span {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.auth-field input {
  width: 100%;
  font: inherit;
  padding: 11px 13px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: var(--fill-1);
  color: var(--text);
}

.auth-field input:focus {
  outline: none;
  border-color: var(--accent);
}

.auth-submit {
  width: 100%;
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  padding: 12px;
  border-radius: 12px;
  border: none;
  background: var(--grad);
  color: #0a0a0f;
}

.auth-submit:hover:not(:disabled) {
  box-shadow: 0 14px 36px -12px rgba(167, 139, 250, 0.8);
}

.auth-submit:disabled {
  opacity: 0.6;
  cursor: default;
}

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

.auth-msg.is-error {
  color: var(--accent-3);
}

.auth-warn {
  font-size: 13px;
  font-weight: 700;
  color: var(--gold);
  background: rgba(251, 191, 36, 0.10);
  border: 1px solid rgba(251, 191, 36, 0.30);
  border-radius: 10px;
  padding: 10px 12px;
  margin: 0 0 14px;
}

.auth-key {
  display: flex;
  gap: 8px;
  align-items: stretch;
  margin-bottom: 16px;
}

.auth-key code {
  flex: 1;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  word-break: break-all;
  background: #07070d;
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 11px 12px;
  color: var(--accent-2);
}

.auth-copy {
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  padding: 0 16px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: var(--fill-2);
  color: var(--text);
}

.auth-copy:hover {
  background: var(--fill-3);
}

/* ---- live net-worth grow flash on the header chip ---- */
.account .chip-worth.bump {
  animation: bump 0.5s ease;
}

.lb-row .lb-amt.bump {
  animation: bump 0.5s ease;
}

/* ---- theme toggle ---- */
.topbar-right {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.theme-toggle {
  font-size: 15px;
  line-height: 1;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid var(--card-border);
  background: var(--fill-2);
  color: var(--text);
  cursor: pointer;
}

.theme-toggle:hover {
  background: var(--fill-3);
}

/* ---- brand mark (faceted unicorn) in the masthead; fills follow the theme ---- */
.brand-mark {
  width: clamp(42px, 9.5vw, 62px);
  height: auto;
  display: block;
  margin: 0;
  flex: none;
  filter: drop-shadow(0 10px 26px rgba(167, 139, 250, 0.42));
}

.brand-mark .mk-body {
  fill: var(--text);
}

.brand-mark .mk-cheek {
  fill: var(--muted);
}

.brand-mark .mk-eye {
  fill: var(--bg);
}

/* ---- transfer credits view ---- */
.transfer-balance {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
  margin: 0 auto 14px;
}

.transfer-balance .label {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.transfer-balance .amount {
  font-size: 26px;
  font-weight: 800;
  background: linear-gradient(120deg, var(--good), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.transfer-gag {
  font-size: 13px;
  font-weight: 700;
  color: var(--gold);
  background: rgba(251, 191, 36, 0.10);
  border: 1px solid rgba(251, 191, 36, 0.30);
  border-radius: 12px;
  padding: 12px 14px;
  margin: 0 auto 18px;
  max-width: 480px;
  text-align: center;
}

.transfer-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
  max-width: 420px;
  margin: 0 auto;
}

.transfer-field {
  display: block;
}

.transfer-field span {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.transfer-field select,
.transfer-field input {
  width: 100%;
  font: inherit;
  padding: 11px 13px;
  border-radius: 10px;
  border: 1px solid var(--card-border);
  background: var(--fill-1);
  color: var(--text);
}

.transfer-field select:focus,
.transfer-field input:focus {
  outline: none;
  border-color: var(--accent);
}

.transfer-msg {
  font-size: 13px;
  margin: 4px 0 0;
  color: var(--muted);
}

.transfer-msg.is-error {
  color: var(--accent-3);
}

/* ---- support buttons (footer): Ko-fi + Patreon ---- */
.support-why {
  max-width: 520px;
  margin: 0 auto 14px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
  text-align: center;
}

.support {
  display: flex;
  gap: 10px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.tip-btn {
  display: inline-block;
  padding: 6px 13px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
  color: var(--muted);
  background: transparent;
  border: 1px solid var(--card-border);
  box-shadow: none;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

.tip-btn:hover {
  color: var(--text);
  background: var(--fill-1);
  border-color: var(--fill-3);
}

/* ---- shop ---- */
.shop-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
  max-width: 560px;
  margin: 0 auto;
}

.shop-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: var(--card);
  border: 1px solid var(--card-border);
  border-radius: 16px;
  padding: 20px;
}

.shop-item .shop-price {
  font-size: 26px;
  font-weight: 800;
  background: var(--grad-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.shop-item .shop-name {
  margin: 0;
  font-size: 17px;
  font-weight: 800;
}

.shop-item .shop-desc {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  flex: 1;
}

.shop-buy {
  margin-top: 6px;
  text-align: center;
  text-decoration: none;
}

.shop-note {
  font-size: 12px;
  color: var(--muted);
  margin-top: 18px;
  text-align: center;
}

/* ---- Seedbuck currency glyph (Ƨ) before money amounts ---- */
.budget .amount::before,
.founder-worth .amount::before,
.transfer-balance .amount::before,
.account .chip-worth::before,
.lb-row .lb-amt::before {
  content: "";
  display: inline-block;
  width: 0.62em;
  height: 0.92em;
  margin-right: 0.14em;
  vertical-align: -0.1em;
  background: url("seedbuck.svg") center / contain no-repeat;
}

/* ---- view content alignment: standalone prompts/buttons center; forms/cards stay left ---- */
#transfer-body,
#shop-body {
  text-align: center;
}

.transfer-form,
.shop-item {
  text-align: left;
}

/* ---- the big money numbers read as glowing trophies ---- */
.budget .amount,
.founder-worth .amount {
  filter: drop-shadow(0 2px 22px rgba(34, 211, 238, 0.28));
}

/* ---- celebration FX (confetti canvas is inline-styled in JS) ---- */
.fx-float {
  position: fixed;
  transform: translate(-50%, 0);
  z-index: 121;
  pointer-events: none;
  font-size: 24px;
  font-weight: 800;
  white-space: nowrap;
  color: var(--good);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
  animation: float-up 1.1s ease-out forwards;
}

@keyframes float-up {
  0% {
    opacity: 0;
    transform: translate(-50%, 10px) scale(0.9);
  }

  15% {
    opacity: 1;
  }

  100% {
    opacity: 0;
    transform: translate(-50%, -66px) scale(1.12);
  }
}

.fx-flash {
  position: fixed;
  inset: 0;
  z-index: 119;
  pointer-events: none;
  background: radial-gradient(circle at 50% 42%, rgba(167, 139, 250, 0.38), rgba(34, 211, 238, 0.18) 42%, transparent 70%);
  animation: flash-fade 0.7s ease-out forwards;
}

@keyframes flash-fade {
  0% {
    opacity: 0;
  }

  18% {
    opacity: 1;
  }

  100% {
    opacity: 0;
  }
}

/* ---- home "top startups right now" peek ---- */
.home-peek {
  margin-top: 30px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.home-peek:empty {
  display: none;
}

.home-peek .peek-title {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 4px;
}

.home-peek .peek-more {
  text-align: center;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent-2);
  text-decoration: none;
  margin-top: 6px;
}

.home-peek .peek-more:hover {
  text-decoration: underline;
}