/* Shared Blacktop Scoreboard stylesheet for openHoops legal and utility pages. */
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/openhoops/fonts/barlow-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/openhoops/fonts/barlow-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/openhoops/fonts/barlow-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/openhoops/fonts/barlow-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow Condensed';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/openhoops/fonts/barlow-condensed-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Barlow Condensed';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/openhoops/fonts/barlow-condensed-700.woff2') format('woff2');
}

:root {
  color-scheme: dark;
  --oh-ground: #0D0E10;
  --oh-obsidian: #121316;
  --oh-surface: #181A1F;
  --oh-surface-2: #1B1D22;
  --oh-surface-3: #23252A;
  --oh-surface-4: #2A2C31;
  --oh-ink: #F2F3F5;
  --oh-body: #D6D8DE;
  --oh-muted: #989DA8;
  --oh-line: rgba(255, 255, 255, 0.09);
  --oh-line-strong: rgba(255, 255, 255, 0.16);
  --oh-gold: #FFC400;
  --oh-gold-hover: #FFD338;
  --oh-gold-soft: #FFD84D;
  --oh-green: #3EDC85;
  --oh-danger: #FF6B6B;
  --oh-shadow: 0 12px 28px rgba(0, 0, 0, 0.48);
  --oh-font-display: 'Barlow Condensed', 'Arial Narrow', Arial, sans-serif;
  --oh-font-body: 'Barlow', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

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

html {
  background: var(--oh-ground);
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  background: var(--oh-ground);
  color: var(--oh-body);
  font-family: var(--oh-font-body);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--oh-gold-soft);
  text-underline-offset: 3px;
}

a:hover {
  color: var(--oh-gold);
}

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--oh-gold);
  outline-offset: 3px;
}

[hidden],
.hidden {
  display: none !important;
}

/* Sticky Subpage Header */
.oh-sub-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(13, 14, 16, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--oh-line);
}

.oh-sub-header-inner {
  width: min(920px, calc(100% - 40px));
  margin: 0 auto;
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 0;
}

.oh-wordmark {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: var(--oh-ink);
  text-decoration: none;
  font-family: var(--oh-font-body);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.03em;
  line-height: 1;
  white-space: nowrap;
  flex-shrink: 0;
}

.oh-wordmark:hover {
  color: var(--oh-ink);
}

.oh-wordmark .oh-hoops {
  font-weight: 700;
  color: var(--oh-gold);
}

.oh-pin {
  width: 24px;
  height: 28px;
  flex-shrink: 0;
  display: block;
}

.oh-sub-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.oh-sub-nav a {
  color: var(--oh-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  padding: 6px 0;
  position: relative;
  transition: color 0.15s ease;
  white-space: nowrap;
}

.oh-sub-nav a:hover {
  color: var(--oh-ink);
}

.oh-sub-nav a[aria-current="page"] {
  color: var(--oh-gold);
}

.oh-sub-nav a[aria-current="page"]::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  background: var(--oh-gold);
  border-radius: 2px;
}

/* Legal Document Pages */
body.oh-doc main {
  flex: 1;
  width: min(780px, calc(100% - 40px));
  margin: 0 auto;
  padding: 44px 0 84px;
}

body.oh-doc h1 {
  margin: 0 0 10px;
  color: var(--oh-ink);
  font-family: var(--oh-font-display);
  font-size: clamp(36px, 5vw, 52px);
  font-weight: 700;
  line-height: 0.96;
  letter-spacing: -0.015em;
}

body.oh-doc h2 {
  margin: 2.2em 0 0.65em;
  color: var(--oh-gold-soft);
  font-family: var(--oh-font-display);
  font-size: clamp(22px, 2.8vw, 28px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.01em;
}

body.oh-doc .meta {
  color: var(--oh-muted);
  font-size: 14px;
  font-weight: 500;
  margin: 0 0 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--oh-line);
}

body.oh-doc p {
  margin: 0 0 1.05em;
  color: var(--oh-body);
}

body.oh-doc strong {
  color: var(--oh-ink);
  font-weight: 600;
}

body.oh-doc ul,
body.oh-doc ol {
  margin: 0 0 1.25em;
  padding-left: 1.35em;
}

body.oh-doc li {
  margin-bottom: 0.65em;
}

body.oh-doc .notice {
  background: var(--oh-surface-2);
  border: 1px solid var(--oh-line-strong);
  border-left: 4px solid var(--oh-gold);
  border-radius: 14px;
  padding: 20px 22px;
  margin: 24px 0 28px;
  box-shadow: var(--oh-shadow);
}

body.oh-doc .notice h2 {
  margin-top: 0;
  color: var(--oh-gold);
}

body.oh-doc .notice p:last-child {
  margin-bottom: 0;
}

body.oh-doc .card {
  background: var(--oh-surface-2);
  border: 1px solid var(--oh-line);
  border-radius: 16px;
  padding: 20px 22px;
  margin: 14px 0 22px;
  box-shadow: var(--oh-shadow);
}

body.oh-doc .card p:last-child {
  margin-bottom: 0;
}

body.oh-doc table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin: 20px 0 28px;
  background: var(--oh-surface);
  border: 1px solid var(--oh-line);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--oh-shadow);
}

body.oh-doc th,
body.oh-doc td {
  text-align: left;
  vertical-align: top;
  padding: 13px 16px;
  border-bottom: 1px solid var(--oh-line);
  font-size: 14.5px;
  line-height: 1.55;
  overflow-wrap: break-word;
}

body.oh-doc tr:last-child td {
  border-bottom: 0;
}

