/* Eternal Invitation — invitation page v3 (modern) */
* { margin: 0; padding: 0; box-sizing: border-box; }
[hidden] { display: none !important; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
body {
  background: var(--bg, #07060a);
  color: var(--text, #f5ead1);
  font-family: var(--f-body, 'Jost', sans-serif);
  overflow-x: hidden;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* ---------- preloader ---------- */
#loader {
  position: fixed; inset: 0; z-index: 100;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  background: var(--bg, #07060a); color: var(--accent, #d4af37);
  transition: opacity .8s ease, visibility .8s;
}
#loader.done { opacity: 0; visibility: hidden; }
.ld-ring { position: relative; width: 120px; height: 120px; }
.ld-ring svg { width: 100%; height: 100%; }
#ldArc { transition: stroke-dashoffset .35s ease; }
.ld-mono {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  font-family: var(--f-display, serif); font-size: 30px; letter-spacing: .08em;
}
.ld-pct { font-size: 11px; letter-spacing: .5em; opacity: .6; padding-left: .5em; }

/* ---------- atmosphere ---------- */
/* backdrop is a soft colour atmosphere, not a visible photo — text must win */
#backdrop { position: fixed; inset: 0; z-index: 0; overflow: hidden; }
#backdrop img {
  width: 100%; height: 106%; object-fit: cover;
  transform: scale(1.22);
  filter: blur(18px) saturate(1.08) brightness(0.52);
}
#silk { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 2; pointer-events: none; mix-blend-mode: screen; }
#veil {
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 38%, var(--veil-c, rgba(7,6,10,0.55)) 0%, var(--veil-e, rgba(7,6,10,0.92)) 78%),
    linear-gradient(var(--veil-e, rgba(7,6,10,0.9)), transparent 22%, transparent 78%, var(--veil-e, rgba(7,6,10,0.94)));
}
#fx { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 3; pointer-events: none; }
#rays {
  position: fixed; inset: -20%; z-index: 2; pointer-events: none; opacity: .5;
  background: conic-gradient(from 190deg at 50% -8%,
    transparent 0deg, var(--ray, rgba(212,175,55,0.10)) 8deg, transparent 17deg,
    transparent 26deg, var(--ray, rgba(212,175,55,0.07)) 34deg, transparent 44deg,
    transparent 58deg, var(--ray, rgba(212,175,55,0.12)) 66deg, transparent 78deg,
    transparent 100deg, var(--ray, rgba(212,175,55,0.08)) 110deg, transparent 122deg, transparent 360deg);
  animation: raysSway 26s ease-in-out infinite alternate;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000 30%, transparent 78%);
}
@keyframes raysSway { from { transform: rotate(-3.5deg); } to { transform: rotate(3.5deg); } }
#grain {
  position: fixed; inset: -50%; z-index: 4; pointer-events: none; opacity: .04;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='240' height='240' filter='url(%23n)' opacity='0.7'/%3E%3C/svg%3E");
  animation: grain 8s steps(10) infinite;
}
@keyframes grain { 0%,100%{transform:translate(0,0)} 20%{transform:translate(-4%,3%)} 40%{transform:translate(3%,-4%)} 60%{transform:translate(-3%,-2%)} 80%{transform:translate(4%,2%)} }

