/* scene photos — Mémoire (PHOTOS). Stage px: 1920×1080, portrait overrides under .is-portrait.
 * Geometry used by the motion (window, grid, tiles, card, sheet) is set inline from photos.js (GEO table).
 * No CSS transitions or animations here: every animated property is written by render(t). */

.s-photos { color: var(--ink); font-family: var(--font-ui); --ovx: 0px; --ovy: 0px; }
/* no overflow clip: the full-bleed photos (.ph-fly) cover the whole viewport, not just the 16:9 / 9:16 stage.
 * --ovx / --ovy = how far the viewport extends past the stage on each side, in stage px (set by photos.js). */
.s-photos .ph-all, .s-photos .ph-top { position: absolute; inset: 0; }

/* ------------------------------------------------------------------ peony lamplight */
.s-photos .ph-glow { position: absolute; left: 640px; top: 20px; width: 1360px; height: 1040px; border-radius: 50%; pointer-events: none;
  background: radial-gradient(closest-side, rgba(238, 130, 150, 0.30), rgba(214, 90, 122, 0.12) 52%, rgba(214, 90, 122, 0) 100%); }
.is-portrait .s-photos .ph-glow { left: -160px; top: 620px; width: 1400px; height: 1360px; }

/* ------------------------------------------------------------------ window */
.s-photos .ph-3d { position: absolute; inset: 0; perspective: 1600px; perspective-origin: 66% 50%; }
.is-portrait .s-photos .ph-3d { perspective-origin: 50% 66%; }
.s-photos .ph-win { position: absolute; left: 716px; top: 132px; width: 1124px; height: 816px; opacity: 0;
  box-shadow: 0 60px 160px -40px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(243, 235, 221, 0.04), 0 0 120px -30px rgba(238, 130, 150, 0.28), inset 0 1px 0 rgba(243, 235, 221, 0.06); }

.s-photos .ph-bar { height: 64px; gap: 18px; padding: 0 20px 0 24px; }
.s-photos .ph-search { position: relative; width: 470px; height: 42px; flex: none; display: flex; align-items: center; gap: 12px; padding: 0 16px;
  border-radius: 12px; background: rgba(243, 235, 221, 0.05); border: 1px solid var(--line); color: var(--ink-3); }
.s-photos .ph-search.is-focus { background: rgba(243, 235, 221, 0.075); border-color: rgba(238, 130, 150, 0.32); }
.s-photos .ph-search .ui-icon { width: 19px; height: 19px; }
.s-photos .ph-search__ph { position: absolute; left: 47px; top: 0; line-height: 40px; font-size: 16px; color: var(--ink-3); white-space: nowrap; }
.s-photos .ph-search__q { font: 500 19px/1 var(--font-mono); color: var(--ink); white-space: pre; letter-spacing: -0.01em; }
.s-photos .ph-search__caret { display: block; width: 2px; height: 22px; margin-left: -10px; border-radius: 1px; background: var(--photos); box-shadow: 0 0 10px rgba(238, 130, 150, 0.7); }
.s-photos .ph-search__line { position: absolute; left: 12px; right: 12px; bottom: -2px; height: 2px; border-radius: 2px; background: var(--photos); box-shadow: 0 0 12px rgba(238, 130, 150, 0.6); }
.s-photos .ph-bar__sp { flex: 1; }
.s-photos .ph-sharebtn { display: flex; align-items: center; gap: 9px; height: 40px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line);
  background: rgba(243, 235, 221, 0.05); font-weight: 600; font-size: 16px; color: var(--ink); white-space: nowrap; }
.s-photos .ph-sharebtn .ui-icon { width: 18px; height: 18px; color: var(--ink-2); }
.s-photos .ph-sharebtn.is-on { border-color: rgba(238, 130, 150, 0.55); background: rgba(238, 130, 150, 0.12); box-shadow: 0 0 0 3px rgba(238, 130, 150, 0.12), 0 0 28px rgba(238, 130, 150, 0.3); }
.s-photos .ph-sharebtn.is-on .ui-icon { color: var(--photos); }

