/* ═══════════════ OKURU — warm film design system ═══════════════ */

:root {
  --paper: #f7f1e8;
  --paper-deep: #efe5d6;
  --ink: #211c18;
  --ink-soft: #5c5248;
  --accent: #c96f4a;
  --accent-deep: #a9532f;
  --accent-soft: #e8b18f;
  --gold: #c9a24b;
  --white: #fffdf9;
  --serif: 'Shippori Mincho B1', serif;
  --sans: 'Zen Kaku Gothic New', sans-serif;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: auto; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 400;
  line-height: 1.9;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--accent-soft); color: var(--ink); }

a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 2px solid var(--accent-deep);
  outline-offset: 3px;
}
.scene--hero :focus-visible, .film :focus-visible {
  outline-color: var(--white);
}

/* ── film grain ── */
.film-grain {
  position: fixed; inset: -50%;
  width: 200%; height: 200%;
  pointer-events: none; z-index: 90;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 250 250' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  animation: grain 8s steps(10) infinite;
}
@keyframes grain {
  0%, 100% { transform: translate(0, 0); }
  20% { transform: translate(-3%, 2%); }
  40% { transform: translate(2%, -3%); }
  60% { transform: translate(-2%, -2%); }
  80% { transform: translate(3%, 3%); }
}

/* ── brand ── */
.brand {
  position: fixed; top: 0; left: 0; right: 0; z-index: 80;
  display: flex; justify-content: space-between; align-items: center;
  padding: 22px 34px;
  mix-blend-mode: normal;
}
.brand__mark {
  font-family: var(--serif); font-weight: 800; font-size: 22px;
  letter-spacing: 0.14em; text-decoration: none; color: var(--white);
  transition: color 0.5s var(--ease-out);
}
.brand--dark .brand__mark { color: var(--ink); }
.brand__dot { color: var(--accent); }
.brand__nedari {
  font-family: var(--sans); font-size: 12.5px; letter-spacing: 0.08em;
  background: rgba(255, 253, 249, 0.12); color: var(--white);
  border: 1px solid rgba(255, 253, 249, 0.4);
  backdrop-filter: blur(8px);
  padding: 9px 18px; border-radius: 100px; cursor: pointer;
  transition: background 0.4s var(--ease-out), border-color 0.4s var(--ease-out), color 0.4s var(--ease-out), transform 0.4s var(--ease-out);
}
.brand--dark .brand__nedari { color: var(--ink); border-color: rgba(33, 28, 24, 0.3); background: rgba(33, 28, 24, 0.04); }
.brand__nedari:hover { background: var(--accent); border-color: var(--accent); color: var(--white); transform: translateY(-2px); }

/* ── account / login (リボン system) ── */
.brand__login {
  font-family: var(--sans); font-size: 12.5px; letter-spacing: 0.08em;
  background: rgba(255, 253, 249, 0.12); color: var(--white);
  border: 1px solid rgba(255, 253, 249, 0.4);
  backdrop-filter: blur(8px);
  padding: 9px 18px; border-radius: 100px; cursor: pointer;
  margin-left: 10px;
  transition: background 0.4s var(--ease-out), border-color 0.4s var(--ease-out), color 0.4s var(--ease-out);
}
.brand--dark .brand__login { color: var(--ink); border-color: rgba(33, 28, 24, 0.3); background: rgba(33, 28, 24, 0.04); }
.brand__login:hover { background: var(--accent); border-color: var(--accent); color: var(--white); }
.brand__account { position: relative; margin-left: 10px; }
.brand__avatarbtn {
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--white); border: 1px solid rgba(33, 28, 24, 0.15);
  display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 4px 16px rgba(33, 28, 24, 0.12);
}
.brand__menu {
  position: absolute; right: 0; top: 52px; z-index: 60;
  background: var(--white); border: 1px solid rgba(33, 28, 24, 0.1);
  border-radius: 16px; padding: 10px; min-width: 232px;
  box-shadow: 0 18px 50px rgba(33, 28, 24, 0.16);
}
.brand__menu-balance {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: var(--ink); font-weight: 700;
  padding: 8px 10px 10px; border-bottom: 1px solid rgba(33, 28, 24, 0.08);
  margin-bottom: 6px;
}
.brand__menu-item {
  display: block; width: 100%; text-align: left;
  font-family: var(--sans); font-size: 13.5px; color: var(--ink);
  background: none; border: 0; border-radius: 10px;
  padding: 10px; cursor: pointer;
}
.brand__menu-item:hover { background: rgba(201, 111, 74, 0.08); }

