/* =========================================================
   うしくウェブ工房 共通スタイル
   色・文字サイズ・余白はここ(:root)の変数を変えれば全体に反映されます。
   ========================================================= */
:root {
  /* 色 */
  --color-bg: #f7f3ea;          /* 生成り色の背景 */
  --color-surface: #fffdf8;     /* カード・表の背景 */
  --color-text: #363636;        /* 本文(濃い灰色) */
  --color-text-sub: #5c5a55;    /* 補足の文字 */
  --color-border: #e2dccd;      /* 罫線 */
  --color-accent: #2c6e6a;      /* アクセント(霞ヶ浦の青緑) */
  --color-accent-dark: #1f5551;
  --color-accent-soft: #e3eeec; /* アクセントの淡い色 */
  --color-line: #06c755;        /* LINEの緑(LINEボタン専用) */
  --color-line-dark: #05a647;
  --color-placeholder: #d9d6cf; /* 仮の画像枠(グレー) */

  /* 文字 */
  --font-base: "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Noto Sans JP",
    "Yu Gothic", "YuGothic", "Meiryo", sans-serif;
  --fs-small: 0.9375rem;  /* 15px:注記など */
  --fs-body: 1.0625rem;   /* 17px:本文 */
  --fs-lead: 1.125rem;    /* 18px:リード文 */
  --fs-h3: 1.1875rem;     /* 19px */
  --fs-h2: 1.5rem;        /* 24px */
  --fs-h1: 1.75rem;       /* 28px:スマホのヒーロー見出し */
  --fs-h1-pc: 2.25rem;    /* 36px:PCのヒーロー見出し */
  --lh-body: 1.9;
  --lh-heading: 1.5;

  /* 余白・形 */
  --space-xs: 0.5rem;
  --space-s: 1rem;
  --space-m: 1.5rem;
  --space-l: 2.5rem;
  --space-xl: 4rem;
  --radius: 10px;
  --content-width: 960px;
  --text-width: 40em;
  --bottom-bar-height: 80px;    /* スマホ:画面下のボタン帯の高さ分の余白 */
  --bottom-bar-height-pc: 150px; /* PC:右下に縦に並ぶボタン2つ分の余白 */
}

/* ---------- 基本 ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-base);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-accent);
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--color-accent-dark);
}

h1,
h2,
h3 {
  line-height: var(--lh-heading);
  margin: 0 0 var(--space-s);
}

p {
  margin: 0 0 var(--space-s);
}

ul,
ol {
  margin: 0 0 var(--space-s);
  padding-left: 1.4em;
}

:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

/* 画面には出さず、読み上げソフトには読ませる */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -9999px;
}

.skip-link:focus {
  left: var(--space-s);
  top: var(--space-s);
  z-index: 100;
  background: var(--color-surface);
  padding: var(--space-xs) var(--space-s);
}

.container {
  width: 100%;
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0 var(--space-s);
}

/* ---------- ヘッダー ---------- */
.site-header {
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  position: relative;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
}

.logo {
  white-space: nowrap;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-text);
  text-decoration: none;
  letter-spacing: 0.05em;
}

.logo:hover {
  color: var(--color-text);
}

.menu-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  font: inherit;
  font-size: var(--fs-small);
  font-weight: 700;
  color: var(--color-text);
  background: none;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 0.35em 0.8em;
  cursor: pointer;
  min-height: 44px;
}

.menu-toggle-icon,
.menu-toggle-icon::before,
.menu-toggle-icon::after {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  position: relative;
}

.menu-toggle-icon::before,
.menu-toggle-icon::after {
  content: "";
  position: absolute;
  left: 0;
}

.menu-toggle-icon::before {
  top: -6px;
}

.menu-toggle-icon::after {
  top: 6px;
}

.site-nav {
  display: none;
}

.site-nav.is-open {
  display: block;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 50;
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06);
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: var(--space-xs) 0;
}

.site-nav a {
  display: block;
  padding: 0.75em var(--space-s);
  color: var(--color-text);
  text-decoration: none;
  font-weight: 700;
}

.site-nav a:hover {
  background: var(--color-accent-soft);
}

/* ---------- セクション共通 ---------- */
.section {
  padding: var(--space-xl) 0;
}

.section:nth-of-type(even) {
  background: var(--color-surface);
}

.section-title {
  font-size: var(--fs-h2);
  text-align: center;
  margin-bottom: var(--space-l);
}

