/* 株式会社いちわり
   レイアウト：PCでは左に固定のサイドバー（ロゴ・タイルのメニュー・問い合わせボタン）、右に本文。
   本文はあたたかい生成り色の地に、ネイビーの見出しと、斜めに切った帯を重ねる。
   見出しは「小さな飾り＋日本語＋英字」を中央にそろえる。 */
:root {
  --navy: #1f3a60;
  --navy-deep: #152a47;
  --navy-soft: #50678a;
  --sky: #e7eef6;
  --sky-line: #cfdbea;
  --bg: #f6f4ef;
  --paper: #ffffff;
  --text: #2a333f;
  --sub: #6b7481;
  --line: #e2ddd3;
  --gold: #c99a45;

  --font-jp: "Zen Kaku Gothic New", "Hiragino Kaku Gothic ProN", "Noto Sans JP", sans-serif;
  --font-en: "Roboto Condensed", "Arial Narrow", sans-serif;

  --side: 280px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-jp);
  font-weight: 500;
  color: var(--text);
  background: var(--bg);
  line-height: 2;
  letter-spacing: 0.08em;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; }

a { color: var(--navy); }

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

/* ---------- サイドバー ---------- */
.side {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--side);
  padding: 36px 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  overflow-y: auto;
  background: var(--bg);
  z-index: 30;
}

.logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--navy);
}

.logo svg { width: 64px; height: 64px; }

.logo-name { font-size: 22px; font-weight: 700; letter-spacing: 0.14em; }

.logo-en {
  font-family: var(--font-en);
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--navy-soft);
  margin-top: -6px;
}

.side-lead {
  font-size: 11px;
  text-align: center;
  color: var(--sub);
  line-height: 1.7;
}

.tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 14px 6px 10px;
  background: var(--paper);
  border-radius: 6px;
  text-decoration: none;
  color: var(--navy);
  font-size: 12px;
  letter-spacing: 0.06em;
  transition: background 0.2s ease;
}

.tile:hover, .tile[aria-current="page"] { background: var(--sky); }

.tile svg { width: 30px; height: 30px; }

.side-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px;
  border-radius: 6px;
  background: var(--navy);
  color: #fff;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
}

.side-cta:hover { background: var(--navy-deep); }

.side-info {
  font-size: 11px;
  color: var(--sub);
  line-height: 1.8;
  border-top: 1px solid var(--line);
  padding-top: 14px;
}

.side-info dt { color: var(--navy); font-weight: 700; }

.side-info dd { margin-bottom: 6px; }

/* 狭い画面の上部バー */
.topbar { display: none; }

/* ---------- 本文 ---------- */
.main { margin-left: var(--side); min-width: 0; overflow-x: clip; }

.inner {
  max-width: 1000px;
  margin: 0 auto;
  padding-left: max(24px, env(safe-area-inset-left, 0px));
  padding-right: max(24px, env(safe-area-inset-right, 0px));
}

/* ヒーロー */
.hero {
  position: relative;
  padding: 44px 0 0;
  min-height: 600px;
}

.hero-copy {
  position: relative;
  z-index: 2;
  padding-left: 32px;
}

.hero-copy h1 {
  font-size: clamp(30px, 3.6vw, 44px);
  line-height: 1.6;
  letter-spacing: 0.16em;
  color: var(--navy);
  font-weight: 700;
}

.hero-copy .en {
  font-family: var(--font-en);
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--navy-soft);
  margin-top: 6px;
}

.hero-visual {
  position: relative;
  margin: -40px 0 0 120px;
  height: 460px;
  background: linear-gradient(160deg, #2b4c78 0%, var(--navy) 55%, var(--navy-deep) 100%);
  clip-path: polygon(0 34%, 100% 0, 100% 100%, 0 100%);
  border-radius: 0 0 0 4px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 0 40px 0 80px;
  overflow: hidden;
}

.hero-visual .screen { width: min(560px, 100%); display: block; }

.hero-note {
  position: absolute;
  right: 0;
  bottom: -22px;
  background: var(--paper);
  padding: 10px 18px;
  font-size: 12px;
  color: var(--sub);
  border-radius: 4px 0 0 4px;
  display: flex;
  gap: 10px;
  align-items: center;
  z-index: 3;
}

.hero-note svg { width: 18px; height: 18px; flex: none; color: var(--navy); }

/* 見出し */
.heading {
  text-align: center;
  margin-bottom: 44px;
}

.heading .mark { display: block; margin: 0 auto 6px; width: 22px; height: 14px; }

.heading h2 {
  font-size: clamp(22px, 2.6vw, 28px);
  color: var(--navy);
  font-weight: 700;
  letter-spacing: 0.14em;
  line-height: 1.6;
}

.heading .en {
  font-family: var(--font-en);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--text);
}