/* ── credit modal ── */
.creditmodal {
  position: fixed; inset: 0; z-index: 130;
  background: rgba(23, 18, 14, 0.55); backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.4s ease;
}
.creditmodal.is-open { opacity: 1; pointer-events: auto; }
.creditmodal__panel {
  position: relative; background: var(--white);
  border-radius: 24px; padding: 40px 34px 30px;
  width: min(420px, calc(100vw - 40px));
  text-align: center;
  box-shadow: 0 30px 80px rgba(23, 18, 14, 0.3);
  transform: translateY(10px); transition: transform 0.4s var(--ease-out);
}
.creditmodal.is-open .creditmodal__panel { transform: translateY(0); }
.creditmodal__ribbon { display: block; margin: 0 auto 14px; }
.creditmodal__context { font-size: 12.5px; color: var(--ink-soft); margin-bottom: 10px; }
.creditmodal__title {
  font-family: var(--serif); font-weight: 700; font-size: 20px;
  color: var(--ink); margin-bottom: 12px; line-height: 1.6;
}
.creditmodal__body { font-size: 13.5px; color: var(--ink-soft); line-height: 2; margin-bottom: 18px; }
.creditmodal__actions { display: flex; flex-direction: column; gap: 10px; align-items: center; }
.creditmodal__gis { min-height: 44px; display: flex; justify-content: center; }
.creditmodal__gis-unavailable { font-size: 12.5px; color: var(--ink-soft); }
.creditmodal__btn {
  display: inline-block; width: 280px; max-width: 100%;
  font-family: var(--sans); font-size: 13.5px; font-weight: 700;
  padding: 12px 18px; border-radius: 100px; cursor: pointer;
  text-decoration: none; text-align: center; border: 0;
}
.creditmodal__btn--line { background: #06c755; color: #fff; }
.creditmodal__btn--ghost { background: none; border: 1px solid rgba(33, 28, 24, 0.25); color: var(--ink); }
.creditmodal__note { font-size: 11.5px; color: rgba(92, 82, 72, 0.75); line-height: 1.9; margin-top: 16px; }
.creditmodal__close {
  position: absolute; right: 16px; top: 12px;
  background: none; border: 0; cursor: pointer;
  font-family: var(--sans); font-size: 12px; color: var(--ink-soft);
  padding: 8px;
}

/* ── toast ── */
.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 140;
  transform: translate(-50%, 16px);
  display: flex; align-items: center; gap: 10px;
  background: var(--white); color: var(--ink);
  border: 1px solid rgba(33, 28, 24, 0.1);
  border-radius: 100px; padding: 11px 20px;
  font-size: 13px; font-weight: 600;
  box-shadow: 0 16px 44px rgba(23, 18, 14, 0.22);
  opacity: 0; transition: opacity 0.35s ease, transform 0.35s var(--ease-out);
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ── freshness note ── */
.result__freshnote {
  text-align: center; font-size: 13px; color: var(--ink-soft);
  background: rgba(201, 111, 74, 0.07); border-radius: 10px;
  padding: 10px 14px; margin: 14px auto 0; max-width: 560px;
}

/* ── shared line reveal ── */
.line { display: block; overflow: hidden; }
.line__inner { display: block; transform: translateY(115%); }

/* ═══ SCENE 0 · HERO ═══ */
.scene { position: relative; }
.scene--hero {
  height: 100svh; min-height: 620px;
  display: flex; align-items: flex-end;
  overflow: hidden;
  background: #17120e;
}
.hero__video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover;
  filter: saturate(1.05);
}
.hero__video--b { opacity: 0; }
.hero__sound {
  position: absolute; left: 6vw; bottom: 5svh; z-index: 5;
  font-family: var(--sans); font-size: 12px; letter-spacing: 0.12em;
  color: var(--white); background: rgba(18, 13, 9, 0.35);
  border: 1px solid rgba(255, 253, 249, 0.45);
  backdrop-filter: blur(8px);
  padding: 9px 20px; border-radius: 100px; cursor: pointer;
  transition: background 0.35s var(--ease-out), transform 0.35s var(--ease-out);
}
.hero__sound:hover { background: rgba(255, 253, 249, 0.2); transform: translateY(-2px); }
.hero__sound::before {
  content: ''; display: inline-block; width: 7px; height: 7px;
  border-radius: 50%; background: var(--accent-soft); margin-right: 9px;
  animation: breathe-dot 2s ease-in-out infinite;
}
@keyframes breathe-dot { 0%, 100% { opacity: 0.5; } 50% { opacity: 1; } }
.hero__shade {
  position: absolute; inset: 0;
  background:
    linear-gradient(to top, rgba(18, 13, 9, 0.88) 0%, rgba(18, 13, 9, 0.35) 38%, rgba(18, 13, 9, 0.12) 60%, rgba(18, 13, 9, 0.3) 100%);
}
/* copy zone ends above the subtitle safe band (lower ~24svh is reserved) */
.hero__copy {
  position: relative; z-index: 3;
  padding: 0 6vw 26svh;
  max-width: 900px;
}
.hero__kicker {
  font-size: clamp(13px, 1.4vw, 16px); letter-spacing: 0.34em;
  color: var(--accent-soft); margin-bottom: 18px; font-weight: 500;
}
.hero__title {
  font-family: var(--serif); font-weight: 700;
  font-size: clamp(38px, 6.2vw, 78px);
  line-height: 1.35; color: var(--white);
  margin-bottom: 22px;
  text-shadow: 0 2px 30px rgba(0, 0, 0, 0.35);
}
.hero__lead {
  font-size: clamp(14px, 1.5vw, 17px); color: rgba(255, 253, 249, 0.85);
  margin-bottom: 34px; letter-spacing: 0.04em;
}
.hero__cta {
  display: inline-block;
  font-family: var(--sans); font-weight: 700; font-size: 15.5px; letter-spacing: 0.12em;
  color: var(--ink); background: var(--white);
  padding: 17px 44px; border-radius: 100px; text-decoration: none;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out), background 0.35s;
}
.hero__cta:hover { background: var(--accent); color: var(--white); box-shadow: 0 16px 50px rgba(201, 111, 74, 0.45); }

