:root {
  --ink: #202427;
  --muted: #69727a;
  --line: rgba(32, 36, 39, 0.12);
  --paper: #f8f3e8;
  --surface: #fffaf0;
  --jade: #2f6d62;
  --jade-dark: #19463f;
  --cinnabar: #9d352c;
  --gold: #c79b4b;
  --blue: #315d84;
  --shadow: 0 22px 60px rgba(21, 18, 12, 0.22);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  color: var(--ink);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  background:
    linear-gradient(135deg, rgba(47, 109, 98, 0.16), transparent 32%),
    linear-gradient(160deg, #f3ebdd 0%, #e8dbc6 44%, #d4ded6 100%);
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

.landing-page {
  display: none;
  min-height: 100vh;
  color: #211c16;
  background:
    radial-gradient(circle at 20% 10%, rgba(224, 177, 82, 0.28), transparent 28%),
    radial-gradient(circle at 86% 12%, rgba(47, 109, 98, 0.16), transparent 30%),
    linear-gradient(135deg, #fff8e9 0%, #efe0c3 46%, #f7efe0 100%);
}

body.landing-mode .landing-page {
  display: block;
}

body.landing-mode .workspace {
  display: none;
}

body.app-mode .landing-page {
  display: none;
}

body.app-mode {
  background: #fbf7ed;
}

body.app-mode .workspace {
  display: block;
  min-height: 100vh;
  padding: 0;
}

body.app-mode .phone {
  width: 100%;
  max-width: none;
  min-height: 100vh;
  height: auto;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  grid-template-rows: auto minmax(420px, 58vh) auto auto auto;
}

body.app-mode .phone::before,
body.app-mode .status-bar,
body.app-mode .product-panel {
  display: none;
}

body.app-mode .mini-header {
  padding-top: max(12px, env(safe-area-inset-top));
  grid-template-columns: 42px 1fr 64px;
  background: rgba(251, 247, 237, 0.98);
}

body.app-mode .scene-panel {
  min-height: clamp(420px, 58vh, 680px);
}

body.app-mode .content-tabs,
body.app-mode .quick-actions,
body.app-mode .tabbar {
  width: min(720px, 100%);
  margin: 0 auto;
}

.landing-nav {
  width: min(1180px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 22px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.landing-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background:
    linear-gradient(145deg, rgba(255, 240, 176, 0.96), rgba(174, 111, 39, 0.92)),
    #d5a24d;
  color: #5c2419;
  font-size: 24px;
  font-weight: 900;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 240, 0.9),
    0 12px 28px rgba(122, 70, 24, 0.22);
}

.landing-brand strong {
  display: block;
  font-size: 20px;
  letter-spacing: 0;
}

.landing-brand small {
  display: block;
  margin-top: 3px;
  color: rgba(33, 28, 22, 0.62);
  font-size: 12px;
  font-weight: 800;
}

.landing-nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.landing-nav-actions button,
.landing-nav-actions a {
  min-height: 38px;
  padding: 0 16px;
  display: inline-grid;
  place-items: center;
  border: 1px solid rgba(96, 62, 26, 0.16);
  border-radius: 999px;
  background: rgba(255, 252, 242, 0.72);
  color: #30241b;
  text-decoration: none;
  font-size: 13px;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(99, 70, 36, 0.08);
}

.landing-nav-actions .landing-account-button {
  border-color: rgba(47, 109, 98, 0.24);
  background: rgba(248, 253, 248, 0.78);
  color: var(--jade-dark);
}

.landing-hero {
  width: min(1180px, calc(100vw - 36px));
  min-height: calc(100vh - 246px);
  margin: 0 auto;
  padding: 38px 0 42px;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, 0.88fr);
  align-items: center;
  gap: 56px;
}

.landing-copy {
  max-width: 690px;
}

.landing-kicker {
  margin: 0 0 14px;
  color: #8b3a2c;
  font-size: 14px;
  font-weight: 900;
}

.landing-copy h1 {
  margin: 0;
  max-width: 680px;
  font-size: clamp(38px, 5.2vw, 60px);
  line-height: 1.1;
  letter-spacing: 0;
}

.landing-subtitle {
  max-width: 620px;
  margin: 24px 0 0;
  color: rgba(33, 28, 22, 0.72);
  font-size: 18px;
  line-height: 1.78;
}

.landing-cta-row {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.landing-primary,
.landing-secondary {
  min-height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 900;
}

.landing-primary {
  background:
    linear-gradient(135deg, #b53328, #6e201b);
  color: #fff9ec;
  box-shadow: 0 16px 34px rgba(135, 45, 31, 0.25);
}

.landing-secondary {
  border: 1px solid rgba(79, 51, 24, 0.18);
  background: rgba(255, 252, 244, 0.76);
  color: #2a211b;
  box-shadow: 0 12px 26px rgba(99, 70, 36, 0.1);
}

.landing-trust-row {
  margin-top: 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.landing-trust-row span {
  padding: 8px 12px;
  border: 1px solid rgba(122, 82, 30, 0.16);
  border-radius: 999px;
  background: rgba(255, 251, 239, 0.62);
  color: rgba(33, 28, 22, 0.74);
  font-size: 13px;
  font-weight: 800;
}

.landing-showcase {
  position: relative;
  min-height: 600px;
  display: grid;
  place-items: center;
}

.showcase-hall {
  position: relative;
  width: min(430px, 100%);
  height: 560px;
  overflow: hidden;
  border: 1px solid rgba(255, 240, 190, 0.34);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(30, 18, 11, 0.02), rgba(30, 18, 11, 0.34)),
    url("./assets/landing/memorial-hall-hero.png") center / cover no-repeat,
    #3a1f17;
  box-shadow:
    inset 0 0 0 1px rgba(255, 240, 190, 0.26),
    inset 0 -110px 120px rgba(23, 12, 7, 0.48),
    0 34px 70px rgba(78, 46, 22, 0.24);
}

.showcase-beam,
.showcase-plaque,
.showcase-pillars,
.showcase-tablet,
.showcase-altar {
  display: none;
}

.showcase-card {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 18px;
  display: grid;
  gap: 4px;
  padding: 15px 16px;
  border: 1px solid rgba(255, 242, 202, 0.24);
  border-radius: 16px;
  background: rgba(30, 20, 14, 0.68);
  color: #fff5dc;
  backdrop-filter: blur(14px);
}

.showcase-card strong {
  font-size: 15px;
}

.showcase-card span {
  color: rgba(255, 245, 220, 0.74);
  font-size: 12px;
  line-height: 1.55;
}

.landing-sections {
  width: min(1180px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 0 0 56px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.landing-sections article {
  min-height: 210px;
  padding: 22px;
  border: 1px solid rgba(111, 76, 35, 0.14);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(255, 253, 246, 0.86), rgba(255, 246, 225, 0.74)),
    rgba(255, 250, 239, 0.72);
  box-shadow: 0 18px 40px rgba(96, 66, 31, 0.1);
}

.landing-sections article > span {
  color: #9d352c;
  font-size: 13px;
  font-weight: 900;
}

.landing-sections h2 {
  margin: 18px 0 10px;
  font-size: 21px;
  letter-spacing: 0;
}

.landing-sections p {
  margin: 0;
  color: rgba(33, 28, 22, 0.68);
  font-size: 14px;
  line-height: 1.7;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  border: 0;
  color: inherit;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(49, 93, 132, 0.28);
  outline-offset: 2px;
}

.workspace {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(390px, 430px) minmax(360px, 460px);
  justify-content: center;
  align-items: center;
  gap: 28px;
  padding: 28px;
  transition: grid-template-columns 0.34s ease, gap 0.28s ease;
}

.phone {
  position: relative;
  width: min(430px, calc(100vw - 24px));
  height: min(920px, calc(100vh - 28px));
  min-height: 740px;
  display: grid;
  grid-template-rows: auto auto minmax(320px, 1fr) auto auto auto;
  overflow: hidden;
  border: 10px solid #15191b;
  border-radius: 38px;
  background: #fbf7ed;
  box-shadow: var(--shadow);
  transition: grid-template-rows 0.34s ease;
}

.phone::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 50%;
  width: 118px;
  height: 24px;
  transform: translateX(-50%);
  border-radius: 0 0 18px 18px;
  background: #15191b;
  z-index: 12;
}

.status-bar {
  position: relative;
  z-index: 13;
  display: flex;
  justify-content: space-between;
  padding: 9px 22px 3px;
  font-size: 12px;
  font-weight: 700;
  color: #263035;
}

.mini-header {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: 40px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px 16px 12px;
  background: rgba(251, 247, 237, 0.94);
  border-bottom: 1px solid rgba(33, 39, 43, 0.08);
  transition: padding 0.28s ease, grid-template-columns 0.28s ease;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 7px;
}

.account-button {
  min-width: 38px;
  max-width: 86px;
  min-height: 36px;
  padding: 0 11px;
  overflow: hidden;
  border: 1px solid rgba(47, 109, 98, 0.2);
  border-radius: 999px;
  background: rgba(47, 109, 98, 0.08);
  color: var(--jade-dark);
  font-size: 12px;
  font-weight: 900;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mini-header h1,
.mini-header p {
  margin: 0;
}

.mini-header h1 {
  font-size: 19px;
  line-height: 1.2;
}

.eyebrow {
  margin-bottom: 2px;
  color: var(--jade);
  font-size: 11px;
  font-weight: 800;
}

.icon-button {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: rgba(32, 36, 39, 0.06);
  color: var(--ink);
}

.chevron-left {
  width: 11px;
  height: 11px;
  border-left: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
}

.text-button,
.primary {
  min-height: 36px;
  padding: 0 13px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 800;
  background: var(--ink);
  color: #fffdf6;
}

.primary {
  background: linear-gradient(135deg, var(--cinnabar), #6f201c);
}

.scene-panel {
  position: relative;
  overflow: hidden;
  min-height: 374px;
  background: #111617;
  isolation: isolate;
  transition: min-height 0.34s ease;
}

#sceneCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  display: block;
  touch-action: none;
}

.scene-loading {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: #fff6e5;
  background: radial-gradient(circle at 50% 42%, rgba(199, 155, 75, 0.28), rgba(16, 21, 22, 0.95) 58%);
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.scene-loading.hide {
  opacity: 0;
  visibility: hidden;
}

.scene-loading strong {
  font-size: 17px;
}

.scene-loading span {
  color: rgba(255, 247, 230, 0.7);
  font-size: 12px;
}

.scene-gradient {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(91, 48, 18, 0.06), transparent 38%, rgba(70, 36, 14, 0.08)),
    linear-gradient(90deg, rgba(48, 25, 11, 0.1), transparent 20%, transparent 80%, rgba(48, 25, 11, 0.08));
  pointer-events: none;
}

.ritual-stage {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0;
  background:
    radial-gradient(circle at 50% 42%, rgba(255, 209, 118, 0.16), rgba(77, 43, 18, 0.05) 35%, rgba(56, 29, 12, 0.14) 78%),
    linear-gradient(180deg, rgba(255, 230, 174, 0.08), rgba(70, 35, 12, 0.11));
  transition: opacity 0.72s ease;
}

.scene-panel.is-ritual-active .ritual-stage {
  opacity: 1;
  animation: ritualBreath 3.4s ease-in-out both;
}

.ritual-cue {
  position: absolute;
  top: 24px;
  left: 50%;
  width: min(334px, calc(100% - 42px));
  z-index: 7;
  display: grid;
  grid-template-columns: 38px 1fr;
  align-items: center;
  gap: 11px;
  min-height: 60px;
  padding: 10px 14px;
  border: 1px solid rgba(230, 190, 110, 0.36);
  border-radius: 14px;
  background:
    linear-gradient(90deg, rgba(44, 20, 14, 0.76), rgba(91, 37, 26, 0.58)),
    rgba(20, 15, 12, 0.68);
  color: #fff6df;
  box-shadow:
    0 18px 44px rgba(0, 0, 0, 0.2),
    0 0 32px rgba(208, 149, 58, 0.11),
    inset 0 1px 0 rgba(255, 245, 215, 0.14);
  backdrop-filter: blur(14px);
  pointer-events: none;
  opacity: 0;
  transform: translateX(-50%) translateY(12px) scale(0.96);
  filter: blur(2px);
  transition: opacity 0.72s ease, transform 0.72s cubic-bezier(0.16, 1, 0.3, 1), filter 0.72s ease;
}

.ritual-cue::after {
  content: "";
  position: absolute;
  left: 68px;
  right: 16px;
  bottom: 9px;
  height: 1px;
  transform-origin: left;
  transform: scaleX(0);
  background: linear-gradient(90deg, rgba(255, 226, 160, 0), rgba(255, 226, 160, 0.9), rgba(255, 226, 160, 0));
}

.ritual-cue.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0) scale(1);
  filter: blur(0);
}

.ritual-cue.show::after {
  animation: ritualLine 3.1s ease-out both;
}

.ritual-seal {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 226, 160, 0.62);
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 26%, #ffe8a7, #bf7c2e 52%, #5f2118 100%);
  color: #fff7df;
  font-size: 18px;
  font-weight: 950;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.42), 0 0 18px rgba(217, 158, 70, 0.2);
}

.ritual-cue strong {
  display: block;
  font-size: 15px;
  letter-spacing: 0;
}

.ritual-cue small {
  display: block;
  margin-top: 3px;
  color: rgba(255, 244, 214, 0.78);
  font-size: 11px;
  line-height: 1.35;
}

.scene-copy {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 32px;
  z-index: 2;
  color: #fff8e9;
  text-shadow: 0 2px 12px rgba(64, 31, 11, 0.55);
}

.scene-copy span {
  display: inline-flex;
  margin-bottom: 6px;
  padding: 4px 9px;
  border: 1px solid rgba(255, 248, 233, 0.28);
  border-radius: 999px;
  background: rgba(82, 42, 14, 0.24);
  font-size: 11px;
  font-weight: 800;
}

.scene-copy strong {
  display: block;
  font-size: 23px;
  line-height: 1.2;
}

.scene-copy small {
  display: block;
  margin-top: 5px;
  color: rgba(255, 248, 233, 0.78);
  font-size: 12px;
}

@keyframes ritualBreath {
  0% {
    opacity: 0;
  }
  18%,
  72% {
    opacity: 1;
  }
  100% {
    opacity: 0;
  }
}

@keyframes ritualLine {
  0% {
    transform: scaleX(0);
    opacity: 0.2;
  }
  18%,
  72% {
    transform: scaleX(1);
    opacity: 1;
  }
  100% {
    transform: scaleX(1);
    opacity: 0;
  }
}

.immersive-toggle {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 5;
  height: 34px;
  display: inline-grid;
  grid-template-columns: 16px auto;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 12px;
  border: 1px solid rgba(255, 248, 233, 0.26);
  border-radius: 999px;
  background: rgba(14, 17, 18, 0.46);
  color: #fff8e9;
  font-size: 12px;
  font-weight: 900;
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.24);
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.immersive-toggle:active {
  transform: translateY(1px) scale(0.98);
}

.immersive-toggle[aria-pressed="true"] {
  border-color: rgba(232, 196, 118, 0.62);
  background: rgba(104, 60, 28, 0.64);
  color: #fff2c8;
}

.immersive-glyph {
  position: relative;
  width: 16px;
  height: 16px;
  display: block;
}

.immersive-glyph::before,
.immersive-glyph::after {
  content: "";
  position: absolute;
  inset: 1px;
  border: 2px solid currentColor;
}

.immersive-glyph::before {
  clip-path: polygon(0 0, 42% 0, 42% 18%, 18% 18%, 18% 42%, 0 42%, 0 0, 58% 0, 100% 0, 100% 42%, 82% 42%, 82% 18%, 58% 18%);
}

.immersive-glyph::after {
  clip-path: polygon(0 58%, 18% 58%, 18% 82%, 42% 82%, 42% 100%, 0 100%, 0 58%, 58% 82%, 82% 82%, 82% 58%, 100% 58%, 100% 100%, 58% 100%);
}

.scene-tools {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 5;
}

.scene-tools summary {
  width: 68px;
  height: 34px;
  display: inline-grid;
  grid-template-columns: 16px auto;
  align-items: center;
  justify-content: center;
  gap: 6px;
  list-style: none;
  border: 1px solid rgba(255, 248, 233, 0.26);
  border-radius: 999px;
  background: rgba(14, 17, 18, 0.46);
  color: #fff8e9;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  backdrop-filter: blur(12px);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.24);
}

.scene-tools summary::-webkit-details-marker {
  display: none;
}

.scene-tools[open] summary {
  border-color: rgba(232, 196, 118, 0.62);
  background: rgba(104, 60, 28, 0.64);
  color: #fff2c8;
}

.tool-glyph {
  position: relative;
  width: 16px;
  height: 16px;
  display: block;
}

.tool-glyph::before,
.tool-glyph::after {
  content: "";
  position: absolute;
  left: 2px;
  right: 2px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 6px 0 currentColor;
}

.tool-glyph::before {
  top: 3px;
}

.tool-glyph::after {
  top: 9px;
  width: 7px;
  left: 7px;
  box-shadow: none;
}

.scene-tool-panel {
  position: absolute;
  top: 42px;
  right: 0;
  width: 236px;
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(255, 248, 233, 0.22);
  border-radius: 16px;
  background:
    linear-gradient(180deg, rgba(255, 248, 233, 0.08), transparent 44%),
    rgba(12, 13, 12, 0.78);
  color: #fff8e9;
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 38px rgba(0, 0, 0, 0.32);
}

.tool-block {
  display: grid;
  gap: 7px;
}

.tool-block.compact {
  grid-template-columns: 42px 1fr;
  align-items: center;
}

.tool-label {
  color: rgba(255, 248, 233, 0.68);
  font-size: 11px;
  font-weight: 900;
}

.scene-chips {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.scene-chips button,
.scene-zoom button {
  min-height: 32px;
  border: 1px solid rgba(255, 248, 233, 0.2);
  border-radius: 9px;
  background: rgba(255, 248, 233, 0.08);
  color: #fff8e9;
  font-size: 12px;
  font-weight: 900;
}

.scene-zoom {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.scene-zoom button {
  width: auto;
  height: 34px;
  display: grid;
  place-items: center;
  font-size: 20px;
  line-height: 1;
}

.scene-sound {
  display: grid;
  gap: 8px;
}

.scene-sound button {
  width: 100%;
  height: 38px;
  display: inline-grid;
  grid-template-columns: 28px auto;
  justify-content: center;
  align-items: center;
  gap: 8px;
  padding: 0 12px;
  border: 1px solid rgba(255, 232, 174, 0.28);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 248, 233, 0.15), rgba(98, 52, 23, 0.12)),
    rgba(255, 248, 233, 0.06);
  color: #fff8e9;
  font-size: 12px;
  font-weight: 900;
  box-shadow: inset 0 1px 0 rgba(255, 250, 222, 0.16);
}

.scene-sound button[aria-pressed="true"] {
  border-color: rgba(232, 196, 118, 0.58);
  background:
    linear-gradient(180deg, rgba(205, 150, 61, 0.26), rgba(74, 34, 16, 0.46)),
    rgba(104, 60, 28, 0.48);
  color: #fff2c8;
}

.sound-glyph {
  position: relative;
  width: 28px;
  height: 28px;
  display: block;
  border: 1px solid rgba(255, 235, 177, 0.46);
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 25%, rgba(255, 251, 221, 0.42), transparent 34%),
    linear-gradient(145deg, rgba(231, 187, 99, 0.42), rgba(74, 38, 17, 0.34));
  box-shadow:
    inset 0 1px 1px rgba(255, 250, 228, 0.3),
    0 6px 14px rgba(0, 0, 0, 0.25);
}

