/* 共通設定：配色・コンテンツ幅・余白・角丸など、ページ全体の基準値。 */
:root {
  /* ディグの白い毛を面に、耳のゴールドを流れとして使う */
  --ivory: #fffdf9;
  --warm-white: #ffffff;
  --champagne: #b89a67;
  /* ロゴはディグの耳の毛に寄せた、少し明るく落ち着いたシャンパン色にする。 */
  --logo-champagne: #c9b38d;
  --champagne-soft: #ddcdb2;
  --warm-beige: #f5f0e8;
  --warm-brown: #6d5e52;
  --deep-brown: #322b27;
  --line: rgba(50, 43, 39, 0.12);
  --blue: #2477a7;
  --cyan: #59c9ce;
  --page-width: 1180px;
  --section-space: clamp(6rem, 10vw, 10rem);
  --radius-large: 2rem;
  --shadow: 0 24px 70px rgba(72, 55, 39, 0.12);
}

/* サイズ計算とページ内移動の基本設定。固定ヘッダーとの重なりも調整する。 */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  /* 固定ヘッダーの下にセクション見出しを表示する。 */
  scroll-padding-top: 7.5rem;
}

/* ページ全体の白い背景・耳色のグラデーションと、本文の文字組み。 */
body {
  margin: 0;
  background:
    radial-gradient(
      ellipse 48rem 62rem at 108% 9%,
      rgba(184, 154, 103, 0.5) 0%,
      rgba(221, 205, 178, 0.34) 38%,
      rgba(255, 255, 255, 0) 72%
    ),
    radial-gradient(
      ellipse 44rem 62rem at -12% 46%,
      rgba(184, 154, 103, 0.38) 0%,
      rgba(221, 205, 178, 0.24) 42%,
      rgba(255, 255, 255, 0) 72%
    ),
    radial-gradient(
      ellipse 46rem 58rem at 108% 82%,
      rgba(184, 154, 103, 0.42) 0%,
      rgba(221, 205, 178, 0.26) 40%,
      rgba(255, 255, 255, 0) 72%
    ),
    var(--warm-white);
  color: var(--deep-brown);
  font-family:
    "Hiragino Kaku Gothic ProN", "Yu Gothic", "YuGothic", "Noto Sans JP",
    sans-serif;
  font-size: 16px;
  line-height: 1.8;
  -webkit-font-smoothing: antialiased;
}

/* JavaScriptから長さを更新する、画面上端の読了バー。 */
.scroll-progress {
  position: fixed;
  z-index: 100;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--champagne);
  transform: scaleX(0);
  transform-origin: left;
  will-change: transform;
}

/* 全画面メニューを開いている間は、背後のページをスクロールさせない。 */
body.menu-open {
  overflow: hidden;
}

/* リンクとボタンの共通表示を整え、端末の標準スタイルとの差を抑える。 */
a {
  color: inherit;
  text-decoration: none;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

/* キーボードで本文へ移動するリンク。フォーカスを受けたときだけ画面内へ出す。 */
.skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100;
  padding: 0.65rem 1rem;
  border-radius: 999px;
  background: var(--deep-brown);
  color: white;
  transform: translateY(-150%);
  transition: transform 180ms ease;
}

.skip-link:focus {
  transform: translateY(0);
}

/* 固定ヘッダー：スクロール時は半透明の背景を重ねて文字を読みやすくする。 */
.site-header {
  position: fixed;
  z-index: 20;
  top: 0;
  left: 0;
  width: 100%;
  transition:
    background-color 240ms ease,
    box-shadow 240ms ease;
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 1px 0 var(--line);
  backdrop-filter: blur(14px);
}

/* 各セクションの横幅と左右余白を揃える、共通の内側コンテナ。 */
.header-inner,
.section-inner,
.hero-inner,
.footer-inner {
  width: min(calc(100% - 3rem), var(--page-width));
  margin-inline: auto;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 7rem;
}

/* 採用ロゴの耳の毛流れと、太めで間隔を取ったブランド名を組み合わせる。 */
.brand {
  display: inline-flex;
  gap: 0.7rem;
  align-items: center;
  font-family: "Arial", "Helvetica Neue", sans-serif;
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  line-height: 1;
}

