:root {
  /* DESIGN typography markers: Space Grotesk for `demodemodatte.com` */
  --foam: #FFF9EF;
  --marble: #F3F0E8;
  --vein: #D7D1C4;
  --teal: #0F4C5C;
  --glass: #8FC9C7;
  --ink: #172026;
  --blush: #F4B9A8;
  --brass: #B9935A;
  --slate: #485762;
  --mx: 50%;
  --my: 35%;
  --tilt-x: 0deg;
  --tilt-y: 0deg;
  --chapter-hue: 0deg;
  color: var(--ink);
  font-family: "Noto Sans", system-ui, sans-serif;
  background: var(--foam);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255, 249, 239, .92) 0 12%, rgba(143, 201, 199, .36) 22%, transparent 43%),
    linear-gradient(135deg, #FFF9EF 0%, #F3F0E8 38%, #8FC9C7 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(15, 76, 92, .045) 1px, transparent 1px),
    linear-gradient(0deg, rgba(15, 76, 92, .035) 1px, transparent 1px),
    radial-gradient(ellipse at 50% -10%, rgba(255,255,255,.8), transparent 55%);
  background-size: 84px 84px, 84px 84px, auto;
  mix-blend-mode: multiply;
  opacity: .48;
}

.light-field {
  position: fixed;
  width: 34vmin;
  height: 34vmin;
  left: var(--mx);
  top: var(--my);
  transform: translate(-50%, -50%);
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle, rgba(255, 249, 239, .58), rgba(244, 185, 168, .16) 42%, transparent 70%);
  filter: blur(16px);
  z-index: 3;
}

.site-shell {
  position: relative;
  z-index: 2;
}

.tableau {
  min-height: 100vh;
  display: grid;
  place-items: center;
  position: relative;
  padding: 8vh 6vw;
  isolation: isolate;
}

.tableau::after {
  content: "";
  position: absolute;
  inset: 12vh 12vw;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(15, 76, 92, .11), transparent 64%);
  filter: blur(22px);
  z-index: -1;
}

.museum-label {
  position: absolute;
  max-width: 190px;
  font-family: "Zen Kaku Gothic New", "Noto Sans", sans-serif;
  font-size: .78rem;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: rgba(23, 32, 38, .63);
  border-top: 1px solid rgba(185, 147, 90, .55);
  padding-top: .8rem;
}

.left-label { left: 7vw; top: 36vh; }
.right-label { right: 7vw; bottom: 24vh; text-align: right; }

.reasoning-tray {
  width: min(760px, 88vw);
  min-height: 620px;
  border-radius: 48px;
  padding: 26px;
  transform: perspective(1200px) rotateX(var(--tilt-x)) rotateY(var(--tilt-y));
  transition: transform .24s ease-out;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,249,239,.96), transparent 28%),
    linear-gradient(145deg, #F4B9A8, #B9935A 18%, #172026 20%, #485762 22%, #F3F0E8 31%, #FFF9EF 100%);
  box-shadow:
    0 46px 90px rgba(15, 76, 92, .27),
    0 18px 32px rgba(23, 32, 38, .12),
    inset 0 2px 0 rgba(255, 249, 239, .86),
    inset 0 -14px 30px rgba(23, 32, 38, .18);
}

.tray-lip {
  height: 86px;
  border-radius: 34px 34px 22px 22px;
  display: grid;
  place-items: center;
  position: relative;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,249,239,.72), transparent 34%),
    linear-gradient(180deg, rgba(255,249,239,.3), rgba(23,32,38,.08)),
    repeating-linear-gradient(102deg, rgba(215, 209, 196, .36) 0 2px, transparent 2px 38px),
    #F3F0E8;
  box-shadow: inset 0 4px 8px rgba(255,255,255,.65), inset 0 -8px 18px rgba(72,87,98,.18);
}

.engraved-domain {
  font-family: "Space Grotesk", Inter, system-ui, sans-serif;
  font-weight: 700;
  font-size: clamp(1.7rem, 5vw, 4.35rem);
  letter-spacing: .075em;
  color: transparent;
  background: linear-gradient(180deg, rgba(23,32,38,.78), rgba(255,249,239,.35));
  -webkit-background-clip: text;
  background-clip: text;
  text-shadow: 0 1px 1px rgba(255,249,239,.75), 0 -1px 1px rgba(15,76,92,.28);
}

