:root {
  --bg: #0d0d0e;
  --bg-raised: #17171a;
  --bg-input: #101012;
  --line: #2a2a2f;
  --text: #f2f2f2;
  --muted: #9a9aa2;
  --accent: #fcaf17;
  --accent-dark: #d18e0c;
  --good: #3ecf6e;
  --bad: #ff5a4f;
  --radius: 6px;
  font-family: "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { margin: 0 0 12px; font-weight: 700; letter-spacing: 0.01em; }
h2 { font-size: 20px; }
h3 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.muted { color: var(--muted); }
.center { text-align: center; }
[hidden] { display: none !important; }

/* Top bar: black with the yellow rule, like the club's own header. */
.topbar {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 0 28px;
  height: 64px;
  background: #000;
  border-bottom: 3px solid var(--accent);
  position: sticky;
  top: 0;
  z-index: 5;
}
.brand { display: flex; align-items: center; gap: 12px; color: var(--text); }
.brand:hover { text-decoration: none; }
.brand-mark {
  display: grid; place-items: center;
  width: 38px; height: 38px;
  background: var(--accent); color: #000;
  font-weight: 900; font-size: 16px; letter-spacing: -0.04em;
  border-radius: 4px;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-size: 17px; }
.brand-text small { color: var(--muted); font-size: 11px; }
.nav { display: flex; gap: 4px; height: 100%; }
.nav a {
  display: flex; align-items: center; gap: 6px;
  padding: 0 14px; color: var(--muted);
  font-weight: 600; text-transform: uppercase; font-size: 13px; letter-spacing: 0.08em;
  border-bottom: 3px solid transparent; margin-bottom: -3px;
}
.nav a:hover { color: var(--text); text-decoration: none; }
.nav a.active { color: var(--text); border-bottom-color: var(--text); }
.pill { background: var(--accent); color: #000; border-radius: 9px; padding: 0 7px; font-size: 11px; }
.me { margin-left: auto; display: flex; align-items: center; gap: 10px; font-weight: 600; }

main { flex: 1; width: 100%; max-width: 1080px; margin: 0 auto; padding: 32px 24px 48px; }

.card {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
}

label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
label small { font-weight: 400; }
input {
  font: inherit; font-size: 15px; color: var(--text);
  background: var(--bg-input); border: 1px solid var(--line); border-radius: 4px;
  padding: 11px 12px; min-width: 0;
}
input:focus { outline: none; border-color: var(--accent); }
button {
  font: inherit; font-weight: 700; font-size: 14px; letter-spacing: 0.04em;
  border-radius: 4px; padding: 11px 20px; cursor: pointer; border: 1px solid var(--line);
  background: transparent; color: var(--text);
}
button:disabled { opacity: 0.5; cursor: progress; }
button.primary { background: var(--accent); border-color: var(--accent); color: #000; text-transform: uppercase; }
button.primary:hover { background: var(--accent-dark); }
button.danger { border-color: var(--bad); color: var(--bad); }
button.small { padding: 6px 12px; font-size: 12px; }
button.link { border: 0; padding: 0; color: var(--muted); font-weight: 600; }
button.link:hover { color: var(--text); }
.error { color: var(--bad); margin: 0; font-size: 14px; }

/* Sign in / register: art on the left, form on the right. */
.auth { display: grid; grid-template-columns: 1fr 400px; gap: 32px; align-items: center; min-height: 60vh; }
.auth-art h1 { font-size: 44px; }
.auth-art p { color: var(--muted); font-size: 18px; max-width: 420px; }
.auth-card { display: flex; flex-direction: column; gap: 16px; margin: 0; }

.hero {
  border-radius: var(--radius);
  background: linear-gradient(120deg, #2a1d05 0%, #121214 55%, #0d0d0e 100%);
  border: 1px solid var(--line);
  padding: 32px;
  margin-bottom: 20px;
}
.hero-inner { display: flex; align-items: center; gap: 24px; }
.hero h1 { font-size: 34px; margin-bottom: 6px; }

.avatar {
  display: inline-grid; place-items: center; flex: none;
  border-radius: 50%; color: #000; font-weight: 800; text-transform: uppercase;
}
.avatar.small { width: 30px; height: 30px; font-size: 13px; }
.avatar.medium { width: 40px; height: 40px; font-size: 16px; }
.avatar.large { width: 96px; height: 96px; font-size: 38px; border: 3px solid var(--accent); }

.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 20px; }
.grid .card { margin: 0; }
.stat .big { font-size: 40px; font-weight: 800; margin: 0 0 6px; }
.steps { margin: 0; padding-left: 20px; line-height: 1.9; color: var(--muted); }
.steps strong { color: var(--text); }

.inline { display: flex; gap: 12px; }
.inline input { flex: 1; }
.stack { display: flex; flex-direction: column; gap: 16px; max-width: 460px; }

.people { list-style: none; margin: 0; padding: 0; }
.people li {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 0; border-top: 1px solid var(--line);
}
.people li:first-child { border-top: 0; }
.people .who { flex: 1; min-width: 0; }
.people .who strong { display: block; }
.people .actions { display: flex; gap: 8px; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); margin-right: 6px; }
.dot.on { background: var(--good); }

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

.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%);
  background: var(--text); color: #000; font-weight: 600;
  padding: 12px 20px; border-radius: 4px; box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}
