/* Homepage layout trial only; game documents and shared site styles stay intact. */
.home-layout-test .container { min-width: 0; max-width: 1193px; }
.home-layout-test .home-layout-row { display: flex; align-items: flex-start; }
.home-layout-test .divleftside { flex: 0 0 172px; float: none; }
.home-layout-test .divcontent {
  box-sizing: border-box; flex: 1 1 auto; float: none;
  width: auto; min-width: 0; max-width: none; min-height: 0;
}
.home-layout-test .contentcontainer,
.home-layout-test .divfoot {
  box-sizing: border-box;
  min-width: 0;
  padding-inline: clamp(12px, 2vw, 20px);
}
.home-layout-test .contentcontainer :is(h1, h2, p, .ptable),
.home-layout-test .divfoot p { padding-inline: 0; }
.home-layout-test #rigamecontainer {
  --home-game-bottom-padding: 10px;
  box-sizing: border-box; position: relative; display: grid;
  grid-template-columns: minmax(0, 554px) 300px; column-gap: 150px;
  align-items: start; justify-content: center; width: 100%;
  padding: 0 6px var(--home-game-bottom-padding); margin: 6px 0 0;
  border: 2px solid #437bb2; background: #f2f7fc;
}
.home-layout-test #rigamecontainer::before {
  content: "ビューポート " attr(data-layout); position: absolute;
  right: 8px; top: 100%; margin-top: 4px; pointer-events: none;
  color: #315f8c; font: 12px/18px Arial, sans-serif;
}
.home-layout-test #ri1501,
.home-layout-test #ri1502 {
  float: none; display: none; width: 150px; height: 1px;
  background: transparent;
}
.home-layout-test #rigamediv {
  position: relative; float: none; justify-self: center;
  box-sizing: border-box; width: 100%; height: 520px; min-width: 0;
  max-width: none; max-height: none; margin: 0;
  border: 3px solid #20875e; background: #fff; overflow: hidden;
}
.home-layout-test #rigamediv::after {
  content: "ゲーム領域 " attr(data-size); position: absolute;
  left: 6px; bottom: 6px; z-index: 1; pointer-events: none;
  padding: 3px 6px; background: #20875e; color: #fff; font: 12px/18px Arial, sans-serif;
}
.home-layout-test #f1 {
  position: absolute; inset: 0 auto auto 0; display: block;
  box-sizing: border-box; width: 100%; height: 100%; border: 2px solid #df3a3a; background: #fff;
}
.home-layout-test.game-outlines-hidden #rigamecontainer {
  border-color: transparent; background: transparent;
}
.home-layout-test.game-outlines-hidden #rigamediv,
.home-layout-test.game-outlines-hidden #f1 { border-color: transparent; }
.home-layout-test.game-outlines-hidden #rigamecontainer::before,
.home-layout-test.game-outlines-hidden #rigamediv::after { visibility: hidden; }
.home-layout-test:not(.game-outlines-hidden) #leftsideadplay {
  outline: 2px dashed #9c2862; outline-offset: 2px;
}
.home-layout-test #rirightadarea {
  position: relative; float: none; display: block; align-self: stretch;
  box-sizing: border-box; width: 300px;
  margin: 0 0 calc(-1 * var(--home-game-bottom-padding)); padding: 0; background: transparent;
}
.home-ad-file-path {
  display: block; padding: 3px 6px; overflow-wrap: anywhere;
  color: #37526e; font: 12px/1.4 Consolas, monospace;
}
#rirightadarea > .home-ad-file-path,
#leftsideadplay > .home-ad-file-path { position: absolute; inset: 0 0 auto; }
.home-layout-test .layout-ad {
  box-sizing: border-box; display: flex; align-items: center;
  justify-content: center; flex-direction: column; gap: 8px;
  width: 300px; height: 250px; border: 2px solid #b87818;
  background: #f6d793; color: #654611; font: 16px/1.5 Arial, sans-serif;
}
.home-layout-test .layout-ad small { font-size: 13px; }
.home-layout-test #leftsideadplay.layout-ad {
  position: relative; width: 160px; height: 600px; margin: 24px auto 0;
  background: #e3edb7; border-color: #8b9c3e; color: #58651d;
}
@media (max-width: 1184px) {
  .home-layout-test #leftsideadplay.layout-ad,
  .home-layout-test #ri1501 { display: none; }
}
@media (max-width: 1060px), (orientation: portrait) {
  .home-layout-test #rigamecontainer { grid-template-columns: minmax(0, 1fr); }
  .home-layout-test #rirightadarea { display: none; }
}
html[data-site-mode="touch"] body.home-layout-test #rigamecontainer {
  grid-template-columns: minmax(0, 1fr); row-gap: 56px;
}
html[data-site-mode="touch"] .home-layout-test #rirightadarea { display: none; }
.home-layout-test #rigamediv:is(.compact-touch-layout, .stacked-desktop-portrait-frame) { overflow: visible; }
.home-layout-test #rigamediv:is(.compact-touch-layout, .stacked-desktop-portrait-frame)::after { top: calc(100% + 8px); bottom: auto; }
.home-layout-test #rigamediv:is(.touch-short-tablet-frame, .short-desktop-frame) { overflow: visible; }
.home-layout-test #rigamediv:is(.touch-short-tablet-frame, .short-desktop-frame)::after { left: calc(100% + 8px); white-space: nowrap; }
@media screen and (min-width: 1008px) and (orientation: landscape) {
  html[data-site-mode="touch"] body.home-layout-test #rigamecontainer {
    grid-template-columns: minmax(0, 554px) 300px;
  }
  html[data-site-mode="touch"] .home-layout-test #rirightadarea {
    display: block; grid-area: 1 / 2;
  }
}
@media (max-width: 962px) {
  .home-layout-test .divleftside { display: none; }
  .home-layout-test .divcontent { width: 100%; border: 0; padding: 0; }
}
@media (max-width: 767px) {
  .home-layout-test #rigamecontainer + br { display: none; }
}
@media (max-width: 350px) {
  .home-layout-test #rigamecontainer::before,
  .home-layout-test #rigamediv::after { font-size: 10px; }
}
@media (min-width: 768px) and (max-height: 650px) {
  .home-layout-test #rigamecontainer { --home-game-bottom-padding: 6px; margin-top: 0; }
}
