@charset "utf-8";

body,
h1,
h2,
h3,
h4,
h5,
h6,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
  padding: 0;
  list-style: none;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 100%;
}

:root {
  --side-padding: clamp(1rem, 0.167rem + 2.78vw, 1.5rem);

  --color-main: #2b1d14;
  --color-accent: #007bff;
  --color-white: #ffffff;
  --color-font-bk: #333;
  --color-border-gy: #ccc;
  --color-bg-light: #f5f5f5;
  --color-bg: #f2ece8;
  --gradient-light: linear-gradient(135deg, #f9f9f9 0%, #e0e0e0 100%);
  --gradient-dark: linear-gradient(135deg, #7a5f4a 0%, #4e392a 35%, #2b1d14 100%);
  --gradient-current: linear-gradient(135deg, #af9684 0%, #8b7463 35%, #655143 100%);
}

body {
  font-size: 1rem;
  line-height: 1.75;
  font-family: YuGothic, "Yu Gothic", "游ゴシック", "游ゴシック体", sans-serif;
  font-weight: 500;
  color: var(--color-font-bk);
  background-color: var(--color-white);
}

h1 {
  font-size: clamp(1.75rem, 2.78vw + 0.92rem, 2.25rem);
  line-height: 1.3;
}

h2 {
  font-size: clamp(1.5rem, 1.39vw + 1.08rem, 1.75rem);
  line-height: 1.4;
}

h3 {
  font-size: clamp(1.25rem, 0.69vw + 1.04rem, 1.375rem);
  line-height: 1.5;
}

h4 {
  font-size: 1.125rem;
  line-height: 1.6;
}

img {
  max-width: 100%;
  height: auto;
  vertical-align: bottom;
}

a {
  color: inherit;
  text-decoration: none;
  transition: all 0.3s ease;
  -webkit-tap-highlight-color: transparent;
}

button {
  -webkit-tap-highlight-color: transparent;
}

@media(any-hover: hover) {
  body a:hover {
    color: var(--color-accent);
  }
}


address {
  font-style: normal;
}

input,
button,
textarea {
  -webkit-appearance: none;
  border-radius: 0;
}

input,
textarea {
  font-size: 16px;
}

.l-section {
  padding-block: clamp(3.75rem, 8vw, 6.25rem);
}

/* 2. 背景色があるセクション（クラスを繋げて記述して優先度を上げる） */
.l-section.is-bg-color {
  /* ←ここを繋げる！htmlは必ず半角スペース開ける<section class="l-section is-bg-color"> ... </section> */
  background-color: var(--color-bg-light);
  padding-block: clamp(2.5rem, 5vw, 5rem);
}

.l-section:not(.is-bg-color)+.l-section:not(.is-bg-color) {
  padding-top: 0;
}

.l-inner {
  max-width: 1080px;
  margin-inline: auto;
  padding-inline: var(--side-padding);
  width: 100%;
  /* 念のため追加しておくと安定 */
}

.l-inner--960 {
  max-width: 960px;
}

.l-inner--800 {
  max-width: 800px;
}

.flex {
  display: flex;
}

.flex-center {
  display: flex;
  justify-content: center;
  align-items: center;
}

.flex-between {
  display: flex;
  justify-content: space-between;
}

.items-center {
  align-items: center;
}

/* --- 共通：カードレイアウト用グリッド --- */
.c-grid {
  display: grid;
  /* 変数が無くても320pxで動くように直接指定を優先させます */
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr));
  gap: 40px 24px;
  justify-content: center;
}

/* --- 共通：カード単体のスタイル --- */
.c-card {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  max-width: 400px;
  /* 巨大化防止 */
  margin-inline: auto;
  /* text-decoration: none; リンクとして使う場合のため */
  color: inherit;
  border: 1px solid var(--color-border-gy);
  /* 線を追加 */
  background: var(--color-white);
  padding: 0;
  /* 画像を端までくっつけるなら0 */
  overflow: hidden;
  transition: all 0.3s ease;
}

@media(any-hover: hover) {
  .c-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
    border-color: var(--color-main);
  }
}

.c-card__image {
  width: 100%;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background-color: #eee;
  /* 画像がない時の保険 */
}

.c-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.c-card__content {
  display: flex;
  flex-direction: column;
  padding: 1.25rem;
  text-align: center;
  flex-grow: 1;
  /* 内容が少なくてもカードの下端を揃える高さを揃えるために必須 */
}

.c-card__title {
  font-size: clamp(1.15rem, 0.917rem + 0.69vw, 1.25rem);
  margin-bottom: 1.25rem;
  font-weight: bold;
  border-bottom: 2px solid var(--color-main);
  /* 実績ページ風の線を共通化してもOK */
  display: inline-block;
  padding-bottom: 5px;
}

