@tailwind base;
@tailwind components;
@tailwind utilities;

:root {
  --header-height: 78px;
  --navy: #061634;
  --deep: #02091c;
  --ink: #102548;
  --blue: #087cff;
  --cyan: #38dfff;
  --orange: #f28a2b;
  --soft: #f3f8ff;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 20px);
  overflow-x: hidden;
}

body {
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background: #fff;
  font-family: var(--font-sans), system-ui, sans-serif;
  letter-spacing: 0;
}

/* スマホでスクロール中に画面が左右にブレる対策:
   overflow-x: hidden はiOS Safariで横方向のパン（ラバーバンド）を許してしまうため、
   対応ブラウザでは clip で横スクロールを完全に禁止する */
@supports (overflow-x: clip) {
  html,
  body {
    overflow-x: clip;
  }
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select,
textarea {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.container {
  width: min(1180px, calc(100% - 48px));
  margin-inline: auto;
}

.section {
  padding: 88px 0;
  position: relative;
}

.section-dark {
  color: #fff;
  background: radial-gradient(circle at 50% 0%, rgba(22, 119, 255, 0.36), transparent 44%), var(--deep);
}

.site-header {
  position: fixed;
  z-index: 50;
  top: 0;
  right: 0;
  left: 0;
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 0 clamp(20px, 5vw, 72px);
  border-bottom: 1px solid rgba(55, 190, 255, 0.22);
  background: rgba(0, 0, 0, 0.94);
  backdrop-filter: blur(16px);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.34), 0 0 24px rgba(0, 136, 255, 0.12);
}

main {
  padding-top: var(--header-height);
}

.brand,
.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: #0a3472;
}

.brand-logo {
  width: clamp(52px, 5.2vw, 64px);
  height: auto;
  max-height: 64px;
  object-fit: contain;
}

.brand-wordmark {
  width: auto;
  height: 54px;
  object-fit: contain;
}

.footer-logo {
  width: min(220px, 100%);
  height: auto;
  object-fit: contain;
}

.brand-title {
  display: block;
  max-width: 300px;
  font-size: clamp(18px, 1.9vw, 28px);
  line-height: 1.08;
  font-weight: 900;
}

.brand strong,
.footer-brand strong {
  display: block;
  font-size: 18px;
  line-height: 1.1;
  font-weight: 900;
}

.brand .brand-title {
  max-width: 300px;
  font-size: clamp(18px, 1.9vw, 28px);
  line-height: 1.08;
}

.brand strong {
  max-width: 250px;
}

.brand small,
.footer-brand small {
  display: block;
  margin-top: 4px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.brand-gloss {
  display: inline;
  color: #f28a2b;
  background:
    linear-gradient(180deg, #ffe39c 0%, #ffb04c 18%, #ff8a2e 42%, #e16419 64%, #9f360d 82%, #ffd16a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  -webkit-text-stroke: 0.45px rgba(143, 54, 7, 0.58);
  filter: drop-shadow(0 2px 0 rgba(98, 35, 5, 0.42)) drop-shadow(0 0 10px rgba(255, 123, 28, 0.46));
  text-shadow: 0 1px 0 rgba(255, 238, 190, 0.34), 0 3px 4px rgba(128, 49, 8, 0.24);
}

.brand-flat {
  display: inline;
  color: #f28a2b;
  font-weight: 900;
}

.section-heading h2 .brand-gloss,
.section-heading h2 .brand-flat,
.about-hero-copy h2 .brand-gloss,
.about-hero-copy h2 .brand-flat {
  font-size: inherit;
  line-height: inherit;
}

.center-copy .brand-flat,
.section-heading h2 .brand-flat,
.about-hero-copy h2 .brand-flat {
  color: #f28a2b;
}

.center-copy .brand-flat {
  margin-right: 0.18em;
  letter-spacing: 0.02em;
}

.global-nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 30px);
  font-size: 14px;
  font-weight: 700;
}

.global-nav a:not(.nav-cta) {
  color: #eaf6ff;
  text-shadow: 0 0 10px rgba(56, 223, 255, 0.2);
}

.nav-cta,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 24px;
  border: 0;
  border-radius: 8px;
  font-weight: 800;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.nav-cta,
.button-primary {
  color: #fff;
  background: linear-gradient(135deg, #0068ff, #48b8ff);
  box-shadow: 0 14px 30px rgba(0, 111, 255, 0.32);
}

.button:hover,
.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 42px rgba(0, 142, 255, 0.36);
}

.nav-cta img,
.button img {
  width: 18px;
  height: 18px;
}

.menu-button {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid rgba(80, 211, 255, 0.42);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
}

.menu-button span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 5px auto;
  background: #8be9ff;
}

.hero {
  min-height: 706px;
  overflow: hidden;
  padding: 96px 0 0;
}

.hero-bg,
.contact-bg {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(90deg, rgba(2, 9, 28, 0.94), rgba(2, 14, 43, 0.7)), url("../assets/images/hero/hero_particle_bg.png");
  background-size: cover;
  background-position: center;
  opacity: 0.98;
}

.hero::after {
  content: "";
  position: absolute;
  inset: auto -8% 0 -8%;
  height: 110px;
  background: radial-gradient(ellipse at 74% 100%, rgba(68, 200, 255, 0.95), transparent 48%);
  filter: blur(10px);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(420px, 1fr);
  align-items: center;
  gap: 56px;
}

.eyebrow,
.section-heading p {
  margin: 0 0 14px;
  color: var(--cyan);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.42em;
}

.hero h1 {
  margin: 0;
  color: #eaf4ff;
  font-size: clamp(44px, 5vw, 76px);
  line-height: 1.18;
  font-weight: 900;
  text-shadow: 0 0 36px rgba(92, 174, 255, 0.3);
  word-break: keep-all;
}

.nowrap {
  white-space: nowrap;
}

.hero-lead {
  max-width: 560px;
  margin: 28px 0 34px;
  color: #f1f7ff;
  font-size: 20px;
  line-height: 1.9;
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.button-ghost {
  color: #fff;
  border: 1px solid rgba(211, 234, 255, 0.7);
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
}

.button-white {
  min-width: 300px;
  color: #0b4d9c;
  background: #fff;
  box-shadow: 0 16px 42px rgba(0, 45, 130, 0.22);
}

.hero-media {
  position: relative;
  min-height: 500px;
  display: grid;
  place-items: center;
}

.hero-video-card {
  position: relative;
  width: min(100%, 360px);
  aspect-ratio: 9 / 16;
  max-height: min(640px, calc(100vh - var(--header-height) - 96px));
  overflow: hidden;
  padding: 0;
  border: 1px solid rgba(110, 204, 255, 0.48);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 26px 80px rgba(0, 8, 26, 0.42), 0 0 34px rgba(29, 168, 255, 0.24);
  cursor: pointer;
  animation: float 5.8s ease-in-out infinite;
}

.hero-video-card video,
.hero-video-card img {
  width: 100%;
  height: 100%;
  aspect-ratio: 9 / 16;
  object-fit: contain;
  background: #000;
}

.hero-video-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(2, 12, 34, 0.06), rgba(2, 12, 34, 0.24));
  pointer-events: none;
}

