/* ========================================
   home.css
   トップページ専用: hero / about / services / company / contact
   ======================================== */

/* ============ HERO ============ */
#hero {
  position: relative;
  min-height: 640px;
  height: 100svh;
  max-height: 920px;
  padding: 100px 40px 40px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  overflow: hidden;
  background: var(--bg);
}

/* hero装飾 */
.hero-eyebrow {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-soft);
  opacity: 0;
  animation: fade 0.9s ease 0.6s forwards;
}
.hero-eyebrow .dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--c-ad);
  margin-right: 10px;
  vertical-align: middle;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.6); opacity: 0.5; }
}
.hero-eyebrow .right-meta {
  display: flex;
  align-items: center;
  gap: 18px;
}
.hero-eyebrow .right-meta span { display: inline-block; }
.hero-eyebrow .bar {
  width: 26px;
  height: 1px;
  background: currentColor;
  display: inline-block;
}

/* 英語サブタイトル（ローテーション） */
.hero-sub {
  position: relative;
  z-index: 2;
  max-width: 1500px;
  width: 100%;
  margin: 18px auto 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(15px, 1.3vw, 22px);
  letter-spacing: 0.04em;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fade 1s ease 1.3s forwards;
}
.hero-sub .arrow {
  display: inline-block;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0;
}
.hero-sub-rotator {
  position: relative;
  display: inline-block;
  height: 1.5em;
  overflow: hidden;
  vertical-align: bottom;
}
.hero-sub-rotator .item {
  display: block;
  height: 1.5em;
  line-height: 1.5em;
  animation: rotate-sub 9s cubic-bezier(0.7, 0, 0.3, 1) infinite;
}
@keyframes rotate-sub {
  0%, 22%   { transform: translateY(0); }
  25%, 47%  { transform: translateY(-1.5em); }
  50%, 72%  { transform: translateY(-3em); }
  75%, 97%  { transform: translateY(-4.5em); }
  100%      { transform: translateY(-6em); }
}

/* スクロールキュー */
.hero-scroll-cue {
  position: absolute;
  right: 40px;
  bottom: 24px;
  z-index: 2;
  font-family: var(--serif);
  font-style: italic;
  font-size: 10px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  gap: 10px;
  opacity: 0;
  animation: fade 0.9s ease 1.5s forwards;
}
.hero-scroll-cue::after {
  content: "";
  width: 1px;
  height: 36px;
  background: currentColor;
  animation: scroll-line 1.6s ease-in-out infinite;
  transform-origin: top;
}
@keyframes scroll-line {
  0% { transform: scaleY(0); transform-origin: top; }
  50% { transform: scaleY(1); transform-origin: top; }
  51% { transform: scaleY(1); transform-origin: bottom; }
  100% { transform: scaleY(0); transform-origin: bottom; }
}

#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.hero-main {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto;
}

