
.words-screen, .daily-screen { box-sizing: border-box; color: #f3efe9; }
.words-screen *, .daily-screen * { box-sizing: border-box; }
.home-hero .hero-image { background-image: url("assets/hero-phone-stand-v5.webp"); }

.words-screen {
  min-height: 100svh;
  padding: clamp(2rem, 6vh, 4.5rem) clamp(1rem, 5vw, 5rem);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: clamp(1.1rem, 3vh, 2rem);
  background: radial-gradient(60% 50% at 50% 55%, rgba(214,162,99,.07), transparent 70%), #0d0c0b;
  border-top: 1px solid rgba(255,255,255,.07);
}
.words-heading { text-align: center; }
.words-heading h2 {
  margin: 0; font-size: clamp(2rem, 4vw, 4rem); font-weight: 350;
  letter-spacing: -.045em; line-height: 1.04;
}
.words-heading h2 strong { font-weight: 720; }

.message-photo {
  position: relative; overflow: hidden; flex: none;
  width: min(100%, 72rem, calc((100svh - 17rem) * 1.777));
  aspect-ratio: 1672 / 941;
  border-radius: .9rem;
  box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 2.4rem 5rem rgba(0,0,0,.55);
  background: #14191d;
}
.message-photo > img { display: block; width: 100%; height: 100%; object-fit: fill; }

.monitor-screen-plane {
  position: absolute; left: 0; top: 0; width: 960px; height: 540px;
  display: grid; place-items: center; overflow: hidden;
  transform-origin: 0 0; visibility: hidden;
  background: radial-gradient(ellipse at 50% 50%, #1a1e23 0%, #111418 70%, #0c0f12 100%);
}
.monitor-screen-plane[data-ready="true"] { visibility: visible; }
.monitor-screen-plane img {
  display: block; width: 97%; height: auto;
  -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 7%, #000 93%, transparent 100%);
          mask-image: linear-gradient(90deg, transparent 0, #000 7%, #000 93%, transparent 100%);
}
.monitor-screen-plane::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(118deg, rgba(255,255,255,.075) 0%, rgba(255,255,255,.02) 28%, transparent 42%),
    radial-gradient(ellipse at 50% 50%, transparent 60%, rgba(0,0,0,.35) 100%);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.04);
}

.words-footnote {
  flex: none; max-width: 44rem; margin: 0;
  color: #aeb4b9; font-size: clamp(.95rem, 1.2vw, 1.1rem); line-height: 1.55; text-align: center;
}

.daily-screen {
  min-height: 100svh;
  padding: clamp(3rem, 8vh, 6rem) clamp(1rem, 5vw, 5rem);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: clamp(2rem, 5vh, 3.5rem);
  background: radial-gradient(60% 50% at 50% 55%, rgba(214,162,99,.07), transparent 70%), #0d0c0b;
}
.daily-heading { text-align: center; }
.daily-heading .story-eyebrow { margin: 0 0 .8rem; color: #8f969c; }
.daily-heading h2 {
  margin: 0; font-size: clamp(2rem, 3.8vw, 3.65rem); font-weight: 680;
  letter-spacing: -.05em; line-height: 1.04;
}
.daily-heading > p:last-child { margin: .75rem 0 0; color: #a3aab0; font-size: clamp(.95rem, 1.2vw, 1.08rem); }

.fm-show { width: min(100%, 72rem); display: flex; flex-direction: column; align-items: center; gap: 1.4rem; }
.fm-show .fm-shot { width: 100%; }

.fm-shot {
  --ratio: 2.8; --x: var(--cx); --y: var(--cy); --w: var(--cw);
  position: relative; overflow: hidden; aspect-ratio: var(--ratio);
  border-radius: 14px; background: #0c0b0a;
  box-shadow: 0 24px 60px rgba(0,0,0,.45);
}
.fm-shot::before {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: radial-gradient(40% 18% at 55% 60%, rgba(240,230,210,.07), transparent 70%);
  mix-blend-mode: screen;
}
.fm-shot::after {
  content: ""; position: absolute; inset: 0; z-index: 3; pointer-events: none;
  background: radial-gradient(ellipse 75% 85% at 50% 42%, transparent 55%, rgba(0,0,0,.5) 100%);
}
.fm-stage {
  position: absolute;
  width: calc(100% * 1672 / var(--w));
  aspect-ratio: 1672 / 941;
  left: calc(-100% * var(--x) / var(--w));
  top: calc(-100% * var(--y) * var(--ratio) / var(--w));
}
.fm-stage > img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
.fm-room { filter: blur(4px) brightness(.95) saturate(1.1); transform: scale(1.02); }
.fm-sharp {
  filter: brightness(1.06);
  clip-path: polygon(27.0% 71.2%, 27.4% 13.0%, 86.8% 7.2%, 86.8% 76.3%, 60.9% 75.5%, 60.9% 81%, 70.1% 84%, 69.5% 87.6%, 44.5% 87.8%, 43.4% 84%, 55.9% 81%, 55.9% 74.2%);
}

.fm-plane {
  position: absolute; left: 0; top: 0; width: 960px; height: 540px;
  transform-origin: 0 0; visibility: hidden; overflow: hidden;
  background: #111316 url("assets/original-black-clock.webp") center / 100% 100% no-repeat;
  -webkit-mask-image: linear-gradient(180deg, rgba(0,0,0,.04) 50%, #000 66%);
          mask-image: linear-gradient(180deg, rgba(0,0,0,.04) 50%, #000 66%);
}
.fm-plane[data-ready="true"] { visibility: visible; }
.fm-plane::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(115deg, rgba(255,255,255,.05) 0%, transparent 32%);
}

.fm-bar {
  position: absolute; z-index: 1; left: 2.4%; width: 91.3%; top: 69.1%; height: 10.2%;
  display: grid; grid-template-columns: repeat(var(--cols, 26), minmax(0, 1fr)); grid-template-rows: 1fr; gap: 3px;
  padding: 4px; border-radius: 8px;
  background: #0d0f12; border: 1px solid rgba(255,255,255,.05);
}
.fm-cell {
  position: relative; min-width: 0; min-height: 0;
  display: grid; place-items: center; overflow: hidden; border-radius: 4px;
  background: linear-gradient(180deg, #24282d 0%, #1c1f23 49.5%, #15181b 50.5%, #191c20 100%);
  box-shadow: inset 0 1px rgba(255,255,255,.05);
  color: #f4efe4;
  font-family: Bahnschrift, "DIN Alternate", "D-DIN", "Arial Narrow", "Segoe UI", sans-serif;
  font-weight: 700; font-size: 30px; line-height: 1;
}
.fm-cell::after {
  content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 1.5px;
  background: #050607;
}
.fm-cell.is-flipping { animation: fm-flip .09s linear; }
@keyframes fm-flip {
  0% { transform: scaleY(1); }
  50% { transform: scaleY(.55); filter: brightness(.7); }
  100% { transform: scaleY(1); }
}

.fm-tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: .6rem; }
.fm-tab {
  padding: .6rem 1.1rem; border: 1px solid rgba(255,255,255,.1); border-radius: 99px;
  background: transparent; color: rgba(243,239,233,.55); cursor: pointer;
  font: inherit; font-size: 15px; font-weight: 600; letter-spacing: -.01em;
  transition: color .2s, background .2s, border-color .2s;
}
.fm-tab:hover { color: #f3efe9; border-color: rgba(255,255,255,.25); }
.fm-tab[aria-selected="true"] { color: #14120f; background: #f1ead9; border-color: #f1ead9; }
.fm-tab:focus-visible { outline: 2px solid #d7bc96; outline-offset: 3px; }
.fm-line { min-height: 1.5em; margin: 0; color: rgba(243,239,233,.66); font-size: 16px; line-height: 1.5; text-align: center; }

@media (max-width: 800px) {
  .words-screen, .daily-screen { min-height: 0; padding: 3.5rem 16px; }
  .words-heading h2 br { display: none; }
  .words-heading h2 strong { display: block; }
  .message-photo { width: 100%; border-radius: .6rem; }
  .fm-show { gap: 1rem; }
  .fm-show .fm-shot { width: calc(100% + 32px); }
  .fm-shot { margin-inline: -16px; border-radius: 0; box-shadow: none; --ratio: 2.46; --x: var(--mcx); --y: var(--mcy); --w: var(--mcw); }
  .fm-room { filter: blur(2.5px) brightness(.95) saturate(1.1); }
  .fm-tabs { flex-wrap: nowrap; gap: .3rem; }
  .fm-tab { padding: .45rem .6rem; font-size: 12.5px; white-space: nowrap; }
  .fm-line { font-size: 14.5px; }
  .fm-copy { padding: 1rem 1.1rem; }
}
.toast:not(.show) { transform: translateY(calc(100% + 2rem)); visibility: hidden; }
@media (prefers-reduced-motion: reduce) {
  .fm-cell.is-flipping { animation: none; }
}

.gallery-screen {
  box-sizing: border-box; color: #f3efe9; background: #000;
  padding: 3.5rem 16px; display: flex; flex-direction: column; gap: 1.4rem;
}
.gallery-screen * { box-sizing: border-box; }
.gallery-screen { position: relative; isolation: isolate; overflow: hidden; }
.gal-ambient {
  position: absolute; inset: -12%; z-index: -2; pointer-events: none;
  background: center / cover no-repeat; filter: blur(24px); opacity: 0;
  transition: opacity .45s ease;
}
.gal-ambient.is-front { opacity: .85; }
.gallery-screen::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse 75% 80% at 62% 44%, rgba(0,0,0,0) 0%, rgba(0,0,0,.35) 50%, #000 92%);
}
.gal-top { display: flex; flex-direction: column; gap: 1.2rem; }
.gallery-heading { text-align: left; }
.gallery-heading h2 {
  margin: 0; font-family: inherit; font-size: clamp(2.2rem, 7vw, 3rem); font-weight: 720;
  letter-spacing: -.05em; line-height: 1.02;
}
.gallery-heading .gal-all { width: auto; min-height: 3rem; margin-top: 1.6rem; padding: .9rem 1.6rem; font-size: .8rem; }

.gal-frame {
  position: relative; width: 100%; aspect-ratio: 16 / 9; overflow: hidden;
  border: 1px solid rgba(255,255,255,.14); border-radius: 14px; background: #080808;
  box-shadow: 0 1.5rem 3.5rem rgba(0,0,0,.6);
}
.gal-frame > img {
  position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity .35s ease;
}
.gal-frame > img.is-front { opacity: 1; z-index: 1; }
.gal-caption {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 4;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 2.2rem 1rem .8rem; background: linear-gradient(to top, rgba(0,0,0,.78), rgba(0,0,0,0));
}
.gal-caption h3 { margin: 0; font-family: inherit; font-size: 1.05rem; font-weight: 650; letter-spacing: -.01em; }
.gal-caption h3 a { color: inherit; text-decoration: none; }
.gal-caption h3 a[href]:hover { text-decoration: underline; text-underline-offset: .2em; }
.gal-caption h3 { flex: none; }
.gal-included {
  margin-right: auto; padding: .22rem .6rem; border-radius: 99px; background: #f1ead9; color: #14120f;
  font-size: .7rem; font-weight: 750; letter-spacing: .08em; text-transform: uppercase;
}
.gal-included[hidden] { display: none; }
.gal-controls { display: flex; align-items: center; gap: .6rem; flex: none; }
.gal-count { font-size: .8rem; letter-spacing: .08em; font-variant-numeric: tabular-nums; color: rgba(243,239,233,.8); }
.gal-count strong { color: #f3efe9; }
.gal-nav {
  width: 2.5rem; height: 2.5rem; display: grid; place-items: center; padding: 0; cursor: pointer;
  border: 0; border-radius: 50%; background: rgba(243,239,233,.94); color: #111;
  box-shadow: 0 6px 18px rgba(0,0,0,.45); transition: transform .2s, background .2s;
}
.gal-nav:hover { background: #fff; transform: scale(1.07); }
.gal-nav:focus-visible, .gal-thumb:focus-visible { outline: 2px solid #d7bc96; outline-offset: 3px; }
.gal-nav svg { width: 1.15rem; height: 1.15rem; fill: none; stroke: currentColor; stroke-width: 2.4; }

.gal-more {
  position: absolute; inset: 0; z-index: 3; display: grid; place-content: center; justify-items: center;
  gap: 1.2rem; background: rgba(0,0,0,.6); text-align: center;
}
.gal-more[hidden] { display: none; }
.gal-more-title { margin: 0; color: #f3efe9; font-size: clamp(1.6rem, 3vw, 3rem); font-weight: 720; letter-spacing: -.035em; }
.gal-more .gal-all { width: auto; min-height: 3rem; padding: .9rem 1.6rem; font-size: .8rem; }

.gal-thumbs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.gal-thumb {
  display: flex; flex-direction: column; gap: .35rem; min-width: 0; padding: 0; cursor: pointer;
  border: 0; background: none; color: #aeb4b9; font: inherit; text-align: left;
}
.gal-thumb-shot {
  position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; overflow: hidden;
  border-radius: 7px; border: 1px solid rgba(255,255,255,.1); background: #111;
}
.gal-thumb-shot img { display: block; width: 100%; height: 100%; object-fit: cover; opacity: .72; transition: opacity .2s, transform .25s; }
.gal-thumb:hover .gal-thumb-shot img, .gal-thumb[aria-current="true"] .gal-thumb-shot img { opacity: 1; }
.gal-thumb:hover .gal-thumb-shot img { transform: scale(1.05); }
.gal-thumb[aria-current="true"] .gal-thumb-shot { outline: 2px solid #f1ead9; outline-offset: 2px; }
.gal-thumb[aria-current="true"] { color: #f3efe9; }
.gal-thumb-name { display: none; font-size: .78rem; font-weight: 600; line-height: 1.25; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gal-thumb-plus {
  position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55);
  color: #fff; font-size: 1.4rem; font-weight: 700;
}

@media (min-width: 801px) {
  .gallery-screen { padding: clamp(3rem, 7vh, 5rem) clamp(1.5rem, 4vw, 4.5rem); }
  .gal-thumbs { grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 10px; }
  .gal-thumb-name { display: block; }
  .gal-caption { padding: 3rem 1.4rem 1.1rem; }
  .gal-caption h3 { font-size: clamp(1.1rem, 1.5vw, 1.45rem); }
  .gal-nav { width: 2.9rem; height: 2.9rem; }
}

@media (min-width: 901px) and (min-aspect-ratio: 5/4) and (min-height: 600px) {
  .gallery-screen {
    --thumbs: clamp(88px, 13vh, 132px);
    height: 100svh; min-height: 0; overflow: hidden; justify-content: center;
    padding: clamp(1.4rem, 4vh, 2.8rem) clamp(1.5rem, 4vw, 4.5rem); gap: clamp(1rem, 3vh, 2rem);
  }
  .gal-top { flex-direction: row; align-items: center; gap: clamp(1.5rem, 4vw, 4.5rem); min-height: 0; }
  .gallery-heading { flex: 1 1 0; min-width: 16rem; }
  .gallery-heading h2 { font-size: clamp(2.6rem, 4.6vw, 5.2rem); }
  .gal-frame { flex: none; width: min(64vw, calc((100svh - var(--thumbs) - 7rem) * 16 / 9)); }
}

@media (prefers-reduced-motion: reduce) { .gal-frame > img, .gal-thumb img, .gal-nav, .gal-ambient { transition: none; } }
