/**
 * First Visit Page Styles
 * 初めての方へ
 *
 * @package Fujioka_Theme_Light
 */

/* ===================================
   Welcome Section
   =================================== */

.first-visit-welcome {
  padding: 60px 40px;
  background: var(--color-bg-warm);
  text-align: center;
}

.first-visit-welcome-inner {
  max-width: 700px;
  margin: 0 auto;
}

.first-visit-welcome-text {
  font-family: var(--font-serif);
  font-size: 16px;
  line-height: 2.2;
  color: var(--color-text);
}

/* ===================================
   Common Section Styles
   =================================== */

.first-visit-section-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 80px 40px;
}

.first-visit-section-label {
  font-size: 12px;
  color: var(--color-accent);
  letter-spacing: 3px;
  text-align: center;
  margin-bottom: 8px;
}

.first-visit-section-title {
  font-family: var(--font-serif);
  font-size: 28px;
  color: var(--color-primary);
  text-align: center;
  margin-bottom: 48px;
  letter-spacing: 2px;
}

/* ===================================
   Welcome Message Section（写真左+縦書きメッセージ右）
   =================================== */

.first-visit-welcome-section {
  padding: 60px 40px 20px;
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
}

.first-visit-welcome-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 52px;
  align-items: stretch;
}

.first-visit-welcome-image-wrap {
  position: relative;
  height: 420px;
  opacity: 0;
  transform: translateY(-30px);
  animation: fadeInFromTop 1s ease forwards;
}

@keyframes fadeInFromTop {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.first-visit-welcome-image {
  width: 100%;
  height: 100%;
  background: var(--color-bg-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-light);
  font-size: 14px;
  overflow: hidden;
}

.first-visit-welcome-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 縦書きメッセージ */
.first-visit-welcome-content {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  height: 500px;
  padding: 10px 0;
}

.first-visit-welcome-title {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: bold;
  color: var(--color-primary);
  line-height: 2;
  letter-spacing: 3px;
  display: block;
  margin-left: 1.5em;
  opacity: 0;
  transform: translateY(-20px);
  animation: fadeInVertical 0.8s ease forwards, highlightExpand 0.8s ease forwards 1s;
  animation-delay: 0.3s, 1s;
  /* マーカー風ハイライト（縦書き：上から下へ） */
  position: relative;
  background: linear-gradient(to left, transparent 40%, var(--color-accent-pale) 40%);
  background-size: 100% 0%;
  background-repeat: no-repeat;
  background-position: top;
}

@keyframes highlightExpand {
  to {
    background-size: 100% 65%;
  }
}

.first-visit-welcome-text {
  font-size: 16px;
  line-height: 3;
  color: var(--color-text);
  letter-spacing: 2px;
  display: block;
  opacity: 0;
  transform: translateY(-20px);
  animation: fadeInVertical 0.8s ease forwards;
}

/* 本文の各行に順番にディレイを設定 */
.first-visit-welcome-text:nth-of-type(1) { animation-delay: 0.6s; }
.first-visit-welcome-text:nth-of-type(2) { animation-delay: 0.9s; }
.first-visit-welcome-text:nth-of-type(3) { animation-delay: 1.2s; }
.first-visit-welcome-text:nth-of-type(4) { animation-delay: 1.5s; }
.first-visit-welcome-text:nth-of-type(5) { animation-delay: 1.8s; }

/* 縦書き用アニメーション */
@keyframes fadeInVertical {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ===================================
   Flow Section
   ※スタイルはfront-page.cssの.flow-*クラスを共用
   =================================== */

.first-visit-flow {
  background: var(--color-bg);
}

/* ===================================
   FAQ Section
   =================================== */

.first-visit-faq {
  background: var(--color-bg-soft);
}

.first-visit-faq-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.first-visit-faq-item {
  background: var(--color-bg);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}

.first-visit-faq-question {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  cursor: pointer;
  list-style: none;
  transition: background 0.3s;
}

.first-visit-faq-question::-webkit-details-marker {
  display: none;
}

.first-visit-faq-question:hover {
  background: var(--color-bg-warm);
}

.first-visit-faq-q,
.first-visit-faq-a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 500;
  flex-shrink: 0;
}

.first-visit-faq-q {
  background: var(--color-accent);
  color: #fff;
}

.first-visit-faq-a {
  background: var(--color-sakura);
  color: #fff;
}

.first-visit-faq-question-text {
  flex: 1;
  font-size: 15px;
  color: var(--color-primary);
  font-weight: 500;
}

.first-visit-faq-toggle {
  color: var(--color-text-light);
  transition: transform 0.3s;
  display: flex;
  align-items: center;
}

.first-visit-faq-toggle i {
  display: flex;
}

.first-visit-faq-item[open] .first-visit-faq-toggle {
  transform: rotate(180deg);
}

.first-visit-faq-answer {
  display: flex;
  gap: 16px;
  padding: 0 24px 24px;
  padding-left: 72px;
}

.first-visit-faq-answer p {
  font-size: 14px;
  color: var(--color-text);
  line-height: 1.9;
}

/* ===================================
   Preparation Section
   =================================== */

.first-visit-prep {
  background: var(--color-bg);
}

.first-visit-prep-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.first-visit-prep-card {
  text-align: center;
  padding: 32px 24px;
  background: var(--color-bg-warm);
  border-radius: var(--radius-md);
}

.first-visit-prep-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  margin: 0 auto 16px;
  background: var(--color-accent-pale);
  border-radius: 50%;
  color: var(--color-accent);
}

