/* ============================================================
   PANCHAPURI MUSEUM — Main Stylesheet
   Design: Refined Minimalist with Warm Earth Tones
   Fonts: DM Serif Display + Jost + Space Mono
   ============================================================ */

:root {
  --ink:    #1A1209;
  --earth:  #2C1F0E;
  --ochre:  #B8892A;
  --gold:   #D4A843;
  --cream:  #F5EFE3;
  --paper:  #FAF7F2;
  --white:  #FFFFFF;
  --grey:   #7A7065;
  --border: rgba(180,150,90,0.18);
  --shadow: 0 2px 40px rgba(26,18,9,0.10);
  --radius: 3px;
  --tr:     all 0.45s cubic-bezier(0.22,1,0.36,1);
  --serif:  'DM Serif Display', 'Laila', Georgia, serif;
  --sans:   'Jost', 'Laila', system-ui, sans-serif;
  --mono:   'Space Mono', monospace;
  --header-h: 80px;
}

/* ── Reset ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; overflow-x: hidden; }
body { font-family: var(--sans); background: var(--paper); color: var(--ink); line-height: 1.7; position: relative; }
html.nav-open, html.nav-open body { overflow: hidden; height: 100%; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
ul { list-style: none; }

/* ── Custom Cursor ─────────────────────────────── */
.cursor-dot {
  width: 6px; height: 6px; background: var(--gold); border-radius: 50%;
  position: fixed; top: 0; left: 0; pointer-events: none; z-index: 9999;
  transform: translate(-50%,-50%);
  transition: opacity 0.3s;
}
.cursor-ring {
  width: 32px; height: 32px;
  border: 1.5px solid var(--gold); border-radius: 50%;
  position: fixed; top: 0; left: 0; pointer-events: none; z-index: 9998;
  transform: translate(-50%,-50%);
  transition: width 0.3s, height 0.3s, border-color 0.3s, transform 0.1s;
}
body:hover .cursor-dot, body:hover .cursor-ring { opacity: 1; }
body.cursor-hover .cursor-ring { width: 48px; height: 48px; border-color: var(--ochre); }

/* ── Page Loader ───────────────────────────────── */
.page-loader {
  position: fixed; inset: 0; background: var(--ink); z-index: 10000;
  display: flex; align-items: center; justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}
.page-loader.hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-inner { text-align: center; }
.loader-logo {
  font-family: var(--serif); font-size: 2.5rem; color: var(--gold);
  letter-spacing: 4px; margin-bottom: 24px;
  animation: pulse 1.5s ease infinite;
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.4} }
.loader-bar {
  width: 180px; height: 2px; background: rgba(255,255,255,0.1); border-radius: 2px;
  margin: 0 auto; overflow: hidden;
}
.loader-fill {
  height: 100%; width: 0; background: var(--gold); border-radius: 2px;
  animation: loadFill 0.9s ease forwards;
}
@keyframes loadFill { to { width: 100%; } }

/* ── Header ────────────────────────────────────── */
#siteHeader {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--header-h);
  background: transparent;
  transition: var(--tr);
}
#siteHeader.scrolled {
  background: rgba(250,247,242,0.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 1px 30px rgba(26,18,9,0.07);
}
.header-inner {
  max-width: 1300px; margin: 0 auto; height: 100%;
  padding: 0 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}

/* Logo */
.site-logo { display: flex; align-items: center; gap: 12px; }
.logo-img { height: 44px; width: auto; object-fit: contain; }
.logo-text { display: flex; flex-direction: column; line-height: 1.1; }
.logo-name { font-family: var(--serif); font-size: 1.05rem; color: var(--ink); }
.logo-tagline { font-size: 0.65rem; letter-spacing: 2px; text-transform: uppercase; color: var(--ochre); }
#siteHeader:not(.scrolled) .logo-name,
#siteHeader:not(.scrolled) .logo-tagline { color: var(--white); }
#siteHeader:not(.scrolled) .logo-tagline { color: var(--gold); }

/* Navigation */
.main-nav { flex: 1; display: flex; justify-content: center; }
.nav-list { display: flex; gap: 6px; }
.nav-link {
  display: inline-block; padding: 8px 14px;
  font-size: 0.78rem; font-weight: 500; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--ink);
  position: relative; transition: color 0.3s;
}
#siteHeader:not(.scrolled) .nav-link { color: rgba(255,255,255,0.88); }
.nav-link::after {
  content: ''; position: absolute; bottom: 4px; left: 14px; right: 14px;
  height: 1px; background: var(--gold); transform: scaleX(0);
  transform-origin: right; transition: transform 0.4s cubic-bezier(0.22,1,0.36,1);
}
.nav-link:hover::after, .nav-link.active::after { transform: scaleX(1); transform-origin: left; }
.nav-link:hover { color: var(--ochre); }
#siteHeader:not(.scrolled) .nav-link:hover { color: var(--gold); }
.nav-link.active { color: var(--ochre); }

