/* Genkan Web サービスサイト（C案 スクロール演出） */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 64px;
}
body {
  margin: 0;
  font-family: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  color: #ffffff;
  background: #0e1b2a;
  -webkit-font-smoothing: antialiased;
}
a {
  color: #8fb4ff;
}
a:hover {
  color: #bfd3ff;
}
.c-story {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
.c-stage-wrap {
  position: sticky;
  top: 64px;
  height: calc(100vh - 64px);
  align-self: start;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.c-stage {
  position: relative;
  width: 560px;
  height: 560px;
  flex-shrink: 0;
}
.c-blk {
  position: absolute;
  box-sizing: border-box;
  white-space: pre-line;
  padding: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-weight: 900;
  line-height: 1.3;
  transition:
    left 0.9s cubic-bezier(0.2, 0.8, 0.2, 1),
    top 0.9s cubic-bezier(0.2, 0.8, 0.2, 1),
    width 0.9s cubic-bezier(0.2, 0.8, 0.2, 1),
    height 0.9s cubic-bezier(0.2, 0.8, 0.2, 1),
    border-radius 0.9s,
    background-color 0.9s,
    opacity 0.7s,
    transform 0.9s cubic-bezier(0.2, 0.8, 0.2, 1),
    font-size 0.6s,
    color 0.6s;
}
.c-step {
  min-height: 100vh;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
  padding: 96px 6vw 96px 9vw;
}
.c-dots {
  position: absolute;
  left: 50%;
  bottom: -48px;
  transform: translateX(-50%);
  display: flex;
  gap: 8px;
}
.c-wide {
  padding-left: 9vw;
  padding-right: 9vw;
}
.c-grid3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.c-grid2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}
@media (max-width: 820px) {
  .c-story {
    grid-template-columns: minmax(0, 1fr);
  }
  .c-stage-wrap {
    order: -1;
    height: 40vh;
    z-index: 2;
    background: #0e1b2a;
  }
  .c-stage {
    transform: scale(0.5);
  }
  .c-step {
    min-height: 72vh;
    padding: 32px 24px 64px;
  }
  .c-wide {
    padding-left: 20px;
    padding-right: 20px;
  }
  .c-grid3,
  .c-grid2 {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 480px) {
  .c-hbtn {
    padding: 0 12px !important;
    font-size: 13px !important;
  }
  .c-hnav {
    gap: 6px !important;
  }
}
@media (prefers-reduced-motion: reduce) {
  .c-blk {
    transition: none;
  }
}

/* テンプレート一覧：横スクロール */
.c-tscroll > a { scroll-snap-align: start; }
.c-tscroll::-webkit-scrollbar { height: 8px; }
.c-tscroll::-webkit-scrollbar-thumb { background: #C9D3E2; border-radius: 4px; }
@media (max-width: 480px) { .c-tscroll { grid-auto-columns: 78% !important; } }

/* お問い合わせフォーム：迷惑メール対策の隠し項目・エラー表示 */
.c-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.c-form-error { margin: 0; padding: 14px 16px; border-radius: 12px; background: #FFF1F0; color: #B42318; font-size: 14px; font-weight: 700; line-height: 1.7; }
#contact-form [aria-invalid="true"] { border-color: #D92D20 !important; background: #FFF6F5 !important; }
#contact-form button[disabled] { opacity: 0.6; cursor: default; }

/* ==========================================================================
   シンプル版：オープニング（玄関の扉が開く）・制作者の想い
   ========================================================================== */
.d-hdr { transition: opacity .5s ease, transform .5s ease; }
.d-hdr.is-hidden { opacity: 0; transform: translateY(-16px); pointer-events: none; }
.d-intro { position: relative; height: 100vh; min-height: 560px; background: #FFFFFF; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.d-logo { width: min(440px, 72vw); height: auto; opacity: 0; transform: translateY(18px) scale(.97); filter: blur(6px); animation: d-logo-in 1.4s cubic-bezier(.2,.8,.2,1) 1.25s forwards; }
.d-door { position: absolute; top: 0; bottom: 0; width: 50.5%; background: #163A63; z-index: 3; animation-duration: 1.25s; animation-timing-function: cubic-bezier(.7,0,.2,1); animation-delay: .45s; animation-fill-mode: forwards; }
.d-door--l { left: 0; animation-name: d-door-l; box-shadow: inset -1px 0 0 rgba(255,255,255,.12); }
.d-door--r { right: 0; animation-name: d-door-r; }
.d-door-light { position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; margin-left: -1px; background: #2F8CF0; z-index: 4; box-shadow: 0 0 24px 6px rgba(47,140,240,.55); animation: d-light 1.7s ease .1s forwards; }
.d-scroll { position: absolute; left: 50%; bottom: 32px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 10px; font-family: 'Manrope', sans-serif; font-size: 11px; font-weight: 700; letter-spacing: .3em; color: #163A63; text-decoration: none; opacity: 0; animation: d-fade .8s ease 2.4s forwards; }
.d-scroll:hover { color: #163A63; }
.d-scroll i { display: block; width: 1px; height: 48px; background: linear-gradient(#163A63 50%, rgba(22,58,99,.15) 50%); background-size: 1px 96px; animation: d-line 1.8s linear infinite; }
.d-msg { position: relative; height: 260vh; background: #FFFFFF; transition: background-color .6s linear; }
.d-msg-in { position: sticky; top: 0; height: 100vh; box-sizing: border-box; display: flex; align-items: center; padding: 0 9vw; gap: 6vw; }
.d-msg-label { margin: 0; flex-shrink: 0; writing-mode: vertical-rl; font-family: 'Manrope', sans-serif; font-size: 12px; font-weight: 800; letter-spacing: .4em; color: #2358D6; display: flex; align-items: center; gap: 16px; }
.d-msg-label::after { content: ""; width: 1px; height: 80px; background: #C9D3E2; }
.d-lines { margin: 0; font-family: 'Shippori Mincho', 'Yu Mincho', 'Hiragino Mincho ProN', serif; color: #163A63; font-size: clamp(20px, 2.3vw, 32px); line-height: 2.1; font-weight: 600; letter-spacing: .06em; transition: color 1s ease; }
.d-line { display: block; word-break: auto-phrase; text-wrap: pretty; opacity: 0; transform: translateY(18px); filter: blur(4px); transition: opacity 1.1s ease, transform 1.1s cubic-bezier(.2,.8,.2,1), filter 1.1s ease; }
.d-line.is-on { opacity: 1; transform: none; filter: none; }
.d-gap { display: block; height: 1.1em; }
.d-em { color: #2F8CF0; }
.d-sign { display: block; margin-top: 1.6em; font-family: 'Manrope', 'Zen Kaku Gothic New', sans-serif; font-size: 14px; font-weight: 700; letter-spacing: .12em; color: #4C5A73; opacity: 0; transition: opacity 1.1s ease, color 1s ease; }
.d-sign.is-on { opacity: 1; }
@keyframes d-door-l { to { transform: translateX(-101%); } }
@keyframes d-door-r { to { transform: translateX(101%); } }
@keyframes d-light { 0% { opacity: 0; transform: scaleY(0); } 30% { opacity: 1; transform: scaleY(1); } 60% { opacity: 1; } 100% { opacity: 0; } }
@keyframes d-logo-in { to { opacity: 1; transform: none; filter: none; } }
@keyframes d-fade { to { opacity: 1; } }
@keyframes d-line { from { background-position: 0 -48px; } to { background-position: 0 48px; } }
@media (max-width: 820px) {
  .d-msg { height: 240vh; }
  .d-msg-in { flex-direction: column; align-items: flex-start; justify-content: center; gap: 28px; padding: 0 24px; }
  .d-msg-label { writing-mode: horizontal-tb; }
  .d-msg-label::after { width: 48px; height: 1px; }
  .d-lines { font-size: clamp(17px, 4.6vw, 22px); line-height: 2; }
}
@media (prefers-reduced-motion: reduce) {
  .d-door, .d-door-light { display: none; }
  .d-logo, .d-scroll { animation: none; opacity: 1; transform: none; filter: none; }
  .d-line, .d-sign, .d-msg { transition: none; }
}
