/* ============================================================
   One Ism — 事例ページ 共通CSS（cases.css）
   ・index.html の世界観（Blueprint × モノクロ・罫線グリッド・縦組みラベル）を踏襲。
   ・3本（ryokan / school / auberge）から共通で読み込む（重複を避ける）。
   ・index.html 本体の <style> は触らない。本ファイルは事例ページ専用。
   ============================================================ */

:root {
  --bg:      #000000;
  --ink:     #F4F4F4;
  --ink-2:   #C2C2C2;
  --ink-3:   #6B6B6B;
  --ink-4:   #383838;
  --line:    #1C1C1C;
  --line-2:  #2A2A2A;
  --hair:    rgba(255,255,255,0.045);
  --maxw:    980px;
  --ease:    cubic-bezier(0.16, 1, 0.3, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg); color: var(--ink);
  font-family: "Shippori Mincho", "IBM Plex Sans", serif;
  font-weight: 400; line-height: 1.95; overflow-x: hidden;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  text-wrap: pretty; word-break: auto-phrase; line-break: strict;
  overflow-wrap: break-word; hanging-punctuation: allow-end;
}
::selection { background: var(--ink); color: #000; }
a { color: inherit; text-decoration: none; }
.mono { font-family: "IBM Plex Mono", monospace; }
:focus:not(:focus-visible) { outline: none; }
a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 2px;
}
@media (max-width: 680px) { .br-pc { display: none; } }

/* ---- 写真の世界観馴染ませ（index.html と同じ手法） ---- */
.ph-img {
  width: 100%; height: 100%; object-fit: cover; display: block;
  filter: grayscale(1) contrast(1.12) brightness(0.92);
}
.ph-veil { position: absolute; inset: 0; pointer-events: none; }
.ph-veil.soft {
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.35) 55%, rgba(0,0,0,0.72) 100%);
}
.ph-blue { position: absolute; inset: 0; pointer-events: none; }
.ph-blue::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(to right, rgba(255,255,255,0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(255,255,255,0.05) 1px, transparent 1px);
  background-size: 32px 32px;
}
.ph-tick { position: absolute; width: 12px; height: 12px; }
.ph-tick::before, .ph-tick::after { content: ""; position: absolute; background: rgba(244,244,244,0.55); }
.ph-tick::before { width: 12px; height: 1px; top: 0; left: 0; }
.ph-tick::after  { width: 1px; height: 12px; top: 0; left: 0; }
.ph-tick.tl { top: 14px; left: 14px; }
.ph-tick.tr { top: 14px; right: 14px; transform: scaleX(-1); }
.ph-tick.bl { bottom: 14px; left: 14px; transform: scaleY(-1); }
.ph-tick.br { bottom: 14px; right: 14px; transform: scale(-1,-1); }

/* ---- 固定の図面枠（sheet） ---- */
.sheet { position: fixed; inset: 0; z-index: 0; pointer-events: none; }
.sheet .border { position: absolute; inset: 22px; border: 1px solid var(--line-2); }
.sheet .tick { position: absolute; width: 9px; height: 9px; }
.sheet .tick::before, .sheet .tick::after { content: ""; position: absolute; background: var(--ink-3); }
.sheet .tick::before { width: 9px; height: 1px; top: 0; left: 0; }
.sheet .tick::after  { width: 1px; height: 9px; top: 0; left: 0; }
.sheet .tl { top: 18px; left: 18px; }
.sheet .tr { top: 18px; right: 18px; transform: scaleX(-1); }
.sheet .bl { bottom: 18px; left: 18px; transform: scaleY(-1); }
.sheet .br { bottom: 18px; right: 18px; transform: scale(-1,-1); }

/* ---- 縦組みの図面ラベル（edge） ---- */
.edge { position: fixed; z-index: 1; pointer-events: none;
  font-family: "IBM Plex Mono", monospace; font-size: 9.5px; letter-spacing: .42em;
  color: var(--ink-3); writing-mode: vertical-rl; text-orientation: mixed; }
.edge-l { left: 30px; bottom: 40px; }
.edge-r { right: 30px; top: 40px; }
@media (max-width: 680px) { .edge { display: none; } }

.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 40px; position: relative; }
@media (max-width: 680px) { .wrap { padding: 0 22px; } }