.brand-mark {
  display: block;
  width: 6.5rem;
  aspect-ratio: 1611 / 976;
  flex: none;
  /* 採用済みPNGの透明度を使い、輪郭と毛流れを保ったまま色だけ指定する。 */
  background-color: var(--logo-champagne);
  -webkit-mask: url("assets/wandea-mark-dig.png") center / contain no-repeat;
  mask: url("assets/wandea-mark-dig.png") center / contain no-repeat;
}

.brand-name {
  white-space: nowrap;
}

.brand-name strong {
  color: inherit;
  font-weight: inherit;
}

/* PCのページ内ナビゲーション。スマホ幅では下部のメディアクエリで切り替える。 */
.global-nav {
  display: flex;
  gap: 2.4rem;
  align-items: center;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.global-nav a {
  position: relative;
}

/* ブランドと開発中サービスへのページ内リンクを同じ装飾で揃える。 */
.global-nav a::after {
  position: absolute;
  right: 0;
  bottom: -0.35rem;
  left: 0;
  height: 1px;
  background: var(--champagne);
  content: "";
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 220ms ease;
}

.global-nav a:hover::after,
.global-nav a:focus-visible::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* メニューの開閉ボタンは、スマホ向けのレイアウトで表示する。 */
.menu-button {
  display: none;
}

/* メインビジュアル：コピーと線画を左右に配置し、有機的な背景を添える。 */
.hero {
  position: relative;
  min-height: 780px;
  overflow: hidden;
  padding: 9.5rem 0 6.5rem;
}

.hero::before {
  position: absolute;
  top: -20%;
  right: -9%;
  width: min(57vw, 780px);
  height: 115%;
  border-radius: 46% 0 0 55%;
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at 54% 38%, var(--warm-white) 0 24%, transparent 24.5%),
    linear-gradient(145deg, var(--warm-white) 8%, var(--champagne-soft) 68%, var(--champagne) 100%);
  content: "";
  transform: rotate(4deg);
}

.hero-inner {
  position: relative;
  display: grid;
  min-height: 590px;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
}

/* セクションの役割を示す小さな英字ラベル。 */
.eyebrow {
  margin: 0 0 1.45rem;
  color: var(--warm-brown);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.24em;
}

/* ファーストビューの見出しと説明文。コピーは画面幅に応じて折り返す。 */
.hero h1 {
  margin: 0;
  color: var(--warm-brown);
  font-family: "Yu Mincho", "YuMincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(2.7rem, 4vw, 3.6rem);
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.42;
}

.hero h1 span {
  display: block;
  /* 長いコピーも画面幅に応じて自然に改行する。 */
  overflow-wrap: anywhere;
  line-break: strict;
}

.hero-description {
  max-width: 38rem;
  margin: 2rem 0 2.4rem;
  color: var(--deep-brown);
  font-size: clamp(0.92rem, 1.4vw, 1.03rem);
  line-height: 2.05;
}

/* ページ内の案内ボタン：基本形・矢印・ホバー時の動きを共通化する。 */
.button {
  display: inline-flex;
  min-height: 3.8rem;
  gap: 2rem;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 1.2rem 0.9rem 1.6rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    background-color 180ms ease;
}

.button span {
  display: grid;
  width: 2.1rem;
  height: 2.1rem;
  place-items: center;
  border-radius: 50%;
  transition: transform 180ms ease;
}

.button:hover span,
.button:focus-visible span {
  transform: translate(2px, -2px);
}

.button:hover,
.button:focus-visible {
  transform: translateY(-2px);
}

/* 開発中サービスへの主導線を、耳色のアクセントで強調する。 */
.button-primary {
  min-width: 13.5rem;
  background: var(--champagne);
  box-shadow: 0 10px 28px rgba(143, 113, 65, 0.2);
  color: var(--deep-brown);
}

.button-primary:hover,
.button-primary:focus-visible {
  background: var(--warm-brown);
  color: white;
  box-shadow: 0 13px 34px rgba(143, 113, 65, 0.28);
}

.button-primary span {
  background: rgba(255, 255, 255, 0.18);
}

/* 二人とディグの写真をもとにした、3枚の線画を表示する領域。 */
.hero-visual {
  position: relative;
  justify-self: end;
  width: min(100%, 500px);
}