#corners { position: fixed; inset: 0; z-index: 2; pointer-events: none; }
.pcorner { position: fixed; width: min(46vw, 340px); aspect-ratio: 1; background-size: cover; background-position: center; opacity: .62; }
.pcorner.tl { top: 0; left: 0; mask-image: radial-gradient(circle at 0% 0%, #000 22%, transparent 68%); -webkit-mask-image: radial-gradient(circle at 0% 0%, #000 22%, transparent 68%); }
.pcorner.br { bottom: 0; right: 0; mask-image: radial-gradient(circle at 100% 100%, #000 22%, transparent 68%); -webkit-mask-image: radial-gradient(circle at 100% 100%, #000 22%, transparent 68%); }
.scorner { position: fixed; width: 150px; height: 150px; color: var(--accent); opacity: .75; }
.scorner svg { width: 100%; height: 100%; display: block; }
.scorner.tl { top: 10px; left: 10px; }
.scorner.tr { top: 10px; right: 10px; transform: scaleX(-1); }
.scorner.bl { bottom: 10px; left: 10px; transform: scaleY(-1); }
.scorner.br { bottom: 10px; right: 10px; transform: scale(-1,-1); }
#letterbox i { position: fixed; left: 0; right: 0; height: 7vh; background: #000; z-index: 5; }
#letterbox .lb-t { top: 0; } #letterbox .lb-b { bottom: 0; }

/* ---------- gold foil ---------- */
.goldfoil {
  background: linear-gradient(100deg,
    var(--acc-d) 0%, var(--accent) 22%, var(--acc-l) 38%,
    #fffbe9 50%, var(--acc-l) 62%, var(--accent) 78%, var(--acc-d) 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  animation: foilShine 5.5s ease-in-out infinite;
  filter: drop-shadow(0 2px 14px var(--acc-glow));
}
@keyframes foilShine { 0%,100% { background-position: 0% 0; } 50% { background-position: 100% 0; } }
/* on light paper the near-white foil stop disappears — use deep accent tones only */
body.light .goldfoil {
  background: linear-gradient(100deg,
    var(--acc-d) 0%, var(--accent) 30%, var(--acc-l) 50%, var(--accent) 70%, var(--acc-d) 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text; background-clip: text;
  filter: none;
}
.great { font-family: 'Great Vibes', cursive; }

/* ---------- 3D envelope ---------- */
#cover {
  position: fixed; inset: 0; z-index: 50;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 40px;
  cursor: pointer; touch-action: manipulation; -webkit-tap-highlight-color: transparent;
}
.env-stage { perspective: 1400px; position: relative; }
.envelope {
  position: relative;
  width: min(86vw, 420px); aspect-ratio: 10/7;
  transform-style: preserve-3d;
  animation: envFloat 5s ease-in-out infinite;
}
@keyframes envFloat { 0%,100% { transform: translateY(0) rotateX(8deg); } 50% { transform: translateY(-12px) rotateX(10deg); } }
.env-shadow {
  width: 70%; height: 26px; margin: 26px auto 0;
  background: radial-gradient(ellipse, rgba(0,0,0,.55), transparent 70%);
  animation: envShadow 5s ease-in-out infinite;
}
@keyframes envShadow { 0%,100% { transform: scaleX(1); opacity: .8; } 50% { transform: scaleX(.86); opacity: .55; } }

.env-back, .env-pocket, .env-flap { position: absolute; inset: 0; }
.env-back {
  background: linear-gradient(160deg, var(--env-2), var(--env-1) 60%);
  border: 1px solid var(--acc-25);
  box-shadow: 0 40px 90px rgba(0,0,0,.6);
}
.env-letter {
  position: absolute; left: 5%; right: 5%; top: 6%; bottom: 8%;
  background:
    radial-gradient(ellipse at 50% 0%, var(--acc-08), transparent 60%),
    linear-gradient(175deg, var(--paper-1), var(--paper-2));
  border: 1px solid var(--acc-25);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  text-align: center; padding: 18px;
  box-shadow: 0 6px 30px rgba(0,0,0,.35);
}
.el-guest { font-size: clamp(20px, 5vw, 26px); color: var(--paper-ink); opacity: .9; }
.el-orn { color: var(--accent); font-size: 13px; letter-spacing: .4em; padding-left: .4em; }
.el-names { font-family: var(--f-display); font-size: clamp(20px, 5vw, 28px); letter-spacing: .06em; color: var(--paper-ink); }
.el-date { font-size: 11px; letter-spacing: .4em; color: var(--paper-ink); opacity: .6; padding-left: .4em; }
.env-pocket {
  background: linear-gradient(200deg, var(--env-2) 0%, var(--env-1) 70%);
  clip-path: polygon(0 0, 50% 44%, 100% 0, 100% 100%, 0 100%);
  border: 1px solid var(--acc-25);
  box-shadow: inset 0 -20px 50px rgba(0,0,0,.25);
}
.env-pocket::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(115deg, transparent 30%, var(--acc-08) 46%, transparent 60%);
}
.env-flap {
  clip-path: polygon(0 0, 100% 0, 50% 58%);
  transform-origin: top center;
  transform-style: preserve-3d;
  z-index: 3;
}
.env-flap-in {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, var(--env-3), var(--env-2) 80%);
  border-top: 1px solid var(--acc-40);
}
.env-seal {
  position: absolute; left: 50%; top: 50%;
  width: clamp(64px, 17vw, 84px); height: clamp(64px, 17vw, 84px);
  transform: translate(-50%, -42%);
  border-radius: 50%; border: none; cursor: pointer; z-index: 4;
  background:
    radial-gradient(circle at 34% 30%, var(--acc-l), var(--accent) 46%, var(--acc-d) 88%);
  box-shadow: 0 8px 26px rgba(0,0,0,.5), inset 0 -3px 8px rgba(0,0,0,.35), inset 0 2px 5px rgba(255,255,255,.35), 0 0 0 6px var(--acc-15);
  display: flex; align-items: center; justify-content: center;
  animation: sealBeat 2.6s ease-in-out infinite;
}
@keyframes sealBeat { 0%,100% { transform: translate(-50%,-42%) scale(1); } 50% { transform: translate(-50%,-42%) scale(1.055); } }
.seal-amp { font-family: var(--f-display); font-size: clamp(26px, 7vw, 36px); color: var(--bg); opacity: .85; }
.env-hint { font-size: 12px; letter-spacing: .5em; text-transform: uppercase; opacity: .55; padding-left: .5em; animation: hintFade 2.6s ease-in-out infinite; }
@keyframes hintFade { 0%,100% { opacity: .35; } 50% { opacity: .75; } }

/* ---------- intro ---------- */
#intro {
  position: fixed; inset: 0; z-index: 40; display: none;
  align-items: center; justify-content: center;
  background: radial-gradient(ellipse at 50% 45%, transparent, rgba(0,0,0,.5)), var(--veil-solid, rgba(5,4,8,0.88));
}
#introText {
  font-family: var(--f-display, serif); font-size: clamp(30px, 7vw, 58px);
  font-style: italic; color: var(--text); text-align: center; padding: 0 24px; opacity: 0;
  text-shadow: 0 4px 40px rgba(0,0,0,.6);
}

/* ---------- scenes ---------- */
#story { position: relative; z-index: 6; }
.scene {
  min-height: 100vh; min-height: 100svh; display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center;
  padding: 100px 22px; position: relative;
}
.chip {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 11px; letter-spacing: .3em; text-transform: uppercase;
  color: var(--accent); padding: 9px 18px 9px calc(18px + .3em);
  border: 1px solid var(--acc-25); border-radius: 100px;
  background: var(--panel); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  margin-bottom: 34px;
}
#progress {
  position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 80;
  background: linear-gradient(90deg, var(--acc-d), var(--accent), var(--acc-l));
  transform: scaleX(0); transform-origin: left; box-shadow: 0 0 12px var(--acc-glow);
}
.names { font-family: var(--f-display, serif); font-weight: 500; line-height: 1.04; }
.nline { display: block; overflow: hidden; padding: 0 12px; }
.names .n1, .names .n2 { display: inline-block; font-size: clamp(54px, 13vw, 118px); letter-spacing: .04em; padding-bottom: 6px; }
.names .n1 .ch, .names .n2 .ch { display: inline-block; }
.names .amp { display: block; font-size: clamp(36px, 7.4vw, 60px); color: var(--accent); margin: 4px 0; opacity: .95; }
.names .amp::before { content: '&'; }
.rule-wrap { display: flex; align-items: center; gap: 14px; margin-top: 34px; width: min(70vw, 380px); }
.rule { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, var(--acc-60)); transform-origin: right; }
.rule:last-child { background: linear-gradient(90deg, var(--acc-60), transparent); transform-origin: left; }
.diamond { width: 7px; height: 7px; background: var(--accent); transform: rotate(45deg); box-shadow: 0 0 14px var(--acc-glow); }
.date-teaser { margin-top: 26px; font-size: 16px; letter-spacing: .3em; padding-left: .3em; color: var(--text); opacity: .95; font-variant-numeric: tabular-nums; text-shadow: 0 2px 18px rgba(0,0,0,.6); }
.scroll-pill {
  position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%);
  width: 26px; height: 44px; border: 1px solid var(--acc-40); border-radius: 100px;
  display: flex; justify-content: center; padding-top: 8px;
}
.scroll-pill span { width: 3px; height: 8px; border-radius: 3px; background: var(--accent); animation: wheel 1.8s ease-in-out infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(16px); opacity: 0; } 100% { opacity: 0; } }