.speaker-mark {
  position: absolute;
  left: 7px;
  top: 10px;
  width: 9px;
  height: 8px;
  background: currentColor;
  clip-path: polygon(0 24%, 36% 24%, 100% 0, 100% 100%, 36% 76%, 0 76%);
  filter: drop-shadow(0 1px 1px rgba(66, 31, 10, 0.35));
}

.sound-wave {
  position: absolute;
  top: 50%;
  border-left: 0;
  border-style: solid;
  border-color: currentColor;
  border-radius: 0 999px 999px 0;
  transform: translateY(-50%);
  opacity: 0.72;
}

.wave-one {
  left: 15px;
  width: 4px;
  height: 8px;
  border-width: 1.5px;
}

.wave-two {
  left: 17px;
  width: 7px;
  height: 13px;
  border-width: 1.5px;
  opacity: 0.52;
}

.wave-three {
  left: 19px;
  width: 10px;
  height: 18px;
  border-width: 1.4px;
  opacity: 0.32;
}

.mute-slash {
  position: absolute;
  left: 7px;
  top: 13px;
  width: 15px;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform: rotate(-42deg);
  box-shadow: 0 0 0 1px rgba(54, 28, 13, 0.18);
}

.scene-sound.is-playing .sound-glyph {
  animation: soundGlyphPulse 2.8s ease-in-out infinite;
}

