/*
 * Sunlight finishing layer. Loaded after the original page styles.
 * Browser surfaces, refined interactions, the sticky header, page transitions,
 * and the starting states that motion.js animates from. Everything outside
 * `html.sl-motion` renders the finished design with no script.
 */

:root {
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --gold: #b9832f;
  /* The one place to change the script face. */
  --script: "Mr Dafoe", "Brush Script MT", cursive;
}

.hero h1,
.program-mark,
.park-story__title,
.included__copy h2,
.homes__title,
.script-title,
.contact-band h2 {
  font-family: var(--script);
}

/* The closing question is a handwritten line too. */
.contact-band h2 {
  max-width: 16ch;
  font-size: clamp(46px, 5vw, 68px);
  font-weight: 400;
  line-height: 1;
  letter-spacing: 0;
}

.contact-band h2 + p {
  margin-top: 26px;
}

/* ---------- Browser surfaces ---------- */

html {
  accent-color: var(--gold);
  scrollbar-color: #a59b8d var(--paper);
  -webkit-tap-highlight-color: rgb(185 131 47 / 18%);
}

::selection {
  color: var(--ink);
  background: rgb(185 131 47 / 30%);
}

.hero ::selection,
.park-story ::selection,
.values ::selection,
.reviews ::selection,
.story-video ::selection,
.site-footer ::selection,
.masthead ::selection {
  color: #0f0f0f;
  background: rgb(250 244 235 / 88%);
}

a {
  text-decoration-thickness: 1px;
  text-underline-offset: 0.22em;
}

/* Phone numbers and prices set with even, lining figures. */
.contact-button,
.hero__button,
.site-footer__contact,
.included__amount {
  font-variant-numeric: lining-nums tabular-nums;
}

/* Let opening quotation marks hang outside the text edge. */
.quote blockquote p,
.review p {
  hanging-punctuation: first;
}

/* Footer links: a gold line draws in from the left instead of a plain underline. */
.site-footer .site-footer__links a,
.site-footer .site-footer__contact a,
.site-footer .site-footer__more a {
  text-decoration: none;
  background: linear-gradient(var(--gold), var(--gold)) no-repeat 100% calc(100% - 2px) / 0 1px;
  transition: background-size 420ms var(--ease-out), color 200ms ease;
}

.site-footer .site-footer__links a:hover,
.site-footer .site-footer__links a:focus-visible,
.site-footer .site-footer__contact a:hover,
.site-footer .site-footer__contact a:focus-visible,
.site-footer .site-footer__more a:hover,
.site-footer .site-footer__more a:focus-visible {
  text-decoration: none;
  background-position: 0 calc(100% - 2px);
  background-size: 100% 1px;
}

/* Blue focus rings disappear on near-black; use cream on dark surfaces. */
.hero :focus-visible,
.park-story :focus-visible,
.values :focus-visible,
.reviews :focus-visible,
.story-video :focus-visible,
.site-footer :focus-visible,
.site-footer a:focus-visible {
  outline-color: var(--logo-cream);
}

p,
dd,
li,
blockquote p {
  text-wrap: pretty;
}