.hero-video-card .play-mark,
.hero-video-card b {
  z-index: 2;
}

.hero-video-card b {
  position: absolute;
  left: 50%;
  bottom: 18px;
  padding: 6px 14px;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.58);
  font-size: 12px;
  letter-spacing: 0.08em;
  transform: translateX(-50%);
  white-space: nowrap;
}

.thumb-card {
  position: absolute;
  overflow: hidden;
  border: 1px solid rgba(110, 204, 255, 0.42);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 26px 80px rgba(0, 8, 26, 0.42), 0 0 34px rgba(29, 168, 255, 0.24);
  animation: float 5.8s ease-in-out infinite;
}

.thumb-card img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: rgba(2, 12, 34, 0.78);
}

.thumb-1 {
  width: 25%;
  min-width: 210px;
  aspect-ratio: 1.24 / 1;
  left: 0;
  top: 34%;
  opacity: 0.76;
}

.thumb-2 {
  width: 38%;
  min-width: 300px;
  aspect-ratio: 1.72 / 1;
  right: 5%;
  top: 4%;
  animation-delay: 0.7s;
}

.thumb-3 {
  width: 44%;
  min-width: 330px;
  aspect-ratio: 1.36 / 1;
  left: 13%;
  bottom: 6%;
  z-index: 2;
  animation-delay: 1.2s;
}

.thumb-4 {
  width: 32%;
  min-width: 260px;
  aspect-ratio: 1.18 / 1;
  right: 0;
  top: 47%;
  animation-delay: 0.3s;
}

.play-mark {
  position: absolute;
  inset: 50% auto auto 50%;
  width: 52px;
  height: 52px;
  border: 1px solid rgba(255, 255, 255, 0.75);
  border-radius: 50%;
  background: rgba(0, 30, 70, 0.5);
  backdrop-filter: blur(8px);
  transform: translate(-50%, -50%);
}

.play-mark::after {
  content: "";
  position: absolute;
  left: 21px;
  top: 15px;
  width: 0;
  height: 0;
  border-top: 11px solid transparent;
  border-bottom: 11px solid transparent;
  border-left: 16px solid #fff;
}

.hero-feature-bar {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  margin-top: 72px;
  padding: 22px max(24px, calc((100vw - 1180px) / 2));
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(2, 8, 22, 0.82);
}

.hero-feature-bar span {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  min-height: 34px;
  border-right: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 18px;
  font-weight: 800;
}

.hero-feature-bar span:last-child {
  border-right: 0;
}

.hero-feature-bar img {
  width: 30px;
  height: 30px;
}

.section-heading {
  max-width: 860px;
  margin: 0 auto 42px;
  text-align: left;
}

.section-heading h2,
.about-hero-copy h2,
.contact-grid h2 {
  margin: 0;
  color: #092556;
  /* 下限を40pxに（タブレット幅で見出しが小さくなりすぎ、カード連番52pxに負けるのを防ぐ） */
  font-size: clamp(40px, 4vw, 48px);
  line-height: 1.28;
  font-weight: 900;
}

.about-hero-copy h2 {
  color: #fff;
}

.section-heading > span {
  display: block;
  margin-top: 18px;
  color: #49617e;
  font-size: 18px;
  line-height: 1.8;
  text-align: left;
}

.feature-heading-title,
.feature-heading-suffix {
  display: block;
}

.section-heading h2 .feature-heading-title,
.section-heading h2 .feature-heading-suffix {
  margin-top: 0;
  color: inherit;
  font-size: inherit;
  line-height: inherit;
}

.feature-heading-title .brand-flat {
  display: inline-block;
  margin: 0;
}

.feature-heading-suffix {
  margin-top: 0;
}

.section-heading.dark h2,
.section-heading.dark > span {
  color: #eef7ff;
}

.worries-section,
.features-section,
.flow-section,
.form-section {
  background: linear-gradient(180deg, #f6fbff, #fff);
}

.worry-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 18px;
}

.mini-card,
.feature-card,
.flow-item,
.faq-item,
.form-shell {
  border: 1px solid rgba(38, 118, 214, 0.12);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 18px 46px rgba(19, 67, 126, 0.1);
}

.mini-card {
  position: relative;
  overflow: hidden;
  min-height: 172px;
  display: grid;
  place-items: center;
  gap: 18px;
  padding: 30px 20px;
  text-align: left;
  background: linear-gradient(180deg, #fff 0%, #f4f9ff 100%);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* カード上辺のアクセントバー */
.mini-card::before,
.feature-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #0068ff, #38dfff);
}

.mini-card:hover,
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 56px rgba(19, 67, 126, 0.18);
}

.mini-card h3,
.mini-card .card-head {
  justify-self: stretch;
}

/* 連番テキスト（左）＋アイコン（右）を横並びにする見出し行 */
.card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.card-icon {
  width: 104px;
  height: 104px;
  object-fit: contain;
  flex-shrink: 0;
}

.mini-card h3 {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
}

/* カード内の連番（01〜）: script-label系のイタリック書体＋ブルーグラデーション・左揃え */
.card-number {
  display: block;
  margin: 0;
  color: rgba(13, 126, 255, 0.55);
  background: linear-gradient(135deg, rgba(13, 126, 255, 0.75), rgba(56, 223, 255, 0.65));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-size: 52px;
  line-height: 1;
  font-style: italic;
  font-weight: 700;
  text-align: left;
  /* イタリック字形の右はみ出しが background-clip: text の塗り範囲外で欠けるのを防ぐ */
  padding-right: 0.2em;
}

/* 特徴カードは見出し行の下に説明文が続くため間隔を確保 */
.feature-card .card-head {
  margin-bottom: 14px;
}

/* 「こんなお悩みはありませんか？」の見出し（h2）と同サイズに揃える */
.center-copy {
  margin: 34px 0 0;
  text-align: left;
  font-size: clamp(40px, 4vw, 48px);
  line-height: 1.28;
  font-weight: 900;
}

.center-copy span {
  color: var(--blue);
}

.about-section {
  overflow: hidden;
  background: linear-gradient(90deg, #fff 0%, #fff 42%, rgba(230, 246, 255, 0.95) 100%);
}

/* 横長写真（about_pc01）を背景にテキストを重ねるレイアウト */
.about-hero {
  position: relative;
  /* パネルが画像下にはみ出せるよう visible に */
  overflow: visible;
  /* 角丸なし（画像・パネルともに直角） */
  border-radius: 0;
  /* 画像と同じ縦横比に固定し、cover でも上下が見切れないようにする */
  aspect-ratio: 1672 / 941;
  /* bottom: -40% のはみ出し分のスペースを確保（次セクションとの重なり防止）。
     はみ出し量 ≒ 40%×高さ ≒ 22.5%×幅 なので、bottom を変える場合はこの % も調整する */
  margin-bottom: 25%;
  box-shadow: 0 28px 70px rgba(0, 60, 130, 0.16);
}

.about-hero > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

/* 写真全体は活かしつつ、左側だけ軽く沈める控えめな暗幕（画像内に限定） */
.about-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(2, 9, 28, 0.5) 0%, rgba(2, 9, 28, 0.18) 55%, rgba(2, 9, 28, 0) 100%);
}

