/* rev4 stage 1. Separate section surfaces share one oak image; no fixed page background. */
:root{--desk-pager-ready:1}
[data-scene]:not([data-scene="top"]){--desk-height:calc(var(--core-scene-height) - var(--nav-height));--desk-light:linear-gradient(135deg,#ffffff20,#fff0 65%,#9d643a12);background:#dcbd90 repeating-linear-gradient(88deg,#0000 0 19px,#fff2 20px,#0000 22px 37px)}
[data-scene]:not([data-scene="top"]) [data-desk-surface]{inset:0;z-index:0;background-image:url('rich/desk-oak.webp');background-size:390px 680px;background-position:calc(var(--desk-index,0)*-100vw) 0;visibility:visible}
[data-scene]:not([data-scene="top"]) [data-desk-surface] img{display:none}
[data-scene="profile"]{--profile-end-space:24px;padding:0;min-height:0;height:auto;padding-bottom:var(--profile-end-space);background-color:#dcbd90}
[data-scene="profile"]::after{display:none}
/* Pin the oak to the scrollport while keeping it inside its horizontal page. */
#profile::before{
  content:"";display:block;position:sticky;top:0;z-index:-1;pointer-events:none;
  height:var(--desk-height);margin-bottom:calc(-1 * var(--desk-height));
  background:url('rich/desk-oak.webp') calc(var(--desk-index,0) * -100vw) 0/390px 680px
}
[data-scene="profile"] .profile-world{top:0}
[data-scene="profile"] .profile-paper{outline:3px solid #e9dfc6;border-radius:7px;background:#7d9a86;box-shadow:0 2px 0 #b7a68a,4px 9px 9px #3a261447;transform:none}
[data-scene="profile"] .profile-paper::after{background:linear-gradient(0deg,#0000 calc(34% - 1px),#384b3c44 34%,#fff5 calc(34% + 1px),#0000 calc(34% + 3px)),linear-gradient(0deg,#0000 calc(68% - 1px),#384b3c44 68%,#fff5 calc(68% + 1px),#0000 calc(68% + 3px)),url('rich/paper-grain.svg');opacity:1}
[data-scene="profile"] .profile-paper::before{content:"";position:absolute;inset:0;box-shadow:inset 0 0 0 3px #e9dfc6;border-radius:3px;z-index:1;pointer-events:none}
[data-scene="profile"] [data-scene-content]{height:auto}
html[data-pager="horizontal"] #profile[data-profile-dwell]{
  min-height:calc(var(--desk-height) * 1.68 + 1px);
  padding-bottom:calc(var(--profile-end-space) + var(--desk-height) * .68);
  overflow-anchor:none;
}
html[data-pager="horizontal"] #profile :is(.profile-world,[data-scene-content]){top:var(--profile-shift,0px)}
[data-scene="profile"] [data-career-stop="origin"]{top:12%}
[data-scene="profile"] [data-career-stop="hospital"]{top:41.39%}
[data-scene="profile"] [data-career-stop="present"]{top:70.87%}
[data-scene="profile"] [data-career-stop="community"]{top:86.96%}
[data-scene="top"] [data-intro-link]::after{background-image:url('desk-corner.svg'),url('rich/desk-oak.webp')}
.scene-nav{display:flex;background:#f7f2e6;border-color:#b9ad96;isolation:isolate;box-shadow:0 -2px 5px #3a261414}
.scene-nav::before{content:"";position:absolute;left:0;top:0;width:var(--tape-width,60px);height:22px;translate:var(--tape-x,8px) var(--tape-y,17px);rotate:-3deg;background:#9fb3d9bf;z-index:0;clip-path:polygon(1% 4%,98% 0,100% 92%,0 100%)}
html[data-pager="horizontal"] .ui-tape:has([aria-current="location"]:not([data-nav-scene="top"]))::before{background-image:url('gemini-ui/ui-tape.webp');background-size:100% 100%}
.scene-nav a{position:relative;z-index:1;background:transparent}
.scene-nav a[data-nav-scene]{flex-grow:1}
.scene-nav a[aria-current="location"]{border-color:transparent;color:#24406f}
.swipe-hint {
  position:absolute;
  left:50%;
  bottom:calc(4px + var(--hint-lift, 0px));
  translate:-50% 0;
  rotate:-2deg;
  display:none;
  align-items:center;
  gap:6px;
  height:24px;
  padding:0 8px 0 10px;
  color:#24406f;
  background:#f7f2e6;
  border:.8px solid #2d2a268c;
  border-radius:3px;
  box-shadow:0 1px #3a26142e;
  pointer-events:none;
  font:700 10.5px/1 Georgia,serif;
  letter-spacing:.2em;
  opacity:0;
  transition:opacity .15s ease;
  z-index:5;
}
.swipe-hint[data-shown]{opacity:1;transition-duration:.3s}
.swipe-hint svg{fill:none;stroke:currentColor;stroke-width:1.6}
.swipe-hint[data-shown] svg{animation:swipe-signal 1.1s ease-in-out infinite}
@keyframes swipe-signal{50%{opacity:.4;translate:5px 0}}
.desk-lift-shadow{position:absolute;inset:3% 2%;border-radius:inherit;box-shadow:0 12px 16px #3a261450;z-index:-1;pointer-events:none}
#connect .desk-lift-shadow{box-shadow:0 18px 22px #3a261478}
.desk-arrival-die{display:none;position:absolute;z-index:2;top:max(4px,calc(50% - var(--binder-height)/2 - 53px));left:calc(50% - 18px);width:42px;pointer-events:none;filter:drop-shadow(2px 3px 2px #3a26143b)}
html[data-pager="horizontal"] .desk-arrival-die{display:block}
html[data-pager="horizontal"] [data-scene]:not([data-scene="top"]){
  --light-x:calc((var(--pager-index,0) - var(--desk-index,0)) * 100vw + 10vw);
  --warmth:calc(var(--desk-evening,0) * 100%);
  --desk-glow:color-mix(in srgb,#fffef4b0,#ffc08c90 var(--warmth));
  --desk-edge:color-mix(in srgb,#f7e8ca12,#85452326 var(--warmth));
  --desk-light:radial-gradient(ellipse 88vw 53svh at var(--light-x) calc(var(--desk-height) * .12),var(--desk-glow),transparent 74%),
    linear-gradient(var(--desk-edge),var(--desk-edge));
}
html[data-pager="horizontal"] #profile::before,
html[data-pager="horizontal"] #apps [data-desk-surface]{
  background-image:var(--desk-light),url('rich/desk-oak.webp');
  background-size:auto,390px 680px;
  background-position:0 0,calc(var(--desk-index,0) * -100vw) 0;
}
html[data-pager="horizontal"] #profile .profile-world::after{background:none}
html[data-pager="horizontal"]{overflow:hidden;scroll-padding:0}
html[data-pager="horizontal"] body{overflow:visible;overflow:clip}
html[data-pager="horizontal"] #main{display:flex;width:100%;height:calc(var(--core-scene-height) - var(--nav-height));padding:0;transform:translateX(calc(var(--pager-index,0)*-100%));will-change:transform}
.scene-page{flex:0 0 100%;min-width:0;height:100%;overflow-y:auto;overflow-x:hidden;overscroll-behavior-y:contain;touch-action:pan-y pinch-zoom;scrollbar-width:none;scroll-padding:0}
.scene-page::-webkit-scrollbar{display:none}
.scene-page>[data-scene="top"]{min-height:100%;height:100%}
html[data-pager="horizontal"] .swipe-hint{display:flex}
html[data-reduced-motion="true"] .swipe-hint{display:flex}
html[data-reduced-motion="true"] .swipe-hint svg{animation:none}
@media(prefers-reduced-motion:reduce){.swipe-hint,.swipe-hint svg{animation:none;transition:none}}