.visual-frame {
  position: relative;
  width: 100%;
  aspect-ratio: 1.25;
  overflow: visible;
  isolation: isolate;
  /* 線画を額縁で囲わず、ページの白い余白へなじませる。 */
  /* 3枚とも同じ周期でゆっくり上下し、操作ボタンは動かさない。 */
  animation: visual-float 16s ease-in-out infinite;
}

/* 画像は同じ位置に重ね、選択中の1枚だけをフェードで表示する。 */
.hero-key-visual {
  position: absolute;
  z-index: 2;
  bottom: 0;
  left: 50%;
  width: 100%;
  max-width: none;
  height: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 1200ms ease, visibility 1200ms;
  transform: translateX(-50%);
}

/* 同じ枠で重ねて切り替え、画像ごとのページの上下動を防ぐ。 */
.hero-key-visual.is-active {
  opacity: 1;
  visibility: visible;
}

/* 左右の操作ボタン：JavaScriptの準備が済むまで表示しない。 */
.hero-carousel-controls {
  display: none;
  position: absolute;
  z-index: 4;
  top: 43%;
  right: 0;
  left: 0;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
}

.carousel-ready .hero-carousel-controls { display: flex; }
.carousel-arrow {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.85);
  color: var(--warm-brown);
  cursor: pointer;
  pointer-events: auto;
  font-size: 1.8rem;
  line-height: 1;
  transition: background-color 200ms ease;
}
.carousel-arrow:hover {
  background: var(--champagne-soft);
}

/* 線画に添えるストーリーのキャプション。 */
.visual-caption {
  margin: 1rem 0 0;
  color: var(--deep-brown);
  font-family: Georgia, serif;
  font-size: 0.76rem;
  font-style: italic;
  letter-spacing: 0.1em;
  text-align: right;
}

/* メインビジュアルの余白に置く、円と小さな点の装飾。 */
.hero-decoration {
  position: absolute;
  border: 1px solid rgba(184, 154, 103, 0.35);
  border-radius: 50%;
}

.hero-decoration-one {
  bottom: 4%;
  left: -5rem;
  width: 12rem;
  height: 12rem;
}

.hero-decoration-two {
  bottom: 10%;
  left: 5rem;
  width: 1rem;
  height: 1rem;
  background: var(--champagne);
  animation: dot-drift 5s ease-in-out infinite;
}

/* ブランドの言葉を横へ流す帯。画面外にはみ出す部分は隠す。 */
.idea-ribbon {
  overflow: hidden;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--warm-white);
}

.idea-ribbon-track {
  display: flex;
  width: max-content;
  gap: 2rem;
  align-items: center;
  padding: 1rem 0;
  color: var(--warm-brown);
  font-family: Georgia, serif;
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  white-space: nowrap;
  animation: ribbon-flow 28s linear infinite;
}

.idea-ribbon-track i {
  color: var(--champagne);
  font-style: normal;
}

/* 同じ文言を2組並べた帯を半分ずつ動かし、横方向のループにつなげる。 */
@keyframes ribbon-flow {
  to {
    transform: translateX(-50%);
  }
}

/* キービジュアル全体を、一定の周期でゆっくり上下させる。 */
@keyframes visual-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}

/* 小さな点の装飾を、斜め方向へ緩やかに往復させる。 */
@keyframes dot-drift {
  0%,
  100% {
    transform: translate(0, 0);
  }
  50% {
    transform: translate(8px, -8px);
  }
}

/* 本文セクションの共通余白と、サービス紹介の見出し・番号・2カラム配置。 */
.section {
  padding-block: var(--section-space);
}

.service {
  position: relative;
  background: transparent;
}

.section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  border-bottom: 1px solid var(--line);
}

.section-number {
  margin: -1rem 0 0;
  color: rgba(184, 154, 103, 0.22);
  font-family: Georgia, serif;
  font-size: clamp(3.5rem, 7vw, 6.25rem);
  line-height: 1;
}

.service-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: clamp(4rem, 9vw, 8rem);
  align-items: center;
  padding-top: clamp(3rem, 7vw, 6rem);
}

/* 開発状況を、小さな点とラベルで控えめに示す。 */
.service-status {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  margin: 1.5rem 0 1.4rem;
  color: var(--warm-brown);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.16em;
}

.service-status span {
  width: 0.46rem;
  height: 0.46rem;
  border-radius: 50%;
  background: var(--champagne);
  box-shadow: 0 0 0 5px rgba(184, 154, 103, 0.14);
}

