.entry-privacy-error { padding: 12px; margin: 12px; border: 2px solid #793b18; background: #fff5d7; color: #452714; }
.entry-privacy-error a { color: #14584f; text-decoration: underline; }
.age-gate-privacy-options { margin: 16px 0; color: #452714; }
.age-gate-privacy-options > summary { cursor: pointer; font-size: 13px; font-weight: 700; line-height: 1.5; }
.age-gate-privacy-options > summary:focus-visible { outline: 3px solid #146b64; outline-offset: 3px; }
/* age-gate.css — mandatory first-run gate. Namespaced to #ageGate / .age-gate-*. */
#ageGate {
  --ag-cream: #fff4d8; --ag-cream-deep: #f3dcaa; --ag-gold: #ffc934;
  --ag-wood-ink: #4e2108; --ag-wood: #8a3f14; --ag-ink: #3a1a06;
  --ag-green-hi: #9ae33c; --ag-green: #4fb21a; --ag-green-deep: #2d7a0c; --ag-green-ink: #12330a;
  --ag-focus: #10305a;
  position: fixed; inset: 0; z-index: 2147483000;
  display: flex; align-items: flex-start; justify-content: center;
  padding: max(12px, env(safe-area-inset-top)) max(12px, env(safe-area-inset-right)) max(12px, env(safe-area-inset-bottom)) max(12px, env(safe-area-inset-left));
  overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  background: rgba(8, 36, 58, .72);
  font-family: "Fredoka FX", "Arial Rounded MT Bold", "Trebuchet MS", system-ui, sans-serif;
  color: var(--ag-ink); box-sizing: border-box;
  user-select: text;
}
#ageGate[hidden] { display: none !important; }
#ageGate *, #ageGate *::before, #ageGate *::after { box-sizing: border-box; }
body[data-age-blocked] { overflow: hidden; }
#gameRuntime[hidden] { display: none !important; }

/* Neutral first paint: the acknowledgement dialog is absent until required. */
#ageGateLoading {
  position: fixed; inset: 0; z-index: 2147483000;
  display: grid; place-items: center; padding: 24px;
  overflow-y: auto; background: rgba(8, 36, 58, .72);
  color: #3a1a06; font: 1rem/1.5 "Trebuchet MS", system-ui, sans-serif;
}
#ageGateLoading[hidden] { display: none !important; }
#ageGateLoading .age-loading-panel {
  width: min(100%, 440px); padding: 24px; border-radius: 16px;
  background: #fff4d8; text-align: center; box-sizing: border-box;
  overflow-wrap: anywhere;
}
#ageGateLoadingStatus { margin: 0; font-weight: 700; }
#ageGateLoading .age-loading-help { font-size: .9rem; }
@media (forced-colors: active) {
  #ageGateLoading, #ageGateLoading .age-loading-panel { background: Canvas; color: CanvasText; }
  #ageGateLoading .age-loading-panel { border: 2px solid CanvasText; }
}

#ageGate .age-gate-panel {
  position: relative; margin: auto; width: min(100%, 440px); min-width: 0;
  padding: clamp(18px, 5vw, 28px) clamp(16px, 5vw, 28px) clamp(20px, 5vw, 30px);
  background: linear-gradient(180deg, #ffffffaa 0 3px, transparent 3px), linear-gradient(180deg, var(--ag-cream), var(--ag-cream-deep));
  border: 4px solid var(--ag-gold); border-radius: 22px;
  box-shadow: 0 0 0 3px var(--ag-wood-ink), 0 8px 0 var(--ag-wood-ink), 0 22px 40px #06253f88;
  display: flex; flex-direction: column; gap: 14px;
}
#ageGate .age-gate-kicker {
  margin: 0; text-align: center; font-weight: 700; font-size: .8rem;
  letter-spacing: .14em; text-transform: uppercase; color: var(--ag-wood);
}
#ageGate #ageGateTitle {
  margin: 0; text-align: center; font-weight: 700; line-height: 1.15;
  font-size: clamp(1.5rem, 6.5vw, 2rem); text-wrap: balance; overflow-wrap: anywhere;
  color: var(--ag-wood-ink); -webkit-text-stroke: 0;
  text-shadow: 0 2px 0 #fff; letter-spacing: .01em;
}
#ageGate .age-gate-statements {
  list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 14px;
}
#ageGate .age-gate-statements li {
  position: relative; padding-left: 26px; font-size: 1.05rem; font-weight: 600;
  line-height: 1.4; color: var(--ag-ink); overflow-wrap: anywhere;
}
#ageGate .age-gate-statements li::before {
  content: ""; position: absolute; left: 4px; top: .55em; width: 11px; height: 11px;
  border-radius: 50%; background: var(--ag-wood);
}
#ageGate .age-gate-statements a {
  color: var(--ag-wood-ink); font-weight: 700; text-decoration: underline;
  text-decoration-thickness: 2px; text-underline-offset: 3px;
}
#ageGate .age-gate-statements a:hover { color: #a81f1c; }
#ageGate .age-gate-note { margin: 0; text-align: center; font-size: .9rem; font-weight: 600; color: #5a2a08; overflow-wrap: anywhere; }
#ageGate .age-gate-privacy { min-width: 0; margin: 0; padding: 12px; border: 2px solid var(--ag-wood); border-radius: 12px; }
#ageGate .age-gate-privacy legend { font-weight: 700; padding: 0 5px; }
#ageGate .age-gate-privacy p { margin: 8px 0; font-size: .9rem; line-height: 1.45; overflow-wrap: anywhere; }
#ageGate .age-gate-privacy label { display: flex; gap: 10px; align-items: flex-start; padding: 10px 0; min-height: 44px; font-weight: 700; }
#ageGate .age-gate-privacy input { flex: 0 0 auto; width: 22px; height: 22px; margin: 0; accent-color: #236526; }
#ageGate .age-gate-privacy input:focus-visible { outline: 3px solid var(--ag-focus); outline-offset: 3px; }
#ageGate #ageGateStatus { margin: 0; text-align: center; font-weight: 700; font-size: .95rem; color: #8a1424; overflow-wrap: anywhere; }
#ageGate #ageGateStatus:empty { display: none; }

