/* Shared look for CS2 Guessr. */

/* ---------- Inter, self-hosted ----------
 * Served from this origin on purpose: pulling it from Google's CDN would send
 * every visitor's IP address to Google, which German courts have treated as a
 * data protection violation. SIL Open Font License 1.1. */

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("/styles/fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("/styles/fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: dark;

  /* surfaces, darkest to lightest */
  --bg:        #080a0f;
  --bg-soft:   #0f1219;
  --panel:     #141822;
  --panel-2:   #1b202c;
  --raised:    #222836;

  --line:      rgba(255, 255, 255, 0.07);
  --line-2:    rgba(255, 255, 255, 0.14);
  --line-3:    rgba(255, 255, 255, 0.22);

  --text:      #eef1f7;
  --muted:     #939eb2;
  --dim:       #616c80;

  --accent:    #f0932b;
  --accent-2:  #ffb454;
  --accent-dk: #c96a12;
  --blue:      #5b93ff;
  --good:      #3fcf75;
  --bad:       #f2544b;

  /* rarity, for the reveal glow */
  --gold:      #ffd166;
  --silver:    #d6dbe4;
  --bronze:    #d59a68;

  --r-sm: 9px;
  --r:    14px;
  --r-lg: 22px;
  --r-xl: 30px;

  --shadow:    0 18px 44px rgba(0, 0, 0, .45);
  --shadow-lg: 0 30px 70px rgba(0, 0, 0, .55);
  --glow-accent: 0 0 0 1px rgba(240,147,43,.35), 0 12px 40px rgba(240,147,43,.18);

  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 1120px;
  --ease: cubic-bezier(.2, .8, .3, 1);
}

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

/* the hidden attribute must win over any display rule below */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Ambient light, fixed so it does not scroll away. */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(900px 520px at 50% -8%, rgba(240, 147, 43, .13), transparent 65%),
    radial-gradient(700px 460px at 8% 105%, rgba(91, 147, 255, .07), transparent 62%);
}

a { color: inherit; }
img { max-width: 100%; }

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}
button { cursor: pointer; border: 0; background: none; }

::selection { background: rgba(240, 147, 43, .3); }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ════════════════ layout ════════════════ */

.wrap { width: min(var(--wrap), 100% - 44px); margin: 0 auto; }

/* ════════════════ brand ════════════════ */

.brand { display: inline-flex; align-items: center; text-decoration: none; flex: 0 0 auto; }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name {
  font-size: 15.5px; font-weight: 900; letter-spacing: -0.02em;
}
.brand__name em { font-style: normal; color: var(--accent); }
/* The domain, quietly present on every page so people can find their way back. */
.brand__site {
  font-size: 10px; font-weight: 700; letter-spacing: .07em;
  text-transform: lowercase; color: var(--dim);
}

/* ════════════════ buttons ════════════════ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 46px; padding: 0 24px;
  border-radius: var(--r); border: 1px solid var(--line-2);
  background: var(--panel-2);
  font-weight: 700; font-size: 14.5px; letter-spacing: -0.01em;
  text-decoration: none; white-space: nowrap;
  transition: background .16s var(--ease), border-color .16s var(--ease),
              transform .08s var(--ease), box-shadow .16s var(--ease);
}
.btn:hover { background: var(--raised); border-color: var(--line-3); }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; }

.btn--primary {
  background: linear-gradient(165deg, var(--accent-2), var(--accent));
  border-color: transparent; color: #170f04;
  box-shadow: 0 8px 24px rgba(240, 147, 43, .22);
}
.btn--primary:hover {
  background: linear-gradient(165deg, #ffc06e, #f39c35);
  border-color: transparent;
  box-shadow: 0 10px 30px rgba(240, 147, 43, .32);
}
.btn--primary:disabled { box-shadow: none; }

.btn--ghost { background: transparent; border-color: var(--line-2); }
.btn--ghost:hover { background: rgba(255, 255, 255, .045); }

.btn--sm { height: 38px; padding: 0 16px; font-size: 13px; border-radius: var(--r-sm); }
.btn--lg { height: 54px; padding: 0 32px; font-size: 16px; }

/* ════════════════ bits ════════════════ */

.tag {
  display: inline-block;
  font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .09em;
  padding: 5px 10px; border-radius: 999px;
  border: 1px solid var(--line-2); color: var(--muted);
}
.tag--live { color: var(--good); border-color: rgba(63, 207, 117, .4); background: rgba(63, 207, 117, .08); }
.tag--accent { color: var(--accent-2); border-color: rgba(240, 147, 43, .4); background: rgba(240, 147, 43, .1); }

.card {
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  background: linear-gradient(180deg, var(--panel), var(--bg-soft));
  box-shadow: var(--shadow);
}

/* ════════════════ site nav ════════════════ */

.topbar {
  position: sticky; top: 0; z-index: 40;
  padding: 14px 0;
  background: rgba(8, 10, 15, .82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar__inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; }

.nav { display: flex; align-items: center; gap: 3px; }
.nav a {
  padding: 9px 14px; border-radius: var(--r-sm);
  font-size: 13.5px; font-weight: 700; text-decoration: none; color: var(--muted);
  transition: color .15s var(--ease), background .15s var(--ease);
}
.nav a:hover { color: var(--text); background: rgba(255, 255, 255, .05); }
.nav a.is-here { color: var(--accent-2); background: rgba(240, 147, 43, .1); }

/* ════════════════ site footer ════════════════ */

.sitefoot {
  margin-top: 60px; padding: 32px 0 40px;
  border-top: 1px solid var(--line);
  text-align: center;
}
.sitefoot__site {
  font-size: 14px; font-weight: 800; letter-spacing: -0.01em; color: var(--text);
  text-decoration: none;
}
.sitefoot__site:hover { color: var(--accent-2); }
.sitefoot__links { margin-top: 12px; display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
.sitefoot__links a {
  font-size: 12.5px; color: var(--muted); text-decoration: none; padding: 4px 8px; border-radius: 6px;
}
.sitefoot__links a:hover { color: var(--text); background: rgba(255, 255, 255, .04); }
.sitefoot__fine {
  margin-top: 14px; font-size: 11.5px; color: var(--dim); line-height: 1.7;
}
.sitefoot__fine a { color: var(--dim); }

/* ════════════════ mobile ════════════════ */

@media (max-width: 720px) {
  .wrap { width: min(var(--wrap), 100% - 28px); }
  .topbar { padding: 9px 0; }
    .brand__name { font-size: 14.5px; }
  .btn { height: 46px; }
  .sitefoot { margin-top: 44px; }

  /* thumbs need something to hit — 44px is the accepted floor */
  .nav a { padding: 12px 11px; font-size: 13px; min-height: 44px; display: flex; align-items: center; }
  .sitefoot__links a { padding: 10px 10px; }
}

@media (max-width: 380px) {
  .brand__site { display: none; }    /* the footer still carries it */
  .nav a { padding: 12px 8px; font-size: 12.5px; }
}
