@charset "UTF-8";

/* =========================================================
   木立工務店（デモサイト）
   Irodori Web / ハナ
   ---------------------------------------------------------
   色・余白・フォントの決めごとは :root にまとめています。
   ここを変えるとサイト全体の印象が変わります。
   ========================================================= */

:root {
  --white:  #ffffff;
  --cream:  #f7f5f1;   /* 生成り。セクションの背景に交互に使う */
  --ink:    #3a3833;   /* 文字色。真っ黒にしない */
  --ink-light: #7c776e; /* 補助テキスト */
  --wood:   #8c7b6b;   /* アクセント（木の色） */
  --line:   #ddd8d0;   /* 罫線 */

  --serif: "Yu Mincho", YuMincho, "Hiragino Mincho ProN", "Hiragino Mincho Pro", "MS PMincho", serif;
  --sans:  "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", YuGothic, "Noto Sans JP", sans-serif;

  --pad-section: 120px;  /* セクションの上下余白（PC） */
  --wrap: 1200px;
  --wrap-text: 680px;
}

/* ---------- リセット ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 15px;
  line-height: 2.0;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  letter-spacing: 0.04em;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { font-weight: normal; margin: 0; }

/* ---------- 共通パーツ ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}
.wrap-text { max-width: var(--wrap-text); }

.section { padding-block: var(--pad-section); }
.section--cream { background: var(--cream); }

/* 見出し（英字ラベル＋日本語） */
.label {
  font-family: var(--serif);
  font-size: 11px;
  letter-spacing: 0.28em;
  color: var(--wood);
  display: block;
  margin-bottom: 20px;
}
.heading {
  font-family: var(--serif);
  font-size: 28px;
  line-height: 1.8;
  letter-spacing: 0.14em;
  margin-bottom: 40px;
}
.lead {
  font-family: var(--serif);
  font-size: 17px;
  line-height: 2.4;
  letter-spacing: 0.1em;
}

/* リンク（下線が伸びる） */
.more {
  display: inline-block;
  font-size: 13px;
  letter-spacing: 0.2em;
  padding-bottom: 6px;
  position: relative;
}
.more::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--ink);
  transform-origin: right;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.more:hover::after { transform: scaleX(0); transform-origin: left; }

/* ---------- ヘッダー ---------- */
.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 40px;
  transition: background 0.4s, padding 0.4s, box-shadow 0.4s;
}
.header.is-scrolled {
  background: rgba(255, 255, 255, 0.94);
  padding-block: 18px;
  box-shadow: 0 1px 0 var(--line);
}
.header__logo {
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.2em;
  line-height: 1.4;
}
.header__logo span {
  display: block;
  font-size: 9px;
  letter-spacing: 0.34em;
  color: var(--ink-light);
  margin-top: 4px;
}
.gnav ul { display: flex; gap: 34px; }
.gnav a {
  font-size: 12.5px;
  letter-spacing: 0.16em;
  position: relative;
  padding-bottom: 4px;
}
.gnav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s;
}
.gnav a:hover::after,
.gnav a[aria-current="page"]::after { transform: scaleX(1); }

/* ヒーロー写真は上半分が明るい空なので、重なっても濃い文字のままにする。
   ただし写真の情報量に負けないよう、ごく薄い白のグラデーションを敷いて可読性を確保する */
.header:not(.is-scrolled)::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(255,255,255,0.72), rgba(255,255,255,0));
  pointer-events: none;
  z-index: -1;
}
.header { position: fixed; isolation: isolate; }

/* ハンバーガー（SPのみ） */
.burger { display: none; }

/* ---------- ヒーロー ---------- */
.hero {
  position: relative;
  height: 100svh;
  min-height: 560px;
  display: flex;
  align-items: center;
  overflow: hidden;
}
.hero__img {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  animation: heroZoom 14s ease-out forwards;
}
@keyframes heroZoom {
  from { transform: scale(1.06); }
  to   { transform: scale(1); }
}
.hero__copy {
  position: relative;
  z-index: 2;
  padding-left: 8vw;
  color: var(--ink);
}
.hero__copy h1 {
  font-family: var(--serif);
  font-size: clamp(28px, 3.6vw, 46px);
  line-height: 1.9;
  letter-spacing: 0.16em;
}
.hero__copy p {
  font-family: var(--serif);
  font-size: clamp(14px, 1.3vw, 17px);
  letter-spacing: 0.18em;
  margin-top: 28px;
  color: var(--ink);
}
/* スクロール誘導の細い線 */
.hero__scroll {
  position: absolute;
  left: 50%; bottom: 0;
  width: 1px; height: 70px;
  background: linear-gradient(to bottom, transparent, var(--ink));
  z-index: 2;
}
.hero__scroll::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--white);
  animation: scrollLine 2.4s ease-in-out infinite;
}
@keyframes scrollLine {
  0%   { transform: translateY(-100%); }
  60%  { transform: translateY(100%); }
  100% { transform: translateY(100%); }
}