/* テキストの裏だけをぼかすすりガラスパネル（ぼかし＋クリッピングマスク相当）。
   画像左端に揃えたパネルを画像下端付近に置き、下方向へ大きくはみ出す（参考デザイン4枚目）。
   はみ出し分は .about-hero の margin-bottom で確保 */
.about-hero-copy {
  position: absolute;
  z-index: 1;
  left: 0;
  bottom: -40%;
  width: 95%;
  padding: clamp(22px, 3vw, 40px);
  border-radius: 0;
  background: rgba(2, 9, 28, 0.46);
  backdrop-filter: blur(14px) saturate(125%);
  -webkit-backdrop-filter: blur(14px) saturate(125%);
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.4);
}

/* スマホ・タブレット縦: 画像全体（見切れなし）の下にパネルを少し重ねて積み上げる */
@media (max-width: 860px) {
  .about-hero {
    aspect-ratio: auto;
    /* スマホは積み上げレイアウトのため下はみ出し用スペースは不要 */
    margin-bottom: 0;
  }

  .about-hero > img {
    position: static;
    width: 100%;
    height: auto;
  }

  .about-hero::before {
    display: none;
  }

  /* 画像左端に揃え、PCと同じく常に95%幅（画像と同サイズにならないように） */
  .about-hero-copy {
    position: static;
    width: 95%;
    margin: -36px 0 0;
  }
}

.about-hero-copy .script-label {
  color: rgba(110, 210, 255, 0.4);
  /* "About" と見出しの行間が詰まっていたので1文字分ほど空ける（base の -6px を上書き） */
  margin-bottom: 0.5em;
}

.about-hero-copy p:not(.script-label) {
  color: #eef5fe;
  font-size: 18px;
  line-height: 2;
  font-weight: 700;
}

/* 写真の明るい部分に文字が重なっても読めるように影を敷く */
.about-hero-copy h2,
.about-hero-copy p:not(.script-label) {
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.85), 0 4px 18px rgba(0, 0, 0, 0.6);
}

