html { color-scheme: light; }

html:not([lang="ru"]) .ru { display: none; }
html[lang="ru"] .ja { display: none; }

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  background: #e3dfd6;
  color: #1a2226;
  font-family: "Zen Kaku Gothic New", "Hiragino Sans", "Yu Gothic", sans-serif;
  font-size: 1.05rem;
  line-height: 1.75;
}

html[lang="ru"] body {
  font-family: "Source Sans 3", "Segoe UI", sans-serif;
  font-size: 1.08rem;
}

a { color: #7d3224; text-underline-offset: 0.16em; }
a:hover { color: #541f16; }

.skip {
  position: absolute;
  left: 0.6rem;
  top: -3rem;
  background: #1a2226;
  color: #f4f1ea;
  padding: 0.35rem 0.6rem;
  z-index: 30;
}
.skip:focus { top: 0.4rem; }

.kishi {
  position: relative;
  height: 400px;
  overflow: hidden;
  background:
    linear-gradient(#c5d2dc 0%, #d7e1e8 46%, #d7e1e8 52%,
      #c9bfb3 52%, #c2b6a8 70%,
      #6e6963 70%, #5a564f 86%,
      #2a4250 86%, #1d3340 100%);
}

.hi-nashi { display: none; }

.ie {
  position: absolute;
  bottom: 48%;
  background: #5a6672;
  z-index: 2;
}

.ie span {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 7px;
  background: #3c4650;
}

.ie1 { left: 5%; width: 78px; height: 48px; }
.ie2 { left: 46%; width: 132px; height: 72px; }
.ie3 { right: 4%; width: 96px; height: 44px; }

.ie .mado {
  position: absolute;
  background: rgba(198, 214, 224, 0.45);
}
.ie1 .mado { width: 8px; height: 10px; left: 14px; bottom: 12px; box-shadow: 22px 0 0 rgba(198, 214, 224, 0.45); }
.ie2 .mado { width: 9px; height: 11px; left: 16px; bottom: 16px; box-shadow: 28px 0 0 rgba(198, 214, 224, 0.4), 56px 0 0 rgba(198, 214, 224, 0.45), 84px 0 0 rgba(198, 214, 224, 0.35); }
.ie3 .mado { width: 8px; height: 10px; left: 16px; bottom: 12px; box-shadow: 26px 0 0 rgba(198, 214, 224, 0.4), 52px 0 0 rgba(198, 214, 224, 0.4); }

.tower {
  position: absolute;
  left: 53%;
  bottom: 48%;
  width: 40px;
  height: 176px;
  z-index: 1;
}

.tower .shaft {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 22px;
  height: 140px;
  transform: translateX(-50%);
  background: linear-gradient(#6d7f90, #3a4854);
  clip-path: polygon(32% 0, 68% 0, 100% 100%, 0 100%);
}

.tower .deck {
  position: absolute;
  left: 50%;
  bottom: 92px;
  width: 36px;
  height: 10px;
  transform: translateX(-50%);
  background: #f4f7f8;
  border-radius: 2px;
}

.tower .needle {
  position: absolute;
  left: 50%;
  bottom: 138px;
  width: 3px;
  height: 36px;
  transform: translateX(-50%);
  background: #3a4854;
}

.hashi { display: none; }

.ki {
  position: absolute;
  left: 14%;
  bottom: 31%;
  width: 86px;
  height: 132px;
  z-index: 4;
  overflow: visible;
}

.miki {
  position: absolute;
  left: 56px;
  bottom: 0;
  width: 10px;
  height: 78px;
  background: #3a322b;
  border-radius: 6px 6px 1px 1px;
}

.eda {
  position: absolute;
  left: 60px;
  bottom: 70px;
  width: 54px;
  height: 6px;
  background: #3a322b;
  border-radius: 4px;
  transform: rotate(-36deg);
  transform-origin: left center;
}

.eda2 {
  position: absolute;
  left: 16px;
  bottom: 52px;
  width: 48px;
  height: 6px;
  background: #3a322b;
  border-radius: 4px;
  transform: rotate(32deg);
  transform-origin: right center;
}

.eda3 {
  position: absolute;
  left: 62px;
  bottom: 104px;
  width: 36px;
  height: 5px;
  background: #3a322b;
  border-radius: 4px;
  transform: rotate(-14deg);
  transform-origin: left center;
}

.koya {
  position: absolute;
  right: 30%;
  bottom: 31%;
  width: 78px;
  z-index: 5;
}

#yane {
  position: relative;
  height: 28px;
  background: #24302a;
  clip-path: polygon(50% 0, 100% 100%, 0 100%);
}

.koya-body {
  height: 34px;
  background: #3c5a48;
  border-bottom: 3px solid #24382e;
}

.koya-body i {
  display: block;
  width: 14px;
  height: 16px;
  margin: 8px auto 0;
  background: #d7e0e4;
}

.benchi {
  position: absolute;
  left: 40%;
  bottom: 31%;
  width: 84px;
  z-index: 5;
}

.ban {
  position: relative;
  height: 9px;
  background: #6b5142;
}

.ashi {
  display: flex;
  justify-content: space-between;
  height: 16px;
  padding: 0 6px;
}

.ashi i {
  width: 4px;
  background: #46362c;
}

.tesuri {
  position: absolute;
  left: 8%;
  width: 58%;
  bottom: calc(30% + 8px);
  height: 6px;
  background: #4d5962;
  z-index: 4;
}

.tesuri::before,
.tesuri::after {
  content: "";
  position: absolute;
  bottom: -18px;
  width: 3px;
  height: 18px;
  background: #4d5962;
}

.tesuri::before { left: 18%; }
.tesuri::after { right: 22%; }

.gishi {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 30%;
  height: 12px;
  background: #b7b1a8;
  z-index: 3;
  box-shadow: 0 1px 0 #4e4a45;
}

.kaidan {
  position: absolute;
  left: 9%;
  bottom: 14%;
  width: 92px;
  z-index: 4;
}

.dan {
  position: relative;
  height: 18px;
  margin-top: 3px;
  background: #8a847c;
  border-top: 1px solid #d4cfc6;
}

.dan:nth-child(2) { width: 74%; margin-left: auto; }
.dan:nth-child(3) { width: 48%; margin-left: auto; }

.fune {
  position: absolute;
  left: 43%;
  bottom: 4%;
  width: 78px;
  height: 16px;
  background: #1a2830;
  border-radius: 2px 8px 4px 4px;
  z-index: 2;
}

.fune::before {
  content: "";
  position: absolute;
  left: 14px;
  bottom: 14px;
  width: 22px;
  height: 12px;
  background: #2a4252;
}

.bui {
  position: absolute;
  left: 58%;
  bottom: 6%;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #2f7a4c;
  box-shadow: inset -5px -4px 0 #1a4630;
  z-index: 2;
}

.yane-yuki,
.yukicap,
.yuki-sora {
  pointer-events: none;
}

.yane-yuki {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.yukicap {
  position: absolute;
  left: 0;
  top: 0;
  z-index: 2;
}

.yuki-sora {
  position: fixed;
  inset: 0;
  z-index: 12;
  width: 100%;
  height: 100%;
}

.namae {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: flex-end;
  gap: 0.7rem 1.8rem;
  padding: 0.95rem 7vw 0;
}

.chi {
  margin: 0;
  font-size: 0.84rem;
  letter-spacing: 0.08em;
  color: #3e4c54;
}

nav { display: flex; flex-wrap: wrap; gap: 0.15rem 0.95rem; }

nav a {
  color: #1a2226;
  text-decoration: none;
}

nav a:hover { color: #7d3224; }

nav a[aria-current="page"] {
  color: #7d3224;
  box-shadow: inset 0 -2px 0 #7d3224;
}

.kotoba {
  display: flex;
  gap: 0.85rem;
  width: 100%;
  font-size: 0.88rem;
}

.kotoba button {
  margin: 0;
  padding: 0.15rem 0;
  border: 0;
  background: transparent;
  color: #1a2226;
  font: inherit;
  cursor: pointer;
}

html:not([lang="ru"]) .kotoba button[data-kotoba="ja"],
html[lang="ru"] .kotoba button[data-kotoba="ru"] {
  color: #7d3224;
  box-shadow: inset 0 -2px 0 #7d3224;
}

.honbun {
  padding: 1.15rem 7vw 2.4rem;
  max-width: 44rem;
}

h1 {
  margin: 0.15rem 0 0.7rem;
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 0.03em;
}

html[lang="ru"] h1 {
  font-weight: 600;
  letter-spacing: 0;
  font-size: 2.15rem;
}

.hiduke {
  margin: 0;
  color: #3e4c54;
  font-size: 0.92rem;
}

.shirabe {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.7rem 1.2rem;
  margin: 1rem 0 1.15rem;
  padding: 0.7rem 0;
  border-top: 1px solid #c9c2b6;
  border-bottom: 1px solid #c9c2b6;
}

.shirabe div { min-width: 7.5rem; }

.shirabe dt {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  color: #5b686f;
}

.shirabe dd { margin: 0; font-weight: 500; }

.honbun p { margin: 0 0 0.95rem; }

.kako {
  margin: 0;
  padding: 0;
  list-style: none;
}

.kako li {
  padding: 0.95rem 0;
  border-top: 1px solid #c9c2b6;
}

.kako li:last-child { border-bottom: 1px solid #c9c2b6; }

.kako time {
  display: block;
  color: #3e4c54;
  font-size: 0.92rem;
}

.kako strong {
  display: block;
  margin: 0.1rem 0 0.35rem;
  font-size: 1.25rem;
  font-weight: 700;
}

html[lang="ru"] .kako strong { font-weight: 600; letter-spacing: 0; }

.kako p { margin: 0; }

footer {
  padding: 0 7vw 2.6rem;
  color: #3e4c54;
  font-size: 0.95rem;
}

footer p { margin: 0.2rem 0; }

@media (max-width: 720px) {
  .kishi { height: 300px; }
  .tower { height: 120px; left: 50%; }
  .tower .shaft { height: 96px; }
  .tower .needle { height: 28px; bottom: 92px; }
  .tower .deck { bottom: 60px; width: 28px; }
  .hashi { width: 96px; bottom: 72%; }
  .shirabe { grid-template-columns: 1fr 1fr; }
  .ie2 { width: 88px; height: 52px; }
  .ie1, .ie3 { display: none; }
  .ki { left: 8%; height: 96px; }
  .miki { height: 62px; }
  .koya { right: 8%; width: 64px; }
  .benchi { left: 40%; }
  .tesuri { width: 46%; }
  .fune { left: 16%; }
  .bui { left: 68%; bottom: 8%; }
  .honbun, .namae, footer { padding-left: 1.1rem; padding-right: 1.1rem; }
  h1 { font-size: 1.7rem; }
}