/* ---------- リード ---------- */
.intro { text-align: center; }
.intro .lead + .lead { margin-top: 2em; }

/* ---------- 施工事例カード ---------- */
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px 32px;
}
.works-grid--2col { grid-template-columns: repeat(2, 1fr); gap: 56px 40px; }

.work-card { display: block; }
.work-card__img {
  overflow: hidden;
  aspect-ratio: 3 / 2;
  background: var(--cream);
}
.work-card__img img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 1.2s cubic-bezier(0.2, 0, 0.2, 1);
}
a.work-card:hover .work-card__img img { transform: scale(1.05); }
.work-card__body { padding-top: 20px; }
.work-card__title {
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.12em;
}
.work-card__meta {
  font-size: 12px;
  color: var(--ink-light);
  letter-spacing: 0.1em;
  margin-top: 8px;
  line-height: 1.9;
}

/* ---------- 4つのこと ---------- */
.promise {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 64px 72px;
}
.promise__item { border-top: 1px solid var(--line); padding-top: 28px; }
.promise__num {
  font-family: var(--serif);
  font-size: 12px;
  letter-spacing: 0.24em;
  color: var(--wood);
}
.promise__title {
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: 0.12em;
  margin: 14px 0 16px;
}
.promise__text { font-size: 14px; color: var(--ink-light); }

/* ---------- 全幅写真（息継ぎ） ---------- */
.full-photo {
  height: 62vh;
  min-height: 340px;
  overflow: hidden;
}
.full-photo img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- 流れ（抜粋・タイムライン） ---------- */
.flow-list { counter-reset: flow; }
.flow-list li {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 32px;
  padding: 32px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.flow-list li:first-child { border-top: 1px solid var(--line); }
.flow-list__num {
  font-family: var(--serif);
  font-size: 13px;
  letter-spacing: 0.2em;
  color: var(--wood);
}
.flow-list__title {
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.12em;
}
.flow-list__text { font-size: 14px; color: var(--ink-light); margin-top: 10px; }

/* ---------- 代表の言葉 ---------- */
.message {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 72px;
  align-items: center;
}
.message__img img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }
.message__name {
  margin-top: 40px;
  font-family: var(--serif);
  font-size: 15px;
  letter-spacing: 0.14em;
}
.message__name span { display: block; font-size: 12px; color: var(--ink-light); margin-bottom: 6px; letter-spacing: 0.2em; }

/* ---------- お知らせ ---------- */
.news li {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 24px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}
.news li:first-child { border-top: 1px solid var(--line); }
.news__date { color: var(--ink-light); font-size: 12.5px; letter-spacing: 0.1em; }

/* ---------- CTA ---------- */
.cta { text-align: center; }
.cta__title {
  font-family: var(--serif);
  font-size: clamp(22px, 2.6vw, 30px);
  line-height: 2;
  letter-spacing: 0.14em;
  margin-bottom: 28px;
}
.cta__text { font-size: 14px; color: var(--ink-light); margin-bottom: 48px; }
.btn {
  display: inline-block;
  border: 1px solid var(--ink);
  padding: 20px 64px;
  font-size: 13px;
  letter-spacing: 0.24em;
  position: relative;
  overflow: hidden;
  transition: color 0.5s;
}
.btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: -1;
}
.btn:hover { color: var(--white); }
.btn:hover::before { transform: scaleX(1); transform-origin: left; }
.btn { z-index: 0; isolation: isolate; }

/* ---------- フッター ---------- */
.footer {
  background: var(--cream);
  padding: 80px 0 40px;
  font-size: 13px;
}
.footer__top {
  display: flex;
  justify-content: space-between;
  gap: 48px;
  flex-wrap: wrap;
  padding-bottom: 56px;
  border-bottom: 1px solid var(--line);
}
.footer__logo {
  font-family: var(--serif);
  font-size: 20px;
  letter-spacing: 0.2em;
}
.footer__addr { margin-top: 20px; color: var(--ink-light); font-size: 13px; line-height: 2.1; }
.footer__nav ul { display: flex; gap: 32px; flex-wrap: wrap; }
.footer__nav a { font-size: 13px; letter-spacing: 0.1em; }

/* デモの注記（必須） */
.demo-note {
  margin-top: 40px;
  padding: 22px 26px;
  background: var(--white);
  border: 1px solid var(--line);
  font-size: 12.5px;
  line-height: 2.1;
  color: var(--ink-light);
}
.demo-note strong { color: var(--ink); font-weight: normal; }
.copyright {
  margin-top: 32px;
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--ink-light);
  text-align: center;
}