/* karaoke subtitle */
/* subtitle safe band: exclusive lower third — headline/copy never enter */
.hero__sub {
  position: absolute; z-index: 4;
  left: 50%; bottom: 9svh; transform: translateX(-50%);
  max-height: 22svh;
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(17px, 2.2vw, 26px);
  color: var(--white); letter-spacing: 0.06em;
  background: rgba(18, 13, 9, 0.5);
  backdrop-filter: blur(6px);
  padding: 10px 26px; border-radius: 12px;
  white-space: nowrap; max-width: 92vw;
  opacity: 0; transition: opacity 0.45s ease;
  text-align: center;
}
.hero__sub.is-on { opacity: 1; }
.hero__sub .sub-char {
  display: inline-block;
  opacity: 0.22; filter: blur(6px); transform: translateY(8px);
  transition: opacity 0.25s ease, filter 0.25s ease, transform 0.25s var(--ease-out);
}
.hero__sub .sub-char.lit { opacity: 1; filter: blur(0); transform: translateY(0); }

.hero__scrollhint {
  position: absolute; right: 6vw; bottom: 5svh; z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
}
.hero__scrollhint-line {
  width: 1px; height: 54px; background: rgba(255, 253, 249, 0.5);
  position: relative; overflow: hidden;
}
.hero__scrollhint-line::after {
  content: ''; position: absolute; left: 0; top: -40%;
  width: 100%; height: 40%; background: var(--white);
  animation: scrollpulse 1.8s var(--ease-out) infinite;
}
@keyframes scrollpulse { 0% { top: -40%; } 100% { top: 110%; } }
.hero__scrollhint-text {
  font-size: 10px; letter-spacing: 0.4em; color: rgba(255, 253, 249, 0.7);
  text-transform: uppercase; writing-mode: vertical-rl;
}

/* ═══ SCENE 4 · INPUT ═══ */