/* Header actions */
.header-actions { display: flex; align-items: center; gap: 16px; }
.btn-visit {
  padding: 9px 22px; font-size: 0.75rem; font-weight: 600;
  letter-spacing: 1.5px; text-transform: uppercase;
  background: var(--gold); color: var(--ink); border-radius: var(--radius);
  transition: var(--tr);
}
.btn-visit:hover { background: var(--ochre); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(180,136,42,0.35); }
#siteHeader:not(.scrolled) .btn-visit { background: rgba(255,255,255,0.15); color: white; border: 1px solid rgba(255,255,255,0.4); }
#siteHeader:not(.scrolled) .btn-visit:hover { background: var(--gold); color: var(--ink); border-color: var(--gold); }

/* Mobile toggle */
.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  width: 44px; height: 44px; justify-content: center; align-items: center;
  padding: 6px; position: relative; z-index: 1001;
  touch-action: manipulation; -webkit-tap-highlight-color: transparent;
  border-radius: 50%; transition: background-color 0.3s ease;
}
.nav-toggle:active { background-color: rgba(180,150,90,0.12); }
.nav-toggle span {
  display: block; width: 22px; height: 1.5px; background: var(--ink);
  transition: transform 0.4s cubic-bezier(0.22,1,0.36,1), opacity 0.25s ease, background-color 0.3s;
  transform-origin: center;
}
#siteHeader:not(.scrolled) .nav-toggle span { background: white; }
.nav-toggle.open span { background: var(--ink) !important; }
.nav-toggle.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.nav-toggle.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* Mobile drawer */
.mobile-drawer {
  position: fixed; inset: 0; top: var(--header-h);
  background: rgba(250,247,242,0.98); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  z-index: 999; overflow-y: auto; -webkit-overflow-scrolling: touch;
  visibility: hidden;
  /* pointer-events:none while closed is a deliberate second line of defense:
     even if visibility/transform ever get out of sync (e.g. an interrupted
     transition on iOS Safari), a closed drawer can never intercept or "eat"
     a touch on the page behind it. */
  pointer-events: none;
  transform: translateX(100%); transition: transform 0.5s cubic-bezier(0.22,1,0.36,1), visibility 0s linear 0.5s;
  box-shadow: -8px 0 40px rgba(26,18,9,0.12);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.mobile-drawer.open {
  transform: translateX(0); visibility: visible; pointer-events: auto;
  transition: transform 0.5s cubic-bezier(0.22,1,0.36,1), visibility 0s linear 0s;
}
.drawer-inner { padding: 40px 32px; }
.drawer-nav { display: flex; flex-direction: column; gap: 4px; }
.drawer-link {
  display: block; padding: 16px 0; font-family: var(--serif);
  font-size: clamp(1.25rem, 5vw, 1.6rem); color: var(--ink); border-bottom: 1px solid var(--border);
  touch-action: manipulation; -webkit-tap-highlight-color: transparent;
  opacity: 0; transform: translateX(24px);
  transition: color 0.3s, padding-left 0.3s, opacity 0.45s ease, transform 0.45s ease;
}
.mobile-drawer.open .drawer-link { opacity: 1; transform: translateX(0); }
.drawer-nav li:nth-child(1) .drawer-link { transition-delay: 0.08s; }
.drawer-nav li:nth-child(2) .drawer-link { transition-delay: 0.13s; }
.drawer-nav li:nth-child(3) .drawer-link { transition-delay: 0.18s; }
.drawer-nav li:nth-child(4) .drawer-link { transition-delay: 0.23s; }
.drawer-nav li:nth-child(5) .drawer-link { transition-delay: 0.28s; }
.drawer-nav li:nth-child(6) .drawer-link { transition-delay: 0.33s; }
.drawer-nav li:nth-child(7) .drawer-link { transition-delay: 0.38s; }
.drawer-link:hover, .drawer-link:active, .drawer-link.active { color: var(--ochre); padding-left: 12px; }
.drawer-footer {
  margin-top: 40px; opacity: 0; transform: translateY(16px);
  transition: opacity 0.45s ease 0.4s, transform 0.45s ease 0.4s;
}
.mobile-drawer.open .drawer-footer { opacity: 1; transform: translateY(0); }
.drawer-contact { display: flex; flex-direction: column; gap: 12px; }
.drawer-contact a { display: flex; gap: 10px; align-items: center; font-size: 0.9rem; color: var(--grey); touch-action: manipulation; }
.drawer-contact a i { color: var(--gold); width: 16px; }

@media (max-width: 480px) {
  .drawer-inner { padding: 28px 24px; }
  .drawer-link { padding: 14px 0; }
}

/* ── Page Hero (generic) ───────────────────────── */
.page-hero {
  min-height: 45vh; display: flex; align-items: flex-end;
  position: relative; overflow: hidden;
  padding: calc(var(--header-h) + 60px) 32px 60px;
  background: var(--earth);
}
.page-hero-bg {
  position: absolute; inset: 0; object-fit: cover; width: 100%; height: 100%;
  opacity: 0.35; transition: transform 8s ease;
}
.page-hero:hover .page-hero-bg { transform: scale(1.04); }
.page-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(160deg, rgba(26,18,9,0.6) 0%, rgba(44,31,14,0.85) 100%);
}
.page-hero-content {
  position: relative; z-index: 1; max-width: 1300px; margin: 0 auto; width: 100%;
}
.page-hero-tag {
  display: inline-block; font-family: var(--mono); font-size: 0.7rem;
  letter-spacing: 3px; text-transform: uppercase; color: var(--gold);
  border: 1px solid rgba(212,168,67,0.4); padding: 4px 12px; border-radius: 2px;
  margin-bottom: 16px;
}
.page-hero h1 {
  font-family: var(--serif); font-size: clamp(2.5rem, 6vw, 5rem);
  color: var(--white); line-height: 1.1; margin-bottom: 20px;
}
.page-hero p { font-size: 1.1rem; color: rgba(255,255,255,0.75); max-width: 600px; }