/* sidebar (landscape only) */
.s-photos .ph-side { position: absolute; left: 0; top: 64px; bottom: 0; width: 248px; padding: 22px 14px; border-right: 1px solid var(--line); background: rgba(0, 0, 0, 0.1); }
.s-photos .ph-side__it { display: flex; align-items: center; gap: 12px; height: 40px; padding: 0 12px; border-radius: 10px; font-weight: 500; font-size: 16px; color: var(--ink-2); white-space: nowrap; }
.s-photos .ph-side__it .ui-icon { width: 19px; height: 19px; color: var(--ink-3); }
.s-photos .ph-side__label { margin: 22px 12px 8px; font-weight: 600; font-size: 15px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); }
.s-photos .ph-side__al { display: flex; align-items: center; gap: 11px; height: 38px; padding: 0 12px; border-radius: 10px; font-size: 15px; color: var(--ink-2); white-space: nowrap; overflow: hidden; }
.s-photos .ph-side__al span { overflow: hidden; text-overflow: ellipsis; }
.s-photos .ph-side__al i { width: 7px; height: 7px; flex: none; border-radius: 50%; background: rgba(243, 235, 221, 0.18); }
.s-photos .ph-side__al.is-on { color: var(--ink); background: rgba(238, 130, 150, 0.09); font-weight: 600; }
.s-photos .ph-side__al.is-on i { background: var(--photos); box-shadow: 0 0 10px rgba(238, 130, 150, 0.8); }
.is-portrait .s-photos .ph-side { display: none; }

/* content header */
.s-photos .ph-head { position: absolute; top: 90px; height: 60px; }
.s-photos .ph-head__t { position: absolute; left: 0; top: 0; display: flex; flex-direction: column; gap: 9px; white-space: nowrap; }
.s-photos .ph-head__t b { font-weight: 650; font-size: 26px; line-height: 1.1; letter-spacing: -0.015em; }
.s-photos .ph-head__t span { font-size: 16px; color: var(--ink-2); }
.s-photos .ph-seg { position: absolute; right: 0; top: 4px; display: flex; padding: 4px; gap: 2px; border-radius: 12px; background: rgba(243, 235, 221, 0.05); border: 1px solid var(--line); }
.s-photos .ph-seg span { padding: 8px 14px; border-radius: 9px; font-weight: 500; font-size: 15px; color: var(--ink-3); }
.s-photos .ph-seg span.is-on { background: rgba(243, 235, 221, 0.1); color: var(--ink); }

/* grid & tiles */
.s-photos .ph-grid { position: absolute; }
.s-photos .ph-cell { position: absolute; overflow: hidden; border-radius: 12px; background: var(--card); transform-origin: 0 0; }
.s-photos .ph-cell__img, .s-photos .ph-fly__img, .s-photos .ph-card__img, .s-photos .ph-sheet__cover { position: absolute; background-size: cover; background-position: 50% 50%; background-repeat: no-repeat; }
.s-photos .ph-cell::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: linear-gradient(180deg, rgba(14, 11, 10, 0) 60%, rgba(14, 11, 10, 0.22)); box-shadow: inset 0 0 0 1px rgba(243, 235, 221, 0.07); }
.s-photos .ph-fade { position: absolute; left: 248px; right: 0; bottom: 0; height: 120px; pointer-events: none;
  background: linear-gradient(to top, rgba(24, 19, 15, 0.96), rgba(24, 19, 15, 0)); }
.is-portrait .s-photos .ph-fade { left: 0; }

