/* ========================================
   INTERIORS PAGE: room by room
   Backgrounds chain through --blend-0 to --blend-4
======================================== */

.plate { margin: 0; }

.plate img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
    border-radius: 18px;
    filter: sepia(.1) saturate(.95);
    transition: transform .9s ease, filter .9s ease;
}

.plate:hover img {
    transform: scale(1.02);
    filter: sepia(0) saturate(1.05);
}

.plate figcaption {
    position: relative;
    z-index: 1;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1rem;
    padding-top: .9rem;
    border-top: 1px solid rgba(58, 46, 40, .35);
    font-size: .8rem;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--label);
}

/* Images uncover as they scroll in; browsers without it just show them */
@keyframes uncover {
    from { clip-path: inset(0 0 100% 0); }
    to   { clip-path: inset(0); }
}

.curtain[data-reveal].is-armed { opacity: 1; transform: none; }

@supports (animation-timeline: view()) {
    .curtain img {
        animation: uncover linear both;
        animation-timeline: view();
        animation-range: entry 0% entry 60%;
    }
}

/* ========================================
   HERO   (fades into the living room)
======================================== */

.int-hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    color: #fff;
    background: var(--deep-espresso);
}

.int-hero > img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 45%;
    animation: settle 2.8s ease-out both;
}

.int-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(58, 46, 40, .6) 0%, rgba(58, 46, 40, .2) 55%, rgba(58, 46, 40, .05) 100%);
}

.int-hero::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 180px;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(250, 247, 241, 0) 0%, var(--blend-0) 100%);
}

.int-hero__content {
    position: relative;
    z-index: 2;
    width: 100%;
    padding: 0 8% 10rem;
}

.int-hero__content > * { animation: rise 1.1s ease-out both; }
.int-hero__content > :nth-child(1) { animation-delay: .3s; }
.int-hero__content > :nth-child(2) { animation-delay: .5s; }
.int-hero__content > :nth-child(3) { animation-delay: .8s; }

.int-hero .section-label { color: var(--honey-oatmilk); }

.int-hero h1 {
    max-width: 12ch;
    margin-bottom: 2rem;
    font-size: clamp(4.5rem, 10vw, 8.5rem);
    line-height: .92;
}

/* Light hero: dark text over the bright, cream room */
.int-hero--light { color: var(--deep-espresso); }

.int-hero--light::after {
    background: linear-gradient(90deg, rgba(250, 247, 241, .85) 0%, rgba(250, 247, 241, .45) 45%, rgba(250, 247, 241, 0) 100%);
}

.int-hero--light .section-label { color: var(--label); }

/* ========================================
   ROOMS
======================================== */

.room--living  { background: linear-gradient(180deg, var(--blend-0) 0%, var(--blend-1) 100%); }
.room--kitchen { background: linear-gradient(180deg, var(--blend-1) 0%, var(--blend-2) 100%); }
.room--dining  { background: linear-gradient(180deg, var(--blend-2) 0%, #E1CEB5 100%); }
.room--bedroom { background: linear-gradient(180deg, #E1CEB5 0%, var(--blend-3) 100%); }
.room--hall    { background: linear-gradient(180deg, var(--blend-3) 0%, #D4BEA2 100%); }

.room__grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    column-gap: 2.5rem;
    align-items: end;
}

.room__tall { grid-column: 1 / span 5; }
.room__tall img { aspect-ratio: 3 / 4; }

.room__side {
    grid-column: 6 / span 7;
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.room__side .plate img { aspect-ratio: 3 / 2; }

.room__text p { max-width: 460px; margin-bottom: 0; }

.room__grid--flip .room__side { grid-column: 1 / span 7; }
.room__grid--flip .room__tall { grid-column: 8 / span 5; }

/* ========================================
   LIGHT DIAL: the room warms from morning to evening
======================================== */

.dial { --dusk: 0; }

.dial__stage {
    position: relative;
    overflow: hidden;
    border-radius: 18px;
}

.dial .dial__stage img {
    aspect-ratio: 3 / 2;
    border-radius: 0;
    transform: none;
    filter: brightness(calc(1.05 - var(--dusk) * .4)) sepia(calc(.08 + var(--dusk) * .4)) saturate(calc(.95 + var(--dusk) * .25));
}

.dial:hover .dial__stage img { transform: none; }

.dial__stage::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 60% 20%, rgba(255, 190, 110, .7), rgba(255, 190, 110, 0) 60%);
    mix-blend-mode: screen;
    opacity: var(--dusk);
    pointer-events: none;
}

.dial__control {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 1rem;
    font-size: .8rem;
    letter-spacing: .16em;
    text-transform: uppercase;
    color: var(--label);
}

.dial__control input[type="range"] {
    flex: 1;
    height: 6px;
    margin: 0;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--honey-oatmilk), var(--antique-wood), var(--deep-espresso));
    -webkit-appearance: none;
    appearance: none;
    cursor: ew-resize;
}

.dial__control input[type="range"]::-webkit-slider-thumb {
    width: 26px;
    height: 26px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: var(--deep-espresso);
    -webkit-appearance: none;
    appearance: none;
}

.dial__control input[type="range"]::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border: 3px solid #fff;
    border-radius: 50%;
    background: var(--deep-espresso);
}

.dial__control input[type="range"]:focus-visible {
    outline: 2px solid var(--antique-wood);
    outline-offset: 6px;
}

/* ========================================
   DINING: text beside one wide image
======================================== */

.dining__grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    column-gap: 2.5rem;
    align-items: center;
}