/* ============ Header ============ */
header {
  position: fixed; top: 22px; left: 22px; right: 22px; z-index: 1000;
  transition: background .5s var(--ease), border-color .5s var(--ease);
  border-bottom: 1px solid transparent;
}
header.scrolled { background: rgba(0,0,0,0.92); border-bottom: 1px solid var(--line-2); }
.nav { display: flex; align-items: stretch; justify-content: space-between; height: 76px; padding: 0 18px; max-width: var(--maxw); margin: 0 auto; }
.logo {
  font-family: "IBM Plex Mono", monospace; font-weight: 400; font-size: 15px;
  letter-spacing: .44em; color: var(--ink); display: inline-flex; align-items: center;
}
.nav-back {
  font-family: "IBM Plex Mono", monospace; font-size: 11px; letter-spacing: .22em;
  text-transform: uppercase; color: var(--ink-2);
  display: inline-flex; align-items: center; gap: 10px;
  border-left: 1px solid var(--line-2); padding: 0 24px; transition: color .3s var(--ease);
}
.nav-back:hover { color: var(--ink); }
.nav-back svg { width: 14px; height: 14px; }
@media (max-width: 680px) { header { left: 14px; right: 14px; top: 14px; } .sheet .border { inset: 14px; } }

/* labels（図面の見出し札） */
.label {
  font-family: "IBM Plex Mono", monospace; font-size: 10.5px; letter-spacing: .38em;
  text-transform: uppercase; color: var(--ink-2);
  display: inline-flex; align-items: center; gap: 14px;
}
.label .idx { color: var(--ink-3); border: 1px solid var(--line-2); padding: 3px 8px; line-height: 1; letter-spacing: .14em; }
.label .rule { display: inline-block; width: 46px; height: 1px; background: var(--line-2); }

/* ============ パンくず ============ */
.crumb {
  font-family: "IBM Plex Mono", monospace; font-size: 10px; letter-spacing: .14em;
  color: var(--ink-3); text-transform: uppercase; margin-bottom: 26px;
}
.crumb a { color: var(--ink-2); }
.crumb a:hover { color: var(--ink); }
.crumb .sep { margin: 0 10px; color: var(--ink-4); }

/* ============ 事例ヒーロー ============ */
.case-hero { position: relative; z-index: 2; padding: 160px 0 70px; }
.case-hero .topline {
  display: flex; gap: 26px; flex-wrap: wrap;
  border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2);
  padding: 13px 0; margin-bottom: 44px;
  font-family: "IBM Plex Mono", monospace; font-size: 10.5px; letter-spacing: .28em;
  text-transform: uppercase; color: var(--ink-2);
}
.case-hero .topline .v { color: var(--ink); }
.case-tag-line {
  font-family: "IBM Plex Mono", monospace; font-size: 11px; letter-spacing: .2em;
  text-transform: uppercase; color: var(--ink-3); margin-bottom: 22px;
}
h1.case-h1 {
  font-family: "Shippori Mincho", serif; font-weight: 600;
  letter-spacing: -.02em; line-height: 1.4;
  font-size: clamp(30px, 5vw, 56px); text-wrap: balance;
}
h1.case-h1 .strong { font-weight: 700; }
.case-hero .lede {
  max-width: 640px; margin-top: 30px; color: var(--ink-2);
  font-size: clamp(15px, 1.5vw, 17px); line-height: 2.0;
}