.script-label {
  margin: 0 0 -6px;
  color: rgba(13, 126, 255, 0.18);
  font-size: 52px;
  line-height: 1;
  font-style: italic;
  font-weight: 700;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.feature-card {
  position: relative;
  overflow: hidden;
  min-height: 310px;
  padding: 44px 28px 36px;
  text-align: left;
  background: linear-gradient(180deg, #fff 0%, #f4f9ff 100%);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.feature-card h3,
.flow-item h3,
.work-card h3 {
  margin: 0 0 12px;
  color: #092556;
  font-size: 20px;
  font-weight: 900;
}

.feature-card p,
.flow-item p,
.work-card p {
  margin: 0;
  color: #526981;
  line-height: 1.75;
}

.works-section {
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(circle at 16% 20%, rgba(56, 223, 255, 0.22), transparent 24%),
    radial-gradient(circle at 84% 78%, rgba(0, 120, 255, 0.28), transparent 28%),
    linear-gradient(180deg, #061634 0%, #041027 100%);
}

.works-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("../assets/images/hero/hero_particle_bg.png");
  background-position: center;
  background-size: cover;
  opacity: 0.38;
  pointer-events: none;
}

.works-section .container {
  position: relative;
  z-index: 1;
}

.works-section .section-heading h2 {
  color: #f2f8ff;
  text-shadow: 0 0 28px rgba(56, 223, 255, 0.22);
}

.category-tabs {
  display: flex;
  gap: 12px;
  max-width: 100%;
  overflow-x: auto;
  padding: 0 0 8px;
  scrollbar-width: none;
}

.category-tabs button {
  min-width: max-content;
  min-height: 38px;
  padding: 0 24px;
  border: 1px solid rgba(129, 218, 255, 0.16);
  border-radius: 999px;
  color: #eaf6ff;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  font-weight: 800;
  box-shadow: 0 8px 24px rgba(0, 14, 40, 0.18);
  cursor: pointer;
}

.category-tabs .is-active {
  color: #fff;
  background: linear-gradient(135deg, #0068ff, #44b9ff);
}

.works-slider {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(390px, 480px);
  gap: 34px;
  max-width: 100%;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  padding: 32px 0 60px;
  scrollbar-color: var(--orange) rgba(255, 255, 255, 0.16);
  scrollbar-width: thin;
}

.scroll-shell {
  position: relative;
}

.scroll-hint {
  position: absolute;
  bottom: 14px;
  left: 50%;
  z-index: 4;
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 14px;
  border: 1px solid rgba(242, 138, 43, 0.82);
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, rgba(242, 138, 43, 0.96), rgba(213, 83, 18, 0.96));
  box-shadow: 0 12px 30px rgba(176, 74, 12, 0.32);
  font-size: 12px;
  font-weight: 900;
  pointer-events: none;
  transform: translateX(-50%);
  transition: opacity 0.2s ease, visibility 0.2s ease;
  white-space: nowrap;
}

.scroll-shell-dark .scroll-hint {
  box-shadow: 0 0 28px rgba(242, 138, 43, 0.44);
}

.scroll-shell.is-at-end .scroll-hint,
.scroll-shell.is-not-scrollable .scroll-hint {
  opacity: 0;
  visibility: hidden;
}

/* スライダー左右の送りボタン（実績動画・料金プラン） */
.slider-arrow {
  position: absolute;
  top: 50%;
  z-index: 5;
  width: 56px;
  height: 56px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 10px 30px rgba(0, 10, 30, 0.35);
  cursor: pointer;
  transform: translateY(-50%);
  transition: opacity 0.2s ease, visibility 0.2s ease;
}

.slider-arrow::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 14px;
  height: 14px;
  border-top: 2px solid #2a3a50;
  border-right: 2px solid #2a3a50;
}

.slider-arrow.prev {
  left: 6px;
}

.slider-arrow.next {
  right: 6px;
}

.slider-arrow.prev::before {
  transform: translate(-30%, -50%) rotate(-135deg);
}

.slider-arrow.next::before {
  transform: translate(-70%, -50%) rotate(45deg);
}

.scroll-shell.is-not-scrollable .slider-arrow,
.scroll-shell.is-at-start .slider-arrow.prev,
.scroll-shell.is-at-end .slider-arrow.next {
  opacity: 0;
  visibility: hidden;
}

.works-slider::-webkit-scrollbar,
.pricing-grid::-webkit-scrollbar,
.flow-comparison::-webkit-scrollbar {
  height: 10px;
}

.works-slider::-webkit-scrollbar-track,
.pricing-grid::-webkit-scrollbar-track,
.flow-comparison::-webkit-scrollbar-track {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
}

.works-slider::-webkit-scrollbar-thumb,
.pricing-grid::-webkit-scrollbar-thumb,
.flow-comparison::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: linear-gradient(90deg, #ffb04c, var(--orange), #d55312);
}

.work-card {
  min-width: 390px;
  scroll-snap-align: start;
  animation: workReveal 0.5s ease both;
}

.work-card[hidden] {
  display: none;
}

.work-card.is-revealing {
  animation: workReveal 0.5s ease both;
}

.work-card button {
  position: relative;
  width: 100%;
  overflow: hidden;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: #092556;
  cursor: pointer;
  box-shadow: 0 18px 44px rgba(3, 42, 97, 0.16);
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.work-card img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  transition: transform 0.35s ease, filter 0.35s ease;
}

.work-card b {
  position: absolute;
  left: 50%;
  bottom: 12px;
  padding: 5px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.62);
  font-size: 11px;
  transform: translateX(-50%);
}

.work-card h3 {
  margin-top: 14px;
  font-size: 18px;
}

.work-card h3 {
  color: #f5fbff;
  font-size: 24px;
  text-shadow: 0 0 20px rgba(56, 223, 255, 0.14);
}

.work-card p {
  color: #cfe2f7;
  font-size: 17px;
}

.work-card button:disabled {
  cursor: default;
}

.work-card button:disabled .play-mark {
  display: none;
}

/* COMING SOON（disabled）中も料金プランのサンプル画像と同様にホバー演出は残す */
.work-card button:hover {
  transform: translateY(-8px);
  box-shadow: 0 26px 62px rgba(3, 42, 97, 0.24), 0 0 28px rgba(34, 168, 255, 0.22);
}

.work-card button:hover img {
  transform: scale(1.07);
  filter: brightness(1.08) saturate(1.08);
}

.work-card button:hover .play-mark {
  border-color: rgba(255, 255, 255, 0.95);
  background: rgba(0, 108, 255, 0.56);
  box-shadow: 0 0 24px rgba(72, 190, 255, 0.55);
}

.flow-list {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.flow-item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 300px;
  padding: 28px 16px;
  text-align: center;
}

.flow-item:not(:last-child)::after {
  content: "›";
  position: absolute;
  top: 50%;
  right: -14px;
  color: var(--blue);
  font-size: 36px;
  font-weight: 700;
  transform: translateY(-50%);
}

.flow-number {
  color: #075bc2;
  font-size: 24px;
  font-weight: 900;
}

.flow-item img {
  width: 96px;
  height: 96px;
  margin: 18px 0;
}

.flow-item h3 {
  font-size: 16px;
}

.flow-item p {
  font-size: 13px;
}

/* スマホ限定: 制作ステップ見出し上の「従来の動画制作の悩み」ブロック */
.flow-worries {
  display: none;
}

.flow-comparison {
  overflow-x: visible;
  padding: 0 0 6px;
}

.flow-table {
  display: grid;
  grid-template-columns: 170px minmax(0, 0.72fr) minmax(0, 1.28fr);
  overflow: hidden;
  border: 3px solid #2b7bac;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 22px 56px rgba(11, 75, 132, 0.14);
  counter-reset: flow-step;
}

.flow-table-corner {
  background: #2d6da7;
}

.flow-table-head {
  padding: 22px 18px;
  color: #fff;
  font-size: 24px;
  font-weight: 900;
  text-align: left;
}

.flow-table-head.normal {
  background: #a9a9a9;
}

.flow-table-head.ai {
  background: linear-gradient(135deg, #0068ff, #38b6ff);
  box-shadow: inset 0 0 26px rgba(255, 255, 255, 0.18);
  text-shadow: 0 0 16px rgba(255, 255, 255, 0.45);
}

.flow-row {
  display: contents;
}

.flow-phase {
  position: relative;
  display: grid;
  justify-items: start;
  align-content: center;
  gap: 8px;
  min-height: 142px;
  padding: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.34);
  background: linear-gradient(180deg, #2d6da7, #3aa4a2);
  color: #fff;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.35;
  text-align: left;
}

/* 工程番号はバッジではなくプレーンな連番テキスト（01〜05） */
.flow-phase::before {
  counter-increment: flow-step;
  content: counter(flow-step, decimal-leading-zero);
  color: rgba(255, 255, 255, 0.55);
  font-size: 26px;
  font-style: italic;
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1;
}

.flow-phase:not(.flow-phase-total)::after {
  content: "";
  position: absolute;
  bottom: -9px;
  left: 50%;
  z-index: 1;
  width: 0;
  height: 0;
  border-left: 9px solid transparent;
  border-right: 9px solid transparent;
  border-top: 10px solid #fff;
  transform: translateX(-50%);
  filter: drop-shadow(0 2px 2px rgba(5, 35, 65, 0.3));
}

.flow-phase-total {
  min-height: 94px;
  border-bottom: 0;
}

.flow-phase-total::before {
  counter-increment: none;
  content: "GOAL";
  color: rgba(255, 211, 145, 0.9);
}

/* 日数ボックスが行の高さいっぱいに伸びるよう、セルの上下paddingは持たせない */
.flow-cell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 108px;
  gap: 18px;
  align-items: center;
  min-height: 142px;
  padding: 0 0 0 28px;
  border-bottom: 1px solid #d7dce2;
  color: #18283c;
}

/* 従来列はトーンを落とし、AI活用列との主従を明確にする */
.flow-cell:not(.flow-cell-ai) {
  background: #f7f8fa;
  color: #5a6b7c;
}

.flow-cell-ai {
  border-left: 3px solid #2f9fd8;
  background: linear-gradient(180deg, rgba(0, 116, 255, 0.07), rgba(56, 182, 255, 0.06));
}

.flow-cell ul {
  display: grid;
  gap: 8px;
  margin: 22px 0;
  padding: 0;
  list-style: none;
  font-size: 16px;
  line-height: 1.55;
  font-weight: 800;
}

.flow-cell li::before {
  content: "•";
  margin-right: 6px;
}

.flow-cell strong {
  align-self: stretch;
  display: grid;
  place-items: center;
  padding: 14px;
  background: #ececec;
  color: #101820;
  font-size: 20px;
  font-weight: 900;
  text-align: center;
}

.flow-cell-ai strong {
  background: linear-gradient(135deg, #0068ff, #3aa0ff);
  color: #fff;
  box-shadow: 0 6px 16px rgba(0, 104, 255, 0.28);
}

.flow-total {
  display: grid;
  justify-items: start;
  align-content: center;
  min-height: 94px;
  padding: 18px;
  border-top: 1px solid #d7dce2;
  font-size: 26px;
  line-height: 1.35;
  font-weight: 900;
  text-align: left;
}

.normal-total {
  color: #5a6b7c;
  background: #f7f8fa;
}

.ai-total {
  color: #b23535;
  border-left: 3px solid #2f9fd8;
  background: linear-gradient(180deg, rgba(0, 116, 255, 0.07), rgba(56, 182, 255, 0.06));
}

.flow-note {
  margin: 22px 0 0;
  color: #526981;
  font-size: 14px;
  text-align: left;
}

.pricing-section {
  overflow: hidden;
  background-image: radial-gradient(circle at 20% 20%, rgba(43, 172, 255, 0.22), transparent 24%),
    radial-gradient(circle at 80% 38%, rgba(121, 82, 255, 0.22), transparent 22%),
    url("../assets/images/hero/hero_particle_bg.png");
  background-size: cover;
  background-position: center;
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: stretch;
  gap: 28px;
}

.pricing-card {
  position: relative;
  padding: 46px 40px 38px;
  border: 1px solid rgba(80, 211, 255, 0.7);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(6, 28, 72, 0.9), rgba(2, 8, 28, 0.78));
  box-shadow: inset 0 0 34px rgba(22, 158, 255, 0.16), 0 0 38px rgba(22, 158, 255, 0.18);
}

.pricing-card.recommended {
  border-color: rgba(255, 176, 76, 0.92);
  padding-top: 78px;
  transform: translateY(-18px);
  background: linear-gradient(180deg, rgba(86, 45, 8, 0.6), rgba(6, 28, 72, 0.9) 40%, rgba(2, 8, 28, 0.78));
  box-shadow: inset 0 0 44px rgba(255, 154, 54, 0.16), 0 0 58px rgba(242, 138, 43, 0.42);
}

/* カード上辺から垂れ下がる、下端をV字に切り欠いたリボン形状 */
.badge {
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  padding: 14px 18px 26px;
  color: #fff;
  background: linear-gradient(180deg, rgba(242, 138, 43, 0.98), rgba(213, 83, 18, 0.98));
  clip-path: polygon(0 0, 100% 0, 100% 100%, 50% calc(100% - 12px), 0 100%);
  font-weight: 800;
  white-space: nowrap;
}

.pricing-card.recommended h3 {
  color: #ffc46a;
}

.pricing-card.recommended .price {
  color: #ffb04c;
  border-bottom-color: rgba(255, 186, 106, 0.45);
}

.pricing-card.recommended li::before {
  color: #ffb04c;
}

.pricing-card h3 {
  margin: 0 0 12px;
  color: #eef7ff;
  font-size: 30px;
  font-weight: 900;
  text-align: left;
}

.pricing-card p {
  min-height: 58px;
  margin: 0;
  text-align: left;
  color: #dcecff;
  line-height: 1.75;
}

.pricing-sample-video {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  margin: 24px 0 26px;
  padding: 0;
  border: 1px solid rgba(100, 223, 255, 0.46);
  border-radius: 8px;
  background: rgba(0, 26, 66, 0.72);
  box-shadow: inset 0 0 24px rgba(44, 180, 255, 0.12), 0 16px 32px rgba(0, 8, 28, 0.24);
  cursor: pointer;
}

.pricing-sample-video:disabled {
  cursor: default;
}

.pricing-sample-video img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  opacity: 0.72;
  transition: transform 0.28s ease, opacity 0.28s ease;
}