.dining__text { grid-column: 1 / span 4; }
.dining__img { grid-column: 5 / span 8; }
.dining__img img { aspect-ratio: 4 / 3; }

/* ========================================
   BEDROOM: staggered pair
======================================== */

.bedroom__grid {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    column-gap: 2.5rem;
    align-items: start;
}

.bedroom__text { grid-column: 1 / span 4; align-self: center; }
.bedroom__a { grid-column: 5 / span 4; }
.bedroom__b { grid-column: 9 / span 4; margin-top: 5rem; }

.bedroom__a img { aspect-ratio: 2 / 3; }
.bedroom__b img { aspect-ratio: 4 / 3; }

/* ========================================
   CALL TO ACTION   (meets the footer)
======================================== */

.int-cta {
    padding: 7rem 0;
    background: linear-gradient(180deg, #D4BEA2 0%, var(--blend-4) 100%);
    text-align: center;
}

.int-cta h2 { margin-bottom: 2rem; }

/* ========================================
   TABLETS AND MOBILE
======================================== */

@media (max-width: 991.98px) {
    .room__grid,
    .dining__grid,
    .bedroom__grid {
        grid-template-columns: 1fr;
        row-gap: 3rem;
    }

    .room__tall,
    .room__side,
    .room__grid--flip .room__side,
    .room__grid--flip .room__tall,
    .dining__text,
    .dining__img,
    .bedroom__text,
    .bedroom__a,
    .bedroom__b {
        grid-column: auto;
        margin-top: 0;
    }

    .room__tall img { aspect-ratio: 4 / 5; }
}

@media (max-width: 575.98px) {
    .int-hero__content { padding-bottom: 8rem; }
}

/* ========================================
   SIZE AND STACKING FIXES
   (kept last so they win; grid changes only apply from tablet up)
======================================== */

/* Hero: a fixed stacking order so the text always sits above the photo */
.int-hero {
    min-height: clamp(560px, 92vh, 960px);
    isolation: isolate;
}

.int-hero > img { z-index: 0; }
.int-hero::before,
.int-hero::after { z-index: 1; }

.int-hero__content {
    z-index: 2;
    padding-bottom: clamp(5rem, 14vh, 9rem);
}

/* Smaller, more balanced images that never fill the whole screen */
.room__tall img,
.bedroom__a img,
.dining__img img {
    max-height: 74vh;
}

.room__side .plate img {
    max-height: 62vh;
}

.dining__img img { aspect-ratio: 5 / 4; }
.bedroom__a img { aspect-ratio: 3 / 4; }

@media (min-width: 992px) {
    .room__tall { grid-column: 1 / span 4; }
    .room__side { grid-column: 5 / span 8; }
    .room__grid--flip .room__side { grid-column: 1 / span 8; }
    .room__grid--flip .room__tall { grid-column: 9 / span 4; }
    .dining__text { grid-column: 1 / span 5; }
    .dining__img { grid-column: 6 / span 7; }
}