.first-visit-prep-icon i {
  display: flex;
}

.first-visit-prep-title {
  font-family: var(--font-serif);
  font-size: 16px;
  color: var(--color-primary);
  margin-bottom: 12px;
}

.first-visit-prep-text {
  font-size: 14px;
  color: var(--color-text-light);
  line-height: 1.8;
}

/* ===================================
   Access Section
   地図+カードはfront-page.cssの.access-wrapper等を共用
   =================================== */

.first-visit-access {
  background: var(--color-bg-soft);
}

/* Access Guide (駐車場・入口案内) */
.first-visit-access-guide {
  margin-top: 48px;
  padding-top: 48px;
  border-top: 1px solid var(--color-border-light);
}

.first-visit-access-guide-text {
  font-size: 14px;
  color: var(--color-text);
}

.first-visit-access-photos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.first-visit-access-photo {
  text-align: center;
  position: relative;
}

.first-visit-access-photo img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
}

/* 写真フィルターオーバーレイ */
.first-visit-access-photo::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 200px;
  background: var(--color-bg-warm);
  opacity: 0.15;
  pointer-events: none;
  border-radius: var(--radius-md);
  z-index: 1;
}

.first-visit-access-photo-placeholder {
  width: 100%;
  height: 200px;
  background: var(--color-bg);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text-light);
  font-size: 14px;
}

.first-visit-access-photo-caption {
  margin-top: 12px;
  font-size: 14px;
  color: var(--color-text-light);
}

/* ===================================
   Responsive
   =================================== */

@media (max-width: 768px) {
  /* Welcome Message Section */
  .first-visit-welcome-section {
    padding: 30px 24px 10px;
  }

  .first-visit-welcome-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .first-visit-welcome-image-wrap {
    height: auto;
  }

  .first-visit-welcome-image {
    aspect-ratio: 16/10;
  }

  /* モバイルでは横書きに戻す */
  .first-visit-welcome-content {
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    height: auto;
    flex-direction: column;
    gap: 16px;
    padding: 0;
  }

  .first-visit-welcome-title {
    font-size: 20px;
    line-height: 1.6;
    letter-spacing: 2px;
    text-align: center;
    margin-left: 0;
    margin-bottom: 20px;
    /* 横書き用マーカーハイライト */
    background: linear-gradient(transparent 60%, var(--color-accent-pale) 60%);
    background-size: 20% 100%;
    background-repeat: no-repeat;
    background-position: center;
    animation: fadeInVertical 0.8s ease forwards, highlightExpandHorizontal 0.8s ease forwards;
    animation-delay: 0.2s, 0.8s;
  }

  @keyframes highlightExpandHorizontal {
    to {
      background-size: 65% 100%;
    }
  }

  .first-visit-welcome-text {
    font-size: 12px;
    line-height: 1.9;
    text-align: center;
    margin-bottom: 8px;
    animation: fadeInVertical 0.8s ease forwards;
    animation-delay: 0.4s;
  }

  /* モバイルではアニメーションディレイを統一 */
  .first-visit-welcome-text:nth-of-type(1),
  .first-visit-welcome-text:nth-of-type(2),
  .first-visit-welcome-text:nth-of-type(3),
  .first-visit-welcome-text:nth-of-type(4),
  .first-visit-welcome-text:nth-of-type(5) {
    animation-delay: 0.4s;
  }

  .first-visit-section-inner {
    padding: 20px 24px;
  }

  .first-visit-section-title {
    font-size: 24px;
    margin-bottom: 36px;
  }

  /* Flow - モバイルスタイルはfront-page.cssで定義済み */

  /* FAQ */
  .first-visit-faq-question {
    padding: 16px 20px;
  }

  .first-visit-faq-q,
  .first-visit-faq-a {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }

  .first-visit-faq-question-text {
    font-size: 14px;
  }

  .first-visit-faq-answer {
    padding-left: 20px;
    flex-direction: column;
    gap: 12px;
  }

  /* Prep - コンパクトな横並びレイアウト */
  .first-visit-prep-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .first-visit-prep-card {
    display: grid;
    grid-template-columns: 40px 1fr;
    grid-template-rows: auto auto;
    gap: 4px 12px;
    padding: 16px;
    text-align: left;
  }

  .first-visit-prep-icon {
    width: 40px;
    height: 40px;
    min-width: 40px;
    margin: 0;
    grid-row: 1 / 3;
  }

  .first-visit-prep-title {
    font-size: 14px;
    margin-bottom: 0;
    align-self: end;
  }

  .first-visit-prep-text {
    font-size: 12px;
    line-height: 1.6;
  }

  .first-visit-prep-text br {
    display: none;
  }

  /* Access Guide */
  .first-visit-access-guide {
    margin-top: 32px;
    padding-top: 32px;
  }

  .first-visit-access-guide-text {
    font-size: 14px;
    text-align: left;
  }

  .first-visit-access-photos {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .first-visit-access-photo img,
  .first-visit-access-photo-placeholder {
    height: 180px;
  }

  .first-visit-access-photo::before {
    height: 180px;
  }
}
