/* ＝＝＝＝＝＝＝＝＝＝＝
    全体リセット
＝＝＝＝＝＝＝＝＝＝＝ */
body, html {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
  }
/* ======================
   パスワード画面
====================== */
#lock {
  position: fixed;
  inset: 0;
  display: block;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

#lock p {
  margin-bottom: 20px;
  font-size: 16px;
  color: #555;
}

/* 枠 */
#lock {
  background: rgba(255, 255, 255, 0.9);
}

/* 中身 */
#lock > * {
  max-width: 320px;
}

#lock input {
  width: 100%;
  padding: 12px;
  font-size: 16px;
  border-radius: 14px;
  border: 1px solid #ddd;
  box-sizing: border-box;
  outline: none;
}

#lock input:focus {
  border-color: #ffb3c7;
}

/* ボタン */
#lock button {
  margin-top: 16px;
  width: 100%;
  padding: 12px 0;
  font-size: 16px;
  border: none;
  border-radius: 14px;
  background: #ffb3c7;
  color: #fff;
  cursor: pointer;
}

#lock button:hover {
  background: #ff9ab5;
}

#lock button:active {
  transform: scale(0.97);
}


/* 中身は最初は必ず隠す */
#content {
  display: none;
}


  
  /* ＝＝＝＝＝＝＝＝＝＝＝
      タイトル画像（1920×1080）
  ＝＝＝＝＝＝＝＝＝＝＝ */
  .title-page {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
  }
  
  .title-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
  }
  
  /* スマホ・タブレットで正方形表示 */
  @media (max-width: 768px) {
    .title-image {
      width: 100vw;
      height: 100vw; /* 正方形 */
      object-fit: cover;
      object-position: center; /* 横長画像の中央1080x1080を表示 */
    }
  }
  
/* ======================
   絵本ページ
====================== */
.page {
    position: relative;
    width: 100%;
    height: 100%;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
  }
  
  /* ------------------------
  フェードイン
  ------------------------ */
  .fadein-image {
    width: 90%;
    height: 100vh;
    object-fit: cover;
    opacity: 0;
    animation: fadeIn 2s ease forwards;
  }
  /* スマホ・タブレットで正方形にする */
@media (max-width: 768px) {
    .fadein-image {
      width: 100vw;       /* 画面幅いっぱい */
      height: 100vw;      /* 幅と高さを同じにして正方形 */
      object-fit: cover;  /* 中央1080x1080部分が表示される */
      object-position: center;
    }
  }
  
  @keyframes fadeIn {
    to { opacity: 1; }
  }


  /* ------------------------
   画像拡大フェードイン
------------------------ */
.zoom-fadein {
    width: 60%;
    height: 100vh;
    overflow: hidden;
    object-fit: cover;
    object-position: center;
   opacity: 1; 
    transform: scale(1.05);
    transition: opacity 3s ease, transform 1.5s ease;
  }
  
  /* スマホ・タブレット正方形対応 */
  @media (max-width: 768px) {
    .zoom-fadein {
      width: 100vw;
      height: 100vw;
      object-fit: cover;
      object-position: center;
    }
  }
  

  /* ------------------------
   共通フェードイン（スクロールで発火）
------------------------ */
.fadein-on-scroll {
    width: 90%;
    height: 100%;
    position: relative;
    object-fit: cover;
    object-position: center;
    opacity: 0;
    transform: scale(1);
    transition: opacity 2s ease, transform 1.5s ease;
  }
  
  /* スマホ・タブレット正方形表示 */
  @media (max-width: 768px) {
    .fadein-on-scroll {
      width: 100%;
      height: 100vw;
      position: relative;
      object-fit: cover;
      object-position: center;
    }
  }

  /* ------------------------
     PC限定ナビボタン
    ------------------------ */
  .pc-nav {
    display: none;
  }
  
  @media (min-width: 1080px) {
    .pc-nav {
      display: block;
      gap: 20px;
      position: absolute;
      bottom: 40%;
      left: 90%;
      transform: translateX(-50%);
    }
  
    .pc-nav{
      padding: 12px 20px;
      border: none;
      border-radius: 8px;
      font-size: 16px;
      cursor: pointer;
      z-index: 2;
    }
  }