/* on-device recognition */
.s-photos .ph-bbox { position: absolute; border-radius: 6px; box-shadow: 0 0 22px rgba(238, 130, 150, 0.35);
  background:
    linear-gradient(var(--photos), var(--photos)) left top / 20px 2px no-repeat,
    linear-gradient(var(--photos), var(--photos)) left top / 2px 20px no-repeat,
    linear-gradient(var(--photos), var(--photos)) right top / 20px 2px no-repeat,
    linear-gradient(var(--photos), var(--photos)) right top / 2px 20px no-repeat,
    linear-gradient(var(--photos), var(--photos)) left bottom / 20px 2px no-repeat,
    linear-gradient(var(--photos), var(--photos)) left bottom / 2px 20px no-repeat,
    linear-gradient(var(--photos), var(--photos)) right bottom / 20px 2px no-repeat,
    linear-gradient(var(--photos), var(--photos)) right bottom / 2px 20px no-repeat; }
.s-photos .ph-tag { position: absolute; display: flex; align-items: center; gap: 8px; height: 32px; padding: 0 13px 0 11px; border-radius: 999px; white-space: nowrap;
  background: rgba(14, 11, 10, 0.74); border: 1px solid rgba(243, 235, 221, 0.14); font-weight: 600; font-size: 15px; color: var(--ink); }
.s-photos .ph-tag::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--photos); box-shadow: 0 0 8px rgba(238, 130, 150, 0.9); }
.s-photos .ph-chip { position: absolute; display: inline-flex; align-items: center; gap: 11px; height: 46px; padding: 0 20px 0 16px; border-radius: 999px; white-space: nowrap;
  background: rgba(243, 235, 221, 0.06); border: 1px solid var(--line-2); font-weight: 600; font-size: 17px; color: var(--ink); }
.s-photos .ph-chip .ui-icon { width: 21px; height: 21px; color: var(--photos); }

/* souvenir card */
.s-photos .ph-card { position: absolute; overflow: hidden; border-radius: 18px; opacity: 0;
  box-shadow: 0 30px 70px -20px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(243, 235, 221, 0.14), 0 0 60px -10px rgba(238, 130, 150, 0.35); }
