:root {
  --wine: #762d3d;
  --wine-dark: #5e2130;
  --ink: #2c2522;
  --paper: #f8f5ef;
  --card: #fffdf9;
  --muted: #766a64;
}

* { box-sizing: border-box; }
html { background: var(--paper); }
body { margin: 0; min-width: 320px; color: var(--ink); background: var(--paper); font-family: Manrope, Arial, sans-serif; }
.checking-access #site-content { visibility: hidden; }
.checking-admin #admin-content, .checking-admin #admin-login-screen { visibility: hidden; }
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: wait; opacity: .68; pointer-events: none; }
svg { width: 1.2rem; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

.wedding-page { min-height: 100svh; display: grid; grid-template-columns: minmax(330px,.92fr) minmax(500px,1.08fr); }
.story-panel { position: relative; min-height: 100svh; overflow: hidden; color: #fff; background: #4a1d28; }
.story-image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.story-overlay { position: absolute; inset: 0; background: linear-gradient(180deg,rgba(32,26,22,.04),rgba(40,20,25,.76)); }
.monogram { position: absolute; top: 2.25rem; left: 2.5rem; display: flex; align-items: center; gap: .65rem; font-size: .84rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.monogram svg, .mobile-brand svg { width: 1.2rem; fill: currentColor; }
.story-copy { position: absolute; left: clamp(2rem,5vw,5rem); right: clamp(2rem,5vw,5rem); bottom: clamp(3rem,8vh,7rem); max-width: 38rem; }
.eyebrow { margin: 0 0 1rem; font-size: .73rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; }
.story-copy h1 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(3.2rem,6vw,6.2rem); line-height: .88; font-weight: 600; letter-spacing: -.045em; }
.story-copy>p:last-child { max-width: 33rem; margin: 1.6rem 0 0; color: rgba(255,255,255,.84); font-size: clamp(1rem,1.4vw,1.12rem); line-height: 1.7; }

.upload-panel { display: flex; min-height: 100svh; align-items: center; justify-content: center; padding: clamp(2rem,6vw,6rem); }
.upload-shell { width: min(100%,34rem); }
.mobile-brand { display: none; }
.upload-heading { text-align: center; }
.camera-mark { display: grid; width: 3.2rem; height: 3.2rem; margin: 0 auto 1.25rem; place-items: center; border-radius: 50%; color: var(--wine); background: #f0e1e1; }
.camera-mark svg { width: 1.45rem; }
.upload-heading .eyebrow { margin-bottom: .65rem; color: #9b6670; }
.upload-heading h2, .success-card h2 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(2.7rem,4.3vw,4.3rem); line-height: 1; font-weight: 600; letter-spacing: -.04em; }
.upload-heading>p:last-child { max-width: 27rem; margin: 1rem auto 2.2rem; color: var(--muted); line-height: 1.65; }

.drop-zone { display: flex; min-height: 19rem; flex-direction: column; align-items: center; justify-content: center; border: 1.5px dashed #cbbab4; border-radius: 1.5rem; padding: 2rem; text-align: center; background: rgba(255,253,249,.82); box-shadow: 0 24px 70px rgba(77,42,40,.08); transition: border-color .2s,transform .2s,background .2s; }
.drop-zone:hover, .drop-zone.dragging { border-color: #9d5262; transform: translateY(-2px); background: var(--card); }
.upload-icon { display: grid; width: 4rem; height: 4rem; place-items: center; border-radius: 1.1rem; color: var(--wine); background: #f7eeee; transform: rotate(-2deg); }
.upload-icon svg { width: 1.8rem; }
.drop-zone strong { margin-top: 1.2rem; font-family: "Cormorant Garamond",Georgia,serif; font-size: 1.55rem; font-weight: 600; }
.drop-zone>span:not(.upload-icon) { margin-top: .35rem; color: #877a74; font-size: .875rem; }
.drop-zone .desktop-only { margin-top: .8rem; font-size: .74rem; }
.primary-button, .upload-button { min-height: 3.25rem; border: 0; border-radius: 999px; padding: 0 1.75rem; display: inline-flex; align-items: center; justify-content: center; gap: .55rem; color: #fffaf5; background: var(--wine); font-weight: 800; box-shadow: 0 10px 24px rgba(118,45,61,.22); transition: background .2s,transform .15s; }
.primary-button:hover, .upload-button:hover { background: var(--wine-dark); }
.primary-button:active, .upload-button:active { transform: translateY(1px); }
.drop-zone .primary-button { margin-top: 1.5rem; }
.privacy-note { display: flex; align-items: center; justify-content: center; gap: .45rem; margin: 1.15rem 0 0; color: #81756f; font-size: .78rem; text-align: center; }
.privacy-note svg { flex: 0 0 auto; width: 1rem; }

.selection-card { border: 1px solid #dfd5cf; border-radius: 1.5rem; padding: 1.35rem; background: rgba(255,253,249,.92); box-shadow: 0 24px 70px rgba(77,42,40,.08); }
.selection-title { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .2rem .15rem 1rem; border-bottom: 1px solid #eee5df; }
.selection-title>div { display: flex; flex-direction: column; gap: .18rem; }
.selection-title strong { font-family: "Cormorant Garamond",Georgia,serif; font-size: 1.35rem; }
.selection-title span { color: #877a74; font-size: .78rem; }
.outline-button { min-height: 2.45rem; border: 1px solid #d9cbc4; border-radius: 999px; padding: 0 .85rem; display: inline-flex; align-items: center; gap: .35rem; color: var(--ink); background: var(--card); font-size: .8rem; font-weight: 700; }
.outline-button:hover { border-color: #9d5262; }
.outline-button svg { width: .95rem; }
.file-list { max-height: 13rem; overflow-y: auto; margin: .45rem -.25rem .25rem; padding: 0 .25rem; }
.file-row { display: grid; grid-template-columns: 2.5rem minmax(0,1fr) 2rem; align-items: center; gap: .7rem; padding: .7rem .15rem; border-bottom: 1px solid #f0e8e3; }
.file-row:last-child { border-bottom: 0; }
.file-icon { display: grid; width: 2.5rem; height: 2.5rem; place-items: center; border-radius: .8rem; color: var(--wine); background: #f6eceb; }
.file-icon svg { width: 1.15rem; }
.file-name { display: flex; min-width: 0; flex-direction: column; gap: .18rem; }
.file-name strong { overflow: hidden; font-size: .8rem; text-overflow: ellipsis; white-space: nowrap; }
.file-name small { color: #8a7d76; font-size: .7rem; }
.icon-button { width: 2rem; height: 2rem; border: 0; display: grid; place-items: center; color: #8a7d76; background: transparent; border-radius: 50%; }
.icon-button:hover { color: #9e3043; background: #f6eceb; }
.icon-button svg { width: 1rem; }
.progress-box { margin: 1rem .15rem .25rem; font-size: .8rem; font-weight: 700; }
.progress-box>div { display: flex; justify-content: space-between; margin-bottom: .5rem; }
.progress-box progress { width: 100%; height: .45rem; display: block; overflow: hidden; border: 0; border-radius: 999px; background: #eee4df; }
.progress-box progress::-webkit-progress-bar { background: #eee4df; }
.progress-box progress::-webkit-progress-value { background: var(--wine); transition: width .2s; }
.progress-box progress::-moz-progress-bar { background: var(--wine); }
.upload-button { width: 100%; min-height: 3.35rem; margin-top: 1rem; }
.upload-button.loading svg { animation: spin .9s linear infinite; }
.error-message { margin: .8rem .2rem 0; color: #a22d3e; font-size: .8rem; line-height: 1.5; }

.success-card { display: block; text-align: center; border: 1px solid #ded1c9; border-radius: 1.8rem; padding: clamp(2.25rem,6vw,4rem) clamp(1.5rem,5vw,3.5rem); background: rgba(255,253,249,.94); box-shadow: 0 24px 70px rgba(77,42,40,.09); }
.success-icon { display: grid; width: 4.5rem; height: 4.5rem; margin: 0 auto 1.35rem; place-items: center; border-radius: 50%; color: #fff; background: var(--wine); box-shadow: 0 12px 26px rgba(118,45,61,.2); }
.success-icon svg { width: 2rem; }
.success-card .eyebrow { margin-bottom: .65rem; color: #9b6670; }
.success-card h2 { font-size: clamp(3rem,5vw,4.7rem); }
.success-card>p:not(.eyebrow) { margin: 1.15rem auto 0; color: var(--muted); line-height: 1.7; }
.success-card .primary-button { margin-top: 1.8rem; }

.access-screen { min-height: 100svh; display: grid; place-items: center; padding: 2rem; text-align: center; background: var(--paper); }
.access-screen>div { width: min(100%,30rem); }
.access-screen svg { width: 3rem; height: 3rem; color: var(--wine); }
.access-screen h1 { margin: 1.4rem 0 .7rem; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(2.5rem,7vw,4rem); line-height: .95; }
.access-screen p { color: var(--muted); line-height: 1.65; }

.gallery-section { padding: clamp(4rem,8vw,7rem) clamp(1.25rem,6vw,6rem) clamp(5rem,10vw,9rem); color: var(--ink); background: #efe9e1; }
.gallery-header { max-width: 82rem; margin: 0 auto 2.2rem; display: flex; align-items: end; justify-content: space-between; gap: 2rem; }
.gallery-header .eyebrow { margin-bottom: .55rem; color: #9b6670; }
.gallery-header h2 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(3rem,6vw,5.4rem); line-height: .92; font-weight: 600; letter-spacing: -.045em; }
.gallery-header>div>p:last-child { margin: .85rem 0 0; color: var(--muted); }
.gallery-header .outline-button { flex: 0 0 auto; min-height: 2.8rem; padding-inline: 1rem; }
.gallery-grid { max-width: 82rem; margin: 0 auto; columns: 4 16rem; column-gap: 1rem; }
.gallery-item { position: relative; width: 100%; margin: 0 0 1rem; padding: 0; overflow: hidden; display: block; break-inside: avoid; border: 0; border-radius: 1rem; color: #fff; background: #dfd5cf; box-shadow: 0 10px 30px rgba(54,39,35,.09); }
.gallery-item img { width: 100%; height: auto; display: block; transition: transform .35s ease; }
.gallery-item:hover img { transform: scale(1.025); }
.gallery-item:after { content: ""; position: absolute; inset: auto 0 0; height: 35%; pointer-events: none; background: linear-gradient(transparent,rgba(26,18,19,.6)); opacity: 0; transition: opacity .2s; }
.gallery-item:hover:after { opacity: 1; }
.gallery-item .video-badge { position: absolute; z-index: 1; right: .7rem; bottom: .7rem; width: 2.4rem; height: 2.4rem; display: grid; place-items: center; border-radius: 50%; color: #fff; background: rgba(28,20,22,.76); backdrop-filter: blur(8px); }
.gallery-item .video-badge svg { width: 1rem; fill: currentColor; }
.gallery-message { max-width: 82rem; min-height: 15rem; margin: 0 auto; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 1px dashed #cbbeb6; border-radius: 1.4rem; padding: 2rem; text-align: center; color: var(--muted); background: rgba(255,253,249,.5); }
.gallery-message>svg { width: 2.5rem; height: 2.5rem; color: var(--wine); }
.gallery-message h3 { margin: 1rem 0 .35rem; font-family: "Cormorant Garamond",Georgia,serif; color: var(--ink); font-size: 1.8rem; }
.gallery-message p { margin: .2rem 0; }
.gallery-spinner { width: 2rem; height: 2rem; border: 2px solid #d8c8c3; border-top-color: var(--wine); border-radius: 50%; animation: spin .8s linear infinite; }
.gallery-error { max-width: 82rem; margin: 0 auto 1rem; color: #a22d3e; }

.lightbox { width: min(94vw,72rem); height: min(92vh,54rem); margin: auto; padding: 0; overflow: visible; border: 0; color: #fff; background: transparent; }
.lightbox::backdrop { background: rgba(21,15,17,.9); backdrop-filter: blur(10px); }
.lightbox-content { width: 100%; height: calc(100% - 2.5rem); display: grid; place-items: center; }
.lightbox-content img, .lightbox-content video { max-width: 100%; max-height: 100%; border-radius: .8rem; box-shadow: 0 24px 80px rgba(0,0,0,.3); }
.lightbox-content video { width: min(100%,70rem); }
.lightbox-close { position: absolute; z-index: 2; top: -2.8rem; right: 0; width: 2.5rem; height: 2.5rem; display: grid; place-items: center; border: 0; border-radius: 50%; color: #fff; background: rgba(255,255,255,.13); }
.lightbox-close svg { width: 1.2rem; }
.lightbox>p { margin: .75rem 0 0; overflow: hidden; text-align: center; text-overflow: ellipsis; white-space: nowrap; }

/* Cinematic wedding experience */
.wedding-page { grid-template-columns: minmax(29rem,1.08fr) minmax(30rem,.92fr); background: #ece7e0; }
.story-panel { isolation: isolate; background: #171012; }
.story-panel:after { content: ""; position: absolute; z-index: 2; inset: 0; pointer-events: none; opacity: .22; background-image: radial-gradient(rgba(255,255,255,.28) .5px,transparent .7px); background-size: 4px 4px; mix-blend-mode: soft-light; }
.story-image { animation: hero-drift 22s ease-in-out infinite alternate; }
.story-overlay { z-index: 1; background: linear-gradient(180deg,rgba(12,8,9,.06) 20%,rgba(16,9,11,.28) 58%,rgba(13,7,9,.9) 100%),linear-gradient(90deg,rgba(29,13,17,.2),transparent 55%); }
.monogram, .story-copy { z-index: 3; }
.monogram { font-size: .72rem; letter-spacing: .2em; }
.story-copy .eyebrow { color: rgba(255,235,220,.76); }
.story-copy h1 { max-width: 49rem; font-size: clamp(4rem,6.8vw,7.4rem); text-wrap: balance; }
.upload-panel { position: relative; overflow: hidden; background: radial-gradient(circle at 100% 0,rgba(118,45,61,.12),transparent 34%),linear-gradient(145deg,#f7f3ed,#ebe4dc); }
.upload-panel:before { content: ""; position: absolute; width: 22rem; height: 22rem; right: -14rem; bottom: -11rem; border: 1px solid rgba(118,45,61,.14); border-radius: 50%; box-shadow: 0 0 0 3rem rgba(118,45,61,.025),0 0 0 7rem rgba(118,45,61,.018); }
.upload-shell { position: relative; z-index: 1; }
.camera-mark { border: 1px solid rgba(118,45,61,.12); background: rgba(255,255,255,.48); backdrop-filter: blur(12px); }
.drop-zone, .selection-card, .success-card { border-color: rgba(118,45,61,.16); background: rgba(255,253,249,.72); backdrop-filter: blur(18px); box-shadow: 0 28px 80px rgba(54,28,32,.1); }
.drop-zone { border-radius: 1.2rem; }

.gallery-section { position: relative; isolation: isolate; overflow: hidden; padding: clamp(5rem,9vw,9rem) clamp(1rem,4vw,4rem) clamp(6rem,11vw,11rem); color: #f7f1e9; background: #0d0b0c; }
.gallery-section:before { content: ""; position: absolute; z-index: -1; inset: 0; pointer-events: none; background: radial-gradient(circle at 15% 8%,rgba(125,47,64,.24),transparent 28rem),radial-gradient(circle at 92% 40%,rgba(117,87,62,.12),transparent 34rem),linear-gradient(180deg,#171114 0,#0d0b0c 42rem); }
.gallery-section:after { content: ""; position: absolute; z-index: -1; inset: 0; pointer-events: none; opacity: .13; background-image: radial-gradient(rgba(255,255,255,.4) .45px,transparent .6px); background-size: 5px 5px; }
.gallery-header { max-width: 90rem; margin-bottom: clamp(2.5rem,6vw,5rem); align-items: end; }
.gallery-header .eyebrow { color: #c9939f; }
.gallery-header h2 { max-width: 64rem; color: #fffaf2; font-size: clamp(3.8rem,7.4vw,8rem); line-height: .82; text-wrap: balance; }
.gallery-header>div>p:last-child { max-width: 34rem; color: rgba(255,244,235,.58); line-height: 1.7; }
.gallery-header .outline-button { border-color: rgba(255,255,255,.16); color: rgba(255,255,255,.8); background: rgba(255,255,255,.06); backdrop-filter: blur(12px); }
.gallery-header .outline-button:hover { border-color: rgba(255,255,255,.38); background: rgba(255,255,255,.11); }

.cinema-stage { position: relative; width: min(100%,90rem); aspect-ratio: 16/9; min-height: 32rem; max-height: 80svh; margin: 0 auto; overflow: hidden; border: 1px solid rgba(255,255,255,.11); border-radius: 1.1rem; color: #fff; background: #050405; box-shadow: 0 3rem 9rem rgba(0,0,0,.48); outline: none; touch-action: pan-y; }
.cinema-stage:focus-visible { box-shadow: 0 0 0 3px rgba(201,147,159,.6),0 3rem 9rem rgba(0,0,0,.48); }
.cinema-visual, .cinema-shade { position: absolute; inset: 0; }
.cinema-visual { display: grid; place-items: center; overflow: hidden; }
.cinema-backdrop { position: absolute; inset: -8%; width: 116%; height: 116%; object-fit: cover; opacity: .48; filter: blur(45px) saturate(.82); transform: scale(1.08); }
.cinema-media-frame { position: absolute; inset: 3%; display: flex; align-items: center; justify-content: center; }
.cinema-media { position: relative; z-index: 1; display: block; width: auto; height: auto; max-width: 76%; max-height: 76%; object-fit: contain; filter: drop-shadow(0 1.8rem 3.5rem rgba(0,0,0,.38)); animation: cinema-reveal .75s cubic-bezier(.2,.75,.25,1) both; }
.cinema-media-frame video { width: min(100%,76rem); max-width: 100%; max-height: 100%; background: #050405; }
.cinema-shade { z-index: 2; pointer-events: none; background: linear-gradient(180deg,rgba(5,4,5,.2),transparent 35%,rgba(5,4,5,.08) 56%,rgba(5,4,5,.88) 100%),linear-gradient(90deg,rgba(5,4,5,.42),transparent 35%,transparent 70%,rgba(5,4,5,.2)); }
.cinema-caption { position: absolute; z-index: 3; left: clamp(1.4rem,4vw,4rem); right: clamp(1.4rem,4vw,4rem); bottom: clamp(5.2rem,8vw,7rem); pointer-events: none; }
.cinema-caption .eyebrow { margin-bottom: .45rem; color: #dcb8bd; font-variant-numeric: tabular-nums; }
.cinema-caption h3 { max-width: min(72%,52rem); margin: 0; overflow: hidden; color: #fffaf3; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(2rem,4.5vw,4.8rem); font-weight: 600; line-height: .92; letter-spacing: -.035em; text-overflow: ellipsis; white-space: nowrap; }
.cinema-caption>p:last-child { margin: .55rem 0 0; color: rgba(255,255,255,.57); font-size: .78rem; letter-spacing: .04em; }
.cinema-arrow, .lightbox-arrow { position: absolute; z-index: 4; top: 50%; width: 3rem; height: 3rem; border: 1px solid rgba(255,255,255,.16); border-radius: 50%; display: grid; place-items: center; color: rgba(255,255,255,.86); background: rgba(10,8,9,.28); backdrop-filter: blur(12px); transform: translateY(-50%); transition: background .2s,border-color .2s,transform .2s; }
.cinema-arrow:hover, .lightbox-arrow:hover { border-color: rgba(255,255,255,.38); background: rgba(10,8,9,.65); }
.cinema-arrow:active { transform: translateY(-50%) scale(.95); }
.cinema-arrow svg, .lightbox-arrow svg { width: 1.25rem; }
.cinema-prev { left: clamp(.8rem,2vw,1.7rem); }
.cinema-next { right: clamp(.8rem,2vw,1.7rem); }
.cinema-toolbar { position: absolute; z-index: 4; left: clamp(1.4rem,4vw,4rem); right: clamp(1.4rem,4vw,4rem); bottom: clamp(1.15rem,2vw,1.8rem); display: grid; grid-template-columns: auto minmax(4rem,1fr) auto; align-items: center; gap: 1rem; }
.cinema-control { min-height: 2.5rem; border: 0; padding: 0; display: inline-flex; align-items: center; gap: .5rem; color: rgba(255,255,255,.78); background: transparent; font-size: .73rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.cinema-control:hover { color: #fff; }
.cinema-control svg { width: 1rem; }
.cinema-control .play-icon { display: block; fill: currentColor; }
.cinema-control .pause-icon { display: none; }
.cinema-control.is-playing .play-icon { display: none; }
.cinema-control.is-playing .pause-icon { display: block; }
.cinema-progress { height: 1px; overflow: hidden; background: rgba(255,255,255,.2); }
.cinema-progress>span { width: 100%; height: 100%; display: block; background: #f1d5d7; transform: scaleX(0); transform-origin: left; }

.cinema-filmstrip { width: min(100%,90rem); margin: 1.25rem auto 0; padding: .25rem 0 .65rem; display: flex; gap: .6rem; overflow-x: auto; scrollbar-color: rgba(255,255,255,.18) transparent; scroll-snap-type: x proximity; }
.filmstrip-item { position: relative; flex: 0 0 5.4rem; aspect-ratio: 4/3; padding: 0; overflow: hidden; border: 1px solid transparent; border-radius: .4rem; background: #241f20; opacity: .5; scroll-snap-align: center; transition: opacity .2s,border-color .2s,transform .2s; }
.filmstrip-item:hover { opacity: .82; }
.filmstrip-item.is-active { border-color: #e7c7ca; opacity: 1; transform: translateY(-2px); }
.filmstrip-item img { width: 100%; height: 100%; display: block; object-fit: cover; }
.filmstrip-item>span { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; background: rgba(0,0,0,.2); }
.filmstrip-item>span svg { width: 1.1rem; fill: currentColor; }

.gallery-index-heading { width: min(100%,90rem); margin: clamp(4.5rem,9vw,8rem) auto 2rem; display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.gallery-index-heading .eyebrow { margin-bottom: .35rem; color: #c9939f; }
.gallery-index-heading h3 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(2.8rem,5vw,5rem); font-weight: 600; line-height: .9; letter-spacing: -.04em; }
.gallery-index-heading>span { color: rgba(255,255,255,.45); font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; }
.gallery-grid { max-width: 90rem; columns: 4 15rem; column-gap: .8rem; }
.gallery-item { margin-bottom: .8rem; border: 1px solid rgba(255,255,255,.07); border-radius: .55rem; background: #221d1f; box-shadow: none; }
.gallery-item img { filter: saturate(.86) contrast(1.03); transition: transform .65s cubic-bezier(.2,.7,.2,1),filter .3s; }
.gallery-item:hover img { transform: scale(1.035); filter: saturate(1) contrast(1.02); }
.gallery-item:after { height: 50%; opacity: .7; background: linear-gradient(transparent,rgba(8,6,7,.7)); }
.gallery-item-number { position: absolute; z-index: 2; left: .75rem; bottom: .65rem; color: rgba(255,255,255,.74); font-size: .68rem; font-weight: 800; letter-spacing: .12em; }
.gallery-item .video-badge { width: 2.2rem; height: 2.2rem; border: 1px solid rgba(255,255,255,.15); background: rgba(10,8,9,.68); }
.gallery-message { color: rgba(255,255,255,.58); border-color: rgba(255,255,255,.15); background: rgba(255,255,255,.025); }
.gallery-message>svg { color: #c9939f; }
.gallery-message h3 { color: #fffaf2; }
.gallery-spinner { border-color: rgba(255,255,255,.15); border-top-color: #d7a8b1; }
.gallery-error { color: #f0a6b3; }

.lightbox { width: 100vw; max-width: none; height: 100dvh; max-height: none; overflow: hidden; color: #fff; background: rgba(4,3,4,.96); }
.lightbox::backdrop { background: #040304; backdrop-filter: none; }
.lightbox-content { width: 100%; height: 100%; padding: clamp(3.5rem,7vw,5rem) clamp(1rem,8vw,8rem) 4.5rem; }
.lightbox-content img, .lightbox-content video { max-width: 100%; max-height: 100%; border-radius: .25rem; box-shadow: 0 2rem 7rem rgba(0,0,0,.48); }
.lightbox-content video { width: min(100%,82rem); }
.lightbox-close { position: fixed; top: 1rem; right: 1rem; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.06); }
.lightbox-arrow { position: fixed; top: 50%; background: rgba(255,255,255,.05); }
.lightbox-prev { left: 1rem; }
.lightbox-next { right: 1rem; }
.lightbox-meta { position: fixed; left: clamp(1rem,5vw,4rem); right: clamp(1rem,5vw,4rem); bottom: 1.15rem; display: flex; align-items: center; justify-content: space-between; gap: 2rem; }
.lightbox-meta p { margin: 0; overflow: hidden; color: rgba(255,255,255,.82); font-family: "Cormorant Garamond",Georgia,serif; font-size: 1.3rem; text-overflow: ellipsis; white-space: nowrap; }
.lightbox-meta span { color: rgba(255,255,255,.45); font-size: .72rem; font-weight: 800; letter-spacing: .12em; }

.admin-page { min-height: 100svh; background: linear-gradient(145deg,#f8f5ef,#eee5dc); }
.admin-shell { width: min(calc(100% - 2rem),52rem); margin: 0 auto; padding: 2rem 0 5rem; }
.admin-topbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.admin-back { display: inline-flex; align-items: center; gap: .35rem; color: var(--wine); font-size: .82rem; font-weight: 800; text-decoration: none; }
.admin-back svg { width: 1rem; }
.admin-logout { min-height: 2.5rem; border: 1px solid #d9cbc4; border-radius: 999px; padding: 0 .9rem; display: inline-flex; align-items: center; gap: .4rem; color: var(--muted); background: rgba(255,253,249,.72); font-size: .8rem; font-weight: 800; }
.admin-logout:hover { color: var(--wine); border-color: #b88b94; }
.admin-logout svg { width: 1rem; }
.admin-header { max-width: 42rem; margin: clamp(3rem,8vw,6rem) 0 2rem; }
.admin-header .eyebrow { margin-bottom: .65rem; color: #9b6670; }
.admin-header h1 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(3.4rem,8vw,6rem); line-height: .88; font-weight: 600; letter-spacing: -.05em; }
.admin-header>p:last-child { margin: 1.2rem 0 0; color: var(--muted); line-height: 1.7; }
.admin-card { border: 1px solid #ded2ca; border-radius: 1.5rem; padding: clamp(1.35rem,4vw,2.3rem); background: rgba(255,253,249,.92); box-shadow: 0 20px 60px rgba(64,43,37,.08); }
.qr-admin-panel { display: grid; grid-template-columns: minmax(0,1fr) 12rem; gap: clamp(1.5rem,5vw,3rem); align-items: center; margin-bottom: 1rem; }
.qr-admin-copy .eyebrow { margin-bottom: .4rem; color: #9b6670; }
.qr-admin-copy h2 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: 2.25rem; line-height: 1; }
.qr-admin-copy>p:last-of-type { margin: .7rem 0 0; color: var(--muted); line-height: 1.6; }
.qr-admin-copy .outline-button { min-height: 3.25rem; text-decoration: none; }
.qr-admin-preview { margin: 0; overflow: hidden; border: 1px solid #e1d4cd; border-radius: 1rem; padding: .7rem; background: #fff; box-shadow: 0 16px 40px rgba(53,35,32,.08); }
.qr-admin-preview img { width: 100%; aspect-ratio: 1; display: block; }
.admin-login-card { width: min(100%,28rem); border: 1px solid #ded2ca; border-radius: 1.5rem; padding: clamp(1.6rem,6vw,2.6rem); background: rgba(255,253,249,.96); box-shadow: 0 24px 70px rgba(64,43,37,.12); }
.admin-login-card>svg { width: 2.8rem; height: 2.8rem; }
.admin-login-card>.eyebrow { margin: 1.2rem 0 .55rem; color: #9b6670; }
.admin-login-card h1 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(2.8rem,10vw,4.3rem); line-height: .9; font-weight: 600; letter-spacing: -.04em; }
.admin-login-card>p:not(.eyebrow,.error-message) { margin: 1rem 0 1.4rem; color: var(--muted); line-height: 1.6; }
.admin-login-card label { display: grid; gap: .45rem; text-align: left; }
.admin-login-card label span { font-size: .82rem; font-weight: 800; }
.admin-login-card input { width: 100%; min-height: 3.2rem; border: 1px solid #d8cac3; border-radius: .8rem; padding: 0 .9rem; background: #fff; outline: none; }
.admin-login-card input:focus { border-color: #9d5262; box-shadow: 0 0 0 3px rgba(157,82,98,.14); }
.admin-login-card .upload-button { margin-top: 1rem; }
.password-panel { display: grid; grid-template-columns: 3.25rem 1fr; gap: 1.15rem; margin-bottom: 2.4rem; }
.admin-setting-icon { width: 3.25rem; height: 3.25rem; display: grid; place-items: center; border-radius: 1rem; color: var(--wine); background: #f3e6e7; }
.admin-setting-icon svg { width: 1.35rem; }
.password-panel .eyebrow { margin: .15rem 0 .35rem; color: #9b6670; }
.password-panel h2, .admin-section-heading h2 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: 2rem; line-height: 1; }
.password-panel>div>p:not(.eyebrow,.error-message) { margin: .6rem 0 0; color: var(--muted); line-height: 1.55; }
.password-panel #change-password { margin-top: 1.1rem; }
.password-form { margin-top: 1.2rem; padding-top: 1.2rem; }
.field-hint { font-size: .75rem; }
.password-actions { display: flex; flex-wrap: wrap; gap: .65rem; margin-top: 1.1rem; }
.password-actions .primary-button { min-height: 2.7rem; }
.admin-section-heading { margin: 0 0 1rem .35rem; }
.admin-section-heading .eyebrow { margin-bottom: .4rem; color: #9b6670; }
.setup-intro { display: grid; grid-template-columns: 2.5rem 1fr; gap: 1rem; align-items: start; }
.setup-intro>span { width: 2.5rem; height: 2.5rem; display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--wine); font-weight: 800; }
.setup-intro h2, .connected-panel h2 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: 2rem; line-height: 1; }
.setup-intro p, .connected-panel p { margin: .55rem 0 0; color: var(--muted); line-height: 1.6; }
.setup-intro .oauth-warning { margin-top: .9rem; padding: .75rem .85rem; border-left: 3px solid #b47b35; border-radius: .35rem; background: #fff5df; color: #665039; font-size: .86rem; }
.setup-intro a { display: inline-block; margin-top: .8rem; color: var(--wine); font-weight: 800; }
.setup-intro.compact { margin-bottom: 1.25rem; }
.redirect-box { margin: 1.4rem 0 2rem 3.5rem; border-radius: 1rem; padding: 1rem; display: grid; grid-template-columns: 1fr auto; gap: .45rem 1rem; background: #f2ebe5; }
.redirect-box>span { grid-column: 1/-1; color: var(--muted); font-size: .75rem; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; }
.redirect-box code { min-width: 0; overflow: hidden; align-self: center; color: #514540; font-size: .78rem; text-overflow: ellipsis; white-space: nowrap; }
.redirect-box .outline-button { min-height: 2.2rem; }
.admin-form { border-top: 1px solid #ece2dc; padding-top: 2rem; }
.admin-form label { display: grid; gap: .45rem; margin-top: 1rem; }
.admin-form label>span { font-size: .82rem; font-weight: 800; }
.admin-form input { width: 100%; min-height: 3.1rem; border: 1px solid #d8cac3; border-radius: .8rem; padding: 0 .9rem; color: var(--ink); background: #fff; outline: none; }
.admin-form input:focus { border-color: #9d5262; box-shadow: 0 0 0 3px rgba(157,82,98,.14); }
.admin-form .upload-button { margin-top: 1.5rem; }
.credentials-saved { margin: 0 0 1rem; border-radius: .75rem; padding: .8rem .9rem; color: #315740; background: #edf6ef; font-size: .82rem; line-height: 1.5; }
.security-note { display: grid; grid-template-columns: 2rem 1fr; gap: .75rem; margin: 1.25rem .5rem 0; color: var(--muted); font-size: .84rem; line-height: 1.6; }
.security-note svg { width: 1.5rem; color: var(--wine); }
.security-note p { margin: 0; }
.connected-panel { display: grid; grid-template-columns: 4rem 1fr; gap: 1.25rem; }
.admin-success-icon { width: 4rem; height: 4rem; display: grid; place-items: center; border-radius: 50%; color: #fff; background: #416653; }
.admin-success-icon svg { width: 1.7rem; }
.connected-panel .eyebrow { margin: .25rem 0 .4rem; color: #52735f; }
.admin-actions { margin-top: 1.3rem; display: flex; flex-wrap: wrap; gap: .7rem; }
.admin-actions .primary-button { text-decoration: none; }
.danger-button { min-height: 3.25rem; border: 1px solid #cfaeb4; border-radius: 999px; padding: 0 1.25rem; color: #912d40; background: #fff; font-weight: 800; }
.danger-button:hover { background: #faeff1; }
.admin-message { border: 1px solid #b8d1bf; border-radius: .9rem; margin: 0 0 1rem; padding: .9rem 1rem; color: #315740; background: #edf6ef; }
.admin-message.error { border-color: #deb8bf; color: #8e293b; background: #fbf0f2; }

.public-info-page { min-height: 100svh; background: linear-gradient(145deg,#f8f5ef,#eee5dc); }
.public-info-shell { width: min(calc(100% - 2rem),68rem); margin: 0 auto; padding: clamp(1rem,5vw,4rem) 0; }
.public-info-hero { min-height: min(38rem,calc(100svh - 8rem)); display: grid; overflow: hidden; border: 1px solid #ded2ca; border-radius: 1.8rem; background: rgba(255,253,249,.95); box-shadow: 0 24px 80px rgba(64,43,37,.12); }
.public-info-copy { width: min(100%,48rem); align-self: center; padding: clamp(2rem,7vw,5.5rem); }
.public-info-copy .eyebrow { color: #9b6670; }
.public-info-copy h1, .legal-shell h1 { margin: 0; font-family: "Cormorant Garamond",Georgia,serif; font-size: clamp(3.7rem,9vw,7rem); line-height: .86; font-weight: 600; letter-spacing: -.055em; }
.public-info-copy>p:not(.eyebrow) { margin: 1.25rem 0 0; color: var(--muted); font-size: 1rem; line-height: 1.75; }
.public-info-links { display: flex; flex-wrap: wrap; gap: .7rem 1.2rem; margin-top: 2rem; }
.public-info-links a, .legal-footer a, .legal-shell section a { color: var(--wine); font-weight: 800; }
.legal-shell { width: min(calc(100% - 2rem),48rem); margin: 0 auto; padding: clamp(2rem,7vw,5rem) 0; }
.legal-shell header { margin: clamp(3rem,9vw,6rem) 0 3rem; }
.legal-shell header .eyebrow { margin-bottom: .65rem; color: #9b6670; }
.legal-shell h1 { max-width: 44rem; font-size: clamp(3.3rem,9vw,6.2rem); }
.legal-updated { margin: 1.2rem 0 0; color: var(--muted); font-size: .86rem; }
.legal-shell section { margin-top: 1rem; border: 1px solid #ded2ca; border-radius: 1.2rem; padding: clamp(1.2rem,4vw,2rem); background: rgba(255,253,249,.88); }
.legal-shell section h2 { margin: 0 0 .65rem; font-family: "Cormorant Garamond",Georgia,serif; font-size: 1.75rem; line-height: 1; }
.legal-shell section p { margin: .65rem 0 0; color: var(--muted); line-height: 1.75; }
.legal-shell section code { padding: .12rem .3rem; border-radius: .25rem; color: var(--wine); background: #f3e6e7; }
.legal-footer { display: flex; flex-wrap: wrap; gap: 1rem 1.5rem; margin-top: 2rem; padding: 1rem .25rem; font-size: .86rem; }

button:focus-visible, .drop-zone:focus-visible { outline: 3px solid rgba(157,82,98,.35); outline-offset: 3px; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes hero-drift { from { transform: scale(1.01); } to { transform: scale(1.065) translate3d(-.5%,.35%,0); } }
@keyframes cinema-reveal { from { opacity: 0; transform: scale(1.018); } to { opacity: 1; transform: scale(1); } }

@media (max-width:960px) {
  .wedding-page { display: block; }
  .story-panel {
    --mobile-photo-height: clamp(17rem,36svh,22rem);
    min-height: 0;
    padding-top: var(--mobile-photo-height);
    background: #211217;
  }
  .story-image {
    top: 0;
    bottom: auto;
    height: var(--mobile-photo-height);
    object-position: 50% 34%;
    animation: none;
  }
  .story-overlay {
    top: 0;
    bottom: auto;
    height: var(--mobile-photo-height);
    background: linear-gradient(180deg,rgba(12,8,9,.02) 50%,rgba(18,9,12,.48) 100%);
  }
  .story-copy {
    position: relative;
    left: auto;
    right: auto;
    bottom: auto;
    max-width: none;
    padding: 1.2rem clamp(1.4rem,6vw,3rem) 1.45rem;
    background: linear-gradient(135deg,#2b171e,#1d1115);
  }
  .story-copy .eyebrow { margin-bottom: .55rem; }
  .story-copy h1 { max-width: 32rem; font-size: clamp(2.55rem,11vw,3.35rem); line-height: .88; }
  .story-copy>p:last-child, .monogram { display: none; }
  .upload-panel { min-height: 64svh; padding: 2rem 1.25rem 3rem; }
  .mobile-brand { display: flex; align-items: center; justify-content: center; gap: .45rem; margin-bottom: 2rem; color: var(--wine); font-size: .74rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
  .camera-mark { display: none; }
  .upload-heading h2 { max-width: 22rem; margin-inline: auto; font-size: clamp(2.35rem,9.5vw,2.8rem); line-height: .94; text-wrap: balance; }
  .upload-heading>p:last-child { margin-bottom: 1.5rem; }
  .drop-zone { min-height: 16rem; }
  .desktop-only { display: none; }
  .gallery-header { align-items: center; }
  .gallery-grid { columns: 3 11rem; column-gap: .7rem; }
  .gallery-item { margin-bottom: .7rem; border-radius: .75rem; }
}

@media (max-width:420px) {
  .story-panel { --mobile-photo-height: clamp(16rem,34svh,19rem); min-height: 0; }
  .story-copy { left: auto; right: auto; bottom: auto; padding: 1.05rem 1.4rem 1.25rem; }
  .story-copy h1 { font-size: clamp(2.35rem,10.8vw,2.65rem); }
  .story-copy .eyebrow { margin-bottom: .65rem; }
  .upload-panel { padding-top: 1.5rem; }
  .mobile-brand { margin-bottom: 1.25rem; }
  .upload-heading h2 { max-width: 20rem; font-size: clamp(2.15rem,9.8vw,2.45rem); }
  .drop-zone { min-height: 15rem; padding: 1.4rem; }
  .selection-card { padding: 1rem; }
  .privacy-note { padding: 0 .5rem; }
  .gallery-section { padding-top: 3.5rem; }
  .gallery-header { align-items: flex-start; }
  .gallery-header h2 { font-size: 3.15rem; }
  .gallery-header>div>p:last-child { max-width: 15rem; font-size: .9rem; }
  .gallery-header .outline-button { width: 2.8rem; padding: 0; font-size: 0; }
  .gallery-header .outline-button svg { width: 1.1rem; }
  .gallery-grid { columns: 2 8rem; }
  .admin-shell { width: min(calc(100% - 1.5rem),52rem); padding-top: 1.3rem; }
  .admin-header { margin-top: 3rem; }
  .admin-header h1 { font-size: 3.4rem; }
  .redirect-box { margin-left: 0; grid-template-columns: 1fr; }
  .redirect-box .outline-button { justify-self: start; }
  .connected-panel { grid-template-columns: 1fr; }
  .password-panel { grid-template-columns: 1fr; }
  .qr-admin-panel { grid-template-columns: 1fr; }
  .qr-admin-preview { width: min(100%,15rem); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

@media (max-width:960px) {
  .gallery-section { padding-inline: .75rem; }
  .gallery-header { padding-inline: .5rem; align-items: flex-end; }
  .gallery-header h2 { font-size: clamp(3.45rem,14vw,5.7rem); }
  .gallery-header>div>p:last-child { max-width: 27rem; }
  .cinema-stage { aspect-ratio: 4/5; min-height: 34rem; max-height: 76svh; border-radius: .75rem; }
  .cinema-media-frame { inset: 2.5%; }
  .cinema-caption { bottom: 5.3rem; }
  .cinema-caption h3 { max-width: 82%; font-size: clamp(2rem,8vw,3.4rem); }
  .cinema-arrow { width: 2.6rem; height: 2.6rem; }
  .cinema-prev { left: .65rem; }
  .cinema-next { right: .65rem; }
  .cinema-toolbar { left: 1.2rem; right: 1.2rem; gap: .75rem; }
  .cinema-filmstrip { margin-top: .85rem; }
  .filmstrip-item { flex-basis: 4.4rem; }
  .gallery-index-heading { padding-inline: .4rem; margin-top: 4.5rem; }
  .gallery-grid { columns: 3 11rem; column-gap: .55rem; }
  .gallery-item { margin-bottom: .55rem; }
  .lightbox-content { padding-inline: 3.8rem; }
}

@media (max-width:480px) {
  .gallery-header { align-items: flex-start; }
  .gallery-header .outline-button { width: 2.8rem; padding: 0; font-size: 0; }
  .gallery-header h2 { font-size: clamp(3.15rem,16vw,4.5rem); }
  .gallery-header>div>p:last-child { font-size: .88rem; }
  .cinema-stage { min-height: 30rem; max-height: 72svh; }
  .cinema-caption h3 { max-width: 100%; padding-right: 1.5rem; }
  .cinema-caption>p:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .cinema-control>span { display: none; }
  .cinema-expand { justify-self: end; }
  .cinema-toolbar { grid-template-columns: 1.8rem 1fr 1.8rem; }
  .gallery-index-heading h3 { font-size: 3.2rem; }
  .gallery-index-heading>span { font-size: .68rem; }
  .gallery-grid { columns: 2 8rem; }
  .lightbox-content { padding: 3.8rem .75rem 5rem; }
  .lightbox-arrow { top: auto; bottom: 1rem; width: 2.6rem; height: 2.6rem; transform: none; }
  .lightbox-prev { left: .75rem; }
  .lightbox-next { right: .75rem; }
  .lightbox-meta { left: 3.9rem; right: 3.9rem; bottom: 1.15rem; }
  .lightbox-meta p { font-size: 1rem; }
}
