/* Keep the first lobby viewport and every gameplay state intact. */
html:has(body.menu-screen) { scrollbar-width: none; }
html:has(body.menu-screen)::-webkit-scrollbar,
body.menu-screen::-webkit-scrollbar { display: none; }
body.menu-screen { overflow-x: hidden; overflow-y: auto; scrollbar-width: none; }
body.menu-screen #game-shell { position: relative; overflow: clip; height: 100vh; height: 100dvh; min-height: 100vh; min-height: 100dvh; }
body.menu-screen #game-shell .site-header,
body.menu-screen #game-shell .sidebar,
body.menu-screen #game-shell .game-section,
body.menu-screen #game-shell .menu-map-label,
body.menu-screen #game-shell .menu-controls { position: absolute; }
body.menu-screen #game-shell .sidebar { overscroll-behavior-y: auto; }
body:not(.menu-screen) #tailhunt-guide { display: none; }

#tailhunt-guide {
  --guide-paper: #f1eedf;
  --guide-ink: #293f35;
  --guide-muted: #5c6b5e;
  --guide-line: #c9cbbb;
  --guide-rust: #a4472c;
  position: relative;
  color: var(--guide-ink);
  background: var(--guide-paper);
  border-top: 6px solid #b75a3b;
  font-size: 16px;
  line-height: 1.85;
  word-break: keep-all;
  overflow-wrap: anywhere;
  touch-action: pan-y;
}
#tailhunt-guide .tailhunt-guide-inner { width: min(100%, 1232px); margin: 0 auto; padding: 0 max(40px, env(safe-area-inset-right, 0px)) 0 max(40px, env(safe-area-inset-left, 0px)); }
#tailhunt-guide a { text-decoration: none; }
#tailhunt-guide a:focus-visible { outline: 3px solid var(--guide-rust); outline-offset: 5px; }
#tailhunt-guide p { margin: 0; }
#tailhunt-guide strong { font-weight: 800; }
#tailhunt-guide .tailhunt-breadcrumb { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 23px 0; border-bottom: 1px solid var(--guide-line); font-size: 12px; color: var(--guide-muted); }
#tailhunt-guide .tailhunt-breadcrumb ol { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; list-style: none; margin: 0; padding: 0; }
#tailhunt-guide .tailhunt-breadcrumb li + li::before { content: '/'; margin-right: 10px; color: #909783; }
#tailhunt-guide .tailhunt-breadcrumb [aria-current] { color: var(--guide-ink); font-weight: 750; }
#tailhunt-guide .tailhunt-breadcrumb a { display: inline-flex; align-items: center; min-height: 28px; }
#tailhunt-guide .tailhunt-breadcrumb a:hover,
#tailhunt-guide .tailhunt-guide-footer a:hover { text-decoration: underline; text-underline-offset: 4px; }
#tailhunt-guide .tailhunt-edition { letter-spacing: .08em; }
#tailhunt-guide .tailhunt-guide-intro { display: grid; grid-template-columns: 1fr 1.08fr; gap: 54px; align-items: center; padding: 56px 0 48px; }
#tailhunt-guide .tailhunt-guide-eyebrow { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; font-size: 13px; font-weight: 800; }
#tailhunt-guide .tailhunt-guide-eyebrow > span[lang] { color: var(--guide-muted); font-size: 10px; letter-spacing: .12em; font-weight: 600; }
#tailhunt-guide .tailhunt-small-mark { width: 29px; height: 29px; display: grid; place-items: center; color: var(--guide-rust); }
#tailhunt-guide .tailhunt-small-mark svg { width: 29px; height: 29px; stroke: none; }
#tailhunt-guide h2 { margin: 23px 0 24px; font-size: clamp(40px, 4.5vw, 60px); line-height: 1.18; font-weight: 900; letter-spacing: -.065em; }
#tailhunt-guide h2 em { color: var(--guide-rust); font-style: normal; }
#tailhunt-guide .tailhunt-lead { font-size: 18px; font-weight: 800; letter-spacing: -.035em; margin-bottom: 12px; }
#tailhunt-guide .tailhunt-description { max-width: 440px; color: var(--guide-muted); font-size: 15px; line-height: 1.95; }
#tailhunt-guide .tailhunt-description strong { color: var(--guide-ink); font-weight: 600; }
#tailhunt-guide .tailhunt-market-photo { min-width: 0; margin: 0; border: 1px solid #a8b09a; padding: 7px 7px 0; background: #faf8ee; transform: rotate(-1deg); }
#tailhunt-guide .tailhunt-photo-frame { aspect-ratio: 1.5; overflow: hidden; background: #8e8f77; }
#tailhunt-guide .tailhunt-photo-frame img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center; }
#tailhunt-guide figcaption { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 5px 12px; padding: 10px 5px 11px; color: var(--guide-muted); font-size: 11px; letter-spacing: -.02em; }
#tailhunt-guide figcaption span:last-child { color: var(--guide-rust); font-weight: 750; }
#tailhunt-guide .tailhunt-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin: 0; padding: 25px 0 28px; border-top: 2px solid var(--guide-ink); border-bottom: 1px solid var(--guide-line); }
#tailhunt-guide .tailhunt-facts > div { display: flex; align-items: baseline; justify-content: center; flex-wrap: wrap; gap: 7px 20px; padding: 0 20px; }
#tailhunt-guide .tailhunt-facts > div + div { border-left: 1px solid var(--guide-line); }
#tailhunt-guide .tailhunt-facts dt { color: var(--guide-muted); font-size: 12px; }
#tailhunt-guide .tailhunt-facts dd { margin: 0; font-size: 33px; line-height: 1.3; font-weight: 850; letter-spacing: -.045em; font-variant-numeric: tabular-nums; }
#tailhunt-guide .tailhunt-facts dd span { margin-left: 4px; font-size: 14px; letter-spacing: -.03em; font-weight: 650; }
#tailhunt-guide .tailhunt-guide-section { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 52px; padding: 48px 0; border-bottom: 1px solid var(--guide-line); }
#tailhunt-guide .tailhunt-section-label { margin: 0 0 13px; color: var(--guide-rust); font-size: 12px; font-weight: 800; }
#tailhunt-guide h3 { margin: 0; font-size: 28px; line-height: 1.45; font-weight: 850; letter-spacing: -.055em; }
#tailhunt-guide h4 { margin: 0 0 8px; font-size: 17px; line-height: 1.6; font-weight: 800; letter-spacing: -.035em; }
#tailhunt-guide .tailhunt-rules { list-style: none; margin: 0; padding: 0; }
#tailhunt-guide .tailhunt-rules li { display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: 20px; padding: 0 0 23px; }
#tailhunt-guide .tailhunt-rules li + li { padding-top: 23px; border-top: 1px solid var(--guide-line); }
#tailhunt-guide .tailhunt-rules li:last-child { padding-bottom: 0; }
#tailhunt-guide .tailhunt-rule-number { padding-top: 2px; color: var(--guide-rust); font: 700 15px/1.8 ui-monospace, monospace; }
#tailhunt-guide .tailhunt-rules p,
#tailhunt-guide .tailhunt-entry-options p { color: var(--guide-muted); font-size: 14px; line-height: 1.95; }
#tailhunt-guide .tailhunt-rules strong,
#tailhunt-guide .tailhunt-entry-options strong { color: var(--guide-ink); font-weight: 750; }
#tailhunt-guide .tailhunt-entry-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 30px; }
#tailhunt-guide .tailhunt-entry-options > div + div { padding-left: 30px; border-left: 1px solid var(--guide-line); }
#tailhunt-guide .tailhunt-guide-controls { margin: 48px 0 0; padding: 32px 36px 34px; color: #f7f3e5; background: #2c4339; }
#tailhunt-guide .tailhunt-controls-heading { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 10px 24px; padding-bottom: 26px; border-bottom: 1px solid #b7c1aa44; }
#tailhunt-guide .tailhunt-controls-heading h3 { font-size: 25px; }
#tailhunt-guide .tailhunt-controls-heading p { color: #d1d6c7; font-size: 13px; }
#tailhunt-guide .tailhunt-controls-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 36px; padding-top: 24px; }
#tailhunt-guide .tailhunt-control-sheet + .tailhunt-control-sheet { padding-left: 36px; border-left: 1px solid #b7c1aa44; }
#tailhunt-guide .tailhunt-control-sheet h4 { margin-bottom: 4px; font-size: 17px; color: #f7f3e5; }
#tailhunt-guide .tailhunt-control-note { color: #d1d6c7; font-size: 12px; }
#tailhunt-guide .tailhunt-control-sheet dl { margin: 20px 0 0; }
#tailhunt-guide .tailhunt-control-sheet dl > div { display: grid; grid-template-columns: 118px minmax(0, 1fr); align-items: baseline; gap: 12px; padding: 12px 0; border-top: 1px solid #b7c1aa33; font-size: 13px; line-height: 1.7; }
#tailhunt-guide .tailhunt-control-sheet dt { color: #d1d6c7; font-weight: 500; }
#tailhunt-guide .tailhunt-control-sheet dd { margin: 0; }
#tailhunt-guide kbd { display: inline-block; min-width: 22px; height: auto; margin: 0 1px 0 0; padding: 1px 5px; border: 1px solid #d3d8c4; border-bottom-width: 3px; border-radius: 3px; color: #293f35; background: #eeeedd; font: 700 11px/1.5 ui-monospace, monospace; text-align: center; white-space: nowrap; vertical-align: baseline; }
#tailhunt-guide .tailhunt-return { display: flex; align-items: center; justify-content: space-between; gap: 28px; padding: 40px 0; }
#tailhunt-guide .tailhunt-return p { font-size: 21px; line-height: 1.5; letter-spacing: -.04em; }
#tailhunt-guide .tailhunt-return a { display: inline-flex; justify-content: space-between; align-items: center; gap: 28px; min-height: 54px; padding: 12px 20px; color: #fff9e9; background: #a4472c; font-size: 15px; font-weight: 800; transition: background .15s; }
#tailhunt-guide .tailhunt-return a:hover { background: #853820; }
#tailhunt-guide .tailhunt-return a span { font-size: 24px; line-height: 1; }
#tailhunt-guide .tailhunt-guide-footer { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px 22px; padding: 20px 0; border-top: 1px solid var(--guide-line); font-size: 12px; }
#tailhunt-guide .tailhunt-guide-footer > span { font-weight: 800; }
#tailhunt-guide .tailhunt-guide-footer [lang] { margin-left: 10px; color: var(--guide-muted); font-size: 9px; font-weight: 600; letter-spacing: .12em; }
#tailhunt-guide .tailhunt-guide-footer a { display: inline-flex; align-items: center; gap: 8px; min-height: 32px; color: var(--guide-muted); }

