:root {
    --vh: 1vh;
    --navbar-height: 60px;
    --bg-color: #faf9f7;
    --accent-color: #333;
}

/* =========================
   LOADER
========================= */
#loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--bg-color);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    transition: opacity 0.8s ease-in-out, visibility 0.8s ease-in-out;
}

#loader.loaded {
    opacity: 0;
    visibility: hidden;
}

.loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
    max-width: 300px;
    width: 80%;
}

.loader-logo {
    width: 100px;
    height: auto;
    animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.05); opacity: 0.8; }
}

.loader-progress-container {
    width: 100%;
    height: 2px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 1px;
    overflow: hidden;
}

.loader-progress-bar {
    width: 0%;
    height: 100%;
    background: var(--accent-color);
    transition: width 0.3s ease-out;
}

.loader-percentage {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 0.9rem;
    letter-spacing: 0.2em;
    color: var(--accent-color);
    opacity: 0.7;
}

@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("/assets/fonts/PlusJakartaSans-Regular.woff2") format("woff2");
    font-weight: 100 800;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Plus Jakarta Sans";
    src: url("/assets/fonts/PlusJakartaSans-Italic.woff2") format("woff2");
    font-weight: 100 800;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Libre Baskerville";
    src: url("/assets/fonts/LibreBaskerville-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Libre Baskerville";
    src: url("/assets/fonts/LibreBaskerville-Regular.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Libre Baskerville";
    src: url("/assets/fonts/LibreBaskerville-Italic.woff2") format("woff2");
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Libre Baskerville";
    src: url("/assets/fonts/LibreBaskerville-Italic.woff2") format("woff2");
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Kurale";
    src: url("/assets/fonts/Kurale-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Amiri";
    src: url("/assets/fonts/Amiri-Regular.woff2") format("woff2");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Amiri";
    src: url("/assets/fonts/Amiri-Italic.woff2") format("woff2");
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}

@font-face {
    font-family: "Amiri";
    src: url("/assets/fonts/Amiri-Bold.woff2") format("woff2");
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: "Amiri";
    src: url("/assets/fonts/Amiri-BoldItalic.woff2") format("woff2");
    font-weight: 700;
    font-style: italic;
    font-display: swap;
}

#app {
    padding: 2rem;
    transition:
        opacity 200ms ease,
        transform 200ms ease;
}

/* Home page slides - fullscreen */
body.home #app,
body.gallery #app {
    padding: 0;
}

/* Home page content should cover full viewport */
body.home #main {
    min-height: 100vh;
}

body {
    font-family: "Plus Jakarta Sans", sans-serif;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
    width: 100%;
}

html {
    height: auto;
    overflow-x: hidden;
    width: 100%;
}

/* ===============================
   FLOATING DOCK NAVBAR
================================ */

.nav-dock {
    position: fixed;
    top: 32px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2147483647;

    /* Standard Glassmorphism */
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 16px;

    display: flex;
    align-items: center;
    padding: 8px;
    overflow: hidden;

    /* Fluid morphing animation */
    transition:
        max-width 0.8s cubic-bezier(0.7, 0, 0.3, 1),
        height 0.8s cubic-bezier(0.7, 0, 0.3, 1),
        padding 0.8s cubic-bezier(0.7, 0, 0.3, 1),
        background 0.4s ease;

    width: auto;
    max-width: 60px; /* Collapsed state */
    height: 60px;
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.1),
        inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.nav-dock.open {
    max-width: 1000px; /* Expanded state */
    padding-right: 32px;
    background: rgba(255, 255, 255, 0.3);
}

.dock-toggle {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border: none;
    background: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: transform 0.3s ease;
}

.dock-toggle:hover {
    transform: scale(1.1);
}

.dock-logo {
    width: 32px;
    height: 32px;
    object-fit: contain;
    opacity: 0.9;
}

.dock-links {
    display: flex;
    gap: 32px;
    margin-left: 0;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.4s ease;
    pointer-events: none;
    white-space: nowrap;
}

