/* My Event Captured — Advent Calendar front and mechanism. Brand palette, no third-party assets. */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --cream: #F7F3EA;
  --green: #1E3B2D;
  --green-deep: #152A1F;
  --gold: #C9A45C;
  --gold-soft: #E4CE9E;
  --sage: #C3D9C7;
  --sage-deep: #9FC0A6;
  --berry: #B23A3A;
  --ink: #22342A;
  --ink-soft: #5C6E62;
  --white: #FFFDF8;

  --font-display: Georgia, 'Times New Roman', serif;
  --font-body: -apple-system, 'Segoe UI', 'Helvetica Neue', Arial, sans-serif;

  --radius-md: 0.6rem;
  --radius-lg: 1rem;
  --shadow-md: 0 4px 14px rgba(30, 59, 45, 0.16);
  --shadow-lg: 0 18px 48px rgba(21, 42, 31, 0.35);
  --tr: 180ms cubic-bezier(0.16, 1, 0.3, 1);
}

html { -webkit-text-size-adjust: none; text-size-adjust: none; scroll-behavior: smooth; }
body {
  min-height: 100dvh;
  font-family: var(--font-body);
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  background-image:
    radial-gradient(circle at 12% 18%, rgba(195, 217, 199, 0.55) 0, transparent 26%),
    radial-gradient(circle at 88% 8%, rgba(201, 164, 92, 0.22) 0, transparent 22%),
    radial-gradient(circle at 50% 108%, rgba(30, 59, 45, 0.10) 0, transparent 40%);
}

button { cursor: pointer; background: none; border: none; font: inherit; color: inherit; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: var(--radius-md); }
a { color: var(--green); }

/* ---------- Header ---------- */
.site-header {
  max-width: 1100px;
  margin: 0 auto;
  padding: clamp(1.25rem, 3vw, 2.5rem) clamp(1rem, 3vw, 2rem) 0.5rem;
  text-align: center;
}
.brand-row { display: inline-flex; align-items: center; gap: 0.75rem; text-decoration: none; }
.mec-logo { width: 44px; height: 44px; flex: none; }
.brand-words { display: flex; flex-direction: column; text-align: left; }
.brand-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  letter-spacing: 0.02em;
  color: var(--green);
  font-weight: 700;
}
.brand-tag { font-size: 0.75rem; color: var(--ink-soft); letter-spacing: 0.06em; text-transform: uppercase; }
.page-title {
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 6vw, 3.6rem);
  color: var(--green);
  margin-top: 0.75rem;
  line-height: 1.1;
}
.page-sub { color: var(--ink-soft); font-size: clamp(0.95rem, 1.6vw, 1.1rem); max-width: 46ch; margin: 0.4rem auto 0; }

/* ---------- Return to the main page ---------- */
.return-row { margin: 1.1rem auto 0; }
.return-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1.3rem;
  background: var(--green);
  color: var(--cream);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  border-radius: 999px;
  box-shadow: var(--shadow-md);
  transition: background var(--tr), transform var(--tr);
}
.return-link:hover, .return-link:focus-visible { background: var(--green-deep); transform: translateY(-2px); }
.return-arrow { font-size: 1.1em; line-height: 1; }

/* ---------- Status bar ---------- */
.status-bar {
  max-width: 620px;
  margin: 1.1rem auto 0;
  padding: 0.65rem 1.1rem;
  background: var(--white);
  border: 1px solid var(--sage-deep);
  border-radius: 999px;
  text-align: center;
  font-size: 0.95rem;
  color: var(--green);
  box-shadow: var(--shadow-md);
}
.status-bar .today-door { font-weight: 700; color: var(--berry); }

/* ---------- Board ---------- */
.board-wrap { max-width: 1100px; margin: 0 auto; padding: clamp(1rem, 3vw, 2rem); }
.board {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(0.5rem, 1.4vw, 0.9rem);
  background: var(--green);
  background-image: linear-gradient(rgba(255, 253, 248, 0.04) 1px, transparent 1px);
  border: 10px solid var(--green-deep);
  border-radius: var(--radius-lg);
  padding: clamp(0.7rem, 1.8vw, 1.3rem);
  box-shadow: var(--shadow-lg);
}
/* MEC-089: the locked board stays completely out of sight until 00:00:01 on
   1 December. The .board display rule above would otherwise override the
   HTML hidden attribute, so the attribute is restated with equal weight. */
.board[hidden] { display: none; }
@media (min-width: 560px) { .board { grid-template-columns: repeat(6, 1fr); } }
@media (min-width: 900px) { .board { grid-template-columns: repeat(8, 1fr); } }

