/* Poker-Manager shared styles (home, join, rankings). The watch page has its own. */
:root {
  --bg: #000000;
  --panel: #181818;
  --panel-2: #1f1f1f;
  --panel-3: #272727;
  --line: #313131;
  --text: #f5f5f5;
  --muted: #9b9b9b;
  --accent: #ffcc33;
  --accent-ink: #131209;
  --danger: #ff6b5a;
  --ok: #5ad19a;
  --ease: cubic-bezier(0.32, 0.72, 0, 1);
  --font: "Geist", "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--bg); }
body {
  margin: 0; background: var(--bg); color: var(--text); font-family: var(--font);
  font-size: 16px; line-height: 24px; -webkit-font-smoothing: antialiased;
}
h1, h2, h3 { text-wrap: balance; font-weight: 600; margin: 0; }
p, li, dd { text-wrap: pretty; }
a { color: inherit; }
img, svg, canvas { display: block; }
.num { font-family: var(--mono); font-variant-numeric: tabular-nums; }

.skip { position: absolute; left: 16px; top: -48px; padding: 8px 12px; background: var(--accent); color: var(--accent-ink);
  border-radius: 8px; font-weight: 600; z-index: 100; transition: top 300ms var(--ease); }
.skip:focus { top: 16px; }

/* Floating island nav */
.nav { position: sticky; top: 0; z-index: 50; display: flex; justify-content: center; padding: 24px 16px 0; pointer-events: none; }
.nav-pill {
  pointer-events: auto; display: flex; align-items: center; gap: 4px; width: max-content; max-width: 100%;
  padding: 4px; border-radius: 9999px; border: 1px solid var(--line);
  background: rgba(24, 24, 24, 0.72); backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px);
}
.brand { display: flex; align-items: center; gap: 8px; padding: 4px 12px 4px 8px; text-decoration: none; font-weight: 600; font-size: 14px; line-height: 20px; }
.brand-mark { width: 24px; height: 24px; }
.nav a.link {
  padding: 8px 12px; border-radius: 9999px; text-decoration: none; font-size: 14px; line-height: 20px; font-weight: 600;
  color: var(--muted); transition: all 500ms var(--ease);
}
.nav a.link:hover { color: var(--text); background: var(--panel-3); }
.nav a.link[aria-current="page"] { color: var(--accent-ink); background: var(--accent); }
@media (max-width: 480px) { .brand span { display: none; } .nav a.link { padding: 8px; } }

main { display: block; }
.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.section { padding: 96px 0; }
.section-sm { padding: 48px 0; }
.kicker { color: var(--accent); font-size: 14px; line-height: 20px; font-weight: 600; margin: 0 0 12px; letter-spacing: 0.02em; }
.h2 { font-size: 36px; line-height: 40px; }
.lede { color: var(--muted); font-size: 18px; line-height: 28px; max-width: 680px; margin: 16px 0 0; }
@media (max-width: 720px) { .section { padding: 64px 0; } .h2 { font-size: 30px; line-height: 36px; } }

.grad { background: linear-gradient(90deg, #ffffff, #9b9b9b); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 8px 12px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--panel-3); color: var(--text); font: inherit; font-size: 16px; line-height: 24px;
  font-weight: 600; text-decoration: none; cursor: pointer; transition: all 500ms var(--ease);
}
.btn:hover { background: var(--line); transform: translateY(-1px); }
.btn:active { transform: scale(0.98); }
.btn:focus-visible, .input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent); outline-offset: 2px;
}
.btn-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-primary:hover { background: #ffd95c; }
.btn-sm { font-size: 14px; line-height: 20px; padding: 4px 12px; border-radius: 8px; }
.btn-danger { color: var(--danger); }
.btn[disabled] { opacity: 0.4; cursor: not-allowed; transform: none; }

/* Cards and forms */
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 24px; }
.card-inner { background: var(--panel-2); border-radius: 8px; padding: 12px; } /* 16 - 8 gap */
.input, select, textarea {
  width: 100%; padding: 8px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text);
  font: inherit; font-size: 16px; line-height: 24px; transition: border-color 400ms var(--ease);
}
textarea { min-height: 192px; resize: vertical; font-size: 14px; line-height: 20px; }
.input:hover, select:hover, textarea:hover { border-color: #4a4a4a; }
label { display: block; font-size: 14px; line-height: 20px; font-weight: 600; margin: 0 0 4px; }
.field { margin: 0 0 16px; }
.hint { color: var(--muted); font-size: 12px; line-height: 16px; margin: 4px 0 0; }
.error { color: var(--danger); font-size: 14px; line-height: 20px; margin: 8px 0 0; min-height: 20px; }
.muted { color: var(--muted); }
.pill { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 9999px; font-size: 12px; line-height: 16px;
  font-weight: 600; background: var(--panel-3); color: var(--muted); }
.pill.live { background: rgba(255, 107, 90, 0.16); color: var(--danger); }
.pill.ok { background: rgba(90, 209, 154, 0.14); color: var(--ok); }
.pill.gold { background: rgba(255, 204, 51, 0.14); color: var(--accent); }
.dot { width: 8px; height: 8px; border-radius: 9999px; background: currentColor; }

.skeleton { background: var(--panel-2); border-radius: 8px; position: relative; overflow: hidden; }
.skeleton::after { content: ""; position: absolute; inset: 0; transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.05), transparent); animation: shimmer 1.4s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }

/* Scroll reveal */
.reveal { opacity: 0; transform: translateY(64px); filter: blur(12px); transition: opacity 900ms var(--ease), transform 900ms var(--ease), filter 900ms var(--ease); }
.reveal.in { opacity: 1; transform: none; filter: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; filter: none; transition: none; }
  * { scroll-behavior: auto !important; }
}

.footer { border-top: 1px solid var(--line); padding: 32px 0; color: var(--muted); font-size: 14px; line-height: 20px; }
.footer .wrap { display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; }
.footer a { color: var(--muted); }

.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 24px); opacity: 0; padding: 8px 16px; border-radius: 12px;
  background: var(--panel-3); border: 1px solid var(--line); transition: all 500ms var(--ease); z-index: 80; font-size: 14px; line-height: 20px; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
@media (max-width: 600px) {
  .wrap { padding: 0 16px; }
  .nav { padding-top: 12px; }
  .card { border-radius: 16px; }
  .btn { min-height: 40px; }
}