body.oh-doc th {
  background: var(--oh-surface-3);
  color: var(--oh-gold);
  font-family: var(--oh-font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

body.oh-doc th:first-child,
body.oh-doc td:first-child {
  width: 31%;
  font-weight: 600;
  color: var(--oh-ink);
}

/* Centered Utility Pages (add-friend, reset, confirm) */
.oh-utility {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 36px 20px 56px;
  background: radial-gradient(ellipse 68% 48% at 50% 24%, rgba(255, 196, 0, 0.07) 0%, rgba(255, 196, 0, 0) 70%);
}

.oh-utility-card {
  width: min(100%, 420px);
  background: var(--oh-surface-2);
  border: 1px solid var(--oh-line);
  border-radius: 22px;
  padding: 32px 28px;
  box-shadow: var(--oh-shadow);
  text-align: center;
}

.oh-utility-card.oh-utility-left {
  text-align: left;
}

.oh-utility-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  border-radius: 16px;
  background: var(--oh-ground);
  border: 1px solid var(--oh-line);
  margin: 0 auto 20px;
}

.oh-utility-left .oh-utility-mark {
  margin: 0 0 18px;
}

.oh-utility-mark .oh-pin {
  width: 32px;
  height: 36px;
}

.oh-utility-card h1 {
  margin: 0 0 10px;
  color: var(--oh-ink);
  font-family: var(--oh-font-display);
  font-size: clamp(30px, 6vw, 36px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.015em;
}

.oh-utility-card p {
  margin: 0 0 22px;
  color: var(--oh-muted);
  font-size: 15px;
  line-height: 1.55;
}

.oh-input {
  display: block;
  width: 100%;
  background: var(--oh-ground);
  border: 1px solid var(--oh-line-strong);
  border-radius: 12px;
  color: var(--oh-ink);
  font-family: var(--oh-font-body);
  font-size: 16px;
  padding: 14px 15px;
  margin: 12px 0 16px;
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.45);
  transition: border-color 0.15s ease;
}

.oh-input::placeholder {
  color: #6F7580;
}

.oh-input:focus {
  border-color: var(--oh-gold);
}

.oh-btn-gold {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 50px;
  padding: 13px 20px;
  background: #F3F4F6;
  color: var(--oh-ground);
  border: 0;
  border-radius: 13px;
  font-family: var(--oh-font-body);
  font-size: 15.5px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease;
}

.oh-btn-gold:hover {
  background: #FFFFFF;
  color: var(--oh-ground);
  transform: translateY(-1px);
}

.oh-btn-gold:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.oh-muted-note {
  display: block;
  margin-top: 18px;
  font-size: 13.5px;
  color: var(--oh-muted);
}

p.oh-muted-note {
  margin: 20px 0 0;
}

/* "Get openHoops" on its own row under "Don't have it yet?" (add-friend.html). */
.oh-get-row {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  margin-top: 10px;
  padding: 12px 20px;
  border: 1.5px solid rgba(255, 255, 255, 0.18);
  border-radius: 13px;
  color: var(--oh-gold-soft);
  font-weight: 700;
  font-size: 15.5px;
  text-decoration: none;
  transition: background 0.15s ease;
}

.oh-get-row:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--oh-gold-soft);
}

.oh-muted-note a {
  color: var(--oh-gold-soft);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.msg {
  font-size: 14.5px;
  line-height: 1.5;
  margin: 14px 0 0;
}

.msg:empty {
  display: none;
}

.err {
  color: var(--oh-danger);
}

.ok {
  color: var(--oh-green);
}

.oh-helper {
  margin-top: 16px !important;
  margin-bottom: 0 !important;
  font-size: 13.5px !important;
  color: var(--oh-muted) !important;
}

/* Compact Subpage Footer */
.oh-sub-footer {
  margin-top: auto;
  border-top: 1px solid var(--oh-line);
  background: var(--oh-obsidian);
  padding: 24px 0;
}

.oh-sub-footer-inner {
  width: min(920px, calc(100% - 40px));
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--oh-muted);
}

.oh-sub-footer-links {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

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

.oh-sub-footer a:hover {
  color: var(--oh-gold);
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .oh-sub-header-inner {
    width: calc(100% - 32px);
    flex-wrap: wrap;
    min-height: 58px;
    gap: 10px 14px;
  }

  .oh-sub-nav {
    gap: 14px;
    justify-content: flex-start;
  }

  .oh-sub-nav a {
    font-size: 13px;
  }

  body.oh-doc main {
    width: calc(100% - 32px);
    padding: 30px 0 64px;
  }

  body.oh-doc .notice,
  body.oh-doc .card {
    padding: 16px;
  }

  /* Stack 2-column policy table into clean cards with zero horizontal overflow */
  body.oh-doc table,
  body.oh-doc tbody {
    display: block;
    width: 100%;
  }

  body.oh-doc tr:first-child {
    display: none;
  }

  body.oh-doc tr {
    display: block;
    padding: 14px 16px;
    border-bottom: 1px solid var(--oh-line);
  }

  body.oh-doc tr:last-child {
    border-bottom: 0;
  }

  body.oh-doc td,
  body.oh-doc td:first-child {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
  }

  body.oh-doc td:first-child {
    color: var(--oh-gold-soft);
    font-size: 15px;
    margin-bottom: 5px;
  }

  .oh-utility {
    padding: 24px 16px 44px;
  }

  .oh-utility-card {
    padding: 26px 20px;
  }

  .oh-sub-footer-inner {
    width: calc(100% - 32px);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