/* ---------- Countdown to 1 December (MEC-089) ---------- */
.countdown-wrap {
  border: 10px solid var(--green-deep);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.countdown-scene { position: relative; aspect-ratio: 16 / 9; min-height: 340px; }
.countdown-photo {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 42%;
  display: block;
}
.countdown-shade {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse at 50% 44%, rgba(21, 42, 31, 0) 0%, rgba(21, 42, 31, 0.30) 58%, rgba(21, 42, 31, 0.62) 100%),
    linear-gradient(180deg, rgba(21, 42, 31, 0.44) 0%, rgba(21, 42, 31, 0.10) 40%, rgba(21, 42, 31, 0.58) 100%);
}
.countdown-clock {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: clamp(0.5rem, 1.6vh, 1rem);
  padding: clamp(1rem, 4vw, 2.5rem);
  text-align: center;
}
.countdown-kicker {
  color: var(--gold-soft);
  font-size: clamp(0.7rem, 1.4vw, 0.85rem);
  font-weight: 600;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.countdown-title {
  font-family: var(--font-display);
  color: var(--white);
  font-size: clamp(1.35rem, 3.6vw, 2.4rem);
  line-height: 1.15;
  text-shadow: 0 2px 14px rgba(21, 42, 31, 0.65);
}
.countdown-digits {
  display: flex; align-items: center; justify-content: center;
  gap: clamp(0.4rem, 1.6vw, 1.1rem);
  flex-wrap: wrap;
}
.cd-unit {
  display: flex; flex-direction: column; align-items: center; gap: 0.28rem;
  min-width: clamp(3.6rem, 9vw, 6.2rem);
  padding: clamp(0.5rem, 1.4vw, 0.95rem) clamp(0.5rem, 1.2vw, 0.9rem);
  background: rgba(21, 42, 31, 0.78);
  border: 1px solid var(--gold);
  border-radius: var(--radius-md);
  box-shadow: 0 6px 18px rgba(10, 22, 15, 0.38);
}
.cd-num {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 5.6vw, 3.6rem);
  line-height: 1;
  color: var(--white);
  font-variant-numeric: tabular-nums;
}
.cd-label {
  color: var(--gold-soft);
  font-size: clamp(0.62rem, 1.1vw, 0.78rem);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
}
.cd-sep {
  color: var(--gold);
  font-size: clamp(1.1rem, 2.4vw, 1.7rem);
  line-height: 1;
  animation: cd-twinkle 2.6s ease-in-out infinite;
}
.cd-sep:nth-of-type(2) { animation-delay: -0.9s; }
.cd-sep:nth-of-type(3) { animation-delay: -1.7s; }
@keyframes cd-twinkle {
  0%, 100% { opacity: 0.55; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.14); }
}
.countdown-when {
  color: var(--sage);
  font-size: clamp(0.78rem, 1.5vw, 0.95rem);
  max-width: 46rem;
}
@media (max-width: 700px) {
  .countdown-scene { aspect-ratio: auto; min-height: 0; }
  /* Small screens drop the fixed aspect ratio, so the absolutely positioned
     clock would leave the scene with no height. Let the clock take part in
     the flow instead (relative keeps it in flow AND paints it above the
     absolutely positioned photo and shade, which a static clock would sit
     beneath), so the scene grows to fit the clock's content. */
  .countdown-clock { position: relative; inset: auto; }
  .countdown-digits { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; max-width: 21rem; }
  .cd-sep { display: none; }
}
@media (prefers-reduced-motion: reduce) { .cd-sep { animation: none; } }
@media print { .countdown-wrap { display: none; } }