@media (max-width: 1000px) {
  #tailhunt-guide .tailhunt-guide-intro { gap: 30px; }
  #tailhunt-guide h2 { font-size: clamp(40px, 5.2vw, 54px); }
  #tailhunt-guide .tailhunt-guide-section { grid-template-columns: 190px minmax(0, 1fr); gap: 30px; }
  #tailhunt-guide .tailhunt-controls-columns { gap: 24px; }
  #tailhunt-guide .tailhunt-control-sheet + .tailhunt-control-sheet { padding-left: 24px; }
  #tailhunt-guide .tailhunt-control-sheet dl > div { grid-template-columns: 93px minmax(0, 1fr); }
}
@media (max-width: 760px) {
  #tailhunt-guide .tailhunt-guide-inner { padding-right: max(24px, env(safe-area-inset-right, 0px)); padding-left: max(24px, env(safe-area-inset-left, 0px)); }
  #tailhunt-guide .tailhunt-breadcrumb { padding: 15px 0; }
  #tailhunt-guide .tailhunt-edition { display: none; }
  #tailhunt-guide .tailhunt-guide-intro { grid-template-columns: minmax(0, 1fr); gap: 30px; padding: 34px 0; }
  #tailhunt-guide h2 { font-size: clamp(43px, 7.8vw, 58px); margin-top: 18px; margin-bottom: 20px; }
  #tailhunt-guide .tailhunt-description { max-width: 560px; }
  #tailhunt-guide .tailhunt-market-photo { width: 100%; transform: none; }
  #tailhunt-guide .tailhunt-photo-frame { aspect-ratio: 1.7; }
  #tailhunt-guide .tailhunt-facts { padding: 20px 0; }
  #tailhunt-guide .tailhunt-facts > div { display: block; text-align: center; padding: 0 8px; }
  #tailhunt-guide .tailhunt-facts dt { margin-bottom: 7px; font-size: 11px; }
  #tailhunt-guide .tailhunt-facts dd { font-size: 28px; }
  #tailhunt-guide .tailhunt-facts dd span { font-size: 12px; }
  #tailhunt-guide .tailhunt-guide-section { grid-template-columns: minmax(0, 1fr); gap: 23px; padding: 32px 0; }
  #tailhunt-guide .tailhunt-section-label { margin-bottom: 8px; }
  #tailhunt-guide h3 { font-size: 26px; }
  #tailhunt-guide .tailhunt-section-heading h3 br { display: none; }
  #tailhunt-guide .tailhunt-rules li { gap: 12px; grid-template-columns: 26px minmax(0, 1fr); }
  #tailhunt-guide .tailhunt-entry-options { gap: 22px; }
  #tailhunt-guide .tailhunt-entry-options > div + div { padding-left: 22px; }
  #tailhunt-guide .tailhunt-guide-controls { padding: 25px 24px; margin-top: 32px; }
  #tailhunt-guide .tailhunt-controls-heading { padding-bottom: 20px; }
  #tailhunt-guide .tailhunt-controls-heading h3 { font-size: 23px; }
  #tailhunt-guide .tailhunt-controls-columns { grid-template-columns: minmax(0, 1fr); gap: 27px; padding-top: 20px; }
  #tailhunt-guide .tailhunt-control-sheet + .tailhunt-control-sheet { padding: 24px 0 0; border-left: 0; border-top: 1px solid #b7c1aa66; }
  #tailhunt-guide .tailhunt-control-sheet dl > div { grid-template-columns: 118px minmax(0, 1fr); }
  #tailhunt-guide .tailhunt-return { padding: 30px 0; }
  #tailhunt-guide .tailhunt-return p { font-size: 19px; }
}
@media (max-width: 480px) {
  #tailhunt-guide .tailhunt-guide-inner { padding-right: max(20px, env(safe-area-inset-right, 0px)); padding-left: max(20px, env(safe-area-inset-left, 0px)); }
  #tailhunt-guide .tailhunt-lead { font-size: 16px; }
  #tailhunt-guide .tailhunt-description { font-size: 14px; }
  #tailhunt-guide .tailhunt-entry-options { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  #tailhunt-guide .tailhunt-entry-options > div + div { padding-left: 0; border-left: 0; }
  #tailhunt-guide .tailhunt-guide-controls { padding: 24px 20px; }
  #tailhunt-guide .tailhunt-control-sheet dl > div { grid-template-columns: 88px minmax(0, 1fr); font-size: 13px; gap: 10px; }
  #tailhunt-guide .tailhunt-return { align-items: stretch; flex-direction: column; gap: 20px; }
  #tailhunt-guide .tailhunt-return p br { display: none; }
  #tailhunt-guide .tailhunt-return a { min-height: 54px; }
}
@media (prefers-reduced-motion: reduce) { #tailhunt-guide .tailhunt-return a { transition: none; } }
/* Portrait still blocks gameplay input; the guide remains readable below. */
@media (orientation: portrait) and (max-width: 850px), (orientation: portrait) and (pointer: coarse) {
  body.menu-screen #landscape-gate { position: absolute; inset: 0 0 auto; height: 100vh; height: 100dvh; min-height: 100vh; min-height: 100dvh; touch-action: pan-y; }
}
#tailhunt-guide .tailhunt-data-link {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

