.globeguess {
  color-scheme: light;
  --gg-page: var(--rcc-page-light);
  --gg-surface: var(--rcc-surface-light);
  --gg-raised: var(--rcc-raised-light);
  --gg-text: var(--rcc-text-light);
  --gg-muted: var(--rcc-muted-light);
  --gg-border: var(--rcc-border-light);
  --gg-accent: #7c3aed;
  --gg-warm: #dc2626;
  --gg-cold: #2563eb;
  --gg-board-width: 900px;
  box-sizing: border-box;
  min-height: 100vh;
  margin: 0;
  padding: 100px 22px 60px;
  overflow-x: hidden;
  background: var(--gg-page);
  color: var(--gg-text);
  font-family: var(--rcc-font-family);
  font-weight: 700;
}

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

/* Nunito everywhere, including form controls (browsers do not inherit it by default). */
.globeguess,
.globeguess button,
.globeguess input,
.globeguess select,
.globeguess textarea { font-family: var(--rcc-font-family); }

.globeguess.gg--dark {
  color-scheme: dark;
  --gg-page: var(--rcc-page-dark);
  --gg-surface: var(--rcc-surface-dark);
  --gg-raised: var(--rcc-raised-dark);
  --gg-text: var(--rcc-text-dark);
  --gg-muted: var(--rcc-muted-dark);
  --gg-border: var(--rcc-border-dark);
  --gg-accent: #8b5cf6;
  --gg-warm: #f87171;
  --gg-cold: #60a5fa;
}