/* サービス名とブランド紹介で使う、明朝体の共通見出し。 */
.service h2,
.about h2 {
  margin: 0;
  color: var(--warm-brown);
  font-family: "Yu Mincho", "YuMincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(2.6rem, 5vw, 4.3rem);
  font-weight: 500;
  letter-spacing: 0.05em;
  line-height: 1.4;
}

/* サービスのコンセプト・導入文・説明文の読みやすさを整える。 */
.service-lead {
  margin: 0.8rem 0 2rem;
  color: var(--warm-brown);
  font-size: clamp(1.25rem, 2vw, 1.55rem);
  font-weight: 600;
  letter-spacing: 0.08em;
}

.service-introduction {
  margin: 1rem 0 0;
  color: var(--deep-brown);
  line-height: 2;
}

.service-description,
.service-experience {
  margin: 0;
  color: var(--deep-brown);
}

.service-experience {
  margin-top: 1rem;
}

/* 「撮る・見る・気づく」を並べ、狭い画面では折り返す体験フロー。 */
.experience-flow {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  align-items: center;
  margin-top: 2rem;
}

.experience-flow span {
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--warm-brown);
  font-size: 0.78rem;
  font-weight: 700;
}

.experience-flow i {
  color: var(--champagne);
  font-style: normal;
}

/* サービス画面の見本を置くパネルと、画面イメージであることを示すラベル。 */
.product-preview {
  position: relative;
  min-height: 640px;
  border-radius: var(--radius-large);
  border: 1px solid var(--line);
  background:
    radial-gradient(circle at 18% 18%, var(--warm-white), transparent 30%),
    linear-gradient(145deg, var(--warm-white) 20%, var(--ivory) 65%, var(--champagne-soft));
  perspective: 1000px;
}

.preview-label {
  position: absolute;
  top: 1.25rem;
  left: 1.5rem;
  margin: 0;
  color: var(--warm-brown);
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.16em;
}

/* スマホの外枠・画面・ヘッダー。傾きはJavaScriptからCSS変数で更新する。 */
.phone-shell {
  --tilt-x: 0px;
  --tilt-y: 0px;
  --tilt-rotate: 2deg;
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  width: min(52%, 270px);
  padding: 0.55rem;
  border: 2px solid rgba(255, 255, 255, 0.82);
  border-radius: 2.8rem;
  background: var(--deep-brown);
  box-shadow: 0 30px 70px rgba(76, 59, 42, 0.23);
  transform: translate(calc(-50% + var(--tilt-x)), calc(-50% + var(--tilt-y))) rotate(var(--tilt-rotate));
  transition: transform 260ms ease;
  will-change: transform;
}

.phone-screen {
  overflow: hidden;
  border-radius: 2.3rem;
  background: var(--warm-white);
}

.phone-header {
  display: flex;
  height: 3.65rem;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.15rem;
  color: var(--warm-brown);
  font-size: 0.72rem;
  font-weight: 700;
}

/* カメラ画面風の背景と光の装飾。実際のカメラ映像は使用しない。 */
.camera-scene {
  position: relative;
  height: 290px;
  overflow: hidden;
  background: linear-gradient(160deg, var(--warm-beige), var(--champagne));
}

.scene-glow {
  position: absolute;
  top: -20%;
  right: -25%;
  width: 80%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: rgba(255, 246, 228, 0.42);
}

/* 画面イメージ内の犬を、顔・目・左右の耳の図形で組み立てる。 */
.dog-portrait {
  position: absolute;
  right: 10%;
  bottom: -8%;
  width: 80%;
  height: 73%;
}

.dog-face {
  position: absolute;
  right: 12%;
  bottom: 0;
  width: 76%;
  height: 85%;
  border-radius: 46% 54% 39% 42%;
  background: linear-gradient(130deg, var(--warm-white) 0 45%, var(--champagne) 46% 65%, var(--warm-beige) 66%);
  box-shadow: inset -18px 8px 35px rgba(99, 74, 51, 0.18);
}

.dog-face::before,
.dog-face::after {
  position: absolute;
  top: 41%;
  width: 0.45rem;
  height: 0.58rem;
  border-radius: 50%;
  background: var(--deep-brown);
  content: "";
}

.dog-face::before {
  left: 28%;
}

.dog-face::after {
  right: 25%;
}

