/* Licensed client font: exact original OTF, self-hosted without conversion.
   CJK glyphs retain the existing system fallback and source artwork. */
@font-face {
  font-family: "Holiday Futura LT Pro";
  src: url('/assets/fonts/FuturaLTProLight.otf') format('opentype');
  font-style: normal;
  font-weight: 300;
  font-display: swap;
}
:root {
  color-scheme: dark;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-synthesis: none;
  color: #fff;
  background: #100f0f;
  --product-scale: 1.6;
  --scene-width: min(100vw, 46.770833vh);
  --bar-texture-width: 42.239583vh;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
}
* { box-sizing: border-box; }
html, body { margin: 0; width: 100%; height: 100%; overflow: hidden; overscroll-behavior: none; }
body { -webkit-font-smoothing: antialiased; }
button, label, input, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; cursor: pointer; }
button, label { touch-action: manipulation; }
button:disabled { cursor: default; }
button:focus-visible, label:focus-visible { outline: 2px solid #d7b77e; outline-offset: 5px; }
/* Only pointer-triggered automatic focus on the consent Back control.
   Keyboard input clears this marker; other controls retain their focus ring. */
#consent-cancel[data-pointer-focus]:focus-visible { outline: none; }
[hidden] { display: none !important; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }
.experience-shell { width: 100%; height: 100%; display: flex; justify-content: center; background: #100f0f; }
.stage { container-type: inline-size; position: relative; width: var(--scene-width); max-width: 100%; height: 100%; overflow: hidden; isolation: isolate; background: #211e1a; }
#output { position: absolute; inset: 0; width: 100%; height: 100%; display: block; object-fit: contain; }
.placeholder { position: absolute; inset: 0; z-index: 1; overflow: hidden; background: radial-gradient(ellipse at 72% 12%, #5b554a 0%, #302d29 24%, #1e1c1a 59%, #131313 100%); }
.mirror-light { position: absolute; inset: -24% -50%; opacity: .36; transform: rotate(-18deg); background: linear-gradient(102deg, transparent 36%, #b3a99120 43%, #d8d1c34d 46%, #c9bda12a 49%, transparent 58%); }
.scene-header { position: absolute; inset: 0 0 auto; height: calc(13% + var(--safe-top)); z-index: 7; pointer-events: none; }
.brand-mark { position: absolute; top: calc(var(--safe-top) + 20px); left: 47.89%; width: 10.44%; height: auto; transform: translateX(-50%); filter: drop-shadow(0 1px 5px #0003); }
.icon-button { appearance: none; display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 0; border-radius: 50%; color: #fff; background: transparent; pointer-events: auto; }
.icon-button span { position: relative; display: block; width: 16px; height: 16px; }
.icon-button span::before, .icon-button span::after { content: ""; position: absolute; left: 7px; top: -1px; width: 1px; height: 19px; background: currentColor; transform: rotate(45deg); }
.icon-button span::after { transform: rotate(-45deg); }
.exit-button { position: absolute; right: max(4%, var(--safe-right)); top: calc(var(--safe-top) + 14px); background: #00000018; }
.entry-screen { position: absolute; inset: 0; z-index: 5; }
.entry-dim { position: absolute; inset: 0; background: #00000012; }
.entry-title { position: absolute; top: 41.98%; left: 49.11%; width: 33.63%; margin: 0; transform: translateX(-50%); }
.entry-title img, .art-button img { display: block; width: 100%; height: auto; }
.art-button { appearance: none; padding: 0; border: 0; color: #fff; background: transparent; transition: opacity .25s ease, transform .2s ease; }
.art-button:active:not(:disabled) { transform: scale(.96); }
.start-button { position: absolute; top: 65.3%; left: 47.05%; width: 37.53%; min-height: 44px; transform: translateX(-50%); }
.start-button:active:not(:disabled) { transform: translateX(-50%) scale(.97); }
.entry-preview-note { position: absolute; left: 15%; right: 15%; bottom: calc(var(--safe-bottom) + 43px); margin: 0; color: #ffffff83; text-align: center; font-size: 10px; line-height: 1.6; letter-spacing: .14em; }
.scene-footer { position: absolute; z-index: 8; left: 8%; right: 8%; bottom: calc(var(--safe-bottom) + 6px); display: flex; justify-content: center; pointer-events: none; }
.text-button { appearance: none; border: 0; padding: 10px 12px; min-height: 40px; background: transparent; color: #fff; font-size: 11px; line-height: 1.4; letter-spacing: .06em; }
.about-toggle { pointer-events: auto; color: #ffffff9c; font-size: 9px; padding: 6px 12px; min-height: 28px; }
.screen-layer { position: absolute; inset: 0; z-index: 20; }
.screen-layer:not([hidden]), .entry-screen:not([hidden]) { animation: screen-reveal .5s ease both; }
.review-screen { overflow-y: auto; -webkit-overflow-scrolling: touch; background: #f9f8f5; color: #24201c; padding: calc(var(--safe-top) + 24px) max(8%, var(--safe-left)) calc(var(--safe-bottom) + 24px); }
.review-card { min-height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; max-width: 390px; margin: 0 auto; }
.review-brand { display: block; width: 83px; height: auto; margin: 0 auto 25px; }
.review-card h2 { margin: 0; width: 114px; max-width: 45%; line-height: 1; }
/* Native vector text replaces undersampled title PNGs, preserving both
   authored title boxes. The existing font stack supplies Chinese glyphs. */
.review-card h2 .review-title-vector { display: block; width: 100%; height: auto; overflow: visible; fill: #000; }
.review-title-vector text { font-family: inherit; font-size: 19px; font-weight: 400; font-style: normal; }
.review-title-vector.localized-english text { font-family: "Holiday Futura LT Pro", -apple-system, BlinkMacSystemFont, sans-serif; font-size: 21.4px; font-weight: 300; }
.review-copy { margin: 34px 0 30px; width: 100%; font-size: 13px; line-height: 1.95; text-align: center; letter-spacing: .02em; }
.review-copy p { margin: 0; }
.review-copy p + p { margin-top: 15px; }
.review-actions { display: flex; flex-direction: column; width: 100%; gap: 8px; }
.solid-button, .outline-button { appearance: none; display: flex; align-items: center; justify-content: center; width: 100%; min-height: 48px; border: 1px solid #22201d; border-radius: 28px; padding: 13px 20px; font-size: 12px; line-height: 1.6; letter-spacing: .04em; text-align: center; text-decoration: none; }
.solid-button { background: #22201d; color: #fff; }
.solid-button:active:not(:disabled) { background: #494039; }
.solid-button:disabled, .outline-button:disabled { opacity: .45; }
.outline-button { background: transparent; color: inherit; border-color: currentColor; }
.dark-text { color: #726a61; }
.review-footnote { margin: 28px 0 0; color: #8e857a; font-size: 9px; line-height: 1.7; text-align: center; }
.loading-screen { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 20px 12%; background: #171614e8; text-align: center; z-index: 10; }
.loading-ring { width: 35px; height: 35px; border: 1px solid #ffffff25; border-top-color: #e8dfcd; border-radius: 50%; animation: prepare-turn 1.3s linear infinite; margin-bottom: 26px; }
.loading-screen p { font-size: 13px; line-height: 1.8; letter-spacing: .06em; margin: 0 0 12px; }
.loading-screen small { font-size: 10px; color: #ffffff79; line-height: 1.7; }
.help-screen { display: flex; align-items: center; justify-content: center; padding: calc(var(--safe-top) + 24px) 9% calc(var(--safe-bottom) + 24px); background: #171513ed; }
.help-card { width: 100%; text-align: center; }
.camera-symbol { width: 38px; height: 28px; border: 1px solid #e0d6c8; border-radius: 5px; margin: 0 auto 27px; position: relative; }
.camera-symbol::before { content: ""; position: absolute; width: 11px; height: 11px; border: 1px solid #e0d6c8; border-radius: 50%; left: 12px; top: 7px; }
.camera-symbol::after { content: ""; position: absolute; width: 13px; height: 4px; border: 1px solid #e0d6c8; border-bottom: 0; left: 11px; top: -5px; }
.help-card h2 { font-size: 18px; font-weight: 400; line-height: 1.6; letter-spacing: .04em; margin: 0 0 17px; }
.help-card > p { color: #e3dbcfbd; font-size: 12px; line-height: 1.95; margin: 0 0 30px; }
.help-card .solid-button { background: #eae4d9; color: #211d18; border-color: #eae4d9; }
.help-card .outline-button { margin-top: 12px; color: #eae4d9; border-color: #eae4d955; }
.help-card .help-note { margin: 25px 0 0; font-size: 10px; color: #fff7; }
.china-overlay { position: absolute; inset: 0; z-index: 3; pointer-events: none; }
.product-shelf { position: absolute; inset: 0; }
.product-visual { position: absolute; inset: 0; filter: drop-shadow(0 2px 3px #0002); }
.product-art, .product-glow, .product-name { position: absolute; display: block; height: auto; }
/* Larger packshot keeps the authored narrow aspect and left-side visual centre. */
.mascara-shelf .product-art { left: 7.74%; top: 49.74%; width: calc(3.90% * var(--product-scale)); transform: translate(-50%, -50%); }
.mascara-shelf .product-glow { left: 7.74%; top: 49.74%; width: calc(7.24% * var(--product-scale)); transform: translate(-50%, -50%); }
.perfume-shelf .product-art { left: 10.805%; top: 48.65%; width: calc(10.69% * var(--product-scale)); transform: translate(-50%, -50%); }
.perfume-shelf .product-glow { left: 10.805%; top: 48.65%; width: calc(14.03% * var(--product-scale)); transform: translate(-50%, -50%); }
.product-name { left: 50%; top: 79.2%; transform: translateX(-50%); }
.product-shelf:not([hidden]) .product-name, .flow-copy img:not([hidden]) { animation: reveal-copy 1s ease both; }
.mascara-shelf .product-name { width: 35.97%; }
.perfume-shelf .product-name { width: 68.26%; }
.flow-copy img { position: absolute; display: block; height: auto; left: 50%; transform: translateX(-50%); filter: drop-shadow(0 1px 4px #0006); }
#flow-instruction-mascara { width: 43.65%; top: max(16.7%, calc(var(--safe-top) + 104px)); }
#flow-instruction-perfume { width: 57.24%; top: max(16.7%, calc(var(--safe-top) + 104px)); }
#flow-photo-instruction { width: 60.25%; top: max(12.4%, calc(var(--safe-top) + 80px)); }
#flow-photo-instruction:not([hidden]) { animation-duration: .5s; }
progress { appearance: none; -webkit-appearance: none; display: block; padding: 0; border: 0; border-radius: 2px; height: 2px; background: url('/assets/china/flow-bar-empty.png') center / 100% 100% no-repeat; overflow: hidden; }
progress::-webkit-progress-bar { background: url('/assets/china/flow-bar-empty.png') center / 100% 100% no-repeat; border-radius: 2px; }
progress::-webkit-progress-value { background: url('/assets/china/flow-bar-full.png') left center / var(--bar-texture-width) 100% no-repeat; border-radius: 2px; }
progress::-moz-progress-bar { background: url('/assets/china/flow-bar-full.png') left center / var(--bar-texture-width) 100% no-repeat; border-radius: 2px; }
#flow-progress { position: absolute; left: 4.12%; width: 90.31%; top: max(12.4%, calc(var(--safe-top) + 70px)); height: 1.30%; }
.photo-overlay { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.photo-overlay img { position: absolute; display: block; height: auto; left: 50%; transform: translateX(-50%); filter: drop-shadow(0 1px 5px #0004); }
#photo-ready-art { top: 16.77%; width: 21.05%; }
#photo-ready-art:not([hidden]), #photo-generating-art:not([hidden]) { animation: reveal-copy .5s ease both; }
#photo-countdown { position: absolute; left: 50%; top: 36%; transform: translate(-50%, -50%); font-family: "Holiday Futura LT Pro", -apple-system, BlinkMacSystemFont, sans-serif; font-weight: 300; font-size: clamp(64px, 9.5vh, 100px); line-height: 1; text-align: center; font-variant-numeric: lining-nums tabular-nums; }
#photo-generating-art { top: 21.51%; width: 35.52%; }
#photo-progress { position: absolute; left: 4.12%; width: 90.31%; top: max(12.4%, calc(var(--safe-top) + 70px)); height: 1.30%; }
.photo-flash { position: absolute; inset: 0; z-index: 12; background: #fff; pointer-events: none; }
.photo-actions { position: absolute; inset: 0; pointer-events: none; z-index: 8; }
.photo-actions button { pointer-events: auto; }
.photo-button, .retake-button { position: absolute; left: 8.5%; top: calc(var(--safe-top) + 3.34%); width: 14.25%; min-height: 54px; }
.photo-button, .retake-button { isolation: isolate; }
.photo-button::before, .retake-button::before { content: ""; position: absolute; z-index: -1; inset: -9px; border-radius: 50%; background: radial-gradient(ellipse, rgba(0, 0, 0, .21), rgba(0, 0, 0, .15) 50%, transparent 75%); filter: blur(4px); pointer-events: none; }
.photo-button img, .retake-button img { filter: drop-shadow(0 1px 2px #0009) drop-shadow(0 0 5px #0003); }
/* Requested photo control occupies the former language-switch anchor.
   Aspect ratio is untouched; safe-area and a 44px target work on narrow phones. */
.photo-button { left: max(12px, var(--safe-left)); top: calc(var(--safe-top) + 12px); bottom: auto; width: clamp(44px, 14.81%, 64px); min-height: 44px; transform: none; }
.photo-button:active:not(:disabled) { transform: scale(.96); }
.photo-button:disabled { opacity: 0 !important; pointer-events: none; }
.retake-button img { width: 100%; }
/* Keep the established Share position and safe-area spacing. */
.share-button { position: absolute; left: 50%; bottom: calc(var(--safe-bottom) + 74px); width: clamp(112px, 32.52%, 160px); min-height: 44px; transform: translateX(-50%); }
.share-button:active:not(:disabled) { transform: translateX(-50%) scale(.97); }
.share-button:disabled, .retake-button:disabled { opacity: .4 !important; }
.product-status { position: absolute; z-index: 8; top: max(calc(var(--safe-top) + 13%), 100px); left: 11%; width: 78%; margin: 0; text-align: center; color: #fff; font-size: 11px; line-height: 1.7; text-shadow: 0 1px 6px #0009; }
.result-caption { position: absolute; z-index: 6; bottom: calc(var(--safe-bottom) + 140px); left: 10%; width: 80%; margin: 0; text-align: center; color: #ffffffe0; font-size: 10px; line-height: 1.7; letter-spacing: .06em; text-shadow: 0 1px 6px #0009; }
.export-recovery { position: absolute; z-index: 9; bottom: calc(var(--safe-bottom) + 132px); left: 10%; width: 80%; text-align: center; }
#export-error { position: absolute; z-index: 9; bottom: calc(var(--safe-bottom) + 190px); left: 10%; width: 80%; font-size: 11px; line-height: 1.8; margin: 0; text-align: center; color: #fff; text-shadow: 0 1px 5px #0008; }
#export-error:not([hidden]) ~ #result-caption { display: none !important; }
#retry-export { min-height: 42px; border-color: #ffffff70; background: #15131299; color: #fff; font-size: 11px; }
.about-screen { display: flex; align-items: flex-end; justify-content: center; padding: 8px; background: #0807068c; z-index: 30; }
.about-card { position: relative; max-height: 92%; overflow-y: auto; -webkit-overflow-scrolling: touch; background: #f8f6f1; color: #26211d; padding: 37px 29px calc(var(--safe-bottom) + 25px); border-radius: 17px 17px 5px 5px; width: 100%; }
.about-close { position: absolute; top: 9px; right: 8px; color: #6b6258; }
.about-eyebrow { margin: 0 0 13px; font: 11px Georgia, serif; letter-spacing: .3em; color: #8b7860; }
.about-card h2 { margin: 0 0 23px; font-size: 21px; font-weight: 400; letter-spacing: .04em; }
.about-card > p:not(.about-eyebrow) { font-size: 12px; line-height: 1.95; margin: 0 0 16px; color: #756d62; }
.about-card small { display: block; color: #958b7e; font-size: 9px; line-height: 1.9; }
body[data-experience="review"] .scene-header, body[data-experience="review"] .scene-footer { visibility: hidden; }
/* Presentation contrast only: this layer is outside #output, so it never
   changes the composited camera frame or the exported local JPEG. */
body[data-experience="result"] .stage::after { content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; background: linear-gradient(180deg, transparent 54%, rgba(13, 10, 8, .10) 70%, rgba(13, 10, 8, .34) 88%, rgba(13, 10, 8, .52) 100%); }
body[data-experience="loading"] .scene-header, body[data-experience="error"] .scene-header { z-index: 21; }
body[data-experience="intro"] .photo-actions, body[data-experience="intro"] #product-status, body[data-experience="loading"] .photo-actions, body[data-experience="review"] .photo-actions, body[data-experience="error"] .photo-actions { visibility: hidden; }
body[data-experience="taking"] .scene-footer, body[data-experience="loading"] .scene-footer { opacity: 0; pointer-events: none; }
body[data-experience="taking"] .scene-footer button, body[data-experience="loading"] .scene-footer button { pointer-events: none; }
@keyframes prepare-turn { to { transform: rotate(360deg); } }
@keyframes screen-reveal { from { opacity: 0; } to { opacity: 1; } }
@keyframes reveal-copy { from { opacity: 0; } to { opacity: 1; } }
@supports (height: 100dvh) { :root { --scene-width: min(100vw, 46.770833dvh); --bar-texture-width: 42.239583dvh; } .experience-shell { height: 100dvh; } #photo-countdown { font-size: clamp(64px, 9.5dvh, 100px); } }
@media (max-aspect-ratio: 3/4) { :root { --scene-width: 100vw; --bar-texture-width: 90.31vw; } }
@media (min-aspect-ratio: 3/4) { .stage { box-shadow: 0 0 100px #0008; } }
@media (max-height: 600px) {
  .review-screen { padding-top: calc(var(--safe-top) + 18px); padding-bottom: calc(var(--safe-bottom) + 16px); }
  .review-brand { width: 58px; margin-bottom: 16px; }
  .review-copy { margin: 20px 0; font-size: 12px; }
  .review-footnote { margin-top: 15px; }
  .help-screen { overflow-y: auto; align-items: flex-start; }
  .help-card { padding-top: 25px; }
  .camera-symbol { margin-bottom: 18px; }
  .help-card > p { margin-bottom: 20px; }
  .brand-mark { top: calc(var(--safe-top) + 12px); }
  .exit-button { top: calc(var(--safe-top) + 5px); }
  .scene-footer { bottom: calc(var(--safe-bottom) + 6px); }
  .entry-preview-note { bottom: calc(var(--safe-bottom) + 29px); font-size: 8px; }
  .about-toggle { font-size: 8px; min-height: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; }
  .product-shelf:not([hidden]) .product-name, .flow-copy img:not([hidden]) { animation: none; }
  .screen-layer:not([hidden]), .entry-screen:not([hidden]), #photo-ready-art:not([hidden]), #photo-generating-art:not([hidden]) { animation: none; }
  .loading-ring { animation: none; border-top-color: #e8dfcd; border-right-color: #e8dfcd; }
  .photo-flash { display: none !important; }
}

/* Language stays outside the composited photo. The upper-left capture
   anchor is unchanged; the compact selector uses the upper-right header slot. */
.language-switch {
  position: absolute; z-index: 40;
  top: calc(var(--safe-top) + 12px); right: max(12px, var(--safe-right));
  display: grid; grid-template-columns: 1fr 1px 1fr; align-items: center; gap: 1px;
  width: 98px; min-height: 48px; padding: 1px;
  border: 1px solid #ffffff38; border-radius: 26px;
  background: #191612b8; color: #fff;
  -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
  box-shadow: 0 2px 12px #00000014;
}
.language-switch button {
  appearance: none; min-width: 44px; min-height: 44px;
  border: 0; border-radius: 23px; padding: 0 6px;
  background: transparent; color: #fff;
  font-family: "Holiday Futura LT Pro", -apple-system, BlinkMacSystemFont, "PingFang SC", sans-serif;
  font-size: 12px; font-weight: 300; line-height: 1.2; letter-spacing: .025em;
  white-space: nowrap; transition: background .2s ease, color .2s ease;
}
.language-switch button[lang="zh-Hans"] { font-weight: 400; }
.language-switch button[aria-pressed="true"] { background: #f1e7d9; color: #302820; }
.language-divider { width: 1px; height: 12px; background: #ffffff38; }
/* Exit yields the upper-right slot without moving the accepted capture. */
.exit-button { left: calc(max(12px, var(--safe-left)) + clamp(44px, 14.81%, 64px) + 8px); right: auto; }
/* Result Retake keeps its original upper-left location and English artwork. */
body[data-experience="result"] .exit-button { left: auto; right: max(12px, var(--safe-right)); top: calc(var(--safe-top) + 68px); }
#consent-screen > .language-switch, #about-sheet > .language-switch { background: #eeebe6ed; border-color: #6b5d4b38; color: #302820; }
#consent-screen > .language-switch button, #about-sheet > .language-switch button { color: #685c4d; }
#consent-screen > .language-switch button[aria-pressed="true"], #about-sheet > .language-switch button[aria-pressed="true"] { background: #29231d; color: #fffaf3; }
#consent-screen > .language-switch .language-divider, #about-sheet > .language-switch .language-divider { background: #74634f38; }
/* A dialog owns its selector and focus trap, but only its content scrolls.
   The header remains outside that scrollport even when automatic Back/Retry
   focus scrolls short English content into view. */
#consent-screen, #camera-help { overflow: hidden; padding: 0; }
.review-scroll, .help-scroll {
  position: absolute; top: calc(var(--safe-top) + 72px); left: 0; right: 0; bottom: 0;
  overflow-y: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain;
}
.review-scroll { padding: 24px max(8%, var(--safe-left)) calc(var(--safe-bottom) + 24px); }
.help-scroll { padding: 24px 9% calc(var(--safe-bottom) + 24px); }
.help-scroll > .help-card { min-height: 100%; display: flex; flex-direction: column; justify-content: center; }
@media (max-height: 600px) {
  .review-scroll { padding-top: 18px; padding-bottom: calc(var(--safe-bottom) + 16px); }
}
/* The sheet's close control retains its own right-hand tap target. */
#about-sheet > .language-switch { right: max(64px, calc(var(--safe-right) + 52px)); }
/* Very narrow landscape stages need a second header row; all source flow
   copy starts below 104px in this layout. No camera or artwork crop changes. */
@container (max-width: 299px) {
  .language-switch { top: calc(var(--safe-top) + 60px); width: 90px; min-height: 44px; }
  .language-switch button { min-width: 40px; min-height: 40px; font-size: 11px; }
  .exit-button { left: max(12px, var(--safe-left)); top: calc(var(--safe-top) + 60px); }
  body[data-experience="result"] .exit-button { top: calc(var(--safe-top) + 112px); }
  #consent-screen > .language-switch, #camera-help > .language-switch, #about-sheet > .language-switch { top: calc(var(--safe-top) + 12px); }
  .review-scroll { padding-top: 18px; }
  .help-scroll { padding-top: 12px; }
}

/* English artwork is restored alongside the accepted Chinese source artwork. */
.localized-english { display: none !important; }
html:lang(en) .localized-art { display: none !important; }
html:lang(en) .localized-english { display: block !important; }
/* The original image's hidden flag is the single flow visibility owner. */
.localized-art[hidden] + .localized-english { display: none !important; }
.flow-copy .localized-english, .photo-overlay .localized-english {
  position: absolute; left: 50%; height: auto; transform: translateX(-50%);
  filter: drop-shadow(0 1px 4px #0006);
}
.localized-flow-instruction-mascara { width: 74%; top: max(16.7%, calc(var(--safe-top) + 104px)); }
.localized-flow-instruction-perfume { width: 58%; top: max(16.7%, calc(var(--safe-top) + 104px)); }
.localized-flow-photo-instruction { width: 76%; top: max(12.4%, calc(var(--safe-top) + 80px)); }
.localized-photo-ready-art { top: 16.77%; width: 35%; }
.localized-photo-generating-art { top: 21.51%; width: 54%; }
.flow-copy .localized-art:not([hidden]) + .localized-english { animation: reveal-copy 1s ease both; }
#flow-photo-instruction:not([hidden]) + .localized-english,
#photo-ready-art:not([hidden]) + .localized-english,
#photo-generating-art:not([hidden]) + .localized-english { animation: reveal-copy .5s ease both; }
html:lang(en) { font-family: "Holiday Futura LT Pro", -apple-system, BlinkMacSystemFont, "Helvetica Neue", sans-serif; font-weight: 300; }
html:lang(en) .entry-title { top: 37.7%; left: 50%; width: 68%; }

html:lang(en) .review-card h2 { width: 219px; max-width: 85%; }
html:lang(en) .review-copy { font-size: 12px; line-height: 1.85; letter-spacing: .005em; }
html:lang(en) .review-copy p + p { margin-top: 14px; }
html:lang(en) .retake-button { width: 18.7%; }
html:lang(en) .about-card > p:not(.about-eyebrow) { line-height: 1.8; }
html:lang(en) .loading-screen p, html:lang(en) .help-card h2 { letter-spacing: .02em; }
html:lang(en) .product-status, html:lang(en) .result-caption { letter-spacing: .02em; }
.product-status { top: max(calc(var(--safe-top) + 13%), 118px); }
@media (max-width: 340px) {
  html:lang(en) .entry-title { width: 74%; }
  html:lang(en) .review-screen { padding-left: 7%; padding-right: 7%; }
  html:lang(en) .about-card { padding-left: 23px; padding-right: 23px; }
  html:lang(en) .solid-button, html:lang(en) .outline-button { font-size: 11px; padding-left: 13px; padding-right: 13px; }
}
@media (max-height: 600px) and (min-aspect-ratio: 3/4) {
  #flow-progress, #photo-progress { top: max(27%, 105px); }
  #flow-instruction-mascara, #flow-instruction-perfume,
  .localized-flow-instruction-mascara, .localized-flow-instruction-perfume { top: max(31%, 120px); }
  #flow-photo-instruction, .localized-flow-photo-instruction { top: max(27%, 105px); }
  #photo-ready-art, .localized-photo-ready-art { top: max(26%, 101px); }
  #photo-generating-art, .localized-photo-generating-art { top: max(31%, 120px); }
  .product-status { top: max(calc(var(--safe-top) + 30%), 116px); }
  html:lang(en) .review-copy { margin: 18px 0; font-size: 11px; line-height: 1.75; }
  html:lang(en) .review-copy p + p { margin-top: 10px; }
}
/* Keep short consent content in the existing vertical scroll area. */
@media (max-height: 450px) {
  #consent-screen .review-card { min-height: 0; justify-content: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  .flow-copy .localized-art:not([hidden]) + .localized-english,
  #photo-ready-art:not([hidden]) + .localized-english,
  #photo-generating-art:not([hidden]) + .localized-english { animation: none; }
}

/* China Figma 513:406 / 513:416: localized outline controls. */
.figma-pill { border: 1px solid rgba(255,255,255,.92); border-radius: 999px; background: transparent; color: #fff; font-family: "Holiday Futura LT Pro", Futura, "Century Gothic", -apple-system, BlinkMacSystemFont, sans-serif; font-weight: 300; letter-spacing: .06em; text-transform: uppercase; line-height: 1.1; text-shadow: 0 1px 4px #0004; }
.figma-pill span { display: block; padding: 0 12px; white-space: nowrap; }
.start-button.figma-pill { aspect-ratio: 336.703 / 110.23; min-height: 44px; font-size: 12px; font-size: clamp(11px, 2.763cqw, 16px); }
.share-button.figma-pill { min-height: 44px; aspect-ratio: 336.703 / 110.23; font-size: 12px; font-size: clamp(11px, 2.763cqw, 15px); background: #15131218; }
/* An unavailable Share control yields its row to Retry in short landscape.
   The full error remains readable below the header; Share stays disabled. */
@media (max-height: 450px) and (min-aspect-ratio: 3/4) {
  .figma-pill span { padding-left: 8px; padding-right: 8px; }
  #export-error:not([hidden]) ~ .photo-actions #share { visibility: hidden; }
  .export-recovery { bottom: calc(var(--safe-bottom) + 74px); }
  #export-error { bottom: calc(var(--safe-bottom) + 150px); left: 5%; width: 90%; line-height: 1.6; }
}

/* Local policy-window preparation. This overlay never owns camera/photo state. */
.policy-link { border: 0; background: transparent; color: inherit; font: inherit; text-decoration: underline; text-underline-offset: .2em; cursor: pointer; padding: .5em 0; }
.policy-sheet { position: absolute; inset: 0; z-index: 60; display: grid; place-items: center; padding: max(18px,var(--safe-top)) max(16px,var(--safe-right)) max(18px,var(--safe-bottom)) max(16px,var(--safe-left)); background: #15131280; color: #24201c; }
.policy-sheet[hidden] { display: none; }
.policy-card { display: flex; flex-direction: column; min-height: 0; width: min(100%,560px); max-height: 82%; max-height: min(82dvh,100%); overflow: hidden; border-radius: 12px; background: #faf9f6; box-shadow: 0 12px 48px #0003; }
.policy-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding: 20px 20px 14px; border-bottom: 1px solid #24201c22; flex: 0 0 auto; }
.policy-header h2 { min-width: 0; flex: 1; margin: 0; font-size: clamp(16px,4vw,22px); line-height: 1.4; word-break: keep-all; overflow-wrap: normal; font-weight: 300; }
.policy-close { border: 1px solid #24201c55; border-radius: 999px; background: transparent; color: inherit; padding: 9px 15px; min-height: 44px; font: inherit; line-height: 1.2; white-space: nowrap; cursor: pointer; }
.policy-body { overflow: auto; min-height: 100px; padding: 4px 20px 20px; font-size: 15px; line-height: 1.75; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.policy-body p { margin: 1em 0; white-space: pre-wrap; overflow-wrap: anywhere; }
#policy-sheet .language-switch { position: absolute; top: max(8px,var(--safe-top)); right: max(8px,var(--safe-right)); }
@media(max-height:450px) { .policy-card { max-height: 100%; } .policy-header { padding-top: 12px; } .policy-body { font-size: 14px; } }


/* Keep the exact Chinese Notice title phrase together, including narrow stages. */
@container (max-width: 260px) { .policy-header { flex-wrap: wrap; } .policy-header h2 { flex-basis: 100%; } .policy-close { margin-left: auto; } }

/* Frozen snapshots already contain the original DG pixels. Hide the live DOM
   mark to keep the result/export composition identical without a second logo. */
body[data-photo-branded="true"] .brand-mark { visibility: hidden; }
