/* ============================================
   EN-NYU — design system
   Palette: warm cream from the UP TO YOU Flutter app.
   Type: Onest (display) + Inter (body) + Noto Sans/Serif JP for Japanese.
   ============================================ */

@font-face {
  font-family: "DroidSans";
  src: url("./assets/fonts/DroidSans.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "DroidSans";
  src: url("./assets/fonts/DroidSans-Bold.ttf") format("truetype");
  font-weight: 700;
  font-display: swap;
}

:root {
  /* Colors — from lib/theme.dart */
  --bg: #e7dfca;
  --bg-2: #f1ead7;
  --bg-3: #fdf6e6;
  --surface: #ffffff;
  --accent: #8d6748;
  --accent-deep: #6b4f3a;
  --accent-soft: #c29670;
  --today: #d4585b;
  --outline: #d4cab1;
  --text: #2a1f15;
  --text-soft: #6b4f3a;
  --text-muted: #aaa28a;
  --hint: #bcb39a;
  --on-accent: #fffaf0;

  /* Spacing */
  --xs: 4px;
  --sm: 8px;
  --md: 16px;
  --lg: 24px;
  --xl: 32px;
  --xxl: 56px;
  --xxxl: 96px;

  /* Radii */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-pill: 999px;

  /* Type stacks */
  --font-body: "Inter", "Noto Sans JP", "Hiragino Sans", "Yu Gothic", "Meiryo",
    system-ui, sans-serif;
  --font-display: "Onest", "Noto Sans JP", "Hiragino Sans", "Yu Gothic",
    system-ui, sans-serif;
  --font-verse: "Fraunces", "Noto Serif JP", "Hiragino Mincho ProN",
    "Yu Mincho", Georgia, serif;

  /* Shadow */
  --shadow-1: 0 1px 0 rgba(42, 31, 21, 0.04),
    0 10px 30px -18px rgba(42, 31, 21, 0.25);
  --shadow-2: 0 18px 50px -22px rgba(42, 31, 21, 0.4);
  --shadow-lift: 0 24px 60px -28px rgba(42, 31, 21, 0.45);
}

/* ============================================
   Base
   ============================================ */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
  /* Belt-and-suspenders: never permit horizontal scroll on small screens
     from a stray wide element (orbs, marquee, etc.). */
  overflow-x: hidden;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Japanese mode: switch into JP-friendly metrics */
html.lang-ja body {
  font-feature-settings: "palt" 1;
  line-height: 1.8;
}

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

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 160ms ease, opacity 160ms ease;
}
a:hover {
  color: var(--text);
}

.wrap {
  width: min(1200px, 92%);
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: #fff;
  padding: 8px 14px;
  border-radius: var(--r-sm);
  z-index: 100;
}
.skip-link:focus {
  left: 16px;
  top: 16px;
}

/* ============================================
   Typography
   ============================================ */

.display,
.h-display {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--text);
  margin: 0;
}

.display {
  font-size: clamp(3.2rem, 8.5vw, 7rem);
  font-weight: 800;
  line-height: 0.98;
}
.display .line {
  display: block;
}
.display em {
  font-style: normal;
  font-weight: 900;
}
.display .line:nth-child(2) em {
  color: var(--accent);
}
.display .line:nth-child(3) em {
  color: var(--accent-soft);
}

.h-display {
  font-size: clamp(1.8rem, 3.8vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.08;
}
.h-display.light {
  color: var(--on-accent);
}
.h-display em {
  font-style: italic;
  color: var(--accent);
  font-weight: 600;
}

html.lang-ja .display,
html.lang-ja .h-display {
  letter-spacing: -0.005em;
  font-family: "Noto Sans JP", "Onest", sans-serif;
}
html.lang-ja .display {
  font-size: clamp(2.6rem, 7vw, 6rem);
  line-height: 1.06;
}

.lede {
  font-size: clamp(1.05rem, 1.2vw, 1.2rem);
  color: var(--text-soft);
  max-width: 58ch;
  line-height: 1.7;
}
.lede.light {
  color: var(--on-accent);
  opacity: 0.95;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-soft);
  font-weight: 700;
  margin-bottom: var(--md);
  padding-left: 14px;
  border-left: 2px solid var(--accent);
}
html.lang-ja .eyebrow {
  letter-spacing: 0.1em;
  text-transform: none;
  font-size: 0.85rem;
}

