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

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --text:      #eaf2f8;
  --muted:     #93a4b8;
  --accent:    #2f7bff;
  --accent2:   #1560e0;
  --border:    #1c2735;
  --card-bg:   rgba(255,255,255,0.04);
  --max-width: 960px;
}

/* ── Brand wordmark (injected into .logo by auth.js) ─────────────────────────── */
.vs-wordmark {
  display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
  font-style: italic; font-weight: 800; letter-spacing: 0.02em; font-size: 1.05rem;
  color: var(--text); line-height: 1;
}
.vs-wordmark b { color: var(--accent); font-weight: 800; margin-left: 5px; }
.vs-mark { width: 44px; height: 44px; flex-shrink: 0; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  background-color: #0b0f14;
  background-image:
    radial-gradient(900px 620px at 82% -8%, rgba(25,185,214,0.10), transparent),
    radial-gradient(760px 520px at -5% 0%, rgba(61,220,132,0.08), transparent);
  background-attachment: fixed;
}

/* ── Nav ─────────────────────────────────────────────────────────────────── */
header {
  border-bottom: 1px solid var(--border);
  padding: 0.85rem 2rem;
  background: rgba(11,15,20,0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 50;
}

nav {
  max-width: var(--max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
  color: var(--text);
}

.nav-links {
  display: flex;
  gap: 1.5rem;
}

nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.9rem;
}

nav a:hover,
.nav-active {
  color: var(--text);
}

.nav-active {
  font-weight: 600;
}

/* ── Top-nav sport links ──────────────────────────────────────────────────── */

.pp-sport-bar {
  display: flex;
  align-items: center;
  gap: 0.15rem;
  margin-right: 0.75rem;
}

.pp-sport-link {
  color: #c8b89a;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 0.3rem 0.65rem;
  border-radius: 4px;
  letter-spacing: 0.01em;
  white-space: nowrap;
  transition: background 0.12s, color 0.12s;
}

.pp-sport-link:hover {
  color: #f5f0e8;
  background: rgba(245,240,232,0.1);
}

.pp-sport-active {
  color: #9aba70;
  background: rgba(154,186,112,0.12);
}

@media (max-width: 600px) {
  .pp-sport-bar { display: none; }
}

/* ── Hamburger button ─────────────────────────────────────────────────────── */

.pp-hamburger {
  background: none;
  border: 1px solid rgba(245,240,232,0.25);
  border-radius: 5px;
  padding: 7px 9px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  align-items: center;
  justify-content: center;
  transition: background 0.15s, border-color 0.15s;
}

.pp-hamburger:hover {
  background: rgba(245,240,232,0.1);
  border-color: rgba(245,240,232,0.45);
}

.pp-hamburger span {
  display: block;
  width: 20px;
  height: 2px;
  background: #f5f0e8;
  border-radius: 1px;
}

/* ── Drawer overlay ───────────────────────────────────────────────────────── */

.pp-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 1000000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
}

.pp-nav-overlay.pp-open {
  opacity: 1;
  pointer-events: auto;
}

/* ── Slide-out drawer ─────────────────────────────────────────────────────── */

.pp-nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 270px;
  background: #2e2218;
  border-left: 2px solid #3a2e1e;
  z-index: 1000001;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.24s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  overflow: hidden;
}

.pp-nav-drawer.pp-open {
  transform: translateX(0);
}

.pp-drawer-hdr {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid #3a2e1e;
  flex-shrink: 0;
}

.pp-drawer-brand {
  font-weight: 700;
  font-size: 0.95rem;
  color: #f5f0e8;
  letter-spacing: -0.01em;
}

