/* ============================================================================
   B・B TAKAOKA — shared design tokens + base + components
   Direction: editorial heritage barber & beauty / warm-neutral, ochre-brass
   LIGHT mode, pure-white base. Single source of truth for every page.
   ========================================================================= */

:root {
  /* ── color — LIGHT, pure white base ─────────────────────────────────── */
  --bg: #ffffff;                /* main background — pure white */
  --surface: #f8f4ea;           /* cards — pale warm cream (yellow chairs, desaturated) */
  --surface-2: #f2ebda;         /* alternating section bands / footer — warm sand */
  --surface-deep: #eadfca;      /* monogram ground / deep insets */
  --text: #211e18;              /* warm near-black (room's dark material) */
  --text-muted: #6e6557;        /* warm taupe */
  --accent: #9c7c2a;            /* brass / ochre — decor + large fills ONLY */
  --accent-deep: #6f561a;       /* deep ochre — text / links (>=4.5:1 on white) */
  --accent-soft: #e7dcbf;       /* soft ochre tint — chips, rules, underlines */
  --border: #e8e1d1;            /* warm hairline */
  --border-strong: #d8cfb9;     /* stronger hairline */

  /* ── type ───────────────────────────────────────────────────────────── */
  --font-display: "Fraunces", Georgia, serif;                  /* Latin display + brand */
  --font-jp-display: "Zen Old Mincho", "Hiragino Mincho ProN", serif; /* JP headings */
  --font-body: "Zen Kaku Gothic New", system-ui, sans-serif;   /* latin labels / nav */
  --font-jp: "Zen Kaku Gothic New", system-ui, sans-serif;     /* JP body */

  /* ── radius — MIXED edges (apply deliberately) ──────────────────────── */
  --radius: 12px;               /* content cards / panels = softly rounded */
  --radius-lg: 20px;            /* larger panels */
  --radius-pill: 999px;         /* buttons / tags = pills */
  /* media/photo frames = sharp (square) — use 0, no token needed */

  /* ── spacing / rhythm ───────────────────────────────────────────────── */
  --maxw: 1200px;
  --section-y: clamp(5rem, 9vw, 8.5rem);
  --gap: clamp(1.25rem, 3vw, 2.5rem);

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --shadow-soft: 0 18px 50px -28px rgba(40, 33, 18, 0.30);
  --shadow-card: 0 1px 0 rgba(40, 33, 18, 0.02), 0 14px 36px -26px rgba(40, 33, 18, 0.28);
}

/* ── reset + base ─────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-jp);
  font-size: 16px;
  line-height: 1.85;
  font-feature-settings: "palt" 1;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; line-height: 1.18; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }

/* anchor targets clear the fixed navbar */
[id] { scroll-margin-top: 96px; }

/* ── layout helpers ───────────────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 3rem);
}
.container--narrow { max-width: 860px; }

.section { padding-block: var(--section-y); }
/* Section bands stay pure white — rhythm comes from whitespace, hairlines, and
   the tinted cards/media, not from creamy full-width fills (house rule). */
.section--tint { background: var(--bg); }
.section--cream { background: var(--bg); }

/* ── typographic atoms ────────────────────────────────────────────────── */
/* small uppercase Latin label above headings */
.eyebrow {
  font-family: var(--font-body);
  font-size: 0.72rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--accent-deep);
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
}
.eyebrow::before {
  content: "";
  width: 28px;
  height: 1px;
  background: var(--accent);
}
.eyebrow--center { justify-content: center; }

/* English display line (Fraunces) */
.display {
  font-family: var(--font-display);
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.05;
}
/* Japanese display heading (Zen Old Mincho) */
.display-jp {
  font-family: var(--font-jp-display);
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: 0.04em;
}
.section-title {
  font-family: var(--font-jp-display);
  font-weight: 600;
  font-size: clamp(1.5rem, 3.4vw, 2.25rem);
  letter-spacing: 0.05em;
  line-height: 1.45;
}
.lead { color: var(--text-muted); font-size: 1.02rem; }
.hairline { border: 0; border-top: 1px solid var(--border); margin: 0; }
.accent-text { color: var(--accent-deep); }