.section-tag {
  display: inline-block;
  font-size: 0.74rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: var(--md);
}
.section-tag.light {
  color: #ffd4a3;
}
html.lang-ja .section-tag {
  letter-spacing: 0.08em;
  text-transform: none;
  font-size: 0.85rem;
}

.small {
  font-size: 0.85rem;
}
.muted {
  color: var(--text-muted);
}

/* ============================================
   Header / Nav
   ============================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(231, 223, 202, 0.86);
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid rgba(212, 202, 177, 0.6);
}

.nav {
  display: flex;
  align-items: center;
  gap: var(--lg);
  height: 76px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 800;
  letter-spacing: 0.06em;
}
.brand:hover {
  color: var(--accent);
}
.brand-mark {
  display: inline-grid;
  place-items: center;
}
.brand-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.nav-links {
  display: flex;
  gap: var(--lg);
  margin-left: auto;
}
.nav-links a {
  color: var(--text);
  font-weight: 500;
  font-size: 0.95rem;
  position: relative;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  height: 2px;
  width: 0;
  background: var(--accent);
  transition: width 220ms ease;
  border-radius: 2px;
}
.nav-links a:hover::after {
  width: 100%;
}

.nav-right {
  display: flex;
  align-items: center;
  gap: var(--md);
}

.nav-toggle {
  display: none;
  margin-left: auto;
  width: 44px;
  height: 44px;
  background: var(--surface);
  border: 1px solid var(--outline);
  border-radius: var(--r-md);
  cursor: pointer;
  padding: 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  transition: background 160ms ease, border-color 160ms ease;
}
.nav-toggle:hover {
  background: #fff;
  border-color: var(--accent-soft);
}
.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 220ms ease, opacity 180ms ease;
  transform-origin: center;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.mobile-menu {
  display: flex;
  flex-direction: column;
  gap: var(--md);
  padding: 0 0 0;
  border-top: 1px solid var(--outline);
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 320ms ease, opacity 220ms ease, padding 220ms ease;
}
.mobile-menu[hidden] {
  display: flex;
}
.mobile-menu a {
  font-size: 1.05rem;
  color: var(--text);
  font-weight: 500;
  padding: 6px 0;
}
.mobile-menu[aria-expanded="true"] {
  max-height: 80vh;
  opacity: 1;
  padding: var(--md) 0 var(--lg);
}

/* Language toggle (pill) */
.lang-toggle {
  display: inline-flex;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--outline);
  border-radius: var(--r-pill);
  padding: 4px;
  gap: 2px;
}
.lang-toggle button {
  appearance: none;
  background: transparent;
  border: 0;
  font-family: inherit;
  cursor: pointer;
  color: var(--text-soft);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--r-pill);
  letter-spacing: 0.04em;
  transition: background 160ms ease, color 160ms ease;
  min-width: 48px;
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.lang-toggle button.active {
  background: var(--accent);
  color: var(--on-accent);
}
.lang-toggle button:not(.active):hover {
  color: var(--text);
}
.lang-toggle.mobile {
  align-self: flex-start;
}
.lang-toggle.footer {
  margin-top: var(--md);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.16);
}
.lang-toggle.footer button {
  color: #c7b9a4;
}
.lang-toggle.footer button.active {
  background: #fff;
  color: var(--text);
}

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--r-pill);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: transform 140ms ease, box-shadow 160ms ease,
    background 160ms ease, color 160ms ease, border-color 160ms ease;
  font-family: inherit;
}
.btn-primary {
  background: var(--text);
  color: var(--on-accent);
  box-shadow: var(--shadow-1);
}
.btn-primary:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-2);
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--text);
}
.btn-ghost:hover {
  background: var(--text);
  color: var(--on-accent);
}
.btn-on-accent {
  background: var(--on-accent);
  color: var(--accent);
  font-weight: 700;
}
.btn-on-accent:hover {
  background: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-2);
}

.nav-cta {
  padding: 9px 18px;
  font-size: 0.88rem;
}

/* ============================================
   Hero
   ============================================ */

