/* ============================================================
   ひデッピークリエ シネマティック版 v1
   現場の一日: 朝(hero) → 日中 → 夕方 → 夜(contact)
   ============================================================ */
:root {
  --navy: #1f2933;
  --deep: #0e1720;
  --ink: #1d2731;
  --muted: #5f6b76;
  --line: #dfe4e8;
  --paper: #fbfaf7;
  --white: #fff;
  --orange: #d97706;
  --gold: #c89a4e;
  --shadow: 0 18px 42px rgba(31, 41, 51, .14);
  /* scene vars (JSがdata-sceneで切替) */
  --scene-bg: #fbfaf7;
  --scene-ink: #1d2731;
  --scene-muted: #5f6b76;
  --scene-line: #dfe4e8;
  --scene-card: #ffffff;
  --heading-font: "Hiragino Mincho ProN", "Yu Mincho", "Noto Serif JP", serif;
}

html { scroll-behavior: smooth; }
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--scene-bg);
  color: var(--scene-ink);
  font-family: "Hiragino Sans", "Yu Gothic", "Noto Sans JP", sans-serif;
  transition: background-color 1.2s ease, color 1.2s ease;
  overflow-x: hidden;
}
body[data-heading="gothic"] { --heading-font: "Hiragino Sans", "Yu Gothic", "Noto Sans JP", sans-serif; }