.s-photos .ph-card__img { inset: 0; }
.s-photos .ph-card__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(14, 11, 10, 0) 30%, rgba(14, 11, 10, 0.82)); }
.s-photos .ph-card__txt { position: absolute; left: 24px; bottom: 22px; display: flex; flex-direction: column; gap: 8px; }
.s-photos .ph-card__eb { font-weight: 600; font-size: 15px; letter-spacing: 0.14em; text-transform: uppercase; color: rgba(243, 235, 221, 0.82); }
.s-photos .ph-card__txt b { font-weight: 650; font-size: 32px; line-height: 1; letter-spacing: -0.02em; color: #FFF8EE; }
.s-photos .ph-card__play { position: absolute; right: 22px; bottom: 22px; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(243, 235, 221, 0.94); color: #1A1410; box-shadow: 0 0 0 6px rgba(243, 235, 221, 0.16), 0 0 30px rgba(238, 130, 150, 0.5); }
.s-photos .ph-card__play .ui-icon { width: 20px; height: 20px; margin-left: 3px; fill: currentColor; }

/* share sheet */
.s-photos .ph-scrim { position: absolute; left: 0; right: 0; top: 64px; bottom: 0; background: rgba(14, 11, 10, 0.9); opacity: 0; }
.s-photos .ph-sheet { position: absolute; padding: 26px 28px 24px; border-radius: 26px; opacity: 0;
  background: linear-gradient(180deg, rgba(40, 32, 26, 0.9), rgba(28, 22, 18, 0.92)); border: 1px solid var(--line-2);
  backdrop-filter: blur(22px) saturate(1.3); -webkit-backdrop-filter: blur(22px) saturate(1.3);
  box-shadow: 0 50px 120px -30px rgba(0, 0, 0, 0.9), 0 0 0 1px rgba(0, 0, 0, 0.3), 0 0 90px -20px rgba(238, 130, 150, 0.3); }
.s-photos .ph-sheet__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.s-photos .ph-sheet__head b { font-weight: 650; font-size: 20px; letter-spacing: -0.01em; white-space: nowrap; }
.s-photos .ph-sheet__priv { position: relative; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; color: var(--ink-3); white-space: nowrap; padding-bottom: 4px; }
.s-photos .ph-sheet__priv .ui-icon { width: 17px; height: 17px; }
.s-photos .ph-sheet__priv::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px; border-radius: 2px; background: var(--photos); opacity: 0; box-shadow: 0 0 10px rgba(238, 130, 150, 0.7); }
.s-photos .ph-sheet__priv.is-lit { color: var(--ink); }
.s-photos .ph-sheet__priv.is-lit .ui-icon { color: var(--photos); }
.s-photos .ph-sheet__priv.is-lit::after { opacity: 1; }
.s-photos .ph-sheet__album { display: flex; align-items: center; gap: 18px; margin-top: 22px; padding: 14px; border-radius: 18px; background: rgba(243, 235, 221, 0.045); border: 1px solid var(--line); }
.s-photos .ph-sheet__cover { position: relative; width: 72px; height: 72px; flex: none; border-radius: 14px; box-shadow: inset 0 0 0 1px rgba(243, 235, 221, 0.1); }
.s-photos .ph-sheet__album div { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.s-photos .ph-sheet__album b { font-weight: 650; font-size: 20px; letter-spacing: -0.01em; white-space: nowrap; }
.s-photos .ph-sheet__album span { font-size: 15px; color: var(--ink-2); white-space: nowrap; }
.s-photos .ph-sheet__label { margin: 22px 0 6px; font-weight: 600; font-size: 15px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-3); }
.s-photos .ph-row { display: flex; align-items: center; gap: 16px; height: 66px; border-bottom: 1px solid var(--line); }
.s-photos .ph-row:last-of-type { border-bottom: 0; }
.s-photos .ph-row__av { position: relative; width: 48px; height: 48px; flex: none; }
.s-photos .ph-row__av .ui-avatar { box-shadow: 0 0 0 2px rgba(24, 19, 15, 0.9); }
.s-photos .ph-row__info { position: relative; flex: 1; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.s-photos .ph-row__info b { font-weight: 600; font-size: 18px; white-space: nowrap; }
.s-photos .ph-row__role { font-size: 15px; color: var(--ink-2); white-space: nowrap; }
.s-photos .ph-row__role--call { position: absolute; left: 0; bottom: 0; display: inline-flex; align-items: center; gap: 7px; color: var(--visio); font-weight: 600; opacity: 0; }
.s-photos .ph-row__role--call .ui-icon { width: 17px; height: 17px; }
.s-photos .ph-row__ok { width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; color: var(--ink-2); background: rgba(243, 235, 221, 0.06); }
.s-photos .ph-row__ok .ui-icon { width: 16px; height: 16px; }
.s-photos .ph-sheet__foot { display: flex; justify-content: flex-end; margin-top: 18px; }
.s-photos .ph-sheet__btn { padding: 13px 26px; border-radius: 13px; background: var(--ink); color: #1A1410; font-weight: 650; font-size: 16px; }

/* ------------------------------------------------------------------ full-bleed photos (hand-off + slideshow) */
.s-photos .ph-fly { position: absolute; left: 0; top: 0; width: 1920px; height: 1080px; overflow: hidden; transform-origin: 0 0; opacity: 0; background: #18130F; }
.is-portrait .s-photos .ph-fly { width: 1080px; height: 1920px; }
/* slide finish: scrim under the header (top 18 %) and the word (bottom 45 %), a soft vignette, film grain */
.s-photos .ph-fly__fx { position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(to bottom, rgba(14, 11, 10, 0.42), rgba(14, 11, 10, 0) 18%),
    linear-gradient(to top, rgba(14, 11, 10, 0.62), rgba(14, 11, 10, 0.3) 22%, rgba(14, 11, 10, 0) 45%),
    radial-gradient(120% 95% at 50% 46%, rgba(14, 11, 10, 0) 58%, rgba(14, 11, 10, 0.38)); }
.s-photos .ph-fly__grain { position: absolute; inset: 0; opacity: 0.09; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .9 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>"); }
.s-photos .ph-fly__scrim { position: absolute; inset: 0; opacity: 0;
  background: radial-gradient(70% 70% at 50% 50%, rgba(14, 11, 10, 0.78), rgba(14, 11, 10, 0.94)); }
.s-photos .ph-show { position: absolute; inset: 0; }
.s-photos .ph-shade { position: absolute; left: calc(-1 * var(--ovx)); right: calc(-1 * var(--ovx)); opacity: 0; pointer-events: none; }
.s-photos .ph-shade--top { top: calc(-1 * var(--ovy)); height: calc(320px + var(--ovy)); background: linear-gradient(to bottom, rgba(14, 11, 10, 0.6), rgba(14, 11, 10, 0.25) 55%, rgba(14, 11, 10, 0)); }
.s-photos .ph-shade--bot { bottom: calc(-1 * var(--ovy)); height: calc(560px + var(--ovy)); background: linear-gradient(to top, rgba(14, 11, 10, 0.66), rgba(14, 11, 10, 0.3) 45%, rgba(14, 11, 10, 0)); }
.is-portrait .s-photos .ph-shade--top { height: calc(420px + var(--ovy)); }
.is-portrait .s-photos .ph-shade--bot { height: calc(900px + var(--ovy)); }
.s-photos .ph-prog { position: absolute; left: 96px; right: 96px; top: 56px; display: flex; gap: 10px; opacity: 0; }
.s-photos .ph-prog__seg { flex: 1; height: 3px; border-radius: 3px; overflow: hidden; background: rgba(243, 235, 221, 0.24); }
.s-photos .ph-prog__seg i { display: block; height: 100%; background: var(--ink); transform-origin: 0 50%; }
.s-photos .ph-mhead { position: absolute; left: 96px; top: 86px; display: flex; align-items: center; gap: 16px; opacity: 0; }
.s-photos .ph-mhead div { display: flex; flex-direction: column; gap: 7px; text-shadow: 0 1px 14px rgba(14, 11, 10, 0.55); }
.s-photos .ph-mhead b { font-weight: 650; font-size: 22px; letter-spacing: -0.01em; }
.s-photos .ph-mhead span { font-size: 17px; color: rgba(243, 235, 221, 0.8); }
.is-portrait .s-photos .ph-prog { left: 72px; right: 72px; top: 72px; }
.is-portrait .s-photos .ph-mhead { left: 72px; top: 104px; }
.s-photos .ph-cap { position: absolute; right: 96px; bottom: 122px; display: inline-flex; align-items: center; gap: 12px; height: 56px; padding: 0 24px 0 18px; border-radius: 999px; white-space: nowrap; opacity: 0;
  background: rgba(14, 11, 10, 0.55); border: 1px solid rgba(243, 235, 221, 0.18); font-weight: 600; font-size: 22px; letter-spacing: -0.01em; color: var(--ink);
  box-shadow: 0 20px 50px -20px rgba(0, 0, 0, 0.7); }
.s-photos .ph-cap .ui-icon { width: 22px; height: 22px; color: var(--photos); }
.is-portrait .s-photos .ph-cap { right: auto; left: 72px; bottom: 470px; }
.s-photos .ph-rev { position: absolute; left: 96px; bottom: 92px; overflow: hidden; padding: 0.12em 0.08em 0.2em; margin: -0.12em -0.08em -0.2em;
  font-family: var(--font-display); font-weight: 400; font-size: 160px; line-height: 1.08; letter-spacing: -0.02em; color: #FFF8EE; white-space: nowrap;
  filter: drop-shadow(0 2px 26px rgba(14, 11, 10, 0.55)); }
.is-portrait .s-photos .ph-rev { left: 72px; bottom: 260px; font-size: 150px; }
.s-photos .ph-rev__in { display: block; }

/* ------------------------------------------------------------------ title card → label */
.s-photos .ph-title { position: absolute; inset: 0; }
.s-photos .ph-tglow { position: absolute; left: 360px; top: 90px; width: 1200px; height: 900px; border-radius: 50%; opacity: 0; pointer-events: none;
  background: radial-gradient(closest-side, rgba(238, 130, 150, 0.34), rgba(214, 90, 122, 0.14) 50%, rgba(214, 90, 122, 0)); }
.is-portrait .s-photos .ph-tglow { left: -160px; top: 500px; width: 1400px; height: 1000px; }
.s-photos .ph-ticon, .s-photos .ph-tname, .s-photos .ph-tdesc { position: absolute; left: 0; top: 0; transform-origin: 0 0; white-space: nowrap; }
.s-photos .ph-ticon { width: 150px; height: 150px; }
.s-photos .ph-ticon__in { position: relative; width: 150px; height: 150px; }
.s-photos .ph-ticon__in .ui-app-icon { position: relative; filter: drop-shadow(0 10px 40px rgba(238, 130, 150, 0.45)); }
.s-photos .ph-ticon__halo { position: absolute; left: -110px; top: -100px; width: 370px; height: 370px; border-radius: 50%; opacity: 0;
  background: radial-gradient(closest-side, rgba(255, 214, 200, 0.55), rgba(238, 130, 150, 0.25) 45%, rgba(238, 130, 150, 0)); }
.s-photos .ph-tname { overflow: hidden; padding: 0 0.07em; font-size: 240px; line-height: 1.12; color: var(--ink); }
.s-photos .ph-tname__in { display: block; }
.s-photos .ph-tdesc { font-size: 26px; letter-spacing: 0.14em; color: var(--ink-2); }
.s-photos .ph-tdesc__in { display: block; }

/* ------------------------------------------------------------------ kinetic text */
.s-photos .ph-kin { position: absolute; left: 96px; top: 436px; width: 590px; }
.is-portrait .s-photos .ph-kin { left: 72px; top: 296px; width: 936px; }
.s-photos .ph-phrase { position: absolute; left: 0; top: 0; width: 100%; }
.s-photos .ph-line { overflow: hidden; padding: 0.12em 0.08em 0.2em; margin: -0.12em -0.08em -0.2em;
  font-family: var(--font-display); font-weight: 400; font-size: 88px; line-height: 1.14; letter-spacing: -0.02em; color: var(--ink); opacity: 0; }
.is-portrait .s-photos .ph-line { font-size: 100px; }
.s-photos .ph-line__in { display: block; }

/* ------------------------------------------------------------------ cursor & ringing avatar */
.s-photos .ph-cursor { position: absolute; left: 0; top: 0; width: 30px; height: 30px; opacity: 0; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, 0.5)); }
.s-photos .ph-cursor svg { width: 100%; height: 100%; display: block; }
.s-photos .ph-ring { position: absolute; left: 0; top: 0; width: 48px; height: 48px; }
.s-photos .ph-ring .ui-avatar { position: relative; box-shadow: 0 0 0 2px rgba(24, 19, 15, 0.9), 0 0 0 4px rgba(180, 141, 224, 0.75); }
.s-photos .ph-ring__halo { position: absolute; left: -46px; top: -46px; width: 140px; height: 140px; border-radius: 50%; opacity: 0;
  background: radial-gradient(closest-side, rgba(180, 141, 224, 0.6), rgba(138, 99, 196, 0.22) 55%, rgba(138, 99, 196, 0)); }
.s-photos .ph-ring__wave { position: absolute; inset: -3px; border-radius: 50%; border: 2px solid var(--visio); opacity: 0; box-shadow: 0 0 14px rgba(180, 141, 224, 0.5); }