.hero {
  position: relative;
  padding: clamp(56px, 9vw, 120px) 0 0;
  overflow: hidden;
  border-bottom: 1px solid var(--outline);
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}
.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(50px);
  opacity: 0.55;
}
.orb-1 {
  top: -8%;
  right: -6%;
  width: 520px;
  height: 520px;
  background: radial-gradient(circle, rgba(253, 246, 230, 0.9), transparent 70%);
}
.orb-2 {
  top: 30%;
  left: -10%;
  width: 460px;
  height: 460px;
  background: radial-gradient(circle, rgba(194, 150, 112, 0.55), transparent 70%);
}
.orb-3 {
  bottom: -10%;
  left: 30%;
  width: 380px;
  height: 380px;
  background: radial-gradient(circle, rgba(141, 103, 72, 0.28), transparent 70%);
}
.grain {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(
      rgba(42, 31, 21, 0.05) 1px,
      transparent 1px
    );
  background-size: 3px 3px;
  opacity: 0.4;
  mix-blend-mode: multiply;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.3fr 0.7fr;
  gap: clamp(var(--lg), 4vw, 64px);
  align-items: center;
  min-height: 600px;
  padding-bottom: var(--xxxl);
}

.hero-copy .cta-row {
  display: flex;
  gap: var(--md);
  flex-wrap: wrap;
  margin-top: var(--lg);
}

.hero-meta {
  list-style: none;
  padding: 0;
  margin: var(--xxl) 0 0;
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: var(--xl);
  max-width: 540px;
  border-top: 1px solid var(--outline);
  padding-top: var(--lg);
}
.hero-meta li {
  display: flex;
  flex-direction: column;
}
.hero-meta strong {
  font-family: var(--font-display);
  font-size: 1.7rem;
  color: var(--text);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.02em;
}
.hero-meta span {
  font-size: 0.74rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--text-muted);
  margin-top: 8px;
  font-weight: 600;
}
html.lang-ja .hero-meta span {
  text-transform: none;
  letter-spacing: 0.04em;
  font-size: 0.82rem;
}

/* Phone mockup */
.phone {
  position: relative;
  justify-self: center;
  max-width: 320px;
  width: 100%;
}
.phone-frame {
  background: var(--bg);
  border: 12px solid #1f1610;
  border-radius: 44px;
  padding: 24px 14px 22px;
  box-shadow: var(--shadow-lift),
    inset 0 0 0 2px rgba(255, 255, 255, 0.06);
  position: relative;
}
.phone-frame::before {
  /* Dynamic-island-ish notch */
  content: "";
  position: absolute;
  top: 6px;
  left: 50%;
  transform: translateX(-50%);
  width: 78px;
  height: 18px;
  background: #1f1610;
  border-radius: 999px;
  z-index: 2;
}
.phone-shadow {
  position: absolute;
  bottom: -34px;
  left: 8%;
  right: 8%;
  height: 40px;
  border-radius: 50%;
  background: radial-gradient(
    closest-side,
    rgba(42, 31, 21, 0.4),
    transparent 70%
  );
  filter: blur(4px);
  z-index: -1;
}

.phone-header {
  display: grid;
  grid-template-columns: 28px 1fr 28px;
  align-items: center;
  gap: 6px;
  padding: 4px 4px 12px;
}
.phone-header .month-pill {
  background: var(--surface);
  border-radius: var(--r-lg);
  text-align: center;
  font-size: 0.92rem;
  color: var(--accent);
  padding: 6px 14px;
  font-weight: 500;
  letter-spacing: 0.06em;
}
.phone-icon-btn {
  appearance: none;
  background: transparent;
  border: 0;
  padding: 0;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: var(--text-soft);
  cursor: default;
}

.day-strip {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  padding: 4px 2px 14px;
}
.day {
  height: 38px;
  display: grid;
  place-items: center;
  font-size: 0.95rem;
  color: var(--text-soft);
  position: relative;
}
.day.muted {
  color: rgba(107, 79, 58, 0.35);
}
.day.selected span {
  background: var(--accent);
  color: #fff;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  font-weight: 600;
}
.day.today i {
  position: absolute;
  bottom: 2px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--today);
}

.phone-section-title {
  text-align: center;
  color: var(--accent);
  letter-spacing: 0.22em;
  font-size: 0.7rem;
  text-transform: uppercase;
  font-weight: 700;
  margin: var(--md) 0 var(--sm);
}
html.lang-ja .phone-section-title {
  letter-spacing: 0.08em;
  text-transform: none;
  font-size: 0.78rem;
}