.scene-sound.is-playing .sound-wave {
  animation: soundWaveBreath 1.9s ease-in-out infinite;
}

.scene-sound.is-playing .wave-two {
  animation-delay: 0.12s;
}

.scene-sound.is-playing .wave-three {
  animation-delay: 0.24s;
}

.scene-sound.is-playing .mute-slash {
  opacity: 0;
}

.scene-sound:not(.is-playing) .sound-wave {
  opacity: 0;
}

@keyframes soundGlyphPulse {
  0%,
  100% {
    box-shadow:
      inset 0 1px 1px rgba(255, 250, 228, 0.3),
      0 6px 14px rgba(0, 0, 0, 0.25);
  }
  50% {
    box-shadow:
      inset 0 1px 1px rgba(255, 250, 228, 0.36),
      0 0 0 3px rgba(230, 190, 110, 0.12),
      0 8px 18px rgba(0, 0, 0, 0.3);
  }
}

@keyframes soundWaveBreath {
  0%,
  100% {
    transform: translateY(-50%) scale(0.96);
  }
  50% {
    transform: translateY(-50%) scale(1.08);
  }
}

.volume-control {
  width: 100%;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  margin: 0;
  padding: 8px 10px 8px 9px;
  border: 1px solid rgba(255, 248, 233, 0.22);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 248, 233, 0.12), rgba(255, 248, 233, 0.04)),
    rgba(255, 248, 233, 0.07);
  color: rgba(255, 248, 233, 0.88);
  font-size: 11px;
  font-weight: 900;
  opacity: 1;
  pointer-events: auto;
}

.volume-label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  white-space: nowrap;
}

.volume-level-glyph {
  position: relative;
  width: 18px;
  height: 16px;
  display: inline-block;
}

.volume-level-glyph::before {
  content: "";
  position: absolute;
  left: 1px;
  bottom: 2px;
  width: 3px;
  height: 6px;
  border-radius: 2px;
  background: #d7aa55;
  box-shadow:
    6px -3px 0 #ead08a,
    12px -7px 0 #fff2bf;
}

.volume-level-glyph::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, rgba(255, 242, 191, 0.2), rgba(255, 242, 191, 0.78));
}

.volume-control input {
  width: 100%;
  min-width: 0;
  height: 5px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  appearance: none;
  background: linear-gradient(90deg, #e6be6e 0 42%, rgba(255, 248, 233, 0.28) 42%);
  accent-color: #e6be6e;
  box-shadow: inset 0 1px 2px rgba(28, 13, 8, 0.35);
}

.volume-control input::-webkit-slider-thumb {
  appearance: none;
  width: 16px;
  height: 16px;
  border: 2px solid #fff2bf;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 28%, #fff6cf 0 18%, transparent 20%),
    linear-gradient(145deg, #d6a84f, #8c5721);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.34),
    0 0 0 3px rgba(232, 196, 118, 0.12);
}

.volume-control input::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border: 2px solid #fff2bf;
  border-radius: 50%;
  background:
    radial-gradient(circle at 35% 28%, #fff6cf 0 18%, transparent 20%),
    linear-gradient(145deg, #d6a84f, #8c5721);
  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.34),
    0 0 0 3px rgba(232, 196, 118, 0.12);
}

.gesture-tip {
  position: absolute;
  left: 50%;
  bottom: 18px;
  z-index: 2;
  width: max-content;
  max-width: calc(100% - 36px);
  transform: translateX(-50%);
  padding: 8px 11px;
  border-radius: 999px;
  background: rgba(255, 248, 233, 0.88);
  color: #293137;
  font-size: 11px;
  font-weight: 800;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
  transition: opacity 0.3s ease;
}

.gesture-tip.fade {
  opacity: 0;
}

.quick-actions {
  position: relative;
  z-index: 5;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  padding: 11px 11px 10px;
  background:
    linear-gradient(180deg, rgba(255, 243, 204, 0.72), rgba(228, 204, 156, 0.18) 44%, transparent),
    linear-gradient(90deg, rgba(126, 53, 32, 0.08), transparent 24%, transparent 76%, rgba(126, 53, 32, 0.08)),
    #fbf3e4;
  border-top: 1px solid rgba(188, 126, 49, 0.28);
  border-bottom: 1px solid rgba(33, 39, 43, 0.08);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 -12px 24px rgba(83, 41, 18, 0.16);
  transition: padding 0.28s ease, gap 0.28s ease;
}

.quick-actions > button,
.ritual-more summary {
  position: relative;
  overflow: hidden;
  min-height: 55px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 4px;
  padding: 5px 3px;
  border: 1px solid rgba(171, 105, 38, 0.26);
  border-radius: 8px;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 246, 205, 0.94), rgba(255, 246, 205, 0) 58%),
    linear-gradient(180deg, rgba(255, 253, 246, 0.98), rgba(238, 222, 188, 0.96)),
    #fffaf0;
  color: #3d2a1f;
  font-size: 10.5px;
  font-weight: 900;
  line-height: 1.05;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    inset 0 -1px 0 rgba(139, 82, 28, 0.12),
    0 7px 16px rgba(82, 50, 27, 0.12);
  transition: transform 0.16s ease, border-color 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}