/* story / photo */
.photo-stage {
  width: min(82vw, 440px); aspect-ratio: 3/4; position: relative; margin-bottom: 46px;
  padding: 12px; background: var(--panel);
  border: 1px solid var(--acc-40);
  box-shadow: 0 30px 80px rgba(0,0,0,.55), 0 0 0 7px var(--acc-08);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.pf-c { position: absolute; width: 34px; height: 34px; border-color: var(--accent); border-style: solid; z-index: 2; }
.pf-tl { top: -6px; left: -6px; border-width: 1.5px 0 0 1.5px; }
.pf-br { bottom: -6px; right: -6px; border-width: 0 1.5px 1.5px 0; }
.photo-stage .ph-in { position: absolute; inset: 12px; overflow: hidden; }
.photo-stage img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph-mono {
  font-family: var(--f-display); font-size: 84px; color: var(--accent); opacity: .85;
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 35%, var(--acc-15), transparent 70%);
}
.story-text {
  max-width: 560px; font-size: clamp(20px, 5vw, 24px); line-height: 1.9;
  font-style: italic; font-family: var(--f-display); opacity: 1; color: var(--text);
  text-shadow: 0 2px 26px rgba(0,0,0,.75);
}

/* details glass card */
.glass {
  position: relative; width: min(94vw, 620px);
  padding: clamp(30px, 6vw, 54px) clamp(20px, 4.5vw, 44px);
  background: var(--panel);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  border-radius: 20px;
  box-shadow: 0 34px 90px rgba(0,0,0,.5);
}
.glass::before {
  content: ''; position: absolute; inset: 0; border-radius: 20px; padding: 1px;
  background: linear-gradient(150deg, var(--acc-60), transparent 32%, transparent 68%, var(--acc-40));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  pointer-events: none;
}
.inv-line { font-size: clamp(16px, 4.2vw, 19px); line-height: 1.85; letter-spacing: .03em; opacity: .96; margin-bottom: 36px; }
.big-date { display: flex; align-items: center; justify-content: center; gap: 24px; font-family: var(--f-display); }
.bd-day { font-size: clamp(84px, 18vw, 140px); line-height: .95; font-weight: 500; }
.bd-rest { text-align: left; border-left: 1px solid var(--acc-40); padding-left: 24px; }
.bd-month { font-size: clamp(20px, 4.2vw, 30px); letter-spacing: .26em; text-transform: uppercase; }
.bd-year { font-size: clamp(18px, 3.6vw, 26px); letter-spacing: .32em; color: var(--soft); margin-top: 6px; }
.bd-weektime { margin-top: 16px; font-size: 14px; letter-spacing: .2em; text-transform: uppercase; color: var(--text); opacity: .85; }

