/* 全ページ共通の部品：ヘッダー（1段）とメニューの幕、ボタン（主・副の2種だけ）、ページ遷移の幕、フッター、 */
/* サブページの共通の型（扉の帯・小見出しの2段組・細線の行・表・受付状況の文字・フォーム）。 */
/* 余白は foundation.css の --space-section / --space-title / --space-block / --space-card だけを使う。 */
/* メディアクエリは site-media.css（最後に読む）へ集約する。 */

:root {
  --button-min: 220px;
  --darkroom-red: #7a1014;
  --darkroom-deep: #1d0507;
  --card-line: rgba(102, 76, 51, 0.2);
  --badge-ng: #8e1d1f;
  --soft-on-dark: rgba(248, 238, 225, 0.78);
}

/* ---- 章タイトル（既存の PROFILE・MENU・FLOW の h2 と同じ型）と、脇の日本語（PORTFOLIO の「朝、昼、夕暮れ、夜」の位置） ---- */

.chapter-head {
  align-items: end;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  justify-content: space-between;
  margin-bottom: var(--space-title);
}

.chapter-head h2 {
  font-size: var(--chapter-size);
  letter-spacing: var(--chapter-tracking);
  margin: 0;
}

.chapter-head p {
  color: var(--ink-soft);
  font-family: var(--font-serif);
  font-size: 0.95rem;
  letter-spacing: 0.1em;
}

/* ---- 英字の小さな見出し語（金） ---- */

.label-en {
  color: var(--gold);
  font-family: var(--font-latin);
  font-size: 0.75rem;
  font-weight: 400;
  letter-spacing: 0.24em;
  line-height: 1.5;
  margin: 0;
}

/* ---- ヘッダー（1段：wordmark／メニュー／撮影を依頼する） ---- */
/* JSが動くと html.header-fixed で固定になり、スクロール後は紙色の半透明の帯に --ink の文字へ。 */

.site-header {
  border-bottom: 1px solid transparent;
  padding-block: 1.1rem;
  transition: background-color 0.4s var(--ease-light), border-color 0.4s var(--ease-light), color 0.4s var(--ease-light);
}

html.header-fixed .site-header {
  position: fixed;
}

.site-header.is-scrolled {
  background-color: rgba(250, 246, 239, 0.9);
  border-bottom-color: var(--hairline);
  color: var(--ink);
}

.header-inner {
  align-items: center;
  column-gap: 1.75rem;
  flex-wrap: nowrap;
  row-gap: 0;
}

.brand {
  font-family: var(--font-latin);
  letter-spacing: 0.28em;
  line-height: 1.2;
  position: relative;
  white-space: nowrap;
  z-index: 2;
}

.global-nav {
  align-items: center;
  display: flex;
  margin-left: auto;
  transition: opacity 0.6s var(--ease-light);
}

.js.intro-lock .global-nav,
.js.intro-lock .header-cta {
  opacity: 0;
}

.header-cta {
  flex: none;
  transition: opacity 0.6s var(--ease-light), background-color 0.4s var(--ease-light), border-color 0.4s var(--ease-light), color 0.4s var(--ease-light);
}

.global-nav-toggle {
  align-items: center;
  background: transparent;
  border: 0;
  border-radius: 0;
  cursor: pointer;
  display: inline-flex;
  flex-direction: column;
  font-family: var(--font-serif);
  font-size: 0.85rem;
  flex: none;
  gap: 0.28rem;
  justify-content: center;
  letter-spacing: 0.12em;
  min-height: 44px;
  min-width: 44px;
  padding: 0;
  position: relative;
  transition: color 0.3s var(--ease-light);
  white-space: nowrap;
  z-index: 2;
}

.global-nav-toggle:focus-visible {
  outline: 1px solid currentColor;
  outline-offset: 4px;
}

.global-nav-toggle-lines {
  display: grid;
  gap: 6px;
  width: 22px;
}

.global-nav-toggle-lines i {
  background: currentColor;
  display: block;
  height: 1px;
  transition: transform 0.4s var(--ease-light);
}

.global-nav-toggle-label {
  font-size: 0.65rem;
  letter-spacing: 0.06em;
  opacity: 0;
  pointer-events: none;
  position: absolute;
}

.global-nav.is-open .global-nav-toggle {
  color: var(--ink);
}

.global-nav.is-open .global-nav-toggle-lines i:first-child {
  transform: translateY(3.5px) rotate(18deg);
}

.global-nav.is-open .global-nav-toggle-lines i:last-child {
  transform: translateY(-3.5px) rotate(-18deg);
}