.input__form { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.input__field {
  display: flex; align-items: center;
  background: var(--white); border: 2px solid rgba(33, 28, 24, 0.1);
  border-radius: 100px; padding: 0 8px 0 26px;
  flex: 1 1 300px; max-width: 400px;
  transition: border-color 0.35s, box-shadow 0.35s;
}
.input__field:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 5px rgba(201, 111, 74, 0.12), 0 14px 44px rgba(33, 28, 24, 0.1);
}
.input__at { font-family: var(--serif); font-size: 20px; color: var(--accent); font-weight: 700; margin-right: 8px; }
.input__handle {
  border: none; outline: none; background: transparent;
  font-family: var(--sans); font-size: 17px; letter-spacing: 0.03em;
  padding: 19px 8px; width: 100%; color: var(--ink);
}
.input__go {
  font-family: var(--sans); font-weight: 700; font-size: 15.5px; letter-spacing: 0.1em;
  background: var(--ink); color: var(--white);
  border: none; border-radius: 100px; padding: 19px 40px; cursor: pointer;
  transition: background 0.35s, transform 0.35s var(--ease-out), box-shadow 0.35s;
}
.input__go:hover { background: var(--accent); box-shadow: 0 14px 40px rgba(201, 111, 74, 0.4); }
.input__go:disabled { opacity: 0.55; cursor: wait; }
.input__err { color: var(--accent-deep); font-size: 13.5px; min-height: 26px; margin-top: 14px; }
.input__mode {
  margin-top: 26px; background: none; border: none; cursor: pointer;
  font-family: var(--sans); font-size: 13.5px; color: var(--ink-soft);
  border-bottom: 1px dashed rgba(33, 28, 24, 0.35); padding-bottom: 3px;
  transition: color 0.3s;
  display: inline-flex; align-items: center; gap: 8px;
}
.input__mode-ico { border-radius: 50%; box-shadow: 0 3px 10px rgba(33, 28, 24, 0.15); transition: transform 0.35s var(--ease-out); }
.input__mode:hover .input__mode-ico { transform: rotate(-10deg) scale(1.12); }
.input__mode:hover { color: var(--accent-deep); border-color: var(--accent-deep); }
.input__note { margin-top: 30px; font-size: 11.5px; color: rgba(92, 82, 72, 0.65); letter-spacing: 0.04em; }