/* 事例ヒーロー写真 */
.hero-photo {
  position: relative; margin-top: 52px; border: 1px solid var(--line-2);
  aspect-ratio: 21 / 9; overflow: hidden;
}
.hero-photo .ph-cap {
  position: absolute; left: 16px; bottom: 14px; z-index: 3;
  font-family: "IBM Plex Mono", monospace; font-size: 9.5px; letter-spacing: .26em;
  color: var(--ink-2); text-transform: uppercase;
}
.hero-photo .ph-cap b { color: var(--ink); font-weight: 400; }
.hero-photo--blank { background: #060606; }
@media (max-width: 680px) { .hero-photo { aspect-ratio: 16 / 9; } }

/* ============ セクション ============ */
.section { position: relative; z-index: 2; padding: clamp(64px, 9vh, 110px) 0; border-top: 1px solid var(--line-2); }
.sec-head { margin-bottom: 44px; }
h2.big {
  font-family: "Shippori Mincho", serif; font-weight: 500;
  letter-spacing: -.02em; line-height: 1.4; font-size: clamp(24px, 3.6vw, 40px);
  margin-top: 26px; text-wrap: balance;
}
h2.big .strong { font-weight: 600; }
.prose p { color: var(--ink-2); font-weight: 400; line-height: 2.0; font-size: 15.5px; margin-bottom: 22px; }
.prose p:last-child { margin-bottom: 0; }
.prose b { color: var(--ink); font-weight: 500; }
.prose h3 {
  font-family: "Shippori Mincho", serif; font-weight: 600;
  font-size: clamp(18px, 2.2vw, 23px); letter-spacing: -.01em; line-height: 1.6;
  margin: 40px 0 16px; color: var(--ink);
}
.prose h3:first-child { margin-top: 0; }

/* 箇条書き（罫線リスト） */
.linelist { border-top: 1px solid var(--line-2); margin-top: 8px; }
.linelist .row {
  display: grid; grid-template-columns: 44px 1fr; gap: 24px; align-items: start;
  padding: 22px 6px; border-bottom: 1px solid var(--line-2);
}
.linelist .row .no {
  font-family: "IBM Plex Mono", monospace; font-size: 11px; color: var(--ink-3);
  letter-spacing: .14em; padding-top: 4px;
}
.linelist .row .txt { color: var(--ink-2); font-size: 15px; line-height: 1.9; }
.linelist .row .txt b { color: var(--ink); font-weight: 500; }
.linelist .row .txt strong { color: var(--ink); font-weight: 500; }

/* ============ 成果（数字） ============ */
.metrics { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--line-2); border-bottom: none; }
.metric-cell {
  border-bottom: 1px solid var(--line-2); border-left: 1px solid var(--line-2);
  padding: 32px 28px; display: flex; flex-direction: column;
}
.metric-cell:first-child { border-left: none; }
.metric-cell .m-label {
  font-family: "IBM Plex Mono", monospace; font-size: 10px; letter-spacing: .18em;
  text-transform: uppercase; color: var(--ink-3);
}
.metric-cell .m-val {
  font-family: "IBM Plex Mono", monospace; font-weight: 500;
  font-size: clamp(30px, 4vw, 46px); letter-spacing: -.03em; line-height: 1.0;
  margin-top: 14px; color: var(--ink);
}
.metric-cell .m-val .u { font-size: .38em; color: var(--ink-2); letter-spacing: .02em; }
.metric-cell .m-note { margin-top: 12px; font-size: 12.5px; color: var(--ink-3); line-height: 1.7; }
.metrics-foot {
  margin-top: 18px;
  font-family: "IBM Plex Mono", monospace; font-size: 10px; letter-spacing: .12em;
  color: var(--ink-3); text-transform: uppercase;
}
@media (max-width: 680px) {
  .metrics { grid-template-columns: 1fr; }
  .metric-cell { border-left: none; }
}

/* ============ CTA ============ */
.cta { position: relative; z-index: 2; border-top: 1px solid var(--line-2); }
.cta-inner { padding: clamp(72px, 11vh, 120px) 0; text-align: center; }
.cta-inner .label { justify-content: center; }
.cta-inner h2.big { margin-top: 26px; }
.cta-inner .sub { color: var(--ink-2); max-width: 560px; margin: 26px auto 0; font-size: 15px; line-height: 1.95; }
.cta-actions { display: inline-flex; gap: 0; flex-wrap: wrap; border: 1px solid var(--line-2); margin-top: 40px; }
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  font-family: "IBM Plex Mono", monospace; font-size: 11px; letter-spacing: .2em;
  text-transform: uppercase; padding: 16px 26px; cursor: pointer;
  transition: background .3s var(--ease), color .3s var(--ease); white-space: nowrap;
}
.btn svg { width: 15px; height: 15px; transition: transform .35s var(--ease); }
.btn-fill { background: var(--ink); color: #000; }
.btn-fill:hover { background: #d2d2d2; }
.btn-fill:hover svg { transform: translateX(5px); }
.btn-line { color: var(--ink); border-left: 1px solid var(--line-2); }
.btn-line:hover { background: #080808; }
.cta-note { margin-top: 16px; font-size: 12.5px; color: var(--ink-3); }

/* 関連事例 */
.related { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line-2); border-bottom: none; margin-top: 8px; }
.related a {
  border-bottom: 1px solid var(--line-2); border-left: 1px solid var(--line-2);
  padding: 28px 26px; transition: background .35s var(--ease);
}
.related a:first-child { border-left: none; }
.related a:hover { background: #070707; }
.related a .r-tag {
  font-family: "IBM Plex Mono", monospace; font-size: 10px; letter-spacing: .18em;
  text-transform: uppercase; color: var(--ink-3);
}
.related a .r-ttl { font-family: "Shippori Mincho", serif; font-weight: 500; font-size: 17px; line-height: 1.6; margin-top: 12px; color: var(--ink); }
@media (max-width: 680px) { .related { grid-template-columns: 1fr; } .related a { border-left: none; } }

/* ============ Footer ============ */
.foot { position: relative; z-index: 2; border-top: 1px solid var(--line-2); }
.foot-inner {
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px;
  padding: 34px 0;
  font-family: "IBM Plex Mono", monospace; font-size: 10.5px; letter-spacing: .14em; color: var(--ink-3);
}
.foot-inner a { color: var(--ink-2); }
.foot-inner a:hover { color: var(--ink); }

@media (prefers-reduced-motion: reduce) {
  *, *::after, *::before { animation: none !important; transition: none !important; }
}