.pricing-sample-video::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(3, 16, 44, 0.1), rgba(3, 16, 44, 0.42));
  pointer-events: none;
}

.pricing-sample-video .play-mark {
  z-index: 2;
  width: 46px;
  height: 46px;
}

.pricing-sample-video .play-mark::after {
  left: 19px;
  top: 14px;
  border-top-width: 9px;
  border-bottom-width: 9px;
  border-left-width: 14px;
}

.pricing-sample-video b {
  position: absolute;
  left: 50%;
  bottom: 10px;
  z-index: 2;
  padding: 5px 12px;
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.58);
  font-size: 11px;
  letter-spacing: 0.08em;
  transform: translateX(-50%);
  white-space: nowrap;
}

.pricing-sample-video:hover img {
  opacity: 0.92;
  transform: scale(1.05);
}

.price {
  /* 動画サムネイル削除版で説明文と密着しないための余白。動画あり版ではボタンのmargin-bottom(26px)と相殺され見た目は変わらない */
  margin-top: 24px;
  padding-bottom: 22px;
  border-bottom: 1px solid rgba(101, 197, 255, 0.4);
  color: #7cc9ff;
  font-size: clamp(34px, 3.8vw, 46px);
  font-weight: 900;
  text-align: left;
  white-space: nowrap;
}

.price small {
  display: block;
  margin-top: 8px;
  color: #e3efff;
  font-size: 16px;
}

.pricing-card ul {
  display: grid;
  gap: 12px;
  margin: 24px 0 0;
  padding: 0;
  list-style: none;
}

.pricing-card li {
  color: #f2f8ff;
  line-height: 1.55;
}

.pricing-card li::before {
  content: "•";
  margin-right: 10px;
  color: var(--cyan);
}

.button-line {
  width: 100%;
  color: var(--cyan);
  border: 1px solid rgba(128, 220, 255, 0.78);
  background: rgba(0, 64, 150, 0.26);
  box-shadow: inset 0 0 22px rgba(52, 195, 255, 0.16);
}

.pricing-banner {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  margin-top: 34px;
  border: 1px solid rgba(79, 202, 255, 0.48);
  border-radius: 8px;
  background: rgba(0, 28, 72, 0.58);
  box-shadow: inset 0 0 24px rgba(39, 174, 255, 0.14);
}

.pricing-banner div {
  display: flex;
  gap: 18px;
  align-items: center;
  min-height: 118px;
  padding: 24px;
  border-right: 1px solid rgba(99, 180, 255, 0.3);
}

.pricing-banner div:last-child {
  border-right: 0;
}

.pricing-banner img {
  width: 48px;
  height: 48px;
}

.pricing-banner strong,
.pricing-banner small {
  display: block;
}

.pricing-banner strong {
  color: var(--cyan);
  font-size: 18px;
}

.pricing-banner small {
  margin-top: 8px;
  color: #deedff;
}

.pricing-note {
  margin: 30px 0 0;
  color: #dbe8fb;
  text-align: left;
}

.faq-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px 24px;
}

.faq-item {
  overflow: hidden;
}

.faq-item button {
  width: 100%;
  min-height: 82px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 20px;
  border: 0;
  color: #0d2c5c;
  background: #fff;
  cursor: pointer;
  text-align: left;
}

.faq-item button span {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
}

.faq-item img {
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
}

.faq-item b {
  color: #0d4c9d;
  font-size: 24px;
}

.faq-item p {
  margin: 0;
  padding: 0 22px 24px 86px;
  color: #506a86;
  line-height: 1.8;
}

.contact-cta {
  position: relative;
  overflow: hidden;
  min-height: 340px;
  color: #fff;
}

.contact-bg {
  background-color: #0b55b8;
  background-image: linear-gradient(90deg, rgba(0, 77, 174, 0.96), rgba(0, 77, 174, 0.8), rgba(0, 77, 174, 0.24)),
    url("../assets/images/contact/contact_bg.png");
  background-position: center, right center;
  background-repeat: no-repeat;
  background-size: cover, auto 100%;
}

.contact-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(11, 85, 184, 0) 0%, rgba(11, 85, 184, 0.08) 43%, rgba(11, 85, 184, 0.72) 56%, rgba(11, 85, 184, 0.3) 68%, rgba(11, 85, 184, 0) 100%),
    radial-gradient(ellipse at 61% 50%, rgba(11, 85, 184, 0.66), transparent 29%);
  pointer-events: none;
}

.contact-grid {
  position: relative;
  z-index: 1;
  display: grid;
  align-items: center;
  min-height: 340px;
}

.contact-grid h2 {
  color: #fff;
}

.contact-grid p:not(.script-label) {
  max-width: 620px;
  margin: 18px 0 26px;
  font-size: 18px;
  line-height: 1.9;
  font-weight: 700;
}

.contact-points {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 24px;
  margin-top: 24px;
  font-weight: 800;
}

.contact-points span {
  display: flex;
  align-items: center;
  gap: 8px;
}