/* ── Section layouts ───────────────────────────── */
.container { max-width: 1300px; margin: 0 auto; padding: 0 32px; }
.section { padding: 100px 0; }
.section-sm { padding: 60px 0; }
.section-dark { background: var(--ink); color: var(--white); }
.section-earth { background: var(--earth); color: var(--white); }
.section-cream { background: var(--cream); }

.section-label {
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 3px;
  text-transform: uppercase; color: var(--ochre); margin-bottom: 12px;
  display: block;
}
.section-title {
  font-family: var(--serif); font-size: clamp(2rem, 4vw, 3.2rem);
  line-height: 1.15; margin-bottom: 20px; color: var(--ink);
}
.section-dark .section-title, .section-earth .section-title { color: var(--white); }
.section-subtitle {
  font-size: 1.05rem; color: var(--grey); max-width: 580px; line-height: 1.75;
}
.section-dark .section-subtitle { color: rgba(255,255,255,0.65); }
.section-header { margin-bottom: 64px; }
.section-header.centered { text-align: center; }
.section-header.centered .section-subtitle { margin: 0 auto; }

/* ── Buttons ───────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 28px; font-size: 0.8rem; font-weight: 600;
  letter-spacing: 1.5px; text-transform: uppercase;
  border-radius: var(--radius); transition: var(--tr); cursor: pointer;
}
.btn-primary {
  background: var(--gold); color: var(--ink);
}
.btn-primary:hover { background: var(--ochre); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(180,136,42,0.35); }
.btn-outline {
  border: 1.5px solid var(--ink); color: var(--ink); background: transparent;
}
.btn-outline:hover { background: var(--ink); color: var(--white); }
.btn-outline-white {
  border: 1.5px solid rgba(255,255,255,0.4); color: var(--white); background: transparent;
}
.btn-outline-white:hover { background: rgba(255,255,255,0.1); border-color: white; }
.btn-ghost { color: var(--ochre); font-size: 0.8rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; display: inline-flex; align-items: center; gap: 6px; }
.btn-ghost::after { content: '→'; transition: transform 0.3s; }
.btn-ghost:hover::after { transform: translateX(4px); }

.share-btn {
  width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border);
  background: transparent; color: var(--grey); display: inline-flex; align-items: center;
  justify-content: center; font-size: 0.85rem; cursor: pointer; transition: all 0.25s;
}
.share-btn:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); transform: translateY(-2px); }

/* ── HOME: Hero Slider ─────────────────────────── */
.hero-slider { position: relative; height: 100vh; min-height: 600px; overflow: hidden; background: var(--ink); }
.hero-slide { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease; }
.hero-slide.active { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.05); transition: transform 8s ease; }
.hero-slide.active img { transform: scale(1); }
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(26,18,9,0.3) 0%, rgba(26,18,9,0.75) 100%);
}
.hero-content {
  position: absolute; bottom: 15%; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 1300px; padding: 0 32px; z-index: 2;
}
.hero-badge {
  display: inline-block; font-family: var(--mono); font-size: 0.68rem;
  letter-spacing: 3px; text-transform: uppercase; color: var(--gold);
  border: 1px solid rgba(212,168,67,0.5); padding: 5px 14px; border-radius: 2px;
  margin-bottom: 20px; animation: fadeUp 0.8s ease both; animation-delay: 0.2s;
}
.hero-title {
  font-family: var(--serif); font-size: clamp(3rem, 7vw, 6.5rem);
  color: var(--white); line-height: 1.05; max-width: 800px;
  animation: fadeUp 0.8s ease both; animation-delay: 0.35s;
}
.hero-desc {
  font-size: 1.1rem; color: rgba(255,255,255,0.72); max-width: 500px;
  margin: 20px 0 32px; line-height: 1.7;
  animation: fadeUp 0.8s ease both; animation-delay: 0.5s;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; animation: fadeUp 0.8s ease both; animation-delay: 0.65s; }
