/* ==========================================================================
   Disconnected: layout.css
   Page furniture: header, navigation, hero, sections, grids, footer.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Header + navigation
   -------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: box-shadow .25s var(--ease), border-color .25s var(--ease);
}
.site-header.is-stuck {
  border-bottom-color: var(--line);
  box-shadow: 0 6px 24px rgba(26, 26, 26, .06);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  min-height: var(--header-h);
}

.logo { display: inline-flex; align-items: center; }
.logo img { height: clamp(40px, 4.4vw, 52px); width: auto; }

.nav__list {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav__link,
.nav__submenu-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.55rem 0.85rem;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--ink-soft);
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1;
  transition: background .2s var(--ease), color .2s var(--ease);
}
.nav__link:hover,
.nav__submenu-toggle:hover {
  background: var(--sand-deep);
  color: var(--ink);
  text-decoration: none;
}
.nav__link.is-active {
  color: var(--orange);
  background: var(--orange-soft);
}

.nav__submenu-toggle svg {
  width: 12px;
  height: 12px;
  transition: transform .25s var(--ease);
}
.nav__submenu-toggle[aria-expanded="true"] svg { transform: rotate(180deg); }

.nav__item { position: relative; }

.nav__submenu {
  list-style: none;
  margin: 0;
  padding: 0.4rem;
}

.nav__submenu a {
  display: block;
  padding: 0.6rem 0.85rem;
  border-radius: var(--radius-sm);
  color: var(--ink-soft);
  font-size: 0.95rem;
}
.nav__submenu a:hover { background: var(--sand); color: var(--orange-dark); text-decoration: none; }
.nav__submenu a small { display: block; color: var(--muted); font-size: 0.78rem; line-height: 1.4; }

.nav__cta { margin-left: 0.5rem; }

@media (min-width: 961px) {
  .nav__submenu {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 0;
    min-width: 260px;
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: opacity .2s var(--ease), transform .2s var(--ease), visibility .2s;
  }
  .nav__item.is-open .nav__submenu {
    opacity: 1;
    visibility: visible;
    transform: none;
  }
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--white);
  padding: 0;
  place-items: center;
}
.nav-toggle span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--ink);
  border-radius: 2px;
  transition: transform .25s var(--ease), opacity .2s var(--ease);
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 960px) {
  .nav-toggle { display: grid; }

  .nav {
    position: fixed;
    inset: var(--header-h) 0 0 0;
    background: var(--white);
    border-top: 1px solid var(--line);
    padding: var(--space-md) 1.25rem var(--space-xl);
    overflow-y: auto;
    transform: translateX(100%);
    visibility: hidden;
    transition: transform .3s var(--ease), visibility .3s;
  }
  .nav.is-open { transform: none; visibility: visible; }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
  }
  .nav__link,
  .nav__submenu-toggle {
    width: 100%;
    justify-content: space-between;
    padding: 0.9rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 1.05rem;
  }
  .nav__submenu {
    display: none;
    margin: 0.15rem 0 0.4rem 0.6rem;
    padding-left: 0.6rem;
    border-left: 2px solid var(--line);
  }
  .nav__item.is-open .nav__submenu { display: block; }
  .nav__cta { margin: var(--space-md) 0 0; }
  .nav__cta .btn { width: 100%; }

  body.nav-open { overflow: hidden; }
}

/* --------------------------------------------------------------------------
   2. Sections
   -------------------------------------------------------------------------- */
