/* Layout for the home page; typography, colour and controls come from the guide. */
:root { --home-section-space: 64px; --home-panel-space: 56px; --home-header-height: 83px; }
html { scroll-padding-top: calc(var(--home-header-height) + 16px); }
body > header { position: sticky; top: 0; z-index: 100; border-bottom: 0; }
.hero { display: grid; grid-template-columns: .93fr 1.07fr; min-height: clamp(520px, 72vh, 760px); }
.hero-copy { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: 65px clamp(28px, 5vw, 75px) 65px max(24px, calc((100vw - 1060px) / 2)); background: var(--paper); border: 0; }
.hero h1 { max-width: 550px; }
.hero p:not(.eyebrow) { max-width: 420px; margin: 24px 0; font-size: 18px; line-height: 1.7; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; }
.hero-actions > a { white-space: nowrap; }
.hero-image { min-height: 410px; position: relative; }
.intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); margin-block: var(--home-section-space); padding: 0; background: var(--teal); color: var(--paper); }
.intro-image { position: relative; min-height: 450px; }
.intro-image img { position: absolute; inset: 0; display: block; width: 100%; height: 100%; object-fit: cover; object-position: 75% center; }
.intro-copy { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; min-width: 0; padding: var(--home-panel-space) clamp(28px, 5vw, 72px); }
.intro-copy .section-title { color: var(--paper); }
.intro .intro-copy p { max-width: 64ch; margin: 18px 0 0; }
.intro .intro-copy p:first-of-type { margin-top: 24px; }
.intro a { color: inherit; overflow-wrap: anywhere; }
.intro a:focus-visible { outline-color: var(--paper); }
.intro p { max-width: 620px; margin: 0; font-size: 18px; line-height: 1.7; }
.homes { padding-bottom: 24px; }

/* A compact editorial credit, immediately after the house photographs. */
.photo-credit { display: flex; align-items: flex-start; gap: 10px; margin-top: 20px; padding-top: 16px; border-top: 1px solid var(--line); }
.photo-credit__icon { flex: 0 0 18px; margin-top: 2px; color: var(--teal); }
.photo-credit .photo-credit__copy { min-width: 0; margin: 0; }
.photo-credit__intro { display: block; color: var(--ink); font-size: 14px; line-height: 1.5; }
.photo-credit__name { display: table; margin-block: 4px; font-family: var(--font-body); font-size: 20px; line-height: 1.4; text-decoration-thickness: 1px; }
.photo-credit__role { display: block; color: var(--ink); font-family: var(--font-ui); font-size: 12px; line-height: 1.5; }

@media (min-width: 761px) {
  .photo-credit { align-items: center; }
  .photo-credit__icon { margin-top: 0; }
  .photo-credit .photo-credit__copy { display: flex; align-items: baseline; gap: 10px; }
  .photo-credit__intro, .photo-credit__name, .photo-credit__role { white-space: nowrap; }
  .photo-credit__name { margin: 0; font-size: 18px; }
  .photo-credit__role::before { content: "·"; margin-right: 10px; }
}