.quick-actions > button::before,
.ritual-more summary::before {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 6px;
  background:
    linear-gradient(135deg, rgba(255, 236, 166, 0.5), transparent 34%, rgba(122, 58, 20, 0.06) 72%, rgba(255, 246, 214, 0.36));
  pointer-events: none;
}

.quick-actions > button::after,
.ritual-more-panel button::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 7px;
  border: 1px solid rgba(205, 150, 64, 0.22);
  pointer-events: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.quick-actions > button.is-ritual-active,
.ritual-more-panel button.is-ritual-active {
  border-color: rgba(188, 116, 48, 0.48);
  color: #7b2f24;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.88),
    0 0 0 2px rgba(199, 155, 75, 0.12),
    0 10px 20px rgba(119, 65, 24, 0.16);
}

.quick-actions > button.is-ritual-active::after,
.ritual-more-panel button.is-ritual-active::after {
  border-color: rgba(205, 150, 64, 0.58);
  box-shadow: inset 0 0 16px rgba(233, 190, 104, 0.16);
  animation: actionPulse 1.2s ease-in-out infinite;
}

.quick-actions > button.is-ritual-complete,
.ritual-more-panel button.is-ritual-complete {
  animation: ritualDone 0.58s ease both;
}

.quick-actions > button:active,
.ritual-more summary:active,
.ritual-more-panel button:active {
  transform: translateY(1px) scale(0.98);
  box-shadow: inset 0 2px 5px rgba(82, 50, 27, 0.16);
}

@keyframes actionPulse {
  0%,
  100% {
    opacity: 0.46;
  }
  50% {
    opacity: 1;
  }
}

@keyframes ritualDone {
  0% {
    transform: translateY(0) scale(1);
  }
  42% {
    transform: translateY(-2px) scale(1.04);
  }
  100% {
    transform: translateY(0) scale(1);
  }
}

.ritual-more {
  position: relative;
  min-width: 0;
}

.ritual-more summary {
  cursor: pointer;
  list-style: none;
}

.ritual-more summary::-webkit-details-marker {
  display: none;
}

.ritual-more[open] summary {
  border-color: rgba(163, 38, 28, 0.36);
  background:
    linear-gradient(180deg, rgba(255, 249, 235, 0.98), rgba(246, 225, 188, 0.96)),
    #fff8e7;
  color: #7b2f24;
}

.ritual-more-panel {
  position: absolute;
  right: 0;
  bottom: calc(100% + 10px);
  z-index: 18;
  width: min(224px, calc(100vw - 22px));
  display: grid;
  gap: 7px;
  padding: 8px;
  border: 1px solid rgba(255, 248, 233, 0.26);
  border-radius: 13px;
  background:
    linear-gradient(180deg, rgba(255, 248, 233, 0.1), transparent 46%),
    rgba(28, 24, 21, 0.86);
  backdrop-filter: blur(15px);
  box-shadow: 0 -16px 32px rgba(0, 0, 0, 0.28);
}

.ritual-more-panel button {
  position: relative;
  overflow: hidden;
  min-height: 42px;
  display: grid;
  grid-template-columns: 26px auto;
  align-items: center;
  justify-content: start;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid rgba(255, 248, 233, 0.2);
  border-radius: 8px;
  background: rgba(255, 248, 233, 0.1);
  color: #fff8e9;
  font-size: 12px;
  font-weight: 900;
  text-align: left;
}