/* =========================================================
   下層ページ
   ========================================================= */

/* ページの見出し（ヒーローの代わり） */
.page-head {
  padding: 210px 0 90px;
  border-bottom: 1px solid var(--line);
}
.page-head__ja {
  font-family: var(--serif);
  font-size: 30px;
  letter-spacing: 0.16em;
  line-height: 1.6;
}
.page-head__en {
  display: block;
  font-family: var(--serif);
  font-size: 11px;
  letter-spacing: 0.28em;
  color: var(--wood);
  margin-bottom: 18px;
}
.page-head__text {
  margin-top: 28px;
  font-size: 14px;
  color: var(--ink-light);
  max-width: var(--wrap-text);
}

/* パンくず */
.breadcrumb {
  font-size: 11.5px;
  letter-spacing: 0.1em;
  color: var(--ink-light);
  padding-top: 40px;
}
.breadcrumb a { border-bottom: 1px solid transparent; }
.breadcrumb a:hover { border-color: var(--ink-light); }

/* ---------- 施工事例 詳細 ---------- */
.work-hero { margin-top: 84px; }
.work-hero img {
  width: 100%;
  height: min(72vh, 720px);
  object-fit: cover;
}
.work-title {
  font-family: var(--serif);
  font-size: 32px;
  letter-spacing: 0.16em;
  margin-bottom: 20px;
}
.work-sub {
  font-family: var(--serif);
  font-size: 17px;
  letter-spacing: 0.1em;
  color: var(--wood);
  line-height: 2.1;
}
.work-data {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  margin-top: 56px;
}
.work-data th, .work-data td {
  border-top: 1px solid var(--line);
  padding: 18px 0;
  text-align: left;
  vertical-align: top;
  font-weight: normal;
}
.work-data th {
  width: 150px;
  color: var(--ink-light);
  letter-spacing: 0.14em;
}
.work-data tr:last-child th,
.work-data tr:last-child td { border-bottom: 1px solid var(--line); }

.work-body { font-size: 15px; line-height: 2.4; }
.work-body h3 {
  font-family: var(--serif);
  font-size: 21px;
  letter-spacing: 0.14em;
  margin-bottom: 28px;
}
.work-body p + p { margin-top: 1.8em; }

/* 写真の並べ方（大／2枚） */
.photo-single { margin-block: var(--pad-section); }
.photo-single img { width: 100%; }
.photo-duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-block: var(--pad-section);
}
.photo-caption {
  font-size: 12px;
  color: var(--ink-light);
  margin-top: 12px;
  letter-spacing: 0.08em;
}

/* お客様の声 */
.voice {
  background: var(--cream);
  padding: 56px 60px;
  font-size: 14.5px;
  line-height: 2.3;
}
.voice__label {
  font-family: var(--serif);
  font-size: 11px;
  letter-spacing: 0.24em;
  color: var(--wood);
  display: block;
  margin-bottom: 22px;
}
.voice__note {
  margin-top: 24px;
  font-size: 11.5px;
  color: var(--ink-light);
}

/* 前後の事例へ */
.work-nav {
  display: flex;
  justify-content: center;
  gap: 48px;
  padding-top: 8px;
}

/* ---------- 会社概要 ---------- */
.company-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.company-table th, .company-table td {
  border-top: 1px solid var(--line);
  padding: 22px 0;
  text-align: left;
  vertical-align: top;
  font-weight: normal;
}
.company-table th { width: 180px; color: var(--ink-light); letter-spacing: 0.14em; }
.company-table tr:last-child th,
.company-table tr:last-child td { border-bottom: 1px solid var(--line); }

.history li {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 24px;
  padding: 18px 0;
  font-size: 14px;
  border-bottom: 1px solid var(--line);
}
.history li:first-child { border-top: 1px solid var(--line); }
.history__year { color: var(--wood); font-family: var(--serif); letter-spacing: 0.14em; }

.staff {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 48px 40px;
}
.staff__item { border-top: 1px solid var(--line); padding-top: 24px; }
.staff__role { font-size: 11px; letter-spacing: 0.2em; color: var(--wood); }
.staff__name {
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: 0.14em;
  margin: 12px 0 14px;
}
.staff__text { font-size: 13.5px; color: var(--ink-light); line-height: 2.1; }