.hero-statement {
  font-family: var(--jp);
  font-weight: 900;
  line-height: 1.15;
  letter-spacing: -0.05em;
  width: 100%;
  --hero-fs: 120px;
  font-size: var(--hero-fs);
}
.hero-statement .line {
  display: block;
  white-space: nowrap;
}
/* 「カタチ」が塗り潰しのため、行間広めに取らないと密着して見える */
.hero-statement .line-2 { margin-top: 0.22em; }
.hero-statement .word {
  display: inline-block;
  overflow: hidden;
  vertical-align: bottom;
}
.hero-statement .word > span {
  display: inline-block;
  transform: translateY(110%);
  animation: rise 1s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.hero-statement .line-2 .word > span { animation-delay: 0.2s; }
.hero-statement .katachi {
  display: inline-block;
  background: var(--ink);
  color: var(--bg);
  padding: 0 0.16em 0.06em;
}
.hero-statement .line-2 .katachi {
  background: var(--c-prod);
}
@keyframes rise { to { transform: translateY(0); } }
@keyframes fade { to { opacity: 1; } }

.hero-foot {
  position: relative;
  z-index: 2;
  display: block;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto;
  padding-top: 48px;
  border-top: 1px solid rgba(14, 14, 14, 0.18);
  opacity: 0;
  animation: fade 1s ease 1.1s forwards;
}
.hero-foot-label {
  font-family: var(--serif);
  font-style: italic;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero-foot-label::before {
  content: "";
  width: 28px;
  height: 1px;
  background: currentColor;
}
.hero-desc {
  font-size: 16px;
  line-height: 1.95;
  color: var(--ink);
  max-width: 520px;
  font-weight: 500;
}

@media (max-width: 900px) {
  #hero {
    padding: 90px 20px 32px;
    min-height: 560px;
  }
  .hero-eyebrow {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .hero-scroll-cue { right: 20px; }
}

@media (max-width: 600px) {
  .hero-sub {
    font-size: 14px;
    gap: 8px;
  }
  .hero-desc {
    font-size: 15px;
    /* 右下のSCROLLキューと文字が重ならないよう右側に余白を確保 */
    padding-right: 64px;
  }
  .hero-foot-label { padding-right: 64px; }
}

/* ============ ABOUT ============ */
#about {
  background: var(--bg);
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.scroll-text {
  font-family: var(--jp);
  font-weight: 900;
  font-size: clamp(22px, 4vw, 56px);
  line-height: 1.5;
  letter-spacing: -0.02em;
  max-width: 1300px;
  margin: 0 auto;
}
.scroll-text .w {
  display: inline-block;
  color: rgba(14, 14, 14, 0.15);
  transition: color 0.3s ease;
  /* 1つのspanが画面幅を超える場合は内部折り返しを許容 */
  max-width: 100%;
}
.scroll-text .w.lit { color: var(--ink); }
.scroll-text .w.accent.lit { color: var(--c-ad); }
.scroll-text .w.accent2.lit { color: var(--c-prod); }
.scroll-text .w.accent3.lit {
  color: var(--ink);
  background: linear-gradient(transparent 60%, var(--c-mc) 60%);
  padding: 0 4px;
}

/* ============ SERVICES ============ */
#services {
  background: var(--ink);
  color: var(--bg);
  overflow: hidden;
}
#services .section-label,
#services .section-heading { color: var(--bg); }

.services-list {
  max-width: 1500px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}

.service-row {
  display: grid;
  grid-template-columns: 90px 1.4fr 1.6fr;
  gap: 48px;
  align-items: center;
  padding: 56px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  position: relative;
}
.service-row:last-child {
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.service-num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 18px;
  color: rgba(255, 255, 255, 0.5);
}

.service-name {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.service-en {
  font-family: var(--serif);
  font-style: italic;
  font-size: 13px;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.55);
}
.service-jp {
  font-family: var(--jp);
  font-weight: 900;
  font-size: clamp(22px, 2.4vw, 32px);
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.service-desc {
  font-size: 13.5px;
  line-height: 1.85;
  color: rgba(255, 255, 255, 0.7);
}

@media (max-width: 900px) {
  .service-row {
    grid-template-columns: 40px 1fr;
    gap: 14px 18px;
    padding: 40px 16px;
  }
  .service-name { grid-column: 2; }
  .service-desc { grid-column: 1 / -1; }
}

/* ============ COMPANY ============ */
#company {
  background: var(--bg);
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}
.company-grid {
  max-width: 1100px;
  margin: 0 auto;
}
.company-dl {
  display: grid;
  grid-template-columns: 220px 1fr;
  border-top: 1px solid rgba(14, 14, 14, 0.18);
}
.company-dl dt,
.company-dl dd {
  padding: 28px 4px;
  border-bottom: 1px solid rgba(14, 14, 14, 0.18);
  margin: 0;
  line-height: 1.7;
  align-self: stretch;
  display: flex;
  align-items: center;
}
.company-dl dt {
  font-family: var(--serif);
  font-style: italic;
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 400;
}
.company-dl dd {
  font-family: var(--jp);
  font-weight: 700;
  font-size: 17px;
  color: var(--ink);
}
@media (max-width: 700px) {
  .company-dl { grid-template-columns: 1fr; }
  .company-dl dt {
    padding: 20px 4px 8px;
    border-bottom: none;
  }
  .company-dl dd {
    padding: 0 4px 20px;
  }
}

/* ============ CONTACT ============ */
#contact {
  background: var(--bg);
  position: relative;
  overflow: hidden;
}
.contact-bg-text {
  position: absolute;
  font-family: var(--serif);
  font-style: italic;
  font-weight: 900;
  font-size: clamp(220px, 32vw, 540px);
  color: rgba(14, 14, 14, 0.05);
  white-space: nowrap;
  bottom: -10%;
  left: -5%;
  letter-spacing: -0.04em;
  pointer-events: none;
  line-height: 0.9;
}
.contact-grid {
  position: relative;
  z-index: 1;
  max-width: 1500px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 100px;
  align-items: start;
}
.contact-lead {
  position: sticky;
  top: 120px;
}
.contact-heading {
  font-weight: 900;
  font-size: clamp(32px, 4.4vw, 60px);
  line-height: 1.25;
  letter-spacing: -0.03em;
  margin-bottom: 32px;
  word-break: normal;
  overflow-wrap: normal;
}
.contact-heading .accent-y {
  background: linear-gradient(transparent 65%, var(--c-mc) 65%);
  padding: 0 6px;
}
.contact-lead-sub {
  font-size: 14px;
  line-height: 2;
  color: var(--ink-soft);
  max-width: 420px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 36px;
}
.form-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.form-label {
  font-family: var(--serif);
  font-style: italic;
  font-size: 11px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.form-label .jp {
  font-family: var(--jp);
  font-style: normal;
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--ink);
  font-weight: 700;
}
.form-label .required {
  font-family: var(--jp);
  font-style: normal;
  font-size: 10px;
  color: var(--c-ad);
  border: 1px solid var(--c-ad);
  padding: 1px 6px;
  border-radius: 999px;
}

