/* ==========================================================================
   Forever Impressions — site stylesheet
   Metal castings of pet paw prints and baby hand & footprints.
   ========================================================================== */

/* --------------------------------------------------------------- 1. Tokens */
:root {
  /* Colour — drawn from the materials: pewter, bronze, oak, linen mount */
  --linen:       #F2F2EE;   /* page ground — cool oyster, not cream */
  --linen-deep:  #E7E7E1;   /* alternating band */
  --surface:     #FFFFFF;
  --ink:         #1B1D1A;   /* patinated near-black */
  --ink-soft:    #565A54;
  --ink-faint:   #8A8D85;
  --line:        #DEDED7;
  --line-soft:   #ECECE6;
  --bronze:      #7A5E36;   /* accent — interactive text and fills */
  --bronze-deep: #5C4626;
  --bronze-lit:  #A98A57;   /* accent on dark grounds */
  --bronze-tint: #EDE8DC;
  --pitch:       #1F211D;   /* footer / dark blocks */
  --focus:       #7A5E36;

  /* Type */
  --font-display: "Petrona", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --font-body:    "Karla", "Segoe UI", system-ui, -apple-system, Helvetica, Arial, sans-serif;

  /* Spacing scale */
  --s-1: 4px;   --s-2: 8px;   --s-3: 12px;  --s-4: 16px;
  --s-5: 24px;  --s-6: 32px;  --s-7: 48px;  --s-8: 64px;
  --s-9: 88px;  --s-10: 120px;

  /* Shape */
  --r-sm: 8px;  --r-md: 14px; --r-lg: 22px; --r-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(31, 29, 26, .05), 0 4px 14px rgba(31, 29, 26, .05);
  --shadow-md: 0 2px 6px rgba(31, 29, 26, .06), 0 18px 40px rgba(31, 29, 26, .09);

  --wrap: 1180px;
  --header-h: 76px;
}

/* ---------------------------------------------------------- 2. Base / reset */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--linen);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -0.012em;
  margin: 0 0 var(--s-4);
  text-wrap: balance;
}

h1 { font-size: clamp(2.4rem, 6vw, 4rem); }
h2 { font-size: clamp(1.9rem, 3.8vw, 2.9rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.55rem); }
h4 { font-size: 1.05rem; letter-spacing: 0; }

p  { margin: 0 0 var(--s-4); }
p:last-child { margin-bottom: 0; }

a { color: var(--bronze); text-decoration-color: rgba(122, 94, 54, .38); text-underline-offset: 3px; }
a:hover { text-decoration-color: currentColor; }

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

.lede {
  font-size: clamp(1.05rem, 1.5vw, 1.22rem);
  color: var(--ink-soft);
  max-width: 60ch;
}

.eyebrow {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--bronze);
  margin: 0 0 var(--s-3);
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 0 0 var(--r-sm) 0;
}
.skip-link:focus { left: 0; }

/* ------------------------------------------------------------- 3. Structure */
.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--s-5); }
.wrap--narrow { max-width: 760px; }