/* ── buttons (pills) ──────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-body);
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  line-height: 1;
  padding: 1.05rem 2rem;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.3s var(--ease), color 0.3s var(--ease),
              border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--accent-deep); color: #fff; }
.btn-primary:hover { background: var(--text); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-deep); }

/* ── tags / chips (pills) ─────────────────────────────────────────────── */
.tag {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-body);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
  padding: 0.4rem 0.95rem;
  border-radius: var(--radius-pill);
  background: var(--accent-soft);
  color: var(--accent-deep);
}
.tag--outline { background: transparent; border: 1px solid var(--border-strong); color: var(--text-muted); }

/* ── cards / panels (rounded) ─────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
}

/* ── media frame (SHARP corners) ──────────────────────────────────────── */
.media {
  position: relative;
  overflow: hidden;
  border-radius: 0;              /* sharp */
  background: var(--surface-2);
}
.media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.media--tall { aspect-ratio: 3 / 4; }
.media--portrait { aspect-ratio: 4 / 5; }
.media--wide { aspect-ratio: 16 / 10; }
.media--square { aspect-ratio: 1 / 1; }

/* ── avatar / monogram (circle) — staff portrait + fallback ───────────── */
.avatar {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  overflow: hidden;
  background: var(--surface-2);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.monogram {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--surface-deep);
  color: var(--accent-deep);
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 7vw, 3.75rem);
  line-height: 1;
}

/* ── step number (circle) ─────────────────────────────────────────────── */
.step-num {
  width: 2.6rem; height: 2.6rem;
  border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid var(--accent);
  color: var(--accent-deep);
  font-family: var(--font-display);
  font-size: 1.1rem;
  flex: none;
}

/* ── page-header pattern for subpages ─────────────────────────────────── */
.page-header {
  padding-top: clamp(8rem, 14vw, 11rem);
  padding-bottom: var(--section-y);
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.page-header .display {
  font-size: clamp(2.4rem, 7vw, 4.5rem);
}

/* ── scroll-reveal (the ONLY entrance-animation system) ───────────────── */
html.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
html.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html.js .reveal { opacity: 1; transform: none; transition: none; }
}

/* ── shared footer ────────────────────────────────────────────────────── */
.site-footer {
  background: var(--surface-2);
  border-top: 1px solid var(--border);
  padding-block: clamp(3.5rem, 6vw, 5rem) 2rem;
}
.site-footer .foot-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  gap: clamp(2rem, 5vw, 4rem);
  align-items: start;
}
.site-footer .foot-brand {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.04em;
}
.site-footer .foot-tag {
  margin-top: 0.85rem;
  color: var(--text-muted);
  font-size: 0.92rem;
  max-width: 30ch;
}
.site-footer .foot-h {
  font-family: var(--font-body);
  font-size: 0.7rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin-bottom: 1rem;
}
.site-footer .foot-list { display: grid; gap: 0.55rem; font-size: 0.92rem; color: var(--text-muted); }
.site-footer .foot-list a { color: var(--text-muted); text-decoration: none; transition: color 0.3s var(--ease); }
.site-footer .foot-list a:hover { color: var(--accent-deep); }
.site-footer .foot-list strong { color: var(--text); font-weight: 500; }
.site-footer .foot-bottom {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
}
.site-footer .foot-bottom .foot-en {
  font-family: var(--font-display);
  letter-spacing: 0.06em;
}
@media (max-width: 760px) {
  .site-footer .foot-grid { grid-template-columns: 1fr; gap: 2.25rem; }
}

/* ============================================================================
   navbar.css  (appended verbatim from navbar-partials/navbar.css)
   STRIPPED: the fallback :root{} block and the generic bare `.container`
   selector — both would silently override this design lock. The nav
   container width is aligned to --maxw.
   ========================================================================= */

nav.bh-nav a,
.mob-menu a { text-decoration: none; color: inherit; }
nav.bh-nav .container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 3rem);
}

.link-slide { position: relative; display: inline-block; padding-bottom: 2px; }
.link-slide::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1px; width: 100%;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.link-slide:hover::after { transform: scaleX(1); transform-origin: left; }

