/* ===========================================================
   House Of ARBS — tokens
=========================================================== */
:root{
  --bone:        #F4EFE5;
  --stone:       #E7DECB;
  --stone-line:  #D3C6A8;
  --espresso:    #241E17;
  --espresso-90: #2E271E;
  --taupe:       #6E6455;
  --taupe-light: #C9BFAE;
  --copper:      #BE6F31;
  --copper-light:#D98A4C;
  /* Darker variants used only where text sits directly on/as the color —
     the base --copper fails WCAG AA (4.5:1) for text at 3.33:1, but reads
     fine as icon strokes, underlines, dots and focus rings (non-text
     contrast requirement is only 3:1), so those keep using --copper. */
  --copper-deep: #8D5324;
  --copper-btn:  #955727;
  --copper-btn-hover: #7D4920;
  --cream:       #F4EFE5;

  --font-display: 'Clash Display', 'Satoshi', sans-serif;
  --font-serif:   'Playfair Display', 'Clash Display', serif;
  --font-body:    'Satoshi', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono:    'IBM Plex Mono', 'SFMono-Regular', monospace;

  --container: 1180px;
  --gutter: clamp(20px, 5vw, 64px);

  --ease: cubic-bezier(.22,.61,.36,1);
}

/* Content stays legible-width, but a fixed 1180px column on a very wide
   monitor leaves the whole page stranded on the left with a large dead
   void on the right — widen the column in two steps as the viewport grows. */
@media (min-width: 1600px){
  :root{ --container: 1320px; }
}
@media (min-width: 2000px){
  :root{ --container: 1460px; }
  .hero__copy{ max-width: 760px; }
}

*, *::before, *::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }

/* Art-directed line breaks in headlines are tuned for wider viewports —
   below that they can strand a single word on its own line, so they're
   dropped in favour of natural wrapping. */
