@font-face { font-family: "Newsreader"; src: url("../fonts/polaroid/newsreader-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Newsreader"; src: url("../fonts/polaroid/newsreader-500i.woff2") format("woff2"); font-weight: 500; font-style: italic; font-display: swap; }
@font-face { font-family: "Albert Sans"; src: url("../fonts/polaroid/albertsans-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Albert Sans"; src: url("../fonts/polaroid/albertsans-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Kalam"; src: url("../fonts/polaroid/kalam-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }

/* PHOTO WALL — birthdays, anniversaries, reunions, graduations and casual weddings: any event with a lot of photos.
   Signature idea: an instant camera. Press the shutter, the flash goes off and a photo slides out and develops.
   The cover is a big taped-up instant photo with the names written under it, and the gallery is a wall of
   snaps pinned at angles (tap to enlarge). Photo-first. Type: Newsreader · Albert Sans · Kalam */
:root { --bg: #e9e1d4; --paper: #fffdf8; --ink: #2a2622; --muted: #6f665c; --line: rgba(42, 38, 34, .14);
  --accent: #d2462e; --accent-ink: #fff; --tape: rgba(240, 220, 160, .75); --cork: #c9a678; --cam: #f4f1ea; --cam-2: #d9d4ca;
  --display: "Newsreader", Georgia, serif; --text: "Albert Sans", system-ui, sans-serif; --hand: "Kalam", cursive; --radius: 3px; }
body { background-color: var(--bg); background-image: radial-gradient(rgba(0,0,0,.05) 1px, transparent 1px); background-size: 6px 6px; color: var(--ink); }

/* intro: instant camera */
.pl-intro { --intro-ms: 2300; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px; background: var(--bg); overflow: hidden; }
.pl-cam { position: relative; width: min(250px, 70vw); aspect-ratio: 1.05; border-radius: 26px 26px 20px 20px; background: linear-gradient(180deg, var(--cam) 0 58%, var(--cam-2) 58%); box-shadow: 0 24px 40px -18px rgba(0,0,0,.45), inset 0 -6px 0 rgba(0,0,0,.06); }
.pl-cam::before { content: ""; position: absolute; left: 0; right: 0; top: 58%; height: 8px; background: repeating-linear-gradient(90deg, #e94b3c 0 20%, #f5a623 20% 40%, #f8e71c 40% 60%, #7ed321 60% 80%, #4a90e2 80% 100%); }
.pl-cam-top { position: absolute; left: 12%; right: 12%; top: 9%; height: 16%; display: flex; justify-content: space-between; }
.pl-flash { width: 36%; border-radius: 6px; background: linear-gradient(135deg, #fff, #ddd); box-shadow: inset 0 0 0 2px rgba(0,0,0,.08); }
.pl-view { width: 20%; border-radius: 6px; background: #222; }
.pl-lens { position: absolute; left: 50%; top: 34%; width: 44%; aspect-ratio: 1; margin-left: -22%; border-radius: 50%; background: radial-gradient(circle, #4a5a75 0 18%, #1a1f2b 20% 52%, #2d2d2d 54% 66%, #111 68%); box-shadow: 0 0 0 6px #e8e3d9, 0 0 0 8px rgba(0,0,0,.12); }
.pl-shutter { position: absolute; right: 9%; top: 32%; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--accent); box-shadow: 0 4px 0 color-mix(in srgb, var(--accent) 60%, #000), 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent); cursor: pointer; animation: pl-ping 2s infinite; }
@keyframes pl-ping { 0% { box-shadow: 0 4px 0 color-mix(in srgb, var(--accent) 60%, #000), 0 0 0 0 color-mix(in srgb, var(--accent) 50%, transparent); } 100% { box-shadow: 0 4px 0 color-mix(in srgb, var(--accent) 60%, #000), 0 0 0 16px transparent; } }
.pl-slot { position: absolute; left: 16%; right: 16%; bottom: 10%; height: 6px; border-radius: 3px; background: #2a2622; }
.pl-print { position: absolute; left: 20%; right: 20%; bottom: 12%; z-index: -1; aspect-ratio: .88; padding: 7% 7% 0; background: var(--paper); box-shadow: 0 10px 20px -8px rgba(0,0,0,.35); display: flex; flex-direction: column; transform: translateY(0); }
.pl-print-img { flex: 1; background: #3b3530; }
.pl-print-cap { font: 700 1rem/1.6 var(--hand); text-align: center; padding: 6px 0; color: var(--ink); overflow-wrap: anywhere; }
.pl-for { margin: 0; font: 700 1.2rem var(--hand); }
.pl-intro .intro-hint { margin: 0; color: var(--muted); font-size: .84rem; }
.pl-white { position: absolute; inset: 0; background: #fff; opacity: 0; pointer-events: none; }
.is-opening .pl-shutter { transform: translateY(3px); box-shadow: 0 1px 0 color-mix(in srgb, var(--accent) 60%, #000); animation: none; }
.is-opening .pl-white { animation: pl-flash .5s ease-out .1s; }
@keyframes pl-flash { 0% { opacity: 0; } 20% { opacity: .95; } 100% { opacity: 0; } }
.is-opening .pl-print { animation: pl-eject 1s cubic-bezier(.2,.7,.2,1) .5s forwards; }
@keyframes pl-eject { to { transform: translateY(105%) rotate(-4deg); } }
.is-opening .pl-print-img { animation: pl-develop 1.2s ease .9s forwards; }
@keyframes pl-develop { to { background: linear-gradient(160deg, color-mix(in srgb, var(--accent) 45%, #fff), color-mix(in srgb, var(--cork) 70%, #fff)); } }

/* hero */
.t-polaroid .pl-hero { display: grid; gap: 22px; padding: 40px 20px 64px; align-content: center; }
.pl-big { position: relative; width: min(330px, 84vw); margin: 0 auto; padding: 14px 14px 0; background: var(--paper); box-shadow: 0 22px 40px -22px rgba(0,0,0,.5); transform: rotate(-2.5deg); }
.pl-tape { position: absolute; left: 50%; top: -14px; width: 110px; height: 30px; margin-left: -55px; background: var(--tape); transform: rotate(3deg); box-shadow: 0 1px 2px rgba(0,0,0,.08); }
.pl-big .pl-pic { position: relative; display: block; aspect-ratio: 1; overflow: hidden; background: #2f2a26; }
.pl-big .pl-pic .cm-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.pl-big .ph-slot { border-radius: 0; height: 100%; }
.pl-cap { display: block; font: 700 clamp(1.4rem, 7vw, 1.9rem)/1.2 var(--hand); text-align: center; padding: 12px 4px 16px; color: var(--ink); }
.pl-copy { text-align: center; max-width: 520px; margin: 0 auto; }
.t-polaroid .hero-guest { font: 700 1.3rem var(--hand); font-style: normal; color: var(--accent); }
.t-polaroid .hero-k { font-size: .76rem; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.t-polaroid .hero-t { font-family: var(--display); font-weight: 500; font-style: italic; font-size: clamp(2.4rem, 11vw, 3.8rem); }
.t-polaroid .hero-line { margin: 12px auto 14px; max-width: 26em; }
.t-polaroid .hero-date { font-weight: 600; margin: 0; }
.t-polaroid .hero-place { color: var(--muted); margin: 2px 0 0; }
.t-polaroid .hero-cta { background: var(--accent); color: var(--accent-ink); font-weight: 600; }

/* sections as pinned index cards */
.t-polaroid .sh-k { font: 700 1.2rem var(--hand); letter-spacing: 0; text-transform: none; color: var(--accent); margin-bottom: 2px; }
.t-polaroid .sh-t { font-family: var(--display); font-weight: 500; font-style: italic; }
.t-polaroid .tl, .t-polaroid .vn-c, .t-polaroid .rs, .t-polaroid .rs-done, .t-polaroid .faq, .t-polaroid .pp-g, .t-polaroid .story-body {
  position: relative; background: var(--paper); border: 0; border-radius: 2px; box-shadow: 0 10px 24px -16px rgba(0,0,0,.4); }
.t-polaroid .vn-c::before, .t-polaroid .rs::before, .t-polaroid .tl::before { content: ""; position: absolute; left: 50%; top: -10px; width: 80px; height: 22px; margin-left: -40px; background: var(--tape); transform: rotate(-2deg); }
.t-polaroid .tl { padding: 18px 18px 8px; }
.t-polaroid .tl-time { font: 700 1rem var(--hand); color: var(--accent); }
.t-polaroid .vn-c { padding: 24px 18px; }
.t-polaroid .cd-u { background: var(--paper); box-shadow: 0 8px 18px -12px rgba(0,0,0,.4); border-radius: 2px; }
.t-polaroid .cd-u b { font-family: var(--display); }
.t-polaroid .rs-btn { background: var(--accent); color: var(--accent-ink); font-weight: 600; }
.t-polaroid .cl-line { font-family: var(--display); font-style: italic; font-size: 1.6rem; }
.t-polaroid .cl-sign { font: 700 1.8rem var(--hand); color: var(--accent); }

/* the photo wall */
.pl-wall-s > .pl-wall { max-width: 760px; }
.pl-wall { display: grid; grid-template-columns: repeat(2, 1fr); gap: 22px 14px; padding: 8px 4px; }
@media (min-width: 640px) { .pl-wall { grid-template-columns: repeat(3, 1fr); } }
.pl-snap { position: relative; display: block; width: 100%; padding: 8px 8px 0; border: 0; background: var(--paper); box-shadow: 0 12px 22px -14px rgba(0,0,0,.5); cursor: zoom-in; transition: transform .3s; color: inherit; font: inherit; text-align: center; }
.pl-snap.r0 { transform: rotate(-3deg); } .pl-snap.r1 { transform: rotate(2.5deg); } .pl-snap.r2 { transform: rotate(-1.5deg); } .pl-snap.r3 { transform: rotate(3.5deg); }
.pl-snap .pl-pic { display: block; aspect-ratio: 1; overflow: hidden; background: #2f2a26; }
.pl-snap .pl-pic img { width: 100%; height: 100%; object-fit: cover; }
.pl-snap .ph-slot { border-radius: 0; min-height: 0; height: 100%; padding: 6px; }
.pl-snap .ph-slot .ph-ic { width: 26px; height: 26px; } .pl-snap .ph-slot .ph-l { font-size: .7rem; }
.pl-snap .pl-cap { font-size: 1rem; padding: 8px 2px 10px; }
.pl-snap[aria-pressed="true"] { position: relative; z-index: 5; transform: rotate(0) scale(1.45); cursor: zoom-out; }
.t-polaroid .ph-slot { color: color-mix(in srgb, var(--accent) 75%, var(--ink)); }
.t-polaroid .cover-photo { display: none; }
.pl-noimg { position: absolute; inset: 0; display: grid; place-items: center; padding: 18px; text-align: center; font: 700 clamp(3.4rem, 18vw, 5rem)/1 var(--hand); color: var(--paper); background: radial-gradient(circle at 30% 25%, #4a413a, #2f2a26); }
