/* =========================================================
   三河屋製パン — カスタムCSS
   手書きのスタイルはこのファイルに集約しています。
   通常の見た目の調整は、基本このファイルを編集してください。
   （assets/index.css は Tailwind の自動生成ファイルのため編集しません）
   ========================================================= */

/* ----- ヒーロー2スライド・お知らせ本文の装飾・各種アニメーション ----- */

/* ヒーロー: 2スライドのホワイトアウト切替 */
.hero-slide {
  opacity: 0;
  transition: opacity 0.6s ease;
  pointer-events: none;
}
.hero-slide.is-active {
  opacity: 1;
  pointer-events: auto;
}
.hero-zoom {
  animation: heroZoom 14s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes heroZoom {
  from {
    transform: scale(1);
  }
  to {
    transform: scale(1.08);
  }
}

/* スライドインジケーター（ドット） */
.hero-dot {
  width: 0.75rem;
  height: 0.75rem;
  padding: 0;
  border: 0;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.5);
  transition: all 0.3s ease;
  cursor: pointer;
}
.hero-dot:hover {
  background: rgba(255, 255, 255, 0.7);
}
.hero-dot.is-active {
  background: #fff;
  width: 2rem;
}

/* スクロール矢印のバウンス */
.hero-bounce {
  animation: heroBounce 1.5s ease-in-out infinite;
}
@keyframes heroBounce {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(8px);
  }
}

/* お知らせ詳細: リッチ本文の装飾 */
.news-content {
  color: #44403c;
  line-height: 1.9;
  font-size: 1rem;
  word-break: break-word;
}
.news-content > *:first-child {
  margin-top: 0;
}
.news-content p {
  margin: 0 0 1.1em;
}
.news-content h1 {
  font-size: 1.6rem;
  font-weight: 700;
  color: #5c4033;
  margin: 1.6em 0 0.6em;
  line-height: 1.4;
}
.news-content h2 {
  font-size: 1.35rem;
  font-weight: 700;
  color: #5c4033;
  margin: 1.5em 0 0.5em;
  padding-bottom: 0.3em;
  border-bottom: 2px solid #f0e6da;
  line-height: 1.4;
}
.news-content h3 {
  font-size: 1.15rem;
  font-weight: 700;
  color: #5c4033;
  margin: 1.3em 0 0.4em;
}
.news-content h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #5c4033;
  margin: 1.2em 0 0.4em;
}
.news-content strong,
.news-content b {
  font-weight: 700;
  color: #3f3a34;
}
.news-content em,
.news-content i {
  font-style: italic;
}
.news-content u {
  text-decoration: underline;
}
.news-content a {
  color: #b45309;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.news-content a:hover {
  color: #92400e;
}
.news-content ul {
  list-style: disc;
  padding-left: 1.5em;
  margin: 0 0 1.1em;
}
.news-content ol {
  list-style: decimal;
  padding-left: 1.5em;
  margin: 0 0 1.1em;
}
.news-content li {
  margin: 0.3em 0;
}
.news-content blockquote {
  border-left: 4px solid #d4a574;
  background: #fbf6ef;
  padding: 0.6em 1em;
  margin: 0 0 1.1em;
  color: #6b5b4d;
  border-radius: 0 0.4rem 0.4rem 0;
}
.news-content img {
  max-width: 100%;
  height: auto;
  border-radius: 0.5rem;
  margin: 0.8em 0;
}
.news-content hr {
  border: 0;
  border-top: 1px solid #e8dfd8;
  margin: 1.6em 0;
}
.news-content table {
  border-collapse: collapse;
  width: 100%;
  margin: 0 0 1.1em;
}
.news-content th,
.news-content td {
  border: 1px solid #e8dfd8;
  padding: 0.5em 0.7em;
  text-align: left;
}
.news-content th {
  background: #fbf6ef;
}
.news-content code {
  background: #f5f0eb;
  padding: 0.1em 0.35em;
  border-radius: 0.25em;
  font-size: 0.9em;
}

/* ヒーロー: ページ読み込み時のオープニング（ホワイトアウト → 画像が現れる） */
.hero-intro {
  position: absolute;
  inset: 0;
  background: #fff;
  z-index: 30;
  pointer-events: none;
  animation: heroIntro 1s ease-out forwards;
}
@keyframes heroIntro {
  0%,
  12% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

/* ヒーロー スライド2: 左上から画像が1枚ずつ → 最後にテキスト（本番の挙動を再現） */
.hero-slide[data-slide="1"] .hero-cell,
.hero-slide[data-slide="1"] .hero-s2-text,
.hero-slide[data-slide="1"] .hero-s2-btns {
  opacity: 0;
}
.hero-slide.is-active[data-slide="1"] .hero-cell {
  animation: heroCellIn 1s ease both;
}
.hero-slide.is-active[data-slide="1"] .hero-cell:nth-child(1) {
  animation-delay: 0.2s;
}
.hero-slide.is-active[data-slide="1"] .hero-cell:nth-child(2) {
  animation-delay: 0.4s;
}
.hero-slide.is-active[data-slide="1"] .hero-cell:nth-child(3) {
  animation-delay: 0.6s;
}
.hero-slide.is-active[data-slide="1"] .hero-cell:nth-child(4) {
  animation-delay: 0.8s;
}
.hero-slide.is-active[data-slide="1"] .hero-s2-text {
  animation: heroFadeUp 0.8s ease both;
  animation-delay: 1s;
}
.hero-slide.is-active[data-slide="1"] .hero-s2-btns {
  animation: heroFadeUp 0.8s ease both;
  animation-delay: 1.2s;
}
@keyframes heroCellIn {
  from {
    opacity: 0;
    transform: scale(1.1);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
@keyframes heroFadeUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ----- トップページ：湯気（steam）アニメーション ----- */

.steam-container {
  position: absolute;
  bottom: 30%;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 200px;
}

.steam {
  position: absolute;
  bottom: 0;
  width: 40px;
  height: 80px;
  background: linear-gradient(to top, rgba(255, 255, 255, 0.3), transparent);
  border-radius: 50%;
  filter: blur(10px);
  animation: steam-rise 3s ease-out infinite;
}

.steam-1 {
  left: 30%;
  animation-delay: 0s;
}

.steam-2 {
  left: 50%;
  animation-delay: 1s;
}

.steam-3 {
  left: 70%;
  animation-delay: 2s;
}

@keyframes steam-rise {
  0% {
    opacity: 0;
    transform: translateY(0) scale(1);
  }
  20% {
    opacity: 0.4;
  }
  80% {
    opacity: 0.2;
  }
  100% {
    opacity: 0;
    transform: translateY(-100px) scale(1.5);
  }
}

/* ----- 給食ページ：商品グリッドのPC/スマホ表示切替 ----- */

@media (max-width: 639px) {
  .bread-scatter-desktop {
    display: none !important;
  }
  .bread-grid-mobile {
    display: grid !important;
  }
}
@media (min-width: 640px) {
  .bread-grid-mobile {
    display: none !important;
  }
}

@media (max-width: 639px) {
  .rice-scatter-desktop {
    display: none !important;
  }
  .rice-grid-mobile {
    display: grid !important;
  }
}
@media (min-width: 640px) {
  .rice-grid-mobile {
    display: none !important;
  }
}