@media (max-width: 640px){
  .br-desktop{ display: none; }
}
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *, *::before, *::after{ animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

body{
  margin: 0;
  background: var(--bone);
  color: var(--espresso);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img, svg{ display:block; max-width: 100%; }
a{ color: inherit; text-decoration: none; }
ul{ margin:0; padding:0; }

.container{
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip-link{
  position:absolute; left:-9999px; top:0; z-index:1000;
  background: var(--espresso); color:var(--cream);
  padding: 12px 18px; font-family: var(--font-mono); font-size: .8rem;
}
.skip-link:focus{ left: 12px; top: 12px; }

:focus-visible{
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

/* ===========================================================
   Type
=========================================================== */
.eyebrow{
  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--copper-deep);
  margin: 0 0 14px;
}
/* For eyebrows sitting on dark backgrounds (hero photo, contact card). */
.eyebrow--light{ color: var(--copper-light); }

.section__title{
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.7rem, 3.4vw, 2.6rem);
  line-height: 1.12;
  letter-spacing: -0.01em;
  margin: 0 0 18px;
}

.section__head{
  max-width: 640px;
  margin-bottom: clamp(40px, 6vw, 72px);
}

/* ===========================================================
   Reveal on scroll
=========================================================== */
[data-reveal]{
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
[data-reveal].is-visible{
  opacity: 1;
  transform: translateY(0);
}
@media (prefers-reduced-motion: reduce){
  [data-reveal]{ opacity:1; transform:none; }
}

/* ===========================================================
   Buttons
=========================================================== */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: .8rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 15px 26px;
  border-radius: 2px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background .25s var(--ease), color .25s var(--ease), border-color .25s var(--ease), transform .15s var(--ease);
}
.btn:active{ transform: scale(.96); }
.btn:disabled{ opacity: .6; cursor: default; transform: none; }
.btn--primary{
  background: var(--copper-btn);
  color: var(--cream);
}
.btn--primary:hover{ background: var(--copper-btn-hover); transform: translateY(-1px); }

.btn--ghost{
  background: transparent;
  color: var(--espresso);
  border-color: var(--espresso);
}
.btn--ghost:hover{ background: var(--espresso); color: var(--cream); }

.btn--ghost-light{
  background: transparent;
  color: var(--cream);
  border-color: rgba(244,239,229,.6);
}
.btn--ghost-light:hover{ background: var(--cream); color: var(--espresso); border-color: var(--cream); }

.btn--block{ width: 100%; }

/* ===========================================================
   Nav
=========================================================== */
.nav{
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background .3s var(--ease), border-color .3s var(--ease);
  animation: nav-in .7s var(--ease) both;
}
@keyframes nav-in{
  from{ opacity: 0; transform: translateY(-14px); }
  to{ opacity: 1; transform: translateY(0); }
}
.nav.is-scrolled{
  background: rgba(244,239,229,.86);
  backdrop-filter: blur(10px);
  border-bottom-color: var(--stone-line);
}
.nav__inner{
  max-width: var(--container);
  margin-inline: auto;
  padding: 16px var(--gutter);
  display: flex;
  align-items: center;
  gap: 28px;
}
.nav__logo{
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: .02em;
  margin-right: auto;
  color: var(--cream);
  text-shadow: 0 1px 14px rgba(20,16,12,.4);
  transition: color .3s var(--ease), text-shadow .3s var(--ease);
}
.nav.is-scrolled .nav__logo{ color: var(--espresso); text-shadow: none; }
.nav__logo .lapel-mark{ transition: transform .4s var(--ease); }
.nav__logo:hover .lapel-mark{ transform: rotate(-8deg) scale(1.08); }

.lapel-mark path,
.lapel-mark line{
  fill: none;
  stroke: currentColor;
  stroke-width: 9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.lapel-mark--nav{ width: 22px; height: 22px; color: currentColor; }
.lapel-mark--footer{ width: 20px; height: 20px; color: var(--cream); }

.nav__links{
  display: flex;
  gap: 26px;
  font-family: var(--font-mono);
  font-size: .78rem;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--cream);
  text-shadow: 0 1px 14px rgba(20,16,12,.4);
  transition: color .3s var(--ease), text-shadow .3s var(--ease);
}
.nav.is-scrolled .nav__links{ color: var(--espresso); text-shadow: none; }
.nav__links a{
  position: relative;
  padding-bottom: 4px;
}
.nav__links a::after{
  content:"";
  position:absolute; left:0; right:0; bottom:0;
  height: 1px; background: var(--copper);
  transform: scaleX(0); transform-origin: left;
  transition: transform .25s var(--ease);
}
.nav__links a:hover::after{ transform: scaleX(1); }

.nav__toggle{
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 44px; height: 44px;
  margin-right: -10px;
  background: none; border: none; cursor: pointer;
  padding: 0;
}
.nav__toggle span{
  display:block; height: 1.5px; width: 22px;
  background: var(--cream);
  box-shadow: 0 1px 8px rgba(20,16,12,.4);
  transition: background .3s var(--ease), transform .35s var(--ease), opacity .35s var(--ease);
}
.nav.is-scrolled .nav__toggle span{ background: var(--espresso); box-shadow: none; }
/* Morph the three bars into an X when the mobile menu is open. */
.nav.is-open .nav__toggle span:nth-child(1){ transform: translateY(6.5px) rotate(45deg); }
.nav.is-open .nav__toggle span:nth-child(2){ opacity: 0; }
.nav.is-open .nav__toggle span:nth-child(3){ transform: translateY(-6.5px) rotate(-45deg); }

.nav__mobile{
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  padding-inline: var(--gutter);
  font-family: var(--font-mono);
  font-size: .85rem;
  text-transform: uppercase;
  letter-spacing: .06em;
  background: var(--bone);
  color: var(--espresso);
  transition: max-height .4s var(--ease), opacity .3s var(--ease), padding-block .4s var(--ease);
}
.nav__mobile a{ padding: 12px 0; border-bottom: 1px dashed var(--stone-line); }
.nav__mobile a:last-child{ border-bottom: none; }
.nav.is-open .nav__mobile{
  max-height: 320px;
  opacity: 1;
  padding-block: 8px 20px;
  border-top: 1px solid var(--stone-line);
}

@media (max-width: 860px){
  .nav__links{ display: none; }
  .nav__toggle{ display: flex; }
}

/* ===========================================================
   Hero
=========================================================== */
.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  overflow: hidden;
  padding-block: 60px;
  color: var(--cream);
}
.hero__bg{
  position: absolute;
  inset: 0;
  z-index: 0;
}
.hero__bg img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 66% 32%;
  transform: scale(1.07);
  animation: hero-zoom 9s var(--ease) forwards;
}
@keyframes hero-zoom{
  from{ transform: scale(1.07); }
  to{ transform: scale(1); }
}
.hero__scrim{
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(180deg, rgba(16,13,10,.55) 0%, rgba(16,13,10,0) 16%, rgba(16,13,10,0) 72%, rgba(16,13,10,.6) 100%),
    linear-gradient(90deg, rgba(16,13,10,.88) 0%, rgba(16,13,10,.62) 34%, rgba(16,13,10,.18) 62%, rgba(16,13,10,.05) 100%);
}
.hero__inner{
  position: relative;
  z-index: 2;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
  width: 100%;
}
.hero__copy{ max-width: 640px; }
.hero__copy > *{
  opacity: 0;
  animation: hero-in .8s var(--ease) both;
}
.hero__copy .eyebrow{ animation-delay: .2s; }
.hero__copy .hero__headline{ animation-delay: .34s; }
.hero__copy .hero__sub{ animation-delay: .5s; }
.hero__copy .hero__actions{ animation-delay: .64s; }
@keyframes hero-in{
  from{ opacity: 0; transform: translateY(18px); }
  to{ opacity: 1; transform: translateY(0); }
}
.hero__headline{
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(2.6rem, 5.8vw, 4.6rem);
  line-height: 1.08;
  letter-spacing: -0.005em;
  color: var(--cream);
  margin: 0 0 22px;
}
.hero__sub{
  font-size: clamp(1rem, 1.4vw, 1.15rem);
  color: var(--taupe-light);
  max-width: 46ch;
  margin: 0 0 34px;
}
.hero__actions{ display: flex; flex-wrap: wrap; gap: 14px; }