.dog-ear {
  position: absolute;
  z-index: 2;
  top: 12%;
  width: 35%;
  height: 55%;
  border-radius: 50% 50% 35% 50%;
  background: var(--warm-brown);
}

.dog-ear-left {
  left: 0;
  transform: rotate(-18deg);
}

.dog-ear-right {
  right: 0;
  transform: rotate(18deg);
}

/* 犬の気持ちの表現例を、しっぽ付きの吹き出しで表示する。 */
.speech-bubble {
  position: absolute;
  z-index: 4;
  top: 1rem;
  left: 50%;
  width: max-content;
  margin: 0;
  padding: 0.72rem 1rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 9px 25px rgba(70, 50, 32, 0.12);
  color: var(--warm-brown);
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.55;
  text-align: center;
  transform: translateX(-50%);
}

.speech-bubble::after {
  position: absolute;
  bottom: -0.5rem;
  left: 50%;
  border-width: 0.55rem 0.45rem 0;
  border-style: solid;
  border-color: rgba(255, 255, 255, 0.94) transparent transparent;
  content: "";
  transform: translateX(-50%);
}

/* スマホ内の結果ラベルと、操作しない見本用ボタンの表示。 */
.result-panel {
  padding: 1rem 1.1rem 1.3rem;
}

.result-label {
  margin: 0 0 0.65rem;
  color: var(--deep-brown);
  font-size: 0.62rem;
  letter-spacing: 0.1em;
}

.result-panel button {
  width: 100%;
  padding: 0.7rem;
  border: 0;
  border-radius: 999px;
  background: var(--champagne);
  color: white;
  font-size: 0.72rem;
  font-weight: 700;
  opacity: 1;
}

/* スマホの周囲に重ねる補足カード。位置と浮遊する動きを上下で変える。 */
.preview-card {
  position: absolute;
  z-index: 3;
  display: flex;
  flex-direction: column;
  padding: 1rem 1.2rem;
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 1rem;
  background: rgba(255, 253, 249, 0.82);
  box-shadow: 0 14px 35px rgba(87, 66, 46, 0.1);
  backdrop-filter: blur(8px);
}

.preview-card span {
  color: var(--warm-brown);
  font-family: Georgia, serif;
  font-size: 1.15rem;
}

.preview-card small {
  color: var(--deep-brown);
  font-size: 0.5rem;
  letter-spacing: 0.14em;
}

.preview-card-top {
  top: 16%;
  right: 7%;
  animation: card-drift 5.5s ease-in-out infinite;
}

.preview-card-bottom {
  bottom: 12%;
  left: 6%;
  animation: card-drift 6.5s 700ms ease-in-out infinite reverse;
}

/* 補足カードを少し持ち上げ、軽く傾けて戻す浮遊演出。 */
@keyframes card-drift {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-8px) rotate(1deg);
  }
}

/* ブランド紹介：名前の由来と活動方針を、左右のカラムで配置する。 */
.about {
  overflow: hidden;
}

.about-grid {
  display: grid;
  grid-template-columns: 0.88fr 1.12fr;
  column-gap: clamp(3rem, 9vw, 8rem);
  row-gap: 5rem;
}

.about h2 {
  font-size: clamp(2.7rem, 5.3vw, 4.5rem);
  letter-spacing: 0.02em;
}

.about h2 .about-plus {
  color: var(--champagne);
  font-size: 0.72em;
}

.about-word { display: inline-block; }

/* スクロールで体験フローとブランド名を順に見せる。 */
@media (prefers-reduced-motion: no-preference) {
  .motion-ready .experience-flow.is-visible > span {
    animation: hero-enter 650ms both ease-out;
  }
  .motion-ready .experience-flow.is-visible > span:nth-of-type(2) { animation-delay: 180ms; }
  .motion-ready .experience-flow.is-visible > span:nth-of-type(3) { animation-delay: 360ms; }
  .motion-ready .about-title-block.is-visible .about-word {
    animation: hero-enter 900ms both ease-out;
  }
  .motion-ready .about-title-block.is-visible .about-word:last-child { animation-delay: 250ms; }
  .motion-ready .about-title-block.is-visible .about-plus {
    display: inline-block;
    animation: idea-connect 900ms 100ms both ease-out;
  }
}

