/* Royal Keepsake: layered local artwork behind real invitation controls. */
@keyframes invitationReveal{from{opacity:0;transform:translateY(14px) scale(.985)}to{opacity:1;transform:translateY(0) scale(1)}}
@keyframes crownFloat{0%,100%{transform:translateY(0)}50%{transform:translateY(-4px)}}
@keyframes balloonDrift{0%,100%{transform:translate3d(0,0,0)}50%{transform:translate3d(3px,-5px,0)}}
body[data-theme="royal-burgundy"] .screen.active{animation:invitationReveal .5s cubic-bezier(.2,.75,.25,1) both}
body[data-theme="royal-burgundy"] .screen.active .crown{animation:crownFloat 3.4s ease-in-out .45s both}
body[data-theme="royal-burgundy"] .screen.active .balloon-cluster{animation:balloonDrift 5s ease-in-out .25s both}
body[data-theme="royal-burgundy"] .app-shell{background:radial-gradient(ellipse at 50% -15%,#831a2a 0,#4e0610 43%,#250006 100%)}
body[data-theme="royal-burgundy"] .app-shell:before{border-color:#c49a57aa}
body[data-theme="royal-burgundy"] .desktop-stage{width:min(1420px,100%);grid-template-columns:minmax(150px,1fr) minmax(340px,440px) minmax(150px,1fr);gap:clamp(20px,4vw,64px);padding:42px clamp(18px,4vw,60px)}
body[data-theme="royal-burgundy"] .desktop-copy{align-self:center}
body[data-theme="royal-burgundy"] .desktop-copy h1{font-family:Georgia,serif;font-size:clamp(38px,4vw,58px);line-height:1;letter-spacing:.04em;color:#f4dba6}
body[data-theme="royal-burgundy"] .desktop-copy .script{font-family:Georgia,serif;font-size:clamp(36px,4vw,62px);font-style:italic;color:#f7e5bd;overflow-wrap:anywhere}
body[data-theme="royal-burgundy"] .phone-shell.invitation-phone{max-width:440px;min-height:0;padding:0;background:transparent;border-radius:10px;box-shadow:0 32px 72px #16000699}
body[data-theme="royal-burgundy"] .phone-shell.invitation-phone .phone-content{border:1px solid #d3ad69;border-radius:8px;overflow:hidden}
body[data-theme="royal-burgundy"] .cover-content{min-height:min(100dvh,850px);height:auto;position:relative;background:#650916 url('/assets/royal-satin-stage.png') center/cover no-repeat;color:#fff9ec}
body[data-theme="royal-burgundy"] .cover-photo-wrap{isolation:auto;height:335px;margin:74px 32px 0;border:2px solid #d8b46a;border-radius:48% 48% 5px 5px;overflow:hidden;box-shadow:0 0 0 5px #4e0814,0 0 0 7px #d3ad69,0 15px 35px #26020aaa}
body[data-theme="royal-burgundy"] .cover-photo-wrap img{object-position:center 24%}
body[data-theme="royal-burgundy"] .cover-photo-fade{inset:55% 0 0;background:linear-gradient(transparent,#36030dcc)}
body[data-theme="royal-burgundy"] .cover-copy-mobile{position:relative;margin:-8px 17px 0;padding:10px 16px 0;color:#fff8e8;text-align:center;background:transparent}
body[data-theme="royal-burgundy"] .cover-copy-mobile .crown{font-size:24px;color:#d9b66f;text-shadow:0 2px 8px #3c0208}
body[data-theme="royal-burgundy"] .cover-copy-mobile .smallcaps{display:none}
body[data-theme="royal-burgundy"] .cover-copy-mobile h2{margin:3px 0 1px;color:#f8e3b3;font:400 clamp(43px,10vw,72px)/1.08 "Segoe Script","Brush Script MT",cursive;text-shadow:0 3px 8px #3c0208;overflow-wrap:anywhere}
body[data-theme="royal-burgundy"] .cover-copy-mobile .event-title{font:20px/1.2 Georgia,serif;color:#fff6e9}
body[data-theme="royal-burgundy"] .cover-copy-mobile .gold-divider{margin:7px 0}
body[data-theme="royal-burgundy"] .cover-copy-mobile .gold-divider:before,body[data-theme="royal-burgundy"] .cover-copy-mobile .gold-divider:after{background:#dbb96f}
body[data-theme="royal-burgundy"] .cover-copy-mobile .gold-divider span{background:#dbb96f}
body[data-theme="royal-burgundy"] .cover-copy-mobile .full-name{margin:6px 0 10px;color:#f6e3bc;font-size:10px;letter-spacing:.24em}
body[data-theme="royal-burgundy"] .invitation-details-card{position:relative;max-width:360px;margin:12px auto 0;padding:28px 17px 12px;color:#4a1718;background:radial-gradient(ellipse at 50% 0,#fffdf4,#f4e6ca 76%,#e2c997);border:1px solid #d7b36d;border-radius:5px;box-shadow:0 9px 22px #26020a66}
body[data-theme="royal-burgundy"] .invitation-details-card:before{content:"";position:absolute;inset:5px;border:1px solid #cda756;border-radius:3px;pointer-events:none}
body[data-theme="royal-burgundy"] .envelope-flap{position:absolute;top:-13px;left:calc(50% - 15px);display:grid;place-items:center;width:30px;height:30px;border:1px solid #b78b41;border-radius:50%;color:#781025;background:#f7ebd4;box-shadow:0 2px 5px #4a142233;z-index:1}
body[data-theme="royal-burgundy"] .invitation-details-card .event-info{margin:0 0 9px;gap:8px}
body[data-theme="royal-burgundy"] .invitation-details-card .event-row{grid-template-columns:23px 1fr;gap:5px}
body[data-theme="royal-burgundy"] .invitation-details-card .event-row .icon{font-size:15px;filter:grayscale(1)}
body[data-theme="royal-burgundy"] .invitation-details-card .event-row b{font:12px/1.4 Georgia,serif;color:#4a1718;overflow-wrap:anywhere}
body[data-theme="royal-burgundy"] .invitation-details-card .event-row small{color:#755741;font-size:10px;overflow-wrap:anywhere}
body[data-theme="royal-burgundy"] .invitation-details-card .primary-btn{position:relative;z-index:1;min-height:52px;color:#4b1719;background:linear-gradient(#fff5dc,#e6c993);border:1px solid #b8883c;box-shadow:inset 0 0 0 3px #f9efda,0 3px 8px #47101744;text-transform:none;font:17px Georgia,serif}
body[data-theme="royal-burgundy"] #openGalleryBtn{position:relative;color:#f3dfb4;background:#4c0912aa;border-radius:22px;padding:8px 17px}
body[data-theme="royal-burgundy"] .cover-content>.balloon-cluster,body[data-theme="royal-burgundy"] .cover-photo-wrap .toy-car{display:none}
body[data-theme="royal-burgundy"] .no-photo{background-image:url('/assets/royal-satin-stage.png');background-position:center;background-size:100% 100%}
body[data-theme="royal-burgundy"] .no-photo img{display:none}
body[data-theme="royal-burgundy"] .form-page{min-height:min(100dvh,760px);height:auto;padding:38px 28px 36px;background:#f8efdE url('/assets/celebration-frame.png') center/cover no-repeat;border:1px solid #d6b871;overflow:visible}
body[data-theme="royal-burgundy"] .form-page:before{content:"";position:absolute;inset:10px;border:1px solid #c39a50aa;border-radius:4px;pointer-events:none}
body[data-theme="royal-burgundy"] .form-page:after{content:"";display:none}
body[data-theme="royal-burgundy"] .form-page>*{z-index:2}
body[data-theme="royal-burgundy"] .progress-meta{display:flex;align-items:center;justify-content:center;gap:12px;margin:0 auto 7px;color:#6d2924;font:13px Georgia,serif;letter-spacing:.16em}
body[data-theme="royal-burgundy"] .progress-meta i{width:28px;height:1px;background:#b69255}
body[data-theme="royal-burgundy"] .progress{max-width:240px;margin:0 auto 17px;gap:6px}
body[data-theme="royal-burgundy"] .progress i{height:4px;background:#d8c49c}
body[data-theme="royal-burgundy"] .progress i.on{background:#790d20}
body[data-theme="royal-burgundy"] .form-page .crown{color:#a6782e;margin-bottom:8px}
body[data-theme="royal-burgundy"] .royal-scrapbook{position:relative;height:300px;margin:-24px -27px 0;overflow:hidden;background:linear-gradient(145deg,#47040e,#8a1027 58%,#42050e)}
body[data-theme="royal-burgundy"] .royal-scrapbook:before,body[data-theme="royal-burgundy"] .royal-scrapbook:after{content:"";position:absolute;width:165px;height:300px;top:-35px;background:linear-gradient(100deg,#660b1c,#9b2037 45%,#520611);border-block:1px solid #d7b66d;opacity:.9}
body[data-theme="royal-burgundy"] .royal-scrapbook:before{left:-106px;transform:rotate(-14deg);border-radius:0 35px 35px 0}
body[data-theme="royal-burgundy"] .royal-scrapbook:after{right:-106px;transform:rotate(14deg);border-radius:35px 0 0 35px}
body[data-theme="royal-burgundy"] .royal-scrapbook .circle-photo{position:absolute;left:50%;top:17px;transform:translateX(-50%) rotate(-5deg);width:235px;height:220px;margin:0;border:9px solid #fff8e9;border-bottom-width:29px;border-radius:3px;outline:1px solid #d1a958;box-shadow:0 14px 25px #25010988;z-index:1}
body[data-theme="royal-burgundy"] .royal-scrapbook .circle-photo img{width:100%;height:100%;object-fit:cover;object-position:center 25%}
body[data-theme="royal-burgundy"] .photo-ribbon{position:absolute;z-index:2;left:16px;bottom:24px;padding:7px 17px;color:#fff0d0;background:#750d23;border:1px solid #dab970;font:italic 15px Georgia,serif;transform:rotate(-8deg);box-shadow:0 4px 10px #25010966}
body[data-theme="royal-burgundy"] .royal-paper-panel{position:relative;margin:-29px -13px 0;padding:20px 13px 20px;background:linear-gradient(#fffaf0,#f3e4c7);border:1px solid #d2ad67;border-radius:35px 35px 5px 5px;box-shadow:0 -7px 22px #3e051533;z-index:3}
body[data-theme="royal-burgundy"] .royal-paper-panel:before{content:"";position:absolute;inset:6px;border:1px solid #d6b979;border-radius:29px 29px 3px 3px;pointer-events:none}
body[data-theme="royal-burgundy"] .royal-paper-panel>*{position:relative;z-index:2}
body[data-theme="royal-burgundy"] .royal-paper-panel .progress-meta{margin-bottom:4px}
body[data-theme="royal-burgundy"] .royal-paper-panel .progress{margin-bottom:18px}
body[data-theme="royal-burgundy"] .form-page h2{color:#5c1019;font:400 clamp(31px,8vw,39px)/1.06 Georgia,serif;letter-spacing:-.03em;overflow-wrap:anywhere}
body[data-theme="royal-burgundy"] .form-page h4{color:#563c31;font:400 18px/1.3 Georgia,serif}
body[data-theme="royal-burgundy"] .form-page p{font:14px/1.55 Georgia,serif;color:#765e4d}
body[data-theme="royal-burgundy"] .entry-label{display:block;margin:24px 0 7px;text-align:left;color:#5b1b1d;font:11px Georgia,serif;letter-spacing:.23em}
body[data-theme="royal-burgundy"] .royal-paper-panel .input-card{margin:0 0 9px;min-height:49px;border:1px solid #bca17c;border-radius:7px;background:#fffaf0;text-align:left}
body[data-theme="royal-burgundy"] .royal-paper-panel .input-card input{font:italic 15px Georgia,serif}
body[data-theme="royal-burgundy"] .form-page .primary-btn{position:relative;z-index:2;min-height:51px;margin-top:8px;background:linear-gradient(110deg,#8c1027,#5f0718);border:1px solid #d5b16b;box-shadow:inset 0 0 0 3px #700a1d,0 5px 10px #57091833;font:17px Georgia,serif;font-weight:400}
body[data-theme="royal-burgundy"] .writing-paper{position:relative;margin-top:17px;padding:13px 15px 12px;border:1px solid #c29a56;border-radius:15px;background:linear-gradient(#fffaf0,#f8efdf);box-shadow:inset 0 0 0 4px #fffaf0,0 3px 10px #60301622;text-align:left}
body[data-theme="royal-burgundy"] .writing-greeting{display:block;padding:0 0 9px;color:#5a151e;font:italic 27px Georgia,serif}
body[data-theme="royal-burgundy"] #prayerText{display:block;min-height:230px;padding:8px 4px 4px;border:0;border-radius:0;background:repeating-linear-gradient(to bottom,transparent 0 30px,#d2c4aa 31px,#d2c4aa 32px);font:italic 15px/32px Georgia,serif;color:#5a151e;resize:vertical}
body[data-theme="royal-burgundy"] #prayerText:focus{outline:2px solid #bb9148;outline-offset:2px}
body[data-theme="royal-burgundy"] .char-count{padding-top:7px;color:#80694f}
body[data-theme="royal-burgundy"] .circle-photo.small{width:93px;height:93px;margin:17px auto 0;border:3px solid #fdf8ec;outline:1px solid #c49b54}
body[data-theme="royal-burgundy"] .toy-car{display:none}
body[data-theme="royal-burgundy"] .verse-page .verse-results{max-height:290px}
body[data-theme="royal-burgundy"] .verse-page .verse-item{background:#fffaf0;border-color:#ddcda8}
body[data-theme="royal-burgundy"] .selfie-page .selfie-circle{width:146px;height:146px;border:4px solid #fff7e8;outline:1px solid #c49b54;background:#f3e3c6}
body[data-theme="royal-burgundy"] .selfie-page .role-option{background:#fffaf0;border-color:#ddcda8}
body[data-theme="royal-burgundy"] .selfie-page .role-option.active{background:#750d23;color:#fff8e9;border-color:#d3ac64}
body[data-theme="royal-burgundy"] .done-card{background:#fff9ee;border-color:#bf964e}
body[data-theme="royal-burgundy"] .done-card h3{color:#70101e;background:#fff9ee}
body[data-theme="royal-burgundy"] .step-back{position:relative;z-index:4;min-height:35px;width:max-content;padding:4px 10px;text-align:left;color:#681522;background:#fff6e7;border:1px solid #c49b54;border-radius:6px}
@media(max-width:700px){
  body[data-theme="royal-burgundy"] .desktop-stage{display:block;min-height:100dvh;padding:16px 10px 28px}
  body[data-theme="royal-burgundy"] .phone-shell.invitation-phone{width:min(100%,440px);max-width:440px}
  body[data-theme="royal-burgundy"] .cover-content{min-height:100dvh}
  body[data-theme="royal-burgundy"] .cover-photo-wrap{height:clamp(270px,82vw,325px);margin:70px 27px 0}
  body[data-theme="royal-burgundy"] .cover-copy-mobile{margin-left:10px;margin-right:10px;padding-inline:13px}
  body[data-theme="royal-burgundy"] .invitation-details-card{margin-top:10px;padding-inline:14px}
  body[data-theme="royal-burgundy"] .right-card{display:none}
  body[data-theme="royal-burgundy"] .desktop-copy{display:none}
  body[data-theme="royal-burgundy"] .flow-wrap{min-height:100dvh;padding:48px 10px 14px}
  body[data-theme="royal-burgundy"] .flow-wrap .phone-shell{width:100%;max-width:440px;padding:0;background:transparent;border-radius:8px}
  body[data-theme="royal-burgundy"] .flow-wrap .phone-content{border-radius:7px}
  body[data-theme="royal-burgundy"] .form-page{min-height:100dvh;padding:32px 23px calc(28px + env(safe-area-inset-bottom))}
  body[data-theme="royal-burgundy"] .royal-scrapbook{height:clamp(245px,72vw,292px);margin:-18px -22px 0}
  body[data-theme="royal-burgundy"] .royal-paper-panel{margin:-26px -12px 0;padding:18px 12px 18px}
  body[data-theme="royal-burgundy"] .royal-paper-panel .circle-photo{max-width:70vw}
}
@media(max-width:380px){
  body[data-theme="royal-burgundy"] .desktop-stage{padding-inline:8px}
  body[data-theme="royal-burgundy"] .cover-content{min-height:100dvh}
  body[data-theme="royal-burgundy"] .cover-photo-wrap{margin-inline:23px}
  body[data-theme="royal-burgundy"] .cover-copy-mobile h2{font-size:49px}
  body[data-theme="royal-burgundy"] .cover-copy-mobile .event-title{font-size:18px}
  body[data-theme="royal-burgundy"] .invitation-details-card{padding:26px 12px 11px}
  body[data-theme="royal-burgundy"] .form-page{padding-inline:19px}
  body[data-theme="royal-burgundy"] .form-page h2{font-size:30px}
  body[data-theme="royal-burgundy"] .royal-paper-panel .input-card{padding-inline:9px}
  body[data-theme="royal-burgundy"] .royal-scrapbook .circle-photo{width:210px}
}
@media(prefers-reduced-motion:reduce){body[data-theme="royal-burgundy"] *{scroll-behavior:auto!important;animation:none!important;transition:none!important}}
.copy-preview{display:grid;gap:.45rem;padding:1.2rem;margin:1rem 0 1.5rem;border:1px solid rgba(186,144,75,.55);border-radius:16px;background:linear-gradient(140deg,#fff9ef,#f2e7d4);color:#780d22;text-align:center}
.copy-preview small{font-size:.66rem;letter-spacing:.2em;color:#79582d}
.copy-preview strong{font-family:Georgia,serif;font-size:clamp(1.5rem,4vw,2rem);font-weight:400}
.toggle-row{display:flex!important;align-items:center;gap:.7rem;margin:1.1rem 0}.toggle-row input{width:auto!important;flex:none}
.submit-status{min-height:1.3em;text-align:center;font-size:.84rem;color:#6c182b;margin:.6rem auto 0}
.verse-feedback{font-size:.84rem;line-height:1.4;color:#6c182b;margin:.5rem 0}.verse-reader-link{display:block;text-align:center;color:#78182c;font-weight:700;margin:.4rem 0 .8rem;text-underline-offset:.2em}.verse-reader-link[hidden]{display:none}
.admin-tabs{grid-template-columns:repeat(5,minmax(0,1fr))}
.photo-marquee{margin:0 auto;padding:2rem 0 2.4rem;max-width:1350px;overflow:hidden;color:var(--cream)}
.photo-marquee-heading{display:flex;justify-content:space-between;align-items:center;padding:0 clamp(1rem,5vw,4rem) 1rem;font:italic clamp(1.2rem,3vw,1.8rem) Georgia,serif}.photo-marquee-heading span:last-child{color:var(--gold)}
.photo-marquee-viewport{overflow:hidden;mask-image:linear-gradient(90deg,transparent,#000 7%,#000 93%,transparent)}
.photo-marquee-track{display:flex;gap:1rem;width:max-content;animation:photoMarquee 32s linear infinite}.photo-marquee-item{flex:none;margin:0;width:clamp(160px,20vw,270px);height:clamp(130px,16vw,210px);border:5px solid var(--cream);border-bottom-width:12px;box-shadow:0 8px 26px #14000855;overflow:hidden}.photo-marquee-item img{display:block;width:100%;height:100%;object-fit:cover}
.photo-marquee-viewport:hover .photo-marquee-track,.photo-marquee-viewport:focus-within .photo-marquee-track{animation-play-state:paused}
@keyframes photoMarquee{to{transform:translateX(calc(-50% - .5rem))}}
.invitation-footer{position:relative;z-index:2;display:flex;gap:1rem;align-items:center;justify-content:center;flex-wrap:wrap;padding:2rem 1rem calc(2rem + env(safe-area-inset-bottom));color:var(--cream);border-top:1px solid color-mix(in srgb,var(--gold) 40%,transparent);font:12px/1.5 Georgia,serif;letter-spacing:.06em;text-align:center}
.invitation-footer span{opacity:.7}.invitation-footer a{color:var(--cream);text-decoration:none;border-bottom:1px solid var(--gold);padding-bottom:.18rem}
.invitation-footer .studio-link{position:static;z-index:auto;font:italic 13px Georgia,serif;letter-spacing:.02em;color:#f1d28d}.invitation-footer a:hover{color:#ffe3a5}
.connection-error button{display:block;margin:1.4rem auto .8rem;border:1px solid var(--gold);border-radius:8px;padding:.85rem 1.5rem;background:var(--cream);color:var(--red);font:600 .95rem Arial,sans-serif;cursor:pointer}
@media(max-width:750px){.admin-tabs{grid-template-columns:repeat(5,minmax(0,1fr));padding-inline:8px}.admin-tabs button{font-size:9px}.photo-marquee{padding-block:1.2rem}.photo-marquee-item{width:150px;height:128px}.invitation-footer{flex-direction:column;gap:.6rem}}
@media(prefers-reduced-motion:reduce){.photo-marquee-track{animation:none!important}.photo-marquee-item[aria-hidden="true"]{display:none}.photo-marquee-viewport{overflow:auto;mask-image:none}}
