.iwashi-screen-header {
  position: fixed !important; inset: 0 0 auto !important;
  display: block; width: var(--iwashi-header-width,100dvw); height: auto; max-width: none; max-height: none;
  margin: 0 !important; padding: clamp(20px, 4vw, 64px) clamp(20px, 4vw, 64px) 0;
  box-sizing: border-box; border: 0; border-radius: 0; box-shadow: none;
  background: #e5e7e9; color: #25282c; z-index: 3000;
  transform: none !important; font-family: Arial, Helvetica, sans-serif;
  text-align: left; line-height: normal;
}
.iwashi-screen-header[hidden] { display: none !important; }
.iwashi-screen-header::backdrop { display: none; }
.iwashi-header-row { display: flex; align-items: center; gap: 12px; padding-bottom: 22px; border-bottom: 1px solid #bfc4ca; }
.iwashi-screen-header .iwashi-header-brand { font: 800 19px Arial, Helvetica, sans-serif; font-weight: 800 !important; letter-spacing: .2em; white-space: nowrap; }
.iwashi-header-icon { width: 28px; height: 28px; object-fit: contain; flex: 0 0 auto; }
.iwashi-header-home { margin-left: auto; flex: 0 0 auto; color: #424a53; text-decoration: none; font: 400 11px Arial, Helvetica, sans-serif; letter-spacing: .08em; }
.iwashi-header-home:focus-visible { outline: 2px solid #424a53; outline-offset: 5px; }
.iwashi-result-ancestor { transform: none !important; perspective: none !important; filter: none !important; contain: none !important; container-type: normal !important; }
[data-iwashi-result-host] {
  position: fixed !important; inset: auto !important;
  top: var(--iwashi-header-height, 0px) !important; left: 0 !important;
  width: 100dvw !important; height: calc(100dvh - var(--iwashi-header-height, 0px)) !important;
  min-width: 0 !important; min-height: 0 !important; max-width: none !important; max-height: none !important;
  margin: 0 !important; padding: 8px !important; box-sizing: border-box;
  transform: none !important; overflow: auto; z-index: 2000;
  background: #101214;
}
[data-iwashi-result-host="rotated"] {
  left: 50% !important; top: calc((100dvh + var(--iwashi-header-height, 0px)) / 2) !important;
  width: calc(100dvh - var(--iwashi-header-height, 0px)) !important; height: 100dvw !important;
  transform: translate(-50%, -50%) rotate(90deg) !important;
}
[data-iwashi-result-host] > :is(.result-card, .stats-card) { max-height: 100%; overflow: auto; }
@media (min-width:921px) and (hover:hover) and (pointer:fine) {
  :root:has([data-setup-fit-active]:not([hidden])) { --iwashi-header-width:100%; }
}
@media (max-width: 700px) {
  .iwashi-screen-header { padding: 16px 16px 0; }
  .iwashi-header-row { padding-bottom: 16px; }
}
@media (max-width: 420px) {
  .iwashi-header-row { gap: 7px; }
  .iwashi-screen-header .iwashi-header-brand { font-size: 15px; letter-spacing: .12em; }
}
@media (max-height: 440px) and (orientation: landscape) and (hover: none),
       (max-height: 440px) and (orientation: landscape) and (pointer: coarse) {
  .iwashi-screen-header { padding: 8px 14px 0; }
  .iwashi-header-row { padding-bottom: 6px; }
  .iwashi-screen-header .iwashi-header-brand { font-size: 15px; }
  .iwashi-header-icon { width: 24px; height: 24px; }
}

/* One title rail across all game setup screens. */
body[data-iwashi-header-screen="setup"] .iwashi-screen-header{height:80px!important;padding:0 32px!important}
body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-row{position:relative;display:flex!important;flex-wrap:nowrap!important;height:80px!important;min-height:0!important;box-sizing:border-box;padding:0!important}
body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-game{display:block!important;position:absolute!important;top:50%!important;left:50%!important;transform:translate(-50%,-50%)!important;flex:none!important;margin:0!important;font:400 32px/1.2 Arial,Helvetica,sans-serif!important;letter-spacing:.07em;white-space:nowrap}
body[data-iwashi-header-screen="setup"] .settings-game-title{display:none!important}
body[data-iwashi-header-screen="result"] .iwashi-header-game{display:none!important}
@media(max-width:920px),(pointer:coarse),(hover:none){
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header{height:72px!important;padding:0 16px!important}
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-row{height:72px!important}
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-game{font-size:20px!important}
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-brand{font-size:11px!important;letter-spacing:.08em!important}
 body[data-iwashi-header-screen="setup"] .iwashi-header-row{gap:4px}
 body[data-iwashi-header-screen="setup"] .iwashi-header-icon{width:20px;height:20px}
 body[data-iwashi-header-screen="setup"] .iwashi-header-home{font-size:9px}
}
@media(max-width:540px){
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-row{align-items:flex-start!important;padding-top:10px!important}
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-game{top:48px!important;font-size:20px!important}
}
@media(max-height:440px) and (orientation:landscape){
 body[data-iwashi-header-screen="setup"] .iwashi-screen-header,body[data-iwashi-header-screen="setup"] .iwashi-screen-header .iwashi-header-row{height:48px!important}
}