.hero,
.park-story,
.values,
.reviews,
.story-video,
.site-footer,
.masthead {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ---------- Hero ---------- */

/* Warm light falling into the room from the upper left. */
.hero::after {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(60% 70% at 8% 0%, rgb(255 190 110 / 30%) 0%, rgb(255 190 110 / 0%) 62%),
    radial-gradient(40% 50% at 30% 100%, rgb(185 131 47 / 14%) 0%, rgb(185 131 47 / 0%) 70%);
  content: "";
  mix-blend-mode: soft-light;
  opacity: var(--sun, 1);
  pointer-events: none;
}

.hero__copy p:first-child {
  color: var(--logo-cream);
  font-size: clamp(17px, 1.3vw, 19px);
  line-height: 1.5;
}

.hero__copy p + p {
  color: #e8dfd2;
}

/* ---------- Buttons: a fill that sweeps across instead of snapping ---------- */

.hero__button,
.contact-button {
  position: relative;
  z-index: 0;
  isolation: isolate;
  overflow: hidden;
  transition: color 320ms var(--ease-out), translate 160ms ease-out;
}

.hero__button::before,
.contact-button::before {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  transform: scaleX(0);
  transform-origin: right center;
  transition: transform 520ms var(--ease-out);
}

.hero__button:hover::before,
.hero__button:focus-visible::before,
.contact-button:hover::before,
.contact-button:focus-visible::before {
  transform: scaleX(1);
  transform-origin: left center;
}

.hero__button:active,
.contact-button:active {
  translate: 0 1px;
}

.hero__button,
.hero__button:hover,
.hero__button--primary,
.hero__button--primary:hover {
  background: transparent;
}

.hero__button::before {
  background: var(--logo-cream);
}

.hero__button:hover,
.hero__button:focus-visible {
  color: var(--ink);
}

.hero__button--primary {
  color: var(--ink);
}

.hero__button--primary::before {
  transform: scaleX(1);
}

.hero__button--primary:hover,
.hero__button--primary:focus-visible {
  color: var(--logo-cream);
}

.hero__button--primary:hover::before,
.hero__button--primary:focus-visible::before {
  transform: scaleX(0);
  transform-origin: right center;
}

.contact-button:hover,
.contact-button:focus-visible {
  color: var(--ink);
  background: var(--ink);
}

.contact-button::before {
  background: #ffffff;
}

.contact-button--outline,
.contact-button--outline:hover,
.contact-button--outline:focus-visible {
  background: transparent;
}

.contact-button--outline::before {
  background: var(--ink);
}

.contact-button--outline:hover,
.contact-button--outline:focus-visible {
  color: var(--logo-cream);
}

/* ---------- Sticky header (enabled by motion.js) ---------- */

.sl-header .masthead {
  position: fixed;
  z-index: 30;
  transition:
    transform 520ms var(--ease-out),
    background-color 360ms ease,
    min-height 360ms var(--ease-out),
    padding 360ms var(--ease-out),
    box-shadow 360ms ease;
}

.sl-header .masthead.is-solid {
  --masthead-height: 76px;
  padding-bottom: 0;
  background: rgb(15 15 15 / 92%);
  box-shadow: 0 1px 0 rgb(250 244 235 / 8%);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.sl-header .masthead .brand {
  transition: min-height 360ms var(--ease-out);
}

.sl-header .masthead .brand__logo--arch {
  transition: height 360ms var(--ease-out);
}

.sl-header .masthead.is-solid .brand {
  min-height: 68px;
}

.sl-header .masthead.is-solid .brand__logo--arch {
  height: 60px;
}

.sl-header .masthead.is-hidden {
  transform: translateY(-104%);
}

@media (max-width: 700px) {
  .sl-header .masthead.is-solid {
    --masthead-height: 68px;
  }

  .sl-header .masthead.is-solid .brand {
    min-height: 60px;
  }

  .sl-header .masthead.is-solid .brand__logo--arch {
    height: 52px;
  }
}

/* ---------- Phones: a call bar once the hero has scrolled away ---------- */

.sl-callbar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 25;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  padding: 10px 12px calc(10px + env(safe-area-inset-bottom));
  background: rgb(15 15 15 / 94%);
  box-shadow: 0 -1px 0 rgb(250 244 235 / 10%);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  -webkit-font-smoothing: antialiased;
  transform: translateY(110%);
  visibility: hidden;
  transition: transform 460ms var(--ease-out), visibility 0s linear 460ms;
}

.sl-callbar.is-shown {
  transform: none;
  visibility: visible;
  transition: transform 460ms var(--ease-out), visibility 0s;
}

.sl-callbar a {
  display: grid;
  align-content: center;
  min-height: 52px;
  padding: 6px 12px;
  color: var(--ink);
  background: var(--logo-cream);
  text-decoration: none;
  line-height: 1.2;
}

.sl-callbar a span {
  font-size: 12px;
  font-weight: 700;
}

.sl-callbar a strong {
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}

.sl-callbar a:focus-visible {
  outline: 3px solid var(--logo-cream);
  outline-offset: 2px;
}

@media (min-width: 701px) {
  .sl-callbar {
    display: none;
  }
}

/* ---------- Home: stack the program section on phones ---------- */

@media (max-width: 700px) {
  .program-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .program-copy {
    padding: 0 0 36px;
    border-right: 0;
    border-bottom: 1px solid rgb(23 23 23 / 24%);
  }

  .program-copy h2 {
    font-size: 19px;
    line-height: 1.35;
  }

  .program-copy p {
    font-size: 16px;
    line-height: 1.6;
  }

  .program-mark {
    font-size: clamp(54px, 16vw, 66px);
  }

  .program-mark__line {
    height: 10px;
    margin: 26px 0 30px;
  }
}

/* ---------- "Recover / All Odds": a dry-brush stroke, not a solid bar ---------- */

/* The stroke is drawn in a generated SVG: a blunt start where the brush
   lands, a long taper, ragged edges and broken bristle streaks, with
   the ink running dry toward the end. Painted as the element's background so
   no box edge can show; no image file to load. */
.program-mark__line {
  height: 24px;
  clip-path: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 40' preserveAspectRatio='none'%3E%3ClinearGradient id='g'%3E%3Cstop offset='0' stop-color='%23171717'/%3E%3Cstop offset='.55' stop-color='%23171717'/%3E%3Cstop offset='.82' stop-color='%23171717' stop-opacity='.72'/%3E%3Cstop offset='1' stop-color='%23171717' stop-opacity='.38'/%3E%3C/linearGradient%3E%3Cfilter id='r' x='0' y='0' width='100%25' height='100%25' filterUnits='userSpaceOnUse'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.03 0.35' numOctaves='2' seed='4' result='edge'/%3E%3CfeDisplacementMap in='SourceGraphic' in2='edge' scale='7' xChannelSelector='R' yChannelSelector='G' result='shape'/%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.011 0.24' numOctaves='3' seed='11' result='n'/%3E%3CfeColorMatrix in='n' values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 8 0 0 0 -2.6' result='streaks'/%3E%3CfeComposite in='shape' in2='streaks' operator='in'/%3E%3C/filter%3E%3Cpath d='M6 19 C 7 9%2C 28 5%2C 78 6 L 330 12 C 468 16 556 22 596 25 C 556 29 468 31 330 31 L 74 35 C 26 37 5 31 6 19 Z' fill='url%28%23g%29' filter='url%28%23r%29'/%3E%3C/svg%3E") center / 100% 100% no-repeat;
}

@media (max-width: 700px) {
  .program-mark__line {
    height: 17px;
  }
}

/* ---------- Galleries ---------- */

.gallery__controls .gallery__count {
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.08em;
}

.gallery__count [data-sl-current] {
  color: var(--ink);
  font-weight: 700;
}

.gallery__slide img {
  transition: transform 900ms var(--ease-out);
}

@media (hover: hover) {
  .gallery:hover .gallery__slide img {
    transform: scale(1.025);
  }
}

/* Ink on gold reads at 5.4:1; cream on gold was about 3:1. */
.home-card__badge {
  color: var(--ink);
}

/* The review band and the story video share one dark field; close the gap. */
.reviews {
  padding-bottom: clamp(24px, 3vw, 40px);
}

html {
  scroll-padding-top: 88px;
}

/* Pause the review drift when it is off screen. */
.reviews__viewport.is-offscreen .reviews__track {
  animation-play-state: paused;
}

/* ---------- Motion starting states (only with motion enabled) ---------- */

.sl-motion .masthead .brand,
.sl-motion .masthead .nav a,
.sl-motion .masthead .menu-button,
.sl-motion .hero h1,
.sl-motion .hero__content > p,
.sl-motion .hero__copy p,
.sl-motion .hero__actions > * {
  opacity: 0;
}

.sl-motion .hero {
  --sun: 0;
}

.sl-motion .hero__image {
  transform: scale(1.07);
}

/* A handwriting line: a soft-edged mask sweeps left to right. Padding lets
   swashes and descenders sit inside the mask without shifting the layout. */
.sl-write {
  width: fit-content;
  margin: -0.22em -0.4em -0.36em;
  padding: 0.22em 0.4em 0.36em;
  -webkit-mask-image: linear-gradient(100deg, #000 calc(var(--wipe, 120%) - 1.1em), transparent var(--wipe, 120%));
  mask-image: linear-gradient(100deg, #000 calc(var(--wipe, 120%) - 1.1em), transparent var(--wipe, 120%));
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
}

.sl-line {
  width: fit-content;
}

/* Dividers and gold rules that draw themselves. */
.sl-draw-y {
  position: relative;
}

@media print {
  .sl-motion [style] {
    opacity: 1 !important;
    clip-path: none !important;
    transform: none !important;
  }

  .sl-write {
    -webkit-mask-image: none;
    mask-image: none;
  }
}

.sl-motion .values__list div::before {
  transform: scaleX(var(--draw, 1));
  transform-origin: left center;
}

.sl-motion .quote {
  border-top-color: transparent;
}

.sl-motion .quote::before {
  position: absolute;
  top: -2px;
  right: 0;
  left: 0;
  height: 2px;
  background: var(--gold);
  content: "";
  transform: scaleX(var(--draw, 1));
  transform-origin: left center;
}

/* Vertical column dividers draw downward. Phone layouts move or drop these
   dividers, so the effect is desktop-only. */
@media (min-width: 701px) {
  .sl-motion .sl-draw-y.is-right {
    border-right-color: transparent;
  }

  .sl-motion .sl-draw-y.is-left {
    border-left-color: transparent;
  }

  .sl-motion .sl-draw-y::after {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 1px;
    background: rgb(23 23 23 / 24%);
    content: "";
    transform: scaleY(var(--draw, 1));
    transform-origin: center top;
  }

  .sl-motion .sl-draw-y.is-right::after {
    right: 0;
  }

  .sl-motion .sl-draw-y.is-left::after {
    left: 0;
  }
}

/* ---------- Page transitions ---------- */

@view-transition {
  navigation: auto;
}

/* A plain crossfade: the header is identical on every page, so it reads as
   staying put while the page beneath it changes. */
::view-transition-old(root) {
  animation: 240ms var(--ease-in-out) both sl-page-out;
}

::view-transition-new(root) {
  animation: 520ms var(--ease-out) 60ms both sl-page-in;
}

@keyframes sl-page-out {
  to {
    opacity: 0;
  }
}

@keyframes sl-page-in {
  from {
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }

  .sl-header .masthead,
  .sl-callbar,
  .sl-callbar.is-shown,
  .hero__button::before,
  .contact-button::before,
  .gallery__slide img {
    transition: none;
  }
}