/* ---------- Festive calendar frame (gold stars, MEC-088) ---------- */
.board-frame { position: relative; padding: clamp(34px, 3.6vw, 40px); }
.frame-garland, .frame-side { position: absolute; pointer-events: none; }
.frame-garland { background-repeat: repeat-x; background-size: auto 100%; }
.frame-side { background-repeat: repeat-y; background-size: 100% auto; width: 30px; }
.frame-top { top: 0; left: 34px; right: 34px; height: 30px; background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22360%22%20height%3D%2230%22%20viewBox%3D%220%200%20360%2030%22%3E%3Crect%20width%3D%22360%22%20height%3D%2230%22%20fill%3D%22%23152A1F%22%2F%3E%3Crect%20width%3D%22360%22%20height%3D%221.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Crect%20y%3D%2228.4%22%20width%3D%22360%22%20height%3D%221.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2226.0%208.7%2027.7%2013.2%2032.4%2013.4%2028.7%2016.3%2029.9%2020.9%2026.0%2018.2%2022.1%2020.9%2023.3%2016.3%2019.6%2013.4%2024.3%2013.2%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2259.6%208.4%2060.8%2011.7%2064.4%2011.9%2061.6%2014.1%2062.6%2017.5%2059.6%2015.5%2056.6%2017.5%2057.6%2014.1%2054.8%2011.9%2058.3%2011.7%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2286.1%2014.7%2087.2%2017.6%2090.2%2017.7%2087.8%2019.6%2088.6%2022.4%2086.1%2020.8%2083.6%2022.4%2084.4%2019.6%2082.1%2017.7%2085.1%2017.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%22122.8%2012.1%20124.4%2016.3%20128.9%2016.5%20125.4%2019.3%20126.6%2023.7%20122.8%2021.2%20119.1%2023.7%20120.3%2019.3%20116.8%2016.5%20121.3%2016.3%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22150.1%2013.5%20152.0%2018.4%20157.2%2018.6%20153.1%2021.9%20154.5%2027.0%20150.1%2024.1%20145.7%2027.0%20147.2%2021.9%20143.0%2018.6%20148.3%2018.4%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22180.8%206.5%20182.2%2010.2%20186.1%2010.4%20183.0%2012.9%20184.1%2016.7%20180.8%2014.5%20177.5%2016.7%20178.6%2012.9%20175.5%2010.4%20179.4%2010.2%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22217.0%206.5%20218.2%209.5%20221.4%209.7%20218.9%2011.7%20219.8%2014.9%20217.0%2013.1%20214.3%2014.9%20215.2%2011.7%20212.6%209.7%20215.9%209.5%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22253.1%206.5%20254.2%209.2%20257.1%209.3%20254.8%2011.2%20255.6%2014.0%20253.1%2012.4%20250.7%2014.0%20251.5%2011.2%20249.2%209.3%20252.1%209.2%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22283.9%2012.2%20285.5%2016.6%20290.3%2016.8%20286.5%2019.8%20287.8%2024.4%20283.9%2021.7%20279.9%2024.4%20281.2%2019.8%20277.5%2016.8%20282.2%2016.6%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22316.4%207.1%20317.9%2011.0%20322.1%2011.2%20318.8%2013.8%20319.9%2017.9%20316.4%2015.6%20312.9%2017.9%20314.0%2013.8%20310.7%2011.2%20314.9%2011.0%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M38.6%2016.7%20Q39.2%2019.0%2041.6%2019.7%20Q39.2%2020.3%2038.6%2022.7%20Q37.9%2020.3%2035.6%2019.7%20Q37.9%2019.0%2038.6%2016.7Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M132.8%207.0%20Q133.5%209.3%20135.7%209.9%20Q133.5%2010.5%20132.8%2012.8%20Q132.2%2010.5%20129.9%209.9%20Q132.2%209.3%20132.8%207.0Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M227.3%207.6%20Q228.0%2010.1%20230.5%2010.8%20Q228.0%2011.5%20227.3%2014.0%20Q226.6%2011.5%20224.0%2010.8%20Q226.6%2010.1%20227.3%207.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M326.9%2014.6%20Q327.4%2016.5%20329.3%2017.0%20Q327.4%2017.5%20326.9%2019.4%20Q326.4%2017.5%20324.5%2017.0%20Q326.4%2016.5%20326.9%2014.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3C%2Fsvg%3E"); }
.frame-bottom { bottom: 0; left: 34px; right: 34px; height: 30px; background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22360%22%20height%3D%2230%22%20viewBox%3D%220%200%20360%2030%22%3E%3Crect%20width%3D%22360%22%20height%3D%2230%22%20fill%3D%22%23152A1F%22%2F%3E%3Crect%20width%3D%22360%22%20height%3D%221.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Crect%20y%3D%2228.4%22%20width%3D%22360%22%20height%3D%221.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2226.0%2015.1%2027.4%2018.7%2031.3%2018.9%2028.2%2021.3%2029.3%2025.1%2026.0%2022.9%2022.7%2025.1%2023.8%2021.3%2020.7%2018.9%2024.6%2018.7%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2259.6%208.9%2060.7%2011.7%2063.7%2011.8%2061.3%2013.7%2062.1%2016.6%2059.6%2014.9%2057.1%2016.6%2057.9%2013.7%2055.5%2011.8%2058.5%2011.7%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2292.5%204.3%2093.7%207.6%2097.2%207.7%2094.5%209.9%2095.4%2013.4%2092.5%2011.4%2089.5%2013.4%2090.4%209.9%2087.7%207.7%2091.2%207.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%22123.6%208.9%20124.9%2012.4%20128.6%2012.6%20125.7%2014.9%20126.7%2018.5%20123.6%2016.4%20120.5%2018.5%20121.5%2014.9%20118.6%2012.6%20122.3%2012.4%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22165.2%2010.1%20167.1%2015.1%20172.4%2015.3%20168.2%2018.6%20169.6%2023.7%20165.2%2020.8%20160.8%2023.7%20162.2%2018.6%20158.1%2015.3%20163.4%2015.1%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%22206.5%2014.8%20207.7%2018.1%20211.3%2018.3%20208.5%2020.5%20209.4%2023.9%20206.5%2022.0%20203.5%2023.9%20204.4%2020.5%20201.6%2018.3%20205.2%2018.1%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%22244.9%207.8%20246.7%2012.7%20251.9%2012.9%20247.8%2016.2%20249.2%2021.2%20244.9%2018.3%20240.5%2021.2%20241.9%2016.2%20237.8%2012.9%20243.0%2012.7%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%22275.1%2010.7%20276.8%2015.1%20281.5%2015.3%20277.8%2018.2%20279.0%2022.7%20275.1%2020.1%20271.2%2022.7%20272.4%2018.2%20268.8%2015.3%20273.5%2015.1%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%22305.2%2016.3%20306.2%2019.2%20309.3%2019.3%20306.9%2021.2%20307.7%2024.1%20305.2%2022.4%20302.6%2024.1%20303.4%2021.2%20301.1%2019.3%20304.1%2019.2%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%22336.5%2011.5%20338.2%2016.2%20343.3%2016.4%20339.3%2019.5%20340.7%2024.4%20336.5%2021.6%20332.3%2024.4%20333.7%2019.5%20329.7%2016.4%20334.7%2016.2%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpath%20d%3D%22M36.3%205.7%20Q37.0%207.9%2039.2%208.5%20Q37.0%209.2%2036.3%2011.4%20Q35.7%209.2%2033.5%208.5%20Q35.7%207.9%2036.3%205.7Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M138.5%2015.4%20Q139.1%2017.6%20141.3%2018.2%20Q139.1%2018.8%20138.5%2021.0%20Q137.9%2018.8%20135.7%2018.2%20Q137.9%2017.6%20138.5%2015.4Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M255.6%208.8%20Q256.3%2011.0%20258.5%2011.7%20Q256.3%2012.3%20255.6%2014.5%20Q255.0%2012.3%20252.8%2011.7%20Q255.0%2011.0%20255.6%208.8Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M351.2%208.5%20Q351.7%2010.3%20353.4%2010.7%20Q351.7%2011.2%20351.2%2013.0%20Q350.7%2011.2%20349.0%2010.7%20Q350.7%2010.3%20351.2%208.5Z%22%20fill%3D%22%23DCC084%22%2F%3E%3C%2Fsvg%3E"); }
.frame-left { left: 0; top: 34px; bottom: 34px; background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2230%22%20height%3D%22360%22%20viewBox%3D%220%200%2030%20360%22%3E%3Crect%20width%3D%2230%22%20height%3D%22360%22%20fill%3D%22%23152A1F%22%2F%3E%3Crect%20width%3D%221.6%22%20height%3D%22360%22%20fill%3D%22%23C9A45C%22%2F%3E%3Crect%20x%3D%2228.4%22%20width%3D%221.6%22%20height%3D%22360%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2218.7%2019.3%2020.3%2023.7%2025.1%2023.9%2021.3%2026.9%2022.6%2031.5%2018.7%2028.8%2014.7%2031.5%2016.0%2026.9%2012.2%2023.9%2017.0%2023.7%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2216.9%2053.3%2017.8%2055.8%2020.5%2055.9%2018.4%2057.6%2019.1%2060.2%2016.9%2058.7%2014.6%2060.2%2015.3%2057.6%2013.2%2055.9%2015.9%2055.8%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2212.9%2080.0%2013.9%2082.6%2016.8%2082.8%2014.5%2084.6%2015.3%2087.3%2012.9%2085.7%2010.5%2087.3%2011.3%2084.6%209.0%2082.8%2011.9%2082.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2215.1%20119.0%2016.4%20122.6%2020.2%20122.8%2017.2%20125.2%2018.3%20128.8%2015.1%20126.7%2011.9%20128.8%2012.9%20125.2%209.9%20122.8%2013.7%20122.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%229.2%20157.7%2010.8%20162.0%2015.3%20162.2%2011.7%20165.0%2013.0%20169.4%209.2%20166.9%205.4%20169.4%206.6%20165.0%203.0%20162.2%207.6%20162.0%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%229.3%20197.1%2010.7%20200.9%2014.7%20201.0%2011.6%20203.5%2012.6%20207.4%209.3%20205.2%206.0%20207.4%207.0%20203.5%203.9%20201.0%207.9%20200.9%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2216.8%20227.5%2018.3%20231.6%2022.7%20231.8%2019.3%20234.6%2020.5%20238.9%2016.8%20236.4%2013.0%20238.9%2014.2%20234.6%2010.8%20231.8%2015.2%20231.6%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%229.9%20261.7%2011.6%20266.2%2016.4%20266.4%2012.6%20269.4%2013.9%20274.0%209.9%20271.4%205.9%20274.0%207.2%20269.4%203.4%20266.4%208.2%20266.2%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2212.6%20297.3%2013.6%20300.1%2016.6%20300.2%2014.3%20302.0%2015.0%20304.9%2012.6%20303.3%2010.1%20304.9%2010.9%20302.0%208.6%20300.2%2011.6%20300.1%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2220.3%20327.3%2021.7%20331.1%2025.7%20331.2%2022.6%20333.8%2023.6%20337.7%2020.3%20335.4%2016.9%20337.7%2018.0%20333.8%2014.8%20331.2%2018.8%20331.1%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M18.0%2039.0%20Q18.5%2040.9%2020.4%2041.4%20Q18.5%2041.9%2018.0%2043.8%20Q17.4%2041.9%2015.6%2041.4%20Q17.4%2040.9%2018.0%2039.0Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M20.2%20137.6%20Q20.7%20139.5%2022.7%20140.1%20Q20.7%20140.6%2020.2%20142.6%20Q19.6%20140.6%2017.7%20140.1%20Q19.6%20139.5%2020.2%20137.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M11.4%20242.3%20Q11.9%20244.2%2013.8%20244.8%20Q11.9%20245.3%2011.4%20247.2%20Q10.9%20245.3%209.0%20244.8%20Q10.9%20244.2%2011.4%20242.3Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M11.0%20342.0%20Q11.6%20344.1%2013.7%20344.7%20Q11.6%20345.3%2011.0%20347.5%20Q10.4%20345.3%208.3%20344.7%20Q10.4%20344.1%2011.0%20342.0Z%22%20fill%3D%22%23DCC084%22%2F%3E%3C%2Fsvg%3E"); }
.frame-right { right: 0; top: 34px; bottom: 34px; background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2230%22%20height%3D%22360%22%20viewBox%3D%220%200%2030%20360%22%3E%3Crect%20width%3D%2230%22%20height%3D%22360%22%20fill%3D%22%23152A1F%22%2F%3E%3Crect%20width%3D%221.6%22%20height%3D%22360%22%20fill%3D%22%23C9A45C%22%2F%3E%3Crect%20x%3D%2228.4%22%20width%3D%221.6%22%20height%3D%22360%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2218.7%2019.3%2020.3%2023.7%2025.1%2023.9%2021.3%2026.9%2022.6%2031.5%2018.7%2028.8%2014.7%2031.5%2016.0%2026.9%2012.2%2023.9%2017.0%2023.7%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2216.9%2053.3%2017.8%2055.8%2020.5%2055.9%2018.4%2057.6%2019.1%2060.2%2016.9%2058.7%2014.6%2060.2%2015.3%2057.6%2013.2%2055.9%2015.9%2055.8%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2212.9%2080.0%2013.9%2082.6%2016.8%2082.8%2014.5%2084.6%2015.3%2087.3%2012.9%2085.7%2010.5%2087.3%2011.3%2084.6%209.0%2082.8%2011.9%2082.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2215.1%20119.0%2016.4%20122.6%2020.2%20122.8%2017.2%20125.2%2018.3%20128.8%2015.1%20126.7%2011.9%20128.8%2012.9%20125.2%209.9%20122.8%2013.7%20122.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%229.2%20157.7%2010.8%20162.0%2015.3%20162.2%2011.7%20165.0%2013.0%20169.4%209.2%20166.9%205.4%20169.4%206.6%20165.0%203.0%20162.2%207.6%20162.0%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%229.3%20197.1%2010.7%20200.9%2014.7%20201.0%2011.6%20203.5%2012.6%20207.4%209.3%20205.2%206.0%20207.4%207.0%20203.5%203.9%20201.0%207.9%20200.9%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2216.8%20227.5%2018.3%20231.6%2022.7%20231.8%2019.3%20234.6%2020.5%20238.9%2016.8%20236.4%2013.0%20238.9%2014.2%20234.6%2010.8%20231.8%2015.2%20231.6%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%229.9%20261.7%2011.6%20266.2%2016.4%20266.4%2012.6%20269.4%2013.9%20274.0%209.9%20271.4%205.9%20274.0%207.2%20269.4%203.4%20266.4%208.2%20266.2%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpolygon%20points%3D%2212.6%20297.3%2013.6%20300.1%2016.6%20300.2%2014.3%20302.0%2015.0%20304.9%2012.6%20303.3%2010.1%20304.9%2010.9%20302.0%208.6%20300.2%2011.6%20300.1%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpolygon%20points%3D%2220.3%20327.3%2021.7%20331.1%2025.7%20331.2%2022.6%20333.8%2023.6%20337.7%2020.3%20335.4%2016.9%20337.7%2018.0%20333.8%2014.8%20331.2%2018.8%20331.1%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M18.0%2039.0%20Q18.5%2040.9%2020.4%2041.4%20Q18.5%2041.9%2018.0%2043.8%20Q17.4%2041.9%2015.6%2041.4%20Q17.4%2040.9%2018.0%2039.0Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M20.2%20137.6%20Q20.7%20139.5%2022.7%20140.1%20Q20.7%20140.6%2020.2%20142.6%20Q19.6%20140.6%2017.7%20140.1%20Q19.6%20139.5%2020.2%20137.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M11.4%20242.3%20Q11.9%20244.2%2013.8%20244.8%20Q11.9%20245.3%2011.4%20247.2%20Q10.9%20245.3%209.0%20244.8%20Q10.9%20244.2%2011.4%20242.3Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M11.0%20342.0%20Q11.6%20344.1%2013.7%20344.7%20Q11.6%20345.3%2011.0%20347.5%20Q10.4%20345.3%208.3%20344.7%20Q10.4%20344.1%2011.0%20342.0Z%22%20fill%3D%22%23DCC084%22%2F%3E%3C%2Fsvg%3E"); }
/* Subtle shimmer: brighter stars laid over the same positions, gently twinkling. */
.frame-garland::after, .frame-side::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-repeat: inherit; background-size: inherit; opacity: 0;
  animation: mec088-shimmer 5.2s ease-in-out infinite;
}
.frame-top::after { background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22360%22%20height%3D%2230%22%20viewBox%3D%220%200%20360%2030%22%3E%3Cpolygon%20points%3D%22316.4%207.1%20317.9%2011.0%20322.1%2011.2%20318.8%2013.8%20319.9%2017.9%20316.4%2015.6%20312.9%2017.9%20314.0%2013.8%20310.7%2011.2%20314.9%2011.0%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%22253.1%206.5%20254.2%209.2%20257.1%209.3%20254.8%2011.2%20255.6%2014.0%20253.1%2012.4%20250.7%2014.0%20251.5%2011.2%20249.2%209.3%20252.1%209.2%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%2259.6%208.4%2060.8%2011.7%2064.4%2011.9%2061.6%2014.1%2062.6%2017.5%2059.6%2015.5%2056.6%2017.5%2057.6%2014.1%2054.8%2011.9%2058.3%2011.7%22%20fill%3D%22%23F1DFAE%22%2F%3E%3C%2Fsvg%3E"); }
.frame-bottom::after { background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22360%22%20height%3D%2230%22%20viewBox%3D%220%200%20360%2030%22%3E%3Cpolygon%20points%3D%22275.1%2010.7%20276.8%2015.1%20281.5%2015.3%20277.8%2018.2%20279.0%2022.7%20275.1%2020.1%20271.2%2022.7%20272.4%2018.2%20268.8%2015.3%20273.5%2015.1%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%22336.5%2011.5%20338.2%2016.2%20343.3%2016.4%20339.3%2019.5%20340.7%2024.4%20336.5%2021.6%20332.3%2024.4%20333.7%2019.5%20329.7%2016.4%20334.7%2016.2%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%22165.2%2010.1%20167.1%2015.1%20172.4%2015.3%20168.2%2018.6%20169.6%2023.7%20165.2%2020.8%20160.8%2023.7%20162.2%2018.6%20158.1%2015.3%20163.4%2015.1%22%20fill%3D%22%23F1DFAE%22%2F%3E%3C%2Fsvg%3E"); animation-delay: -1.8s; animation-duration: 6.1s; }
.frame-left::after { background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2230%22%20height%3D%22360%22%20viewBox%3D%220%200%2030%20360%22%3E%3Cpolygon%20points%3D%229.2%20157.7%2010.8%20162.0%2015.3%20162.2%2011.7%20165.0%2013.0%20169.4%209.2%20166.9%205.4%20169.4%206.6%20165.0%203.0%20162.2%207.6%20162.0%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%229.9%20261.7%2011.6%20266.2%2016.4%20266.4%2012.6%20269.4%2013.9%20274.0%209.9%20271.4%205.9%20274.0%207.2%20269.4%203.4%20266.4%208.2%20266.2%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%2216.8%20227.5%2018.3%20231.6%2022.7%20231.8%2019.3%20234.6%2020.5%20238.9%2016.8%20236.4%2013.0%20238.9%2014.2%20234.6%2010.8%20231.8%2015.2%20231.6%22%20fill%3D%22%23F1DFAE%22%2F%3E%3C%2Fsvg%3E"); animation-delay: -3.1s; animation-duration: 5.6s; }
.frame-right::after { background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2230%22%20height%3D%22360%22%20viewBox%3D%220%200%2030%20360%22%3E%3Cpolygon%20points%3D%229.2%20157.7%2010.8%20162.0%2015.3%20162.2%2011.7%20165.0%2013.0%20169.4%209.2%20166.9%205.4%20169.4%206.6%20165.0%203.0%20162.2%207.6%20162.0%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%229.9%20261.7%2011.6%20266.2%2016.4%20266.4%2012.6%20269.4%2013.9%20274.0%209.9%20271.4%205.9%20274.0%207.2%20269.4%203.4%20266.4%208.2%20266.2%22%20fill%3D%22%23F1DFAE%22%2F%3E%3Cpolygon%20points%3D%2216.8%20227.5%2018.3%20231.6%2022.7%20231.8%2019.3%20234.6%2020.5%20238.9%2016.8%20236.4%2013.0%20238.9%2014.2%20234.6%2010.8%20231.8%2015.2%20231.6%22%20fill%3D%22%23F1DFAE%22%2F%3E%3C%2Fsvg%3E"); animation-delay: -0.9s; animation-duration: 6.7s; }
@keyframes mec088-shimmer { 0%, 100% { opacity: 0.12; } 50% { opacity: 0.85; } }
@media (prefers-reduced-motion: reduce) {
  .frame-garland::after, .frame-side::after, .frame-corner::after { animation: none; opacity: 0.45; }
}
.frame-corner {
  position: absolute; width: 64px; height: 64px; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2264%22%20height%3D%2264%22%20viewBox%3D%220%200%2064%2064%22%3E%3Ccircle%20cx%3D%2232%22%20cy%3D%2232%22%20r%3D%2219%22%20fill%3D%22%23152A1F%22%20stroke%3D%22%23C9A45C%22%20stroke-width%3D%221.4%22%2F%3E%3Cpolygon%20points%3D%2232.0%2019.0%2035.2%2027.6%2044.4%2028.0%2037.2%2033.7%2039.6%2042.5%2032.0%2037.5%2024.4%2042.5%2026.8%2033.7%2019.6%2028.0%2028.8%2027.6%22%20fill%3D%22%23C9A45C%22%2F%3E%3Cpath%20d%3D%22M20.0%2016.6%20Q20.7%2019.3%2023.4%2020.0%20Q20.7%2020.7%2020.0%2023.4%20Q19.3%2020.7%2016.6%2020.0%20Q19.3%2019.3%2020.0%2016.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M44.0%2016.6%20Q44.7%2019.3%2047.4%2020.0%20Q44.7%2020.7%2044.0%2023.4%20Q43.3%2020.7%2040.6%2020.0%20Q43.3%2019.3%2044.0%2016.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M20.0%2040.6%20Q20.7%2043.3%2023.4%2044.0%20Q20.7%2044.7%2020.0%2047.4%20Q19.3%2044.7%2016.6%2044.0%20Q19.3%2043.3%2020.0%2040.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3Cpath%20d%3D%22M44.0%2040.6%20Q44.7%2043.3%2047.4%2044.0%20Q44.7%2044.7%2044.0%2047.4%20Q43.3%2044.7%2040.6%2044.0%20Q43.3%2043.3%2044.0%2040.6Z%22%20fill%3D%22%23DCC084%22%2F%3E%3C%2Fsvg%3E"); background-size: 100% 100%;
}
.frame-corner::after {
  content: ""; position: absolute; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%2264%22%20height%3D%2264%22%20viewBox%3D%220%200%2064%2064%22%3E%3Ccircle%20cx%3D%2232%22%20cy%3D%2232%22%20r%3D%2219%22%20fill%3D%22%23152A1F%22%20stroke%3D%22%23C9A45C%22%20stroke-width%3D%221.4%22%2F%3E%3Cpolygon%20points%3D%2232.0%2019.0%2035.2%2027.6%2044.4%2028.0%2037.2%2033.7%2039.6%2042.5%2032.0%2037.5%2024.4%2042.5%2026.8%2033.7%2019.6%2028.0%2028.8%2027.6%22%20fill%3D%22%23F1DFAE%22%2F%3E%3C%2Fsvg%3E"); background-size: 100% 100%;
  animation: mec088-shimmer 4.4s ease-in-out infinite;
}
.c-tl { top: -16px; left: -16px; }
.c-tr { top: -16px; right: -16px; }
.c-br { bottom: -16px; right: -16px; }
.c-bl { bottom: -16px; left: -16px; }
.c-tr::after, .c-br::after { animation-delay: -2.2s; }
.c-bl::after { animation-delay: -1.1s; }
@media (max-width: 560px) {
  .frame-corner { width: 48px; height: 48px; }
  .c-tl { top: -12px; left: -12px; } .c-tr { top: -12px; right: -12px; }
  .c-br { bottom: -12px; right: -12px; } .c-bl { bottom: -12px; left: -12px; }
}
/* ---------- Doors ---------- */
.door {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: var(--radius-md);
  border: 2px solid var(--gold);
  background: linear-gradient(175deg, #2A4C39, var(--green) 60%, #17301F);
  box-shadow: inset 0 -6px 0 rgba(0, 0, 0, 0.22), var(--shadow-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.15rem;
  color: var(--gold-soft);
  transition: transform var(--tr), box-shadow var(--tr), filter var(--tr);
}
.door:hover, .door:focus-visible { transform: translateY(-3px) scale(1.03); box-shadow: var(--shadow-lg); filter: brightness(1.08); }
.door .num {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 4vw, 2.1rem);
  font-weight: 700;
  line-height: 1;
  color: var(--gold);
}
.door .door-date { font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.85; }
.door .knob { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); margin-top: 0.2rem; }
/* Small festive motif at the top of every door: subtle, gold-soft, code-drawn. */
.door-motif {
  position: absolute;
  top: 0.5rem;
  left: 50%;
  transform: translateX(-50%);
  width: 14px;
  height: 14px;
  color: var(--gold-soft);
  opacity: 0.8;
}
/* On small doors the centred lock stack reaches the top band, so the motif
   moves to the free top-right corner instead of sitting behind the lock. */
@media (max-width: 560px) {
  .door-motif { width: 12px; height: 12px; top: 0.3rem; left: auto; right: 0.25rem; transform: none; }
  .door .lock { font-size: 0.8rem; line-height: 1; }
}

/* Open / today / locked states */
.door.open { cursor: pointer; }
.door.today {
  border-color: var(--gold);
  background: linear-gradient(175deg, #3D6650, #2A4C39 55%, #1E3B2D);
  animation: todayGlow 2.2s ease-in-out infinite;
}
@keyframes todayGlow {
  0%, 100% { box-shadow: 0 0 0 0 rgba(201, 164, 92, 0.55), var(--shadow-md); }
  50% { box-shadow: 0 0 0 7px rgba(201, 164, 92, 0), var(--shadow-md); }
}
.door.today .num { color: var(--white); }
.door.today::after {
  content: "Today";
  position: absolute;
  top: -0.55rem;
  background: var(--berry);
  color: var(--white);
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
}
.door.locked { filter: saturate(0.55) brightness(0.92); cursor: not-allowed; }
.door.locked:hover { transform: none; filter: saturate(0.55) brightness(0.92); }
.door .lock { font-size: 0.95rem; opacity: 0.75; }
.door.opened .num { color: var(--sage); }
.door.opened::before {
  content: "";
  position: absolute;
  inset: 3px;
  border: 1.5px dashed rgba(195, 217, 199, 0.55);
  border-radius: calc(var(--radius-md) - 3px);
}
.door.shake { animation: shake 0.4s ease; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px) rotate(-1deg); }
  75% { transform: translateX(4px) rotate(1deg); }
}

/* ---------- Footer ---------- */
.site-footer {
  max-width: 720px;
  margin: 0 auto 2.5rem;
  padding: 1rem 1.5rem 0;
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.9rem;
}
.footer-return { margin: 0 0 0.55rem; }
.footer-return-link {
  background: none;
  box-shadow: none;
  padding: 0.1rem 0.2rem;
  color: var(--green);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
.footer-return-link:hover, .footer-return-link:focus-visible { background: none; transform: none; color: var(--berry); }

/* ---------- Modal ---------- */
.modal {
  position: fixed;
  inset: 0;
  background: rgba(21, 42, 31, 0.82);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(0.5rem, 2vw, 1.5rem);
  z-index: 50;
}
.modal[hidden] { display: none; }
.modal-card {
  position: relative;
  width: min(760px, 100%);
  max-height: 94dvh;
  overflow: auto;
  background: var(--cream);
  border-radius: var(--radius-lg);
  padding: clamp(0.8rem, 2.5vw, 1.6rem);
  box-shadow: var(--shadow-lg);
  animation: cardIn 320ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes cardIn { from { transform: translateY(24px) scale(0.97); opacity: 0; } to { transform: none; opacity: 1; } }
.modal-close {
  position: absolute;
  top: 0.6rem; right: 0.6rem;
  width: 2.2rem; height: 2.2rem;
  border-radius: 50%;
  background: var(--green);
  color: var(--cream);
  font-size: 1rem;
  z-index: 2;
}
.modal-close:hover { background: var(--green-deep); }
.stage-title {
  font-family: var(--font-display);
  color: var(--green);
  font-size: clamp(1.25rem, 3vw, 1.7rem);
  margin-bottom: 0.6rem;
  padding-right: 2rem;
}

/* ---------- Media slot ---------- */
.media-slot {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
}
.media-slot video {
  display: block;
  width: 100%;
  height: auto;
  max-height: 62dvh;
  object-fit: contain;
}
/* The picture arrives as a surprise: it spins in veiled and dreamlike,
   then gently settles into focus while the slow zoom continues beneath.
   The frame is square (the artwork is 1:1) and the spin holds a scale that
   keeps the rotating image covering the frame at every angle.
   Smoothness: only transforms and opacity animate (both GPU-composited).
   The "focus" look is a crossfade from a statically blurred copy of the
   picture to the sharp one, so no filter is ever re-rendered per frame. */
.media-reveal {
  width: min(100%, 62dvh);
  margin: 0 auto;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--green-deep);
}
.media-spin {
  position: relative;
  animation: spinIn 5.5s cubic-bezier(0.32, 0.12, 0.22, 1) forwards,
             spinSettle 1.4s 5.5s cubic-bezier(0.35, 0.1, 0.25, 1) forwards;
  will-change: transform;
  transform: translateZ(0);
  backface-visibility: hidden;
}
.media-spin img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}
.mi-blur {
  position: absolute;
  inset: 0;
  filter: blur(14px) brightness(1.07);
  animation: veilOut 5.5s linear forwards;
}
.mi-sharp {
  position: relative;
  opacity: 0;
  animation: sharpIn 5.5s linear forwards, slowZoom 26s ease-in-out forwards;
}
/* One continuous rotation, no intermediate keyframes: an ease-out curve
   spanning every keyframe pair is what caused the speed to dip to zero
   mid-spin ("pauses between angles"). Here the spin is a single segment
   with one smooth deceleration, and the zoom settles separately afterwards. */
@keyframes spinIn {
  from { transform: rotate(360deg) scale(1.45); }
  to { transform: rotate(0deg) scale(1.45); }
}
@keyframes spinSettle {
  from { transform: rotate(0deg) scale(1.45); }
  to { transform: rotate(0deg) scale(1); }
}
/* Complementary crossfade: veil (1-x) + sharp (x) always sum to 1, so the
   frame never shows through, and the picture stays veiled for the first
   40% before resolving gradually through the rest of the spin. */
@keyframes veilOut { 0%, 40% { opacity: 1; } 100% { opacity: 0; } }
@keyframes sharpIn { 0%, 40% { opacity: 0; } 100% { opacity: 1; } }
@keyframes slowZoom {
  from { transform: scale(1); }
  to { transform: scale(1.12); }
}
.media-placeholder {
  aspect-ratio: 16 / 9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 1rem;
  text-align: center;
  border: 2px dashed var(--sage-deep);
  border-radius: var(--radius-md);
  background:
    radial-gradient(circle at 20% 30%, rgba(195, 217, 199, 0.18) 0, transparent 45%),
    radial-gradient(circle at 80% 70%, rgba(201, 164, 92, 0.14) 0, transparent 45%),
    var(--green-deep);
  color: var(--sage);
}
.ph-icon { width: 40px; height: 40px; opacity: 0.8; }
.ph-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--gold-soft);
}
.ph-sub {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.75;
}
.media-caption {
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--ink-soft);
  text-align: center;
  min-height: 1.2em;
}

/* ---------- Activity link ---------- */
.activity-link-row { margin-top: 1rem; text-align: center; }
.activity-link {
  display: inline-block;
  padding: 0.7rem 1.5rem;
  border-radius: 999px;
  background: var(--berry);
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow-md);
  transition: filter var(--tr), transform var(--tr);
}
.activity-link:hover, .activity-link:focus-visible { filter: brightness(1.1); transform: translateY(-2px); }
.activity-link.placeholder {
  background: none;
  border: 1.5px dashed var(--sage-deep);
  color: var(--ink-soft);
  font-weight: 500;
  box-shadow: none;
  cursor: default;
}
.activity-link.placeholder:hover { filter: none; transform: none; }

/* ---------- Activity pack viewer ---------- */
.activity-modal { z-index: 70; }
.activity-card { width: min(880px, 100%); }
.activity-actions { margin-bottom: 0.9rem; text-align: center; }
.activity-download {
  display: inline-block;
  padding: 0.55rem 1.2rem;
  border-radius: 999px;
  background: var(--green);
  color: var(--white);
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  box-shadow: var(--shadow-md);
  transition: filter var(--tr), transform var(--tr);
}
.activity-download:hover, .activity-download:focus-visible { filter: brightness(1.15); transform: translateY(-2px); }
.activity-pages {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(0.6rem, 1.6vw, 1.1rem);
}
@media (max-width: 620px) { .activity-pages { grid-template-columns: 1fr; } }
.activity-page {
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--sage-deep);
  border-radius: var(--radius-md);
  padding: 0.5rem;
  box-shadow: var(--shadow-md);
}
.activity-page-btn { display: block; border-radius: calc(var(--radius-md) - 2px); overflow: hidden; }
.activity-page-btn img {
  display: block;
  width: 100%;
  height: 34dvh;
  object-fit: contain;
  object-position: top;
  background: var(--white);
  transition: transform var(--tr);
}
.activity-page-btn:hover img, .activity-page-btn:focus-visible img { transform: scale(1.03); }
.activity-page-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  padding: 0.45rem 0.3rem 0.15rem;
}
.activity-page-kind {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--green);
  font-size: 0.92rem;
}
.activity-page-save {
  flex: none;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--berry);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.activity-hint { margin-top: 0.8rem; text-align: center; font-size: 0.78rem; color: var(--ink-soft); }

/* ---------- Full-size page viewer ---------- */
.page-modal { z-index: 80; }
.page-close { position: fixed; top: 1rem; right: 1rem; }
.page-figure {
  max-width: min(680px, 96vw);
  max-height: 96dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.page-figure img {
  max-width: 100%;
  max-height: 84dvh;
  object-fit: contain;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  background: var(--white);
}
.page-figure figcaption {
  color: var(--cream);
  font-size: 0.9rem;
  text-align: center;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  flex-wrap: wrap;
  justify-content: center;
}
.page-figure figcaption .activity-page-save { color: var(--gold-soft); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
