/* ==========================================================================
   Kearsten DeGolyer Design — shared stylesheet
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,300;9..144,400;9..144,500;9..144,600&family=Fraunces:ital,opsz,wght@1,9..144,400&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

:root{
  /* --- Color tokens — cool stone/plaster, grounded in Saorsa Ranch --- */
  --stone:      #E8E6E1;   /* cool limestone/plaster grey, main background */
  --stone-dark: #DAD7D0;   /* deeper grey for section breaks */
  --paper:      #F4F3F0;   /* lightest card surface */
  --ink:        #211E1A;   /* warm charcoal — black steel windows, dark millwork */
  --ink-soft:   #5B5955;   /* neutral grey, secondary text */
  --sage:       #565C63;   /* primary accent — the slate-blue cabinetry seen through the house */
  --sage-deep:  #34383D;   /* deep slate, solid buttons / focus */
  --clay:       #6E5640;   /* secondary accent — walnut millwork, used sparingly */
  --brass:      #8C8377;   /* tertiary accent — fireplace stone */
  --line:       #D2CFC8;   /* hairline rule color */

  /* --- Type tokens --- */
  --f-display: 'Fraunces', serif;
  --f-body: 'Inter', -apple-system, sans-serif;
  --f-mono: 'JetBrains Mono', monospace;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.75rem;
  --space-4: 3rem;
  --space-5: 5rem;
  --space-6: 8rem;
}

*, *::before, *::after{ box-sizing: border-box; }

html{ scroll-behavior: smooth; }

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body{
  margin: 0;
  background: var(--stone);
  color: var(--ink);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img{ max-width: 100%; display: block; }

a{ color: inherit; }

h1, h2, h3, h4{
  font-family: var(--f-display);
  font-weight: 500;
  line-height: 1.08;
  margin: 0;
  letter-spacing: -0.01em;
}

p{ margin: 0 0 1em 0; }

.container{
  max-width: 1240px;
  margin: 0 auto;
  padding-left: var(--space-3);
  padding-right: var(--space-3);
}

/* --- Focus states --- */
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible{
  outline: 2px solid var(--sage-deep);
  outline-offset: 3px;
}

/* ==========================================================================
   Site header — logo left, menu right, single horizontal bar
   ========================================================================== */

.site-header{
  position: sticky;
  top: 0;
  z-index: 150;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.6rem var(--space-4);
  background: var(--stone);
}
.site-header__location{
  font-family: var(--f-mono);
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-soft);
}
@media (max-width: 760px){
  .site-header__location{ font-size: 0.7rem; }
}
@media (max-width: 480px){
  .site-header__location{ display: none; }
}
.site-header__wordmark{
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--f-display);
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--ink);
  text-decoration: none;
}
@media (max-width: 760px){
  .site-header__wordmark{ font-size: 1rem; max-width: 60vw; text-align: center; }
}
@media (max-width: 400px){
  .site-header__wordmark{ font-size: 0.85rem; max-width: 55vw; }
}
.menu-btn{
  display: flex;
  align-items: center;
  gap: 0.8em;
  padding: 0.85em 1.4em;
  border-radius: 999px;
  border: 1px solid var(--ink);
  background: transparent;
  color: var(--ink);
  font-family: var(--f-mono);
  font-size: 0.85rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease;
}
.menu-btn:hover{ background: var(--ink); color: var(--paper); }
.menu-btn__lines{
  display: flex;
  flex-direction: column;
  gap: 4px;
  width: 18px;
}
.menu-btn__lines span{
  display: block;
  height: 2px;
  background: currentColor;
}
.menu-btn__lines span:nth-child(2){ width: 70%; }
@media (max-width: 760px){
  .site-header{ padding: 1rem var(--space-2); }
  .menu-btn span:not(.menu-btn__lines){ display: none; }
  .menu-btn{ padding: 0.7em; }
}

/* ==========================================================================
   Main content
   ========================================================================== */

main, .site-footer{ margin-left: 0; }

/* full nav overlay */
.nav-overlay__backdrop{
  position: fixed;
  inset: 0;
  background: rgba(17,15,13,0.45);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}
.nav-overlay__backdrop.is-open{
  opacity: 1;
  pointer-events: auto;
}