.section { padding-block: clamp(var(--s-8), 9vw, var(--s-10)); }
.section--tight { padding-block: clamp(var(--s-7), 6vw, var(--s-8)); }
.section--tinted { background: var(--linen-deep); }
.section--dark { background: var(--pitch); color: #E9E9E3; }
.section--dark h2, .section--dark h3 { color: #F7F7F2; }
.section--dark .lede, .section--dark p { color: #BFC0B9; }
.section--dark .eyebrow { color: var(--bronze-lit); }

.section-head { max-width: 660px; margin-bottom: var(--s-7); }
.section-head--center { margin-inline: auto; text-align: center; }

.grid { display: grid; gap: var(--s-5); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(var(--s-6), 6vw, var(--s-9));
  align-items: center;
}

/* ---------------------------------------------------------------- 4. Header */
.site-header {
  position: sticky; top: 0; z-index: 60;
  background: rgba(242, 242, 238, .88);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header__inner {
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: var(--s-5);
}

.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { width: 34px; height: 34px; border-radius: 9px; }
.brand__name {
  font-family: var(--font-display);
  font-size: 1.16rem; font-weight: 600; letter-spacing: -.02em; line-height: 1.05;
}
.brand__name span { display: block; font-family: var(--font-body); font-size: .62rem; font-weight: 600;
  letter-spacing: .2em; text-transform: uppercase; color: var(--ink-faint); }

.nav { display: flex; align-items: center; gap: var(--s-2); }
.nav a {
  color: var(--ink-soft); text-decoration: none; font-size: .93rem; font-weight: 500;
  padding: 9px 13px; border-radius: var(--r-pill); transition: background .15s, color .15s;
}
.nav a:hover { background: var(--line-soft); color: var(--ink); }
.nav a[aria-current="page"] { color: var(--ink); background: var(--bronze-tint); }

.header-actions { display: flex; align-items: center; gap: var(--s-3); }

.cart-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  background: none; border: 1px solid var(--line); border-radius: var(--r-pill);
  padding: 9px 15px; font: inherit; font-size: .9rem; font-weight: 500;
  color: var(--ink); cursor: pointer; transition: border-color .15s, background .15s;
}
.cart-btn:hover { border-color: var(--ink-faint); background: var(--surface); }
.cart-count {
  min-width: 20px; height: 20px; padding: 0 6px; border-radius: var(--r-pill);
  background: var(--bronze); color: #fff; font-size: .72rem; font-weight: 600;
  display: inline-grid; place-items: center;
}

.nav-toggle {
  display: none; background: none; border: 1px solid var(--line); border-radius: var(--r-sm);
  width: 42px; height: 42px; cursor: pointer; padding: 0; place-items: center; color: var(--ink);
}

/* ---------------------------------------------------------------- 5. Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  padding: 14px 26px; border-radius: var(--r-pill); border: 1px solid transparent;
  font: inherit; font-size: .96rem; font-weight: 600; line-height: 1;
  text-decoration: none; cursor: pointer; transition: transform .12s, background .15s, border-color .15s, color .15s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--bronze); color: #fff; }
.btn--primary:hover { background: var(--bronze-deep); color: #fff; }
.btn--outline { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn--outline:hover { background: var(--ink); color: var(--linen); }
.btn--quiet { background: var(--surface); border-color: var(--line); color: var(--ink); }
.btn--quiet:hover { border-color: var(--ink-faint); }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--bronze-tint); }
.btn--sm { padding: 10px 18px; font-size: .88rem; }
.btn--full { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s-3); }

/* ------------------------------------------------------------------- 6. Hero */
.hero { padding-block: clamp(var(--s-8), 8vw, var(--s-10)) clamp(var(--s-7), 7vw, var(--s-9)); }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(var(--s-6), 6vw, var(--s-8)); align-items: center; }
.hero h1 { margin-bottom: var(--s-5); }
.hero .btn-row { margin-top: var(--s-6); }

.hero__proof {
  display: flex; flex-wrap: wrap; align-items: center; gap: var(--s-5);
  margin-top: var(--s-7); padding-top: var(--s-5); border-top: 1px solid var(--line);
  font-size: .88rem; color: var(--ink-soft);
}
.hero__proof strong { color: var(--ink); font-weight: 600; }

.hero__art { position: relative; }
.hero__art img { border-radius: var(--r-lg); box-shadow: var(--shadow-md); width: 100%; }
.hero__art .float {
  position: absolute; width: 44%; border-radius: var(--r-lg);
  box-shadow: var(--shadow-md); border: 6px solid var(--linen);
}
.hero__art .float--a { right: -6%; bottom: -9%; }

/* ------------------------------------------------------------------ 7. Cards */
.card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--r-lg); padding: var(--s-5);
}

.product {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.product:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: transparent; }
.product__media { position: relative; aspect-ratio: 1 / 1; background: var(--linen-deep); }
.product__media img { width: 100%; height: 100%; object-fit: cover; }
.product__tag {
  position: absolute; top: 12px; left: 12px;
  background: rgba(255,255,255,.94); border-radius: var(--r-pill);
  padding: 5px 12px; font-size: .72rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink-soft);
}
.product__body { padding: var(--s-5); display: flex; flex-direction: column; gap: var(--s-2); flex: 1; }
.product__body h3 { margin: 0; font-size: 1.16rem; }
.product__desc { font-size: .92rem; color: var(--ink-soft); margin: 0; flex: 1; }
.product__foot { display: flex; align-items: center; justify-content: space-between; gap: var(--s-3); margin-top: var(--s-3); }
.price { font-family: var(--font-display); font-size: 1.22rem; font-weight: 600; }
.price small { font-family: var(--font-body); font-size: .78rem; font-weight: 500; color: var(--ink-faint); }

/* ------------------------------------------------------------------ 8. Steps */
.steps { counter-reset: step; }
.step { position: relative; padding-top: var(--s-5); border-top: 2px solid var(--ink); }
.step::before {
  counter-increment: step; content: "0" counter(step);
  font-family: var(--font-display); font-size: .95rem; font-weight: 600; color: var(--bronze);
  display: block; margin-bottom: var(--s-3);
}
.step h3 { font-size: 1.2rem; margin-bottom: var(--s-2); }
.step p { font-size: .95rem; color: var(--ink-soft); margin: 0; }
.section--dark .step { border-top-color: rgba(255,255,255,.28); }
.section--dark .step::before { color: var(--bronze-lit); }