.contact-points img {
  width: 28px;
  height: 28px;
}

.form-shell {
  padding: clamp(26px, 5vw, 54px);
}

.success-message {
  margin: 0 0 24px;
  padding: 16px 20px;
  border-radius: 8px;
  color: #075233;
  background: #e8fff3;
  font-weight: 800;
}

form {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.field {
  display: grid;
  gap: 8px;
}

.field-wide {
  grid-column: 1 / -1;
}

/* 送信ボタン上のプライバシーポリシー同意文（フォームは明るい背景のため本文と同じ文字色） */
.form-privacy-note {
  margin: 0;
  color: var(--ink);
  font-size: 15px;
  line-height: 1.8;
}

.form-privacy-note a {
  color: #7cc9ff;
  text-decoration: underline;
}

.form-privacy-note a:hover {
  opacity: 0.85;
}

.field span {
  color: #12315d;
  font-weight: 800;
}

.field em {
  margin-left: 6px;
  color: #fff;
  background: #006eff;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 11px;
  font-style: normal;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(16, 77, 150, 0.18);
  border-radius: 8px;
  background: #f8fbff;
  color: #102548;
  outline: none;
}

input,
select {
  height: 54px;
  padding: 0 16px;
}

textarea {
  resize: vertical;
  padding: 16px;
  line-height: 1.7;
}

input:focus,
select:focus,
textarea:focus {
  border-color: #1687ff;
  box-shadow: 0 0 0 4px rgba(22, 135, 255, 0.12);
}

.error {
  color: #d92626;
  font-weight: 700;
}

.form-submit {
  grid-column: 1 / -1;
  justify-self: center;
  min-width: 260px;
}

.footer {
  position: relative;
  padding: 48px 0 28px;
  background: #000;
  border-top: 1px solid rgba(55, 190, 255, 0.22);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1.5fr 0.8fr 1fr;
  gap: 34px;
}

.footer h2 {
  margin: 0 0 12px;
  color: #eaf6ff;
  font-size: 15px;
}

.footer p,
.footer a {
  display: block;
  margin: 0 0 9px;
  color: #c7d9ec;
  font-size: 14px;
  line-height: 1.6;
}

.footer-button {
  width: max-content;
  margin-top: 14px !important;
  padding: 10px 16px;
  border-radius: 8px;
  color: #fff !important;
  background: linear-gradient(135deg, #0068ff, #48b8ff);
  font-weight: 800;
}

.copyright {
  margin: 36px 0 0;
  padding-top: 18px;
  /* 左寄せ時もコンテナ幅に揃うように左右の余白を確保する */
  padding-inline: max(24px, calc((100vw - 1180px) / 2));
  border-top: 1px solid rgba(55, 190, 255, 0.18);
  color: #9eb8d4;
  text-align: left;
}

.page-top {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 40;
  width: 76px;
  height: 76px;
  display: block;
  gap: 0;
  border: 1px solid rgba(90, 230, 255, 0.82);
  border-radius: 50%;
  color: #fff;
  background:
    radial-gradient(circle at 35% 25%, rgba(255, 255, 255, 0.32), transparent 22%),
    linear-gradient(135deg, #00d7ff 0%, #0078ff 48%, #7438ff 100%);
  font-size: 20px;
  line-height: 1;
  font-weight: 900;
  box-shadow: 0 0 0 6px rgba(43, 194, 255, 0.12), 0 0 34px rgba(56, 223, 255, 0.56), 0 18px 42px rgba(4, 20, 70, 0.32);
  text-shadow: 0 0 12px rgba(255, 255, 255, 0.55);
  animation: cyberFloat 3.2s ease-in-out infinite;
}

.page-top span,
.page-top strong {
  display: block;
}

.page-top span {
  position: absolute;
  top: 18px;
  left: 50%;
  width: 24px;
  height: 15px;
  margin: 0;
  border: 0;
  font-size: 0;
  line-height: 0;
  transform: translateX(-50%);
}

.page-top span::before,
.page-top span::after {
  content: "";
  position: absolute;
  top: 6px;
  width: 15px;
  height: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.88);
}

.page-top span::before {
  left: 1px;
  transform: rotate(-45deg);
}

.page-top span::after {
  right: 1px;
  transform: rotate(45deg);
}

.page-top strong {
  position: absolute;
  top: 38px;
  left: 0;
  width: 100%;
  font-size: 19px;
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
}

.page-top:hover {
  animation-play-state: paused;
  transform: translateY(-6px);
  box-shadow: 0 0 0 8px rgba(43, 194, 255, 0.16), 0 0 46px rgba(56, 223, 255, 0.72), 0 20px 52px rgba(4, 20, 70, 0.38);
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: 24px;
}

.modal[hidden] {
  display: none;
}

.modal-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 8, 24, 0.78);
}

.modal-content {
  position: relative;
  z-index: 1;
  width: min(920px, 100%);
  aspect-ratio: 16 / 9;
  border-radius: 8px;
  background: #000;
  box-shadow: 0 30px 90px rgba(0, 0, 0, 0.48);
}

.modal-content:has(.modal-video:not([hidden])) {
  width: min(96vw, 640px, calc((100dvh - 72px) * 9 / 16));
  aspect-ratio: 9 / 16;
}

.modal-content iframe,
.modal-video {
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: 8px;
  background: #000;
}

.modal-content iframe[hidden],
.modal-video[hidden] {
  display: none;
}

.modal-close {
  position: absolute;
  top: -48px;
  right: 0;
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  cursor: pointer;
}

.reveal {
  animation: fadeUp 0.8s ease both;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-14px);
  }
}