/* ---- シーン配色 ---- */
body[data-scene="day"]  { --scene-bg:#fbfaf7; --scene-ink:#1d2731; --scene-muted:#5f6b76; --scene-line:#dfe4e8; --scene-card:#ffffff; }
body[data-scene="dusk"] { --scene-bg:#f2e2c8; --scene-ink:#3a2c1c; --scene-muted:#7a6248; --scene-line:#e2cfae; --scene-card:#fbf3e3; }
body[data-scene="night"]{ --scene-bg:#0e1720; --scene-ink:#eef2f5; --scene-muted:#9fb0bd; --scene-line:#26333f; --scene-card:#17222d; }

/* オールダーク パターン */
body[data-mood="dark"] { --scene-bg:#0e1720 !important; --scene-ink:#eef2f5 !important; --scene-muted:#9fb0bd !important; --scene-line:#26333f !important; --scene-card:#17222d !important; }

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
p { line-height: 2; margin: 0 0 14px; }

.container { width: min(1280px, calc(100% - 96px)); margin: 0 auto; }
@media (max-width: 720px) { .container { width: calc(100% - 40px); } }

/* ---- 空のグラデーション（固定背景） ---- */
.sky {
  position: fixed; inset: 0; z-index: -2; pointer-events: none;
  opacity: 1; transition: opacity 1.4s ease;
}
.sky-layer { position: absolute; inset: 0; opacity: 0; transition: opacity 1.6s ease; }
.sky-day   { background: linear-gradient(180deg, #dcebf5 0%, #fbfaf7 46%, #fbfaf7 100%); }
.sky-dusk  { background: linear-gradient(180deg, #f0b57a 0%, #f2e2c8 52%, #f2e2c8 100%); }
.sky-night { background: linear-gradient(180deg, #060b12 0%, #0e1720 55%, #0e1720 100%); }
body[data-scene="day"]   .sky-day   { opacity: 1; }
body[data-scene="dusk"]  .sky-dusk  { opacity: 1; }
body[data-scene="night"] .sky-night { opacity: 1; }
body[data-mood="dark"] .sky-day, body[data-mood="dark"] .sky-dusk { opacity: 0; }
body[data-mood="dark"] .sky-night { opacity: 1; }

/* ---- ヘッダー ---- */
.header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 30;
  transition: background .6s ease, box-shadow .6s ease;
}
.header-inner { height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.header .logo { width: 220px; }
.header.is-solid { background: rgba(14, 23, 32, .82); backdrop-filter: blur(12px); box-shadow: 0 2px 24px rgba(0,0,0,.25); }
.nav { display: flex; align-items: center; gap: clamp(18px, 2.2vw, 40px); font-weight: 700; font-size: 14px; color: #fff; }
.nav a { opacity: .85; transition: opacity .2s; text-shadow: 0 1px 8px rgba(0,0,0,.4); }
.nav a:hover { opacity: 1; }
.nav .nav-cta {
  background: var(--orange); color: #fff; padding: 10px 20px; border-radius: 999px;
  opacity: 1; text-shadow: none; box-shadow: 0 6px 18px rgba(217,119,6,.35);
}
@media (max-width: 900px) { .nav a:not(.nav-cta) { display: none; } .header .logo { width: 180px; } }

/* ---- ヒーロー（全画面・映画のオープニング） ---- */
.hero {
  position: relative; min-height: 100svh;
  display: grid; place-items: center;
  overflow: hidden; color: #fff;
}
.hero-bg { position: absolute; inset: -6% 0; z-index: 0; }
.hero-bg-img {
  position: absolute; inset: 0;
  background-size: cover; background-position: center;
  opacity: 0;
  transition: opacity 1.8s ease-in-out;
  animation: kenburns 26s ease-in-out infinite alternate;
}
.hero-bg-img.is-active { opacity: 1; }
.hero-veil {
  position: absolute; inset: 0; z-index: 1;
  background:
    radial-gradient(120% 90% at 50% 100%, rgba(6,11,18,.15) 0%, rgba(6,11,18,0) 50%),
    linear-gradient(180deg, rgba(6,11,18,.62) 0%, rgba(14,23,32,.38) 40%, rgba(14,23,32,.72) 100%);
}
@keyframes kenburns { from { transform: scale(1); } to { transform: scale(1.09); } }

.hero-stage {
  position: relative; z-index: 2;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center; gap: clamp(24px, 4vw, 72px);
  width: min(1280px, calc(100% - 96px));
  padding: 110px 0 80px;
}
.hero-copy h1 {
  font-family: var(--heading-font);
  font-size: clamp(34px, 4.6vw, 68px);
  line-height: 1.5; margin: 0 0 26px; font-weight: 700;
  letter-spacing: .04em;
  text-shadow: 0 2px 30px rgba(0,0,0,.45);
}
.hero-copy h1 span { color: var(--gold); }
.hero-lead {
  font-size: clamp(15px, 1.2vw, 18px); line-height: 2.1;
  color: rgba(255,255,255,.88); max-width: 34em;
  text-shadow: 0 1px 14px rgba(0,0,0,.5);
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; margin-top: 34px; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 15px 32px; border-radius: 999px; font-weight: 700; font-size: 15px;
  transition: transform .25s ease, box-shadow .25s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--orange); color: #fff; box-shadow: 0 10px 26px rgba(217,119,6,.4); }
.btn-ghost { border: 1.5px solid rgba(255,255,255,.6); color: #fff; backdrop-filter: blur(4px); }

.hero-figure { position: relative; justify-self: center; width: min(420px, 78%); }
.hero-video, .hero-still-img {
  width: 100%; display: block;
  filter: drop-shadow(0 30px 60px rgba(0,0,0,.5));
}
.hero-still-img { position: absolute; inset: 0; opacity: 0; pointer-events: none; }

.hero-scroll {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  z-index: 2; color: rgba(255,255,255,.75); font-size: 11px; letter-spacing: .3em;
  display: grid; justify-items: center; gap: 10px;
}
.hero-scroll::after {
  content: ""; width: 1px; height: 44px;
  background: linear-gradient(180deg, rgba(255,255,255,.8), rgba(255,255,255,0));
  animation: scrollhint 2.2s ease-in-out infinite;
}
@keyframes scrollhint { 0%{transform:scaleY(0);transform-origin:top;} 45%{transform:scaleY(1);transform-origin:top;} 55%{transform:scaleY(1);transform-origin:bottom;} 100%{transform:scaleY(0);transform-origin:bottom;} }

@media (max-width: 900px) {
  .hero-stage { grid-template-columns: 1fr; text-align: center; padding: 120px 0 90px; }
  .hero-copy h1 { font-size: clamp(30px, 8vw, 42px); }
  .hero-lead { margin-inline: auto; }
  .hero-actions { justify-content: center; }
  .hero-figure { width: min(300px, 70%); order: -1; }
}

/* ---- 章タイトル ---- */
.chapter {
  text-align: center; margin-bottom: clamp(40px, 6vw, 72px);
}
.chapter .ch-no {
  display: block; font-size: 12px; letter-spacing: .42em; font-weight: 700;
  color: var(--gold); margin-bottom: 14px; text-transform: uppercase;
}
.chapter h2 {
  font-family: var(--heading-font);
  font-size: clamp(26px, 3.2vw, 44px); margin: 0; letter-spacing: .06em; line-height: 1.6;
}
.chapter .ch-sub { color: var(--scene-muted); margin-top: 14px; font-size: 15px; }

section.scene { padding: clamp(80px, 11vw, 150px) 0; position: relative; }

/* ---- Prologue / About ---- */
.prologue-grid {
  display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 80px); align-items: center;
}
.prologue-grid img { width: min(320px, 80%); margin-inline: auto; filter: drop-shadow(0 20px 40px rgba(31,41,51,.18)); }
.prologue-text p { font-size: clamp(15px, 1.15vw, 17px); }
.prologue-text .big-line {
  font-family: var(--heading-font);
  font-size: clamp(20px, 2.2vw, 30px); line-height: 1.9; font-weight: 700;
  margin: 26px 0; letter-spacing: .04em;
}
.prologue-text .big-line em { font-style: normal; color: var(--orange); }
.signature { display: flex; align-items: center; gap: 14px; margin-top: 28px; font-weight: 700; font-size: 14px; }
.signature img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; }
@media (max-width: 900px) { .prologue-grid { grid-template-columns: 1fr; text-align: center; } .signature { justify-content: center; } }

/* ---- 強み ---- */
.strength-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.s-card {
  background: var(--scene-card); border: 1px solid var(--scene-line);
  border-radius: 16px; padding: 34px 26px; box-shadow: var(--shadow);
  transition: transform .35s ease, background-color 1.2s ease, border-color 1.2s ease;
}
.s-card:hover { transform: translateY(-6px); }
.s-card .s-icon { width: 46px; height: 46px; color: var(--orange); margin-bottom: 18px; }
.s-card .s-icon svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.s-card h3 { margin: 0 0 6px; font-size: 18px; }
.s-card strong { display: block; font-size: 13px; color: var(--gold); margin-bottom: 10px; }
.s-card p { font-size: 14px; line-height: 1.9; color: var(--scene-muted); margin: 0; }
@media (max-width: 1000px) { .strength-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .strength-grid { grid-template-columns: 1fr; } }

/* ---- サービス ---- */
.plan-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.p-card {
  background: var(--scene-card); border: 1px solid var(--scene-line); border-radius: 16px;
  overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column;
  transition: transform .35s ease, background-color 1.2s ease, border-color 1.2s ease;
}
.p-card:hover { transform: translateY(-6px); }
.p-name { background: var(--navy); color: #fff; text-align: center; font-weight: 700; padding: 14px; font-size: 15px; letter-spacing: .06em; }
.p-card.featured .p-name { background: var(--orange); }
.p-body { padding: 26px 22px; text-align: center; display: grid; gap: 12px; flex: 1; align-content: start; }
.p-body .p-icon { width: 40px; height: 40px; margin: 0 auto; color: var(--gold); }
.p-body .p-icon svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.p-desc { font-size: 14px; line-height: 1.9; margin: 0; }
.p-quote { font-size: 12px; color: var(--scene-muted); margin: 0; }
@media (max-width: 1000px) { .plan-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .plan-grid { grid-template-columns: 1fr; } }

/* ---- 制作サンプル ---- */
.sample-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.smp {
  background: var(--scene-card); border: 1px solid var(--scene-line); border-radius: 18px;
  overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column;
  transition: transform .35s ease, background-color 1.2s ease;
}
.smp:hover { transform: translateY(-6px); }
.smp-thumb { position: relative; aspect-ratio: 16/10; overflow: hidden; }
.smp-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s ease; }
.smp:hover .smp-thumb img { transform: scale(1.06); }
.smp-badge {
  position: absolute; top: 12px; left: 12px; background: rgba(14,23,32,.82); color: #fff;
  font-size: 11px; font-weight: 700; letter-spacing: .16em; padding: 5px 12px; border-radius: 999px;
}
.smp-body { padding: 22px 22px 26px; display: grid; gap: 10px; }
.smp-body h3 { margin: 0; font-size: 16px; line-height: 1.7; }
.smp-meta { font-size: 12px; color: var(--scene-muted); display: flex; gap: 12px; flex-wrap: wrap; }
.smp-link { font-size: 13px; font-weight: 700; color: var(--orange); display: inline-flex; align-items: center; gap: 6px; }
.samples-note { text-align: center; color: var(--scene-muted); font-size: 13px; margin-top: 26px; }
@media (max-width: 900px) { .sample-grid { grid-template-columns: 1fr; } }

/* ---- 発信メディア ---- */
.media-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.m-card {
  background: var(--scene-card); border: 1px solid var(--scene-line); border-radius: 16px;
  padding: 28px 24px; box-shadow: var(--shadow); display: grid; gap: 12px; align-content: start;
  transition: transform .35s ease, background-color 1.2s ease;
}
.m-card:hover { transform: translateY(-5px); }
.m-top { display: flex; align-items: center; gap: 14px; }
.m-top img { width: 44px; height: 44px; border-radius: 10px; object-fit: contain; }
.m-top .duo { display: flex; gap: 6px; }
.m-top .duo img { width: 34px; height: 34px; }
.m-top h3 { margin: 0; font-size: 16px; }
.m-top small { color: var(--scene-muted); }
.m-card p { font-size: 14px; margin: 0; color: var(--scene-muted); line-height: 1.9; }
.m-link { font-size: 13px; font-weight: 700; color: var(--orange); }
@media (max-width: 900px) { .media-grid { grid-template-columns: 1fr; } }

/* ---- 制作の流れ ---- */
.flow-steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px; counter-reset: fl; }
.f-step {
  background: var(--scene-card); border: 1px solid var(--scene-line); border-radius: 16px;
  padding: 28px 20px; text-align: center; box-shadow: var(--shadow);
  transition: background-color 1.2s ease;
}
.f-no { display: block; font-size: 26px; font-weight: 800; color: var(--gold); font-family: var(--heading-font); margin-bottom: 8px; }
.f-step h3 { margin: 0 0 8px; font-size: 15px; }
.f-step p { font-size: 13px; color: var(--scene-muted); line-height: 1.8; margin: 0; }
@media (max-width: 1000px) { .flow-steps { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .flow-steps { grid-template-columns: 1fr; } }

/* ---- 夜のコンタクト ---- */
.contact-grid { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(32px, 5vw, 80px); }
.contact h2 { font-family: var(--heading-font); font-size: clamp(26px, 3vw, 42px); line-height: 1.7; margin: 0 0 22px; }
.contact-email {
  display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 17px;
  color: var(--gold); border: 1px solid var(--scene-line); border-radius: 12px; padding: 14px 22px;
  background: var(--scene-card);
}
.biz-info {
  margin: 26px 0 0; display: grid; gap: 0;
  border: 1px solid var(--scene-line); border-radius: 12px; overflow: hidden;
  background: var(--scene-card);
}
.biz-row {
  display: grid; grid-template-columns: 100px 1fr; gap: 14px;
  padding: 12px 18px; border-top: 1px solid var(--scene-line); font-size: 13.5px;
}
.biz-row:first-child { border-top: 0; }
.biz-row dt { margin: 0; font-weight: 700; color: var(--scene-muted); }
.biz-row dd { margin: 0; line-height: 1.7; }
@media (max-width: 560px) { .biz-row { grid-template-columns: 84px 1fr; gap: 10px; } }
.form { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form .full { grid-column: 1 / -1; }
.form label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.form .req { color: var(--orange); font-size: 11px; margin-left: 6px; }
.form input, .form textarea {
  width: 100%; padding: 13px 14px; border-radius: 10px; font-size: 15px;
  border: 1px solid var(--scene-line); background: var(--scene-card); color: var(--scene-ink);
  font-family: inherit;
}
.form textarea { min-height: 130px; resize: vertical; }
.form-consent { grid-column: 1 / -1; font-size: 13px; display: flex; gap: 8px; align-items: flex-start; color: var(--scene-muted); }
.form-actions { grid-column: 1 / -1; display: grid; gap: 12px; }
.form-actions button {
  background: var(--orange); color: #fff; border: 0; border-radius: 999px;
  padding: 16px; font-size: 16px; font-weight: 700; cursor: pointer;
  box-shadow: 0 10px 26px rgba(217,119,6,.35); transition: transform .25s;
}
.form-actions button:hover { transform: translateY(-2px); }
.form-notes { font-size: 12px; color: var(--scene-muted); line-height: 1.9; margin: 0; }
.form-notes a { text-decoration: underline; }
.form-status { font-size: 14px; font-weight: 700; margin: 0; }
.form-honeypot { position: absolute; left: -9999px; }
@media (max-width: 900px) { .contact-grid, .form { grid-template-columns: 1fr; } }

/* ---- 受注について ---- */
.order-card {
  max-width: 780px; margin: 0 auto; text-align: center;
  border: 1px solid var(--scene-line); background: var(--scene-card);
  border-radius: 20px; padding: clamp(36px, 5vw, 60px); box-shadow: var(--shadow);
}
.order-card h2 { font-family: var(--heading-font); margin: 0 0 18px; font-size: clamp(22px, 2.4vw, 32px); }
.order-card p { font-size: 15px; color: var(--scene-muted); }
.order-cta {
  display: inline-block; margin-top: 18px; background: var(--navy); color: #fff;
  padding: 14px 34px; border-radius: 999px; font-weight: 700;
}
body[data-scene="night"] .order-cta, body[data-mood="dark"] .order-cta { background: var(--orange); }

/* ---- フッター ---- */
.footer { border-top: 1px solid var(--scene-line); padding: 44px 0 60px; }
.footer-inner { display: grid; gap: 20px; justify-items: center; text-align: center; }
.footer-logo { width: 240px; }
.footer-nav { display: flex; gap: 20px; flex-wrap: wrap; justify-content: center; font-size: 13px; font-weight: 700; }
.footer .copy { font-size: 12px; color: var(--scene-muted); }

/* ---- 出現アニメーション ---- */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(34px); transition: opacity .9s ease, transform .9s cubic-bezier(.22,.9,.3,1); }
  .reveal.is-in { opacity: 1; transform: none; }
  .reveal[data-delay="1"] { transition-delay: .12s; }
  .reveal[data-delay="2"] { transition-delay: .24s; }
  .reveal[data-delay="3"] { transition-delay: .36s; }
  body[data-motion="low"] .reveal { transition-duration: .5s; transform: translateY(12px); }
}

/* ---- パララックス装飾 ---- */
.parallax { will-change: transform; }

/* ---- 浮遊CTA ---- */
.floating-cta {
  position: fixed; right: 22px; bottom: 22px; z-index: 40;
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--orange); color: #fff; font-weight: 700; font-size: 14px;
  padding: 14px 22px; border-radius: 999px; box-shadow: 0 12px 30px rgba(217,119,6,.45);
  opacity: 0; pointer-events: none; transform: translateY(12px);
  transition: opacity .4s ease, transform .4s ease;
}
.floating-cta.is-on { opacity: 1; pointer-events: auto; transform: none; }
.floating-cta svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; }

/* ---- Tweaks パネル ---- */
.tweaks-panel {
  position: fixed; right: 18px; top: 90px; z-index: 60; width: 250px;
  background: #fff; color: #1d2731; border-radius: 14px; box-shadow: 0 20px 50px rgba(0,0,0,.3);
  font-size: 13px; overflow: hidden;
}
.tweaks-head { display: flex; justify-content: space-between; align-items: center; padding: 12px 16px; background: #1f2933; color: #fff; cursor: grab; }
.tweaks-close { background: none; border: 0; color: #fff; font-size: 16px; cursor: pointer; }
.tweaks-body { padding: 14px 16px 18px; display: grid; gap: 14px; }
.tweak-row label { display: block; font-weight: 700; margin-bottom: 7px; }
.segments { display: flex; gap: 6px; flex-wrap: wrap; }
.segments button {
  border: 1px solid #dfe4e8; background: #fff; border-radius: 999px; padding: 6px 12px;
  font-size: 12px; cursor: pointer; font-family: inherit;
}
.segments button.is-on { background: #1f2933; color: #fff; border-color: #1f2933; }