.action-icon {
  position: relative;
  width: 30px;
  height: 30px;
  display: block;
  border-radius: 50%;
  background:
    radial-gradient(circle at 32% 23%, rgba(255, 255, 238, 0.98), rgba(255, 229, 153, 0.82) 30%, rgba(180, 105, 38, 0.7) 68%, rgba(72, 32, 18, 0.36)),
    linear-gradient(145deg, #f5d486, #9b5f28 68%, #5d2d19);
  box-shadow:
    inset 0 0 0 1px rgba(255, 250, 218, 0.9),
    inset 0 0 0 3px rgba(106, 50, 20, 0.12),
    inset 0 -3px 7px rgba(75, 36, 18, 0.28),
    0 4px 10px rgba(91, 49, 21, 0.18);
}

.action-icon::before {
  content: "";
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  border: 1px solid rgba(255, 238, 173, 0.58);
  box-shadow: inset 0 1px 2px rgba(255, 255, 245, 0.34);
  pointer-events: none;
}

.action-icon > span {
  position: absolute;
  display: block;
  pointer-events: none;
}

.ritual-more-panel .action-icon {
  width: 26px;
  height: 26px;
}

.incense-icon .icon-flame {
  left: 10px;
  top: 3px;
  width: 10px;
  height: 10px;
  border-radius: 50% 50% 48% 48%;
  background:
    radial-gradient(circle at 52% 54%, #fff9c8 0 20%, #ffbf4e 42%, #c84a24 68%, rgba(200, 74, 36, 0) 72%);
  filter: drop-shadow(0 0 4px rgba(255, 178, 67, 0.82));
}

.incense-stick {
  bottom: 8px;
  width: 2px;
  height: 16px;
  border-radius: 6px;
  transform-origin: bottom center;
  background:
    linear-gradient(180deg, #f4d184 0 26%, #b7372b 27% 100%);
  box-shadow: 0 0 0 0.5px rgba(80, 28, 16, 0.2);
}

.incense-icon .stick-one {
  left: 11px;
  transform: rotate(-10deg);
}

.incense-icon .stick-two {
  left: 15px;
  height: 18px;
}

.incense-icon .stick-three {
  left: 19px;
  transform: rotate(10deg);
}

.incense-bowl {
  left: 8px;
  bottom: 4px;
  width: 16px;
  height: 8px;
  border-radius: 4px 4px 12px 12px;
  background:
    linear-gradient(180deg, #ffe3a3 0 18%, #b9762d 20% 58%, #6d321b 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 250, 220, 0.68),
    0 1px 3px rgba(69, 31, 13, 0.26);
}

.flower-stem {
  left: 14px;
  top: 9px;
  width: 3px;
  height: 14px;
  border-radius: 4px;
  background: linear-gradient(180deg, #5d8c4f, #2e6844);
  transform: rotate(10deg);
}

.flower-stem::before,
.flower-stem::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 4px;
  border-radius: 50%;
  background: #3f8a58;
}

.flower-stem::before {
  left: -7px;
  top: 6px;
  transform: rotate(-24deg);
}

.flower-stem::after {
  right: -7px;
  top: 8px;
  transform: rotate(26deg);
}

.flower-bloom {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, #ffe9a8 0 16%, #e26f86 18% 54%, #9d3550 76%);
  box-shadow:
    0 0 0 1px rgba(255, 245, 210, 0.42),
    0 1px 3px rgba(82, 24, 34, 0.2);
}

.flower-bloom::before,
.flower-bloom::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: 50%;
  border-left: 3px solid rgba(255, 191, 207, 0.76);
  border-right: 3px solid rgba(164, 45, 74, 0.28);
}

.flower-icon .bloom-one {
  left: 6px;
  top: 5px;
}

.flower-icon .bloom-two {
  left: 14px;
  top: 4px;
  transform: scale(0.92);
  background:
    radial-gradient(circle at 50% 50%, #fff2bd 0 16%, #f5d45b 18% 56%, #b27722 78%);
}

.flower-icon .bloom-three {
  left: 11px;
  top: 11px;
  transform: scale(0.82);
  background:
    radial-gradient(circle at 50% 50%, #fffdf0 0 16%, #f6efe0 18% 58%, #b8a486 80%);
}

.flower-vase {
  left: 10px;
  bottom: 3px;
  width: 12px;
  height: 10px;
  border-radius: 3px 3px 7px 7px;
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.65), transparent 28%),
    linear-gradient(180deg, #fff6dc, #caa266 52%, #8d5525);
  box-shadow:
    inset 0 0 0 1px rgba(96, 55, 24, 0.24),
    0 1px 3px rgba(69, 31, 13, 0.24);
}

.lamp-flame {
  left: 12px;
  top: 3px;
  width: 8px;
  height: 13px;
  border-radius: 50% 50% 46% 46%;
  background:
    radial-gradient(circle at 50% 58%, #fff8d2 0 20%, #ffc15a 38%, #e86b24 64%, rgba(232, 107, 36, 0) 70%);
  filter: drop-shadow(0 0 5px rgba(255, 177, 75, 0.86));
}

.lamp-glass {
  left: 9px;
  top: 8px;
  width: 14px;
  height: 14px;
  border-radius: 7px 7px 5px 5px;
  border: 1px solid rgba(255, 245, 205, 0.74);
  background:
    linear-gradient(90deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.08) 34%, rgba(143, 70, 24, 0.12)),
    rgba(255, 190, 94, 0.2);
}

.lamp-body {
  left: 8px;
  bottom: 6px;
  width: 16px;
  height: 8px;
  border-radius: 50% 50% 6px 6px;
  background:
    linear-gradient(180deg, #ffe0a0, #bd7b2d 54%, #6e3219);
  box-shadow: inset 0 1px 0 rgba(255, 248, 212, 0.72);
}

.lamp-base {
  left: 6px;
  bottom: 3px;
  width: 20px;
  height: 5px;
  border-radius: 50%;
  background: linear-gradient(180deg, #f4cc78, #7d3e1f);
  box-shadow: 0 1px 3px rgba(69, 31, 13, 0.25);
}

.letter-icon {
  border: 0;
}

.letter-icon::before {
  content: "";
  position: absolute;
  left: 6px;
  top: 7px;
  width: 16px;
  height: 12px;
  border: 2px solid #315d84;
  border-radius: 3px;
  border-bottom: 2px solid #315d84;
  transform: skewY(-24deg);
}

.ritual-guide-icon::before {
  content: "";
  position: absolute;
  left: 8px;
  top: 5px;
  width: 12px;
  height: 16px;
  border-radius: 8px 8px 4px 4px;
  background:
    linear-gradient(90deg, rgba(255, 246, 210, 0.72), transparent 45%),
    linear-gradient(180deg, #b4342b, #6d1f1a);
  box-shadow:
    0 0 0 2px rgba(199, 155, 75, 0.55),
    inset 0 -3px 0 rgba(60, 20, 14, 0.22);
}

.ritual-guide-icon::after {
  content: "";
  position: absolute;
  left: 11px;
  top: 9px;
  width: 6px;
  height: 8px;
  border-left: 2px solid #f6d58b;
  border-right: 2px solid #f6d58b;
}

.tea-icon::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 11px;
  width: 14px;
  height: 9px;
  border: 2px solid var(--jade);
  border-radius: 0 0 10px 10px;
}

.tea-icon::after {
  content: "";
  position: absolute;
  right: 5px;
  top: 12px;
  width: 6px;
  height: 6px;
  border: 2px solid var(--jade);
  border-left: 0;
  border-radius: 0 8px 8px 0;
}

.wine-icon::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 7px;
  width: 11px;
  height: 14px;
  border: 2px solid #7b3b2b;
  border-top: 0;
  border-radius: 3px 3px 9px 9px;
  background:
    linear-gradient(180deg, transparent 0 34%, rgba(224, 183, 109, 0.95) 35%),
    #fff7df;
}

.wine-icon::after {
  content: "";
  position: absolute;
  left: 8px;
  bottom: 5px;
  width: 13px;
  height: 2px;
  border-radius: 4px;
  background: #7b3b2b;
  box-shadow:
    4px -3px 0 -1px rgba(199, 155, 75, 0.96),
    4px -14px 0 -1px #7b3b2b;
}

.silence-icon::before {
  content: "";
  position: absolute;
  inset: 6px;
  border-radius: 50%;
  border: 2px solid #6a6570;
}

.silence-icon::after {
  content: "";
  position: absolute;
  left: 13px;
  top: 9px;
  width: 2px;
  height: 7px;
  background: #6a6570;
  box-shadow: 4px 8px 0 #6a6570;
}

.dish-icon::before {
  content: "";
  position: absolute;
  left: 5px;
  right: 5px;
  bottom: 7px;
  height: 7px;
  border: 2px solid #9b6a2f;
  border-top: 0;
  border-radius: 0 0 14px 14px;
  background: #fff6df;
}

.dish-icon::after {
  content: "";
  position: absolute;
  left: 8px;
  top: 7px;
  width: 12px;
  height: 9px;
  border-radius: 50%;
  background: linear-gradient(135deg, #f5d7a0, #b86637);
  box-shadow: 5px 2px 0 #e7bf78;
}

.more-icon::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 11px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #7b3b2b;
  box-shadow: 7px 0 0 #7b3b2b, 14px 0 0 #7b3b2b;
}

.content-tabs {
  min-height: 184px;
  padding: 12px;
  background: #fbf7ed;
  overflow: hidden;
  transition: min-height 0.34s ease, padding 0.28s ease;
}

.segmented {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  padding: 4px;
  border-radius: 14px;
  background: rgba(32, 36, 39, 0.06);
}

.segmented button {
  min-height: 34px;
  border-radius: 11px;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 900;
}

.segmented button.active {
  background: #fffdf8;
  color: var(--ink);
  box-shadow: 0 5px 13px rgba(32, 36, 39, 0.08);
}

.tab-panel {
  display: none;
  padding: 14px 4px 0;
}

.tab-panel.active {
  display: block;
}

.tab-panel h2 {
  margin: 0 0 8px;
  font-size: 16px;
}

.tab-panel p {
  margin: 0;
  color: #5d6267;
  font-size: 13px;
  line-height: 1.6;
}

.dialog-note {
  margin: -2px 0 10px;
  padding: 10px 12px;
  border-radius: 10px;
  background: rgba(199, 155, 75, 0.12);
  color: #67523a;
  font-size: 12px;
  line-height: 1.55;
}

.album-heading {
  margin-bottom: 4px;
}

.album-note {
  margin-bottom: 10px !important;
}

.portrait-upload {
  display: grid;
  grid-template-columns: 82px 1fr;
  gap: 10px;
  align-items: stretch;
  margin: 10px 0 12px;
  padding: 10px;
  border: 1px solid rgba(111, 81, 45, 0.14);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(255, 253, 248, 0.96), rgba(244, 234, 213, 0.78));
}

.portrait-preview {
  min-height: 104px;
  border-radius: 8px;
  border: 2px solid rgba(199, 155, 75, 0.72);
  background:
    linear-gradient(180deg, rgba(35, 18, 10, 0) 55%, rgba(35, 18, 10, 0.68)),
    radial-gradient(circle at 50% 34%, #6b5a4f 0 18%, transparent 19%),
    radial-gradient(circle at 50% 82%, #453b35 0 34%, transparent 35%),
    linear-gradient(180deg, #e9dcc2, #b7c8c1);
  background-size: cover;
  background-position: center;
  box-shadow: inset 0 0 0 3px rgba(93, 29, 23, 0.24);
}

.portrait-preview.has-photo {
  background-size: cover;
  background-position: center;
}

.portrait-upload-actions {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 8px;
  align-content: center;
}

.portrait-upload-actions strong {
  grid-column: 1 / -1;
  color: var(--ink);
  font-size: 14px;
}

.portrait-upload-actions span {
  grid-column: 1 / -1;
  color: #6d6253;
  font-size: 12px;
  line-height: 1.45;
}

.portrait-upload-button,
.portrait-upload-actions button {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
  text-align: center;
}

.portrait-upload-button {
  color: #fff8e8;
  background: linear-gradient(135deg, #8f4733, #c79b4b);
}

.portrait-upload-button.secondary {
  background: linear-gradient(135deg, #8c5a24, #5b2c18);
}

.portrait-upload-actions button {
  color: #6d3b2e;
  background: rgba(143, 71, 51, 0.1);
}

.portrait-upload-actions button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.portrait-upload-actions input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.memorial-audio-upload {
  display: grid;
  grid-template-columns: 1fr 78px 54px;
  gap: 8px;
  align-items: center;
  margin: 0 0 12px;
  padding: 10px;
  border: 1px solid rgba(111, 81, 45, 0.14);
  border-radius: 12px;
  background:
    linear-gradient(135deg, rgba(255, 253, 248, 0.94), rgba(240, 226, 198, 0.78));
}

.memorial-audio-upload strong,
.memorial-audio-upload span {
  display: block;
}

.memorial-audio-upload strong {
  color: var(--ink);
  font-size: 14px;
}

.memorial-audio-upload span {
  margin-top: 3px;
  color: #6d6253;
  font-size: 12px;
  line-height: 1.45;
}

.memorial-audio-upload button {
  min-height: 32px;
  border-radius: 8px;
  background: rgba(143, 71, 51, 0.1);
  color: #6d3b2e;
  font-size: 12px;
  font-weight: 900;
}

.memorial-audio-upload button:disabled {
  opacity: 0.45;
}

.memorial-audio-upload input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.memorial-audio-upload audio {
  grid-column: 1 / -1;
  display: none;
  width: 100%;
  height: 34px;
}

.memorial-audio-upload audio.show {
  display: block;
}

.stat-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 12px;
}

.stat-row span {
  padding: 10px;
  border-radius: 12px;
  background: #fffdf8;
  color: #6d6253;
  font-size: 12px;
}

.stat-row strong {
  display: block;
  color: var(--jade-dark);
  font-size: 18px;
}

.album-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.album-tile {
  min-height: 86px;
  display: flex;
  align-items: end;
  justify-content: flex-start;
  padding: 10px;
  border-radius: 12px;
  color: #fff8e9;
  font-size: 12px;
  font-weight: 900;
  text-align: left;
}

.album-tile.warm {
  background: linear-gradient(135deg, #8f4733, #d2a34c);
}

.album-tile.green {
  background: linear-gradient(135deg, #2f6d62, #8ea56f);
}

.album-tile.blue {
  background: linear-gradient(135deg, #315d84, #b5c6d7);
}

.record-list {
  height: 118px;
  margin: 0;
  padding: 0 4px 0 22px;
  overflow: auto;
  color: #575f65;
  font-size: 13px;
  line-height: 1.8;
}

.record-list li::marker {
  color: var(--gold);
}

.family-hub {
  display: grid;
  gap: 10px;
  max-height: 150px;
  padding-right: 3px;
  overflow: auto;
}

.invite-arrival-card,
.family-share-card,
.message-form,
.message-list li {
  border: 1px solid rgba(151, 92, 39, 0.14);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.9), rgba(248, 237, 214, 0.8)),
    #fffaf0;
  box-shadow: 0 8px 18px rgba(82, 50, 27, 0.06);
}

.invite-arrival-card {
  display: grid;
  gap: 8px;
  padding: 13px;
  border-color: rgba(157, 53, 44, 0.22);
  background:
    linear-gradient(135deg, rgba(157, 53, 44, 0.13), rgba(199, 155, 75, 0.2)),
    #fff9ea;
}

.invite-arrival-card[hidden] {
  display: none;
}

.invite-arrival-card span {
  color: var(--cinnabar);
  font-size: 11px;
  font-weight: 950;
}

.invite-arrival-card h2 {
  margin: 0;
  font-size: 16px;
  line-height: 1.3;
}

.invite-arrival-card p {
  font-size: 12px;
}

.invite-action-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 7px;
}

.invite-action-row button {
  min-height: 34px;
  padding: 0 8px;
  border-radius: 10px;
  background: rgba(255, 253, 248, 0.9);
  color: #6f3a26;
  font-size: 11px;
  font-weight: 900;
}

.invite-action-row button:disabled {
  opacity: 0.58;
}

.family-share-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 12px;
}

.family-share-card span {
  color: var(--cinnabar);
  font-size: 11px;
  font-weight: 950;
}

.family-share-card h2 {
  margin: 3px 0 5px;
  font-size: 15px;
}

.family-share-card p {
  font-size: 12px;
}

.family-share-card .primary {
  min-width: 78px;
  border-radius: 10px;
}

.message-form {
  display: grid;
  gap: 8px;
  padding: 10px;
}

.message-form label {
  display: grid;
  gap: 6px;
  color: #5d4a32;
  font-size: 12px;
  font-weight: 900;
}

.message-form textarea {
  min-height: 62px;
  resize: vertical;
}

.message-form button {
  justify-self: end;
  min-height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, #9d352c, #c79b4b);
  color: #fff8e8;
  font-size: 12px;
  font-weight: 900;
}

.message-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.message-list li {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 8px;
  align-items: start;
  padding: 10px;
  color: #4d4035;
  font-size: 12px;
}

.message-list li strong {
  color: var(--jade-dark);
}

.message-list li span {
  line-height: 1.45;
}

.message-list li small {
  color: #9a8f82;
  white-space: nowrap;
}

.message-list .message-empty {
  display: block;
  color: #7a6c5c;
  line-height: 1.5;
}

.ritual-hub {
  display: grid;
  gap: 10px;
  max-height: 150px;
  padding-right: 3px;
  overflow: auto;
}

.ritual-card {
  padding: 12px;
  border: 1px solid rgba(151, 92, 39, 0.14);
  border-radius: 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.88), rgba(248, 237, 214, 0.82)),
    #fffaf0;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.82);
}

.ritual-primary-card {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 10px;
  border-color: rgba(157, 53, 44, 0.18);
  background:
    linear-gradient(135deg, rgba(157, 53, 44, 0.12), rgba(199, 155, 75, 0.16)),
    #fffaf0;
}

.ritual-card-kicker {
  display: inline-flex;
  margin-bottom: 5px;
  color: var(--cinnabar);
  font-size: 11px;
  font-weight: 950;
}

.ritual-card h2 {
  margin: 0 0 6px;
  font-size: 15px;
  line-height: 1.25;
}

.ritual-card p {
  font-size: 12px;
  line-height: 1.55;
}

.ritual-start-button {
  min-width: 58px;
  border-radius: 10px;
}

.ritual-step-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
}

.ritual-step-list button {
  min-height: 54px;
  display: grid;
  grid-template-columns: 88px 1fr;
  align-items: center;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid rgba(151, 92, 39, 0.12);
  border-radius: 10px;
  background: #fffdf8;
  color: #332c25;
  text-align: left;
  box-shadow: 0 5px 12px rgba(82, 50, 27, 0.06);
}

.ritual-step-list button strong {
  color: var(--jade-dark);
  font-size: 12px;
}

.ritual-step-list button span {
  color: #6b6259;
  font-size: 11px;
  line-height: 1.35;
}

.ritual-step-list button.is-step-complete {
  border-color: rgba(199, 155, 75, 0.58);
  box-shadow:
    0 0 0 2px rgba(199, 155, 75, 0.12),
    0 8px 18px rgba(82, 50, 27, 0.12);
}

.ritual-tags,
.family-action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.ritual-tags span,
.family-action-row button,
.subtle-action {
  min-height: 30px;
  padding: 0 10px;
  border: 1px solid rgba(151, 92, 39, 0.14);
  border-radius: 999px;
  background: rgba(255, 253, 248, 0.84);
  color: #6f3a26;
  font-size: 11px;
  font-weight: 900;
}

.subtle-action {
  margin-top: 10px;
}

.tabbar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 8px 8px 10px;
  background: #fffdf8;
  border-top: 1px solid rgba(33, 39, 43, 0.08);
  transition: padding 0.28s ease;
}

.tabbar button {
  min-height: 38px;
  border-radius: 12px;
  background: transparent;
  color: #86817a;
  font-size: 12px;
  font-weight: 900;
}

.tabbar button.active {
  color: var(--cinnabar);
  background: rgba(157, 53, 44, 0.08);
}

.toast {
  position: absolute;
  left: 50%;
  bottom: 102px;
  z-index: 30;
  max-width: calc(100% - 40px);
  transform: translateX(-50%) translateY(12px);
  padding: 10px 14px;
  border-radius: 999px;
  background: rgba(22, 25, 26, 0.88);
  color: #fff7e9;
  font-size: 12px;
  font-weight: 800;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.phone.is-immersive {
  grid-template-rows: auto auto minmax(520px, 1fr) auto minmax(74px, auto) auto;
}

.phone.is-immersive .status-bar {
  padding: 7px 20px 2px;
  font-size: 11px;
}

.phone.is-immersive .mini-header {
  grid-template-columns: 34px 1fr 52px;
  gap: 8px;
  padding: 6px 14px 7px;
}

.phone.is-immersive .mini-header h1 {
  font-size: 16px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.phone.is-immersive .eyebrow {
  display: none;
}

.phone.is-immersive .icon-button {
  width: 32px;
  height: 32px;
}

.phone.is-immersive .text-button {
  min-height: 30px;
  padding: 0 11px;
  font-size: 12px;
}

.phone.is-immersive .scene-panel {
  min-height: 520px;
}

.phone.is-immersive .scene-copy {
  bottom: 20px;
}

.phone.is-immersive .scene-copy span {
  margin-bottom: 5px;
  padding: 3px 8px;
  font-size: 10px;
}

.phone.is-immersive .scene-copy strong {
  font-size: 20px;
}

.phone.is-immersive .scene-copy small {
  font-size: 11px;
}

.phone.is-immersive .quick-actions {
  gap: 4px;
  padding: 6px 8px;
}

.phone.is-immersive .quick-actions > button,
.phone.is-immersive .ritual-more summary {
  min-height: 40px;
  grid-template-columns: 22px auto;
  align-content: center;
  justify-content: center;
  gap: 4px;
  padding: 3px 4px;
  border-radius: 8px;
  font-size: 10px;
}

.phone.is-immersive .action-icon {
  width: 28px;
  height: 28px;
  transform: scale(0.9);
}

.phone.is-immersive .content-tabs {
  min-height: 74px;
  padding: 8px 10px 7px;
}

.phone.is-immersive .segmented {
  gap: 3px;
  padding: 3px;
  border-radius: 12px;
}

.phone.is-immersive .segmented button {
  min-height: 28px;
  border-radius: 9px;
  font-size: 11px;
}

.phone.is-immersive .tab-panel {
  padding: 6px 3px 0;
}

.phone.is-immersive .tab-panel h2 {
  margin: 0;
  font-size: 12px;
  line-height: 1.25;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.phone.is-immersive .tab-panel p,
.phone.is-immersive .stat-row,
.phone.is-immersive .album-grid {
  display: none;
}

.phone.is-immersive .record-list {
  height: 34px;
  padding-left: 20px;
  overflow: hidden;
  font-size: 11px;
  line-height: 1.55;
}

.phone.is-immersive .ritual-hub {
  max-height: 58px;
  gap: 6px;
}

.phone.is-immersive .ritual-card,
.phone.is-immersive .ritual-step-list button {
  min-height: 0;
  padding: 8px;
  border-radius: 9px;
}

.phone.is-immersive .ritual-card h2 {
  margin-bottom: 3px;
  font-size: 12px;
}

.phone.is-immersive .ritual-card p,
.phone.is-immersive .ritual-step-list button span {
  display: block;
  font-size: 10px;
  line-height: 1.35;
}

.phone.is-immersive .ritual-step-list button {
  grid-template-columns: 72px 1fr;
}

.phone.is-immersive .tabbar {
  padding: 5px 8px 6px;
}

.phone.is-immersive .tabbar button {
  min-height: 30px;
  border-radius: 9px;
  font-size: 10.5px;
}

.phone.is-immersive .toast {
  bottom: 76px;
}

.product-panel {
  align-self: stretch;
  max-height: min(920px, calc(100vh - 56px));
  overflow: auto;
  padding: 28px;
  border: 1px solid rgba(32, 36, 39, 0.1);
  border-radius: 24px;
  background: rgba(255, 252, 245, 0.82);
  box-shadow: 0 18px 44px rgba(21, 18, 12, 0.12);
  backdrop-filter: blur(18px);
  transition: padding 0.28s ease;
}

.panel-heading p,
.panel-heading h2,
.panel-heading span {
  margin: 0;
}

.panel-heading p {
  color: var(--jade);
  font-size: 13px;
  font-weight: 900;
}

.panel-heading h2 {
  margin-top: 6px;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.08;
}

.panel-heading span {
  display: block;
  margin-top: 12px;
  color: #5f6265;
  line-height: 1.7;
}

.ops-section {
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid rgba(32, 36, 39, 0.1);
}

.ops-section h3 {
  margin: 0 0 14px;
  font-size: 17px;
}

.ops-section dl {
  display: grid;
  gap: 10px;
  margin: 0;
}

.ops-section dl div {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.52);
}

.ops-section dt {
  color: #81807b;
  font-size: 13px;
  font-weight: 900;
}

.ops-section dd {
  margin: 0;
  color: var(--ink);
  font-weight: 800;
}

.module-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}

.module-grid span {
  min-height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(47, 109, 98, 0.12);
  border-radius: 14px;
  background: rgba(47, 109, 98, 0.08);
  color: var(--jade-dark);
  font-size: 13px;
  font-weight: 900;
}

.value-grid {
  display: grid;
  gap: 8px;
}

.value-grid span {
  display: block;
  padding: 11px 12px;
  border: 1px solid rgba(151, 92, 39, 0.12);
  border-radius: 14px;
  background:
    linear-gradient(90deg, rgba(157, 53, 44, 0.08), rgba(199, 155, 75, 0.08)),
    rgba(255, 253, 248, 0.62);
  color: #5d5146;
  font-size: 12px;
  font-weight: 800;
  line-height: 1.45;
}

.value-grid strong {
  display: block;
  margin-bottom: 3px;
  color: var(--cinnabar);
  font-size: 12px;
}

.roadmap {
  margin: 0;
  padding-left: 20px;
  color: #5f6265;
  line-height: 1.8;
}

.dialog {
  width: min(430px, calc(100vw - 24px));
  max-height: calc(100vh - 28px);
  overflow: auto;
  border: 0;
  border-radius: 22px;
  padding: 0;
  background: #fffdf8;
  color: var(--ink);
  box-shadow: 0 28px 80px rgba(15, 18, 20, 0.34);
}

.dialog::backdrop {
  background: rgba(15, 18, 20, 0.48);
  backdrop-filter: blur(8px);
}

.dialog form {
  padding: 22px;
}

.dialog-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.dialog-title h2 {
  margin: 0;
  font-size: 21px;
}

.account-dialog {
  width: min(420px, calc(100vw - 24px));
}

.account-kicker {
  display: block;
  margin-bottom: 3px;
  color: var(--cinnabar);
  font-size: 11px;
  font-weight: 900;
}

.account-mode-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
  padding: 4px;
  border-radius: 8px;
  background: rgba(32, 36, 39, 0.06);
}

.account-mode-switch button {
  min-height: 38px;
  border-radius: 6px;
  color: #66594c;
  font-size: 13px;
  font-weight: 900;
}

.account-mode-switch button.active {
  background: #fffdf8;
  color: var(--jade-dark);
  box-shadow: 0 3px 10px rgba(46, 38, 27, 0.12);
}

.account-intro,
.account-footnote {
  margin: 12px 0 0;
  color: #74695d;
  font-size: 12px;
  line-height: 1.6;
}

.account-footnote {
  text-align: center;
  font-size: 11px;
}

.account-error {
  min-height: 20px;
  margin: 10px 0 -6px;
  color: #9d352c;
  font-size: 12px;
  font-weight: 800;
}

.account-profile {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  padding-top: 4px;
}

.account-profile[hidden],
#accountAuthPanel[hidden],
#accountNameField[hidden] {
  display: none;
}

.account-avatar {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(199, 155, 75, 0.42);
  border-radius: 50%;
  background: linear-gradient(145deg, #f7db91, #a5672b);
  color: #5f241a;
  font-size: 21px;
  font-weight: 950;
  box-shadow: inset 0 1px 0 rgba(255, 255, 240, 0.8), 0 8px 18px rgba(115, 69, 26, 0.16);
}

.account-profile strong,
.account-profile small {
  display: block;
}

.account-profile strong {
  font-size: 17px;
}

.account-profile small {
  margin-top: 4px;
  color: #817468;
  font-size: 12px;
}

.account-profile p,
.account-profile .dialog-actions {
  grid-column: 1 / -1;
}

.account-profile p {
  margin: 4px 0 0;
  padding: 11px 12px;
  border-left: 3px solid rgba(47, 109, 98, 0.5);
  background: rgba(47, 109, 98, 0.06);
  color: #5e625d;
  font-size: 12px;
  line-height: 1.6;
}

.close-dialog {
  font-size: 25px;
  line-height: 1;
}

label {
  display: grid;
  gap: 7px;
  margin-top: 13px;
  color: #42464a;
  font-size: 13px;
  font-weight: 900;
}

.material-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.material-row label {
  min-width: 0;
}

.custom-text-config {
  margin: 14px 0 2px;
  padding: 12px;
  border: 1px solid rgba(165, 118, 46, 0.24);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(255, 251, 241, 0.94), rgba(244, 226, 188, 0.5));
}

.custom-text-config legend {
  padding: 0 6px;
  color: #7b4a15;
  font-size: 13px;
  font-weight: 900;
}

.custom-text-config label {
  margin-top: 8px;
}

.custom-text-config textarea {
  resize: vertical;
  min-height: 58px;
}

.family-tablet-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
  padding: 10px;
  border: 1px solid rgba(141, 91, 28, 0.2);
  background: rgba(91, 43, 20, 0.045);
}

.family-tablet-fields[hidden],
#memorialTabletFields[hidden] {
  display: none;
}