.card {
  background: var(--surface);
  border-radius: var(--r-md);
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 8px;
}
.card .thumb {
  width: 44px;
  height: 44px;
  border-radius: var(--r-sm);
  flex-shrink: 0;
  display: grid;
  place-items: center;
  background: var(--bg-2);
  color: var(--accent-soft);
}
.card .thumb svg {
  width: 28px;
  height: 28px;
}
.menu-body small {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
html.lang-ja .menu-body small {
  letter-spacing: 0.04em;
  text-transform: none;
  font-size: 0.7rem;
}
.menu-body p {
  margin: 2px 0 0;
  font-size: 0.85rem;
  color: var(--accent);
  line-height: 1.3;
}

.check-row {
  display: grid;
  grid-template-columns: 40px 1fr;
  align-items: center;
  gap: 12px;
  padding: 6px 6px;
}
.check-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  color: var(--accent-soft);
}
.check-icon svg {
  width: 28px;
  height: 28px;
}
.check-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.check-label {
  font-size: 0.78rem;
  color: var(--text-soft);
  font-weight: 500;
}
.bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 3px;
  height: 24px;
}
.bars .bar {
  width: 8px;
  height: var(--h);
  border-radius: 2px 2px 0 0;
  border: 1.5px solid var(--accent-soft);
  background: transparent;
  transition: background 200ms ease;
}
.bars .bar.on {
  background: var(--accent);
  border-color: var(--accent);
}

/* ============================================
   Bands
   ============================================ */

.band {
  padding: clamp(80px, 9vw, 140px) 0;
  position: relative;
}
.band-cream {
  background: var(--bg-2);
}
.band-accent {
  background: var(--text);
  color: var(--on-accent);
}

.band-head {
  max-width: 780px;
  margin-bottom: var(--xxl);
}
.band-head .lede {
  margin-top: var(--md);
}

/* ============================================
   Verse section (the manifesto)
   ============================================ */

.band-verse {
  background:
    radial-gradient(
      ellipse 800px 500px at 50% 20%,
      rgba(194, 150, 112, 0.14),
      transparent 70%
    ),
    var(--bg-3);
  position: relative;
}

.verse-wrap {
  max-width: 760px;
  margin-inline: auto;
  text-align: center;
  position: relative;
}
.verse-title {
  margin: 0 auto var(--xxl);
  font-family: var(--font-verse);
  font-weight: 500;
  font-style: italic;
  font-size: clamp(1.7rem, 3.4vw, 2.6rem);
  letter-spacing: -0.01em;
  line-height: 1.25;
  max-width: 22ch;
}
html.lang-ja .verse-title {
  font-family: "Noto Serif JP", serif;
  font-style: normal;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.5;
}

.verse {
  display: flex;
  flex-direction: column;
  gap: var(--lg);
  font-family: var(--font-verse);
  text-align: center;
}
html.lang-ja .verse {
  font-family: "Noto Serif JP", "Hiragino Mincho ProN", serif;
}
.verse-p {
  margin: 0;
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  line-height: 1.85;
  color: var(--text);
  font-weight: 400;
}
.verse-p em {
  font-style: italic;
  font-weight: 600;
  color: var(--accent);
}
html.lang-ja .verse-p em {
  font-style: normal;
}
.verse-p-strong {
  font-weight: 600;
  font-size: clamp(1.2rem, 1.6vw, 1.45rem);
  color: var(--accent-deep);
  margin: var(--md) 0;
}
.verse-p-quote {
  font-style: italic;
  color: var(--text-soft);
  position: relative;
  padding: 0 var(--lg);
}
html.lang-ja .verse-p-quote {
  font-style: normal;
}
.verse-p-coda {
  font-weight: 600;
  font-size: clamp(1.15rem, 1.5vw, 1.35rem);
  color: var(--accent-deep);
  margin-top: var(--md);
}

.verse-rule {
  width: 60px;
  height: 1px;
  background: var(--accent-soft);
  margin: var(--md) auto;
}

/* ============================================
   Pillars
   ============================================ */

.card-soft {
  background: var(--surface);
  border-radius: var(--r-lg);
  padding: clamp(var(--lg), 2.5vw, 36px);
  box-shadow: var(--shadow-1);
  border: 1px solid rgba(212, 202, 177, 0.6);
  transition: transform 240ms ease, box-shadow 240ms ease;
}
.card-soft:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-2);
}

.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--lg);
}
.pillar h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  margin: var(--sm) 0 var(--md);
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
  line-height: 1.2;
}
.pillar p {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--text-soft);
}
.pillar-num {
  font-family: var(--font-display);
  color: var(--accent-soft);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.18em;
}