.form-input,
.form-textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--ink);
  padding: 12px 0;
  font-family: var(--jp);
  font-weight: 500;
  font-size: 17px;
  color: var(--ink);
  outline: none;
  transition: border-color 0.3s ease, padding 0.35s ease;
  border-radius: 0;
}
.form-input::placeholder,
.form-textarea::placeholder {
  color: rgba(14, 14, 14, 0.3);
  font-weight: 400;
}
.form-input:focus,
.form-textarea:focus {
  border-color: var(--c-prod);
  padding-left: 8px;
}
.form-input.is-error,
.form-textarea.is-error {
  border-color: var(--c-ad);
}
.form-textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.8;
}

/* ハニーポット（bot対策。ユーザーには見せない） */
.form-hp {
  position: absolute;
  left: -9999px;
  top: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.form-error {
  font-size: 12px;
  color: var(--c-ad);
  margin-top: 4px;
  display: none;
}
.form-error.is-visible { display: block; }

.form-flash {
  padding: 16px 20px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 8px;
}
.form-flash.is-success {
  background: rgba(31, 122, 77, 0.1);
  border: 1px solid var(--c-lp);
  color: var(--c-lp);
}
.form-flash.is-error {
  background: rgba(255, 61, 46, 0.08);
  border: 1px solid var(--c-ad);
  color: var(--c-ad);
}

.form-submit-wrap {
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}
.form-submit {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 24px 48px;
  background: var(--ink);
  color: var(--bg);
  font-family: var(--jp);
  font-weight: 900;
  font-size: 16px;
  letter-spacing: 0.1em;
  border: none;
  cursor: pointer;
  overflow: hidden;
  border-radius: 999px;
  transition: color 0.4s ease;
}
.form-submit::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--acid);
  transform: translateY(101%);
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}
.form-submit:hover::before { transform: translateY(0); }
.form-submit:hover { color: var(--ink); }
.form-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
.form-submit span {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.form-note {
  font-size: 12px;
  color: var(--ink-soft);
  letter-spacing: 0.05em;
  line-height: 1.7;
}

@media (max-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 64px;
  }
  .contact-lead { position: static; }
}

@media (max-width: 600px) {
  .form-submit {
    padding: 20px 36px;
    font-size: 15px;
  }
  .form-submit-wrap {
    gap: 16px;
  }
}