/* Dismissible extension promo: fixed so it never shifts the board layout. */
.globeguess .gg__promo { position: fixed; top: 0; left: 0; right: 0; z-index: 500; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 40px; padding: 6px 48px; background: var(--gg-accent); color: #fff; font-size: 14px; font-weight: 700; text-align: center; }
.globeguess .gg__promo[hidden] { display: none; }
.globeguess .gg__promo-text { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.globeguess .gg__promo-close { position: absolute; top: 50%; right: 10px; display: flex; width: 28px; height: 28px; align-items: center; justify-content: center; transform: translateY(-50%); border: 0; border-radius: 50%; background: transparent; color: #fff; font-size: 22px; line-height: 1; cursor: pointer; }
.globeguess .gg__promo-close:hover { background: rgb(255 255 255 / 20%); }
/* While the promo is up, the fixed gear and session board sit below it instead of under it. */
.globeguess.gg--promo .gg__settings-toggle { top: 52px; }
@media (min-width: 1000px) {
  .globeguess.gg--promo .floating-leaderboard:not([style*="top"]) { top: 52px; }
}

.globeguess .gg__shell { width: min(100%, var(--gg-board-width)); margin: 0 auto; }

/* Title lockup */
.globeguess .gg__header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 48px;
  margin-bottom: 8px;
  padding: 0 48px;
}

.globeguess .gg__title-container { display: flex; width: 100%; align-items: center; justify-content: center; gap: 8px; }

.globeguess .gg__title {
  margin: 0;
  color: var(--gg-text);
  font-size: clamp(1.55rem, 3vw, 1.875rem);
  font-weight: 900;
  letter-spacing: -.035em;
  line-height: 1;
  white-space: nowrap;
}

.globeguess .gg__logo { width: 36px; height: 36px; flex: 0 0 auto; border-radius: 5px; object-fit: contain; }

.globeguess .gg__guidance { margin: 0 0 5px; color: var(--gg-muted); font-size: 18px; text-align: center; }

/* Quick (three-dot) menu */
.globeguess .gg__quick { position: absolute; top: 4px; right: 0; }
.globeguess .gg__icon-button {
  width: 40px;
  height: 40px;
  border: 0;
  padding: 0;
  background: transparent;
  color: inherit;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.globeguess .gg__quick-menu {
  position: absolute;
  top: 42px;
  right: 0;
  z-index: 900;
  display: grid;
  min-width: 190px;
  gap: 2px;
  border: 1px solid var(--gg-border);
  border-radius: 8px;
  padding: 6px;
  background: var(--gg-surface);
  box-shadow: var(--rcc-shadow-floating);
}
.globeguess .gg__quick-menu[hidden] { display: none; }
.globeguess .gg__quick-menu button {
  border: 0;
  border-radius: 6px;
  padding: 9px 10px;
  background: transparent;
  color: var(--gg-text);
  font: 900 .72rem "Nunito", ui-rounded, sans-serif;
  letter-spacing: .04em;
  text-align: left;
  cursor: pointer;
}
.globeguess .gg__quick-menu button:hover,
.globeguess .gg__quick-menu button:focus-visible { background: var(--gg-raised); outline: none; }
.globeguess .gg__quick-menu button[data-armed="true"] { background: var(--rcc-danger); color: #fff; }

/* Board: guesses on the left, the globe on the right (stacked on phones). */
.globeguess .gg__board { width: 100%; min-width: 0; padding: 0; color: var(--gg-text); }
.globeguess .gg__meta:not(:has(#timerWrap:not([hidden]))) { display: none; }
.globeguess .gg__meta { display: flex; align-items: baseline; justify-content: flex-end; gap: 12px; margin: 0 0 8px; color: var(--gg-text); font-size: .8rem; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; }
.globeguess .gg__meta strong { font-weight: 900; }
.globeguess .gg__meta [hidden] { display: none; }

.globeguess .gg__hints { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; min-height: 26px; margin: 0 0 8px; font-size: .8rem; }
/* The strip keeps its slot when empty so a hint gift never pushes the board down. */
.globeguess .gg__hints[hidden] { visibility: hidden; }
.globeguess .gg__hints strong { color: var(--gg-muted); font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.globeguess .gg__hint-chip { border: 2px solid var(--gg-accent); border-radius: 999px; padding: 2px 10px; font-weight: 900; }

.globeguess .gg__arena { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 18px; align-items: start; }
.globeguess .gg__column { display: grid; min-width: 0; gap: 10px; }

/* Rows: avatar, name over country, miles (and the verdict on the latest-guess row). */
.globeguess .gg__row {
  display: grid;
  min-width: 0;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  border: 2px solid var(--gg-border);
  border-radius: 6px;
  padding: 5px 10px 5px 6px;
  background: var(--gg-surface);
}
.globeguess .gg__row-avatar { width: 38px; height: 38px; flex: 0 0 auto; border-radius: 4px; object-fit: cover; background: #312d36; }
.globeguess .gg__row-main { display: grid; min-width: 0; gap: 1px; }
.globeguess .gg__row-name,
.globeguess .gg__row-country,
.globeguess .gg__row-by { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.globeguess .gg__row-name { font-size: .82rem; font-weight: 700; }
.globeguess .gg__row-country { font-size: .95rem; font-weight: 900; text-transform: uppercase; letter-spacing: .01em; }
.globeguess .gg__row-by { color: var(--gg-muted); font-size: .7rem; font-weight: 800; }
.globeguess .gg__row-miles { justify-self: end; font-size: .9rem; font-weight: 900; white-space: nowrap; font-variant-numeric: tabular-nums; }
.globeguess .gg__row-side { display: grid; justify-items: end; gap: 3px; }

/* Latest guess: a fixed slot from the start, so nothing that appears mid-round moves the board. */
.globeguess .gg__recent { height: 62px; }
.globeguess .gg__row--recent { height: 62px; border-color: var(--gg-text); }
.globeguess .gg__row--recent .gg__row-avatar { width: 46px; height: 46px; }
.globeguess .gg__recent-empty { display: grid; height: 62px; margin: 0; place-items: center; border: 2px dashed var(--gg-border); border-radius: 6px; color: var(--gg-muted); font-size: .85rem; }
.globeguess .gg__verdict { border: 2px solid currentColor; border-radius: 5px; padding: 1px 7px; font-size: .68rem; font-weight: 900; letter-spacing: .06em; white-space: nowrap; }
.globeguess .gg__verdict[data-verdict="warmer"] { color: var(--gg-warm); }
.globeguess .gg__verdict[data-verdict="colder"] { color: var(--gg-cold); }
.globeguess .gg__verdict[data-verdict="correct"] { border-color: transparent; background: #16a34a; color: #fff; padding: 0 9px; font-size: 1rem; line-height: 1.25; }
.globeguess .gg__verdict[data-verdict="first"],
.globeguess .gg__verdict[data-verdict="duplicate"] { color: var(--gg-muted); border-style: dashed; }
.globeguess .gg__recent[data-verdict="duplicate"] .gg__row { opacity: .7; }

/* Sorted list: closest first. The first row is the tile the globe line starts from. */
.globeguess .gg__list { position: relative; display: grid; max-height: 470px; gap: 5px; margin: 0 -4px; overflow-y: auto; padding: 4px; list-style: none; scrollbar-width: none; }
.globeguess .gg__list::-webkit-scrollbar { display: none; }
.globeguess .gg__list:empty { display: none; }
.globeguess .gg__guess { grid-template-columns: 22px auto minmax(0, 1fr) auto; padding-block: 4px; }
.globeguess .gg__guess .gg__row-avatar { width: 32px; height: 32px; }
.globeguess .gg__row-rank { color: var(--gg-muted); font-size: .78rem; font-weight: 900; text-align: center; }
.globeguess .gg__guess--closest { border-color: var(--gg-accent); box-shadow: 0 0 0 1px var(--gg-accent), 0 0 18px rgb(139 92 246 / 35%); }
.globeguess .gg__guess--closest .gg__row-rank { color: var(--gg-accent); }
.globeguess .gg__guess[data-target="true"] { border-color: #facc15; box-shadow: 0 0 0 1px #facc15; }
/* New or repeated guess: a brief 2px outline in the text colour (no animation, adds no size). */
.globeguess .gg__guess--flash { outline: 2px solid var(--gg-text); outline-offset: 1px; }

/* Globe: the snippet's deep navy in both themes. */
.globeguess .gg__globe-wrap { position: relative; width: 100%; aspect-ratio: 1 / 1; max-height: 600px; overflow: hidden; border-radius: 14px; background: radial-gradient(circle at 50% 45%, #10243b 0%, #070f1b 70%); }
.globeguess .gg__globe { position: absolute; inset: 0; }
.globeguess .gg__globe canvas { display: block; }
.globeguess .gg__globe-notice { position: absolute; inset: auto 12px 12px; margin: 0; border-radius: 8px; padding: 10px 12px; background: rgb(0 0 0 / 55%); color: #fff; font-size: .82rem; text-align: center; }
.globeguess .gg__globe-notice[hidden] { display: none; }
/* Above the closest-guess line (z-index 450). globe.gl writes a small inline z-index on every label, hence !important;
   no ancestor up to the body forms a stacking context, so this competes with the fixed line directly. */
.globeguess .gg__globe-tag {
  z-index: 460 !important;
  position: absolute;
  transform: translate(-8px, -100%);
  border-radius: 8px;
  padding: 6px 12px;
  background: #fff;
  box-shadow: 0 6px 18px rgb(0 0 0 / 45%);
  color: #0b1a2c;
  font: 800 15px var(--rcc-font-family);
  white-space: nowrap;
  pointer-events: none;
}
.globeguess .gg__globe-tag--target { background: #facc15; color: #1d1300; }

/* The closest-guess line: drawn over the page, never catches clicks. */
.globeguess .gg__line { position: fixed; inset: 0; z-index: 450; width: 100vw; height: 100vh; overflow: visible; pointer-events: none; }
.globeguess .gg__line path { fill: none; stroke: var(--gg-accent); stroke-width: 3; stroke-linecap: round; filter: drop-shadow(0 0 4px rgb(139 92 246 / 70%)); }
.globeguess .gg__line circle { fill: #fff; stroke: var(--gg-accent); stroke-width: 3; }
.globeguess .gg__line[data-visible="false"] { display: none; }
.globeguess .gg__line[data-facing="false"] { opacity: .3; }

.globeguess .gg__status { min-height: 22px; margin: 12px 0 0; color: var(--gg-muted); font-size: 18px; line-height: 22px; text-align: center; }

/* Host answer box under the status line (contract feature boardGuess). */
.globeguess .gg__board-guess { display: flex; width: min(100%, 360px); align-items: flex-end; gap: 10px; margin: 12px auto 0; }
.globeguess .gg__answer-field {
  position: relative;
  min-width: 0;
  flex: 1;
}
.globeguess .gg__answer-field input {
  display: block;
  width: 100%;
  height: 41px;
  border: 0;
  border-radius: 7px;
  padding: 0 10px;
  outline: none;
  background: var(--gg-surface);
  color: var(--gg-text);
  font: 900 1rem var(--rcc-font-family);
}
.globeguess .gg__answer-field input::placeholder { color: var(--gg-muted); font-weight: 700; opacity: 1; }
.globeguess .gg__answer-field:focus-within { filter: drop-shadow(0 2px 4px rgb(139 92 246 / 35%)); }
/* Not a country: a 2px ring in the text colour, inside the field so nothing moves. */
.globeguess .gg__answer-field input[aria-invalid="true"] { box-shadow: inset 0 0 0 2px var(--gg-text); }
.globeguess .gg__board-guess button {
  height: 41px;
  border: 0;
  border-radius: 7px;
  padding: 0 14px;
  background: #0c2238; /* the globe's ocean blue, in both themes */
  color: #fff;
  font: 900 .72rem var(--rcc-font-family);
  letter-spacing: .04em;
  cursor: pointer;
}
.globeguess .gg__board-guess input:disabled,
.globeguess .gg__board-guess button:disabled { opacity: .5; cursor: not-allowed; }

/* Settings drawer action buttons */
.globeguess .gg__settings-action {
  height: 41px;
  border: 0;
  border-radius: 7px;
  padding: 0 14px;
  background: var(--gg-accent);
  color: #fff;
  font: 900 .72rem "Nunito", ui-rounded, sans-serif;
  letter-spacing: .04em;
  cursor: pointer;
}

/* Host drawer */
.globeguess .gg__settings-panel {
  position: fixed;
  top: 0;
  right: -330px;
  z-index: 1200;
  width: min(var(--rcc-settings-width), 100vw);
  height: 100vh;
  overflow: auto;
  background: #1c1c1c;
  color: #fff;
  box-shadow: -2px 0 10px rgb(0 0 0 / 30%);
  transition: right .3s ease;
}
.globeguess .gg__settings-panel--open { right: 0; }
.globeguess .gg__settings-header { display: flex; align-items: center; justify-content: space-between; padding: 20px; border-bottom: 1px solid #3a3a3c; }
.globeguess .gg__settings-header h2 { margin: 0; color: #fff; font-size: 24px; font-weight: 800; }
.globeguess .gg__close-button,
.globeguess .gg__settings-toggle { border: 0; background: transparent; color: inherit; cursor: pointer; }
.globeguess .gg__close-button { display: flex; width: 32px; height: 32px; align-items: center; justify-content: center; border-radius: 50%; font-size: 24px; transition: background-color .2s ease; }
.globeguess .gg__close-button:hover { background: #3a3a3c; }
.globeguess .gg__settings-section { border-bottom: 1px solid #3a3a3c; }
.globeguess .gg__settings-section-header {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: space-between;
  border: 0;
  padding: 15px 20px;
  background: transparent;
  color: #fff;
  font: 800 18px "Nunito", ui-rounded, sans-serif;
  text-align: left;
  cursor: pointer;
}
.globeguess .gg__settings-section-header:hover,
.globeguess .gg__settings-section-header:focus-visible { background: #2a2a2c; outline: none; }
.globeguess .gg__settings-arrow { transition: transform .2s ease; }
.globeguess .gg__settings-section-header[aria-expanded="true"] .gg__settings-arrow { transform: rotate(180deg); }
.globeguess .gg__settings-section-content { display: grid; max-height: 0; gap: 18px; overflow: hidden; padding: 0 20px; visibility: hidden; transition: max-height .3s ease, padding .3s ease; }
.globeguess .gg__settings-section-header[aria-expanded="true"] + .gg__settings-section-content { max-height: none; padding: 15px 20px 20px; visibility: visible; }
.globeguess .gg__setting-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.globeguess .gg__setting-column { display: grid; gap: 7px; }
.globeguess .gg__setting-column input,
.globeguess .gg__setting-column select { height: 38px; border: 1px solid #444; border-radius: 4px; padding: 0 9px; background: #2a2a2c; color: #fff; font: inherit; }
.globeguess .gg__settings-action { width: 100%; height: 40px; border: 1px solid #4a4a4c; border-radius: 4px; background: #3a3a3c; font-size: 14px; font-weight: 700; letter-spacing: 0; }
.globeguess .gg__settings-action:hover { background: #4a4a4c; }
.globeguess .gg__settings-action--primary { border-color: transparent; background: #538d4e; }
.globeguess .gg__settings-action--primary:hover { background: #4a7a44; }
.globeguess .gg__settings-action--gold { border-color: transparent; background: #b59f3b; }
.globeguess .gg__settings-action--gold:hover { background: #a08c32; }
.globeguess .gg__settings-action--danger { border-color: transparent; background: var(--rcc-danger); }
.globeguess .gg__settings-action[data-armed="true"] { outline: 3px solid #fda4af; }
.globeguess .gg__data-notice { margin: 0; color: #fdba74; font-size: .78rem; line-height: 1.35; }
.globeguess .gg__data-notice:empty { display: none; }
.globeguess .gg__answers { display: grid; gap: 7px; }
.globeguess .gg__answers-title { font-size: 15px; }
.globeguess .gg__answers-value { color: #5eead4; font-size: 1rem; font-weight: 900; text-transform: uppercase; }
.globeguess .gg__answers-meta { color: #bdb5c3; font-size: .72rem; }
.globeguess .gg__profile-upload { display: grid; justify-items: center; gap: 10px; }
.globeguess .gg__profile-preview { width: 104px; height: 104px; border: 3px solid #8b5cf6; border-radius: 8px; background: #312d36; object-fit: cover; }
.globeguess .gg__profile-actions { display: flex; gap: 8px; }
.globeguess .gg__profile-upload-button,
.globeguess .gg__profile-remove {
  min-height: 34px;
  border: 1px solid #5a5161;
  border-radius: 7px;
  padding: 8px 11px;
  background: #2b2630;
  color: #fff;
  font: 900 .68rem "Nunito", ui-rounded, sans-serif;
  cursor: pointer;
}
.globeguess .gg__profile-upload > span { color: #bdb5c3; font-size: .72rem; text-align: center; }
.globeguess .gg__profile-status { min-height: 1em; color: #c4b5fd !important; font-weight: 800; }
.globeguess .gg__simulation { display: grid; gap: 8px; }
.globeguess .gg__simulation > strong { font-size: .75rem; letter-spacing: .08em; }
.globeguess .gg__simulation > span { color: #bdb5c3; font-size: .75rem; line-height: 1.35; }
.globeguess .gg__simulation-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.globeguess .gg__simulation-button { min-height: 36px; border: 1px solid #5a5161; border-radius: 7px; padding: 6px 8px; background: #2b2630; color: #fff; font: 900 .67rem "Nunito", ui-rounded, sans-serif; cursor: pointer; }
.globeguess .gg__simulation-button:last-child { grid-column: 1 / -1; }
.globeguess .gg__simulation-button:hover { border-color: #a78bfa; background: #352e3c; }
.globeguess .gg__simulation-status { min-height: 1em; color: #c4b5fd !important; font-weight: 800; }

.globeguess .gg__settings-toggle {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 1000;
  display: grid;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 50%;
  background: #1c1c1c;
  color: #fff;
  box-shadow: 0 2px 8px rgb(0 0 0 / 20%);
  transition: background-color .2s ease, transform .2s ease;
}
.globeguess .gg__settings-toggle:hover { background: #2a2a2c; transform: scale(1.1); }
.globeguess .gg__settings-toggle svg { width: 24px; height: 24px; }
.globeguess .gg__settings-toggle[data-alert="true"]::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 2px;
  width: 11px;
  height: 11px;
  border: 2px solid #1c1c1c;
  border-radius: 50%;
  background: #f97316;
}

/* Session leaderboard */
.globeguess .floating-leaderboard {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 600;
  width: min(var(--rcc-leaderboard-width), calc(100vw - 20px));
  border: 1px solid #444;
  border-radius: 8px;
  background: #2c2c2c;
  color: #fff;
  box-shadow: 0 4px 12px rgb(0 0 0 / 30%);
  user-select: none;
  transition: opacity .2s;
}
.globeguess .floating-leaderboard.opacity-50 { opacity: .7; }
.globeguess .floating-leaderboard-header { display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid #444; border-radius: 8px 8px 0 0; padding: 8px 12px; background: #333; color: #fff; font-size: 14px; font-weight: 600; cursor: move; touch-action: none; }
.globeguess .leaderboard-controls { display: flex; align-items: center; gap: 4px; }
.globeguess .leaderboard-nav-btn,
.globeguess .floating-leaderboard-toggle { display: flex; width: 20px; height: 20px; align-items: center; justify-content: center; border: 0; border-radius: 3px; padding: 0; background: transparent; color: #fff; font: inherit; font-size: 1rem; cursor: pointer; text-decoration: none; transition: background .2s; }
.globeguess .floating-leaderboard-toggle { font-size: 1.2rem; }
.globeguess .leaderboard-nav-btn:hover:not(:disabled),
.globeguess .floating-leaderboard-toggle:hover { background: #444; }
.globeguess .leaderboard-nav-btn:disabled { color: #666; cursor: not-allowed; }
.globeguess .leaderboard-page-info { min-width: 24px; margin: 0 2px; color: #ccc; font-size: 16px; text-align: center; }
.globeguess .floating-leaderboard-body { display: block; max-height: 290px; overflow-y: auto; padding: 8px; }
.globeguess .floating-leaderboard-body.collapsed { display: none; }
.globeguess .floating-leaderboard-body--expanded { max-height: none; overflow-y: visible; }
.globeguess .leaderboard-height-toggle { display: block; margin: 10px 0 0 auto; border: 0; padding: 0; background: transparent; color: #fff; font: inherit; font-size: 18px; line-height: 1; cursor: pointer; }
.globeguess .leaderboard-list { display: flex; flex-direction: column; gap: 2px; }
.globeguess .leaderboard-item { display: flex; height: 36px; align-items: center; justify-content: space-between; border-radius: 4px; padding: 6px 10px; background: #3a3a3a; }
.globeguess .leaderboard-user { display: flex; min-width: 0; flex: 1; align-items: center; gap: 6px; }
.globeguess .leaderboard-rank { min-width: 18px; flex-shrink: 0; color: #aaa; font-size: .8rem; font-weight: 600; text-align: right; }
.globeguess .leaderboard-img { width: 30px; height: 30px; flex-shrink: 0; border-radius: 4px; background: #555; object-fit: cover; }
.globeguess .leaderboard-username { min-width: 0; flex: 1; overflow: hidden; color: #fff; font-size: 16px; font-weight: 500; text-overflow: ellipsis; white-space: nowrap; }
.globeguess .leaderboard-points { flex-shrink: 0; margin-left: 6px; color: #4285f4; font-size: 18px; font-weight: 600; }
.globeguess .leaderboard-empty { padding: 20px; color: #888; font-size: .8rem; font-style: italic; text-align: center; }
.globeguess .floating-leaderboard--dragging { cursor: grabbing; }

/* Winner overlay */
.globeguess .winning-overlay { position: fixed; inset: 0; z-index: 3100; visibility: hidden; background: rgb(0 0 0 / 50%); opacity: 0; transition: opacity var(--rcc-transition-medium), visibility var(--rcc-transition-medium); }
.globeguess .winning-overlay.show { visibility: visible; opacity: 1; }
.globeguess .winning-modal { position: fixed; top: 50%; left: 50%; width: 92%; max-width: var(--rcc-overlay-width); max-height: 92vh; overflow: auto; transform: translate(-50%, -50%); border: 1px solid var(--gg-border); border-radius: var(--rcc-radius-medium); padding: 20px; background: var(--gg-surface); color: var(--gg-text); box-shadow: var(--rcc-shadow-overlay); text-align: center; }
.globeguess .winning-title { margin-bottom: 14px; font-size: 22px; font-weight: 900; overflow-wrap: anywhere; }
.globeguess .single-winner { display: flex; justify-content: center; margin-bottom: 12px; }
.globeguess .winner-photo { width: 150px; height: 150px; border: 3px solid var(--rcc-highlight); border-radius: 0; object-fit: cover; }
.globeguess .multiple-winners { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: center; gap: 10px; margin-bottom: 12px; }
.globeguess .multi-winner { display: flex; max-width: 112px; flex-direction: column; align-items: center; gap: 4px; margin: 0; }
.globeguess .multi-winner-photo { width: 66px; height: 66px; border: 2px solid var(--rcc-highlight); border-radius: 0; object-fit: cover; }
.globeguess .multi-winner-photo--lead { width: 112px; height: 112px; border-width: 3px; }
.globeguess .multi-winner figcaption { display: grid; max-width: 100%; gap: 1px; }
.globeguess .multi-winner-name { overflow: hidden; font-size: .8rem; font-weight: 800; text-overflow: ellipsis; white-space: nowrap; }
.globeguess .multi-winner-count { color: var(--gg-muted); font-size: .7rem; font-weight: 800; }
.globeguess .winning-site { width: fit-content; margin: 12px auto 6px; border-radius: 5px; padding: 5px 10px; background: #6b6562; color: #f7be57; font-size: 20px; font-weight: 600; opacity: .9; }

.globeguess .gg__sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }

/* The floating leaderboard (left 20px, 280px wide) must never sit on top of the board:
   wide screens start the board just right of it; narrower screens dock it at the bottom. */
@media (min-width: 1000px) {
  .globeguess { padding-left: max(318px, calc((100vw - var(--gg-board-width)) / 2)); padding-right: 22px; }
  .globeguess .gg__shell { margin: 0; }
}

@media (max-width: 999px) {
  .globeguess .floating-leaderboard { top: auto; bottom: 10px; left: 10px; }
  .globeguess .floating-leaderboard-body { max-height: 150px; }
  .globeguess { padding-bottom: 240px; }
}

@media (max-width: 760px) {
  .globeguess { padding: 100px 10px 240px; }
  .globeguess .gg__quick { display: none; }
  .globeguess .gg__settings-toggle { top: 14px; right: 10px; }
  .globeguess .floating-leaderboard { top: auto; bottom: 10px; left: 10px; }
  .globeguess .floating-leaderboard-body { max-height: 150px; }
}

/* Phones: globe on top, guesses below. */
@media (max-width: 699px) {
  .globeguess .gg__arena { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .globeguess .gg__globe-wrap { order: -1; max-height: 360px; }
  .globeguess .gg__list { max-height: 300px; }
}

@media (max-width: 430px) {
  .globeguess .gg__header { margin-left: 0; padding: 0 30px 0 0; }
  .globeguess .gg__title-container { gap: 4px; justify-content: flex-start; }
  .globeguess .gg__title { font-size: clamp(.7rem, 3.6vw, 1rem); letter-spacing: -.045em; }
  .globeguess .gg__logo { width: 26px; height: 26px; }
  .globeguess .gg__row-country { font-size: .85rem; }
  .globeguess .gg__globe-tag { font-size: 13px; padding: 4px 9px; }
}

@media (prefers-reduced-motion: reduce) {
  .globeguess .gg__board { animation: none; }
  .globeguess,
  .globeguess *,
  .globeguess *::before,
  .globeguess *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
}

/* Host tutorial (tutorial.js): transparent overlay under the drawer, spotlight ring, dialog. No animation. */
.globeguess .gg__tutorial-overlay { position: fixed; inset: 0; z-index: 1100; background: transparent; }
.globeguess .gg__tutorial-spotlight {
  position: fixed;
  z-index: 1300;
  border: 3px solid #a78bfa;
  border-radius: 10px;
  box-shadow: 0 0 0 2px rgb(28 28 28 / 85%), 0 0 16px 4px rgb(167 139 250 / 55%);
  pointer-events: none;
}
.globeguess .gg__tutorial-spotlight[hidden] { display: none; }
.globeguess .gg__tutorial-dialog {
  position: fixed;
  z-index: 1310;
  width: 340px;
  max-width: calc(100vw - 16px);
  max-height: calc(100vh - 16px);
  overflow: auto;
  border: 1px solid var(--gg-border);
  border-radius: var(--rcc-radius-medium);
  padding: 16px 18px 18px;
  background: var(--gg-surface);
  color: var(--gg-text);
  box-shadow: var(--rcc-shadow-overlay);
}
.globeguess .gg__tutorial-dialog:focus { outline: none; }
.globeguess .gg__tutorial-dialog[data-place="center"] { top: 50%; left: 50%; width: min(460px, calc(100vw - 24px)); transform: translate(-50%, -50%); text-align: center; }
.globeguess .gg__tutorial-dialog[data-place="dock"] { right: auto; bottom: 8px; left: 50%; width: min(480px, calc(100vw - 16px)); transform: translateX(-50%); }
.globeguess .gg__tutorial-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 30px; margin: 0 0 6px; }
.globeguess .gg__tutorial-count { min-width: 0; margin: 0; color: var(--gg-muted); font-size: .72rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; text-align: left; }
.globeguess .gg__tutorial-lang { display: inline-flex; flex: 0 0 auto; margin-left: auto; border: 1px solid var(--gg-border); border-radius: 7px; overflow: hidden; }
.globeguess .gg__tutorial-lang-btn {
  min-width: 34px;
  min-height: 28px;
  border: 0;
  border-left: 1px solid var(--gg-border);
  padding: 4px 8px;
  background: transparent;
  color: var(--gg-muted);
  font: 800 .72rem var(--rcc-font-family);
  letter-spacing: .04em;
  cursor: pointer;
}
.globeguess .gg__tutorial-lang-btn:first-child { border-left: 0; }
.globeguess .gg__tutorial-lang-btn:hover { background: var(--gg-raised); color: var(--gg-text); }
.globeguess .gg__tutorial-lang-btn[aria-pressed="true"] { background: #6d28d9; color: #fff; }
.globeguess .gg__tutorial-lang-btn:focus-visible { outline: 3px solid #a78bfa; outline-offset: -3px; }
.globeguess .gg__tutorial-title { margin: 0 0 6px; font-size: 1.15rem; font-weight: 900; line-height: 1.2; }
.globeguess .gg__tutorial-text { margin: 0 0 14px; font-size: .9rem; font-weight: 700; line-height: 1.45; }
.globeguess .gg__tutorial-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.globeguess .gg__tutorial-dialog[data-place="center"] .gg__tutorial-actions { justify-content: center; }
.globeguess .gg__tutorial-btn {
  min-height: 38px;
  border: 1px solid var(--gg-border);
  border-radius: 7px;
  padding: 8px 16px;
  background: transparent;
  color: var(--gg-text);
  font: 800 .82rem var(--rcc-font-family);
  cursor: pointer;
}
.globeguess .gg__tutorial-btn:hover { background: var(--gg-raised); }
.globeguess .gg__tutorial-btn--primary { border-color: transparent; background: #6d28d9; color: #fff; }
.globeguess .gg__tutorial-btn--primary:hover { background: #5b21b6; }
.globeguess .gg__tutorial-btn:focus-visible { outline: 3px solid #a78bfa; outline-offset: 2px; }