.hero__scroll{
  position: absolute;
  z-index: 2;
  bottom: 32px;
  left: var(--gutter);
  font-family: var(--font-mono);
  font-size: .68rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--taupe-light);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  opacity: 0;
  animation: hero-in .8s var(--ease) .9s both;
}
.hero__scroll::after{
  content:"";
  width: 1px; height: 26px;
  background: var(--taupe-light);
  animation: scrollLine 2.2s var(--ease) infinite;
}
@keyframes scrollLine{
  0%{ transform: scaleY(0); transform-origin: top; opacity: 0; }
  40%{ transform: scaleY(1); transform-origin: top; opacity: 1; }
  60%{ transform: scaleY(1); transform-origin: bottom; opacity: 1; }
  100%{ transform: scaleY(0); transform-origin: bottom; opacity: 0; }
}
@media (prefers-reduced-motion: reduce){
  .hero__scroll::after{ animation: none; }
}
@media (max-width: 640px){
  .hero__scroll{ display: none; }

  /* Header: slightly shorter on phones. The 44px hamburger target itself
     is untouched — only the surrounding breathing room shrinks. */
  .nav__inner{ padding-block: 11px; }

  /* Hero: stop vertically centering the copy block. Centering a now-shorter
     block inside a full-viewport hero was what created the oversized gap
     above the eyebrow — anchor content near the top instead, with the
     leftover space falling below the CTAs rather than split evenly. */
  .hero{
    align-items: flex-start;
    padding-block: 0;
  }
  .hero__bg img{ object-position: 58% 30%; }
  .hero__scrim{
    background: linear-gradient(180deg,
      rgba(12,10,8,.86) 0%,
      rgba(12,10,8,.74) 38%,
      rgba(12,10,8,.4) 62%,
      rgba(12,10,8,.12) 100%);
  }
  .hero__inner{
    padding-inline: 24px;
    padding-top: 104px;
    padding-bottom: max(32px, env(safe-area-inset-bottom, 0px));
  }
  .hero__copy{ max-width: 420px; }
  .hero__copy .eyebrow{
    font-size: .64rem;
    letter-spacing: .13em;
    margin-bottom: 10px;
  }
  .hero__headline{
    font-size: clamp(2rem, 8.6vw, 2.4rem);
    line-height: 1.07;
    margin-bottom: 14px;
  }
  .hero__sub{
    font-size: .92rem;
    line-height: 1.5;
    max-width: 34ch;
    margin-bottom: 26px;
  }
  .hero__actions{
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
  .hero__actions .btn{
    width: 87%;
    max-width: 300px;
    padding: 13px 20px;
    font-size: .72rem;
  }
}

/* ===========================================================
   Services
=========================================================== */
.services{ padding-block: clamp(70px, 10vw, 130px); scroll-margin-top: 84px; }

.services__grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--stone-line);
  border: 1px solid var(--stone-line);
}
.service-card{
  position: relative;
  background: var(--bone);
  /* Explicit list (rather than relying on the generic [data-reveal] rule)
     because same-specificity + later-in-source would otherwise let this
     silently replace the reveal's opacity/transform transition. */
  transition: opacity .6s var(--ease), background .3s var(--ease), transform .4s var(--ease), box-shadow .35s var(--ease);
}
.service-card:hover,
.service-card:active{
  background: var(--stone);
  transform: translateY(-6px);
  box-shadow: 0 28px 44px -30px rgba(36, 30, 23, .45);
  z-index: 2;
}
.services__grid .service-card:nth-child(2){ transition-delay: .09s; }
.services__grid .service-card:nth-child(3){ transition-delay: .18s; }