.photos { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-template-rows: repeat(4, 124px); gap: 15px; }
.photo { position: relative; }
.photo--bed { grid-column: 1 / span 6; grid-row: 1 / span 2;  }
.photo--kitchen { grid-column: 7 / span 6; grid-row: 1 / span 2;  }
.photo--shelf { grid-column: 1 / span 6; grid-row: 3;  }
.photo--detail { grid-column: 7 / span 6; grid-row: 3;  }
.photo--desk { grid-column: 1 / span 6; grid-row: 4;  }
.photo--hall { grid-column: 7 / span 6; grid-row: 4;  }
.house-plan { padding: 0; }
.shell.story { padding-block: var(--home-section-space); }
.house-plan + .guide { margin-top: var(--home-section-space); }
.guide + .story { border-top: 0; }
.music + .story { padding-top: 40px; }
.house-plan details { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.house-plan summary { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 22px 0; color: var(--teal); cursor: pointer; list-style: none; }
.house-plan summary::-webkit-details-marker { display: none; }
.house-plan__title { font-family: var(--section-font); font-size: clamp(25px, 3vw, 34px); line-height: 1.15; }
.house-plan__hint { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 13px; white-space: nowrap; }
.house-plan__hint::after { content: "+"; color: var(--teal); font: 25px/1 system-ui, sans-serif; }
.house-plan details[open] .house-plan__hint::after { content: "−"; }
.house-plan__content { padding: 8px 0 28px; }
.house-plan__content a { display: block; max-width: 860px; margin: 0 auto; background: #fff; }
.house-plan__content img { display: block; width: 100%; height: auto; }
.house-plan__content a:focus-visible { outline-offset: 5px; }
.seo-copy { padding: 0 0 88px; }
.seo-copy p { max-width: 700px; margin: 0; font-size: 18px; line-height: 1.7; }
html[lang="en"] .seo-copy { display: none; }
.guide { display: grid; grid-template-columns: 1fr 1fr; background: var(--teal); color: var(--paper); }
.guide-image { min-height: 450px; position: relative; }
.guide-copy { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; padding: var(--home-panel-space) clamp(28px, 5vw, 72px); }
.guide h2 { max-width: 480px; }
.guide .section-title, .guide .eyebrow { color: var(--paper); }
.guide p:not(.eyebrow) { max-width: 430px; margin: 25px 0 30px; font-size: 17px; }
.guide .cta { color: var(--teal); background: var(--paper); }
.guide .cta:hover { background: var(--soft); }
.guide a:focus-visible { outline-color: var(--paper); }
.music { padding: var(--home-section-space) 0 40px; }
.music-intro { margin: 0; }
.footer-line { width: min(100%, 1060px); }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 24px; margin-bottom: 20px; }
.carousel-toolbar { display: flex; justify-content: flex-end; align-items: center; margin: 16px 0 18px; }
.carousel-controls { display: flex; gap: 10px; align-items: center; }
.carousel-status { min-width: 85px; text-align: center; color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.carousel-button { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid var(--teal); background: var(--paper); color: var(--teal); font: 24px/1 system-ui,sans-serif; cursor: pointer; }
.carousel-button:hover:not(:disabled) { background: var(--teal); color: var(--paper); }
.carousel-button:disabled { border-color: var(--line); color: var(--muted); opacity: 1; border-style: dashed; cursor: default; }
.playlist-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 48px) / 3.2); gap: 24px; overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: thin; scrollbar-color: var(--line) var(--paper); padding: 4px 0 18px; margin: 0; list-style: none; }
.playlist-slide { min-width: 0; scroll-snap-align: start; }
.playlist { display: block; color: var(--ink); text-decoration: none; }
.playlist img { display: block; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; }
.playlist h3 { margin: 13px 0 6px; font-size: clamp(23px, 2.5vw, 30px); line-height: 1.13; letter-spacing: -.025em; }
.playlist p { margin: 0; color: var(--muted); font-size: 13px; }
.playlist .listen-link { display: inline-block; margin-top: 12px; color: var(--teal); font-size: 13px; font-weight: 650; }
.playlist:hover .listen-link { text-decoration: underline; text-underline-offset: 3px; }
.playlist:focus-visible { outline-offset: -2px; }
@media (prefers-reduced-motion: no-preference) {
  .playlist img { transition: transform 250ms ease; }
  .playlist:hover img { transform: translateY(-3px); }
}
@media (max-width: 900px) {
  .playlist-track { grid-auto-columns: 42%; gap: 20px; }
}
@media (max-width: 760px) {
  :root { --home-section-space: 48px; --home-panel-space: 40px; }
  .hero, .guide { grid-template-columns: 1fr; }
  .hero { min-height: auto; }
  .hero .hero-copy { min-height: auto; padding: 36px 24px; }
  .hero-image { min-height: 62vw; }
  .intro { grid-template-columns: 1fr; padding: 0; }
  .intro-image { order: 2; min-height: 0; aspect-ratio: 3 / 2; }
  .intro-copy { order: 1; padding: var(--home-panel-space) 24px; }
  .intro p { font-size: 16px; }
  .homes { padding-bottom: 24px; }
  .house-plan summary { padding: 18px 0; gap: 16px; }
  .house-plan__title { font-size: 27px; }
  .house-plan__hint { font-size: 12px; }
  .house-plan__content { padding-bottom: 20px; }
  .seo-copy { padding-bottom: 64px; }
  .seo-copy p { font-size: 16px; }
  .photos { grid-template-columns: 1fr 1fr; grid-template-rows: none; gap: 12px; }
  .photo { grid-column: auto; grid-row: auto; min-height: 0; }
  .photo--bed, .photo--kitchen, .photo--desk, .photo--hall { grid-column: span 2; aspect-ratio: 4 / 3; }
  .photo--shelf, .photo--detail { aspect-ratio: 1 / 1; }
  .guide-copy { min-height: 0; padding: var(--home-panel-space) 24px; }
  .guide-image { min-height: 60vw; }
  .music { padding: var(--home-section-space) 0 28px; }
  .music + .story { padding-top: 32px; }
  body > footer { padding-inline: 16px; }
  .section-head { align-items: flex-start; flex-direction: column; gap: 14px; }
}
@media (max-width: 570px) {
  .playlist-track { grid-auto-columns: 82%; gap: 16px; }
  .carousel-controls { gap: 6px; }
  .carousel-status { min-width: 68px; font-size: 11px; }
  .carousel-toolbar { gap: 8px; }
}
@media (max-width: 380px) {
  .topbar nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
  .topbar nav > a:not(.book) { font-size: .875rem; }
}
@media (prefers-reduced-motion: reduce) {
  .playlist-track { scroll-behavior: auto; }
}

/* Real image elements retain the exact former background crops and grid geometry. */
.hero-image > img, .photo > img, .guide-image > img { position:absolute; inset:0; display:block; width:100%; height:100%; object-fit:cover; object-position:center; }
