/* ============================================
   PAMUSHA HOME — home.css
   Homepage-specific styles
   ============================================ */

/* --- Homepage: hide loading overlay (splash replaces it) --- */
.is-home .loading-overlay {
    display: none;
}

/* --- Splash Screen --- */
.splash {
    position: fixed;
    inset: 0;
    z-index: 500;
    background-color: var(--ivory);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    transition: opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
                visibility 1.2s;
    cursor: pointer;
}

.splash.dismissed {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

@keyframes splashGrow {
    0%   { transform: scale(1);   letter-spacing: 0.14em; }
    100% { transform: scale(1.4); letter-spacing: 0.22em; }
}

.splash-name {
    font-family: var(--font-header);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 300;
    letter-spacing: 0.14em;
    color: var(--chestnut);
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    text-transform: uppercase;
    line-height: 1;
    will-change: transform, opacity;
    animation: splashGrow 8s cubic-bezier(0.37, 0, 0.63, 1) infinite alternate;
    animation-play-state: paused;
}

html.ready .splash-name {
    animation-play-state: running;
}

.splash-name:hover {
    opacity: 0.6;
}

/* Transition-based zoom out (JS freezes current scale, then applies this) */
.splash-name.zoom-exit {
    animation: none;
    transition: transform 2s cubic-bezier(0.16, 1, 0.3, 1),
                letter-spacing 2s cubic-bezier(0.16, 1, 0.3, 1),
                opacity 1.6s cubic-bezier(0.16, 1, 0.3, 1);
    transform: scale(3.5);
    letter-spacing: 0.4em;
    opacity: 0;
}

/* --- Homepage: hide scrollbar during splash --- */
.is-home {
    overflow: hidden;
}

.is-home.splash-dismissed {
    overflow: auto;
}

/* --- Home Content (hidden until splash dismissed) --- */
.home-content {
    opacity: 0;
    transition: opacity 0.8s var(--ease-out) 0.3s;
}

.splash-dismissed .home-content {
    opacity: 1;
}

/* --- Locations --- */
.splash-locations {
    position: absolute !important;
    bottom: var(--space-xl);
    left: 50% !important;
    right: auto !important;
    transform: translateX(-50%) !important;
    width: max-content !important;
    text-align: center !important;
    font-family: var(--font-header) !important;
    font-size: calc(var(--text-sm) * 0.7);
    font-weight: 400;
    letter-spacing: var(--letters-wide);
    text-transform: uppercase;
    color: var(--chestnut);
    margin: 0 !important;
    max-width: none !important;
}

/* --- Hero --- */
.hero {
    position: relative;
    height: 100vh;
    min-height: 600px;
    max-height: 1000px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-image-wrapper {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.hero-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(
        165deg,
        #3d2e24 0%,
        #5a4335 25%,
        #8b7355 50%,
        #b9af9e 75%,
        #c2a58a 100%
    );
}

.hero-image-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(56, 47, 47, 0.15) 0%,
        rgba(56, 47, 47, 0.3) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 56rem;
    padding: 0 var(--edge);
}

.hero-heading {
    font-family: var(--font-header);
    font-size: clamp(2.4rem, 6vw, 4.5rem);
    font-weight: 300;
    color: var(--white);
    line-height: 1.05;
    letter-spacing: -0.01em;
    margin-bottom: var(--space-md);
}

.hero-subtitle {
    font-family: var(--font-body);
    font-size: var(--text-md);
    font-weight: 300;
    color: rgba(255, 255, 255, 0.85);
    max-width: 44ch;
    margin: 0 auto var(--space-xl);
    line-height: var(--line-relaxed);
    letter-spacing: var(--letters-normal);
}

.hero-cta {
    display: flex;
    gap: var(--space-sm);
    justify-content: center;
    flex-wrap: wrap;
}

/* --- Editorial (kept for overline reuse) --- */
.editorial-overline {
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 400;
    letter-spacing: var(--letters-xwide);
    text-transform: uppercase;
    color: var(--seasonal-four);
    margin-bottom: var(--space-lg);
    display: block;
}

/* --- Asymmetric Image Grid --- */
.image-grid {
    padding: 0;
}

.image-grid-container {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 4px;
}

.grid-item {
    position: relative;
    overflow: hidden;
}

.grid-item-large {
    grid-row: 1 / 3;
}

.grid-placeholder {
    width: 100%;
    height: 100%;
    min-height: 280px;
    transition: transform 1s var(--ease-out);
}

.grid-item-large .grid-placeholder {
    min-height: 560px;
    background: linear-gradient(135deg, var(--seasonal-two), var(--seasonal-three));
}

.grid-item:nth-child(2) .grid-placeholder {
    background: linear-gradient(135deg, var(--seasonal-one), var(--seasonal-two));
}

.grid-item:nth-child(3) .grid-placeholder {
    background: linear-gradient(135deg, var(--seasonal-three), var(--seasonal-four));
}

.grid-item:hover .grid-placeholder,
.grid-item:hover img {
    transform: scale(1.02);
}

.grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1s var(--ease-out);
}

.grid-caption {
    position: absolute;
    bottom: var(--space-md);
    left: var(--space-md);
    font-family: var(--font-body);
    font-size: var(--text-xs);
    font-weight: 400;
    letter-spacing: var(--letters-wide);
    text-transform: uppercase;
    color: var(--white);
    background-color: rgba(56, 47, 47, 0.7);
    padding: 6px 14px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* --- Full-width Banner Image --- */
.banner-image {
    width: 100%;
    overflow: hidden;
}

.banner-image img {
    width: 100%;
    height: 65vh;
    min-height: 400px;
    max-height: 700px;
    object-fit: cover;
}

.banner-placeholder {
    width: 100%;
    height: 65vh;
    min-height: 400px;
    max-height: 700px;
    background: linear-gradient(135deg, var(--seasonal-three), var(--seasonal-one));
}

/* --- Services Section --- */
.home-services {
    background-color: var(--white);
}

.services-split {
    max-width: var(--width-site);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    min-height: 500px;
}

.services-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: var(--space-xxl) var(--space-xxl);
}

.services-content .overline {
    margin-bottom: var(--space-md);
}

.services-content .section-heading {
    margin-bottom: var(--space-md);
}

.services-content p {
    margin-bottom: var(--space-xl);
    color: var(--seasonal-four);
    line-height: var(--line-relaxed);
}

.services-placeholder {
    width: 100%;
    height: 100%;
    min-height: 500px;
    background: linear-gradient(165deg, var(--seasonal-two), var(--seasonal-three));
}

.services-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* --- Brand Story --- */
.brand-story {
    text-align: center;
    padding: var(--space-xxxxl) var(--edge);
}

.brand-story-container {
    max-width: var(--width-narrow);
    margin: 0 auto;
}

.brand-story-text {
    font-family: var(--font-header);
    font-size: clamp(1.1rem, 1.8vw, 1.35rem);
    font-weight: 300;
    line-height: var(--line-relaxed);
    margin-bottom: var(--space-xl);
    max-width: none;
    color: var(--chestnut);
    letter-spacing: var(--letters-tight);
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .hero {
        min-height: 85vh;
    }

    .image-grid-container {
        grid-template-columns: 1fr;
        grid-template-rows: auto;
    }

    .grid-item-large {
        grid-row: auto;
    }

    .grid-item-large .grid-placeholder {
        min-height: 350px;
    }

    .services-split {
        grid-template-columns: 1fr;
        min-height: auto;
    }

    .services-content {
        padding: var(--space-xl) var(--space-lg);
    }

    .services-image {
        order: -1;
    }

    .services-placeholder {
        min-height: 350px;
    }
}
