/* ============================================
   Still Sonic Media — gallery-page.css
   Shared layout for the gallery pages (concert, jimbo, scotland, tunisia,
   streets, florida, food, wildlife): fonts, nav, page hero, masonry grid, lightbox.
   Change it once here and every gallery page follows.
   ============================================ */
@font-face { font-family: 'Redaction35'; src: url('fonts/Redaction_35-Regular.woff2') format('woff2'); font-weight: 400; font-display: swap; }
@font-face { font-family: 'Redaction35'; src: url('fonts/Redaction_35-Bold.woff2') format('woff2'); font-weight: 700; font-display: swap; }
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root { --bg: #0f0d0b; --surface: #15120f; --border: #241f1a; --text: #f7f2ea; --muted: #7a7268; --accent: #c8a97e; }
html { scroll-behavior: smooth; }
body { background: var(--bg); color: var(--text); font-family: 'Redaction35', Georgia, serif; font-weight: 400; overflow-x: hidden; }
nav { position: fixed; top: 0; left: 0; right: 0; z-index: 1000; display: flex; align-items: center; justify-content: space-between; padding: 1.5rem 3rem; background: linear-gradient(to bottom, rgba(15,13,11,0.95) 0%, transparent 100%); backdrop-filter: blur(8px); border-bottom: 1px solid rgba(255,255,255,0.04); }
.nav-logo { display: flex; align-items: center; text-decoration: none; }
.nav-links { display: flex; gap: 2.5rem; list-style: none; }
.nav-links a { text-decoration: none; color: var(--muted); font-size: 0.75rem; letter-spacing: 0.18em; text-transform: uppercase; transition: color 0.3s; font-family: 'Redaction35', Georgia, serif; }
.nav-links a:hover { color: var(--text); }
.nav-right { display: flex; align-items: center; gap: 1rem; }
.nav-instagram { color: var(--muted); text-decoration: none; display: flex; align-items: center; transition: color 0.3s; }
.nav-instagram:hover { color: var(--text); }
.nav-hamburger { display: none; background: none; border: none; cursor: pointer; flex-direction: column; gap: 5px; padding: 4px; }
.nav-hamburger span { display: block; width: 22px; height: 1px; background: var(--muted); transition: transform 0.3s, opacity 0.3s; }
.nav-hamburger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
@media (max-width: 768px) { nav { padding: 1.2rem 1.5rem; } .nav-hamburger { display: flex; } .nav-links { display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(15,13,11,0.97); backdrop-filter: blur(12px); flex-direction: column; align-items: center; justify-content: center; gap: 2.5rem; z-index: 99; } .nav-links.open { display: flex; } .nav-links a { font-size: 1.1rem; letter-spacing: 0.22em; } }
.page-hero { min-height: 45vh; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 10rem 2rem 4rem; position: relative; overflow: hidden; }
.page-hero-bg { position: absolute; inset: 0; background: radial-gradient(ellipse 60% 50% at 50% 50%, rgba(200,169,126,0.05) 0%, transparent 70%); pointer-events: none; }
.gallery-hero-eyebrow { font-size: 0.68rem; letter-spacing: 0.35em; text-transform: uppercase; color: var(--accent); margin-bottom: 1rem; }
.gallery-hero-title { font-family: 'Redaction35', Georgia, serif; font-size: clamp(3rem, 8vw, 6rem); font-weight: 400; line-height: 1.0; letter-spacing: -0.01em; }
.gallery-hero-subtitle { font-size: 0.78rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); margin-top: 1.5rem; }
.page-hero-line { width: 1px; height: 40px; background: linear-gradient(to bottom, var(--accent), transparent); margin: 2rem auto 0; }
#gallery { padding: 5rem 2rem 8rem; }
.gallery-grid { columns: 3 320px; column-gap: 1rem; max-width: 1400px; margin: 0 auto; }
.gallery-item { break-inside: avoid; margin-bottom: 1rem; position: relative; overflow: hidden; cursor: pointer; }
.gallery-item img { width: 100%; display: block; transition: transform 0.6s cubic-bezier(0.25,0.46,0.45,0.94); }
.gallery-item:hover img { transform: scale(1.04); }
.gallery-item-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(15,13,11,0.8) 0%, transparent 50%); opacity: 0; transition: opacity 0.4s; display: flex; align-items: flex-end; padding: 1.5rem; }
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gallery-item-label { font-size: 0.7rem; letter-spacing: 0.15em; text-transform: uppercase; color: var(--text); }
.lightbox { position: fixed; inset: 0; z-index: 9000; background: rgba(0,0,0,0.95); display: none; align-items: center; justify-content: center; padding: 2rem; }
.lightbox.active { display: flex; }
.lightbox img { max-width: 90vw; max-height: 90vh; object-fit: contain; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: scale(0.97); } to { opacity: 1; transform: scale(1); } }
.lightbox-close { position: absolute; top: 1.5rem; right: 2rem; font-size: 1.5rem; color: var(--muted); cursor: pointer; background: none; border: none; font-family: inherit; transition: color 0.2s; z-index: 9001; }
.lightbox-close:hover { color: var(--text); }
.lightbox-nav { position: absolute; top: 50%; transform: translateY(-50%); background: none; border: none; color: var(--muted); font-size: 2rem; cursor: pointer; padding: 1rem; transition: color 0.2s; z-index: 9001; }
.lightbox-nav:hover { color: var(--text); }
.lightbox-prev { left: 1rem; } .lightbox-next { right: 1rem; }
footer { padding: 2rem 3rem; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; font-size: 0.7rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted); }
.footer-back { color: var(--accent); text-decoration: none; font-size: 0.7rem; letter-spacing: 0.18em; text-transform: uppercase; transition: opacity 0.2s; }
.footer-back:hover { opacity: 0.7; }
@media (max-width: 768px) { .gallery-grid { columns: 1; } footer { flex-direction: column; gap: 0.75rem; text-align: center; } }

/* Stop double-tap zooming on phones; pinch zoom still works. */
html, body { touch-action: manipulation; }
/* Project hero: the cover photo from the homepage card, dimmed behind the title.
   Opening a project from its card grows that photo into this spot (site.js). */
.page-hero.has-photo { min-height: 58vh; }
.page-hero-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: brightness(0.32) saturate(0.9); view-transition-name: proj-photo; }
.page-hero.has-photo::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(15,13,11,0.55) 0%, transparent 35%, transparent 60%, var(--bg, #0f0d0b) 100%); pointer-events: none; }
.page-hero.has-photo > :not(.page-hero-photo) { position: relative; z-index: 1; }
.page-hero.has-photo .page-hero-bg { position: absolute; }
.gallery-hero-title { view-transition-name: proj-title; }
/* Project credits under the title (filled in by ui.js from the admin) */
.page-credits { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1.75rem; margin: 1.25rem auto 0; max-width: 720px; animation: credits-in 0.6s ease both; }
.page-credits div { display: flex; gap: 0.55rem; align-items: baseline; }
.page-credits dt { font-family: 'Space Mono', monospace; font-size: 0.58rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--accent, #c8a97e); }
.page-credits dd { margin: 0; font-size: 0.85rem; color: var(--text, #f7f2ea); opacity: 0.85; }
@keyframes credits-in { from { opacity: 0; transform: translateY(6px); } }
@media (prefers-reduced-motion: reduce) { .page-credits { animation: none; } }