.toast.bad { background: var(--bad); color: #fff; }

/* Shark cards */
.store-hero { display: flex; justify-content: space-between; align-items: center; gap: 24px; }
.store-hero .bank { text-align: right; }
.big { font-size: 40px; font-weight: 800; margin: 0; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-bottom: 20px; }
.shark {
  position: relative; overflow: hidden;
  background: linear-gradient(150deg, #1f2a3a 0%, #121418 70%);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; display: flex; flex-direction: column; gap: 8px; min-height: 180px;
}
.shark::after {
  content: "$"; position: absolute; right: -6px; bottom: -34px;
  font-size: 150px; font-weight: 900; color: rgba(255, 255, 255, 0.05);
}
.shark h3 { color: var(--text); font-size: 14px; margin: 0; }
.shark .amount { font-size: 30px; font-weight: 800; color: var(--good); }
.shark .price { color: var(--muted); font-size: 13px; }
.shark button { margin-top: auto; align-self: flex-start; position: relative; z-index: 1; }
.shark.tier-red { background: linear-gradient(150deg, #4a1414 0%, #151213 70%); }
.shark.tier-tiger { background: linear-gradient(150deg, #4a3110 0%, #151413 70%); }
.shark.tier-bull { background: linear-gradient(150deg, #13304a 0%, #121418 70%); }
.shark.tier-greatwhite { background: linear-gradient(150deg, #3a3f46 0%, #141517 70%); }
.shark.tier-whale { background: linear-gradient(150deg, #0f3d3a 0%, #121615 70%); }
.shark.tier-megalodon { background: linear-gradient(150deg, #3d2a07 0%, #17130b 60%); border-color: var(--accent); }
.warn { border-color: var(--accent); }
.plain { list-style: none; margin: 0; padding: 0; }
.plain li { padding: 8px 0; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 16px; }
.plain li:first-child { border-top: 0; }

/* Admin */
.table { width: 100%; border-collapse: collapse; margin: 16px 0; font-size: 14px; }
.table th { text-align: left; color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; padding: 8px; border-bottom: 1px solid var(--line); }
.table td { padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table td input { width: 100%; max-width: 150px; padding: 7px 9px; font-size: 14px; }
.table .who { display: flex; align-items: center; gap: 10px; }
.tag { font-size: 11px; font-weight: 800; letter-spacing: 0.08em; padding: 2px 7px; border-radius: 3px; background: var(--accent); color: #000; vertical-align: middle; }
.tag.bad { background: var(--bad); color: #fff; }
.pager { display: flex; align-items: center; gap: 12px; justify-content: flex-end; }
.money-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; max-width: 460px; }
label.check { flex-direction: row; align-items: center; gap: 10px; margin: 8px 0; color: var(--text); }
.row-actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
#stats-form { display: flex; flex-direction: column; gap: 8px; }
#stats-form button { align-self: flex-start; }

@media (max-width: 760px) {
  .cards { grid-template-columns: 1fr; }
  .store-hero { flex-direction: column; align-items: flex-start; }
  .store-hero .bank { text-align: left; }
  .table { display: block; overflow-x: auto; }
  .topbar { gap: 12px; padding: 0 16px; height: auto; min-height: 56px; flex-wrap: wrap; }
  .brand-text small { display: none; }
  .nav { order: 3; width: 100%; height: 44px; overflow-x: auto; }
  .me span:not(.avatar) { display: none; }
  main { padding: 20px 16px 40px; }
  .auth { grid-template-columns: 1fr; min-height: 0; }
  .auth-art h1 { font-size: 30px; }
  .grid { grid-template-columns: 1fr; }
  .hero-inner { flex-direction: column; align-items: flex-start; }
  .inline { flex-direction: column; }
}