@keyframes fadeUp { from{opacity:0;transform:translateY(30px)} to{opacity:1;transform:translateY(0)} }

.hero-controls {
  position: absolute; bottom: 32px; right: 32px; z-index: 3;
  display: flex; gap: 8px;
}
.hero-btn {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,0.3); color: white; font-size: 0.9rem;
  display: flex; align-items: center; justify-content: center;
  background: rgba(26,18,9,0.4); backdrop-filter: blur(8px);
  transition: var(--tr);
}
.hero-btn:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }

.hero-dots {
  position: absolute; bottom: 40px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 8px; z-index: 3;
}
.hero-dot {
  width: 6px; height: 6px; border-radius: 3px; background: rgba(255,255,255,0.35);
  transition: all 0.4s ease; cursor: pointer;
}
.hero-dot.active { background: var(--gold); width: 24px; }

.hero-scroll-hint {
  position: absolute; bottom: 40px; left: 32px; z-index: 3;
  display: flex; align-items: center; gap: 12px;
  font-family: var(--mono); font-size: 0.65rem; letter-spacing: 2px;
  text-transform: uppercase; color: rgba(255,255,255,0.5);
}
.hero-scroll-hint::before {
  content: ''; width: 40px; height: 1px; background: rgba(255,255,255,0.3);
  animation: scrollLine 2s ease infinite;
}
@keyframes scrollLine { 0%{width:0;opacity:0} 50%{width:40px;opacity:1} 100%{width:40px;opacity:0} }

/* ── HOME: Stats bar ───────────────────────────── */
.stats-bar {
  background: var(--ink);
  border-top: 1px solid rgba(212,168,67,0.2);
  border-bottom: 1px solid rgba(212,168,67,0.2);
}
.stats-bar .container { display: flex; }
.stat-item {
  flex: 1; padding: 32px 24px; text-align: center;
  border-right: 1px solid rgba(255,255,255,0.07);
}
.stat-item:last-child { border-right: none; }
.stat-number {
  font-family: var(--serif); font-size: 2.5rem; color: var(--gold);
  line-height: 1; display: block;
}
.stat-label { font-size: 0.72rem; letter-spacing: 2px; text-transform: uppercase; color: rgba(255,255,255,0.45); margin-top: 6px; }

/* ── HOME: About section ───────────────────────── */
.about-split { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.about-mvh-grid { grid-template-columns: repeat(3, 1fr); }
.artifact-detail-grid { grid-template-columns: 1fr 1fr; }
.about-image-wrap { position: relative; }
.about-image-main {
  width: 100%; aspect-ratio: 4/5; object-fit: cover; border-radius: 2px;
  transition: var(--tr);
}
.about-image-accent {
  position: absolute; width: 55%; aspect-ratio: 1;
  object-fit: cover; border: 6px solid var(--paper);
  border-radius: 2px; bottom: -40px; right: -40px;
  box-shadow: var(--shadow);
}
.about-year-badge {
  position: absolute; top: 32px; left: -24px;
  background: var(--gold); color: var(--ink);
  font-family: var(--serif); font-size: 1.6rem; line-height: 1;
  padding: 20px 16px; border-radius: 2px; text-align: center;
  box-shadow: var(--shadow);
}
.about-year-badge small { display: block; font-family: var(--sans); font-size: 0.65rem; letter-spacing: 1.5px; text-transform: uppercase; margin-top: 4px; }
.about-text { padding-bottom: 40px; }
.about-text p { color: var(--grey); margin-bottom: 20px; font-size: 1.02rem; }
.about-features { display: flex; gap: 32px; margin: 36px 0; flex-wrap: wrap; }
.about-feature { display: flex; align-items: flex-start; gap: 12px; }
.about-feature i { color: var(--gold); margin-top: 3px; font-size: 0.9rem; }
.about-feature-text strong { display: block; font-size: 0.85rem; font-weight: 600; margin-bottom: 2px; }
.about-feature-text span { font-size: 0.8rem; color: var(--grey); }

/* ── Collection card grid ──────────────────────── */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 2px; }
.card-grid-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid-4 { grid-template-columns: repeat(4, 1fr); }