/* ═══ ANALYZING OVERLAY ═══ */
.analyzing {
  position: fixed; inset: 0; z-index: 100;
  background: radial-gradient(ellipse at 50% 40%, #2c241d 0%, #17120e 70%);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  /* visibility flips AFTER the fade-out so the close still animates; while
     hidden the browser paints nothing here */
  visibility: hidden;
  transition: opacity 0.7s ease, visibility 0s 0.7s;
}
.analyzing.is-open { opacity: 1; pointer-events: auto; visibility: visible; transition: opacity 0.7s ease; }
/* the closed overlay used to keep 7 animations ticking invisibly (2x enso ring
   incl. drop-shadow + 5 skeleton shimmers) — measured running on the idle
   landing page 2026-08-04 while the owner reported severe scroll jank */
.analyzing:not(.is-open) * { animation-play-state: paused !important; }
.analyzing__stage { text-align: center; padding: 0 6vw; max-width: 720px; }

/* 点の輪 — dots circling the concierge (owner request 2026-08-03: the solid
   brush ring read as a broken loading bar in captures). Layer 1: always present,
   carries the screen alone if the character loop can't play. */
.enso { width: clamp(120px, 26vw, 168px); height: auto; display: block; margin: 0 auto 34px; }

/* the concierge works inside the circle. Video is the top layer only; under it a
   still of the same pose, and under that the circle alone — each falls back cleanly. */
.charstage { position: relative; width: clamp(212px, 56vw, 332px); aspect-ratio: 1 / 1; margin: 0 auto 26px; }
.charstage .enso { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; }
.charstage__disc {
  position: absolute; left: 20.5%; top: 19%; width: 63%; height: 63%;
  border-radius: 50%; overflow: hidden; background: var(--paper, #f7f1e8);
  box-shadow: 0 0 48px rgba(201, 111, 74, 0.24);
  opacity: 0; transform: scale(0.92);
  transition: opacity 0.9s var(--ease-out), transform 0.9s var(--ease-out);
}
.charstage__disc.is-on { opacity: 1; transform: scale(1); }
.charstage__still, .charstage__clip {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 40%;
  opacity: 0; transition: opacity 0.7s ease;
}
.charstage__still.is-on, .charstage__clip.is-on { opacity: 1; }
.enso__stroke {
  stroke: var(--accent);
  stroke-width: 7;
  /* pathLength=48 on the circle → period 4 tiles 12 identical dots; the seam
     never shows because 48/4 is exact. One period per 1.3s ≈ one calm lap
     every ~15s — motion that says "working", not "hurrying".
     No filter here: an animated drop-shadow forced a stroke re-blur every
     frame; the disc's static box-shadow already carries the warm glow. */
  stroke-dasharray: 0.1 3.9;
  animation: enso-march 1.3s linear infinite,
             enso-breathe 3.4s ease-in-out infinite;
}
@keyframes enso-march { to { stroke-dashoffset: -4; } }
@keyframes enso-breathe {
  0%, 100% { opacity: 0.78; }
  50% { opacity: 1; }
}

.analyzing__handle {
  font-size: 13px; color: rgba(247, 241, 232, 0.5);
  letter-spacing: 0.14em; margin-bottom: 14px;
}
.analyzing__line {
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(18px, 2.5vw, 27px); color: var(--paper);
  letter-spacing: 0.08em; min-height: 2.6em; line-height: 1.8;
  white-space: pre-line; line-break: strict; word-break: keep-all;
  transition: opacity 0.5s ease;
}

/* honest stage dots — the last one fills only when the result actually lands */
.analyzing__dots { list-style: none; display: flex; gap: 11px; justify-content: center; margin: 22px 0 0; }
.analyzing__dots li {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(247, 241, 232, 0.22);
  transition: background 0.6s var(--ease-out), transform 0.6s var(--ease-out);
}
.analyzing__dots li.is-on { background: var(--accent-soft); transform: scale(1.3); }
.analyzing__dots li.is-now { animation: dot-pulse 1.8s ease-in-out infinite; }
@keyframes dot-pulse { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }

.analyzing__tip {
  margin-top: 26px; font-size: 13px; line-height: 1.9;
  white-space: pre-line;
  color: rgba(247, 241, 232, 0.5);
  min-height: 3.6em; opacity: 0; transition: opacity 0.7s ease;
}
.analyzing__tip.is-on { opacity: 1; }

/* the shape of what's coming */
.analyzing__skeleton { display: flex; gap: 9px; justify-content: center; margin-top: 28px; opacity: 0; transition: opacity 0.8s ease; }
.analyzing__skeleton.is-on { opacity: 1; }
.analyzing__skeleton span {
  width: 34px; height: 44px; border-radius: 6px;
  background: linear-gradient(100deg, rgba(247,241,232,0.06) 30%, rgba(247,241,232,0.16) 50%, rgba(247,241,232,0.06) 70%);
  background-size: 220% 100%;
  animation: skel-shimmer 2.4s linear infinite;
}
.analyzing__skeleton span:nth-child(2) { animation-delay: 0.18s; }
.analyzing__skeleton span:nth-child(3) { animation-delay: 0.36s; }
.analyzing__skeleton span:nth-child(4) { animation-delay: 0.54s; }
.analyzing__skeleton span:nth-child(5) { animation-delay: 0.72s; }
@keyframes skel-shimmer { 0% { background-position: 140% 0; } 100% { background-position: -40% 0; } }

.analyzing__promise { margin-top: 30px; font-size: 12.5px; color: rgba(247, 241, 232, 0.42); letter-spacing: 0.06em; }
/* A re-run press does not yet know whether a full analysis will start, so the
   time promise is held until the server says one did. It keeps its space while
   held: nothing below it moves when the line arrives. */
.analyzing__promise.is-held { visibility: hidden; }
.analyzing__cancel {
  margin-top: 16px; background: none; border: none; cursor: pointer;
  font-family: var(--sans); font-size: 13px; color: rgba(247, 241, 232, 0.55);
  border-bottom: 1px solid rgba(247, 241, 232, 0.25); padding-bottom: 2px;
  transition: color 0.35s, border-color 0.35s;
}
.analyzing__cancel:hover { color: var(--paper); border-color: var(--paper); }

/* ═══ RESULT ═══ */
.result {
  display: none;
  background: var(--paper); min-height: 100svh;
  padding: 16svh 6vw 12svh;
}
.result.is-open { display: block; }
.result__inner { max-width: 880px; margin: 0 auto; }
.result__head { text-align: center; margin-bottom: 8svh; }
.result__eyebrow { font-size: 13.5px; letter-spacing: 0.22em; color: var(--accent-deep); margin-bottom: 18px; font-weight: 500; }
.result__persona {
  font-family: var(--serif); font-weight: 800;
  font-size: clamp(30px, 4.6vw, 52px); line-height: 1.5; margin-bottom: 20px;
}
.result__summary { color: var(--ink-soft); max-width: 620px; margin: 0 auto 26px; font-size: 15px; }
.result__adnote {
  /* 景表法 clarity bar: recognizable without effort. 13px, full opacity, and
     a soft band so it reads as a deliberate notice, not fine print
     (owner-confirmed strengthening 2026-08-04). */
  text-align: center; font-size: 13px; color: var(--ink-soft);
  letter-spacing: 0.04em; margin: 0 0 16px;
  background: rgba(201, 111, 74, 0.07);
  border-radius: 10px; padding: 9px 14px;
}
.result__keywords { list-style: none; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.result__keywords li {
  font-size: 12.5px; letter-spacing: 0.06em;
  background: var(--white); border: 1px solid rgba(33, 28, 24, 0.12);
  padding: 7px 16px; border-radius: 100px; color: var(--ink-soft);
}

.gift {
  background: var(--white); border-radius: 24px;
  padding: 34px; margin-bottom: 26px;
  box-shadow: 0 14px 50px rgba(33, 28, 24, 0.08);
  transition: transform 0.45s var(--ease-out), box-shadow 0.45s var(--ease-out);
  opacity: 0; transform: translateY(40px);
  display: grid; grid-template-columns: 128px 1fr; gap: 28px; align-items: start;
}
.gift__photo { margin: 0; }
.gift__photo img {
  width: 100%; aspect-ratio: 4 / 5; object-fit: cover;
  border-radius: 14px; background: var(--paper-deep);
}
/* real Amazon product shots come on white — contain them on white with breathing
   room instead of cropping, so the product is always fully visible */
.gift__photo img.gift__photo-product { object-fit: contain; background: #fff; padding: 10%; box-sizing: border-box; }
/* honest search tile: gifts without a resolved product keep a muted, clearly
   non-product photo area with an explicit label (trust — the still must never
   read as the actual product photo) */
.gift__photo--search { position: relative; overflow: hidden; border-radius: 14px; }
.gift--hero .gift__photo--search { border-radius: 18px; }
.gift__photo--search img { filter: grayscale(0.85) contrast(0.9) brightness(1.05); opacity: 0.45; }
.gift__photo-searchnote {
  position: absolute; left: 8px; right: 8px; bottom: 8px;
  background: rgba(33, 28, 24, 0.82); color: #fff;
  font-size: 11px; line-height: 1.55; letter-spacing: 0.03em;
  padding: 7px 9px; border-radius: 9px; text-align: center;
}
.gift--hero .gift__photo-searchnote { font-size: 12px; left: 10px; right: 10px; bottom: 10px; }
.gift--hero { grid-template-columns: 236px 1fr; padding: 40px; }
.gift--hero .gift__photo img { border-radius: 18px; }
.gift--hero .gift__buy { background: var(--accent); }
.gift--hero .gift__buy:hover { background: var(--accent-deep); }
body.is-result #ctaPill { display: none; }
.gift.is-in { opacity: 1; transform: translateY(0); transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out), box-shadow 0.45s var(--ease-out); }
.gift:hover { box-shadow: 0 26px 80px rgba(33, 28, 24, 0.15); transform: translateY(-6px); }
.gift--hero { border: 2px solid var(--accent-soft); position: relative; }
.gift--hero::before {
  content: 'いちばんの、おすすめ';
  position: absolute; top: -14px; left: 40px;
  background: var(--accent); color: var(--white);
  font-size: 12px; letter-spacing: 0.14em; font-weight: 700;
  padding: 6px 18px; border-radius: 100px;
}
.gift__rank { font-family: var(--serif); font-size: 13px; color: var(--accent); letter-spacing: 0.2em; font-weight: 700; }
.gift__name { font-family: var(--serif); font-size: clamp(21px, 2.6vw, 30px); font-weight: 700; margin: 10px 0 6px; }
.gift--hero .gift__name { font-size: clamp(26px, 3.4vw, 38px); }
.gift__desc { font-size: 14px; color: var(--ink-soft); margin-bottom: 18px; }
/* the quote is the climax of the whole read, not its only input — the label
   and the taste tags above it carry that story (owner direction 2026-08-04) */
.gift__tags { display: flex; gap: 8px; flex-wrap: wrap; margin: -4px 0 12px; }
.gift__tag {
  font-size: 12px; font-weight: 700; color: var(--accent-deep, #a9532f);
  background: rgba(201, 111, 74, 0.08);
  border: 1px solid rgba(201, 111, 74, 0.25);
  border-radius: 100px; padding: 4px 12px; letter-spacing: 0.03em;
}
.gift__quote-label {
  font-size: 12px; color: var(--ink-soft); letter-spacing: 0.04em;
  margin-bottom: 6px;
}
.gift__quote {
  border-left: 3px solid var(--accent-soft);
  background: var(--paper);
  font-family: 'Klee One', var(--serif); font-weight: 600; font-size: 15.5px; line-height: 1.9;
  padding: 16px 22px; border-radius: 0 12px 12px 0;
  color: var(--ink); margin-bottom: 16px;
}
.gift__quote::before { content: '『'; color: var(--accent); }
.gift__quote::after { content: '』より'; color: var(--accent); font-size: 12.5px; }
.gift__reason { font-size: 14.5px; margin-bottom: 24px; }
.gift__foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.gift__price { font-size: 13.5px; color: var(--ink-soft); letter-spacing: 0.05em; }
.gift__buy {
  font-weight: 700; font-size: 14px; letter-spacing: 0.08em;
  color: var(--white); background: var(--ink); text-decoration: none;
  padding: 14px 30px; border-radius: 100px;
  transition: background 0.35s, transform 0.35s var(--ease-out);
}
.gift__buy:hover { background: var(--accent); transform: translateY(-2px); }
.gift__rest { display: grid; gap: 26px; }

/* ── share system: grandma-test buttons (≥48px, ≥16px text, explicit verbs) ── */
.result__sharehead {
  text-align: center; font-weight: 700; font-size: 16px;
  margin: 4svh 0 16px;
}
.result__sharebar {
  display: flex; flex-direction: column; gap: 12px;
  max-width: 460px; margin: 0 auto 7svh;
}
/* display:flex must not defeat the hidden attribute (audit bug) */
.result__sharebar[hidden], .stickyshare[hidden] { display: none; }
.result__loop-form .input__field { flex: none; width: 100%; }
.result__sharebar-row { display: flex; gap: 12px; }
.result__sharebar-row .sharebtn { flex: 1; }
.sharebtn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px;
  font-family: var(--sans); font-weight: 700; font-size: 16px; letter-spacing: 0.04em;
  border-radius: 100px; padding: 13px 24px; cursor: pointer;
  text-decoration: none; border: none; text-align: center;
  transition: transform 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out), background 0.3s;
}
.sharebtn--hero { width: 100%; }
.sharebtn:hover { transform: translateY(-2px); }
.sharebtn--line { background: #06c755; color: #fff; }
.sharebtn--line:hover { box-shadow: 0 10px 30px rgba(6, 199, 85, 0.35); }
.sharebtn--x { background: var(--ink); color: var(--white); }
.sharebtn--copy, .sharebtn--native {
  background: var(--white); color: var(--ink);
  border: 1.5px solid rgba(33, 28, 24, 0.25);
  font-size: 15px;
}
.sharebtn--copy:hover, .sharebtn--native:hover { border-color: var(--ink); }
.sharebtn--copy.is-done { background: #e8f7ee; border-color: #06c755; color: #067a3c; }

/* sticky bottom bar: the share/loop moment never scrolls away */
.stickyshare {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 75;
  display: flex; gap: 10px; justify-content: center;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: rgba(247, 241, 232, 0.92);
  backdrop-filter: blur(12px);
  border-top: 1px solid rgba(33, 28, 24, 0.1);
}
.stickyshare .sharebtn { flex: 0 1 300px; }

/* loop module: viewer is one field away from their own result */
.result__loop {
  max-width: 560px; margin: 0 auto 8svh;
  text-align: center;
  background: var(--white); border-radius: 24px;
  border: 2px solid var(--accent-soft);
  padding: 32px 26px;
}
.result__loop-copy { font-weight: 700; font-size: 16.5px; margin-bottom: 18px; }
.result__loop-form { display: flex; flex-direction: column; gap: 12px; }
.result__loop-btn {
  min-height: 52px;
  font-family: var(--sans); font-weight: 700; font-size: 16.5px; letter-spacing: 0.06em;
  color: var(--white); background: var(--accent);
  border: none; border-radius: 100px; cursor: pointer;
  transition: background 0.35s, transform 0.35s var(--ease-out), box-shadow 0.35s;
}
.result__loop-btn:hover { background: var(--accent-deep); box-shadow: 0 14px 40px rgba(201, 111, 74, 0.4); transform: translateY(-2px); }

/* coda tell-a-friend */
.coda__share {
  text-align: center; margin-bottom: 9svh;
  padding: 36px 26px;
  background: var(--white); border-radius: 24px;
  border: 1px solid rgba(33, 28, 24, 0.09);
}
.coda__share-head { font-weight: 700; font-size: 16.5px; margin-bottom: 18px; }
.coda__share-btns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.coda__share-btns .sharebtn--line { min-width: 260px; }

.result__actions { display: flex; gap: 16px; justify-content: center; margin-top: 5svh; flex-wrap: wrap; }
.result__share {
  font-weight: 700; font-size: 15px; letter-spacing: 0.08em;
  background: var(--accent); color: var(--white);
  border: none; border-radius: 100px; padding: 17px 40px; cursor: pointer;
  transition: background 0.35s, transform 0.35s var(--ease-out), box-shadow 0.35s;
}
.result__share:hover { background: var(--accent-deep); box-shadow: 0 14px 40px rgba(201, 111, 74, 0.4); }
.result__again {
  font-size: 14px; background: none; border: 1.5px solid rgba(33, 28, 24, 0.25);
  color: var(--ink-soft); border-radius: 100px; padding: 17px 34px; cursor: pointer;
  transition: border-color 0.35s, color 0.35s;
}
.result__again:hover { border-color: var(--ink); color: var(--ink); }

/* ═══ SHARE CARD ═══ */
.sharecard {
  position: fixed; inset: 0; z-index: 110;
  background: rgba(18, 13, 9, 0.7); backdrop-filter: blur(10px);
  display: none; align-items: center; justify-content: center; padding: 5vh 5vw;
}
.sharecard.is-open { display: flex; }
.sharecard__panel { text-align: center; }
#shareCanvas {
  max-height: 74vh; max-width: 90vw; width: auto;
  border-radius: 18px; box-shadow: 0 30px 100px rgba(0, 0, 0, 0.5);
}
.sharecard__btns { margin-top: 24px; display: flex; gap: 14px; justify-content: center; }
.sharecard__dl {
  font-weight: 700; font-size: 14.5px; text-decoration: none;
  background: var(--white); color: var(--ink);
  padding: 14px 34px; border-radius: 100px;
  transition: background 0.35s var(--ease-out), color 0.35s var(--ease-out);
}
.sharecard__dl:hover { background: var(--accent); color: var(--white); }
.sharecard__close {
  background: none; border: 1px solid rgba(255, 253, 249, 0.4); color: var(--paper);
  font-size: 14px; padding: 14px 30px; border-radius: 100px; cursor: pointer;
}



/* ── responsive ── */
@media (max-width: 780px) {
  .hero__sub { white-space: normal; bottom: 8svh; }
  .hero__title { font-size: min(38px, 10.2vw); }
  .brand { padding: 16px 20px; }
  .gift, .gift--hero { padding: 26px 22px; grid-template-columns: 1fr; gap: 18px; }
  .gift__photo img, .gift--hero .gift__photo img { aspect-ratio: 16 / 10; }
}

@media (prefers-reduced-motion: reduce) {
  .film-grain, .hero__scrollhint-line::after { animation: none; }
  .enso__stroke { animation: none; stroke-dashoffset: 0; }
  .analyzing__dots li.is-now, .analyzing__skeleton span { animation: none; }
  .charstage__disc { transition: opacity 0.4s ease; transform: none; }
  .charstage__clip { display: none; }
  .line__inner { transform: none; }
}