.nav-dock.open .dock-links {
    margin-left: 24px;
    opacity: 1;
    transform: translateX(0);
    pointer-events: auto;
}

.nav-item {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 13px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
    color: #111;
    text-decoration: none;
    font-weight: 500;
    position: relative;
}

.nav-item::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 0%;
    height: 1px;
    background: #111;
    transition: width 0.3s ease;
}

.nav-item:hover::after {
    width: 100%;
}

/* Animation states for app content */
.fade-in {
    opacity: 1;
    transform: translateY(0);
}

.fade-out {
    opacity: 0;
    transform: translateY(10px);
}

.page {
    min-height: 60vh;
}

#title {
    font-size: 10em;
    font-weight: 800;
    font-family: "Kurale";
    letter-spacing: -14px;
    margin: 0;
    position: relative;
}

#subtitle {
    font-size: 1.2em;
    color: #666;
    margin: 0;
}

.slide {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    height: calc(var(--vh, 1vh) * 100);
    text-align: center;
    width: 100%;
    position: relative;
    overflow: hidden;
}

#slide-title {
    background: none;
    flex-direction: column;
    justify-content: center;
    gap: 1rem;
}

.hero-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.hero-tagline {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 14px;
    letter-spacing: 6px;
    text-transform: uppercase;
    color: #888;
    margin: 0;
    opacity: 0;
    animation: fadeIn 1s ease 0.5s forwards;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.hero-scroll {
    position: absolute;
    bottom: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    opacity: 0.6;
    animation: fadeIn 1s ease 1s forwards;
}

.hero-scroll span {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.hero-scroll .scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, #1a1a1a, transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

#slide-subtitle {
    background: #f8f8f8;
}

#slide-3d {
    background: #faf9f7;
    height: 100vh;
    width: 100%;
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

#model-container {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

/* =====================================
   HOME POEMS ALBUM SLIDE
   ===================================== */

#slide-poems {
    background: #f8f5ef;
}

.album-home {
    max-width: 720px;
    margin: 0 auto;
    padding: 80px 40px;
    text-align: center;
}

.album-home h1 {
    font-family: "Libre Baskerville", serif;
    font-size: 42px;
    letter-spacing: 2px;
    margin-bottom: 10px;
}

.album-home .subtitle {
    font-family: "Plus Jakarta Sans", sans-serif;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 4px;
    opacity: 0.6;
    margin-bottom: 40px;
}

.album-home .ornament {
    font-size: 22px;
    margin: 20px 0;
    opacity: 0.4;
}

.album-home .album-intro {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: #444;
    margin-bottom: 40px;
    max-width: 480px;
    margin-left: auto;
    margin-right: auto;
}

.album-home .album-link {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #111;
    text-decoration: none;
    padding: 12px 30px;
    border: 1px solid #111;
    display: inline-block;
    transition: all 0.3s ease;
}

.album-home .album-link:hover {
    background: #111;
    color: #fff;
    letter-spacing: 3px;
}

/* =====================================
   HERO NEWS MARQUEE
   ===================================== */

.hero-news {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 40px 0 60px;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(255, 255, 255, 0.4) 100% /* Much lighter gradient */
    );
    z-index: 5; /* Ensure it's above the background logo but below floating photos */
}

.news-marquee {
    position: relative;
    width: 100%;
    overflow: visible; /* Important: don't clip the cards or their shadows */
}

.news-track {
    display: flex;
    gap: 24px;
    width: max-content;
    animation: newsScroll 50s linear infinite;
}

.news-card {
    flex-shrink: 0;
    width: 280px;
    padding: 20px 24px;
    background: rgba(255, 255, 255, 0.4); /* Transparent glass base */
    backdrop-filter: blur(15px); /* Strong blur */
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.5); /* Crisp glass edge */
    border-radius: 12px;
    z-index: 1;
    transition:
        transform 0.3s cubic-bezier(0.2, 1, 0.3, 1),
        background 0.3s ease,
        box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-8px) scale(1.02);
    background: rgba(255, 255, 255, 0.7);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
}

.news-date {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #888;
    display: block;
    margin-bottom: 8px;
}