.brass-pin {
  position: absolute;
  right: 22px;
  top: 22px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: radial-gradient(circle at 32% 28%, #FFF9EF, #B9935A 42%, #6f512b 100%);
  box-shadow: 0 3px 7px rgba(23, 32, 38, .32), inset 0 -2px 3px rgba(23, 32, 38, .23);
}

.marble-basin {
  min-height: 480px;
  margin-top: 20px;
  border-radius: 32px;
  padding: clamp(24px, 5vw, 52px);
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,249,239,.95), transparent 21%),
    radial-gradient(ellipse at 18% 20%, rgba(143,201,199,.28), transparent 38%),
    linear-gradient(125deg, transparent 0 22%, rgba(215,209,196,.8) 23%, transparent 25% 48%, rgba(215,209,196,.6) 49%, transparent 51%),
    repeating-linear-gradient(158deg, rgba(215,209,196,.5) 0 1px, transparent 1px 32px),
    #F3F0E8;
  box-shadow: inset 0 18px 36px rgba(72,87,98,.18), inset 0 -8px 22px rgba(255,249,239,.8);
}

.wave-glyph {
  position: absolute;
  left: 50%;
  top: 22px;
  transform: translateX(-50%);
  font-family: "Zen Kaku Gothic New", sans-serif;
  font-size: 2.4rem;
  color: rgba(15, 76, 92, .28);
}

.token-row, .stone-row {
  display: flex;
  justify-content: center;
  gap: clamp(12px, 3vw, 28px);
  flex-wrap: wrap;
}

.hesitation-token {
  border: 0;
  width: 128px;
  height: 78px;
  border-radius: 999px;
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: .16em;
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 13px 24px rgba(72,87,98,.2), inset 0 4px 9px rgba(255,255,255,.68), inset 0 -8px 13px rgba(72,87,98,.18);
  transition: transform .25s ease, box-shadow .25s ease;
}

.hesitation-token:hover, .hesitation-token.active {
  transform: translateY(5px);
  box-shadow: 0 7px 15px rgba(72,87,98,.18), inset 0 8px 16px rgba(72,87,98,.14), inset 0 -2px 5px rgba(255,255,255,.55);
}