/* --------------------------------------------------------------- 9. Gallery */
.filters { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-6); }
.chip {
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-soft);
  border-radius: var(--r-pill); padding: 9px 18px; font: inherit; font-size: .9rem; font-weight: 500;
  cursor: pointer; transition: all .15s;
}
.chip:hover { border-color: var(--ink-faint); color: var(--ink); }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--linen); }

.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-4); }
.gallery figure {
  margin: 0; border-radius: var(--r-md); overflow: hidden;
  background: var(--linen-deep); position: relative; aspect-ratio: 1 / 1;
}
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.gallery figure:hover img { transform: scale(1.04); }
.gallery figcaption {
  position: absolute; inset: auto 0 0 0; padding: var(--s-5) var(--s-4) var(--s-3);
  background: linear-gradient(transparent, rgba(31,29,26,.72));
  color: #fff; font-size: .85rem; font-weight: 500;
}
.gallery figure[hidden] { display: none; }

/* --------------------------------------------------------- 10. Testimonials */
.quote { display: flex; flex-direction: column; gap: var(--s-4); height: 100%; }
.stars { color: var(--bronze); letter-spacing: 2px; font-size: .95rem; }
.quote blockquote { margin: 0; font-size: 1.02rem; line-height: 1.6; flex: 1; }
.quote cite { font-style: normal; font-size: .87rem; color: var(--ink-faint); }
.quote cite strong { display: block; color: var(--ink); font-weight: 600; font-style: normal; }

/* ----------------------------------------------------------- 11. Price table */
.tier {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg);
  padding: var(--s-6); display: flex; flex-direction: column; gap: var(--s-4);
}
.tier--featured { border-color: var(--bronze); box-shadow: var(--shadow-md); position: relative; }
.tier--featured::after {
  content: "Most popular"; position: absolute; top: -13px; left: var(--s-6);
  background: var(--bronze); color: #fff; font-size: .72rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; padding: 5px 14px; border-radius: var(--r-pill);
}
.tier__price { font-family: var(--font-display); font-size: 2.4rem; font-weight: 600; line-height: 1; }
.tier__price small { font-family: var(--font-body); font-size: .85rem; font-weight: 500; color: var(--ink-faint); }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-3); flex: 1; }
.ticks li { display: grid; grid-template-columns: 20px 1fr; gap: 10px; font-size: .94rem; color: var(--ink-soft); }
.ticks li::before { content: "✓"; color: var(--bronze); font-weight: 700; }

table.rates { width: 100%; border-collapse: collapse; font-size: .95rem; }
table.rates th, table.rates td { text-align: left; padding: var(--s-3) var(--s-4); border-bottom: 1px solid var(--line); }
table.rates th { font-weight: 600; font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); }
table.rates td:last-child, table.rates th:last-child { text-align: right; white-space: nowrap; }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ------------------------------------------------------------------ 12. FAQ */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; padding: var(--s-5) var(--s-6) var(--s-5) 0;
  font-family: var(--font-display); font-size: 1.1rem; font-weight: 500;
  position: relative; transition: color .15s;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--bronze); }
.faq summary::after {
  content: "+"; position: absolute; right: 0; top: 50%; transform: translateY(-50%);
  font-size: 1.5rem; font-family: var(--font-body); font-weight: 300; color: var(--bronze); line-height: 1;
}
.faq details[open] summary::after { content: "–"; }
.faq details > div { padding: 0 var(--s-7) var(--s-5) 0; color: var(--ink-soft); font-size: .97rem; }

/* ---------------------------------------------------------------- 13. Forms */
.field { display: grid; gap: 7px; margin-bottom: var(--s-4); }
.field label { font-size: .88rem; font-weight: 600; }
.field .hint { font-size: .82rem; color: var(--ink-faint); }
.field input, .field select, .field textarea {
  font: inherit; font-size: .97rem; color: var(--ink);
  padding: 13px 15px; border: 1px solid var(--line); border-radius: var(--r-md);
  background: var(--surface); width: 100%; transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--bronze); box-shadow: 0 0 0 3px rgba(122,94,54,.16);
}
.field textarea { min-height: 130px; resize: vertical; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-4); }

.form-note { font-size: .85rem; color: var(--ink-faint); margin-top: var(--s-3); }
.form-status {
  margin-top: var(--s-4); padding: var(--s-4); border-radius: var(--r-md);
  background: var(--bronze-tint); color: var(--bronze-deep); font-size: .93rem; font-weight: 500;
}
.form-status[hidden] { display: none; }