.service-card__media{
  aspect-ratio: 11 / 10;
  overflow: hidden;
}
.service-card__media img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s var(--ease);
}
.service-card:hover .service-card__media img,
.service-card:active .service-card__media img{ transform: scale(1.045); }

.service-card__body{
  padding: clamp(28px, 3vw, 40px);
}

.service-card__icon{
  width: 56px; height: 56px;
  margin-bottom: 26px;
}
.service-card__icon path,
.service-card__icon line,
.service-card__icon circle{
  fill: none;
  stroke: var(--copper);
  stroke-width: 3.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-card__tag{
  font-family: var(--font-mono);
  font-size: .72rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--taupe);
  margin: 0 0 10px;
}
.service-card__title{
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.25rem;
  margin: 0 0 12px;
}
.service-card__desc{
  color: var(--taupe);
  font-size: .95rem;
  margin: 0;
}

@media (max-width: 780px){
  .services__grid{ grid-template-columns: 1fr; }
}

/* ===========================================================
   Clients
=========================================================== */
.clients{
  padding-block: clamp(60px, 9vw, 110px);
  background: var(--stone);
  border-block: 1px solid var(--stone-line);
  scroll-margin-top: 84px;
}
.marquee{
  position: relative;
  overflow: hidden;
}
.marquee__track{
  display: flex;
  width: max-content;
  animation: marquee-scroll 32s linear infinite;
}
.marquee:hover .marquee__track{ animation-play-state: paused; }

@keyframes marquee-scroll{
  from{ transform: translateX(0); }
  to{ transform: translateX(-50%); }
}

.marquee__group{
  display: flex;
  align-items: center;
  flex-shrink: 0;
}
.marquee__logo{
  display: flex;
  align-items: center;
  justify-content: center;
  width: clamp(160px, 18vw, 220px);
  height: 116px;
  padding-inline: clamp(20px, 3vw, 40px);
  flex-shrink: 0;
}
.marquee__logo img{
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  transition: transform .3s var(--ease);
}
.marquee__logo:hover img,
.marquee__logo:active img{ transform: scale(1.08); }