.news-card h3 {
    font-family: "Libre Baskerville", serif;
    font-size: 16px;
    font-weight: 400;
    color: #1a1a1a;
    margin-bottom: 8px;
    line-height: 1.3;
}

.news-card p {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 13px;
    line-height: 1.5;
    color: #666;
    margin: 0;
}

@keyframes newsScroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

/* =====================================
   FLOATING PHOTOS (PARALLAX)
   ===================================== */

.floating-photos {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    min-height: 100%;
    pointer-events: none;
    z-index: 2147483640; /* Above content, below dock */
}

.floating-photo {
    position: absolute;
    border-radius: 6px;
    will-change: transform;
    z-index: 2147483647 !important;
    pointer-events: auto;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
}

.photo-inner {
    border-radius: inherit;
    background-size: cover;
    background-position: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    background-color: rgba(255, 255, 255, 0.25);
    will-change: transform, filter;

    /* Buttery Smooth CSS Transitions */
    transition:
        transform 1.5s cubic-bezier(0.2, 1, 0.2, 1),
        filter 1.5s ease,
        scale 1.5s cubic-bezier(0.2, 1, 0.2, 1);
    pointer-events: none;
}

/* State when hovered - JS will handle the specific rotation logic */
.floating-photo.is-hovered .photo-inner {
    filter: blur(0px) !important;
    -webkit-filter: blur(0px) !important;
}

/* When hovering a photo, unblur the hovered one */
.floating-photo:hover {
    filter: blur(0px) !important;
}

/* =====================================
   STORY SLIDES
   ===================================== */

.slide-story {
    background: #faf9f7;
}

/* Slide with background image */
.slide-image {
    position: relative;
    overflow: hidden;
}

.slide-image-bg {
    position: absolute;
    inset: -20%;
    background-size: cover;
    background-position: center;
    will-change: transform;
    opacity: 0;
    transition: opacity 1s ease-out;
}

/* Override original backgrounds when slide has image */
.slide-image.slide-story,
.slide-image.slide-location,
.slide-image.slide-dark {
    background: none !important;
}

.slide-image .story-content,
.slide-image .pillars-container,
.slide-image .journey-content,
.slide-image .location-card {
    position: relative;
    z-index: 2;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    padding: 3rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.12);
    max-width: 800px;
    margin: 0 auto;
}

.slide-image .pillars-container {
    max-width: 1000px;
}

.slide-image .location-card {
    max-width: 500px;
    padding: 4rem; /* Keeping original padding for the location card */
}

/* Remove or override specific backgrounds that might clash */
.slide-image.slide-story,
.slide-image.slide-location,
.slide-image.slide-dark,
.slide-image.slide-pillars,
.slide-image.slide-journey {
    background: none !important;
}

.story-content {
    max-width: 640px;
    padding: 2rem;
    text-align: center;
}

.story-label {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: #888;
    display: block;
    margin-bottom: 1.5rem;
}

.story-label.light {
    color: rgba(255, 255, 255, 0.6);
}

.story-title {
    font-family: "Libre Baskerville", serif;
    font-size: 42px;
    font-weight: 400;
    line-height: 1.3;
    margin: 0 0 1.5rem 0;
    color: #1a1a1a;
}

.story-title.light {
    color: #fff;
}

.story-text {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 17px;
    line-height: 1.8;
    color: #555;
    margin: 0;
}

.story-text.light {
    color: rgba(255, 255, 255, 0.8);
}

/* =====================================
   DARK SLIDE
   ===================================== */

.slide-dark {
    background: #1a1a1a;
}

/* =====================================
   LOCATION SLIDE
   ===================================== */

.slide-location {
    background: linear-gradient(135deg, #f5f3f0 0%, #e8e4df 100%);
    position: relative;
}

.location-visual {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 2rem;
}

.location-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(20px);
    padding: 4rem;
    border-radius: 4px;
    text-align: center;
    max-width: 500px;
    border: 1px solid rgba(255, 255, 255, 0.5);
}

.location-label {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: #888;
    display: block;
    margin-bottom: 1rem;
}