/* ---------- フォーム ---------- */
.form-note {
  background: var(--cream);
  border-left: 2px solid var(--wood);
  padding: 24px 28px;
  font-size: 13px;
  line-height: 2.1;
  margin-bottom: 64px;
}
.form-row { margin-bottom: 40px; }
.form-row label {
  display: block;
  font-size: 13px;
  letter-spacing: 0.12em;
  margin-bottom: 14px;
}
.form-row .req {
  font-size: 10.5px;
  color: var(--wood);
  border: 1px solid var(--wood);
  padding: 2px 8px;
  margin-left: 12px;
  letter-spacing: 0.1em;
}
.form-row input,
.form-row textarea,
.form-row select {
  width: 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  padding: 12px 2px;
  font-family: inherit;
  font-size: 15px;
  color: var(--ink);
  border-radius: 0;
  transition: border-color 0.4s;
}
.form-row textarea { min-height: 160px; resize: vertical; }
.form-row input:focus,
.form-row textarea:focus,
.form-row select:focus { outline: none; border-bottom-color: var(--wood); }
.form-submit { text-align: center; margin-top: 72px; }

/* お問い合わせ先の並び */
.contact-info {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  text-align: center;
  padding-top: 8px;
}
.contact-info dt {
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--wood);
  margin-bottom: 14px;
}
.contact-info dd { margin: 0; font-family: var(--serif); font-size: 17px; letter-spacing: 0.08em; }

/* ---------- スクロールで浮かび上がる ---------- */
.fade {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.fade.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .fade { opacity: 1; transform: none; transition: none; }
  .hero__img { animation: none; }
}

/* =========================================================
   スマートフォン
   ========================================================= */
@media (max-width: 820px) {
  :root { --pad-section: 64px; }

  body { font-size: 14.5px; }

  .header { padding: 18px 20px; }
  .header__logo { font-size: 17px; }

  /* ナビをドロワーに */
  .burger {
    display: block;
    width: 28px; height: 18px;
    position: relative;
    background: none; border: 0; padding: 0;
    z-index: 110;
    cursor: pointer;
  }
  .burger span {
    position: absolute;
    left: 0;
    width: 100%; height: 1px;
    background: var(--ink);
    transition: transform 0.4s, opacity 0.3s, background 0.4s;
  }
  .burger span:nth-child(1) { top: 0; }
  .burger span:nth-child(2) { top: 50%; }
  .burger span:nth-child(3) { bottom: 0; }
  .burger.is-open span { background: var(--ink); }
  .burger.is-open span:nth-child(1) { transform: translateY(8px) rotate(20deg); }
  .burger.is-open span:nth-child(2) { opacity: 0; }
  .burger.is-open span:nth-child(3) { transform: translateY(-9px) rotate(-20deg); }

  .gnav {
    position: fixed;
    inset: 0;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.5s, visibility 0.5s;
    z-index: 105;
  }
  .gnav.is-open { opacity: 1; visibility: visible; }
  .gnav ul { flex-direction: column; gap: 32px; text-align: center; }
  .gnav a { font-size: 15px; font-family: var(--serif); letter-spacing: 0.2em; }

  .hero__copy { padding-left: 28px; padding-right: 28px; }
  /* スマホでは「いい家は、静かです。」が2行に割れるので、画面幅に追従させて1行に収める */
  .hero__copy h1 {
    font-size: 6.2vw;
    line-height: 1.95;
    letter-spacing: 0.1em;
  }
  .hero__copy p { font-size: 3.5vw; letter-spacing: 0.14em; margin-top: 22px; }

  .works-grid,
  .works-grid--2col { grid-template-columns: 1fr; gap: 40px; }
  .promise { grid-template-columns: 1fr; gap: 40px; }
  .message { grid-template-columns: 1fr; gap: 36px; }
  .message__img img { aspect-ratio: 4 / 3; }

  .flow-list li { grid-template-columns: 60px 1fr; gap: 16px; padding: 24px 0; }
  .news li { grid-template-columns: 1fr; gap: 6px; }

  .full-photo { height: 46vh; min-height: 240px; }

  /* 下層ページ */
  .page-head { padding: 130px 0 56px; }
  .page-head__ja { font-size: 23px; }
  .work-hero { margin-top: 64px; }
  .work-hero img { height: 44vh; min-height: 240px; }
  .work-title { font-size: 24px; }
  .work-sub { font-size: 15px; }
  .work-data th, .company-table th { width: 100px; font-size: 12.5px; }
  .work-data, .company-table { font-size: 13px; }
  .photo-duo { grid-template-columns: 1fr; gap: 32px; }
  .voice { padding: 36px 26px; }
  .staff { grid-template-columns: 1fr; gap: 32px; }
  .history li { grid-template-columns: 80px 1fr; gap: 12px; }
  .contact-info { grid-template-columns: 1fr; gap: 28px; }
  .work-nav { gap: 28px; flex-wrap: wrap; }
  .heading { font-size: 22px; margin-bottom: 28px; }
  .lead { font-size: 15.5px; line-height: 2.3; }
  .btn { padding: 18px 44px; }

  .footer__top { flex-direction: column; gap: 32px; }
}