.section { padding: var(--space-2xl) 0; }
.section--tight { padding: var(--space-xl) 0; }
.section--sand { background: var(--sand); }
.section--sand-deep { background: var(--sand-deep); }
.section--ink { background: var(--ink); color: #cfd4d8; }
.section--ink h2, .section--ink h3 { color: #fff; }

.section-head {
  max-width: 720px;
  margin-bottom: var(--space-lg);
}
.section-head--center {
  margin-inline: auto;
  text-align: center;
}
.section-head p { color: var(--body); font-size: var(--step-1); line-height: 1.6; }

/* --------------------------------------------------------------------------
   3. Hero
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  isolation: isolate;
  padding: clamp(3.5rem, 8vw, 7rem) 0 clamp(3rem, 6vw, 5.5rem);
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .94) 0%, rgba(255, 255, 255, .78) 55%, rgba(250, 247, 242, .96) 100%),
    url("../img/hero/living-space.jpg") center / cover no-repeat,
    linear-gradient(135deg, #eef5f3 0%, #faf7f2 45%, #fdeed9 100%);
}
.hero::before,
.hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  z-index: -1;
}
.hero::before {
  width: 520px; height: 520px;
  top: -180px; right: -140px;
  background: radial-gradient(circle at 30% 30%, rgba(247, 127, 10, .16), transparent 65%);
}
.hero::after {
  width: 460px; height: 460px;
  bottom: -220px; left: -160px;
  background: radial-gradient(circle at 60% 40%, rgba(31, 122, 107, .14), transparent 65%);
}

.hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr);
  gap: var(--space-xl);
  align-items: center;
}

.hero__statement {
  margin: var(--space-sm) 0 var(--space-md);
  padding-left: var(--space-md);
  border-left: 3px solid var(--orange);
  font-family: var(--font-display);
  font-size: var(--step-3);
  font-weight: 500;
  color: var(--ink);
  line-height: 1.3;
  max-width: 24ch;
}

/* Logo above the supporting facts, in the second hero column */
.hero__aside {
  display: grid;
  gap: var(--space-lg);
  justify-items: start;
}
.hero__logo {
  width: min(100%, 320px);
  height: auto;
}

/* The three steps, kept quiet so the statement carries the hero */
.hero__stats {
  width: 100%;
  display: grid;
  gap: var(--space-sm);
}
.hero__stats .stat {
  padding: var(--space-xs) 0 var(--space-xs) var(--space-md);
  background: none;
  border-left: 2px solid var(--line);
  border-radius: 0;
}
.hero__stats .stat__value {
  font-size: var(--step-1);
  color: var(--ink-soft);
}
.hero__stats .stat__label { font-size: var(--step--1); }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm);
  margin-top: var(--space-lg);
}

@media (max-width: 900px) {
  .hero__inner { grid-template-columns: 1fr; gap: var(--space-lg); }
  .hero__statement { max-width: 100%; }
}

.motto {
  background: var(--ink);
  color: #fff;
  padding: var(--space-md) 0;
}
.motto__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem 1.25rem;
  text-align: center;
}
.motto p {
  margin: 0;
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: 500;
  letter-spacing: -0.01em;
}

/* --------------------------------------------------------------------------
   4. Grids
   -------------------------------------------------------------------------- */
.grid { display: grid; gap: var(--space-md); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-xl);
  align-items: center;
}

@media (max-width: 960px) {
  .grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split   { grid-template-columns: 1fr; gap: var(--space-lg); }
}
@media (max-width: 620px) {
  .grid--2, .grid--3, .grid--4 { grid-template-columns: 1fr; }
}

/* --------------------------------------------------------------------------
   5. Page header + editorial layout (inner pages)
   -------------------------------------------------------------------------- */
.page-head {
  padding: var(--space-xl) 0 var(--space-lg);
  background: linear-gradient(180deg, var(--sand) 0%, var(--white) 100%);
  border-bottom: 1px solid var(--line);
}
.page-head h1 { max-width: 20ch; }
.page-head p { max-width: 62ch; font-size: var(--step-1); }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0 0 var(--space-sm);
  padding: 0;
  list-style: none;
  font-size: var(--step--1);
  color: var(--muted);
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--orange-dark); }
.breadcrumb li + li::before { content: "/"; margin-right: 0.4rem; color: var(--line); }

.doc {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: var(--space-xl);
  align-items: start;
}
.toc {
  position: sticky;
  top: calc(var(--header-h) + 1.5rem);
  padding: var(--space-md);
  background: var(--sand);
  border-radius: var(--radius);
}
.toc h2 {
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: var(--space-sm);
}
.toc ul { list-style: none; margin: 0; padding: 0; }
.toc li { margin-bottom: 0.5rem; line-height: 1.35; }
.toc a { color: var(--ink-soft); font-size: 0.92rem; }
.toc a:hover, .toc a.is-active { color: var(--orange-dark); text-decoration: none; }
.toc a.is-active { font-weight: 600; }

@media (max-width: 960px) {
  .doc { grid-template-columns: 1fr; gap: var(--space-lg); }
  .toc { position: static; }
}

/* --------------------------------------------------------------------------
   6. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  background: var(--ink);
  color: #a8b0b7;
  padding: var(--space-xl) 0 var(--space-md);
  font-size: 0.95rem;
}
.site-footer a { color: #d6dbdf; }
.site-footer a:hover { color: var(--orange); text-decoration: none; }

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: var(--space-lg);
}
.footer-brand img {
  height: 42px;
  width: auto;
  margin-bottom: var(--space-sm);
}
.footer-brand p { max-width: 34ch; color: #8f979e; }

.footer-col h3 {
  color: #fff;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: var(--space-sm);
}
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin-bottom: 0.55rem; }

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-xl);
  padding-top: var(--space-md);
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: 0.86rem;
  color: #7d858c;
}

@media (max-width: 860px) {
  .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 520px) {
  .footer-grid { grid-template-columns: 1fr; }
}