.family-tablet-fields label {
  min-width: 0;
  margin-top: 0;
}

.family-tablet-main-field {
  grid-column: 1 / -1;
}

.position-row,
.custom-plaque-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.position-row input[type="range"] {
  width: 100%;
  accent-color: #b9852d;
}

.offering-config {
  margin: 14px 0 2px;
  padding: 12px;
  border: 1px solid rgba(165, 118, 46, 0.24);
  border-radius: 8px;
  background: linear-gradient(180deg, rgba(255, 251, 241, 0.9), rgba(246, 232, 207, 0.55));
}

.offering-config legend {
  padding: 0 6px;
  color: #7b4a15;
  font-size: 13px;
  font-weight: 900;
}

.offering-toggle-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.offering-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 34px;
  margin: 0;
  padding: 8px 9px;
  border: 1px solid rgba(91, 54, 20, 0.12);
  border-radius: 8px;
  background: rgba(255, 253, 248, 0.82);
  color: #4b3424;
  font-size: 12px;
  line-height: 1.2;
}

.offering-toggle input {
  flex: 0 0 auto;
  width: 16px;
  height: 16px;
  margin: 0;
  padding: 0;
  border-radius: 4px;
  accent-color: #8f5a20;
}

.offering-toggle span {
  min-width: 0;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid rgba(32, 36, 39, 0.15);
  border-radius: 13px;
  padding: 11px 12px;
  background: #fbf7ed;
  color: var(--ink);
}