.porcelain { background: linear-gradient(145deg, #FFF9EF, #D7D1C4); }
.shell { background: radial-gradient(circle at 30% 30%, #FFF9EF, #F4B9A8 48%, #D7D1C4); }
.lacquer { background: linear-gradient(145deg, #485762, #172026); color: #FFF9EF; }

.ceramic-slider {
  margin: 44px auto 34px;
  max-width: 500px;
  padding: 20px 24px;
  border-radius: 26px;
  background: rgba(255,249,239,.54);
  box-shadow: inset 0 7px 18px rgba(72,87,98,.16), 0 12px 28px rgba(15,76,92,.1);
}

.slider-label, .side-script, .note-kana {
  display: block;
  font-family: "Zen Kaku Gothic New", "Noto Sans", sans-serif;
  letter-spacing: .18em;
  color: var(--teal);
}

.slider-track {
  display: block;
  height: 18px;
  margin-top: 16px;
  border-radius: 999px;
  background: linear-gradient(90deg, #8FC9C7, #F4B9A8, #B9935A);
  box-shadow: inset 0 3px 7px rgba(23,32,38,.2);
  position: relative;
}

.slider-thumb {
  position: absolute;
  left: var(--slider-left, 8%);
  top: 50%;
  width: 56px;
  height: 36px;
  border-radius: 999px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle at 34% 28%, #FFF9EF, #F3F0E8 55%, #D7D1C4);
  box-shadow: 0 8px 15px rgba(72,87,98,.25), inset 0 -4px 8px rgba(72,87,98,.17);
  transition: left .5s cubic-bezier(.2,.8,.2,1);
}

.dial-and-slip {
  display: grid;
  grid-template-columns: 190px minmax(220px, 1fr);
  gap: 26px;
  align-items: center;
}

.shell-dial {
  width: 186px;
  height: 186px;
  border-radius: 50%;
  position: relative;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,249,239,.95), transparent 28%),
    conic-gradient(from 20deg, #F4B9A8, #FFF9EF, #8FC9C7, #D7D1C4, #F4B9A8);
  box-shadow: 0 18px 35px rgba(72,87,98,.23), inset 0 7px 14px rgba(255,255,255,.68), inset 0 -10px 16px rgba(72,87,98,.16);
  transform: rotate(var(--dial-rotation, 0deg));
  transition: transform .7s cubic-bezier(.2,.8,.2,1);
}

.dial-mark {
  position: absolute;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  letter-spacing: .12em;
  font-size: .8rem;
}
.dial-mark.one { top: 28px; left: 38px; }
.dial-mark.two { bottom: 30px; right: 24px; }
.dial-needle {
  position: absolute;
  left: 50%; top: 50%;
  width: 8px; height: 75px;
  border-radius: 99px;
  transform: translate(-50%, -92%);
  transform-origin: 50% 92%;
  background: var(--brass);
  box-shadow: 0 3px 7px rgba(23,32,38,.25);
}

.washi-note {
  min-height: 168px;
  padding: 30px;
  border-radius: 8px 24px 18px 8px;
  background:
    linear-gradient(120deg, rgba(255,255,255,.35), transparent 38%),
    repeating-linear-gradient(90deg, rgba(215,209,196,.38) 0 1px, transparent 1px 18px),
    #FFF9EF;
  box-shadow: 0 18px 30px rgba(72,87,98,.17), inset 0 0 0 1px rgba(185,147,90,.2);
  transform: translateX(var(--slip-x, 0));
  transition: transform .65s cubic-bezier(.2,.8,.2,1);
}

.washi-note p, .chapter-copy, .drawer-slip p {
  line-height: 1.8;
  color: rgba(23, 32, 38, .78);
  font-weight: 400;
}

.chapter-object {
  width: min(700px, 88vw);
  min-height: 520px;
  border-radius: 44px;
  padding: clamp(30px, 6vw, 68px);
  text-align: center;
  position: relative;
  transform: translateY(34px) scale(.96);
  opacity: .45;
  transition: opacity .75s ease, transform .75s ease;
  box-shadow: 0 42px 80px rgba(15, 76, 92, .24), inset 0 2px 0 rgba(255,255,255,.55);
}

.tableau.in-view .chapter-object {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.chapter-object h1 {
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: clamp(2.2rem, 6vw, 5rem);
  line-height: .96;
  letter-spacing: -.045em;
  margin: 22px auto;
}

.lacquer-lid {
  color: #FFF9EF;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(244,185,168,.35), transparent 24%),
    linear-gradient(145deg, #485762, #172026 68%);
  border: 12px solid #B9935A;
}
.lacquer-lid .chapter-copy { color: rgba(255,249,239,.78); }
.lacquer-lid .side-script { color: #F4B9A8; }

.hanko, .seal-mark {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  margin: 0 auto;
  border: 3px solid #F4B9A8;
  color: #F4B9A8;
  font-family: "Zen Kaku Gothic New", sans-serif;
  font-weight: 700;
  font-size: 1.9rem;
  transform: rotate(-6deg);
}

.inset-ridge {
  display: flex;
  justify-content: space-around;
  max-width: 420px;
  margin: 34px auto;
  padding: 15px;
  border-radius: 999px;
  box-shadow: inset 0 8px 18px rgba(0,0,0,.3), inset 0 -1px 0 rgba(255,255,255,.16);
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: .14em;
}

.tide-pool {
  overflow: hidden;
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,249,239,.85), transparent 24%),
    radial-gradient(circle at 50% 42%, rgba(143,201,199,.86), rgba(15,76,92,.42) 44%, transparent 45%),
    linear-gradient(145deg, #FFF9EF, #F3F0E8);
}

.rings span {
  position: absolute;
  left: 50%; top: 43%;
  width: 140px; height: 140px;
  border: 1px solid rgba(15, 76, 92, .25);
  border-radius: 50%;
  transform: translate(-50%, -50%) scale(1);
  animation: ripple 5.5s infinite ease-out;
}
.rings span:nth-child(2) { animation-delay: 1.4s; }
.rings span:nth-child(3) { animation-delay: 2.8s; }

@keyframes ripple {
  0% { opacity: .55; transform: translate(-50%, -50%) scale(.5); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(4.2); }
}

.stone {
  min-width: 120px;
  padding: 18px 22px;
  border-radius: 999px 999px 80px 999px;
  background: linear-gradient(145deg, #F3F0E8, #D7D1C4);
  box-shadow: 0 14px 26px rgba(72,87,98,.18), inset 0 5px 10px rgba(255,255,255,.6);
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  letter-spacing: .13em;
}
.stone.blush { background: linear-gradient(145deg, #FFF9EF, #F4B9A8); }
.stone.teal { background: linear-gradient(145deg, #8FC9C7, #0F4C5C); color: #FFF9EF; }

.paper-drawer {
  background:
    radial-gradient(circle at var(--mx) var(--my), rgba(255,249,239,.96), transparent 26%),
    linear-gradient(145deg, #F3F0E8, #D7D1C4);
  border: 14px solid #485762;
}
.drawer-top { position: relative; }
.folded-corner {
  position: absolute;
  right: 0; top: -28px;
  width: 64px; height: 64px;
  background: linear-gradient(135deg, #D7D1C4 50%, #FFF9EF 51%);
  box-shadow: -6px 8px 14px rgba(72,87,98,.12);
}
.drawer-slip {
  margin: 22px auto;
  max-width: 520px;
  padding: 24px;
  border-radius: 12px;
  background: #FFF9EF;
  box-shadow: inset 0 0 0 1px rgba(185,147,90,.24), 0 12px 20px rgba(72,87,98,.12);
  transform: translateY(var(--drawer-y, 0));
  transition: transform .6s cubic-bezier(.2,.8,.2,1);
}

.seal-button {
  border: 0;
  padding: 17px 26px;
  border-radius: 999px;
  background: linear-gradient(145deg, #F4B9A8, #B9935A);
  color: #172026;
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  letter-spacing: .12em;
  cursor: pointer;
  box-shadow: 0 14px 20px rgba(72,87,98,.2), inset 0 4px 10px rgba(255,255,255,.38), inset 0 -5px 10px rgba(23,32,38,.16);
}
.seal-button:active { transform: translateY(4px); }
.seal-mark {
  position: absolute;
  right: clamp(38px, 8vw, 100px);
  bottom: clamp(30px, 7vw, 80px);
  opacity: 0;
  color: #F4B9A8;
  border-color: #F4B9A8;
  transition: opacity .3s ease, transform .45s cubic-bezier(.2,.8,.2,1);
}
.seal-mark.visible {
  opacity: 1;
  transform: rotate(-9deg) scale(1.08);
}

.chapter-nav {
  position: fixed;
  right: 24px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 5;
  display: grid;
  gap: 12px;
}
.nav-dot {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  text-decoration: none;
  color: var(--teal);
  font-family: "Zen Kaku Gothic New", sans-serif;
  background: rgba(255,249,239,.62);
  box-shadow: inset 0 2px 6px rgba(255,255,255,.7), 0 8px 16px rgba(72,87,98,.12);
  transition: background .25s ease, color .25s ease, transform .25s ease;
}
.nav-dot.active {
  color: #FFF9EF;
  background: var(--teal);
  transform: scale(1.08);
}

@media (max-width: 760px) {
  .museum-label { display: none; }
  .reasoning-tray { min-height: auto; padding: 14px; border-radius: 30px; }
  .tray-lip { height: 70px; }
  .marble-basin { min-height: auto; padding-top: 58px; }
  .dial-and-slip { grid-template-columns: 1fr; justify-items: center; }
  .chapter-nav { right: 10px; }
  .chapter-object { min-height: auto; }
  .hesitation-token { width: 105px; height: 62px; }
}