.location-name {
    font-family: "Libre Baskerville", serif;
    font-size: 48px;
    font-weight: 400;
    margin: 0 0 1.5rem 0;
    color: #1a1a1a;
}

.location-desc {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: #555;
    margin: 0 0 2rem 0;
}

.location-coords {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 13px;
    letter-spacing: 2px;
    color: #888;
}

.coords-divider {
    margin: 0 1rem;
    opacity: 0.4;
}

/* =====================================
   PILLARS SLIDE
   ===================================== */

.slide-pillars {
    background: #fff;
}

.pillars-container {
    max-width: 1000px;
    padding: 4rem 2rem;
    text-align: center;
}

.pillars-title {
    font-family: "Libre Baskerville", serif;
    font-size: 36px;
    font-weight: 400;
    margin: 1rem 0 3rem 0;
    color: #1a1a1a;
}

.pillars-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
}

.pillar {
    text-align: center;
}

.pillar-number {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 12px;
    letter-spacing: 3px;
    color: #ccc;
    display: block;
    margin-bottom: 1rem;
}

.pillar h3 {
    font-family: "Libre Baskerville", serif;
    font-size: 24px;
    font-weight: 400;
    margin: 0 0 1rem 0;
    color: #1a1a1a;
}

.pillar p {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 15px;
    line-height: 1.7;
    color: #666;
    margin: 0;
}

/* =====================================
   JOURNEY SLIDE
   ===================================== */

.slide-journey {
    background: linear-gradient(180deg, #f8f5ef 0%, #fff 100%);
}

.journey-content {
    max-width: 640px;
    padding: 2rem;
    text-align: center;
}

.journey-title {
    font-family: "Libre Baskerville", serif;
    font-size: 42px;
    font-weight: 400;
    line-height: 1.3;
    margin: 1rem 0 1.5rem 0;
    color: #1a1a1a;
}

.journey-text {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 17px;
    line-height: 1.8;
    color: #555;
    margin: 0 0 2.5rem 0;
}

.journey-link {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #1a1a1a;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    border: 1px solid #1a1a1a;
    transition: all 0.3s ease;
}

.journey-link:hover {
    background: #1a1a1a;
    color: #fff;
}

.journey-link svg {
    transition: transform 0.3s ease;
}

.journey-link:hover svg {
    transform: translateX(4px);
}

/* =====================================
   ABOUT PAGE
   ===================================== */

.about-page {
    min-height: 100vh;
}

.about-hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 6rem 2rem;
    background: linear-gradient(180deg, #f8f5ef 0%, #fff 100%);
    position: relative;
}

.about-hero-content {
    max-width: 800px;
}

.about-label {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: #888;
    display: block;
    margin-bottom: 1.5rem;
}

.about-hero-title {
    font-family: "Libre Baskerville", serif;
    font-size: 72px;
    font-weight: 400;
    line-height: 1.1;
    margin: 0 0 1.5rem 0;
    color: #1a1a1a;
}

.about-hero-subtitle {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 18px;
    color: #666;
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

.about-hero-scroll {
    position: absolute;
    bottom: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    opacity: 0.6;
}

.about-hero-scroll span {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 11px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, #1a1a1a, transparent);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%,
    100% {
        transform: scaleY(1);
        opacity: 1;
    }
    50% {
        transform: scaleY(0.5);
        opacity: 0.5;
    }
}

/* About Container */
.about-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* About Story Section */
.about-story {
    padding: 8rem 0;
    background: #fff;
}

.about-story-text {
    max-width: 700px;
    margin: 0 auto;
    text-align: center;
}

.about-story-text h2 {
    font-family: "Libre Baskerville", serif;
    font-size: 36px;
    font-weight: 400;
    margin: 0 0 2rem 0;
    color: #1a1a1a;
}

.about-story-text p {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 17px;
    line-height: 1.8;
    color: #555;
    margin: 0 0 1.5rem 0;
}

.about-story-text p.lead {
    font-size: 20px;
    color: #333;
}

/* About Values Section */
.about-values {
    padding: 8rem 0;
    background: #f8f5ef;
    text-align: center;
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-top: 3rem;
}

.value-card {
    background: rgba(255, 255, 255, 0.6);
    padding: 2.5rem 2rem;
    border-radius: 4px;
    text-align: center;
}

.value-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 1.5rem;
    color: #1a1a1a;
}

.value-icon svg {
    width: 100%;
    height: 100%;
}

.value-card h3 {
    font-family: "Libre Baskerville", serif;
    font-size: 20px;
    font-weight: 400;
    margin: 0 0 1rem 0;
    color: #1a1a1a;
}

.value-card p {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 14px;
    line-height: 1.6;
    color: #666;
    margin: 0;
}

/* About Village Section */
.about-village {
    padding: 8rem 0;
    background: #1a1a1a;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.village-map {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.map-placeholder {
    width: 100%;
    aspect-ratio: 4/3;
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.map-placeholder::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.map-dot {
    width: 16px;
    height: 16px;
    background: #fff;
    border-radius: 50%;
    position: relative;
    z-index: 1;
    animation: pulse 2s ease-in-out infinite;
}

.map-dot::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: ripple 2s ease-out infinite;
}

@keyframes pulse {
    0%,
    100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}

@keyframes ripple {
    0% {
        width: 16px;
        height: 16px;
        opacity: 1;
    }
    100% {
        width: 80px;
        height: 80px;
        opacity: 0;
    }
}

.map-label {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 14px;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
    margin-top: 1.5rem;
    position: relative;
    z-index: 1;
}

.village-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 2rem;
}