textarea {
  resize: vertical;
}

.dialog-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 18px;
}

.dialog-actions.single {
  grid-template-columns: 1fr;
}

.dish-grid,
.incense-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.incense-grid {
  grid-template-columns: 1fr;
}

.dish-grid button,
.incense-grid button {
  min-height: 74px;
  display: grid;
  align-content: center;
  gap: 5px;
  padding: 12px;
  border: 1px solid rgba(151, 92, 39, 0.16);
  border-radius: 13px;
  background: linear-gradient(180deg, #fffdf7, #f7ead2);
  color: var(--ink);
  text-align: left;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.dish-grid button {
  grid-template-columns: 58px 1fr;
  align-items: center;
  column-gap: 10px;
}

.dish-choice-visual {
  grid-row: span 2;
  position: relative;
  width: 54px;
  height: 42px;
  border-radius: 50%;
  background:
    radial-gradient(ellipse at 50% 72%, rgba(37, 18, 7, 0.16), transparent 58%),
    linear-gradient(180deg, #fff9e9, #e8d6b7);
  box-shadow: inset 0 -3px 0 rgba(151, 92, 39, 0.12), 0 7px 12px rgba(98, 55, 24, 0.13);
}

.dish-choice-visual::before {
  content: "";
  position: absolute;
  left: 7px;
  right: 7px;
  bottom: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(124, 54, 20, 0.24);
}

.dish-choice-visual::after {
  content: "";
  position: absolute;
  left: 13px;
  top: 12px;
  width: 28px;
  height: 15px;
  border-radius: 52% 48% 45% 55%;
  background: linear-gradient(135deg, #ffe1a6, #c98643 72%, #8b421f);
  box-shadow: inset 5px 4px 8px rgba(255, 244, 205, 0.46), inset -4px -3px 5px rgba(96, 34, 12, 0.2);
}

.dish-choice-visual.duck::after {
  background: linear-gradient(135deg, #c98242, #793018 76%, #4b1b10);
}

.dish-choice-visual.fish::after {
  left: 8px;
  top: 13px;
  width: 34px;
  height: 12px;
  border-radius: 60% 45% 45% 60%;
  background: linear-gradient(135deg, #f3f7ef, #93aab0 65%, #5f747b);
  box-shadow: 13px 0 0 -7px #d08742, inset 5px 3px 7px rgba(255, 255, 255, 0.55);
}

.dish-choice-visual.pork::after {
  left: 9px;
  top: 12px;
  width: 34px;
  height: 16px;
  border-radius: 5px;
  background:
    repeating-linear-gradient(90deg, rgba(105, 45, 22, 0.36) 0 2px, transparent 2px 5px),
    linear-gradient(180deg, #d97734 0 32%, #fff1d2 33% 58%, #d9a184 59% 100%);
  box-shadow:
    inset 0 3px 3px rgba(255, 225, 155, 0.4),
    inset 0 -4px 5px rgba(99, 34, 15, 0.24),
    0 4px 6px rgba(52, 22, 10, 0.22);
}

.incense-grid button {
  grid-template-columns: 44px 1fr;
  align-items: center;
  column-gap: 12px;
  min-height: 88px;
  background:
    linear-gradient(135deg, rgba(133, 34, 28, 0.08), rgba(233, 191, 104, 0.18)),
    linear-gradient(180deg, #fffdf7, #f7ead2);
}

.incense-grid em {
  grid-row: span 2;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 28%, #ffe6a7, #c58332 64%, #73331f);
  color: #fff8dc;
  font-style: normal;
  font-size: 20px;
  font-weight: 950;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.5), 0 8px 16px rgba(115, 51, 31, 0.18);
}

.dish-grid strong,
.incense-grid strong {
  font-size: 14px;
}

.dish-grid span,
.incense-grid span {
  color: #696058;
  font-size: 11px;
  line-height: 1.35;
}

.dialog-actions button {
  min-height: 42px;
  border-radius: 999px;
  background: rgba(32, 36, 39, 0.08);
  font-weight: 900;
}

.dialog-actions .primary {
  background: linear-gradient(135deg, var(--cinnabar), #6f201c);
}

@media (min-width: 901px) {
  body.is-immersive-layout .workspace {
    grid-template-columns: minmax(430px, 500px) minmax(286px, 340px);
    gap: 18px;
  }

  body.is-immersive-layout .phone {
    width: min(500px, calc(100vw - 24px));
  }

  body.is-immersive-layout .product-panel {
    padding: 20px;
  }

  body.is-immersive-layout .panel-heading h2 {
    font-size: clamp(24px, 3vw, 32px);
  }

  body.is-immersive-layout .panel-heading span {
    font-size: 13px;
    line-height: 1.55;
  }

  body.is-immersive-layout .ops-section {
    margin-top: 16px;
    padding-top: 16px;
  }

  body.is-immersive-layout .ops-section h3 {
    margin-bottom: 10px;
    font-size: 15px;
  }

  body.is-immersive-layout .ops-section dl {
    gap: 7px;
  }

  body.is-immersive-layout .ops-section dl div {
    grid-template-columns: 64px 1fr;
    gap: 8px;
    padding: 10px;
    border-radius: 11px;
  }

  body.is-immersive-layout .module-grid,
  body.is-immersive-layout .value-grid {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  body.is-immersive-layout .module-grid span,
  body.is-immersive-layout .value-grid span {
    min-height: 34px;
    border-radius: 11px;
    font-size: 12px;
  }

  body.is-immersive-layout .roadmap {
    font-size: 13px;
    line-height: 1.55;
  }
}

@media (max-width: 900px) {
  .landing-nav {
    align-items: flex-start;
  }

  .landing-nav-actions {
    flex-wrap: wrap;
    justify-content: flex-end;
  }

  .landing-hero {
    min-height: auto;
    grid-template-columns: 1fr;
    gap: 34px;
    padding-top: 22px;
  }

  .landing-copy h1 {
    font-size: clamp(36px, 11vw, 56px);
  }

  .landing-subtitle {
    font-size: 16px;
  }

  .landing-showcase {
    min-height: 520px;
  }

  .showcase-hall {
    height: 500px;
  }

  .landing-sections {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .workspace {
    grid-template-columns: 1fr;
    align-items: start;
    padding: 14px;
  }

  .phone {
    justify-self: center;
    height: auto;
    min-height: 820px;
  }

  .product-panel {
    width: min(430px, calc(100vw - 24px));
    justify-self: center;
    max-height: none;
  }
}

@media (max-width: 460px) {
  .landing-nav,
  .landing-hero,
  .landing-sections {
    width: min(100% - 24px, 430px);
  }

  .landing-nav {
    padding: 16px 0 8px;
  }

  .landing-brand small {
    display: none;
  }

  .landing-nav-actions a {
    display: none;
  }

  .landing-copy h1 {
    font-size: 34px;
    line-height: 1.12;
  }

  .landing-cta-row {
    display: grid;
    grid-template-columns: 1fr;
  }

  .landing-primary,
  .landing-secondary {
    width: 100%;
  }

  .landing-showcase {
    min-height: 470px;
  }

  .showcase-hall {
    height: 450px;
    border-radius: 18px;
  }

  .showcase-plaque {
    left: 62px;
    right: 62px;
  }

  .showcase-tablet {
    width: 138px;
    height: 214px;
  }

  .landing-sections {
    grid-template-columns: 1fr;
    padding-bottom: 28px;
  }

  .landing-sections article {
    min-height: auto;
  }

  .workspace {
    padding: 0;
  }

  .phone {
    width: 100vw;
    min-height: 100vh;
    border: 0;
    border-radius: 0;
  }

  .phone.is-immersive {
    grid-template-rows: auto auto minmax(clamp(500px, 64vh, 660px), 1fr) auto minmax(72px, auto) auto;
  }

  .phone::before {
    display: none;
  }

  .scene-panel {
    min-height: 382px;
  }

  .phone.is-immersive .scene-panel {
    min-height: clamp(500px, 64vh, 660px);
  }

  .quick-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 5px;
    padding: 8px 8px 7px;
  }

  .quick-actions > button,
  .ritual-more summary {
    min-height: 50px;
    font-size: 10px;
  }

  .action-icon {
    width: 28px;
    height: 28px;
  }

  .ritual-more-panel {
    right: -2px;
    bottom: calc(100% + 8px);
    width: min(214px, calc(100vw - 16px));
  }

  .product-panel {
    width: 100%;
    border-radius: 0;
  }

  .material-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .position-row,
  .custom-plaque-grid,
  .family-tablet-fields,
  .memorial-audio-upload {
    grid-template-columns: 1fr;
  }

  .offering-toggle-grid {
    grid-template-columns: 1fr;
  }
}