.artifact-card {
  background: var(--white); position: relative; overflow: hidden; cursor: pointer;
  transition: var(--tr);
}
.artifact-card:hover { transform: translateY(-4px); box-shadow: 0 20px 60px rgba(26,18,9,0.14); }
.artifact-card-img {
  width: 100%; aspect-ratio: 4/3; object-fit: cover;
  transition: transform 0.7s cubic-bezier(0.22,1,0.36,1);
}
.artifact-card:hover .artifact-card-img { transform: scale(1.06); }
.artifact-card-body { padding: 20px 24px 24px; }
.artifact-card-cat {
  font-family: var(--mono); font-size: 0.62rem; letter-spacing: 2px;
  text-transform: uppercase; color: var(--ochre); margin-bottom: 8px; display: block;
}
.artifact-card-title {
  font-family: var(--serif); font-size: 1.15rem; margin-bottom: 10px; color: var(--ink);
  line-height: 1.3;
}
.artifact-card-period { font-size: 0.8rem; color: var(--grey); }
.artifact-card-overlay {
  position: absolute; inset: 0; background: rgba(26,18,9,0.85);
  display: flex; flex-direction: column; justify-content: flex-end; padding: 24px;
  opacity: 0; transition: opacity 0.4s ease;
}
.artifact-card:hover .artifact-card-overlay { opacity: 1; }
.artifact-card-overlay p { color: rgba(255,255,255,0.8); font-size: 0.88rem; line-height: 1.6; margin-bottom: 16px; }
.artifact-card-overlay .btn { position: relative; z-index: 2; min-height: 44px; }
/* Touch devices (phones/tablets) have no :hover, so the overlay + its "View
   Detail" button were invisible and effectively unreachable — this was the
   reported "Collection button not working" bug. Show a lighter, always-on
   gradient with the button on touch devices instead of relying on hover. */
@media (hover: none), (pointer: coarse) {
  .artifact-card-overlay {
    opacity: 1;
    background: linear-gradient(to top, rgba(26,18,9,0.88) 0%, rgba(26,18,9,0.35) 55%, rgba(26,18,9,0) 100%);
  }
}

/* ── Gallery Grid ──────────────────────────────── */
.gallery-masonry {
  columns: 3; gap: 4px; column-gap: 4px;
}
.gallery-item {
  break-inside: avoid; margin-bottom: 4px;
  position: relative; overflow: hidden; cursor: pointer;
}
.gallery-item img { width: 100%; display: block; transition: transform 0.6s ease; }
.gallery-item:hover img { transform: scale(1.06); }
.gallery-item-overlay {
  position: absolute; inset: 0; background: linear-gradient(to top, rgba(26,18,9,0.85) 0%, transparent 60%);
  opacity: 0; transition: opacity 0.4s; display: flex; align-items: flex-end; padding: 20px;
}
.gallery-item:hover .gallery-item-overlay { opacity: 1; }
.gallery-item-overlay p { color: white; font-size: 0.88rem; line-height: 1.4; }
@media (hover: none), (pointer: coarse) {
  .gallery-item-overlay { opacity: 1; background: linear-gradient(to top, rgba(26,18,9,0.8) 0%, transparent 65%); }
}

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; background: rgba(10,8,5,0.95); z-index: 9000;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden; transition: all 0.4s;
}
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox-img { max-width: 90vw; max-height: 88vh; object-fit: contain; border-radius: 2px; }
.lightbox-close {
  position: absolute; top: 20px; right: 24px; font-size: 1.5rem; color: white;
  background: none; border: none; cursor: pointer; opacity: 0.7; transition: opacity 0.2s;
}
.lightbox-close:hover { opacity: 1; }
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  font-size: 1.2rem; color: white; background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.2); border-radius: 50%;
  width: 48px; height: 48px; display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: var(--tr);
}
.lightbox-nav:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }
.lightbox-caption { position: absolute; bottom: 24px; left: 50%; transform: translateX(-50%); color: rgba(255,255,255,0.7); font-size: 0.85rem; text-align: center; }

/* ── Blog Cards ────────────────────────────────── */
.blog-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.blog-card { background: var(--white); border-radius: var(--radius); overflow: hidden; transition: var(--tr); }
.blog-card:hover { transform: translateY(-4px); box-shadow: 0 20px 50px rgba(26,18,9,0.12); }
.blog-card-img { width: 100%; aspect-ratio: 16/10; object-fit: cover; transition: transform 0.6s ease; display: block; }
.blog-card:hover .blog-card-img { transform: scale(1.04); }
.blog-card-img-wrap { overflow: hidden; }
.blog-card-body { padding: 24px; }