html.nav-open .site-header {
  color: var(--ink);
}

/* メニューの幕：紙の面に明朝の一覧。9項目を1段に並べると列（1016px）に収まらないため、全幅でこの幕に入れる。 */

.global-nav-panel {
  background-color: var(--paper);
  background-image: url("../images/paper-washi.webp");
  background-repeat: repeat;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  inset: 0;
  justify-content: center;
  opacity: 0;
  overflow-y: auto;
  padding: 6rem var(--gutter) 3rem;
  position: fixed;
  transition: opacity 0.4s var(--ease-light), visibility 0s linear 0.4s;
  visibility: hidden;
  z-index: 1;
}

.global-nav.is-open .global-nav-panel {
  opacity: 1;
  transition: opacity 0.4s var(--ease-light);
  visibility: visible;
}

.global-nav-list {
  align-items: flex-start;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  list-style: none;
  margin: 0 auto;
  max-width: 24rem;
  padding: 0;
  width: 100%;
}

.global-nav-list a {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: 1.125rem;
  letter-spacing: 0.12em;
  padding-block: 0.55rem;
  position: relative;
}

.global-nav-list a:not(.global-nav-cta)::after {
  background: currentColor;
  bottom: 0.3rem;
  content: "";
  height: 1px;
  inset-inline: 0;
  opacity: 0.55;
  position: absolute;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s var(--ease-light);
}

.global-nav-list a[aria-current="page"]::after {
  transform: scaleX(1);
}

.global-nav-list li:last-child {
  margin-top: 1.5rem;
}

/* ---- ボタン（主＝塗り／副＝線の2種だけ。ホバーは 0.4s の色の変化だけ） ---- */

.site-button {
  align-items: center;
  background: transparent;
  border: 1px solid var(--ink);
  border-radius: 0;
  color: var(--ink);
  cursor: pointer;
  display: inline-flex;
  font-family: var(--font-serif);
  font-size: 0.9rem;
  font-weight: 500;
  justify-content: center;
  letter-spacing: 0.14em;
  line-height: 1.5;
  min-height: 3.4rem;
  min-width: var(--button-min);
  padding: 0.5rem 2.75rem;
  position: relative;
  text-align: center;
  transition: background-color 0.4s var(--ease-light), border-color 0.4s var(--ease-light), color 0.4s var(--ease-light);
}

.site-button > span {
  position: relative;
}