/* ============================================
   App section
   ============================================ */

.app-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--lg), 5vw, 80px);
  align-items: center;
}
.app-title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 900;
  letter-spacing: -0.02em;
  margin: 0 0 var(--md);
  line-height: 1;
}
html.lang-ja .app-title {
  letter-spacing: 0;
}

.features {
  margin-top: var(--xl);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--lg) var(--xl);
}
.feature {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: var(--md);
  align-items: start;
}
.feature-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  background: var(--surface);
  color: var(--accent);
  border-radius: 50%;
  border: 1px solid var(--outline);
  flex-shrink: 0;
}
.feature-icon svg {
  width: 22px;
  height: 22px;
}
.feature {
  grid-template-columns: 40px 1fr;
}
.feature h4 {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin: 0 0 4px;
  color: var(--text);
  font-weight: 700;
  letter-spacing: -0.01em;
}
.feature p {
  margin: 0;
  font-size: 0.92rem;
  color: var(--text-soft);
  line-height: 1.55;
}

/* App mosaic */
.app-mosaic {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: var(--md);
  aspect-ratio: 4 / 5;
  max-width: 520px;
  margin-inline: auto;
  width: 100%;
}
.mosaic-card {
  position: relative;
  border-radius: var(--r-lg);
  overflow: hidden;
  margin: 0;
  box-shadow: var(--shadow-1);
  background: var(--surface);
  border: 1px solid var(--outline);
  display: grid;
  place-items: center;
  padding: var(--xl);
  transition: transform 240ms ease, box-shadow 240ms ease,
    border-color 240ms ease;
}
.mosaic-card:nth-child(4n + 1) { background: var(--bg-3); }
.mosaic-card:nth-child(4n + 2) { background: var(--bg-2); }
.mosaic-card:nth-child(4n + 3) { background: var(--bg);   }
.mosaic-card:nth-child(4n)     { background: var(--bg-3); }
.mosaic-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent-soft);
  box-shadow: var(--shadow-2);
}
.mosaic-svg {
  width: 60%;
  max-width: 120px;
  height: auto;
  aspect-ratio: 1 / 1;
  color: var(--accent-soft);
  transition: color 240ms ease, transform 400ms ease;
}
.mosaic-card:hover .mosaic-svg {
  color: var(--accent);
  transform: scale(1.05);
}
.mosaic-card figcaption {
  position: absolute;
  left: 14px;
  bottom: 12px;
  font-family: var(--font-display);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--text-soft);
}
.mc-a {
  grid-column: 1;
  grid-row: 1 / span 2;
}
.mc-b {
  grid-column: 2;
  grid-row: 1;
}
.mc-c {
  grid-column: 2;
  grid-row: 2;
}
.mc-d {
  display: none;
}

/* ============================================
   Journal / blog
   ============================================ */

.journal {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--lg);
}
.post {
  display: flex;
  flex-direction: column;
  gap: var(--md);
  position: relative;
  overflow: hidden;
}
.post::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent);
  transform: translateY(-3px);
  transition: transform 240ms ease;
}
.post:hover::before {
  transform: translateY(0);
}
.post-meta {
  display: flex;
  gap: var(--md);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  font-weight: 700;
}
.post-meta span:last-child {
  color: var(--text-muted);
}
html.lang-ja .post-meta {
  text-transform: none;
  letter-spacing: 0.04em;
  font-size: 0.85rem;
}
.post h3 {
  font-family: var(--font-display);
  font-size: 1.35rem;
  margin: 0;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.015em;
  line-height: 1.25;
}
.post p {
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-soft);
  line-height: 1.65;
}
.post-cta {
  align-self: flex-start;
  font-weight: 600;
  font-size: 0.85rem;
  color: var(--accent);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: auto;
  padding-top: var(--sm);
}
.post-cta::after {
  content: " →";
  transition: transform 200ms ease;
  display: inline-block;
}
.post-cta:hover::after {
  transform: translateX(4px);
}
html.lang-ja .post-cta {
  text-transform: none;
  letter-spacing: 0.04em;
}

/* ============================================
   Contact / CTA
   ============================================ */

