@import url("common.css");

/* 基本設定 */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: var(--bg);
  color: var(--text-black);
  overflow-x: hidden;
}

/* ヘッダー：ロゴとカウントダウン */
header {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 10px 20px;
  height: 60px;
  background: var(--white);
}

.logo {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip-path: inset(100%);
  white-space: nowrap;
  border-width: 0;
}

.countdown {
  font-size: 1.2rem;
  font-weight: bold;
}

#days {
  font-size: 3rem;
  letter-spacing: 2px;
  color: var(--accent-red);
  padding: 0 10px;
}

.container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  height: calc(100vh - 60px);
  height: calc(100dvh - 60px);
  position: relative;
  color: var(--white);
  font-style: italic;
}

.spot {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background-size: cover;
  background-position: center;
  padding: 0 16px;
}

/* 背景画像（publicフォルダを参照） */
.river {
  grid-column: 1 / 2;
  grid-row: 1 / 2;
  background-position: 50% 74%;
  background-image: linear-gradient(rgb(0 0 0 / 10%), rgb(0 0 0 / 10%)), url("images/banner/kawa.jpg");
  transition: background-image 0.6s ease;
}

.river:hover {
  background-image: linear-gradient(#418ad36e, #418ad3b8), url("images/banner/kawa.jpg");
}

.mountain {
  grid-column: 2 / 3;
  grid-row: 1 / 2;
  background-position: 50% 82%;
  background-image: linear-gradient(rgb(0 0 0 / 10%), rgb(0 0 0 / 10%)), url("images/banner/yama.jpg");
  transition: background-image 0.6s ease;
}

.mountain:hover {
  background-image: linear-gradient(#485465a4, #87a3c1b3), url("images/banner/yama.jpg");
}

.camp {
  grid-column: 1 / -1;
  grid-row: 2 / 3;
  background-position: 50% 88%;
  background-image: linear-gradient(rgb(0 0 0 / 10%), rgb(0 0 0 / 10%)), url("images/banner/camp.jpg");
  transition: background-image 0.6s ease;
}

.camp:hover {
  background-image: linear-gradient(#f0c0325f, #f0c032b8), url("images/banner/camp.jpg");
}

/* .title h2::after rules removed */

.enter-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
}

.enter-btn img {
  width: 80%;
  height: auto;
  max-height: 80%;
  object-fit: contain;
}

/* セクション全体をクリック範囲にするための擬似要素 */
.enter-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  cursor: pointer;
}

.enter-btn:focus-visible {
  outline: 3px solid var(--white);
  outline-offset: 4px;
}

.bottom-row a:focus-visible {
  outline: 3px solid var(--white);
  outline-offset: 2px;
}

.middle-row {
  flex-grow: 1;
  display: flex;
  align-items: center;
  text-align: center;
  justify-content: center;
  width: 100%;
  letter-spacing: 2px;
}

/* --- レスポンシブ（スマホ用） --- */
@media (width <= 768px) {
  .container {
    display: flex;
    flex-direction: column;
    height: calc(100vh - 50px);
    height: calc(100dvh - 50px);
    min-height: auto;
    position: relative;
  }

  .spot {
    width: 100%;
    height: 34vh;
    min-height: auto;
    padding: 8px 16px;
  }

  /* ボタンサイズ調整 */

  .enter-btn img {
    width: 60%;
    height: auto;
    max-height: 60%;
  }

  /* ヘッダーのスマホ対応 */
  header {
    padding: 5px 15px;
    height: auto;
    min-height: 50px;
  }

  .countdown {
    font-size: 0.8rem;
  }

  #days {
    font-size: 1.6rem;
    padding: 0 4px;
  }
}