/* flip countdown */
.countdown { display: flex; justify-content: center; gap: clamp(10px, 3vw, 22px); margin: 40px 0; perspective: 500px; }
.unit { display: flex; flex-direction: column; align-items: center; gap: 9px; }
.flip {
  min-width: clamp(58px, 14vw, 76px); padding: 12px 8px;
  font-family: var(--f-display); font-size: clamp(28px, 6.4vw, 42px); font-weight: 500;
  color: var(--accent); font-variant-numeric: tabular-nums;
  background: linear-gradient(180deg, var(--flip-1), var(--flip-2));
  border: 1px solid var(--acc-25); border-radius: 12px;
  box-shadow: 0 10px 26px rgba(0,0,0,.35), inset 0 1px 0 var(--acc-15);
  position: relative;
}
.flip::after { content: ''; position: absolute; left: 6%; right: 6%; top: 50%; height: 1px; background: var(--acc-15); }
.unit i { font-style: normal; font-size: 10px; letter-spacing: .3em; text-transform: uppercase; opacity: .55; padding-left: .3em; }

.venue-name { font-family: var(--f-display); font-size: clamp(26px, 5.2vw, 38px); letter-spacing: .08em; }
.venue-addr { margin-top: 8px; font-size: 16px; opacity: .88; line-height: 1.65; }
.parents { margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--acc-15); }
.par-title { font-size: 11px; letter-spacing: .36em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; padding-left: .36em; }
.par-names { display: flex; flex-direction: column; gap: 6px; }
.par-names span { font-family: var(--f-display); font-size: clamp(17px, 3.6vw, 21px); letter-spacing: .04em; opacity: .95; }
.par-names span:empty { display: none; }
.btns { display: flex; gap: 14px; margin-top: 36px; flex-wrap: wrap; justify-content: center; }
.btn {
  text-decoration: none; font-size: 12px; letter-spacing: .24em; text-transform: uppercase;
  padding: 18px 34px 18px calc(34px + .24em); border-radius: 100px; transition: .35s; cursor: pointer; will-change: transform;
}
.btn-solid { background: linear-gradient(120deg, var(--acc-d), var(--accent) 55%, var(--acc-l)); color: var(--bg); box-shadow: 0 12px 36px var(--acc-glow); }
@media (hover: hover) { .btn-solid:hover { filter: brightness(1.1); } }
.btn-ghost { border: 1px solid var(--acc-60); color: var(--accent); background: var(--panel); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
@media (hover: hover) { .btn-ghost:hover { background: var(--acc-15); } }

/* horizontal gallery */
#s-gallery { padding: 110px 0 60px; }
.g-head { text-align: center; padding: 0 22px; }
.g-title { font-family: var(--f-display); font-size: clamp(28px, 6vw, 44px); letter-spacing: .1em; margin-bottom: 10px; text-shadow: 0 2px 22px rgba(0,0,0,.7); }
.g-viewport { overflow: hidden; }
.g-track { display: flex; gap: clamp(16px, 3vw, 28px); padding: 40px max(6vw, 24px) 60px; width: max-content; }
.g-item {
  flex: 0 0 auto; width: clamp(240px, 62vw, 380px); aspect-ratio: 3/4;
  padding: 10px; background: var(--panel); border: 1px solid var(--acc-25);
  box-shadow: 0 22px 60px rgba(0,0,0,.5);
  transform: rotate(var(--tilt, 0deg));
}
.g-item:nth-child(odd) { --tilt: 1.2deg; margin-top: 26px; }
.g-item:nth-child(even) { --tilt: -1.2deg; }
.g-item .gi-in { width: 100%; height: 100%; overflow: hidden; }
.g-item img { width: 110%; height: 100%; object-fit: cover; margin-left: -5%; display: block; }

/* final */
.final-script { font-size: clamp(60px, 13vw, 104px); color: var(--accent); line-height: 1.1; margin-bottom: 4px; text-shadow: 0 4px 34px var(--acc-glow); }
.final-text { font-family: var(--f-display); font-style: italic; font-size: clamp(21px, 5vw, 30px); line-height: 1.8; text-shadow: 0 2px 26px rgba(0,0,0,.7); }
.final-names { margin-top: 26px; font-family: var(--f-display); font-size: clamp(26px, 5.4vw, 36px); letter-spacing: .1em; }
.watermark { margin-top: 80px; text-decoration: none; text-align: center; opacity: .55; transition: opacity .4s; display: flex; flex-direction: column; gap: 4px; }
.watermark:hover { opacity: .95; }
.watermark span { font-size: 12px; letter-spacing: .34em; text-transform: uppercase; color: var(--text); }
.watermark em { font-style: normal; font-size: 12px; color: var(--accent); letter-spacing: .06em; }

/* wishes / guestbook */
#s-wishes { padding-top: 100px; padding-bottom: 60px; }
#wishForm { margin-bottom: 46px; text-align: left; }
.field-w { margin-bottom: 16px; }
.field-w label { display: block; font-size: 11px; letter-spacing: .26em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; opacity: .9; }
.field-w input, .field-w textarea {
  width: 100%; background: var(--acc-08); border: 1px solid var(--acc-25); color: var(--text);
  font-family: var(--f-body); font-size: 15px; padding: 13px 15px; outline: none; transition: border-color .3s;
  border-radius: 10px;
}
.field-w input:focus, .field-w textarea:focus { border-color: var(--acc-60); }
.field-w textarea { min-height: 88px; resize: vertical; font-family: var(--f-display); font-style: italic; }
#wishSubmit { width: 100%; margin-top: 4px; }
.wish-msg { margin-top: 12px; font-size: 13px; text-align: center; min-height: 18px; }
.wish-msg.ok { color: var(--accent); }
.wish-msg.err { color: #e08a8a; }
.wish-wall { width: min(94vw, 620px); display: flex; flex-direction: column; gap: 14px; }
.wish-card {
  text-align: left; padding: 18px 22px; background: var(--panel);
  border-left: 2px solid var(--accent); border-radius: 4px 12px 12px 4px;
  box-shadow: 0 10px 30px rgba(0,0,0,.25);
}
.wish-card .wc-name { font-family: var(--f-display); font-size: 17px; color: var(--accent); margin-bottom: 6px; }
.wish-card .wc-msg { font-size: 15px; line-height: 1.65; opacity: .95; font-style: italic; font-family: var(--f-display); }
.wish-empty { opacity: .5; font-size: 14px; font-style: italic; }
body.kit-editorial .wish-wall, body.kit-editorial #wishForm { margin-left: 0; }
body.kit-minimal .wish-card { background: none; border-left: 1px solid var(--acc-40); border-radius: 0; box-shadow: none; }
body.kit-minimal .field-w input, body.kit-minimal .field-w textarea { background: none; border-radius: 0; }

/* custom cursor (desktop) */
#cursor { position: fixed; inset: 0; z-index: 90; pointer-events: none; }
.cur-dot, .cur-ring { position: fixed; top: 0; left: 0; border-radius: 50%; will-change: transform; }
.cur-dot { width: 6px; height: 6px; background: var(--accent); margin: -3px 0 0 -3px; }
.cur-ring {
  width: 36px; height: 36px; margin: -18px 0 0 -18px;
  border: 1px solid var(--acc-60); transition: width .25s, height .25s, margin .25s, opacity .25s;
}
#cursor.hov .cur-ring { width: 58px; height: 58px; margin: -29px 0 0 -29px; opacity: .9; }
@media (pointer: coarse) { #cursor { display: none; } }

/* mute */
#muteBtn {
  position: fixed; right: 18px; bottom: 18px; z-index: 60;
  width: 46px; height: 46px; border-radius: 50%; cursor: pointer;
  background: var(--panel); border: 1px solid var(--acc-40);
  color: var(--accent); display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
#muteBtn svg { width: 20px; height: 20px; }

/* light theme */
body.light #grain { opacity: .028; }
body.light #backdrop img { filter: blur(18px) saturate(.95) brightness(1.06); }
body.light .story-text, body.light #introText { text-shadow: none; }
body.light #silk { mix-blend-mode: multiply; opacity: .5; }
body.light .glass, body.light .photo-stage, body.light .g-item { box-shadow: 0 24px 70px rgba(60,45,30,.2); }

@media (max-width: 480px) {
  .big-date { gap: 16px; }
  .btns { width: 100%; }
  .btn { flex: 1 1 auto; text-align: center; padding: 16px 8px 16px calc(8px + .24em); }
  .pcorner { opacity: .55; }
  .scorner { width: 96px; height: 96px; }
}

/* ============ LAYOUT KITS ============ */
/* --- editorial: left-aligned, magazine typography --- */
body.kit-editorial .scene {
  align-items: flex-start; text-align: left;
  padding-left: clamp(26px, 9vw, 110px); padding-right: clamp(20px, 6vw, 70px);
}
body.kit-editorial .nline { padding: 0; }
body.kit-editorial .names .n1, body.kit-editorial .names .n2 { letter-spacing: .01em; }
body.kit-editorial .names .amp { margin: 2px 0 2px 4px; }
body.kit-editorial .rule-wrap { width: min(56vw, 300px); }
body.kit-editorial .scroll-pill { left: clamp(26px, 9vw, 110px); transform: none; }
body.kit-editorial .photo-stage { transform: rotate(0deg); }
body.kit-editorial .glass { text-align: left; border-radius: 0; }
body.kit-editorial .glass::before { border-radius: 0; }
body.kit-editorial .big-date, body.kit-editorial .countdown, body.kit-editorial .btns { justify-content: flex-start; }
body.kit-editorial .flip { border-radius: 0; }
body.kit-editorial .btn { border-radius: 0; }
body.kit-editorial .chip { border-radius: 0; }
body.kit-editorial .g-head { text-align: left; padding-left: clamp(26px, 9vw, 110px); }
body.kit-editorial .story-text { font-style: normal; }
body.kit-editorial .final-script { margin-left: -8px; }
body.kit-editorial .pcorner.tl { display: none; }
body.kit-editorial .scorner.tl, body.kit-editorial .scorner.tr { display: none; }

/* --- minimal: air, restraint, no ornament --- */
body.kit-minimal #corners, body.kit-minimal #rays { display: none; }
body.kit-minimal #grain { opacity: .025; }
body.kit-minimal .chip { border: none; background: none; backdrop-filter: none; letter-spacing: .5em; padding-left: .5em; }
body.kit-minimal .names .n1, body.kit-minimal .names .n2 { font-weight: 400; letter-spacing: .08em; }
body.kit-minimal .rule-wrap { width: 100px; }
body.kit-minimal .diamond { border-radius: 50%; box-shadow: none; }
body.kit-minimal .photo-stage { padding: 0; background: none; border: none; box-shadow: 0 34px 90px rgba(0,0,0,.6); }
body.kit-minimal .photo-stage .ph-in { inset: 0; }
body.kit-minimal .pf-c { display: none; }
body.kit-minimal .glass { background: none; -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: none; padding-left: 0; padding-right: 0; width: min(94vw, 560px); }
body.kit-minimal .glass::before { display: none; }
body.kit-minimal .flip { background: none; border: none; box-shadow: none; padding: 0; min-width: 54px; }
body.kit-minimal .flip::after { display: none; }
body.kit-minimal .countdown { border-top: 1px solid var(--acc-15); border-bottom: 1px solid var(--acc-15); padding: 22px 10px; }
body.kit-minimal .btn { border-radius: 0; letter-spacing: .3em; }
body.kit-minimal .btn-solid { background: var(--accent); box-shadow: none; }
body.kit-minimal .g-item { padding: 0; background: none; border: none; }
body.kit-minimal .g-item:nth-child(odd), body.kit-minimal .g-item:nth-child(even) { --tilt: 0deg; margin-top: 0; }
body.kit-minimal .seal-amp { font-weight: 400; }
body.kit-minimal .env-back, body.kit-minimal .env-pocket { border-radius: 0; }
body.kit-minimal .watermark { opacity: .4; }

/* --- paper: light botanical card (ChungDoi-style) --- */
body.kit-paper #rays, body.kit-paper #silk { display: none; }
body.kit-paper #grain { opacity: .035; }
body.kit-paper #backdrop img { filter: blur(22px) saturate(.85) brightness(1.12); opacity: .55; }
body.kit-paper .pcorner { opacity: .85; }
body.kit-paper .pcorner.tl { mask-image: radial-gradient(circle at 0% 0%, #000 30%, transparent 72%); -webkit-mask-image: radial-gradient(circle at 0% 0%, #000 30%, transparent 72%); }
body.kit-paper .pcorner.br { mask-image: radial-gradient(circle at 100% 100%, #000 30%, transparent 72%); -webkit-mask-image: radial-gradient(circle at 100% 100%, #000 30%, transparent 72%); }

body.kit-paper .paper-arch {
  position: relative;
  padding: clamp(54px, 12vw, 84px) clamp(26px, 7vw, 52px) clamp(30px, 6vw, 44px);
  max-width: min(88vw, 460px);
}
body.kit-paper .paper-arch::before, body.kit-paper .paper-arch::after {
  content: ''; position: absolute; pointer-events: none;
  border: 1.4px solid var(--accent);
  border-radius: 999px 999px 10px 10px / 40% 40% 10px 10px;
}
body.kit-paper .paper-arch::before { inset: 0; opacity: .85; }
body.kit-paper .paper-arch::after { inset: 9px; border-width: 0.8px; opacity: .45; }

body.kit-paper .chip { border: none; background: none; backdrop-filter: none; letter-spacing: .44em; padding-left: .44em; font-size: 10px; margin-bottom: 22px; }
body.kit-paper .names .n1, body.kit-paper .names .n2 {
  font-size: clamp(40px, 9.5vw, 72px); font-weight: 500; letter-spacing: .06em;
}
body.kit-paper .goldfoil { animation-duration: 9s; filter: none; }
body.kit-paper .names .amp { font-size: clamp(30px, 6vw, 46px); }
body.kit-paper .rule-wrap { width: min(50vw, 220px); margin-top: 24px; }
body.kit-paper .date-teaser { text-shadow: none; opacity: .8; }
body.kit-paper .story-text, body.kit-paper .final-text { text-shadow: none; }

/* polaroid photo with wax seal */
body.kit-paper .photo-stage {
  padding: 14px 14px 58px; background: #fffdf8;
  border: 1px solid rgba(90, 70, 40, .14);
  box-shadow: 0 18px 50px rgba(90, 70, 40, .18);
  transform: rotate(-2deg); border-radius: 3px;
}
body.kit-paper .photo-stage .ph-in { inset: 14px 14px 58px; }
body.kit-paper .pf-c { display: none; }
body.kit-paper .photo-stage::after {
  content: '&'; position: absolute; right: 16px; bottom: 8px; width: 42px; height: 42px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-family: var(--f-display); font-size: 20px; color: #fffdf8;
  background: radial-gradient(circle at 34% 30%, var(--acc-l), var(--accent) 50%, var(--acc-d) 92%);
  box-shadow: 0 3px 10px rgba(90, 70, 40, .3), inset 0 -2px 5px rgba(0,0,0,.25);
  transform: rotate(8deg);
}

/* paper card instead of glass */
body.kit-paper .glass {
  background: rgba(255, 253, 248, .92);
  -webkit-backdrop-filter: none; backdrop-filter: none;
  border-radius: 8px;
  box-shadow: 0 22px 60px rgba(90, 70, 40, .16);
}
body.kit-paper .glass::before {
  border-radius: 8px;
  background: linear-gradient(150deg, var(--acc-40), var(--acc-15) 40%, var(--acc-40));
}
body.kit-paper .flip {
  background: #fffdf8; border: 1px solid rgba(90, 70, 40, .16);
  box-shadow: 0 6px 18px rgba(90, 70, 40, .12); border-radius: 10px;
}
body.kit-paper .btn { border-radius: 4px; letter-spacing: .2em; }
body.kit-paper .btn-solid { box-shadow: 0 10px 26px var(--acc-glow); }
body.kit-paper .btn-ghost { background: #fffdf8; }

body.kit-paper .g-item {
  padding: 10px 10px 34px; background: #fffdf8;
  border: 1px solid rgba(90, 70, 40, .14);
  box-shadow: 0 16px 40px rgba(90, 70, 40, .16);
  border-radius: 3px;
}
body.kit-paper .g-title { text-shadow: none; }

/* light paper envelope */
body.kit-paper .env-back { background: linear-gradient(160deg, #efe6d6, #e6dac4 60%); border-color: rgba(150, 120, 70, .35); }
body.kit-paper .env-pocket { background: linear-gradient(200deg, #f3ebdc 0%, #e9decb 70%); border-color: rgba(150, 120, 70, .3); }
body.kit-paper .env-flap-in { background: linear-gradient(180deg, #f6efe2, #ece1cd 80%); border-top-color: rgba(150, 120, 70, .4); }
body.kit-paper .env-letter { border-color: rgba(150, 120, 70, .3); }
body.kit-paper .env-shadow { background: radial-gradient(ellipse, rgba(90, 70, 40, .3), transparent 70%); }
body.kit-paper .watermark { opacity: .55; }
@media (prefers-reduced-motion: reduce) {
  #rays, #grain, .envelope, .env-shadow, .env-seal, .goldfoil { animation: none !important; }
}