.cta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--lg), 5vw, 80px);
  align-items: center;
}
.cta-grid .section-tag.light {
  color: #ffd4a3;
}
.email-link {
  display: inline-block;
  margin-top: var(--lg);
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.2vw, 1.7rem);
  font-weight: 600;
  color: var(--on-accent);
  border-bottom: 1px solid rgba(255, 250, 240, 0.3);
  padding-bottom: 4px;
  letter-spacing: -0.005em;
}
.email-link:hover {
  color: #fff;
  border-color: rgba(255, 250, 240, 0.7);
}

.contact-card {
  background: var(--bg-3);
  border-radius: var(--r-xl);
  padding: clamp(var(--lg), 2.5vw, 40px);
  display: flex;
  flex-direction: column;
  gap: var(--md);
  box-shadow: var(--shadow-2);
  color: var(--text);
}
.contact-card label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.78rem;
  color: var(--text-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 700;
}
html.lang-ja .contact-card label {
  letter-spacing: 0.04em;
  text-transform: none;
  font-size: 0.88rem;
  font-weight: 600;
}
.contact-card input,
.contact-card textarea {
  font-family: inherit;
  font-size: 1rem;
  color: var(--text);
  background: var(--surface);
  border: 1.5px solid transparent;
  border-radius: var(--r-md);
  padding: 13px 14px;
  outline: none;
  resize: vertical;
  transition: border-color 160ms ease, box-shadow 160ms ease;
  text-transform: none;
  letter-spacing: 0;
}
.contact-card input::placeholder,
.contact-card textarea::placeholder {
  color: var(--hint);
}
.contact-card input:focus,
.contact-card textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px rgba(141, 103, 72, 0.14);
}
.contact-card .btn {
  align-self: flex-start;
}
.contact-card .form-status {
  font-size: 0.92rem;
  text-transform: none;
  letter-spacing: 0;
  margin: 0;
  font-weight: 500;
  padding: 10px 14px;
  border-radius: var(--r-md);
  background: rgba(141, 103, 72, 0.08);
  color: var(--accent);
}
.contact-card .form-status[data-tone="err"] {
  background: rgba(212, 88, 91, 0.08);
  color: var(--today);
}
.contact-card .btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

/* ============================================
   Footer
   ============================================ */

.site-footer {
  background: #1f1610;
  color: #d8c9b6;
  padding: var(--xxxl) 0 var(--lg);
}
.site-footer .brand,
.site-footer h5 {
  color: var(--on-accent);
}
.site-footer a {
  color: #d8c9b6;
}
.site-footer a:hover {
  color: var(--on-accent);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: var(--lg);
  padding-bottom: var(--xl);
  border-bottom: 1px solid rgba(216, 201, 182, 0.12);
  align-items: start;
}
.site-footer h5 {
  font-family: var(--font-display);
  margin: 0 0 var(--md);
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.site-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.site-footer .muted {
  color: #a8957f;
}
.legal {
  display: flex;
  justify-content: space-between;
  padding-top: var(--lg);
  flex-wrap: wrap;
  gap: var(--sm);
}

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 980px) {
  .hero-grid {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-bottom: var(--xxl);
  }
  .phone {
    margin-top: var(--xl);
    max-width: 300px;
  }
  .app-grid,
  .cta-grid {
    grid-template-columns: 1fr;
  }
  .pillars,
  .journal {
    grid-template-columns: 1fr;
  }
  .features {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .nav-links,
  .nav-right {
    display: none;
  }
  .nav-toggle {
    display: flex;
  }
}

@media (max-width: 600px) {
  .display {
    font-size: clamp(2.6rem, 13vw, 4rem);
  }
  .hero-meta {
    grid-template-columns: repeat(3, 1fr);
    gap: var(--md);
  }
  .hero-meta strong {
    font-size: 1.3rem;
  }
  .hero-meta span {
    font-size: 0.66rem;
  }
  html.lang-ja .hero-meta span {
    font-size: 0.72rem;
  }
  .app-mosaic {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 170px 170px;
    aspect-ratio: auto;
    max-width: none;
  }
  .mc-a { grid-column: 1; grid-row: 1; }
  .mc-b { grid-column: 2; grid-row: 1; }
  .mc-c { grid-column: 1; grid-row: 2; }
  .mc-d { display: block; grid-column: 2; grid-row: 2; }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .legal {
    flex-direction: column;
  }
  .nav {
    gap: var(--sm);
  }
  .verse-p {
    font-size: 1rem;
    line-height: 1.8;
  }
  .verse-title {
    font-size: clamp(1.5rem, 6vw, 2rem);
  }
}

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