#ageGate button {
  font: inherit; font-weight: 700; cursor: pointer; min-height: 48px; width: 100%;
  max-width: 100%; padding: 10px 18px; line-height: 1.2; overflow-wrap: anywhere;
}
#ageGate #ageGateRetry[hidden] { display: none !important; }
#ageGate .age-gate-confirm {
  align-self: center; width: min(100%, 260px); margin-top: 6px; min-height: 56px;
  font-size: 1.5rem; letter-spacing: .06em; text-transform: uppercase; color: #102408;
  -webkit-text-stroke: 0;
  text-shadow: 0 1px 0 #cfff90;
  background: linear-gradient(180deg, #ffffff77 0 3px, transparent 3px), linear-gradient(180deg, var(--ag-green-hi), var(--ag-green) 55%, #3f9a12);
  border: 3px solid var(--ag-green-ink); border-radius: 14px;
  box-shadow: inset 0 -4px 0 #1f5c0a55, 0 5px 0 var(--ag-green-deep), 0 8px 0 var(--ag-green-ink), 0 12px 14px #0a2a0a55;
  transition: transform .1s ease, box-shadow .1s ease;
}
#ageGate .age-gate-confirm:hover:not(:disabled) { filter: brightness(1.06); }
#ageGate .age-gate-confirm:active:not(:disabled) {
  transform: translateY(5px) !important;
  box-shadow: inset 0 -2px 0 #1f5c0a55, 0 0 0 var(--ag-green-deep), 0 3px 0 var(--ag-green-ink);
}
#ageGate .age-gate-confirm:disabled { filter: saturate(.4); cursor: not-allowed; }
#ageGate #ageGateRetry, #ageGate .age-gate-leave {
  align-self: center; width: min(100%, 260px); color: var(--ag-wood-ink);
  background: linear-gradient(180deg, #fff 0 2px, transparent 2px), linear-gradient(var(--ag-cream), var(--ag-cream-deep));
  border: 3px solid var(--ag-gold); border-radius: 14px; font-size: 1rem;
  box-shadow: 0 0 0 2px var(--ag-wood-ink), 0 4px 0 var(--ag-wood-ink);
}
#ageGate .age-gate-leave { background: transparent; border-color: var(--ag-wood); box-shadow: none; text-decoration: underline; text-underline-offset: 3px; min-height: 44px; }
#ageGate :is(button, a):focus-visible { outline: 4px solid var(--ag-focus); outline-offset: 3px; box-shadow: 0 0 0 7px #fff; }

@media (max-width: 340px) {
  #ageGate { padding: 8px; }
  #ageGate .age-gate-panel { border-width: 3px; border-radius: 16px; gap: 12px; }
  #ageGate .age-gate-statements li { font-size: 1rem; }
}
@media (max-height: 520px) and (orientation: landscape) {
  #ageGate { padding: 8px; }
  #ageGate .age-gate-panel { width: min(100%, 560px); gap: 10px; padding: 14px 20px 18px; }
  #ageGate #ageGateTitle { font-size: 1.4rem; }
  #ageGate .age-gate-statements { gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  #ageGate .age-gate-confirm { transition: none; }
}
@media (forced-colors: active) {
  #ageGate { background: Canvas; }
  #ageGate .age-gate-panel { border: 3px solid CanvasText; box-shadow: none; background: Canvas; }
  #ageGate #ageGateTitle { color: CanvasText; -webkit-text-stroke: 0; text-shadow: none; }
  #ageGate :is(.age-gate-kicker, .age-gate-note, #ageGateStatus, .age-gate-statements li) { color: CanvasText; }
  #ageGate .age-gate-statements li::before { background: CanvasText; forced-color-adjust: none; }
  #ageGate .age-gate-statements a { color: LinkText; }
  #ageGate :is(.age-gate-confirm, .age-gate-leave, #ageGateRetry) {
    background: ButtonFace; color: ButtonText; border: 3px solid ButtonText; box-shadow: none; text-shadow: none; -webkit-text-stroke: 0;
  }
  #ageGate :is(button, a):focus-visible { outline: 3px solid Highlight; box-shadow: none; }
}