.heading.left { text-align: left; }

.heading.left .mark { margin-left: 0; }

/* セクション */
.section { padding: 110px 0; position: relative; }

.about { text-align: center; }

.about .label {
  font-family: var(--font-en);
  font-size: 11px;
  letter-spacing: 0.24em;
  color: var(--gold);
}

.about .label::before, .about .label::after { content: "|"; margin: 0 14px; color: var(--gold); }

.about h2 {
  font-size: clamp(22px, 2.6vw, 28px);
  color: var(--navy);
  font-weight: 700;
  letter-spacing: 0.14em;
  line-height: 1.7;
  margin: 18px 0 36px;
}

.about p { font-size: 14px; line-height: 2.3; }

.about p + p { margin-top: 1.6em; }

/* 斜めの帯 */
.slant { position: relative; }

.slant::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--sky);
  clip-path: polygon(0 70px, 100% 0, 100% 100%, 0 100%);
  z-index: -1;
}

.slant .inner { padding-top: 60px; }

/* 特徴 */
.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
}

.feature { text-align: center; }

.feature .pic {
  background: var(--paper);
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  margin-bottom: 20px;
}

.feature .pic svg { width: 62%; height: auto; }

.feature h3 { font-size: 16px; color: var(--navy); margin-bottom: 10px; letter-spacing: 0.1em; }

.feature p { font-size: 13px; text-align: left; line-height: 2; }

/* ボタン */
.more-btn {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  min-width: 240px;
  padding: 14px 18px 14px 40px;
  background: var(--navy);
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  font-size: 13px;
  letter-spacing: 0.14em;
  transition: background 0.2s ease;
}

.more-btn:hover { background: var(--navy-deep); }

.more-btn::after { content: "→"; font-family: var(--font-en); }

.center { text-align: center; margin-top: 52px; }

/* サービス（左に文、右にタイル） */
.services-block {
  background: var(--paper);
  border-radius: 0 28px 28px 0;
  margin-right: 24px;
  padding: 80px 0;
}

.services-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.3fr;
  gap: 56px;
  align-items: center;
}

.services-grid p { font-size: 14px; margin-bottom: 36px; }

.svc-tiles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.svc-tile {
  background: var(--sky);
  padding: 22px 14px 14px;
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
  gap: 14px;
  transition: background 0.2s ease;
}

.svc-tile:hover { background: var(--sky-line); }

.svc-tile .circle {
  width: 84px;
  height: 84px;
  margin: 0 auto;
  border-radius: 50%;
  background: var(--paper);
  display: grid;
  place-items: center;
  color: var(--navy);
}

.svc-tile .circle svg { width: 44px; height: 44px; }

.svc-tile .name {
  font-size: 13px;
  font-weight: 700;
  border-top: 1px solid var(--sky-line);
  padding-top: 10px;
  display: flex;
  justify-content: space-between;
  letter-spacing: 0.06em;
}

.svc-tile .name::after { content: "›"; color: var(--navy); }

/* 実績 */
.case {
  background: var(--paper);
  display: grid;
  grid-template-columns: 300px 1fr;
}

.case + .case { margin-top: 32px; }