.c-card__text {
  text-align: left;
  padding-inline: 6px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* header固定分の余白 今回115px */
.l-main {
  padding-top: 115px;
}


/* header固定　高さ115px */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 115px;
  background: var(--color-white);
  /* z-index: 1000; */
  z-index: 100;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.header-inner {
  max-width: 1080px;
  height: 100%;
  margin-inline: auto;
  padding-inline: var(--side-padding);
  position: relative;
  /* ← 将来事故防止 */
}

.logo a {
  display: flex;
  align-items: center;
}

.logo img {
  /* 480px以下で30px、1080px以上で40px、その間は可変 */
  height: clamp(30px, 1.6vw + 22px, 40px);
  width: auto;
  /* 画像がボヤけるのを防ぎ、アスペクト比を維持 */
  aspect-ratio: 240 / 40;
  object-fit: contain;
}

.header-top {
  padding-block: 15px;
}

.header-address dl {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.header-address .tel {
  font-size: 1.25rem;
  font-weight: bold;
  line-height: 1;
}

.header-address .time {
  font-size: 0.75rem;
}

.tel-icon img {
  height: 38px;
  /* ここで高さをコントロール */
  width: auto;
  /* 画像がぼやけないように、比率を維持して収める設定 */
  aspect-ratio: 30 / 48;
  object-fit: contain;
}


body.menu-open {
  overflow: hidden;
}

/* PCメニュー、初期化で必要 */
.menu {
  position: static;
}

.menu ul {
  padding-block: 0.5rem;
}

.menu li {
  width: 180px;
  line-height: 24px;
  text-align: center;
  border-left: 2px solid var(--color-border-gy);
}

.menu li:last-child {
  border-right: 2px solid var(--color-border-gy);
}

.menu li a {
  display: block;
  width: 100%;
  height: 100%;
  font-weight: bold;
}

/* ハンバーガー非表示 */
.menu-icon,
.overlay {
  display: none;
}

.current {
  background: var(--gradient-current);
  color: var(--color-white);
}

.site-footer {
  background: var(--color-bg);
  color: var(--color-font-bk);
  padding-top: 30px;
}

.footer-inner {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  /* 左・右の比率調整 */
  gap: clamp(1.25rem, -1.827rem + 6.41vw, 2.5rem);
  /* 40px～20px */
  align-items: center;
}

/* 左：ロゴ・住所 */
.footer-left {
  text-align: left;
}

.footer-logo {
  display: inline-block;
  text-align: left;
  margin-bottom: 20px;
}

/* .footer-logo img {
  filter: brightness(0) invert(1);
  ロゴが黒い場合、白抜きにする指定
} */

.company-name {
  font-size: 1.25rem;
  font-weight: bold;
  margin-bottom: 0.5rem;
}

.address,
.tel-fax,
.license {
  margin-bottom: 0.5rem;
}

.tel-fax {
  font-size: 1.25rem;
  font-weight: bold;
}

.tel {
  margin-right: 0.5rem;
}

.sns-icons {
  display: flex;
  gap: 1.75rem;
  padding-top: 20px;
}

.sns-icons a {
  display: flex;
  align-items: center;
  justify-content: center;
  /* 背景と枠線を消す */
  background: none;
  border-radius: 0;
  /* クリックしやすくするために、透明な「押ししろ」だけ残す */
  width: 32px;
  height: 32px;
  transition: opacity 0.3s;
}

@media (any-hover: hover) {
  .sns-icons a:hover {
    opacity: 0.7;
  }
}

.sns-icons a:active {
  opacity: 0.5; 
  transition: none; 
}

/* SVGのサイズと色を一括管理 */
.icon-svg {
  width: 1.75rem;
  height: 1.75rem;
  fill: #000;
}

.sr-only {
  display: none;
}

/* ナビゲーションを2列に */
.footer-nav-grid {
  display: grid;
  grid-template-columns: max-content max-content;
  gap: 10px 30px;
}

.footer-nav-grid a::before {
  content: "> ";
}

.footer-nav-grid a {
  display: inline-block;
  /* paddingを効かせるため */
  padding-block: 5px;
  /* 上下に5pxずつ余白を作って、クリック範囲を広げる */
  color: var(--color-font-bk);
  font-weight: bold;
}

.copyright {
  background: var(--gradient-dark);
  color: var(--color-white);
  padding-block: 0.5rem;
  text-align: center;
  font-size: 0.875rem;
  margin-top: 40px;
}

/* ボタンの基本スタイル */
.to-top {
  position: fixed;
  right: 25px;
  bottom: 25px;
  width: 50px;
  height: 50px;
  background-color: #0078d4;
  /* フッターカラーにより変える */
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1100;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  transition: background-color 0.3s, transform 0.3s, opacity 0.3s, visibility 0.3s;
  /* --- 途中から表示させる（CSS Scroll-driven Animations） --- */
  opacity: 0;
  visibility: hidden;
  /* サファリが対応したら下記適用その１
  animation: fade-in-scroll linear forwards;
  animation-timeline: scroll();
  animation-range: 200px 500px; */
}

.to-top.is-show {
  opacity: 1;
  visibility: visible;
}

/* 矢印アイコン（SVG）のサイズ調整 */
.to-top svg {
  width: 24px;
  height: 24px;
  transition: transform 0.3s ease;
}

/* サファリが対応したら下記適用、表示用のアニメーションその２
@keyframes fade-in-scroll {
  to {
    opacity: 1;
    visibility: visible;
  }
} */

/* ホバー時の演出：少し浮き上がり、矢印がピョコっと動く */
@media (any-hover: hover) {
  .to-top:hover {
    background-color: #2c5d91;
    transform: translateY(-5px);
  }

  .to-top:hover svg {
    transform: translateY(-2px);
  }
}

.to-top:active {
  opacity: 0.8;
  transition: none;
}

/* ===== SP表示 =====ヘッダー70px、パディング同値で */
@media screen and (max-width: 768px) {
  .tel-link {
    color: inherit !important; 
    text-decoration: none !important;
  }
  
  .site-header {
    height: 70px;
  }

  .l-main {
    padding-top: 70px;
  }

  .header-address {
    display: none;
    /* スマホでは電話を隠す */
  }

  /* ハンバーガー */
  .menu-icon {
    display: inline-block;
    width: 40px;
    height: 40px;
    cursor: pointer;
    /* z-index: 1002; */
    z-index: 130;
    touch-action: manipulation;
    /* iOS用 */
  }

  .menu-icon span {
    display: block;
    height: 4px;
    margin: 6px 0;
    background: #333;
    border-radius: 2px;
    transition: 0.4s;
  }

  /* 三本線のアニメーション（直後の兄弟ではないので ~ を使用） */
  #menu-toggle:checked~.header-top .menu-icon span:nth-child(1) {
    transform: translateY(10px) rotate(45deg);
  }

  #menu-toggle:checked~.header-top .menu-icon span:nth-child(2) {
    opacity: 0;
  }

  #menu-toggle:checked~.header-top .menu-icon span:nth-child(3) {
    transform: translateY(-10px) rotate(-45deg);
  }

  /* overlay、高さtopヘッダーに合わせる */
  .overlay {
    display: block;
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    bottom: 0;
    /* inset: 0; */
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    pointer-events: none;
    transition: 0.4s;
    /* z-index: 1000; */
    z-index: 110;
  }

  #menu-toggle:checked~.overlay {
    opacity: 1;
    pointer-events: auto;
  }

  /* スライドメニュー */
  .menu {
    position: fixed;
    top: 70px;
    /* headerの高さ分下げる */
    right: 0;
    bottom: 0;
    width: 250px;
    background: var(--color-white);
    transform: translateX(100%);
    transition: transform 0.4s ease;
    /* z-index: 1001; */
    z-index: 120;
  }

  #menu-toggle:checked~.menu {
    transform: translateX(0);
  }

  .menu ul {
    display: block;
    padding: 20px 0 40px;
  }

  /* bottom: 0;は入れておく（親の影響防止） */
  .menu li {
    margin-bottom: 0;
    width: 100%;
    text-align: center;
  }

  .menu a {
    padding-block: 20px;
    border-bottom: 1px solid var(--color-border-gy);
  }

  .footer-inner {
    display: flex;
    flex-direction: column;
    /* ↓ここを center にすることで、中身のブロックを中央に */
    align-items: center;
    gap: 40px;
    text-align: center;
    /* ナビなどの全体の並びも中央寄りにする場合 */
  }

  .footer-left {
    /* ↓ここがポイント：テキストは左揃えを維持 */
    text-align: left;
    /* 必要であれば、ブロックが広がりすぎないように幅を固定 */
    width: fit-content;
  }

  .footer-nav-grid {
    /* ナビも中央に寄せたい場合はこれ */
    justify-content: center;
    text-align: left;
    /* ナビの文字自体は左揃え */
  }

  .footer-logo {
    display: block;
    /* inline-blockからblockに変更 */
    margin-inline: auto;
    /* 左右の余白を自動にして中央へ */
    width: fit-content;
    /* ロゴのサイズに合わせる */
  }

  .sns-icons {
    /* ↓横一列のアイコン全体を中央に寄せる */
    justify-content: center;
  }
}

@media screen and (max-width: 480px) {
  .site-header {
    height: 60px;
  }

  .l-main {
    padding-top: 60px;
  }

  .header-top {
    padding-block: 10px;
  }

  .overlay {
    top: 60px;
  }

  .menu {
    top: 60px;
  }

  /* --- フッター --- */
  .footer-nav-grid {
    grid-template-columns: 1fr;
  }

  .footer-nav-grid a {
    display: block;
    /* 横幅いっぱいをリンク範囲にする */
    width: 100%;
    /* 念のため幅100%を明示 */
    text-align: left;
    /* 文字は左寄せ */
  }

  .tel,
  .fax {
    display: block;
    /* 電話とFAXを縦に並べて */
    margin-bottom: 0.5rem;
  }

  .to-top {
    right: 15px;
    bottom: 15px;
    width: 45px;
    height: 45px;
  }
}