.nav-overlay{
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  width: min(440px, 86vw);
  background: var(--ink);
  color: var(--paper);
  z-index: 200;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--space-3) var(--space-4);
  transform: translateX(-100%);
  transition: transform 0.45s cubic-bezier(.7,0,.2,1);
  box-shadow: 12px 0 40px rgba(17,15,13,0.25);
}
.nav-overlay.is-open{ transform: translateX(0); }

.nav-overlay__logo{
  position: absolute;
  top: var(--space-3);
  left: var(--space-4);
  width: 64px;
}
.nav-overlay__logo img{ width: 100%; display: block; }

.nav-overlay__close{
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  background: none;
  border: 1px solid rgba(248,246,240,0.35);
  color: var(--paper);
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.6em 1.1em;
  border-radius: 999px;
  cursor: pointer;
}

.nav-overlay__list{
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-overlay__list li{ margin: 0.15em 0; }
.nav-overlay__list a{
  font-family: var(--f-display);
  font-size: clamp(1.8rem, 6vw, 2.6rem);
  text-decoration: none;
  color: var(--paper);
  display: inline-flex;
  gap: 0.4em;
  align-items: baseline;
  transition: color 0.2s ease;
}
.nav-overlay__list a:hover{ color: var(--sage); }
.nav-overlay__num{
  font-family: var(--f-mono);
  font-size: 0.9rem;
  color: var(--brass);
}

.nav-overlay__foot{
  margin-top: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: 0.7em;
  font-family: var(--f-mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: rgba(248,246,240,0.6);
}
.nav-overlay__foot a{ text-decoration: none; }
.nav-overlay__foot a:hover{ color: var(--paper); }

@media (max-width: 760px){
  .nav-overlay{ padding: var(--space-3) var(--space-2); }
  .nav-overlay__logo{ left: var(--space-2); width: 48px; }
  .nav-overlay__close{ right: var(--space-2); }
}

/* ==========================================================================
   Eyebrow / labels
   ========================================================================== */

.eyebrow{
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--sage-deep);
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  margin-bottom: var(--space-2);
}
.eyebrow::before{
  content: "";
  width: 18px;
  height: 1px;
  background: var(--clay);
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero{
  padding-top: var(--space-6);
  padding-bottom: var(--space-5);
  position: relative;
}

.hero__title{
  font-size: clamp(2.6rem, 6.2vw, 5.6rem);
  max-width: 14ch;
}
.hero__title em{
  font-style: italic;
  font-weight: 400;
  color: var(--clay);
}

.hero__lede{
  font-size: 1.15rem;
  color: var(--ink-soft);
  max-width: 42ch;
  margin-top: var(--space-3);
}

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

/* ==========================================================================
   Swatch rail — signature motif: a strip of material samples
   ========================================================================== */

.swatchrail{
  display: flex;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
  scrollbar-width: none;
}
.swatchrail::-webkit-scrollbar{ display: none; }

.swatch{
  flex: 0 0 auto;
  width: 168px;
  padding: var(--space-2) var(--space-2) var(--space-3);
  border-right: 1px solid var(--line);
}
.swatch__chip{
  width: 100%;
  aspect-ratio: 1;
  border-radius: 2px;
  margin-bottom: 0.9em;
  box-shadow: inset 0 0 0 1px rgba(35,32,25,0.08);
}
.swatch__name{
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  display: block;
}
.swatch__code{
  font-family: var(--f-mono);
  font-size: 0.65rem;
  color: var(--ink-soft);
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn{
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
  padding: 0.95em 1.6em;
  border-radius: 999px;
  border: 1px solid var(--ink);
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  transition: background 0.25s ease, color 0.25s ease, border-color .25s ease;
}
.btn:hover{ background: var(--ink); color: var(--paper); }

.btn--solid{
  background: var(--sage-deep);
  border-color: var(--sage-deep);
  color: var(--paper);
}
.btn--solid:hover{ background: var(--ink); border-color: var(--ink); }

/* ==========================================================================
   Section spacing / dividers
   ========================================================================== */

section{ padding: var(--space-5) 0; }
.section--tight{ padding-top: var(--space-4); padding-bottom: var(--space-4); }
.section--stone{ background: var(--stone-dark); }
.section--ink{ background: var(--ink); color: var(--paper); }
.section--ink .ink-soft{ color: rgba(248,246,240,0.62); }
.section--ink .eyebrow{ color: var(--brass); }
.section--ink .eyebrow::before{ background: var(--brass); }

.rule{
  border: none;
  border-top: 1px solid var(--line);
  margin: 0;
}

/* ==========================================================================
   Grid helpers
   ========================================================================== */

.grid-2{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
}
.grid-3{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
@media (max-width: 860px){
  .grid-2, .grid-3{ grid-template-columns: 1fr; }
}

.offset-col{
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: var(--space-4);
  align-items: start;
}
@media (max-width: 860px){
  .offset-col{ grid-template-columns: 1fr; }
}

.text-photo-col{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
  align-items: center;
}
@media (max-width: 860px){
  .text-photo-col{ grid-template-columns: 1fr; }
}

/* ==========================================================================
   Placeholder imagery blocks
   Client note: replace these with real project photography.
   ========================================================================== */

.ph{
  position: relative;
  width: 100%;
  aspect-ratio: var(--ph-ratio, 4/3);
  border-radius: 3px;
  overflow: hidden;
  background: linear-gradient(155deg, var(--ph-a, #CFC7B4), var(--ph-b, #B9AF97));
  display: flex;
  align-items: flex-end;
  color: rgba(35,32,25,0.55);
}
.ph::after{
  content: "";
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(135deg, rgba(35,32,25,0.05) 0 2px, transparent 2px 14px);
}
.ph__label{
  position: relative;
  z-index: 1;
  font-family: var(--f-mono);
  font-size: 0.68rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.9em 1em;
}

/* Real photo variant — no texture overlay, no label */
.ph--photo{
  background: var(--stone-dark);
  display: block;
}
.ph--photo::after{ content: none; }
.ph--photo img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ==========================================================================
   Cards — services / process
   ========================================================================== */

.card{
  border-top: 1px solid var(--line);
  padding-top: var(--space-3);
}
.card__num{
  font-family: var(--f-mono);
  font-size: 0.75rem;
  color: var(--clay);
}
.card h3{
  font-size: 1.5rem;
  margin: 0.5em 0 0.5em;
}
.card p{ color: var(--ink-soft); }

/* ==========================================================================
   Testimonial / quote
   ========================================================================== */

.quote{
  font-family: var(--f-display);
  font-style: italic;
  font-size: clamp(1.4rem, 3vw, 2.1rem);
  max-width: 26ch;
  line-height: 1.3;
}
.quote__attr{
  font-family: var(--f-mono);
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-top: var(--space-3);
  display: block;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer{
  background: var(--ink);
  color: var(--paper);
  padding: var(--space-5) 0 var(--space-3);
}
.site-footer a{ text-decoration: none; }
.footer-logo{
  width: 56px;
  margin-bottom: var(--space-3);
}
.footer-logo img{ width: 100%; display: block; }

.footer-top{
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: var(--space-4);
}
@media (max-width: 760px){
  .footer-top{ grid-template-columns: 1fr; }
}
.footer-top h4{
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--brass);
  margin-bottom: 1em;
}
.footer-links{ list-style: none; padding: 0; margin: 0; }
.footer-links li{ margin-bottom: 0.6em; color: rgba(248,246,240,0.75); }
.footer-links a:hover{ color: var(--sage); }
.footer-bottom{
  margin-top: var(--space-5);
  padding-top: var(--space-3);
  border-top: 1px solid rgba(248,246,240,0.15);
  display: flex;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 1em;
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.05em;
  color: rgba(248,246,240,0.5);
}

/* ==========================================================================
   Forms
   ========================================================================== */

.form-field{ margin-bottom: var(--space-3); }
.form-field label{
  display: block;
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.6em;
  color: var(--ink-soft);
}
.form-field input, .form-field textarea, .form-field select{
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--line);
  padding: 0.7em 0.1em;
  font-family: var(--f-body);
  font-size: 1rem;
  color: var(--ink);
}
.form-field input:focus, .form-field textarea:focus, .form-field select:focus{
  border-bottom-color: var(--sage-deep);
}
.form-field textarea{ resize: vertical; min-height: 110px; }
.form-note{
  font-family: var(--f-mono);
  font-size: 0.72rem;
  color: var(--ink-soft);
  margin-top: 1.5em;
}

/* ==========================================================================
   Homepage carousel — cycles through project photography
   ========================================================================== */

.hero-carousel{
  position: relative;
  width: 100%;
  aspect-ratio: 16/10;
  overflow: hidden;
  border-radius: 2px;
  background: var(--ink);
}
@media (max-width: 760px){
  .hero-carousel{ aspect-ratio: 4/5; }
}
.hero-carousel__slide{
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1.4s ease;
}
.hero-carousel__slide.is-active{ opacity: 1; z-index: 1; }
.hero-carousel__slide img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.hero-carousel__caption{
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: var(--space-3);
  background: linear-gradient(0deg, rgba(17,15,13,0.55) 0%, rgba(17,15,13,0) 60%);
}
.hero-carousel__caption span{
  font-family: var(--f-mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--paper);
}
.hero-carousel__dots{
  display: flex;
  gap: 0.5em;
}
.hero-carousel__dot{
  width: 6px; height: 6px;
  border-radius: 50%;
  background: rgba(248,246,240,0.4);
  transition: background 0.3s ease, transform 0.3s ease;
}
.hero-carousel__dot.is-active{
  background: var(--paper);
  transform: scale(1.3);
}

/* ==========================================================================
   Lightbox — full uncropped photo viewer with prev/next
   ========================================================================== */

.lightbox{
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(17,15,13,0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}
.lightbox.is-open{
  opacity: 1;
  pointer-events: auto;
}
.lightbox__figure{
  max-width: 92vw;
  max-height: 82vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.lightbox__figure img{
  max-width: 92vw;
  max-height: 78vh;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
.lightbox__caption{
  margin-top: 1.2em;
  font-family: var(--f-mono);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(248,246,240,0.75);
  text-align: center;
}
.lightbox__close{
  position: absolute;
  top: var(--space-3);
  right: var(--space-3);
  background: none;
  border: 1px solid rgba(248,246,240,0.35);
  color: var(--paper);
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.6em 1.1em;
  border-radius: 999px;
  cursor: pointer;
}
.lightbox__arrow{
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: 1px solid rgba(248,246,240,0.35);
  color: var(--paper);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  cursor: pointer;
  font-family: var(--f-body);
  font-size: 1.3rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.25s ease;
}
.lightbox__arrow:hover{ background: rgba(248,246,240,0.12); }
.lightbox__arrow--prev{ left: var(--space-3); }
.lightbox__arrow--next{ right: var(--space-3); }
@media (max-width: 760px){
  .lightbox__close{ top: 14px; right: 14px; }
  .lightbox__arrow{ width: 40px; height: 40px; }
  .lightbox__arrow--prev{ left: 10px; }
  .lightbox__arrow--next{ right: 10px; }
}

.filterbar{
  display: flex;
  gap: 0.6em;
  flex-wrap: wrap;
  margin-bottom: var(--space-4);
}
.filterbar button{
  font-family: var(--f-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.6em 1.1em;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink-soft);
  cursor: pointer;
}
.filterbar button.is-active{
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.project-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-3);
}
@media (max-width: 980px){
  .project-grid{ grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px){
  .project-grid{ grid-template-columns: 1fr; }
}
.project-card{ text-decoration: none; color: var(--ink); display: block; }
.project-card__meta{
  display: flex;
  justify-content: space-between;
  margin-top: 0.9em;
  font-family: var(--f-mono);
  font-size: 0.72rem;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.project-card h3{
  font-size: 1.3rem;
  margin-top: 0.35em;
}

/* ==========================================================================
   Instagram grid
   ========================================================================== */

.igrid{
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
}
@media (max-width: 760px){
  .igrid{ grid-template-columns: repeat(2, 1fr); }
}
.igrid__item{
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  display: block;
  text-decoration: none;
}
.igrid__item .ph{ aspect-ratio: 1; border-radius: 0; height: 100%; }
.igrid__item::after{
  content: "";
  position: absolute; inset: 0;
  background: rgba(17,21,38,0);
  transition: background 0.25s ease;
}
.igrid__item:hover::after{ background: rgba(17,21,38,0.18); }
.igrid__icon{
  position: absolute;
  top: 12px; right: 12px;
  width: 20px; height: 20px;
  z-index: 2;
  opacity: 0.85;
}

/* animations */
.reveal{
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible{ opacity: 1; transform: none; }
