:root{font-family:"Microsoft YaHei","PingFang SC",sans-serif}
#gift-cover{
 box-sizing:border-box;
 width:min(88vw,390px);
 overflow:hidden;
 padding:38px 26px 35px;
 text-align:center;
 color:#ede5ce;
 background:radial-gradient(ellipse at 50% 2%,#34412b 0,#1b2b20 44%,#111e18 100%);
 border:1px solid #b5915680;
 border-radius:18px;
 box-shadow:0 26px 100px #030c08d9,inset 0 0 0 5px #e7c18b12;
}
#gift-cover::backdrop{background:#07130fc4;backdrop-filter:blur(7px)}
#gift-cover .gift-star{font-family:Georgia,serif;color:#edce8a;font-size:42px;line-height:1;text-shadow:0 0 28px #eebd6f88}
#gift-cover h2{margin:20px 0 11px;font-family:"Songti SC",SimSun,serif;font-size:clamp(26px,7.6vw,36px);font-weight:400;letter-spacing:.08em}
#gift-cover p{margin:0 0 23px;color:#dad2ba;font-size:13px;line-height:1.8}
#gift-cover #gift-status{margin:12px 0 0}
#gift-status:empty{display:none}
#gift-open{min-height:44px;padding:0 26px;background:#e2c392;border-color:#f7dfb4;color:#17241a;border-radius:999px}
#gift-open:hover:not(:disabled){background:#f1d4a5;color:#17241a}
#gift-photos{display:none}
@media(max-width:760px){
 .topbar{left:17px;right:17px;top:max(12px,env(safe-area-inset-top))}
 .topbar .brand{gap:8px;font-size:21px}
 .topbar .brand>span{font-size:15px;letter-spacing:.13em}
 .topbar .brand small,.topbar .top-actions,.intro{display:none}
 .control-panel{
  box-sizing:border-box;left:12px;right:12px;width:auto;
  top:calc(max(12px,env(safe-area-inset-top)) + 34px);bottom:auto;max-height:min(63dvh,565px);
  padding:8px;margin:0;z-index:5;border-radius:13px;
 }
 .panel-actions{display:grid;grid-template-columns:1.25fr 1fr .8fr;gap:4px}
 .panel-actions button{min-height:42px;min-width:0;padding:3px 2px;font-size:clamp(10px,3vw,13px)}
 #connection{margin:5px 3px 0;min-height:0}
 #connection:empty{display:none}
 #gesture-guide[hidden]{display:none}
 #gesture-guide:not([hidden]){display:block}
 #settings-drawer:not([hidden]){padding:1px 5px 5px}
 #camera-inset{
  top:calc(max(12px,env(safe-area-inset-top)) + 112px);right:12px;bottom:auto;
  width:min(30vw,135px);z-index:4;
 }
 #camera-inset button{min-height:28px}
 .shape-dock{left:50%;width:calc(100% - 20px);max-width:465px;bottom:calc(max(8px,env(safe-area-inset-bottom)) + 46px);gap:4px}
 .shape-dock button{flex:1 1 0;min-width:0;min-height:48px;padding:3px 1px;font-size:clamp(10px,3vw,13px);white-space:nowrap}
 .shape-dock button span{display:block;font-size:16px;line-height:1.1;margin:0}
 footer{left:13px;right:13px;bottom:max(8px,env(safe-area-inset-bottom));justify-content:center}
 footer .footer-tagline{display:none}
 footer :is(button,select){min-height:38px;padding:3px 6px;font-size:clamp(10px,3vw,13px)}
 footer #motion{margin-left:0}
 #gift-photos{display:block}
 #photo-dialog .photo-nav,#photo-dialog #close-photo{opacity:1}
 #large-photo{max-height:59dvh;max-width:81vw}
 #photo-dialog .photo-nav button{min-height:44px}
 #photo-dialog{touch-action:pan-y}
}