.site-button--primary,
.global-nav-list a.global-nav-cta {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.site-button--small {
  min-height: 2.6rem;
  padding: 0.3rem 1.75rem;
}

/* 暗い面（夜の章など）の上の副ボタン：線と文字を紙色に。 */
.site-button--light {
  border-color: var(--night-paper);
  color: var(--night-paper);
}

.site-button[disabled],
.site-button[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.5;
}

.global-nav-list a.global-nav-cta {
  align-items: center;
  border: 1px solid var(--ink);
  display: inline-flex;
  font-size: 0.9rem;
  justify-content: center;
  letter-spacing: 0.14em;
  min-height: 3.4rem;
  min-width: var(--button-min);
  padding: 0.5rem 2.75rem;
  transition: background-color 0.4s var(--ease-light), border-color 0.4s var(--ease-light);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.25rem;
  justify-content: flex-start;
  margin-top: var(--space-block);
}

.cta-row--center {
  justify-content: center;
}

.cta-row--after-list {
  margin-top: var(--space-block);
}

/* ---- 通常遷移の紙色フェード。ルートの疑似要素なのでJS到着前から描画できる。 ---- */

html::after {
  background: #f8f5ee;
  content: "";
  inset: 0;
  opacity: 0;
  pointer-events: none;
  position: fixed;
  transition: opacity 0.45s ease-out;
  z-index: 2000;
}

html.veil-in::after {
  opacity: 1;
  transition: none;
}

html.veil-out::after {
  opacity: 1;
  transition: opacity 0.22s ease-in;
}

/* ---- フッター（上段2列・細線・下段の注記と制作・著作） ---- */

.site-footer {
  background: var(--ink);
  color: var(--paper);
  padding-block: 5rem;
}

.site-footer p {
  margin: 0;
}

.footer-top {
  align-items: start;
  border-bottom: 1px solid var(--hairline-on-dark);
  display: grid;
  gap: 2.5rem 4rem;
  grid-template-columns: minmax(0, 1fr) auto;
  padding-bottom: 3rem;
}

.site-footer .footer-brand {
  font-family: var(--font-latin);
  font-size: 1.125rem;
  letter-spacing: 0.28em;
  line-height: 1.4;
}

.site-footer .footer-name {
  font-family: var(--font-serif);
  font-size: 0.875rem;
  letter-spacing: 0.12em;
  margin-top: 0.9rem;
}

.footer-nav ul {
  display: grid;
  gap: 0.75rem 3.5rem;
  grid-auto-flow: column;
  grid-template-rows: repeat(5, auto);
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-nav a {
  font-family: var(--font-serif);
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  line-height: 1.6;
  transition: color 0.4s var(--ease-light);
}

.footer-bottom {
  display: grid;
  gap: 0.35rem;
  padding-top: 2.5rem;
}

.site-footer .footer-note {
  color: rgba(250, 246, 239, 0.7);
  font-size: 0.8rem;
  line-height: 1.8;
}

.footer-credit {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 2rem;
  justify-content: space-between;
  margin-top: 1.75rem;
}

/* ---- サブページの共通の型 ---- */

body.subpage {
  color: var(--ink);
}

/* 扉の帯：英字の見出し語（小・金）→ 章タイトル（既存の型）→ 明朝の一文。高さは中身なり。 */

.page-head {
  background-color: var(--theme-morning);
  isolation: isolate;
  overflow: hidden;
  padding-block: 7rem 5rem;
  position: relative;
}

.page-head::before,
.page-head::after {
  content: "";
  inset: 0;
  pointer-events: none;
  position: absolute;
}

.page-head::before {
  background-image: url("../images/paper-washi.webp");
  background-repeat: repeat;
  mix-blend-mode: multiply;
  opacity: 0.22;
  z-index: -2;
}

.page-head::after {
  background-image: url("../images/light-window-pass-v9.webp");
  background-position: 88% 30%;
  background-repeat: no-repeat;
  background-size: min(46rem, 90vw) auto;
  -webkit-mask-image: radial-gradient(ellipse 50% 50% at 80% 40%, #000 30%, transparent 90%);
  mask-image: radial-gradient(ellipse 50% 50% at 80% 40%, #000 30%, transparent 90%);
  mix-blend-mode: screen;
  opacity: 0.3;
  transform: translate3d(0, 0, 0) scale(1.02);
  z-index: -1;
}

.sub-motion .page-head::after {
  animation: komorebi-drift 15s var(--ease-light) infinite alternate;
}

.page-kicker {
  margin-bottom: 1rem;
}

.page-head .page-title,
.page-head .post-title {
  font-size: var(--chapter-size);
  font-weight: 500;
  letter-spacing: var(--chapter-tracking);
  line-height: 1.45;
  margin: 0;
}

.page-lead {
  color: var(--ink-soft);
  font-family: var(--font-serif);
  font-size: 1.05rem;
  letter-spacing: 0.05em;
  line-height: 2;
  margin-top: 1.25rem;
  max-width: 44rem;
  text-wrap: pretty;
}

html[data-daypart="daylight"] .page-head {
  background-color: color-mix(in srgb, var(--theme-daylight) 58%, var(--paper));
}

html[data-daypart="golden"] .page-head {
  background-color: var(--theme-golden);
  color: var(--night-paper);
}

html[data-daypart="night"] .page-head {
  background-color: var(--theme-night);
  color: var(--night-paper);
}

html[data-daypart="golden"] .page-head .page-lead,
html[data-daypart="night"] .page-head .page-lead,
html[data-daypart="golden"] .page-head .post-meta,
html[data-daypart="night"] .page-head .post-meta {
  color: var(--soft-on-dark);
}

html[data-daypart="golden"] .page-head .label-en,
html[data-daypart="night"] .page-head .label-en {
  color: var(--champagne-gold);
}

html[data-daypart="golden"]:not(.nav-open) body.subpage .site-header:not(.is-scrolled),
html[data-daypart="night"]:not(.nav-open) body.subpage .site-header:not(.is-scrolled) {
  color: var(--night-paper);
}

html[data-daypart="golden"]:not(.nav-open) body.subpage .site-header:not(.is-scrolled) .header-cta,
html[data-daypart="night"]:not(.nav-open) body.subpage .site-header:not(.is-scrolled) .header-cta {
  background: var(--night-paper);
  border-color: var(--night-paper);
  color: var(--ink);
}

html[data-daypart="night"] .page-head::before {
  mix-blend-mode: soft-light;
  opacity: 0.18;
}

.sub-section {
  isolation: isolate;
  padding-block: var(--space-section);
  position: relative;
}

.sub-section--paper {
  background-color: #f8f1e6;
  background-image: url("../images/paper-washi.webp");
  background-repeat: repeat;
}

.sub-section--light {
  background-color: #fffdf9;
}

/* 小見出し：英字の小さな見出し語（金）＋その下に明朝の日本語の2段組。 */

.sub-head {
  margin-bottom: var(--space-title);
}

.sub-head .label-en {
  margin-bottom: 0.55rem;
}

.sub-heading {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  line-height: 1.6;
  margin: 0;
}

.prose {
  max-width: 44rem;
}

.prose p {
  line-height: 2.1;
  text-wrap: pretty;
}

.prose p + p {
  margin-top: 1.2em;
}

.sub-list {
  list-style: none;
  margin: 0;
  max-width: 46rem;
  padding: 0;
}

.sub-list li {
  line-height: 1.95;
  padding-left: 1.5rem;
  position: relative;
}

.sub-list li + li {
  margin-top: 0.85rem;
}

.sub-list li::before {
  background: var(--champagne-gold);
  border-radius: 50%;
  content: "";
  height: 0.35rem;
  left: 0.3rem;
  position: absolute;
  top: 0.82em;
  width: 0.35rem;
}

.meta-text {
  color: var(--ink-soft);
  font-size: 0.875rem;
}

/* ---- カード：箱（枠線＋影）をやめ、細線の行か細い金線1本の枠で作る ---- */

.paper-card {
  background: none;
  border: 0;
  box-shadow: none;
  padding: 0;
  position: relative;
}

.card-grid {
  display: grid;
  gap: var(--space-title) var(--space-block);
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-link {
  display: block;
  transition: color 0.4s var(--ease-light);
}

/* 細い金線1本の枠（額装と同じ --champagne-gold）。写真の外に紙の余白を残して線を引く。 */
.gold-frame,
.blog-card-image {
  display: block;
  margin: 0.5rem;
  outline: 1px solid var(--champagne-gold);
  outline-offset: 0.5rem;
  overflow: hidden;
}

/* ---- ブログの並び（トップとブログ一覧で共通） ---- */

.blog-card {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
}

.blog-card-image {
  aspect-ratio: 3 / 2;
}

.blog-card-image img {
  /* アイキャッチを3:2の枠へ収める内在サイズ制御。 */
  height: 100%;
  object-fit: cover;
  transition: transform 0.9s var(--ease-light);
  width: 100%;
}

.blog-card-body {
  display: grid;
  gap: 0.55rem;
  /* 列の幅はカードの幅まで（区切れない長い題が枠の外へ出ないように） */
  grid-template-columns: minmax(0, 1fr);
}

.blog-card-meta {
  align-items: baseline;
  color: var(--ink-soft);
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
}

.blog-card-meta time {
  font-family: var(--font-latin);
  font-size: 0.8rem;
  letter-spacing: 0.06em;
}

.blog-card h3,
.blog-card .blog-card-title {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.65;
  margin: 0;
  text-wrap: pretty;
  transition: color 0.4s var(--ease-light);
}

.blog-card-excerpt {
  -webkit-box-orient: vertical;
  color: var(--ink-soft);
  display: -webkit-box;
  font-size: 0.9rem;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  line-height: 1.9;
  overflow: hidden;
}

/* ---- 表（細線。見出し列・日付・ラベルは明朝） ---- */

.info-table {
  border-collapse: collapse;
  width: 100%;
}

.info-table th,
.info-table td {
  border-bottom: 1px solid var(--hairline);
  line-height: 1.85;
  padding: 1.1rem 1.25rem 1.1rem 0;
  text-align: left;
  vertical-align: top;
}

.info-table thead th {
  color: var(--ink-soft);
  font-family: var(--font-serif);
  font-size: 0.8rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  padding-block: 0.7rem;
}

.info-table tbody th {
  font-family: var(--font-serif);
  font-weight: 500;
  letter-spacing: 0.04em;
  white-space: nowrap;
  width: 13rem;
}

.info-table tr:first-child th,
.info-table tr:first-child td {
  border-top: 1px solid var(--hairline);
}

.info-table thead tr:first-child th {
  border-top: 0;
}

/* ---- 受付状況・判定・分類：小さな明朝の文字（受付中は金の点、準備中は薄い点） ---- */

.badge {
  align-items: center;
  color: var(--ink-soft);
  display: inline-flex;
  font-family: var(--font-serif);
  font-size: 0.8rem;
  gap: 0.55em;
  letter-spacing: 0.08em;
  line-height: 1.6;
  white-space: nowrap;
}

.badge--open::before,
.badge--soon::before {
  border-radius: 50%;
  content: "";
  flex: none;
  height: 6px;
  width: 6px;
}

.badge--open {
  color: var(--ink);
}

.badge--open::before {
  background: var(--gold);
}

.badge--soon {
  color: var(--ink);
}

.badge--soon::before {
  background: var(--champagne-gold-soft);
  box-shadow: inset 0 0 0 1px var(--champagne-gold);
}

.badge--full,
.badge--closed {
  color: var(--ink-soft);
}

.badge--ok {
  color: var(--ink);
}

.badge--ask {
  color: var(--gold);
}

.badge--ng,
.badge--none {
  color: var(--ink-soft);
}

/* 受付の文の前の金の点（休止中は点を消し、文字を --ink-soft に） */
.booking-lamp {
  background: var(--gold);
  border-radius: 50%;
  flex: none;
  height: 6px;
  position: relative;
  top: -0.2em;
  width: 6px;
}

.is-closed .booking-lamp {
  display: none;
}

.is-closed [data-booking-text] {
  color: var(--ink-soft);
}

/* ---- フォーム ---- */

.form-field {
  border: 0;
  display: grid;
  gap: 0.6rem;
  margin: 0;
  min-width: 0;
  padding: 0;
}

.form-field + .form-field {
  margin-top: var(--space-block);
}

.form-label {
  align-items: baseline;
  display: flex;
  flex-wrap: wrap;
  font-family: var(--font-serif);
  font-size: 1.0625rem;
  gap: 0.75rem;
  letter-spacing: 0.04em;
  padding: 0;
}

.form-required {
  color: var(--gold);
  font-family: var(--font-serif);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
}

.form-help {
  color: var(--ink-soft);
  font-size: 0.875rem;
  line-height: 1.8;
}

.form-input,
.form-textarea,
.form-select {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 0;
  color: var(--ink);
  font: inherit;
  font-size: 1rem;
  max-width: 100%;
  min-height: 3.1rem;
  padding: 0.75rem 0.95rem;
  transition: border-color 0.4s var(--ease-light);
}

.form-input {
  width: 32rem;
}

.form-input--short {
  width: 14rem;
}

.form-textarea {
  line-height: 1.8;
  min-height: 9rem;
  resize: vertical;
  width: 40rem;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  border-color: var(--ink);
  box-shadow: none;
  outline: none;
}

/* 選択肢：細線の下線式（選択中は --ink の 1px 線＋文字が --ink、未選択は --ink-soft） */

.choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 2rem;
}

.choice {
  cursor: pointer;
  display: inline-flex;
  padding-block: 0.45rem;
  position: relative;
}

.choice input {
  height: 1px;
  opacity: 0;
  position: absolute;
  width: 1px;
}

.choice span {
  border-bottom: 1px solid var(--hairline);
  color: var(--ink-soft);
  display: inline-block;
  font-family: var(--font-serif);
  letter-spacing: 0.06em;
  line-height: 1.7;
  padding-bottom: 0.2rem;
  transition: border-color 0.4s var(--ease-light), color 0.4s var(--ease-light);
}

.choice input:checked + span {
  border-bottom-color: var(--ink);
  color: var(--ink);
}

.choice input:focus-visible + span {
  outline: 2px solid var(--gold);
  outline-offset: 4px;
}

.check-line {
  align-items: flex-start;
  cursor: pointer;
  display: flex;
  gap: 0.75rem;
  line-height: 1.8;
}

.check-line input {
  accent-color: var(--ink);
  flex: none;
  height: 1.25rem;
  margin-top: 0.3rem;
  width: 1.25rem;
}

.check-line a {
  text-decoration: underline;
  text-decoration-color: var(--champagne-gold);
  text-underline-offset: 0.25em;
}

.form-error {
  color: var(--badge-ng);
  font-size: 0.875rem;
}

.form-error[hidden] {
  display: none;
}

.honeypot {
  height: 1px;
  left: -9999px;
  overflow: hidden;
  position: absolute;
  width: 1px;
}

/* ---- サブページの出現アニメ（body.subpage に限定。トップの data-reveal とは別） ---- */

@keyframes sub-rise {
  from {
    opacity: 0;
    transform: translate3d(0, 18px, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

.sub-motion body.subpage [data-sub-reveal]:not(.is-shown) {
  opacity: 0;
}

.sub-motion body.subpage [data-sub-reveal].is-shown {
  animation: sub-rise 0.72s var(--ease-light) var(--sub-delay, 0s) both;
}

.visually-hidden {
  clip: rect(0 0 0 0);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}
