/* ============================================================
   OWNEST — 02. BASE
   Reset, document defaults, typography, buttons, utilities.
   Depends on: tokens.css
============================================================ */

/* ------------------------------------------------ Reset ---- */
*{ box-sizing:border-box; }
html{ scroll-behavior:smooth; scroll-padding-top:calc(var(--header-h) + 16px); }

body{
  margin:0;
  font-family:var(--font-body);
  font-size:16px;
  color:var(--ink);
  background:var(--cream);
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
}

img{ max-width:100%; display:block; }
a{ color:inherit; text-decoration:none; }
ul{ list-style:none; margin:0; padding:0; }
button{ font-family:inherit; cursor:pointer; }
figure{ margin:0; }

:focus-visible{
  outline:2px solid var(--taupe-dark);
  outline-offset:3px;
  border-radius:var(--radius-sm);
}

::selection{ background:var(--taupe-pale); color:var(--ink); }

/* ------------------------------------------- Typography ---- */
h1,h2,h3,h4{
  font-family:var(--font-display);
  font-weight:500;
  line-height:1.15;
  margin:0;
  color:var(--ink);
}
h4{ font-family:var(--font-body); font-weight:600; }

p{ margin:0; }

.eyebrow{
  display:inline-block;
  font-family:var(--font-body);
  font-size:13px;
  font-weight:600;
  color:var(--taupe-dark);
  letter-spacing:.02em;
}

.lede{
  font-size:17px;
  line-height:1.75;
  color:var(--ink-soft);
}

/* ----------------------------------------------- Layout ---- */
.wrap{
  max-width:var(--container);
  margin:0 auto;
  padding:0 var(--gutter);
}

section{ padding:88px 0; }

.section-head{ max-width:640px; margin-bottom:48px; }
.section-head h2{ font-size:clamp(26px,3vw,36px); margin-top:10px; }
.section-head p{ margin-top:14px; color:var(--ink-soft); font-size:16px; line-height:1.7; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }

.section-white{ background:var(--white); }
.section-cream{ background:var(--white); } /* legacy alias */
.section-deep{ background:var(--cream-deep); }

.divider{ height:1px; background:var(--line); border:0; margin:0; }

/* ---------------------------------------------- Buttons ---- */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  padding:13px 26px;
  border-radius:var(--radius-md);
  font-size:15px;
  font-weight:600;
  line-height:1;
  border:1px solid transparent;
  transition:transform var(--t-fast) var(--ease),
             box-shadow var(--t-fast) var(--ease),
             background var(--t-fast) var(--ease),
             color var(--t-fast) var(--ease);
}
.btn svg{ width:17px; height:17px; flex-shrink:0; }

.btn-primary{ background:var(--ink); color:var(--cream); }
.btn-primary:hover{ background:var(--taupe-dark); box-shadow:var(--shadow-card); transform:translateY(-1px); }

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

.btn-light{ background:var(--cream); color:var(--ink); }
.btn-light:hover{ background:var(--white); transform:translateY(-1px); }

.btn-outline-light{ background:transparent; color:var(--cream); border-color:rgba(216,204,184,.5); }
.btn-outline-light:hover{ background:var(--cream); color:var(--ink); border-color:var(--cream); }

.btn-sm{ padding:10px 18px; font-size:13.5px; }
.btn-lg{ padding:16px 32px; font-size:16px; }
.btn-block{ width:100%; }

/* --------------------------------------------- Utilities --- */
.stack-8  > * + *{ margin-top:8px; }
.stack-14 > * + *{ margin-top:14px; }
.stack-20 > * + *{ margin-top:20px; }

.text-soft{ color:var(--ink-soft); }
.text-accent{ color:var(--taupe-dark); }
.text-center{ text-align:center; }
.mt-0{ margin-top:0 !important; }
.pt-0{ padding-top:0 !important; }
.pb-0{ padding-bottom:0 !important; }

/* swap copy between desktop and phone without duplicating markup */
.m-only{ display:none; }
@media (max-width: 760px){
  .d-only{ display:none; }
  .m-only{ display:inline; }
}

.sr-only{
  position:absolute; width:1px; height:1px;
  padding:0; margin:-1px; overflow:hidden;
  clip:rect(0 0 0 0); white-space:nowrap; border:0;
}

.skip-link{
  position:absolute; left:-9999px; top:0; z-index:100;
  background:var(--ink); color:var(--cream);
  padding:12px 20px; border-radius:0 0 var(--radius-md) 0;
  font-size:14px; font-weight:600;
}
.skip-link:focus{ left:0; }

/* ------------------------------------------------ Motion --- */
@media (prefers-reduced-motion: no-preference){
  .reveal{
    opacity:0;
    transform:translateY(14px);
    transition:opacity .7s var(--ease), transform .7s var(--ease);
  }
  .reveal.is-visible{ opacity:1; transform:none; }
  .reveal[data-delay="1"]{ transition-delay:.08s; }
  .reveal[data-delay="2"]{ transition-delay:.16s; }
  .reveal[data-delay="3"]{ transition-delay:.24s; }
}
@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  *{ animation-duration:.01ms !important; transition-duration:.01ms !important; }
}

/* ---------------------------------------------- Responsive - */
@media (max-width: 760px){
  :root{ --gutter:20px; }
  section{ padding:60px 0; }
  .section-head{ margin-bottom:34px; }
}