.section-title::after {
  content: "";
  display: block;
  width: 48px;
  height: 3px;
  background: var(--color-accent);
  margin: var(--space-xs) auto 0;
  border-radius: 2px;
}

.section-title small {
  display: block;
  font-size: var(--fs-small);
  font-weight: 400;
  color: var(--color-text-sub);
}

.text-block {
  max-width: var(--text-width);
  margin: 0 auto;
}

.note {
  font-size: var(--fs-small);
  color: var(--color-text-sub);
}

/* 仮の画像枠(写真が用意できたら img の src を差し替える) */
.ph {
  width: 100%;
  background: var(--color-placeholder);
  border-radius: var(--radius);
  aspect-ratio: 3 / 2;
  object-fit: cover;
}

/* ---------- ボタン ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4em;
  min-height: 52px;
  padding: 0.6em 1.4em;
  border-radius: 999px;
  border: 2px solid transparent;
  font-size: var(--fs-body);
  font-weight: 700;
  text-decoration: none;
  line-height: 1.4;
  text-align: center;
}

.btn-line {
  background: var(--color-line);
  color: #fff;
}

.btn-line:hover {
  background: var(--color-line-dark);
  color: #fff;
}

.btn-accent {
  background: var(--color-accent);
  color: #fff;
}

.btn-accent:hover {
  background: var(--color-accent-dark);
  color: #fff;
}

.btn-outline {
  background: var(--color-surface);
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.btn-outline:hover {
  background: var(--color-accent-soft);
}

.btn-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-s);
}

/* ---------- ヒーロー ---------- */
.hero {
  padding: var(--space-l) 0 var(--space-xl);
}

.hero-inner {
  display: grid;
  gap: var(--space-l);
}

.hero-title {
  font-size: var(--fs-h1);
  margin-bottom: var(--space-m);
}

.hero-title span {
  display: inline-block; /* 句の途中で改行しにくくする */
}

.hero-lead {
  font-size: var(--fs-lead);
  margin-bottom: var(--space-l);
}

.hero-lead strong {
  color: var(--color-accent-dark);
}

/* ---------- こんなお悩み ---------- */
.trouble-list {
  list-style: none;
  padding: 0;
  max-width: var(--text-width);
  margin: 0 auto;
  display: grid;
  gap: var(--space-s);
}

.trouble-list li {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-s) var(--space-s) var(--space-s) 3em;
  position: relative;
}

.trouble-list li::before {
  content: "";
  position: absolute;
  left: 1.1em;
  top: 1.35em;
  width: 0.8em;
  height: 0.45em;
  border-left: 3px solid var(--color-accent);
  border-bottom: 3px solid var(--color-accent);
  transform: rotate(-45deg);
}

/* ---------- 料金表(スマホはカード、PCは表) ---------- */
.price-table {
  width: 100%;
  border-collapse: collapse;
}

.price-table caption {
  text-align: left;
  font-size: var(--fs-small);
  color: var(--color-text-sub);
  padding-bottom: var(--space-xs);
}

.price-table thead {
  /* スマホでは見出し行を隠す(画面読み上げには残す) */
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.price-table tr {
  display: block;
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-m);
  margin-bottom: var(--space-s);
}

.price-table th,
.price-table td {
  display: block;
  padding: 0;
  text-align: left;
}

.price-table tbody th {
  font-size: var(--fs-h3);
  color: var(--color-accent-dark);
  margin-bottom: var(--space-xs);
}

.price-table .price {
  font-size: 1.5rem;
  font-weight: 700;
  margin-top: var(--space-xs);
}

.price-table .price small {
  font-size: var(--fs-small);
  font-weight: 400;
}

.price-note {
  margin-top: var(--space-m);
}

/* ---------- 選ばれる理由 ---------- */
.reason-list {
  display: grid;
  gap: var(--space-m);
}

.reason {
  background: var(--color-bg);
  border-radius: var(--radius);
  padding: var(--space-m);
  border-top: 4px solid var(--color-accent);
}

.reason h3 {
  font-size: var(--fs-h3);
}

.reason p {
  margin: 0;
}

/* ---------- 制作例 ---------- */
.works-list {
  display: grid;
  gap: var(--space-l);
}

.work-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
}

.work-card .ph {
  border-radius: 0;
  aspect-ratio: 4 / 3;
}

.work-card-body {
  padding: var(--space-m);
}

.work-card-label {
  display: inline-block;
  font-size: var(--fs-small);
  background: var(--color-accent-soft);
  color: var(--color-accent-dark);
  border-radius: 4px;
  padding: 0 0.6em;
  margin-bottom: var(--space-xs);
}