/* ブランド名の「＋」を回転と拡大でつなぎ、由来を印象づける。 */
@keyframes idea-connect {
  from { opacity: 0; transform: rotate(-90deg) scale(0.65); }
  to { opacity: 1; transform: rotate(0) scale(1); }
}

/* ブランド紹介の本文・段落間隔・リード文を整える。 */
.about-content {
  padding-top: 2.9rem;
}

.about-content p {
  margin: 0;
  color: var(--deep-brown);
}

.about-content p + p {
  margin-top: 1.2rem;
}

.about-content .about-lead {
  margin-bottom: 1.8rem;
  color: var(--warm-brown);
  font-family: "Yu Mincho", "YuMincho", "Hiragino Mincho ProN", serif;
  font-size: clamp(1.3rem, 2.5vw, 1.8rem);
  line-height: 1.6;
}

/* 方針をカード状に並べるためのスタイル。現在のHTMLでは未使用。 */
.about-principles {
  display: grid;
  grid-column: 1 / -1;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.about-principles article {
  min-height: 210px;
  padding: 2rem;
}

.about-principles article + article {
  border-left: 1px solid var(--line);
}

.about-principles span {
  color: var(--champagne);
  font-family: Georgia, serif;
  font-size: 0.73rem;
}

.about-principles h3 {
  margin: 1.8rem 0 0.5rem;
  color: var(--warm-brown);
  font-family: "Yu Mincho", "YuMincho", "Hiragino Mincho ProN", serif;
  font-size: 1.35rem;
  font-weight: 500;
}

.about-principles p {
  margin: 0;
  color: var(--deep-brown);
  font-size: 0.88rem;
}

/* 最後のブランド紹介から、既存の余白でフッターへつなぐ。 */
.site-footer {
  padding: 3.5rem 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1.5rem;
}

.footer-inner > p {
  margin: 0;
  color: var(--deep-brown);
  font-family: Georgia, serif;
  font-size: 0.7rem;
  font-style: italic;
  letter-spacing: 0.08em;
}

.footer-inner .copyright {
  justify-self: end;
  font-family: inherit;
  font-style: normal;
  letter-spacing: 0.04em;
}

/* スマホだけに表示する補助要素は、PC幅では隠す。 */
.mobile-only {
  display: none;
}

/* スクロール表示の共通状態。JavaScriptが無効でも本文は読める状態に保つ。 */
.reveal {
  opacity: 1;
  transform: translateY(0);
}

.motion-ready .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 650ms ease,
    transform 650ms ease;
}

.motion-ready .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ファーストビューのラベル・見出し・説明・ボタンを順に表示する。 */
.motion-ready .hero-copy.is-visible .eyebrow,
.motion-ready .hero-copy.is-visible h1 span,
.motion-ready .hero-copy.is-visible .hero-description,
.motion-ready .hero-copy.is-visible .button {
  animation: hero-enter 650ms both ease-out;
}

.motion-ready .hero-copy.is-visible h1 span:first-child {
  animation-delay: 80ms;
}

.motion-ready .hero-copy.is-visible h1 span:last-child {
  animation-delay: 160ms;
}

.motion-ready .hero-copy.is-visible .hero-description {
  animation-delay: 240ms;
}

.motion-ready .hero-copy.is-visible .button {
  animation-delay: 320ms;
}

/* フェードと短い上方向の移動を組み合わせる、登場演出の基本動作。 */
@keyframes hero-enter {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* キーボードで選択している要素を、共通のフォーカス枠で示す。 */
:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 4px;
}

