.phone-overlay{position:absolute;inset:0;z-index:8;display:grid;place-items:center;touch-action:auto;isolation:isolate;color:#f5f5f8;font-family:system-ui,sans-serif}
.phone-backdrop{position:absolute;inset:0;z-index:-1;background:rgba(4,10,16,.67);backdrop-filter:blur(5px)}
.phone-device{position:relative;height:min(92%,640px);aspect-ratio: .51;max-width:86%;filter:drop-shadow(0 24px 32px rgba(0,0,0,.45));touch-action:manipulation}
.phone-hardware{height:100%;padding:6px;background:linear-gradient(130deg,#78808c,#222731 22%,#10141b 78%,#69707b);border:1px solid #abb1ba;border-radius:32px;position:relative}
.phone-screen{--phone-brightness:1;position:relative;height:100%;overflow:hidden;border-radius:26px;background:#192433;color:white;display:flex;flex-direction:column}
.phone-screen:before{content:"";position:absolute;inset:0;background:linear-gradient(145deg,#243753 6%,#8b5e6b 60%,#dda88e);z-index:0;pointer-events:none}
.phone-screen[data-wallpaper=ocean]:before{background:linear-gradient(145deg,#0d3e54,#3c9aaa 65%,#a1d8cc)}
.phone-screen[data-wallpaper=forest]:before{background:linear-gradient(145deg,#182b29,#4d7361 65%,#b1ba98)}
.phone-screen:after{content:"";position:absolute;inset:0;background:#000;opacity:calc(1 - var(--phone-brightness));pointer-events:none;z-index:5}
.phone-island{position:absolute;z-index:6;left:50%;top:13px;transform:translateX(-50%);width:29%;height:14px;border-radius:20px;background:#080b11;pointer-events:none}
.phone-status,.phone-content,.phone-nav{position:relative;z-index:1}.phone-status{height:32px;padding:9px 18px 0;display:flex;align-items:flex-start;justify-content:space-between;font-size:10px;font-weight:650;flex:none}
.phone-content{flex:1;min-height:0;overflow:auto;overscroll-behavior:contain;touch-action:pan-y}.phone-nav{height:32px;display:flex;justify-content:space-around;align-items:center;flex:none}.phone-nav button{border:0;background:transparent;color:#fff;font-size:25px;padding:0 18px;line-height:1;cursor:pointer}.phone-nav button span{display:block;width:48px;height:4px;border-radius:4px;background:white}
.phone-overlay button,.phone-overlay input,.phone-overlay select,.phone-overlay textarea{font-family:inherit}.phone-overlay button{cursor:pointer}.phone-overlay button:focus-visible,.phone-overlay input:focus-visible,.phone-overlay textarea:focus-visible,.phone-overlay select:focus-visible{outline:2px solid #fff;outline-offset:2px}
.phone-close{position:absolute;top:0;left:calc(100% + 12px);width:38px;height:38px;border:1px solid #ffffff77;border-radius:50%;color:white;background:#202a34;font-size:27px!important;line-height:1}
.phone-lock,.phone-off{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:space-between;padding:18% 14px 15%;text-align:center}.phone-lock div{display:flex;flex-direction:column;gap:5px}.phone-lock-date{font-size:12px;text-transform:capitalize}.phone-lock-time{font-size:clamp(37px,8vh,64px);letter-spacing:-.05em;font-weight:400}.phone-lock p{font-size:11px;opacity:.8;margin:auto 0 15px}.phone-lock button,.phone-off button{border:1px solid #ffffff55;border-radius:18px;background:#ffffff25;color:#fff;padding:10px 20px;font-size:11px}.phone-lock button span{margin-left:10px}
.phone-screen[data-page=off]:before{background:#05070a}.phone-off{justify-content:center;gap:20px;color:#aaa;font-size:13px}
.phone-home{min-height:100%;display:flex;flex-direction:column;padding:18px 15px 12px}.phone-greeting{display:flex;flex-direction:column;gap:5px;margin:6px 0 22px}.phone-greeting span{font-size:9px;letter-spacing:.16em;opacity:.75}.phone-greeting strong{font-size:25px;letter-spacing:-.04em}.phone-greeting small{font-size:10px;opacity:.8;line-height:1.4}.phone-app-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:16px 6px}.phone-app-grid button{border:0;background:none;color:white;padding:0;display:flex;flex-direction:column;align-items:center;gap:5px}.phone-app-grid small{font-size:9px}.phone-app-icon{display:grid;place-items:center;width:min(45px,100%);aspect-ratio:1;border-radius:13px;font-size:22px;font-weight:500;box-shadow:0 4px 12px #0003}.icon-camera{background:#303943}.icon-gallery{background:#a76b82}.icon-notes{background:#dfae62}.icon-messages{background:#69a07b}.icon-calls{background:#5b9a85}.icon-clock{background:#313f61}.icon-settings{background:#78828a}.phone-quick{margin-top:auto;padding-top:18px}.phone-quick button{width:100%;border:1px solid #ffffff40;background:#111c2a77;color:white;border-radius:14px;padding:11px;font-size:12px;text-align:left}.phone-quick span{margin-left:6px}
.phone-screen:not([data-page=home]):not([data-page=lock]):not([data-page=off]):before{background:#f4f5f7}.phone-screen:not([data-page=home]):not([data-page=lock]):not([data-page=off]){color:#202b39}.phone-screen:not([data-page=home]):not([data-page=lock]):not([data-page=off]) .phone-nav button{color:#202b39}.phone-screen:not([data-page=home]):not([data-page=lock]):not([data-page=off]) .phone-nav button span{background:#202b39}
.phone-app-head{display:flex;gap:8px;align-items:center;padding:10px 12px 8px}.phone-app-head button{border:0;background:transparent;color:#334959;font-size:30px;line-height:1;padding:0 5px}.phone-app-head div{display:flex;flex-direction:column;gap:2px}.phone-app-head strong{font-size:16px}.phone-app-head small{font-size:9px;color:#74808c}.phone-notice{font-size:10px;color:#9a4b2d;margin:0 15px}.phone-notice:empty{display:none}
.phone-camera{position:relative;min-height:calc(100% - 54px);background:#101820;display:flex;flex-direction:column;align-items:center;justify-content:center;overflow:hidden}.phone-preview{width:100%;height:100%;position:absolute;inset:0;object-fit:cover}.phone-camera-label{position:absolute;top:12px;color:#fff;font-size:9px;letter-spacing:.1em}.phone-shutter{position:relative;margin-top:auto;margin-bottom:8px;width:52px;height:52px;border:3px solid white;border-radius:50%;background:#ffffff33;display:grid;place-items:center}.phone-shutter span{width:38px;height:38px;border-radius:50%;background:white}.phone-camera small{position:relative;color:white;font-size:9px;margin-bottom:10px}
.phone-gallery,.phone-photo-detail{padding:12px}.phone-empty{color:#74808c;text-align:center;font-size:12px;margin:28px 10px;line-height:1.5}.phone-photo-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:3px}.phone-photo-grid button{border:0;padding:0;aspect-ratio:1;background:#c4c9cd}.phone-photo-grid img{width:100%;height:100%;object-fit:cover}.phone-photo-detail{display:flex;flex-direction:column;gap:14px}.phone-photo-detail img{width:100%;border-radius:8px}.phone-photo-detail button,.phone-settings button{border:0;border-radius:9px;background:#e4e8eb;color:#34434d;padding:10px}
.phone-notes{display:block;width:calc(100% - 24px);height:calc(100% - 65px);margin:0 12px;border:0;resize:none;background:transparent;color:#25323a;font-size:13px;line-height:1.6;outline:none}
.phone-messages{padding:12px;min-height:45%;max-height:58%;overflow:auto}.phone-bubble{width:fit-content;max-width:85%;padding:9px 11px;border-radius:13px;background:#e0e6ea;font-size:11px;line-height:1.4;overflow-wrap:anywhere}.phone-bubble.out{margin-left:auto;background:#587e72;color:white}.phone-message-form{display:flex;gap:6px;margin:10px}.phone-message-form input{min-width:0;flex:1;border:1px solid #d8dee3;border-radius:12px;padding:9px;font-size:11px}.phone-message-form button,.phone-timer button{border:0;border-radius:10px;background:#314e62;color:white;padding:8px 11px;font-size:11px}
.phone-calls,.phone-clock{display:flex;flex-direction:column;align-items:center;text-align:center;padding:16px 15px;gap:10px}.phone-avatar{width:58px;height:58px;display:grid;place-items:center;border-radius:50%;background:#d8e5e0;color:#52786a;font-size:24px}.phone-calls p,.phone-clock p{font-size:11px;color:#75838d;line-height:1.4}.phone-calls button{border:0;border-radius:20px;color:white;background:#4e9c72;padding:10px 18px}.phone-calls button.is-ending{background:#bf5c5c}.phone-big-time{font-size:40px;font-weight:400;letter-spacing:-.05em}.phone-timer{width:100%;text-align:left;border-radius:14px;background:#e8ecef;padding:12px;font-size:11px}.phone-timer label{display:flex;justify-content:space-between;align-items:center}.phone-timer input{width:55px;border:1px solid #c4cbd1;border-radius:6px;padding:5px}.phone-timer div{display:flex;gap:6px}
.phone-settings{display:flex;flex-direction:column;gap:12px;padding:8px 14px 15px;font-size:11px}.phone-settings label{display:flex;flex-wrap:wrap;justify-content:space-between;gap:8px}.phone-settings input[type=range]{width:100%;accent-color:#4f7684}.phone-settings select{width:100%;padding:8px;border:1px solid #d3d9dd;border-radius:8px;background:white;color:#24323b}.phone-toggle{align-items:center}.phone-toggle span{display:flex;flex-direction:column;gap:3px}.phone-toggle small,.phone-footnote{color:#7b8892;font-size:9px;line-height:1.4}.phone-settings p{margin:0}
@media(max-height:450px){.phone-device{height:94%}.phone-app-grid{gap:7px 4px}.phone-app-icon{width:32px;border-radius:9px;font-size:17px}.phone-greeting{margin:0 0 8px}.phone-greeting strong{font-size:18px}.phone-greeting small{display:none}.phone-home{padding-top:8px}.phone-quick{padding-top:8px}.phone-quick button{padding:6px}.phone-status{height:25px;padding-top:7px}.phone-nav{height:24px}.phone-island{height:10px;top:10px}}

.phone-overlay[hidden]{display:none}.phone-side-power{position:absolute;right:-8px;top:25%;height:42px;width:5px;padding:0;border:0;border-radius:0 4px 4px 0;background:#929aa6;z-index:7}.phone-side-power:focus-visible{outline:2px solid white}

.phone-quick{display:grid;gap:5px}.phone-notifications{padding:12px;font-size:11px;color:#53616c}.phone-notification-list p{background:#e6ebee;border-radius:10px;padding:10px;overflow-wrap:anywhere}.phone-notifications button{border:0;border-radius:9px;background:#dfe5e8;color:#34434d;padding:8px 12px;margin-top:10px}

.phone-nav[hidden]{display:none}
/* The interactive glass is composited over the camera-relative held hand;
   the rest of the real 3D scene stays visible instead of a modal backdrop. */
.phone-backdrop{background:transparent;backdrop-filter:none}
.phone-device{height:min(82%,530px);aspect-ratio:.495;max-width:80%;transform:translateX(12%);filter:drop-shadow(0 8px 8px rgba(0,0,0,.28))}
.phone-status{font-size:9px;gap:12px}.phone-status>span:last-child{font-size:8px;text-align:right}.phone-island{width:25%;height:10px;top:13px}
.sim-stage.is-phone-using .sim-reticle,.sim-stage.is-phone-using .sim-item-actions,.sim-stage.is-phone-using .sim-stage-top,.sim-stage.is-phone-using .sim-move-action,.sim-stage.is-phone-using .sim-jump{visibility:hidden}
@media(max-height:450px){.phone-device{height:min(82%,530px)}.phone-close{width:32px;height:32px;font-size:23px!important;left:calc(100% + 7px)}}
.phone-overlay{grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr);min-width:0;min-height:0}
.phone-device{min-width:0;min-height:0}

.phone-screen{container-name:phoneDisplay;container-type:size}
@container phoneDisplay (max-height:400px){
  .phone-status{height:24px;padding:6px 12px 0;font-size:9px}
  .phone-nav{height:23px}.phone-nav button{font-size:19px}.phone-nav button span{width:36px}
  .phone-home{padding:8px 8px 6px}.phone-greeting{gap:3px;margin:0 0 8px}
  .phone-greeting span{font-size:8px}.phone-greeting strong{font-size:17px}.phone-greeting small{display:none}
  .phone-app-grid{gap:7px 2px}.phone-app-grid button{min-width:0;gap:3px}.phone-app-grid small{font-size:7px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .phone-app-icon{width:min(30px,100%);border-radius:9px;font-size:16px}
  .phone-quick{padding-top:6px;gap:4px}.phone-quick button{font-size:9px;padding:6px}
  .phone-app-head{padding:6px 8px 4px}.phone-app-head strong{font-size:13px}.phone-app-head small{font-size:8px}
  .phone-lock-time{font-size:35px}.phone-lock-date{font-size:10px}.phone-lock p{font-size:9px}
}
/* The only interactive overlay is the glass, aligned to the projected mesh.
   The casing and hand remain WebGL geometry throughout the raise/lower. */
.phone-overlay.is-dormant{inset:auto;left:-3000px;top:0;width:240px;height:480px;opacity:0;pointer-events:none}
.phone-overlay .phone-device{position:absolute;transform:none;aspect-ratio:auto;max-width:none;filter:none;visibility:hidden}
.phone-overlay.is-ready .phone-device{visibility:visible}
.phone-overlay.is-dormant .phone-device{left:0!important;top:0!important;width:240px!important;height:480px!important;visibility:visible}
.phone-hardware{width:100%;height:100%;padding:0;border:0;border-radius:0;background:transparent}
.phone-screen{width:100%;height:100%;border-radius:0}
.phone-island{top:2%;height:3%;width:25%}
.phone-side-power{right:-23px;top:25%;height:max(44px,16%);width:24px;background:transparent;outline-offset:1px}
.phone-close{top:-4px;left:calc(100% + 15px);width:34px;height:34px;font-size:22px!important}
.phone-screen[data-page=off] .phone-status,.phone-screen[data-page=off] .phone-island{visibility:hidden}
.phone-screen[data-page=off] .phone-off>span,.phone-screen[data-page=off] [data-phone=power]{visibility:hidden}

/* Invisible hit targets: all visible pixels belong to the 3D phone texture. */
.phone-overlay.is-ready .phone-hardware{opacity:0}

/* Movement stays available alongside the real phone glass. */
.phone-overlay{pointer-events:none}
.phone-overlay.is-ready .phone-device{pointer-events:auto}
.sim-stage.is-phone-using .sim-joystick{z-index:9}

/* Phone system: restrained, high-contrast glass with compact, consistent
   controls. These are the actual screen's hit targets and texture source. */
.phone-screen{font-family:system-ui,-apple-system,sans-serif;letter-spacing:0}
.phone-screen:before{background:radial-gradient(ellipse at 84% 18%,#4c6673 0%,transparent 48%),radial-gradient(ellipse at 8% 100%,#58616d 0%,transparent 48%),linear-gradient(155deg,#131f2e 0%,#243746 58%,#26303b 100%)}
.phone-screen[data-wallpaper=ocean]:before{background:radial-gradient(ellipse at 85% 15%,#50898c 0%,transparent 50%),linear-gradient(150deg,#122933,#1d525c 58%,#17373f)}
.phone-screen[data-wallpaper=forest]:before{background:radial-gradient(ellipse at 80% 12%,#657f6c 0%,transparent 50%),linear-gradient(150deg,#172b28,#314f41 60%,#202d2a)}
.phone-status{height:29px;padding:8px 12px 0;box-sizing:border-box;align-items:flex-start;font-size:9px;font-weight:650;letter-spacing:.02em}
.phone-status-right{display:flex;align-items:center;gap:4px;font-size:8px}.phone-status-right svg{width:11px;height:11px}
.phone-battery-icon{width:13px;height:7px;border:1px solid currentColor;border-radius:2px;display:block;position:relative;padding:1px;box-sizing:border-box}
.phone-battery-icon:after{content:"";position:absolute;right:-3px;top:2px;width:1px;height:2px;background:currentColor}
.phone-battery-icon i{display:block;width:100%;height:100%;background:currentColor;border-radius:1px}
.phone-nav{height:27px}.phone-nav button{display:grid;place-items:center;min-width:36px;min-height:24px;padding:0 8px;font-size:inherit}.phone-nav button svg{width:13px;height:13px}.phone-nav button span{width:34px;height:3px}
.phone-lock{box-sizing:border-box;padding:14px 14px 16px}.phone-lock-heading{align-items:center;gap:3px}.phone-lock-mark{display:grid;place-items:center;opacity:.75;margin:2px 0 6px}.phone-lock-mark svg{width:14px;height:14px}
.phone-lock-time{font-size:clamp(35px,24cqw,58px);font-weight:300;letter-spacing:-.06em;line-height:1.05}.phone-lock-date{font-size:10px;font-weight:500;opacity:.82}
.phone-lock-footer{display:flex;flex-direction:column;align-items:center;gap:7px;width:100%}.phone-lock-footer p{margin:0;font-size:9px;opacity:.65}.phone-lock-footer button{width:100%;max-width:180px;padding:9px 12px;border:1px solid #ffffff38;border-radius:12px;background:#ffffff1c;font-weight:600;font-size:10px}.phone-lock-footer button span{margin-left:10px}.phone-lock-footer small{font-size:8px;opacity:.65}
.phone-home{box-sizing:border-box;min-height:100%;padding:10px 12px 8px}.phone-greeting{display:flex;flex-direction:column;gap:3px;margin:2px 0 14px}.phone-home-label,.phone-section-label{font-size:8px;font-weight:700;letter-spacing:.12em;color:#d6e0e2;opacity:.75}.phone-home-time{font-size:32px;line-height:1.05;font-weight:350;letter-spacing:-.06em}.phone-home-date{display:block;font-size:10px;text-transform:capitalize;opacity:.76}
.phone-section-label{display:flex;justify-content:space-between;margin-bottom:10px}.phone-section-label span{font-weight:500;letter-spacing:.04em;opacity:.7}
.phone-app-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:12px 3px}.phone-app-grid button{gap:5px;min-width:0}.phone-app-grid small{font-size:9px;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;opacity:.91}
.phone-app-icon{width:min(40px,95%);border:1px solid #ffffff30;border-radius:12px;box-sizing:border-box;box-shadow:none}.phone-app-icon svg{width:53%;height:53%}
.icon-camera{background:#41505b}.icon-gallery{background:#756c79}.icon-notes{background:#867c67}.icon-messages{background:#567968}.icon-calls{background:#526f77}.icon-clock{background:#474e68}.icon-settings{background:#626b72}
.phone-quick{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px;padding-top:14px}.phone-quick button{display:flex;align-items:center;gap:6px;min-width:0;padding:8px;border:1px solid #ffffff2b;border-radius:11px;background:#101b29a6;color:#fff;text-align:left}.phone-quick button svg{width:16px;height:16px;flex:none}.phone-quick button span{display:flex;flex-direction:column;min-width:0;gap:2px;margin:0}.phone-quick button strong{font-size:9px;font-weight:650}.phone-quick button small{font-size:8px;opacity:.7;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.phone-quick button[aria-pressed=true]{background:#496c70;border-color:#a9d5d0}
.phone-app-head button{display:grid;place-items:center;min-width:27px;min-height:27px;padding:3px}.phone-app-head button svg{width:17px;height:17px}
@container phoneDisplay (max-height:400px){
  .phone-status{height:23px;padding:6px 9px 0;font-size:8px}.phone-status-right{font-size:7px;gap:3px}.phone-status-right svg{width:9px;height:9px}.phone-battery-icon{width:11px;height:6px}
  .phone-nav{height:22px}.phone-nav button{min-height:20px}.phone-nav button svg{width:11px;height:11px}.phone-nav button span{width:29px}
  .phone-home{padding:6px 8px 5px}.phone-greeting{gap:2px;margin:0 0 8px}.phone-home-label,.phone-section-label{font-size:7px}.phone-home-time{font-size:24px}.phone-home-date{display:block;font-size:8px}.phone-section-label{margin-bottom:6px}
  .phone-app-grid{gap:7px 2px}.phone-app-grid small{font-size:7px}.phone-app-icon{width:min(29px,95%);border-radius:9px}
  .phone-quick{padding-top:7px;gap:4px}.phone-quick button{gap:4px;padding:5px;border-radius:8px}.phone-quick button svg{width:12px;height:12px}.phone-quick button strong{font-size:7px}.phone-quick button small{font-size:7px}
  .phone-lock{padding:8px 9px 10px}.phone-lock-time{font-size:35px}.phone-lock-date{font-size:9px}.phone-lock-mark{margin:0 0 3px}.phone-lock-mark svg{width:11px;height:11px}.phone-lock-footer{gap:4px}.phone-lock-footer p,.phone-lock-footer small{font-size:7px}.phone-lock-footer button{padding:6px;font-size:8px}
}

/* App surfaces share one quiet visual language while retaining the screen's
   real interactive DOM, scrolling and accessibility labels. */
.phone-screen:not([data-page=home]):not([data-page=lock]):not([data-page=off]):before{background:#f1f4f3}
.phone-screen:not([data-page=home]):not([data-page=lock]):not([data-page=off]){color:#1c2b30}
.phone-app-head{box-sizing:border-box;min-height:43px;padding:8px 12px 7px;gap:8px}.phone-app-head button{border:1px solid #dce3e1;border-radius:9px;background:#fff;color:#273d42}
.phone-app-head div{min-width:0;gap:2px}.phone-app-head strong{font-size:15px;font-weight:700;letter-spacing:-.025em}.phone-app-head small{font-size:9px;color:#778784;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.phone-notice{font-size:9px;color:#427168;margin:2px 13px 5px;line-height:1.3}.phone-notice:empty{display:none}
.phone-screen[data-page=camera]:before{background:#111b20!important}.phone-screen[data-page=camera]{color:#f6faf8!important}.phone-screen[data-page=camera] .phone-nav button{color:#f6faf8!important}.phone-screen[data-page=camera] .phone-nav button span{background:#f6faf8!important}
.phone-screen[data-page=camera] .phone-app-head button{background:#253238;color:#f6faf8;border-color:#405057}.phone-screen[data-page=camera] .phone-app-head small{color:#aebbb7}.phone-screen[data-page=camera] .phone-notice{color:#a9d6cb}
.phone-camera{height:calc(100% - 43px);min-height:0;display:flex;gap:0;padding:0 10px 6px;box-sizing:border-box;background:transparent}
.phone-viewfinder{position:relative;width:100%;flex:1;min-height:32px;overflow:hidden;border-radius:10px;background:#26383c}
.phone-preview{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}.phone-camera-label{position:absolute;top:9px;left:9px;color:#fff;font-size:8px;font-weight:650;letter-spacing:.1em;text-shadow:0 1px 4px #000}
.phone-camera-frame{position:absolute;inset:9px;border:1px solid #ffffff4d;border-radius:6px;pointer-events:none}.phone-camera-mode{flex:none;padding:7px 0 3px;font-size:8px;font-weight:700;letter-spacing:.18em;color:#d6e8df}
.phone-camera-controls{width:100%;display:grid;grid-template-columns:1fr auto 1fr;align-items:center;justify-items:center;flex:none}.phone-camera-gallery{border:1px solid #667672;border-radius:9px;width:30px;height:30px;display:grid;place-items:center;background:#2e3e41;color:#fff}.phone-camera-gallery svg{width:16px;height:16px}
.phone-shutter{position:static;margin:0;width:46px;height:46px;border:2px solid #f5faf7;border-radius:50%;background:transparent;display:grid;place-items:center}.phone-shutter span{width:34px;height:34px;border-radius:50%;background:#f5faf7}.phone-camera-caption{position:static;margin:5px 0 0;color:#acbbb7;font-size:8px}
.phone-gallery,.phone-photo-detail{padding:10px 12px 14px}.phone-library-heading{display:flex;justify-content:space-between;align-items:center;margin:2px 0 10px}.phone-library-heading strong{font-size:12px}.phone-library-heading span{font-size:9px;color:#778784}
.phone-empty{min-height:140px;margin:0;padding:15px;box-sizing:border-box;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;background:#fff;border:1px solid #e2e9e6;border-radius:13px;color:#667875;text-align:center;line-height:1.4}.phone-empty[hidden]{display:none}.phone-empty strong{font-size:11px;color:#273b39}.phone-empty small{font-size:9px}.phone-empty button{border:0;border-radius:8px;background:#dfece8;color:#345d54;font-size:9px;font-weight:700;padding:8px 10px}.phone-empty-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:11px;background:#e7f0ed;color:#4f766b}.phone-empty-icon svg{width:18px;height:18px}
.phone-photo-grid{grid-template-columns:repeat(3,minmax(0,1fr));gap:4px}.phone-photo-grid button{border-radius:6px;overflow:hidden;background:#dce5e1}.phone-photo-detail{gap:10px}.phone-photo-detail img{background:#dce5e1;border-radius:10px}.phone-photo-meta{display:flex;flex-direction:column;gap:3px}.phone-photo-meta strong{font-size:11px}.phone-photo-meta span{font-size:9px;color:#778784}.phone-photo-detail button{display:flex;justify-content:center;align-items:center;gap:6px;background:#f4e7e5;color:#a14e4a;font-size:10px;font-weight:650}.phone-photo-detail button svg{width:14px;height:14px}
.phone-note-page{min-height:calc(100% - 43px);box-sizing:border-box;display:flex;flex-direction:column;margin:0 12px 10px;border:1px solid #e0e7e3;border-radius:12px;background:#fff}.phone-note-meta{display:flex;justify-content:space-between;gap:5px;padding:11px 12px 0;font-size:8px;font-weight:700;letter-spacing:.07em;color:#83938d}.phone-note-count{letter-spacing:0;font-weight:500;white-space:nowrap}
.phone-notes{box-sizing:border-box;display:block;flex:1;width:100%;min-height:100px;height:auto;margin:0;padding:12px;border:0;background:transparent;color:#243832;font-size:12px;line-height:1.6;resize:none}.phone-note-footer{padding:0 12px 10px;font-size:8px;color:#8a9994}
.phone-conversation{height:calc(100% - 43px);min-height:160px;display:flex;flex-direction:column;box-sizing:border-box}.phone-conversation-heading{display:flex;align-items:center;gap:8px;margin:0 12px;padding:9px 0;border-bottom:1px solid #dce5e0}.phone-conversation-avatar{display:grid;place-items:center;width:30px;height:30px;border-radius:10px;background:#d8e8e1;color:#486b5d;font-size:12px;font-weight:700}.phone-conversation-heading>span:last-child{display:flex;flex-direction:column;gap:2px}.phone-conversation-heading strong{font-size:10px}.phone-conversation-heading small{font-size:8px;color:#82928b}
.phone-messages{flex:1;min-height:35px;max-height:none;padding:12px;overflow:auto}.phone-bubble{margin:0 0 8px;max-width:83%;padding:9px 10px;border-radius:12px 12px 12px 3px;background:#fff;color:#344943;font-size:10px;line-height:1.4}.phone-bubble.out{border-radius:12px 12px 3px 12px;background:#426b60;color:#fff}
.phone-message-form{flex:none;align-items:center;gap:6px;margin:0 12px 10px}.phone-message-form input{height:33px;box-sizing:border-box;border:1px solid #dce6e1;border-radius:10px;background:#fff;padding:8px;font-size:10px;color:#263d36}.phone-message-form button{width:33px;height:33px;display:grid;place-items:center;padding:0;background:#426b60}.phone-message-form button svg{width:16px;height:16px}
.phone-calls,.phone-clock{box-sizing:border-box;padding:12px;gap:8px}.phone-call-label,.phone-clock-label{font-size:8px;font-weight:700;letter-spacing:.12em;color:#82938b}.phone-avatar{width:58px;height:58px;border-radius:20px;background:#dceae4;color:#496e5e;font-size:22px;font-weight:650}.phone-calls strong{font-size:13px}.phone-calls p,.phone-clock p{margin:0;color:#788b83;font-size:9px;line-height:1.45}.phone-calls button{display:flex;align-items:center;justify-content:center;gap:7px;border-radius:10px;background:#416e5d;padding:10px 14px;font-size:10px;font-weight:650}.phone-calls button svg{width:15px;height:15px}.phone-calls button.is-ending{background:#aa5b58}
.phone-big-time{font-size:42px;font-weight:350;line-height:1;letter-spacing:-.055em;color:#253a34}.phone-timer{box-sizing:border-box;margin-top:10px;padding:12px;border:1px solid #dee7e2;border-radius:12px;background:#fff;text-align:left}.phone-timer-heading{display:flex;justify-content:space-between;align-items:center}.phone-timer-heading strong{font-size:12px;color:#263d35}.phone-timer-heading span{font-size:8px;color:#86968e}.phone-timer .phone-timer-status{margin:6px 0 10px;font-size:10px;color:#587368}.phone-timer label{font-size:9px;color:#536b60}.phone-timer input{background:#f5f8f6;color:#263d35;border-color:#d9e4de}.phone-timer div:last-child{margin-top:10px}.phone-timer button{flex:1;background:#426b60;font-size:9px;font-weight:650}.phone-timer button:last-child{background:#e9efec;color:#486157}
.phone-settings{gap:7px;padding:7px 12px 14px}.phone-settings-section{padding:5px 1px 1px;font-size:8px;font-weight:700;letter-spacing:.1em;color:#84958d}.phone-settings label,.phone-battery-row{box-sizing:border-box;margin:0;padding:10px;border:1px solid #e1e9e4;border-radius:10px;background:#fff;font-size:10px;font-weight:600}.phone-settings label output,.phone-battery-row strong{color:#668578;font-size:9px}.phone-settings input[type=range]{accent-color:#537e70;margin:5px 0 0}.phone-settings select{border-color:#e0e8e3;background:#f6f8f7;color:#263b33;font-size:10px}.phone-toggle small,.phone-footnote{font-size:8px;font-weight:400;color:#899990}.phone-battery-row{display:flex;justify-content:space-between}.phone-settings button{background:#dfece6;color:#416a5b;font-size:10px;font-weight:650}.phone-settings .phone-footnote{padding:3px 1px;line-height:1.45}
.phone-notifications{padding:8px 12px 14px}.phone-notification-heading{display:flex;justify-content:space-between;align-items:center;margin-bottom:9px}.phone-notification-heading strong{font-size:8px;letter-spacing:.1em;color:#81938a}.phone-notifications button{margin:0;background:transparent;color:#517b6e;font-size:9px;font-weight:650;padding:5px}.phone-notification-list p:not(.phone-empty){margin:0 0 6px;padding:11px;background:#fff;border:1px solid #e0e9e3;border-radius:10px;color:#40564e;font-size:10px}.phone-notification-list .phone-empty{min-height:110px}
@container phoneDisplay (max-height:400px){
  .phone-app-head{min-height:34px;padding:5px 8px;gap:6px}.phone-app-head button{min-width:23px;min-height:23px;border-radius:7px}.phone-app-head button svg{width:13px;height:13px}.phone-app-head strong{font-size:12px}.phone-app-head small{font-size:7px}.phone-notice{font-size:8px;margin:1px 9px 3px}
  .phone-camera{height:calc(100% - 34px);padding:0 8px 4px}.phone-camera-label{top:6px;left:6px;font-size:7px}.phone-camera-frame{inset:6px}.phone-camera-mode{padding:4px 0 2px;font-size:7px}.phone-camera-gallery{width:25px;height:25px}.phone-camera-gallery svg{width:13px;height:13px}.phone-shutter{width:36px;height:36px}.phone-shutter span{width:26px;height:26px}.phone-camera-caption{font-size:7px;margin-top:3px}
  .phone-gallery,.phone-photo-detail{padding:7px 8px 10px}.phone-library-heading strong{font-size:10px}.phone-library-heading span{font-size:8px}.phone-empty{min-height:95px;gap:5px;padding:8px}.phone-empty strong{font-size:9px}.phone-empty small,.phone-empty button{font-size:8px}.phone-empty-icon{width:27px;height:27px}.phone-empty-icon svg{width:14px;height:14px}
  .phone-note-page{min-height:calc(100% - 34px);margin:0 8px 8px}.phone-note-meta{padding:8px 8px 0;font-size:7px}.phone-notes{min-height:65px;padding:8px;font-size:10px}.phone-note-footer{padding:0 8px 7px;font-size:7px}
  .phone-conversation{height:calc(100% - 34px);min-height:120px}.phone-conversation-heading{margin:0 8px;padding:5px 0}.phone-conversation-avatar{width:24px;height:24px}.phone-conversation-heading strong{font-size:9px}.phone-conversation-heading small{font-size:7px}.phone-messages{padding:8px}.phone-bubble{font-size:9px;padding:7px 8px}.phone-message-form{margin:0 8px 6px}.phone-message-form input,.phone-message-form button{height:27px}.phone-message-form button{width:27px}
  .phone-calls,.phone-clock{padding:8px;gap:5px}.phone-avatar{width:42px;height:42px;border-radius:14px}.phone-big-time{font-size:32px}.phone-timer{margin-top:6px;padding:8px}.phone-timer .phone-timer-status{margin:4px 0 6px}.phone-timer div:last-child{margin-top:6px}.phone-settings{padding:5px 8px 10px;gap:5px}.phone-settings label,.phone-battery-row{padding:7px;font-size:9px}.phone-notifications{padding:6px 8px 10px}
}
/* Keep app toolbars and content within the projected physical screen. */
.phone-app-head{height:43px}.phone-app-head button{box-sizing:border-box;width:27px;height:27px;flex:none}.phone-app-head div{line-height:1.15}
.phone-note-page{height:calc(100% - 53px);min-height:0}.phone-notes{min-height:0}
.phone-wallpaper-setting{box-sizing:border-box;padding:10px;border:1px solid #e1e9e4;border-radius:10px;background:#fff;font-size:10px;font-weight:600}
.phone-wallpaper-options{display:flex;gap:5px;margin-top:7px}.phone-settings .phone-wallpaper-options button{flex:1;min-width:0;padding:7px 3px;background:#eef3f0;color:#62766e;border:1px solid transparent;border-radius:7px;font-size:9px}
.phone-settings .phone-wallpaper-options button[aria-pressed=true]{background:#dcebe3;color:#305c4e;border-color:#a9c7b8}
.phone-settings input[type=checkbox]{accent-color:#537e70}
@container phoneDisplay (max-height:400px){
  .phone-app-head{height:34px}.phone-app-head button{width:23px;height:23px}.phone-note-page{height:calc(100% - 42px);min-height:0}.phone-notes{min-height:0}
  .phone-wallpaper-setting{padding:7px;font-size:9px}.phone-wallpaper-options{gap:3px;margin-top:5px}.phone-settings .phone-wallpaper-options button{padding:5px 2px;font-size:8px}
}
@container phoneDisplay (max-width:155px){
  .phone-status{font-size:7px;padding-left:6px;padding-right:6px}.phone-status-right{font-size:6px;gap:2px}.phone-status-right svg{width:8px;height:8px}.phone-battery-icon{width:9px}.phone-island{width:20%}
  .phone-greeting .phone-home-date{display:block;font-size:7px}.phone-app-grid small{font-size:6px}.phone-section-label{font-size:6px}
  .phone-quick button strong,.phone-quick button small{font-size:5.5px}.phone-quick button svg{width:10px;height:10px}
  .phone-app-head strong{font-size:10px}.phone-app-head small{font-size:6px}.phone-app-head button{width:21px;height:21px;min-width:21px;min-height:21px}
  .phone-camera-caption{font-size:6px;white-space:nowrap}.phone-camera-label{font-size:6px;letter-spacing:.05em}
  .phone-calls,.phone-clock{padding:5px;gap:4px}.phone-calls strong{font-size:9px}.phone-calls p,.phone-clock p{font-size:7px}.phone-call-label,.phone-clock-label{font-size:6px}.phone-avatar{width:32px;height:32px;border-radius:10px;font-size:14px}.phone-calls button{min-height:25px;padding:5px 9px;font-size:8px}.phone-calls button svg{width:11px;height:11px}
  .phone-big-time{font-size:27px}.phone-timer{margin-top:3px;padding:6px}.phone-timer-heading strong{font-size:9px}.phone-timer-heading span{font-size:6px;white-space:nowrap}.phone-timer .phone-timer-status{font-size:8px;margin:3px 0 5px}.phone-timer label{font-size:7px}.phone-timer input{box-sizing:border-box;width:36px;height:22px;min-height:0;padding:3px;font-size:8px}.phone-timer div:last-child{margin-top:5px}.phone-timer button{min-height:23px;padding:4px;font-size:7px}
  .phone-conversation-heading strong{font-size:7px;white-space:nowrap}.phone-conversation-heading small{font-size:6px}.phone-conversation-avatar{width:20px;height:20px;font-size:9px}.phone-messages{padding:6px}.phone-bubble{font-size:7px}.phone-message-form input{min-height:0;font-size:8px}.phone-message-form button{min-height:0}
}
.phone-notice:not(:empty)+.phone-camera{height:calc(100% - 60px)}
@container phoneDisplay (max-height:400px){.phone-notice:not(:empty)+.phone-camera{height:calc(100% - 47px)}}

/* Home: a calmer, more legible dashboard on the physical display. */
.phone-screen:before{background:radial-gradient(ellipse at 90% 0%,#465b6b 0%,transparent 48%),linear-gradient(160deg,#111e2b,#223544 57%,#1a2a35)}
.phone-screen[data-wallpaper=ocean]:before{background:radial-gradient(ellipse at 90% 0%,#44777c 0%,transparent 48%),linear-gradient(160deg,#102a33,#214d56 60%,#18353d)}
.phone-screen[data-wallpaper=forest]:before{background:radial-gradient(ellipse at 90% 0%,#5c7466 0%,transparent 48%),linear-gradient(160deg,#162b28,#304d41 60%,#202f2b)}
.phone-home{padding:11px 12px 9px}.phone-greeting{margin:0 0 14px;gap:4px}.phone-home-kicker{display:flex;justify-content:space-between;align-items:center;margin-bottom:5px}.phone-home-label{font-size:7px;letter-spacing:.14em;opacity:.7}.phone-home-indicator{display:flex;align-items:center;gap:4px;font-size:7px;font-weight:700;letter-spacing:.08em;color:#c4e8dc}.phone-home-indicator i{width:4px;height:4px;border-radius:50%;background:#9bd4b7}
.phone-home-time{font-size:33px;line-height:1;font-weight:350;letter-spacing:-.055em}.phone-home-date{font-size:10px;opacity:.75}.phone-section-label{align-items:baseline;margin:0 0 10px;color:#f0f5f3;letter-spacing:0;opacity:1}.phone-section-label strong{font-size:10px;font-weight:650}.phone-section-label span{font-size:8px;opacity:.6;letter-spacing:0}
.phone-app-grid{row-gap:12px}.phone-app-grid button{gap:5px}.phone-app-grid small{font-size:8px;font-weight:500;opacity:.88}.phone-app-icon{width:min(40px,95%);border-radius:13px;border-color:#ffffff29;box-shadow:inset 0 1px 0 #ffffff1a,0 3px 8px #06111830}.phone-app-icon svg{width:50%;height:50%}
.icon-camera{background:#415664}.icon-gallery{background:#776a78}.icon-notes{background:#837660}.icon-messages{background:#4d766c}.icon-calls{background:#4c6d75}.icon-clock{background:#4b5871}.icon-settings{background:#626e73}
.phone-quick{gap:6px}.phone-quick button{min-height:43px;background:#0c1a28a8;border-color:#ffffff26;border-radius:12px}.phone-quick button svg{width:15px;height:15px;color:#cde2dc}.phone-quick button strong{font-size:9px}.phone-quick button small{font-size:8px}
@container phoneDisplay (max-height:400px){.phone-home{padding:6px 8px 5px}.phone-greeting{margin:0 0 8px;gap:2px}.phone-home-kicker{margin-bottom:3px}.phone-home-label,.phone-home-indicator{font-size:6px}.phone-home-time{font-size:24px}.phone-home-date{font-size:8px}.phone-section-label{margin-bottom:6px}.phone-section-label strong{font-size:8px}.phone-section-label span{font-size:7px}.phone-app-grid{row-gap:7px}.phone-app-icon{width:min(29px,95%);border-radius:9px}.phone-app-grid small{font-size:7px}.phone-quick button{min-height:32px;border-radius:8px}.phone-quick button strong,.phone-quick button small{font-size:7px}}
@container phoneDisplay (max-width:155px){.phone-home-label,.phone-home-indicator{font-size:5px}.phone-section-label strong{font-size:7px}.phone-section-label span{font-size:6px}.phone-app-grid small{font-size:6px}.phone-quick button strong,.phone-quick button small{font-size:5.5px}}
.phone-greeting .phone-home-label{font-size:7px;white-space:nowrap}.phone-greeting .phone-home-indicator{font-size:7px;white-space:nowrap;letter-spacing:.08em;opacity:1}
@container phoneDisplay (max-height:400px){.phone-greeting .phone-home-label,.phone-greeting .phone-home-indicator{font-size:6px}}
@container phoneDisplay (max-width:155px){.phone-greeting .phone-home-label,.phone-greeting .phone-home-indicator{font-size:5px}}
@container phoneDisplay (max-width:155px){.phone-quick{gap:3px}.phone-quick button{gap:3px;padding:4px}.phone-quick button svg{width:10px;height:10px}.phone-quick button strong{white-space:nowrap;font-size:5.5px}}

/* The camera viewfinder is the entire physical screen; controls float above it. */
.phone-screen[data-page=camera] .phone-status,.phone-screen[data-page=camera] .phone-island,.phone-screen[data-page=camera] .phone-nav{display:none}
.phone-screen[data-page=camera] .phone-content{width:100%;height:100%;overflow:hidden}
.phone-camera{position:relative;width:100%;height:100%!important;padding:0!important;overflow:hidden;display:block;background:#111b20}
.phone-camera-inner{position:absolute;inset:0;overflow:hidden;background:transparent}
.phone-screen[data-orientation=landscape] .phone-camera-inner{inset:auto;left:0;top:100%;width:100cqh;height:100cqw;transform-origin:0 0;transform:rotate(-90deg)}
.phone-viewfinder{position:absolute;inset:0;width:100%;height:100%;border-radius:0;background:#111b20;overflow:hidden}
.phone-preview{width:100%;height:100%;object-fit:cover}
.phone-camera-top,.phone-camera-bottom{position:absolute;z-index:2;left:0;right:0;display:flex;align-items:center;justify-content:space-between;padding:12px;color:#fff}
.phone-camera-top{top:0;background:linear-gradient(#0009,transparent);gap:8px}.phone-camera-top>span{font-size:8px;font-weight:700;letter-spacing:.12em;text-shadow:0 1px 4px #000}
.phone-camera-top button,.phone-camera-gallery{display:grid;place-items:center;width:32px;height:32px;border:1px solid #ffffff45;border-radius:50%;background:#172327a8;color:#fff;padding:6px}.phone-camera-top button svg,.phone-camera-gallery svg{width:17px;height:17px}.phone-orientation-glyph{font-size:19px;line-height:1}.phone-camera-top button[aria-pressed=true] .phone-orientation-glyph{transform:rotate(90deg)}
.phone-camera-bottom{bottom:0;padding:14px 18px 18px;background:linear-gradient(transparent,#000b);gap:8px}.phone-camera-bottom>*{flex:none}.phone-shutter{width:52px;height:52px;border:2px solid #fff;background:#0003;box-shadow:0 1px 6px #0008}.phone-shutter span{width:38px;height:38px}.phone-camera-mode{font-size:8px;letter-spacing:.12em;color:#fff;padding:0;min-width:32px;text-align:center}
.phone-camera .phone-notice:not(:empty){position:absolute;z-index:3;top:48px;left:12px;right:12px;margin:0;padding:6px;border-radius:7px;background:#14221ee8;color:#e2fff4;font-size:9px;text-align:center}
.phone-screen[data-orientation=landscape] .phone-camera-top,.phone-screen[data-orientation=landscape] .phone-camera-bottom{top:0;bottom:0;width:46px;right:auto;flex-direction:column;justify-content:space-between;background:linear-gradient(90deg,#0009,transparent);padding:10px 6px}.phone-screen[data-orientation=landscape] .phone-camera-top{left:0}.phone-screen[data-orientation=landscape] .phone-camera-top>span{display:none}.phone-screen[data-orientation=landscape] .phone-camera-bottom{left:auto;right:0;background:linear-gradient(270deg,#000a,transparent)}.phone-screen[data-orientation=landscape] .phone-camera .phone-notice:not(:empty){top:10px;left:55px;right:55px}
@container phoneDisplay (max-width:155px){.phone-camera-top,.phone-camera-bottom{padding:7px}.phone-camera-top button,.phone-camera-gallery{width:25px;height:25px;padding:4px}.phone-camera-top>span{font-size:6px}.phone-shutter{width:38px;height:38px}.phone-shutter span{width:27px;height:27px}.phone-camera-mode{font-size:7px}.phone-screen[data-orientation=landscape] .phone-camera-top,.phone-screen[data-orientation=landscape] .phone-camera-bottom{width:32px;padding:6px 3px}}
.phone-screen[data-orientation=landscape] .phone-camera-top,.phone-screen[data-orientation=landscape] .phone-camera-bottom{box-sizing:border-box;width:68px}
@container phoneDisplay (max-width:155px){.phone-screen[data-orientation=landscape] .phone-camera-top,.phone-screen[data-orientation=landscape] .phone-camera-bottom{width:46px}}

.phone-lens-status{position:absolute;z-index:2;left:50%;top:50%;transform:translate(-50%,-50%);padding:7px 10px;border-radius:8px;background:#1b2529d9;color:#fff;font-size:9px;line-height:1.2;text-align:center;white-space:nowrap;pointer-events:none}.phone-lens-status[hidden]{display:none}

/* Compact, consistent controls on the real touch surface and its 3D texture. */
.phone-island{width:12%;max-width:28px}
.phone-status-right{min-width:0;justify-content:flex-end}
.phone-app-head>div{flex:1;min-width:0}
.phone-app-head strong,.phone-app-head small{overflow:hidden;text-overflow:ellipsis}
.phone-settings label:not(.phone-toggle){display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:4px 6px}
.phone-settings label:not(.phone-toggle) input[type=range]{grid-column:1 / -1;min-width:0;margin:3px 0 0}
.phone-settings .phone-toggle{flex-wrap:nowrap;gap:5px}.phone-toggle span{min-width:0}
.phone-screen button{touch-action:manipulation;-webkit-tap-highlight-color:transparent}
.phone-screen button:active{filter:brightness(.85)}
.phone-screen button:focus-visible,.phone-screen input:focus-visible,.phone-screen textarea:focus-visible,.phone-screen select:focus-visible{outline:2px solid #568e7b;outline-offset:1px}
.phone-screen[data-page=camera] button:focus-visible,.phone-screen[data-page=home] button:focus-visible,.phone-screen[data-page=lock] button:focus-visible{outline-color:#fff}
.phone-app-grid button{min-height:0}.phone-app-grid button:active .phone-app-icon{filter:brightness(1.2)}
.phone-photo-grid button:focus-visible{outline-offset:-2px}
.phone-message-form button,.phone-calls button,.phone-timer button,.phone-empty button{cursor:pointer}

.phone-settings input[type=range]{box-sizing:border-box;height:20px;min-height:20px;padding:0;border:0;background:transparent}
.phone-camera-top>span{white-space:nowrap;text-align:center}
@container phoneDisplay (max-width:155px){.phone-camera-top>span{font-size:5px;letter-spacing:.06em}}
.phone-gallery .phone-empty,.phone-note-page,.phone-timer,.phone-settings label,.phone-wallpaper-setting,.phone-battery-row,.phone-notification-list p:not(.phone-empty){box-shadow:0 1px 2px #152b2010}
.phone-quick button,.phone-app-head button,.phone-empty button,.phone-message-form button,.phone-calls button,.phone-timer button,.phone-settings button,.phone-photo-detail button{transition:filter .12s ease,background-color .12s ease}
@media (prefers-reduced-motion:reduce){.phone-screen button{transition:none}}
.phone-camera-top button{flex:none;box-sizing:border-box}
.phone-camera-top>span{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis}