.case-head {
  background: var(--navy);
  color: #fff;
  padding: 36px 30px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.case-head .tag {
  font-family: var(--font-en);
  font-size: 11px;
  letter-spacing: 0.2em;
  color: #b9cbe2;
}

.case-head h3 { font-size: 19px; line-height: 1.7; letter-spacing: 0.1em; }

.case-head ul { list-style: none; margin-top: auto; display: flex; flex-wrap: wrap; gap: 6px; }

.case-head li {
  font-size: 11px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 999px;
  padding: 0 10px;
}

.case-body { padding: 32px 36px; display: grid; gap: 20px; min-width: 0; }

.case-body h4 {
  font-size: 12px;
  color: var(--navy);
  letter-spacing: 0.14em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.case-body h4::before { content: ""; width: 14px; height: 1px; background: var(--gold); }

.case-body p { font-size: 14px; }

/* 進め方 */
.flow {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0;
  background: var(--paper);
}

.flow li {
  padding: 32px 24px;
  position: relative;
}

.flow li + li { border-left: 1px dashed var(--line); }

.flow .step {
  font-family: var(--font-en);
  font-size: 12px;
  letter-spacing: 0.2em;
  color: var(--gold);
}

.flow .num {
  font-family: var(--font-en);
  font-size: 40px;
  font-weight: 300;
  color: var(--navy);
  line-height: 1.2;
  display: block;
  margin-bottom: 12px;
}

.flow h3 { font-size: 15px; color: var(--navy); margin-bottom: 8px; letter-spacing: 0.1em; }

.flow p { font-size: 13px; }

/* よくある質問 */
.faq { display: grid; gap: 10px; max-width: 800px; margin: 0 auto; }

.faq details { background: var(--paper); padding: 20px 26px; }

.faq summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  gap: 16px;
  align-items: baseline;
  font-weight: 700;
  color: var(--navy);
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::before { content: "Q"; font-family: var(--font-en); font-size: 18px; color: var(--gold); }

.faq summary::after { content: "+"; margin-left: auto; font-family: var(--font-en); }

.faq details[open] summary::after { content: "−"; }

.faq details p { margin: 10px 0 0 30px; font-size: 14px; }

/* 下層ページの見出し */
.page-head {
  position: relative;
  padding: 72px 0 90px;
}

.page-head::before {
  content: "";
  position: absolute;
  inset: 0 0 0 0;
  background: var(--sky);
  clip-path: polygon(0 0, 100% 0, 100% 62%, 0 100%);
  z-index: -1;
}

.page-head .en {
  font-family: var(--font-en);
  font-size: 12px;
  letter-spacing: 0.22em;
  color: var(--gold);
}

.page-head h1 {
  font-size: clamp(26px, 3.2vw, 36px);
  color: var(--navy);
  letter-spacing: 0.16em;
  line-height: 1.6;
  margin-top: 4px;
}

.page-head p { font-size: 14px; margin-top: 14px; max-width: 40em; }

.crumb { font-size: 11px; color: var(--sub); margin-bottom: 18px; }

.crumb a { color: var(--sub); }

/* サービス詳細 */
.svc-detail {
  background: var(--paper);
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 40px;
  padding: 44px;
  scroll-margin-top: 24px;
}

.svc-detail + .svc-detail { margin-top: 24px; }

.svc-detail .head { color: var(--navy); }

.svc-detail .circle {
  width: 110px;
  height: 110px;
  border-radius: 50%;
  background: var(--sky);
  display: grid;
  place-items: center;
  margin-bottom: 18px;
}

.svc-detail .circle svg { width: 56px; height: 56px; }

.svc-detail h2 { font-size: 20px; letter-spacing: 0.12em; line-height: 1.6; }

.svc-detail .no { font-family: var(--font-en); font-size: 12px; letter-spacing: 0.2em; color: var(--gold); }

.svc-detail h3 {
  font-size: 13px;
  color: var(--navy);
  margin: 22px 0 6px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--line);
}

.svc-detail h3:first-child { margin-top: 0; }

.svc-detail ul { padding-left: 1.2em; font-size: 14px; }

.svc-detail p { font-size: 14px; }

/* 会社概要 */
.company-table { width: 100%; border-collapse: collapse; background: var(--paper); }

.company-table th, .company-table td {
  text-align: left;
  vertical-align: top;
  padding: 22px 28px;
  border-bottom: 1px solid var(--line);
  font-size: 14px;
}

.company-table th { width: 12em; color: var(--navy); background: #fbfaf7; }

/* お問い合わせ */
.contact-box { background: var(--paper); padding: 44px; }

.contact-box .note { font-size: 13px; color: var(--sub); margin-bottom: 20px; }

.contact-form { width: 100%; height: 1250px; border: 0; display: block; }

/* 下部の問い合わせ帯 */
.cta {
  position: relative;
  color: #fff;
  padding: 120px 0 90px;
  margin-top: 40px;
}

.cta::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--navy);
  clip-path: polygon(0 60px, 100% 0, 100% 100%, 0 100%);
  z-index: -1;
}