/* ── Homepage Team section ────────────────────────── */
.home-team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; }
.home-team-card {
  text-align: center; background: var(--white); padding: 36px 24px;
  border-radius: var(--radius); transition: var(--tr);
}
.home-team-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); }
.home-team-photo {
  width: 90px; height: 90px; object-fit: cover; border-radius: 50%;
  margin: 0 auto 16px; border: 3px solid var(--gold); display: block;
}
.home-team-photo-placeholder {
  background: var(--border); display: flex; align-items: center; justify-content: center;
  color: var(--grey); font-size: 2rem;
}
.home-team-name { font-family: var(--serif); font-size: 1.1rem; margin-bottom: 4px; }
.home-team-role { font-size: 0.78rem; letter-spacing: 1px; text-transform: uppercase; color: var(--ochre); }
.blog-card-meta { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.blog-card-cat {
  font-family: var(--mono); font-size: 0.62rem; letter-spacing: 2px;
  text-transform: uppercase; color: var(--white);
  background: var(--ochre); padding: 3px 8px; border-radius: 2px;
}
.blog-card-date { font-size: 0.78rem; color: var(--grey); }
.blog-card-title {
  font-family: var(--serif); font-size: 1.2rem; line-height: 1.35;
  color: var(--ink); margin-bottom: 12px; transition: color 0.3s;
}
.blog-card:hover .blog-card-title { color: var(--ochre); }
.blog-card-excerpt { font-size: 0.88rem; color: var(--grey); line-height: 1.65; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.blog-card-footer { padding: 16px 24px; border-top: 1px solid var(--border); display: flex; justify-content: space-between; align-items: center; }
.blog-card-read { font-size: 0.75rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; color: var(--ochre); display: flex; gap: 6px; align-items: center; transition: gap 0.3s; }
.blog-card:hover .blog-card-read { gap: 10px; }

/* ── Blog single ───────────────────────────────── */
.blog-single-layout { display: grid; grid-template-columns: 1fr 340px; gap: 60px; max-width: 1200px; margin: 0 auto; }
.blog-body { font-size: 1.05rem; line-height: 1.85; color: #3A2E1E; }
.blog-body h2 { font-family: var(--serif); font-size: 1.8rem; color: var(--ink); margin: 2em 0 0.6em; }
.blog-body h3 { font-family: var(--serif); font-size: 1.4rem; color: var(--ink); margin: 1.6em 0 0.5em; }
.blog-body p { margin-bottom: 1.4em; }
.blog-body img { border-radius: 2px; margin: 2em 0; }
.blog-body blockquote {
  border-left: 3px solid var(--gold); padding: 16px 24px; margin: 2em 0;
  background: var(--cream); color: var(--earth); border-radius: 0 2px 2px 0;
  font-family: 'Laila', var(--sans); font-style: italic;
}
.blog-sidebar { position: sticky; top: calc(var(--header-h) + 32px); height: fit-content; }
.sidebar-widget { background: var(--cream); padding: 28px; border-radius: var(--radius); margin-bottom: 28px; }
.sidebar-widget h4 { font-family: var(--serif); font-size: 1.1rem; margin-bottom: 16px; padding-bottom: 12px; border-bottom: 1px solid var(--border); }
.sidebar-recent a { display: flex; gap: 12px; margin-bottom: 16px; color: var(--ink); transition: color 0.3s; }
.sidebar-recent a:hover { color: var(--ochre); }
.sidebar-recent img { width: 64px; height: 64px; object-fit: cover; border-radius: 2px; flex-shrink: 0; }
.sidebar-recent-title { font-size: 0.88rem; line-height: 1.4; font-weight: 500; }
.sidebar-recent-date { font-size: 0.73rem; color: var(--grey); margin-top: 4px; }
.cat-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-tag {
  font-size: 0.75rem; padding: 5px 12px; border: 1px solid var(--border);
  border-radius: 2px; color: var(--grey); transition: var(--tr);
}
.cat-tag:hover { background: var(--gold); color: var(--ink); border-color: var(--gold); }

/* ── Contact ───────────────────────────────────── */
.contact-layout { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px; }
.contact-info-item { display: flex; gap: 16px; margin-bottom: 32px; }
.contact-info-icon {
  width: 48px; height: 48px; background: var(--cream); border-radius: 2px;
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-size: 1rem; flex-shrink: 0;
}
.contact-info-text strong { display: block; font-weight: 600; margin-bottom: 4px; }
.contact-info-text span { color: var(--grey); font-size: 0.9rem; }
.contact-map { width: 100%; height: 300px; border-radius: 2px; margin-top: 32px; border: 1px solid var(--border); }

/* Form */
.museum-form { display: flex; flex-direction: column; gap: 20px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-label { font-size: 0.78rem; font-weight: 600; letter-spacing: 1px; text-transform: uppercase; color: var(--earth); }
.form-input, .form-textarea, .form-select {
  padding: 14px 16px; font-family: var(--sans); font-size: 0.95rem;
  background: var(--cream); border: 1.5px solid var(--border);
  border-radius: var(--radius); color: var(--ink); outline: none;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.form-input:focus, .form-textarea:focus, .form-select:focus {
  border-color: var(--gold); box-shadow: 0 0 0 3px rgba(212,168,67,0.12);
}
.form-textarea { resize: vertical; min-height: 140px; }
.form-msg { padding: 14px 16px; border-radius: var(--radius); font-size: 0.9rem; margin-top: 4px; display: none; }
.form-msg.success { background: #edf7f0; color: #1e6b40; border: 1px solid #9fd8b4; display: block; }
.form-msg.error { background: #fef2f2; color: #9b2c2c; border: 1px solid #feb2b2; display: block; }

/* ── Visit Info ────────────────────────────────── */
.visit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.visit-card {
  padding: 36px 28px; border: 1.5px solid var(--border); border-radius: var(--radius);
  transition: var(--tr); position: relative; overflow: hidden;
}
.visit-card::before {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 2px;
  background: var(--gold); transform: scaleX(0); transform-origin: left;
  transition: transform 0.4s ease;
}
.visit-card:hover { border-color: rgba(212,168,67,0.4); box-shadow: var(--shadow); }
.visit-card:hover::before { transform: scaleX(1); }
.visit-card-icon { font-size: 1.6rem; color: var(--gold); margin-bottom: 16px; }
.visit-card h3 { font-family: var(--serif); font-size: 1.2rem; margin-bottom: 12px; }
.visit-card p { font-size: 0.88rem; color: var(--grey); white-space: pre-line; line-height: 1.7; }

/* ── Pagination ────────────────────────────────── */
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 60px; flex-wrap: wrap; }
.page-link {
  width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--border); border-radius: var(--radius); font-size: 0.85rem;
  color: var(--grey); transition: var(--tr);
}
.page-link:hover, .page-link.active { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.page-link.wide { width: auto; padding: 0 16px; }

/* ── Filter tabs ───────────────────────────────── */
.filter-bar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 48px; }
.filter-btn {
  padding: 8px 20px; font-size: 0.75rem; font-weight: 600; letter-spacing: 1.5px;
  text-transform: uppercase; border: 1.5px solid var(--border);
  border-radius: var(--radius); color: var(--grey); background: transparent;
  transition: var(--tr); cursor: pointer;
}
.filter-btn:hover, .filter-btn.active { background: var(--ink); border-color: var(--ink); color: var(--white); }

/* ── Breadcrumbs ───────────────────────────────── */
.breadcrumb {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.78rem; color: var(--grey); margin-bottom: 40px;
  padding: calc(var(--header-h) + 24px) 32px 0;
  max-width: 1300px; margin-left: auto; margin-right: auto;
}
.breadcrumb a { color: var(--ochre); }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb span { color: var(--grey); }

/* ── Featured section strip ────────────────────── */
.featured-strip {
  background: var(--gold); padding: 20px 32px;
  display: flex; align-items: center; gap: 16px;
}
.featured-strip-label {
  font-family: var(--mono); font-size: 0.65rem; letter-spacing: 3px;
  text-transform: uppercase; color: var(--earth); white-space: nowrap;
}
.featured-strip-text { font-size: 0.88rem; color: var(--earth); }

/* ── CTA Banner ────────────────────────────────── */
.cta-banner { background: var(--earth); padding: 80px 0; text-align: center; }
.cta-banner h2 { font-family: var(--serif); font-size: clamp(2rem, 4vw, 3rem); color: white; margin-bottom: 16px; }
.cta-banner p { color: rgba(255,255,255,0.65); max-width: 500px; margin: 0 auto 36px; }
.cta-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

/* ── Search bar ────────────────────────────────── */
.search-wrap { position: relative; max-width: 480px; width: 100%; }
.search-input {
  width: 100%; padding: 14px 48px 14px 18px; background: rgba(255,255,255,0.06);
  border: 1.5px solid var(--border); border-radius: var(--radius);
  font-family: var(--sans); font-size: 0.95rem; color: var(--ink); outline: none;
  transition: border-color 0.3s;
}
.search-input:focus { border-color: var(--gold); }
.search-icon { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); color: var(--grey); pointer-events: none; }

/* ── No results ────────────────────────────────── */
.empty-state { text-align: center; padding: 80px 24px; color: var(--grey); }
.empty-state i { font-size: 3rem; color: var(--border); margin-bottom: 16px; }
.empty-state h3 { font-family: var(--serif); font-size: 1.5rem; color: var(--ink); margin-bottom: 8px; }

/* ── Toast notification ────────────────────────── */
.toast {
  position: fixed; bottom: 24px; right: 24px; z-index: 9999;
  background: var(--ink); color: white; padding: 14px 20px;
  border-radius: var(--radius); font-size: 0.88rem;
  transform: translateY(20px) scale(0.95); opacity: 0;
  transition: all 0.4s; pointer-events: none; max-width: 340px;
}
.toast.show { transform: translateY(0) scale(1); opacity: 1; }
.toast.success { border-left: 3px solid #4CAF50; }
.toast.error { border-left: 3px solid #f44336; }

/* ── Scroll animations ─────────────────────────── */
[data-reveal] {
  opacity: 0; transform: translateY(40px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.22,1,0.36,1);
}
[data-reveal].revealed { opacity: 1; transform: translateY(0); }
[data-reveal-delay="100"] { transition-delay: 0.1s; }
[data-reveal-delay="200"] { transition-delay: 0.2s; }
[data-reveal-delay="300"] { transition-delay: 0.3s; }
[data-reveal-delay="400"] { transition-delay: 0.4s; }
[data-reveal-delay="500"] { transition-delay: 0.5s; }

/* ── Footer ────────────────────────────────────── */
.site-footer { background: var(--ink); color: rgba(255,255,255,0.75); }
.footer-top { padding: 80px 0 60px; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.2fr; gap: 60px; max-width: 1300px; margin: 0 auto; padding: 0 32px; }
.footer-logo { display: block; margin-bottom: 16px; }
.footer-logo img { height: 40px; filter: brightness(0) invert(1) opacity(0.8); }
.footer-about { font-size: 0.88rem; line-height: 1.75; color: rgba(255,255,255,0.5); margin-bottom: 24px; }
.footer-socials { display: flex; gap: 12px; }
.footer-socials a {
  width: 36px; height: 36px; border: 1px solid rgba(255,255,255,0.12); border-radius: 2px;
  display: flex; align-items: center; justify-content: center; font-size: 0.85rem;
  color: rgba(255,255,255,0.5); transition: var(--tr);
}
.footer-socials a:hover { background: var(--gold); border-color: var(--gold); color: var(--ink); }
.footer-heading { font-size: 0.72rem; letter-spacing: 2.5px; text-transform: uppercase; color: var(--gold); margin-bottom: 20px; font-family: var(--mono); }
.footer-links { display: flex; flex-direction: column; gap: 10px; }
.footer-links a { font-size: 0.88rem; color: rgba(255,255,255,0.5); transition: color 0.3s; }
.footer-links a:hover { color: var(--gold); }
.footer-address { font-style: normal; display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.footer-address p { font-size: 0.85rem; display: flex; gap: 10px; color: rgba(255,255,255,0.5); }
.footer-address i { color: var(--gold); margin-top: 3px; flex-shrink: 0; font-size: 0.75rem; }
.footer-address a { color: rgba(255,255,255,0.5); transition: color 0.3s; }
.footer-address a:hover { color: var(--gold); }
.footer-cta { font-size: 0.75rem; font-weight: 600; letter-spacing: 1.5px; text-transform: uppercase; color: var(--gold); display: inline-flex; gap: 6px; align-items: center; transition: gap 0.3s; }
.footer-cta:hover { gap: 10px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.06); padding: 24px 32px;
  display: flex; justify-content: space-between; align-items: center;
  max-width: 1300px; margin: 0 auto; font-size: 0.78rem; color: rgba(255,255,255,0.3);
}
.nepal-flag { font-size: 1rem; }

/* ── Responsive ────────────────────────────────── */
@media (max-width: 1100px) {
  .card-grid-4 { grid-template-columns: repeat(3, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 40px; }
}
@media (max-width: 900px) {
  .main-nav, .btn-visit { display: none; }
  .nav-toggle { display: flex; }
  .blog-grid, .card-grid-3, .card-grid-4, .home-team-grid { grid-template-columns: repeat(2, 1fr); }
  .about-split { grid-template-columns: 1fr; gap: 48px; }
  .about-image-accent { right: 0; bottom: -24px; width: 45%; }
  .about-year-badge { left: 0; }
  .about-mvh-grid { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
  .artifact-detail-grid { grid-template-columns: 1fr; gap: 40px; }
  .contact-layout { grid-template-columns: 1fr; gap: 48px; }
  .visit-grid { grid-template-columns: repeat(2, 1fr); }
  .blog-single-layout { grid-template-columns: 1fr; }
  .blog-sidebar { position: static; }
  .gallery-masonry { columns: 2; }
  .stats-bar .container { flex-wrap: wrap; }
  .stat-item { flex: 50%; border-right: none; border-bottom: 1px solid rgba(255,255,255,0.07); }
  .form-row { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  :root { --header-h: 70px; }
  /* Full 100vh + min-height:600px hero made for an awkwardly tall, often
     viewport-jumpy (mobile browser chrome) block on phones. A 3:4 portrait
     ratio reads as an intentional, properly composed image instead. */
  .hero-slider { height: auto; aspect-ratio: 3 / 4; min-height: 0; }
  .header-inner { padding: 0 20px; }
  .container { padding: 0 20px; }
  .section { padding: 60px 0; }
  .blog-grid, .card-grid-3, .card-grid-4, .home-team-grid { grid-template-columns: 1fr; }
  .about-mvh-grid { grid-template-columns: 1fr; }
  .visit-grid { grid-template-columns: 1fr; }
  .gallery-masonry { columns: 1; }
  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .hero-scroll-hint { display: none; }
  /* Artifact detail: image and metadata stack on small phones with tighter
     gaps and thumbnails wrapping/scrolling instead of overflowing. */
  .artifact-detail-grid { gap: 28px; }
  .share-row { flex-wrap: wrap; }
}
@media (max-width: 420px) {
  .logo-text { display: none; }
}