.pp-drawer-close {
  background: none;
  border: none;
  color: #c8b89a;
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.pp-drawer-close:hover { color: #f5f0e8; }

.pp-drawer-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
  display: flex;
  flex-direction: column;
}

.pp-drawer-section-label {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #7a6a56;
  padding: 12px 18px 5px;
}

.pp-drawer-section-link {
  color: #9aba70;
  text-decoration: none;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  transition: color 0.12s;
}

.pp-drawer-section-link:hover {
  color: #b0d888;
}

.pp-drawer-link {
  display: block;
  padding: 10px 18px;
  color: #c8b89a;
  text-decoration: none;
  font-size: 0.92rem;
  border-left: 3px solid transparent;
  transition: background 0.12s, color 0.12s;
}

.pp-drawer-link:hover {
  background: rgba(245,240,232,0.06);
  color: #f5f0e8;
  border-left-color: transparent;
}

.pp-drawer-active {
  color: #9aba70;
  border-left-color: #9aba70;
  background: rgba(154,186,112,0.09);
  font-weight: 600;
}

.pp-drawer-active:hover {
  background: rgba(154,186,112,0.14);
  color: #b0d888;
}

.pp-drawer-foot {
  border-top: 1px solid #3a2e1e;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-shrink: 0;
}

.pp-drawer-user {
  font-family: monospace;
  font-size: 0.8rem;
  color: #5a8898;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pp-drawer-signout {
  font-size: 0.82rem;
  color: #c8b89a;
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}

.pp-drawer-signout:hover { color: #f5f0e8; }

/* ── Main content ─────────────────────────────────────────────────────────── */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

/* ── Hero ─────────────────────────────────────────────────────────────────── */
.hero {
  padding: 5rem 0 4rem;
  text-align: center;
}

.hero-eyebrow {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.hero h1 {
  font-size: clamp(2.8rem, 6vw, 4.5rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.08;
  color: var(--text);
  margin-bottom: 1.1rem;
}

.tagline {
  font-size: 1.15rem;
  color: var(--muted);
  max-width: 520px;
  margin: 0 auto;
  line-height: 1.6;
}

.hero-ctas {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-top: 2.25rem;
  flex-wrap: wrap;
}

.cta-btn {
  display: inline-block;
  padding: 0.72rem 1.85rem;
  border-radius: 4px;
  font-size: 0.9rem;
  font-weight: 700;
  text-decoration: none;
  letter-spacing: 0.01em;
  transition: opacity 0.15s, transform 0.1s;
}

.cta-btn:hover { opacity: 0.88; transform: translateY(-1px); }

.cta-primary {
  background: #7a5c3a;
  color: var(--text);
  border: 2px solid #a07a50;
}

.cta-secondary {
  background: transparent;
  color: var(--text);
  border: 2px solid var(--border);
}

.cta-secondary:hover { border-color: var(--accent); }

/* ── Sections ─────────────────────────────────────────────────────────────── */
section {
  padding: 3.5rem 0;
  border-top: 1px solid var(--border);
}

.hero + section {
  border-top: none;
}

section h2 {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

/* Clickable sport section headings on homepage */
.sport-section-link {
  color: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  padding: 0.1em 0.5em 0.1em 0;
  border-radius: 4px;
  transition: color 0.15s, background 0.15s;
}
.sport-section-link:hover {
  color: #fff;
  background: rgba(255,255,255,0.08);
  padding-left: 0.4em;
}

section p {
  color: var(--text);
  margin-bottom: 1rem;
}

section p:last-child {
  margin-bottom: 0;
}

/* ── Tool cards ───────────────────────────────────────────────────────────── */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

@media (max-width: 720px) {
  .tool-grid { grid-template-columns: 1fr; }
}

.tool-card {
  display: flex;
  flex-direction: column;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 1.6rem 1.4rem;
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.15s, background 0.15s, transform 0.1s;
}

.tool-card:hover {
  border-color: var(--accent);
  background: rgba(0,0,0,0.32);
  transform: translateY(-2px);
}

.tool-card-icon {
  font-size: 1.6rem;
  margin-bottom: 0.75rem;
  line-height: 1;
}

.tool-card-name {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.tool-card-desc {
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.6;
  flex: 1;
}

.tool-card-cta {
  display: inline-block;
  margin-top: 1.1rem;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.04em;
}

/* ── About-page credentials strip ────────────────────────────────────────── */
.cred-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem 1.25rem;
  margin-top: 1.25rem;
}

.cred-item {
  font-size: 0.82rem;
  color: var(--muted);
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 0.28rem 0.7rem;
}

/* ── Philosophy quote ─────────────────────────────────────────────────────── */
.pull-quote {
  border-left: 3px solid var(--accent);
  padding: 0.6rem 1.25rem;
  margin: 1.5rem 0;
  font-size: 1.1rem;
  font-style: italic;
  color: var(--text);
  line-height: 1.55;
}

/* ── Game canvas wrapper ──────────────────────────────────────────────────── */
.pong-wrapper {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.5rem;
}

#lacrosseCanvas {
  display: block;
  width: 100%;
  max-width: 680px;
  border: 3px solid #3a2e1e;
  image-rendering: pixelated;
}

.pong-hint {
  font-size: 0.78rem;
  color: var(--muted);
  font-family: monospace;
}

/* Game controls legend */
.game-controls {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 0.75rem;
  max-width: 680px;
}

.control-group {
  display: flex;
  align-items: baseline;
  gap: 0.75rem;
}

.control-key {
  font-family: monospace;
  font-size: 0.78rem;
  font-weight: 700;
  background: #3a2e1e;
  color: #f5f0e8;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  white-space: nowrap;
  min-width: 4rem;
  text-align: center;
  letter-spacing: 0.05em;
}

.control-desc {
  font-size: 0.85rem;
  color: var(--muted);
}

.control-note {
  margin-top: 0.5rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.6;
  border-left: 2px solid #4a6741;
  padding-left: 0.75rem;
}

/* ── Footer ───────────────────────────────────────────────────────────────── */
footer {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 2rem;
  border-top: 3px solid #3a2e1e;
  font-size: 0.85rem;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

footer a {
  color: var(--muted);
  text-decoration: none;
}

footer a:hover { color: var(--text); }