.cta .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  flex-wrap: wrap;
}

.cta .en { font-family: var(--font-en); font-size: 12px; letter-spacing: 0.22em; color: #b9cbe2; }

.cta h2 { font-size: clamp(20px, 2.4vw, 26px); letter-spacing: 0.12em; line-height: 1.7; }

.cta .more-btn { background: var(--paper); color: var(--navy); }

.cta .more-btn:hover { background: var(--sky); }

/* フッター */
.footer {
  background: var(--navy-deep);
  color: #aebcd0;
  font-size: 12px;
  padding: 36px 0;
}

.footer .inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 14px; }

.footer a { color: #dfe7f1; text-decoration: none; margin-right: 22px; }

/* ---------- 画面幅ごとの調整 ---------- */
@media (max-width: 1080px) {
  .hero-visual { margin-left: 40px; }
  .services-grid { grid-template-columns: 1fr; gap: 32px; }
}

@media (max-width: 960px) {
  :root { --side: 0px; }

  .topbar {
    display: flex;
    position: sticky;
    top: env(safe-area-inset-top, 0px);
    z-index: 40;
    align-items: center;
    justify-content: space-between;
    height: 60px;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
  }

  .topbar .logo { flex-direction: row; gap: 8px; }

  .topbar .logo svg { width: 34px; height: 34px; }

  .topbar .logo-name { font-size: 17px; }

  .menu-toggle {
    background: var(--navy);
    color: #fff;
    border: 0;
    border-radius: 4px;
    padding: 8px 14px;
    font: inherit;
    font-size: 12px;
    cursor: pointer;
  }

  .side {
    display: none;
    top: 60px;
    width: 100%;
    padding: 20px max(16px, env(safe-area-inset-left, 0px)) 28px;
    border-bottom: 1px solid var(--line);
    bottom: auto;
    max-height: calc(100vh - 60px);
  }

  .side.open { display: flex; }

  .side > .logo, .side > .side-lead { display: none; }

  .tiles { grid-template-columns: repeat(3, 1fr); }

  .main { margin-left: 0; }

  .hero { min-height: 0; padding-top: 32px; }

  .hero-copy { padding-left: 0; }

  .hero-visual { margin: 24px 0 0; height: 340px; padding: 0 16px 0 40px; }

  .features { grid-template-columns: 1fr; gap: 40px; }

  .services-block { margin-right: 0; border-radius: 0; }

  .case { grid-template-columns: 1fr; }

  .flow { grid-template-columns: 1fr 1fr; }

  .flow li:nth-child(3) { border-left: 0; }

  .flow li:nth-child(n+3) { border-top: 1px dashed var(--line); }

  .svc-detail { grid-template-columns: 1fr; gap: 20px; padding: 32px 24px; }
}

@media (max-width: 600px) {
  body { font-size: 14px; letter-spacing: 0.05em; }
  .section { padding: 80px 0; }
  .svc-tiles { grid-template-columns: 1fr 1fr; }
  .tiles { grid-template-columns: 1fr 1fr; }
  .flow { grid-template-columns: 1fr; }
  .flow li + li { border-left: 0; border-top: 1px dashed var(--line); }
  .case-body { padding: 26px 22px; }
  .company-table th, .company-table td { display: block; width: auto; padding: 12px 18px; }
  .company-table th { border-bottom: 0; padding-bottom: 0; background: none; }
  .contact-box { padding: 28px 18px; }
  .about p br { display: none; }
  .hero-copy h1 { letter-spacing: 0.1em; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .tile, .more-btn, .svc-tile { transition: none; }
}

.nb { display: inline-block; }

@media (max-width: 960px) {
  .hero-note { position: static; margin: 0; border-radius: 0; }
}