.work-card h3 {
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}

.work-card .btn {
  width: 100%;
  margin-top: var(--space-xs);
}

/* ---------- 制作の流れ ---------- */
.flow-list {
  list-style: none;
  padding: 0;
  max-width: var(--text-width);
  margin: 0 auto;
  counter-reset: flow;
}

.flow-list li {
  counter-increment: flow;
  position: relative;
  padding: 0 0 var(--space-m) 3.5em;
}

.flow-list li::before {
  content: counter(flow);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.2em;
  height: 2.2em;
  border-radius: 50%;
  background: var(--color-accent);
  color: #fff;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.flow-list li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 1.1em;
  top: 2.4em;
  bottom: 0.2em;
  width: 2px;
  background: var(--color-border);
}

.flow-list strong {
  display: block;
}

/* ---------- よくある質問 ---------- */
.faq-list {
  max-width: var(--text-width);
  margin: 0 auto;
}

.faq-item {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--space-m);
  margin-bottom: var(--space-s);
}

.faq-item dt {
  font-weight: 700;
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}

.faq-item dt::before {
  content: "Q.";
  color: var(--color-accent);
  margin-right: 0.4em;
}

.faq-item dd {
  margin: 0;
}

/* ---------- プロフィール ---------- */
.profile {
  display: grid;
  gap: var(--space-m);
  max-width: var(--text-width);
  margin: 0 auto;
  align-items: start;
}

.profile .ph {
  max-width: 200px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  margin: 0 auto;
}

.profile-name {
  font-weight: 700;
  font-size: var(--fs-h3);
  margin-bottom: var(--space-xs);
}

/* ---------- お問い合わせ ---------- */
.contact-box {
  max-width: var(--text-width);
  margin: 0 auto;
  background: var(--color-surface);
  border: 2px solid var(--color-accent);
  border-radius: var(--radius);
  padding: var(--space-l) var(--space-m);
}

.contact-box .btn-group {
  margin-bottom: var(--space-m);
}

.contact-item p {
  margin-bottom: var(--space-xs);
}

.contact-item + .contact-item {
  margin-top: var(--space-m);
}

.contact-item .btn {
  width: 100%;
}

/* ---------- フッター ---------- */
.site-footer {
  background: var(--color-text);
  color: #f2efe8;
  padding: var(--space-l) 0;
  /* 画面下のボタンがフッターの文字を隠さないよう、下に余白を足す */
  padding-bottom: calc(var(--space-l) + var(--bottom-bar-height) + env(safe-area-inset-bottom));
  font-size: var(--fs-small);
}

.site-footer a {
  color: #f2efe8;
}

.footer-name {
  font-size: var(--fs-h3);
  font-weight: 700;
  margin-bottom: var(--space-xs);
}

.footer-links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs) var(--space-m);
}

.copyright {
  margin: var(--space-m) 0 0;
  opacity: 0.8;
}

/* ---------- 画面下に常に出す相談ボタン(LINE・フォーム) ---------- */
/* スマホ・タブレット:画面下に横並びで半分ずつ */
.bottom-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  display: flex;
  gap: var(--space-xs);
  padding: 10px var(--space-s) calc(10px + env(safe-area-inset-bottom));
  background: rgba(247, 243, 234, 0.95);
  border-top: 1px solid var(--color-border);
}

.bottom-bar .btn {
  flex: 1 1 0;
  min-width: 0;
  min-height: 52px;
  padding: 0.5em 0.5em;
  white-space: nowrap;
}

/* =========================================================
   タブレット・PC(幅768px以上)
   ========================================================= */