.village-info .about-label {
    color: rgba(255, 255, 255, 0.5);
}

.village-info h2 {
    font-family: "Libre Baskerville", serif;
    font-size: 42px;
    font-weight: 400;
    margin: 1rem 0 1.5rem 0;
    color: #fff;
}

.village-info p {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: rgba(255, 255, 255, 0.7);
    margin: 0 0 2.5rem 0;
}

.village-stats {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.village-stats li {
    text-align: center;
}

.stat-number {
    font-family: "Libre Baskerville", serif;
    font-size: 48px;
    color: #fff;
    display: block;
}

.stat-label {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

/* About Team Section */
.about-team {
    padding: 8rem 0;
    background: #fff;
    text-align: center;
}

.about-team h2 {
    font-family: "Libre Baskerville", serif;
    font-size: 36px;
    font-weight: 400;
    margin: 1rem 0 3rem 0;
    color: #1a1a1a;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 3rem;
}

.team-member {
    text-align: center;
}

.member-photo {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 1.5rem;
    border: 3px solid #f0ede8;
}

.member-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.team-member:hover .member-photo img {
    transform: scale(1.05);
}

.team-member h4 {
    font-family: "Libre Baskerville", serif;
    font-size: 20px;
    font-weight: 400;
    margin: 0 0 0.5rem 0;
    color: #1a1a1a;
}

.member-role {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 12px;
    letter-spacing: 1px;
    color: #888;
    margin: 0;
}

/* About CTA Section */
.about-cta {
    padding: 8rem 0;
    background: #f8f5ef;
    text-align: center;
}

.about-cta h2 {
    font-family: "Libre Baskerville", serif;
    font-size: 42px;
    font-weight: 400;
    margin: 0 0 1.5rem 0;
    color: #1a1a1a;
}

.about-cta p {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 17px;
    color: #555;
    max-width: 500px;
    margin: 0 auto 2.5rem;
    line-height: 1.6;
}

.cta-button {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 13px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #fff;
    text-decoration: none;
    background: #1a1a1a;
    padding: 1rem 2.5rem;
    display: inline-block;
    transition: all 0.3s ease;
}

.cta-button:hover {
    background: #333;
    letter-spacing: 3px;
}

/* Social Links */
.social-links {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 2rem;
}

.social-link {
    width: 56px;
    height: 56px;
    border: 1px solid #1a1a1a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1a1a1a;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: #1a1a1a;
    color: #fff;
}

.social-link svg {
    width: 22px;
    height: 22px;
}

html,
body {
    height: 100%;
    margin: 0;
    padding: 0;
}

* {
    box-sizing: border-box;
}

/* ScrollSmoother - let it control scrolling */
#smooth-wrapper {
    height: 100%;
    width: 100%;
    position: relative;
}

#smooth-content {
    position: relative;
    min-height: 100%;
}