@keyframes cyberFloat {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

@keyframes workReveal {
  from {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
    filter: blur(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
  }
}

@media (max-width: 1120px) {
  .global-nav {
    gap: 14px;
    font-size: 13px;
  }

  .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-media {
    min-height: 420px;
  }

  .worry-grid,
  .feature-grid,
  .pricing-banner,
  .footer-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* 2列以下では横に広がりすぎて余白が空くため、グリッド幅を固定して中央寄せ */
  .worry-grid,
  .feature-grid {
    max-width: 760px;
    margin-inline: auto;
  }

  /* 5列横並び（PC）では気にならないが、2列以下ではカード文字が小さく見えるため拡大 */
  .mini-card h3 {
    font-size: 18px;
  }

  .pricing-grid {
    grid-template-columns: none;
    grid-auto-flow: column;
    grid-auto-columns: minmax(320px, 42%);
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    padding: 18px 0 60px;
    scrollbar-color: var(--orange) rgba(255, 255, 255, 0.16);
    scrollbar-width: thin;
  }

  .pricing-card {
    scroll-snap-align: start;
    padding: 38px 28px 32px;
  }

  .pricing-card h3 {
    font-size: 30px;
  }

  .pricing-card p {
    font-size: 16px;
  }

  .flow-list {
    grid-template-columns: repeat(3, 1fr);
  }

  .flow-cell {
    grid-template-columns: minmax(0, 1fr) 96px;
    padding-left: 22px;
  }

  .pricing-card.recommended {
    transform: none;
  }
}

@media (max-width: 983px) {
  :root {
    --header-height: 70px;
  }

  .site-header {
    padding-inline: 18px;
  }

  .brand-wordmark {
    height: 46px;
  }

  .menu-button {
    display: block;
  }

  .global-nav {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    display: grid;
    gap: 0;
    padding: 12px 18px 22px;
    background: rgba(0, 0, 0, 0.98);
    box-shadow: 0 24px 44px rgba(0, 0, 0, 0.38);
    transform: translateY(-130%);
    transition: transform 0.24s ease;
  }

  .global-nav.is-open {
    transform: translateY(0);
  }

  .global-nav a {
    min-height: 48px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid rgba(80, 211, 255, 0.18);
  }

  .nav-cta {
    margin-top: 12px;
  }
}

@media (max-width: 860px) {

  .container {
    width: min(100% - 32px, 680px);
  }

  .section {
    padding: 68px 0;
  }

  .hero {
    min-height: auto;
    padding: 68px 0 0;
  }

  .hero h1 {
    font-size: clamp(36px, 11vw, 64px);
  }

  .hero-lead {
    font-size: 17px;
  }

  /* CTAボタン4箇所は横に広がりすぎないよう、グリッドと同じ520pxで固定して中央寄せ */
  .button {
    display: flex;
    width: 100%;
    max-width: 520px;
    margin-inline: auto;
  }

  .hero-media {
    display: block;
    min-height: auto;
    margin-top: 28px;
  }

  .hero-video-card {
    /* button は inline-block のため block 化しないと margin auto が効かず左寄せになる */
    display: block;
    width: min(100%, 360px);
    height: auto;
    max-height: none;
    margin-inline: auto;
  }

  .thumb-card {
    position: relative;
    inset: auto;
    width: 100%;
    min-width: 0;
    height: auto;
  }

  .thumb-1 {
    width: 100%;
    aspect-ratio: 1.24 / 1;
    grid-column: 1;
    grid-row: 1;
  }

  .thumb-2 {
    width: 100%;
    aspect-ratio: 1.72 / 1;
    grid-column: 2;
    grid-row: 1;
  }

  .thumb-3 {
    width: 100%;
    aspect-ratio: 1.36 / 1;
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .thumb-4 {
    width: 100%;
    aspect-ratio: 1.18 / 1;
    grid-column: 2;
    grid-row: 3;
  }

  .hero-feature-bar {
    grid-template-columns: repeat(2, 1fr);
    margin-top: 28px;
    padding: 16px;
  }

  .hero-feature-bar span {
    justify-content: flex-start;
    border-right: 0;
    font-size: 16px;
  }

  form,
  .faq-grid {
    grid-template-columns: 1fr;
  }

  .worry-grid {
    display: grid;
    grid-template-columns: 1fr;
    grid-auto-flow: row;
    grid-auto-columns: auto;
    /* 1列表示でも横に広がりすぎないよう幅を固定して中央寄せ */
    max-width: 520px;
    margin-inline: auto;
    overflow-x: visible;
    scroll-snap-type: none;
    padding-bottom: 0;
  }

  .mini-card {
    scroll-snap-align: start;
  }

  .feature-grid,
  .pricing-banner,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  /* 1列表示でも横に広がりすぎないよう、お悩みカードと同じ幅で固定して中央寄せ */
  .feature-grid {
    max-width: 520px;
    margin-inline: auto;
  }

  .pricing-grid {
    grid-template-columns: 1fr;
    grid-auto-flow: row;
    grid-auto-columns: auto;
    /* 縦1列時にカードが横に広がりすぎて右側が空くのを防ぐ（お悩み・特徴カードと同じ520px固定・中央寄せ） */
    max-width: 520px;
    margin-inline: auto;
    overflow-x: visible;
    scroll-snap-type: none;
    padding: 14px 0 0;
    gap: 22px;
  }

  .pricing-card {
    padding: 26px 18px 24px;
  }

  .pricing-card.recommended {
    padding-top: 56px;
  }

  .badge {
    top: -1px;
    padding: 10px 14px 20px;
    clip-path: polygon(0 0, 100% 0, 100% 100%, 50% calc(100% - 9px), 0 100%);
    font-size: 14px;
  }

  .pricing-card h3 {
    font-size: 30px;
    word-break: keep-all;
    overflow-wrap: anywhere;
  }

  .pricing-card p {
    min-height: auto;
    font-size: 16px;
    line-height: 1.55;
  }

  .pricing-sample-video {
    margin: 16px 0 18px;
  }

  /* 金額の右に余白が空くので「（税別）」を金額の右横に並べる */
  .price {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 10px;
    padding-bottom: 16px;
    font-size: 30px;
  }

  .price small {
    margin-top: 0;
    font-size: 16px;
  }

  .pricing-card ul {
    gap: 9px;
    margin-top: 18px;
  }

  .pricing-card li {
    font-size: 16px;
    line-height: 1.5;
  }

  .pricing-banner div {
    border-right: 0;
    border-bottom: 1px solid rgba(99, 180, 255, 0.3);
  }

  .pricing-banner div:last-child {
    border-bottom: 0;
  }

  /* 1列表示では右側が空くので、説明（small）をタイトル（strong）の右横に並べて1行に */
  .pricing-banner span {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 6px 14px;
  }

  /* タイトル幅を揃え、説明の開始位置（横軸）を全項目で一致させる */
  .pricing-banner strong {
    min-width: 170px;
  }

  .pricing-banner small {
    margin-top: 0;
    font-size: 16px;
  }

  .flow-list {
    grid-template-columns: 1fr;
  }

  .flow-item {
    min-height: auto;
    align-items: flex-start;
    text-align: left;
    padding: 28px 20px 28px 140px;
  }

  .flow-item img {
    position: absolute;
    left: 24px;
    top: 66px;
  }

  .flow-item:not(:last-child)::after {
    top: auto;
    right: auto;
    left: 68px;
    bottom: -30px;
    transform: rotate(90deg);
  }

  .flow-comparison {
    max-width: 100%;
    overflow-x: visible;
    padding-bottom: 0;
  }

  /* スマホ限定: 制作ステップ見出し上の「従来の動画制作の悩み」ブロック */
  .flow-worries {
    display: block;
    margin-bottom: 44px;
  }

  .flow-worries h3 {
    margin: 0 0 18px;
    color: #092556;
    font-size: 26px;
    line-height: 1.4;
    font-weight: 900;
  }

  .flow-worries ul {
    display: grid;
    gap: 10px;
    /* お悩みカードと同じ幅で固定して中央寄せ */
    max-width: 520px;
    margin: 0 auto;
    padding: 0;
    list-style: none;
  }

  .flow-worries li {
    display: flex;
    align-items: center;
    justify-content: center;
    /* 枠の高さを従来の約2倍に */
    min-height: 104px;
    padding: 14px 20px;
    border: 1px solid rgba(38, 118, 214, 0.24);
    border-radius: 8px;
    color: #fff;
    background: linear-gradient(135deg, #0a1f44, #061634);
    box-shadow: 0 10px 26px rgba(19, 67, 126, 0.16);
    font-size: 20px;
    font-weight: 800;
    text-align: center;
  }

  .flow-worries strong {
    color: #ffb04c;
  }

  /* スマホは「従来の動画制作」列を非表示にし、工程名（左）＋AI活用列（右）の2列で表示する */
  .flow-table {
    min-width: 0;
    grid-template-columns: 120px 1fr;
    border-width: 2px;
  }

  .flow-table-corner,
  .flow-table-head.normal,
  .flow-cell:not(.flow-cell-ai),
  .flow-total.normal-total {
    display: none;
  }

  .flow-table-head {
    padding: 22px 12px;
    font-size: 16px;
  }

  .flow-table-head.ai {
    grid-column: 1 / -1;
    font-size: 20px;
  }

  .flow-phase {
    grid-column: 1;
    /* 各行に高さの余裕を持たせる */
    min-height: 132px;
    padding: 24px 10px;
    font-size: 16px;
    gap: 6px;
  }

  .flow-phase::before {
    font-size: 18px;
  }

  /* モバイルは工程間（行の下）に矢印を表示する */
  .flow-phase:not(.flow-phase-total)::after {
    content: none;
  }

  .flow-row::after {
    content: "";
    grid-column: 1 / -1;
    justify-self: center;
    width: 0;
    height: 0;
    margin: 10px 0;
    border-left: 11px solid transparent;
    border-right: 11px solid transparent;
    border-top: 12px solid #2d6da7;
  }

  /* スマホは右側の日数ボックス（strong）を省き、説明文を16pxで読みやすく1列表示 */
  .flow-cell {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
    min-height: auto;
    padding: 0 12px;
  }

  .flow-cell-ai {
    grid-column: 2;
    border-left: 0;
  }

  .flow-cell ul {
    gap: 12px;
    margin: 24px 0;
    font-size: 16px;
    line-height: 1.5;
  }

  /* 右側の日数ボックスは省略（崩れ防止・視認性優先） */
  .flow-cell strong {
    display: none;
  }

  .flow-phase-total {
    min-height: auto;
  }

  .flow-total {
    min-height: 60px;
    padding: 12px 8px;
    font-size: 16px;
  }

  .ai-total {
    grid-column: 2;
    border-left: 0;
  }

  .contact-bg {
    background-image: linear-gradient(90deg, rgba(0, 51, 128, 0.97), rgba(0, 69, 158, 0.9), rgba(0, 69, 158, 0.52)), url("../assets/images/contact/contact_bg.png");
    background-position: center, right center;
    background-size: cover, auto 100%;
  }

  .contact-bg::after {
    background:
      linear-gradient(90deg, rgba(0, 69, 158, 0.16) 0%, rgba(0, 69, 158, 0.62) 50%, rgba(0, 69, 158, 0.12) 100%),
      radial-gradient(ellipse at 64% 50%, rgba(0, 69, 158, 0.58), transparent 34%);
  }

  .contact-grid {
    min-height: 430px;
  }

  .contact-grid h2 {
    /* 見出し下限40pxにより nowrap だと狭幅で横はみ出しするため折り返し可に */
    white-space: normal;
  }
}

@media (max-width: 480px) {
  .brand strong {
    font-size: 15px;
  }

  .brand small {
    font-size: 8px;
  }

  .brand-logo {
    width: 46px;
    max-height: 46px;
  }

  .brand-wordmark {
    height: 40px;
  }

  .hero-video-card {
    width: min(100%, 300px);
  }

  .brand .brand-title {
    max-width: 172px;
    font-size: 16px;
  }

  .hero-actions {
    gap: 12px;
  }

  .hero-feature-bar {
    grid-template-columns: 1fr;
  }

  .section-heading h2,
  .about-hero-copy h2,
  .contact-grid h2 {
    font-size: 28px;
  }

  .contact-grid h2 {
    font-size: clamp(21px, 5.8vw, 24px);
  }

  .section-heading span,
  .about-hero-copy p:not(.script-label),
  .contact-grid p:not(.script-label) {
    font-size: 16px;
  }

  .center-copy {
    font-size: 28px;
  }

  .price {
    font-size: 30px;
  }

  .pricing-card {
    padding: 26px 18px 24px;
  }

  .worry-grid {
    grid-template-columns: 1fr;
  }

  .works-slider {
    position: relative;
    grid-auto-columns: 92%;
    padding: 26px 0 54px;
  }

  .work-card {
    min-width: 0;
  }

  .scroll-hint {
    bottom: 12px;
    min-height: 30px;
    padding: 0 12px;
    font-size: 11px;
  }

  .slider-arrow {
    width: 44px;
    height: 44px;
  }

  .slider-arrow::before {
    width: 11px;
    height: 11px;
  }

  .flow-table-head {
    font-size: 16px;
  }

  .flow-phase {
    font-size: 16px;
  }

  .flow-cell ul {
    font-size: 16px;
  }

  .page-top {
    right: 14px;
    bottom: 14px;
    width: 66px;
    height: 66px;
  }

  .page-top span {
    top: 16px;
    width: 21px;
    height: 13px;
  }

  .page-top span::before,
  .page-top span::after {
    top: 5px;
    width: 13px;
    height: 3px;
  }

  .page-top strong {
    top: 33px;
    font-size: 16px;
  }

  .contact-points {
    display: grid;
  }
}

/* ===== オープニング動画（スプラッシュ） ===== */
.splash {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  opacity: 1;
  transition: opacity 0.5s ease, background-color 0.3s ease;
}

/* 1. ホワイトアウト: 背景を白へ、動画とボタンをフェードアウト */
.splash.is-whiteout {
  background-color: #fff;
}

.splash.is-whiteout .splash-video,
.splash.is-whiteout .splash-skip,
.splash.is-whiteout .splash-sound {
  opacity: 0;
  pointer-events: none;
}

/* 2. 白幕をフェードアウトして本編を表示 */
.splash.is-hiding {
  opacity: 0;
  pointer-events: none;
}

/* 再訪問/視差軽減時は最初から非表示（head のインラインスクリプトで付与） */
.no-splash .splash {
  display: none;
}

/* スプラッシュ表示中は背面のスクロールを止める */
html.splash-open,
html.splash-open body {
  overflow: hidden;
}

.splash-video {
  width: 100%;
  height: 100%;
  /* 縦動画を見切れなく中央表示（左右は黒背景） */
  object-fit: contain;
  background: #000;
  transition: opacity 0.3s ease;
}

/* スマホは縦画面に合わせて全画面で見せる */
@media (max-width: 860px) {
  .splash-video {
    object-fit: cover;
  }
}

.splash-skip,
.splash-sound {
  position: absolute;
  z-index: 1;
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.42);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.2s ease, opacity 0.3s ease;
}

.splash-skip:hover,
.splash-sound:hover {
  background: rgba(0, 0, 0, 0.65);
  transform: translateY(-1px);
}

.splash-sound:hover {
  transform: translateX(-50%) translateY(-1px);
}

.splash-skip {
  top: clamp(16px, 4vw, 28px);
  right: clamp(16px, 4vw, 28px);
  padding: 10px 18px;
  font-size: 14px;
}

.splash-sound {
  left: 50%;
  bottom: clamp(22px, 6vw, 40px);
  transform: translateX(-50%);
  padding: 12px 24px;
  font-size: 15px;
}