.marquee__fade{
  position: absolute;
  inset-block: 0;
  width: clamp(40px, 8vw, 120px);
  z-index: 2;
  pointer-events: none;
}
.marquee__fade--left{
  left: 0;
  background: linear-gradient(to right, var(--stone), transparent);
}
.marquee__fade--right{
  right: 0;
  background: linear-gradient(to left, var(--stone), transparent);
}

@media (prefers-reduced-motion: reduce){
  .marquee__track{ animation: none; justify-content: center; }
  .marquee__group[aria-hidden="true"]{ display: none; }
}

/* ===========================================================
   About + Contact
=========================================================== */
.about{ padding-block: clamp(56px, 8vw, 96px); scroll-margin-top: 84px; }
.about__grid{
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
}
.about__copy p{
  color: var(--taupe);
  font-size: 1.02rem;
  max-width: 46ch;
}
.about__copy p:last-of-type{
  color: var(--espresso);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.1rem;
}
.about__portrait{
  max-width: 380px;
  margin-inline: auto 0;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  border-radius: 2px;
  transition-delay: .12s;
}
.about__portrait img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 15%;
  transition: transform .6s var(--ease);
}
.about__portrait:hover img,
.about__portrait:active img{ transform: scale(1.05); }

.contact{
  padding-block: clamp(56px, 8vw, 96px);
  background: var(--stone);
  border-block: 1px solid var(--stone-line);
  scroll-margin-top: 84px;
}
.contact__card{
  max-width: 600px;
  margin-inline: auto;
  background: var(--espresso);
  color: var(--cream);
  padding: clamp(32px, 5vw, 44px);
  border-radius: 2px;
}
.contact__title{
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.6rem;
  margin: 0 0 10px;
}
.contact__sub{
  color: #C9BFAE;
  margin: 0 0 30px;
  font-size: .95rem;
}

.lead-form{ display: flex; flex-direction: column; gap: 18px; }
.lead-form__field{ display: flex; flex-direction: column; gap: 8px; }
.lead-form__field label{
  font-family: var(--font-mono);
  font-size: .7rem;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #C9BFAE;
}
.lead-form__field input,
.lead-form__field textarea{
  background: var(--espresso-90);
  border: 1px solid #4A4030;
  color: var(--cream);
  font-family: var(--font-body);
  /* iOS Safari zooms the page in on focus for any field under 16px —
     16px here is a floor, not a design choice. */
  font-size: max(1rem, .98rem);
  padding: 13px 14px;
  border-radius: 2px;
  resize: vertical;
  transition: border-color .25s var(--ease), box-shadow .25s var(--ease);
}
.lead-form__field input:focus,
.lead-form__field textarea:focus{
  outline: none;
  border-color: var(--copper);
  box-shadow: 0 0 0 3px rgba(190, 111, 49, .18);
}
.lead-form__field input::placeholder,
.lead-form__field textarea::placeholder{ color: #8A7E68; }

.lead-form .btn{ margin-top: 6px; }
.lead-form__status{
  margin: 0;
  font-family: var(--font-mono);
  font-size: .8rem;
  min-height: 1.2em;
}
.lead-form__status[data-state="success"]{ color: #B7D3A0; }
.lead-form__status[data-state="error"]{ color: #E0A08C; }

@media (max-width: 900px){
  .about__grid{ grid-template-columns: 1fr; }
  .about__portrait{ max-width: 340px; margin-inline: auto; aspect-ratio: 3 / 2; }
}

/* ===========================================================
   Footer
=========================================================== */
.footer{
  background: var(--espresso);
  color: var(--cream);
}
.footer__top{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding-block: 34px;
}
.footer__logo{
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: .95rem;
}
.footer__contact{
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 22px;
  font-family: var(--font-mono);
  font-size: .78rem;
  letter-spacing: .02em;
  color: var(--taupe-light);
}
.footer__contact a{ transition: color .2s var(--ease); }
.footer__contact a:hover{ color: var(--copper-light); }

.footer__bottom{
  padding-block: 18px;
  border-top: 1px solid var(--espresso-90);
}
.footer__meta{
  margin: 0;
  font-family: var(--font-mono);
  font-size: .75rem;
  color: #A69C89;
}