#main {
    position: relative;
    font-family: "Plus Jakarta Sans", sans-serif;
}

.parallax-logo-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none;
    overflow: hidden;
}

.patibrata-svg.parallax-logo {
    position: absolute;
    width: 120%;
    max-width: 900px;
    left: 50%;
    transform: translateX(-50%);
    height: auto;
    z-index: 1;
    opacity: 0.15;
    top: 50%;
    will-change: transform;
}

#title {
    position: relative;
    z-index: 2;
}

a {
    color: #007bff;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* ===============================
   POEM PAGE
================================ */

.poem {
    max-width: 720px;
    margin: 80px auto;
    padding: 0 40px;
    animation: fadeIn 0.6s ease;
}

/* Title (from # in markdown) */
.poem h1 {
    font-family: "Libre Baskerville", serif;
    font-size: 40px;
    text-align: center;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

/* Author (from ### in markdown) */
.poem h3 {
    font-family: "Plus Jakarta Sans", sans-serif;
    text-align: center;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 4px;
    opacity: 0.6;
    margin-bottom: 70px;
    font-weight: 400;
}

/* Poem body */
.poem p {
    font-family: "Libre Baskerville", serif;
    font-size: 19px;
    line-height: 2.1;
    margin: 0 0 28px 0;
}

/* Drop cap on first stanza */
.poem p:first-of-type {
    position: relative;
}

.poem p:first-of-type::before {
    content: "❦";
    display: block;
    text-align: center;
    font-size: 18px;
    margin-bottom: 30px;
    opacity: 0.4;
}

.poem span[lang="ar"] {
    font-family: "Amiri", serif;
    direction: rtl;
    unicode-bidi: isolate;
}

.back-link {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 12px;
    letter-spacing: 2px;
    text-decoration: none;
    opacity: 0.6;
    display: inline-block;
    margin-bottom: 60px;
}

.back-link:hover {
    opacity: 1;
}

#reveal-overlay {
    position: fixed;
    inset: 0;
    background: white;
    overflow: hidden;
    z-index: 9999;
    clip-path: circle(0px at 50% 100%);
}

.portal-section {
    height: 150vh;
    position: relative;
}

/* =====================================
   MOBILE RESPONSIVE FIXES
===================================== */

@media (max-width: 768px) {
    #app {
        padding: 1.5rem;
    }

    #main {
        padding: 1rem;
    }

    .slide {
        padding-top: 40px;
        padding-bottom: 40px;
        box-sizing: border-box;
        min-height: calc(var(--vh, 1vh) * 100);
        align-items: center;
    }

    #title {
        font-size: 3.5rem;
        letter-spacing: -3px;
    }

    .patibrata-svg {
        width: 150%;
        left: -25%;
        opacity: 0.2;
    }

    .poem {
        margin: 40px auto;
        padding: 0 20px;
    }

    .poem h1 {
        font-size: 28px;
    }

    .poem p {
        font-size: 17px;
        line-height: 1.9;
    }

    .album-home h1 {
        font-size: 32px;
    }

    .news-card {
        width: 240px;
    }

    .floating-photo {
        width: 80px;
        height: 110px;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .floating-photo:nth-child(n + 5) {
        display: none;
    }

    .about-hero-title {
        font-size: 42px;
    }

    .values-grid {
        grid-template-columns: 1fr;
    }

    .about-village {
        grid-template-columns: 1fr;
        padding: 4rem 1.5rem;
    }

    .team-grid {
        grid-template-columns: 1fr;
    }

    .nav-dock {
        top: auto;
        bottom: 24px;
        flex-direction: column;
        width: auto;
        max-width: 64px;
        height: auto;
        max-height: 64px;
        padding: 10px;

        /* Standard Glassmorphism */
        background: rgba(255, 255, 255, 0.7);
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
        border: 1px solid rgba(255, 255, 255, 0.4);
        box-shadow:
            0 15px 40px rgba(0, 0, 0, 0.15),
            inset 0 0 0 1px rgba(255, 255, 255, 0.2);
    }

    .nav-dock.open {
        max-width: calc(100% - 48px);
        max-height: 600px;
        padding: 24px 20px 32px;
        border-radius: 28px;
        background: rgba(255, 255, 255, 0.25);
    }

    .dock-logo {
        filter: none; /* Back to original colors */
        width: 36px;
        height: 36px;
    }

    .nav-item {
        color: #111;
        font-size: 16px;
        text-align: center;
        padding: 8px 0;
        width: 100%;
    }

    .nav-dock.open .dock-links {
        flex-direction: column;
        margin-left: 0;
        margin-top: 24px;
        gap: 16px;
        width: 100%;
        align-items: center;
        justify-content: center;
    }
}