/* ── Nav (base — shared across all variants) ─────────────────────── */
nav.bh-nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transition: transform 0.4s cubic-bezier(0.4,0,0.2,1), background 0.3s ease, border-color 0.3s ease;
}
nav.bh-nav .container { padding-block: 1.1rem; }
nav.bh-nav .nav-links { display: flex; gap: 2rem; }
nav.bh-nav .nav-links a {
  font-family: var(--font-body); font-size: 12px; letter-spacing: 0.1em;
  transition: color 0.3s ease;
}
nav.bh-nav .brand {
  font-family: var(--font-display); font-size: 1.15rem; letter-spacing: 0.02em;
  white-space: nowrap; transition: color 0.3s ease;
}
nav.bh-nav .hamburger {
  display: none; flex-direction: column; align-items: center; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 0.5rem;
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
nav.bh-nav .hamburger span {
  width: 22px; height: 2px; background: var(--text);
  transition: transform 0.3s, opacity 0.3s, background 0.3s;
  will-change: transform, opacity;
  backface-visibility: hidden;
  transform: translate3d(0, 0, 0);
}

/* ── Hamburger morph variants — open/close animation ────────────────── */

/* 1. classic-rotate (default) — simultaneous rotate + fade. */
nav.bh-nav .hamburger--morph-classic-rotate.open span:nth-child(1) {
  transform: translate3d(0, 7px, 0) rotate(45deg);
}
nav.bh-nav .hamburger--morph-classic-rotate.open span:nth-child(2) {
  opacity: 0;
}
nav.bh-nav .hamburger--morph-classic-rotate.open span:nth-child(3) {
  transform: translate3d(0, -7px, 0) rotate(-45deg);
}

/* Variant 4 + 5: centered-split + centered-split-cinema (shared layout) */
nav.bh-nav.centered-split {
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid color-mix(in srgb, var(--border) 70%, transparent);
}
nav.bh-nav.centered-split .container {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 3rem;
}
nav.bh-nav.centered-split .nav-links {
  gap: 2.75rem;
}
nav.bh-nav.centered-split .nav-links-left {
  justify-self: end;
}
nav.bh-nav.centered-split .nav-links-right {
  justify-self: start;
}
nav.bh-nav.centered-split .brand-centered {
  font-size: 1.4rem;
  font-weight: 500;
  text-align: center;
  justify-self: center;
}

@media (max-width: 1024px) {
  nav.bh-nav.centered-split .container {
    display: flex;
    justify-content: space-between;
  }
  nav.bh-nav.centered-split .nav-links-left,
  nav.bh-nav.centered-split .nav-links-right { display: none; }
  nav.bh-nav.centered-split .brand-centered { text-align: left; }
  nav.bh-nav.centered-split .hamburger { display: flex; }
}

/* Mob menu — shared base. */
.mob-menu {
  position: fixed; inset: 0; z-index: 99;
  display: flex; flex-direction: column; gap: 1.5rem;
}

/* 3. centered-minimal-light */
.mob-menu--style-centered-minimal-light {
  background: var(--bg);
  padding: 2rem;
  align-items: center;
  justify-content: center;
  gap: 1.75rem;
}
.mob-menu--style-centered-minimal-light a {
  font-family: var(--font-jp);
  font-size: 1.15rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  color: var(--text);
}

/* 2. slide-top */
.mob-menu--reveal-slide-top {
  transform: translateY(-100%);
  transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.mob-menu--reveal-slide-top.open { transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .mob-menu {
    transition: opacity 0.15s ease !important;
    transform: none !important;
    opacity: 0;
    pointer-events: none;
  }
  .mob-menu.open {
    transform: none !important;
    opacity: 1;
    pointer-events: auto;
  }
}

/* ── Keyboard focus (a11y) ─────────────────────────────────────────────── */
nav.bh-nav a:focus-visible,
nav.bh-nav .hamburger:focus-visible,
.mob-menu a:focus-visible {
  outline: 2px solid var(--accent, #1a1a1a);
  outline-offset: 3px;
}