/* タブレット・スマホ：全画面メニューへ切り替え、本文を1カラムに積む。 */
@media (max-width: 860px) {
  .header-inner,
  .section-inner,
  .hero-inner,
  .footer-inner {
    width: min(calc(100% - 2rem), var(--page-width));
  }

  .header-inner {
    height: 6.15rem;
  }

  .brand-mark {
    width: 5.5rem;
  }

  .brand {
    font-size: 1rem;
  }

  /* 丸い開閉ボタンを表示し、開いた状態では2本線を閉じる記号に変える。 */
  .menu-button {
    position: relative;
    z-index: 22;
    display: grid;
    width: 2.8rem;
    height: 2.8rem;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 50%;
    place-content: center;
    gap: 0.35rem;
    background: rgba(255, 253, 249, 0.75);
  }

  .menu-button span {
    display: block;
    width: 1.05rem;
    height: 1px;
    background: var(--deep-brown);
    transition: transform 180ms ease;
  }

  .menu-button[aria-expanded="true"] span:first-child {
    transform: translateY(3px) rotate(45deg);
  }

  .menu-button[aria-expanded="true"] span:last-child {
    transform: translateY(-3px) rotate(-45deg);
  }

  /* ナビゲーションを画面全体へ広げ、閉じたリンクは操作対象から外す。 */
  .global-nav {
    position: fixed;
    z-index: 21;
    inset: 0;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    align-items: center;
    justify-content: center;
    background: rgba(250, 248, 243, 0.97);
    font-family: Georgia, serif;
    font-size: 1.45rem;
    opacity: 0;
    /* 閉じたリンクをキーボード操作と支援技術の読み上げ対象から外す。 */
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-0.5rem);
    transition:
      opacity 180ms ease,
      transform 180ms ease;
  }

  .global-nav.is-open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
  }

  /* コピーの下へ線画を移し、サービス説明とプレビューも縦に並べる。 */
  .hero {
    min-height: auto;
    padding: 8.5rem 0 5rem;
  }

  .hero::before {
    top: auto;
    right: -45%;
    bottom: 0;
    width: 105%;
    height: 48%;
  }

  .hero-inner,
  .service-grid,
  .about-grid {
    grid-template-columns: 1fr;
  }

  .hero-inner {
    gap: 4.5rem;
  }

  .hero-copy {
    position: relative;
    z-index: 2;
  }

  .hero-visual {
    width: min(84%, 430px);
    justify-self: center;
  }

  .service-grid {
    gap: 4rem;
  }

  .product-preview {
    min-height: 570px;
  }

  .about-content {
    padding-top: 0;
  }

  .about-grid {
    row-gap: 2.5rem;
  }

  .about-principles {
    margin-top: 2rem;
    grid-template-columns: 1fr;
  }

  .about-principles article {
    min-height: auto;
  }

  .about-principles article + article {
    border-top: 1px solid var(--line);
    border-left: 0;
  }

  /* フッターのロゴ・メッセージ・著作権を縦に並べる。 */
  .footer-inner {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
    align-items: flex-start;
  }

  .footer-inner .copyright {
    align-self: flex-start;
  }
}

/* 小さなスマホ：見出し・ロゴ・余白・画面イメージを画面幅に合わせて調整する。 */
@media (max-width: 560px) {
  :root {
    --section-space: 5.5rem;
    --radius-large: 1.3rem;
  }

  .brand {
    gap: 0.6rem;
    font-size: 0.85rem;
  }

  .brand-mark {
    width: 4.75rem;
  }

  .hero {
    padding-top: 7.7rem;
  }

  .hero h1 {
    font-size: clamp(2.25rem, 11vw, 3rem);
    line-height: 1.48;
  }

  .hero-description {
    margin-top: 1.4rem;
    line-height: 1.9;
  }

  .desktop-only {
    display: none;
  }

  .mobile-only {
    display: initial;
  }

  .hero-visual {
    width: 94%;
  }

  .visual-caption {
    text-align: left;
  }

  .section-number {
    font-size: 3.7rem;
  }

  .service-grid {
    padding-top: 2.8rem;
  }

  .service h2,
  .about h2 {
    font-size: 2.6rem;
  }

  .product-preview {
    min-height: 490px;
    margin-inline: -0.15rem;
  }

  .phone-shell {
    width: 61%;
  }

  .camera-scene {
    height: 245px;
  }

  .preview-card {
    padding: 0.8rem 0.9rem;
  }

  .preview-card-top {
    top: 9%;
    right: 3%;
  }

  .preview-card-bottom {
    bottom: 7%;
    left: 2%;
  }

  .about-principles article {
    padding: 1.5rem 1rem;
  }

}

/* 動きを抑える設定：スクロール・表示切り替え・常時アニメーションを抑制する。 */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }

  .hero-visual,
  .visual-frame,
  .hero-key-visual,
  .hero-decoration-two,
  .idea-ribbon-track,
  .preview-card,
  .motion-ready .hero-copy.is-visible .eyebrow,
  .motion-ready .hero-copy.is-visible h1 span,
  .motion-ready .hero-copy.is-visible .hero-description,
  .motion-ready .hero-copy.is-visible .button {
    animation: none;
  }
}