/* =====================================
   GALLERY PAGE (ALBUM BASED)
===================================== */

.gallery-container {
    max-width: 1400px;
    margin: 0 auto 80px;
    padding: 140px 40px 0;
}

.gallery-header {
    text-align: center;
    margin-bottom: 80px;
}

.album-section {
    margin-bottom: 100px;
    opacity: 0;
    transform: translateY(20px);
}

.album-header {
    margin-bottom: 32px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.album-title {
    font-family: "Libre Baskerville", serif;
    font-size: 28px;
    font-weight: 400;
    color: #1a1a1a;
    text-transform: capitalize;
    margin: 0;
}

.album-count {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #888;
    margin-top: 8px;
    display: block;
}

.masonry {
    column-count: 3;
    column-gap: 24px;
    width: 100%;
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 24px;
    border-radius: 4px;
    overflow: hidden;
    background: #f0ede8;
    transition: transform 0.4s cubic-bezier(0.2, 1, 0.3, 1);
    cursor: zoom-in;
}

.masonry-item:hover {
    transform: scale(1.02);
    z-index: 2;
}

.masonry-item img {
    width: 100%;
    height: auto;
    display: block;
    transition: opacity 0.5s ease;
}

.gallery-loader {
    text-align: center;
    padding: 100px 0;
}

.loader-spinner {
    width: 40px;
    height: 40px;
    border: 2px solid #f0ede8;
    border-top: 2px solid #1a1a1a;
    border-radius: 50%;
    margin: 0 auto 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@media (max-width: 1024px) {
    .masonry {
        column-count: 2;
        column-gap: 20px;
    }
}

/* =====================================
   GALLERY LIGHTBOX
===================================== */

#gallery-lightbox {
    position: fixed;
    inset: 0;
    z-index: 2147483647;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

#gallery-lightbox.active {
    display: flex;
}

.lightbox-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
}

.lightbox-content {
    position: relative;
    z-index: 2;
    max-width: 100%;
    max-height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 40px;
    height: 40px;
    border: 2px solid rgba(0, 0, 0, 0.05);
    border-top: 2px solid #1a1a1a;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    display: none;
}

.lightbox-content img {
    max-width: 100%;
    max-height: calc(100vh - 120px);
    object-fit: contain;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.15);
    border-radius: 4px;
    animation: lightboxZoom 0.4s cubic-bezier(0.2, 1, 0.3, 1);
}

.lightbox-close {
    position: fixed;
    top: 32px;
    right: 32px;
    background: none;
    border: none;
    font-size: 48px;
    color: #1a1a1a;
    cursor: pointer;
    line-height: 1;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.lightbox-close:hover {
    opacity: 1;
}

.lightbox-caption {
    margin-top: 24px;
    font-family: "Libre Baskerville", serif;
    font-size: 18px;
    color: #1a1a1a;
}

@keyframes lightboxZoom {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@media (max-width: 768px) {
    #gallery-lightbox {
        padding: 20px;
    }
    
    .lightbox-close {
        top: 16px;
        right: 16px;
        font-size: 36px;
    }
}