@media (min-width: 768px) {
  :root {
    --space-xl: 5.5rem;
  }

  .hero {
    padding: var(--space-xl) 0;
  }

  .hero-title {
    font-size: var(--fs-h1-pc);
  }

  .btn-group {
    flex-direction: row;
    flex-wrap: wrap;
  }

  /* 料金表を通常の表に戻す */
  .price-table {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
  }

  .price-table thead {
    position: static;
    width: auto;
    height: auto;
    overflow: visible;
    clip: auto;
    display: table-header-group;
  }

  .price-table tr {
    display: table-row;
    border: 0;
    padding: 0;
    margin: 0;
    background: none;
  }

  .price-table th,
  .price-table td {
    display: table-cell;
    padding: var(--space-s) var(--space-m);
    border-bottom: 1px solid var(--color-border);
    vertical-align: top;
  }

  .price-table thead th {
    background: var(--color-accent);
    color: #fff;
    font-size: var(--fs-small);
  }

  .price-table tbody th {
    white-space: nowrap;
  }

  .price-table .price {
    text-align: right;
    white-space: nowrap;
    margin: 0;
  }

  .reason-list {
    grid-template-columns: repeat(2, 1fr);
  }

  /* 理由が奇数個のときは、最後のカードを横いっぱいにする */
  .reason:last-child:nth-child(odd) {
    grid-column: 1 / -1;
  }

  .works-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .profile {
    grid-template-columns: 180px 1fr;
  }

  .contact-box .btn-group {
    justify-content: center;
  }

  .contact-item .btn {
    width: auto;
    min-width: 280px;
  }
}

/* =========================================================
   PC(幅1024px以上):メニューを横並びに、ヒーローを2列に
   ========================================================= */
@media (min-width: 1024px) {
  .menu-toggle {
    display: none;
  }

  .site-nav,
  .site-nav.is-open {
    display: block;
    position: static;
    box-shadow: none;
    border: 0;
    background: none;
  }

  .site-nav ul {
    display: flex;
    gap: var(--space-xs);
    padding: 0;
  }

  .site-nav a {
    padding: 0.4em 0.7em;
    font-size: var(--fs-small);
    border-radius: var(--radius);
  }

  .hero-inner {
    grid-template-columns: 1.25fr 1fr;
    align-items: center;
  }

  /* 相談ボタンは画面右下に縦に2つ並べる */
  .bottom-bar {
    left: auto;
    right: var(--space-m);
    bottom: var(--space-m);
    flex-direction: column;
    padding: 0;
    background: none;
    border: 0;
  }

  .bottom-bar .btn {
    flex: none;
    padding: 0.6em 1.6em;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
  }

  .site-footer {
    padding-bottom: calc(var(--space-l) + var(--bottom-bar-height-pc));
  }
}

/* =========================================================
   制作サンプル・下層ページ用の部品
   ========================================================= */

/* 制作サンプルの上部に必ず出す帯(うしくウェブ工房のヘッダーを兼ねる) */
.sample-band {
  background: var(--color-accent);
  color: #fff;
  font-family: var(--font-base);
  font-size: var(--fs-small);
  line-height: 1.6;
}

.sample-band-inner {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 0.6rem var(--space-s);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem var(--space-s);
}

.sample-band-text {
  margin: 0;
  font-size: var(--fs-body);
  font-weight: 700;
}

.sample-band a {
  color: #fff;
  font-weight: 700;
}

.sample-band-logo {
  text-decoration: none;
  white-space: nowrap;
}

/* 制作サンプルの最後に出す、うしくウェブ工房からの案内 */
.works-cta {
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-base);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  padding: var(--space-xl) 0;
  border-top: 6px solid var(--color-accent);
}

.works-cta-inner {
  max-width: var(--text-width);
  margin: 0 auto;
  padding: 0 var(--space-s);
}

.works-cta-label {
  display: inline-block;
  font-size: var(--fs-small);
  background: var(--color-accent-soft);
  color: var(--color-accent-dark);
  border-radius: 4px;
  padding: 0 0.6em;
}

.works-cta h2 {
  font-family: var(--font-base);
  font-size: var(--fs-h2);
  color: var(--color-text);
  letter-spacing: 0;
}

.works-cta .btn-group {
  margin: var(--space-m) 0;
}

.works-cta a:not(.btn) {
  color: var(--color-accent);
}

/* 画面下のボタンがないページのフッター */
.site-footer--plain {
  padding-bottom: var(--space-l);
}

/* 下層ページの見出し */
.page-header {
  padding: var(--space-l) 0 var(--space-m);
}

.page-header h1 {
  font-size: var(--fs-h2);
  margin: 0;
}

/* 文章中心のページ(個人情報の取り扱いなど) */
.prose {
  max-width: var(--text-width);
  margin: 0 auto;
  padding-bottom: var(--space-xl);
}

.prose h2 {
  font-size: var(--fs-h3);
  margin-top: var(--space-l);
  padding-left: 0.6em;
  border-left: 4px solid var(--color-accent);
}

.prose .note {
  margin-top: var(--space-l);
}

@media (min-width: 768px) {
  .works-cta .btn-group {
    justify-content: flex-start;
  }

  .page-header h1 {
    font-size: 2rem;
  }
}