/* --------------------------------------------------------------- 14. Footer */
.site-footer { background: var(--pitch); color: #BFC0B9; padding-block: var(--s-8) var(--s-6); font-size: .93rem; }
.site-footer h4 { color: #F7F7F2; font-family: var(--font-body); font-size: .78rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; margin-bottom: var(--s-4); }
.site-footer a { color: #BFC0B9; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: var(--s-6); }
.footer-brand .brand { color: #F7F7F2; margin-bottom: var(--s-4); }
.footer-brand .brand__name span { color: #85887F; }
.footer-bottom {
  margin-top: var(--s-7); padding-top: var(--s-5); border-top: 1px solid rgba(255,255,255,.12);
  display: flex; flex-wrap: wrap; gap: var(--s-4); justify-content: space-between;
  font-size: .84rem; color: #85887F;
}

/* ------------------------------------------------------------- 15. Utilities */
.page-head { padding-block: var(--s-8) var(--s-6); }
.page-head .lede { margin-top: var(--s-4); }

.media-frame { border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-md); }
.media-frame img { width: 100%; }

.badge-row { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.badge {
  border: 1px solid var(--line); border-radius: var(--r-pill); padding: 6px 14px;
  font-size: .8rem; font-weight: 500; color: var(--ink-soft); background: var(--surface);
}

.callout {
  background: var(--bronze-tint); border-radius: var(--r-lg); padding: var(--s-6);
  border: 1px solid rgba(122,94,54,.20);
}

.center { text-align: center; }
.mt-6 { margin-top: var(--s-6); }
.mt-7 { margin-top: var(--s-7); }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ------------------------------------------------------------- 16. Cart tray */
.tray {
  position: fixed; inset: 0 0 0 auto; width: min(400px, 100%); background: var(--surface);
  box-shadow: -20px 0 60px rgba(31,29,26,.18); z-index: 90;
  transform: translateX(100%); visibility: hidden;
  transition: transform .28s ease, visibility 0s linear .28s;
  display: flex; flex-direction: column;
}
.tray[data-open="true"] {
  transform: none; visibility: visible;
  transition: transform .28s ease, visibility 0s;
}
.tray__head { display: flex; align-items: center; justify-content: space-between;
  padding: var(--s-5); border-bottom: 1px solid var(--line); }
.tray__head h3 { margin: 0; font-size: 1.2rem; }
.tray__body { padding: var(--s-5); overflow-y: auto; flex: 1; }
.tray__foot { padding: var(--s-5); border-top: 1px solid var(--line); }
.tray-line { display: flex; justify-content: space-between; gap: var(--s-3); padding-block: var(--s-3);
  border-bottom: 1px solid var(--line-soft); font-size: .93rem; }
.tray-line button { background: none; border: 0; color: var(--ink-faint); cursor: pointer; font: inherit; font-size: .8rem; }
.tray-line button:hover { color: var(--bronze); }
.tray-total { display: flex; justify-content: space-between; font-weight: 600; margin-bottom: var(--s-4); }
.scrim {
  position: fixed; inset: 0; background: rgba(31,29,26,.4); z-index: 80; opacity: 0; pointer-events: none;
  transition: opacity .28s;
}
.scrim[data-open="true"] { opacity: 1; pointer-events: auto; }

/* ------------------------------------------------------------ 17. Responsive */
@media (max-width: 1000px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  :root { --header-h: 66px; }

  .nav-toggle { display: grid; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    background: var(--linen); border-bottom: 1px solid var(--line);
    flex-direction: column; align-items: stretch; padding: var(--s-4);
    gap: 2px; display: none; box-shadow: var(--shadow-md);
  }
  .nav[data-open="true"] { display: flex; }
  .nav a { padding: 13px 16px; border-radius: var(--r-md); font-size: 1rem; }

  .hero__grid, .split { grid-template-columns: 1fr; }
  .hero__art { order: -1; }
  .hero__art .float { display: none; }

  .grid--2, .grid--3 { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .field-row { grid-template-columns: 1fr; }
  .tier--featured::after { left: 50%; transform: translateX(-50%); }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .grid--4 { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: repeat(2, 1fr); gap: var(--s-3); }
  .footer-grid { grid-template-columns: 1fr; }
  .brand__name span { display: none; }
  .cart-btn span.label { display: none; }
  .btn { width: 100%; }
  .btn-row { flex-direction: column; }
  .hero__proof { gap: var(--s-3); flex-direction: column; align-items: flex-start; }
}

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

@media print {
  .site-header, .site-footer, .tray, .scrim, .btn { display: none !important; }
}
