:root {
  --bg: #F8F6F2;
  --page-bg: #EAE5DC;
  --ink: #1D1D1D;
  --muted: #6E6A65;
  --accent: #6E3A36;
  --hairline: #E7E2DA;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Inter", -apple-system, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--page-bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* The designed page sits at a fixed width with a soft lift off the
   surrounding background — everything beyond it is just background. */
.page {
  max-width: 1180px;
  margin: 0 auto;
  background: var(--bg);
  box-shadow: 0 40px 90px -30px rgba(29, 29, 29, 0.16), 0 2px 10px rgba(29, 29, 29, 0.04);
  position: relative;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

.narrow { max-width: 760px; margin-left: auto; margin-right: auto; }

/* Hairlines structure the page — no boxes, no shadows */
hr.rule {
  border: none;
  border-top: 1px solid var(--hairline);
  margin: 0;
}

h1, h2, h3 { font-family: var(--serif); font-weight: 500; margin: 0; }

.label {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 20px;
}

.body { color: var(--muted); max-width: 62ch; text-wrap: pretty; }

a { color: var(--accent); }

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

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

.hero { position: relative; overflow: hidden; }

.hero-photo {
  position: absolute;
  top: 0;
  right: 0;
  width: 100%;
  height: calc(100% - 1px);
  background: url("assets/hero.jpg?v=2") center 38% / cover no-repeat;
}

/* Top edge softens into the background; bottom edge is left as a hard line. */
.hero-photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, var(--bg) 0%, rgba(248, 246, 242, 0) 16%);
}

.hero-inner {
  position: relative;
  padding-top: 128px;
  padding-bottom: 120px;
}

.hero-copy { max-width: 56%; }

.wordmark {
  font-size: clamp(64px, 9vw, 112px);
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1.05;
  margin-bottom: 36px;
}

.tagline {
  font-family: var(--serif);
  font-size: clamp(24px, 2.6vw, 31px);
  line-height: 1.45;
  margin: 0 0 28px;
}

.support {
  color: var(--muted);
  max-width: 40ch;
  margin: 0;
}

/* ---------- Philosophy ---------- */

.philosophy .container:first-child { padding-top: 96px; padding-bottom: 96px; }

.philosophy h2 { max-width: 920px; text-wrap: pretty; }

.philosophy .body { max-width: 85ch; }

.philosophy h2,
.about h2,
.contact h2 {
  font-size: clamp(30px, 3.4vw, 40px);
  line-height: 1.3;
  margin-bottom: 28px;
}

.philosophy .body { margin: 0 0 22px; }
.philosophy .body:last-of-type { margin-bottom: 0; }

/* ---------- Products ---------- */

.products .container:first-child { padding-top: 96px; }

.cards {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
  padding: 0;
  margin: 0;
}

.card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--hairline);
  border-radius: 10px;
  padding: 40px 36px 34px;
  background: transparent;
  transition: background-color 0.35s ease;
}

.card:hover { background-color: rgba(110, 58, 54, 0.03); }

/* Exactly one tiny oxblood accent rule at the top of each card */
.tick {
  display: block;
  width: 28px;
  height: 2px;
  background: var(--accent);
  margin: 0 0 26px;
}

.card h3 { font-size: 32px; font-weight: 500; margin-bottom: 8px; }

.descriptor {
  color: var(--ink);
  font-weight: 500;
  font-size: 17px;
  line-height: 1.5;
  min-height: 3em;
  margin: 0 0 24px;
}

.card hr.rule { margin-bottom: 24px; }

.value {
  font-family: var(--serif);
  font-style: italic;
  font-size: 16.5px;
  line-height: 1.65;
  color: var(--ink);
  margin: 0 0 28px;
}

.status {
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--accent);
  margin: auto 0 0; /* bottom-align across equal-height cards */
}

.more {
  text-align: center;
  padding: 64px 0 96px;
}

.vtick {
  display: block;
  width: 2px;
  height: 22px;
  background: var(--accent);
  margin: 0 auto 18px;
}

.more p { margin: 0; color: var(--ink); font-size: 16px; }

/* ---------- About ---------- */

.about {
  position: relative;
  overflow: hidden;
}

.about-rule {
  position: absolute;
  left: 0;
  right: 0;
  border: none;
  border-top: 1px solid var(--hairline);
  margin: 0;
}

.about-rule-top { top: 44px; }
.about-rule-bottom { bottom: 0; }

.about-photo {
  position: absolute;
  top: 44px;
  right: 0;
  width: 42%;
  height: calc(100% - 44px);
  background: url("assets/about.jpg") 42% 88% / cover no-repeat;
}

.about-inner { padding-top: 96px; padding-bottom: 110px; }

.about-copy { max-width: 52%; }

.about .body { margin: 0 0 22px; }
.about .body:last-of-type { margin-bottom: 0; }

/* ---------- Contact ---------- */

.contact { background: var(--bg); }

.contact .narrow {
  text-align: center;
  padding-top: 100px;
  padding-bottom: 120px;
}

.contact .body {
  max-width: 640px;
  margin: 0 auto 26px;
}

.email { margin: 0 0 36px; }

.email a {
  font-size: 17px;
  text-decoration: none;
  border-bottom: 1px solid rgba(110, 58, 54, 0.35);
  padding-bottom: 2px;
}

.email a:hover { border-bottom-color: var(--accent); }

.button {
  display: inline-block;
  font-family: var(--sans);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--ink);
  border-radius: 10px;
  padding: 15px 34px;
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.button .arrow {
  display: inline-block;
  margin-left: 10px;
  font-family: var(--serif);
  letter-spacing: 0;
  transition: transform 0.3s ease;
}

.button:hover,
.button:focus-visible {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
}

.button:hover .arrow { transform: translateX(4px); }

/* ---------- Contact modal ---------- */

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(29, 29, 29, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 1000;
}

.modal-overlay[hidden] { display: none; }

.modal {
  position: relative;
  background: var(--bg);
  border-radius: 14px;
  padding: 56px 40px 40px;
  max-width: 480px;
  width: 100%;
  max-height: calc(100vh - 48px);
  overflow-y: auto;
  box-shadow: 0 30px 70px rgba(29, 29, 29, 0.25);
}

.modal-close {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 32px;
  height: 32px;
  border: 1px solid var(--hairline);
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.modal-close:hover { background: rgba(110, 58, 54, 0.06); border-color: var(--accent); }

.modal-form { display: flex; flex-direction: column; gap: 18px; }

.field { display: flex; flex-direction: column; }

.field label {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.field input,
.field textarea {
  width: 100%;
  font-family: var(--sans);
  font-size: 15px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--hairline);
  border-radius: 8px;
  padding: 11px 14px;
  resize: vertical;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
}

.modal-submit {
  margin-top: 4px;
  align-self: flex-start;
  cursor: pointer;
}

.modal-success p {
  font-family: var(--serif);
  font-size: 19px;
  margin: 0;
}

.modal-error p {
  color: var(--accent);
  font-size: 14.5px;
  margin: 16px 0 0;
}

/* ---------- Footer ---------- */

.footer-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  padding-top: 28px;
  padding-bottom: 28px;
}

.footer-mark {
  font-family: var(--serif);
  font-size: 17px;
  text-align: center;
  margin: 0;
}

.footer-tag {
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
  margin: 0;
  text-align: left;
}

.copyright {
  font-size: 12.5px;
  color: var(--muted);
  margin: 0;
  text-align: right;
}

/* ---------- Motion ---------- */

.reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.9s ease, transform 0.9s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .card, .button, .button .arrow { transition: none; }
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .hero-copy { max-width: 70%; }
  .cards { gap: 20px; }
  .card { padding: 32px 28px 28px; }
  /* Photo stays 42% of .about's full width here — copy has to stay
     narrow enough to leave a real gap, or the (opaque, unmasked) photo
     paints over the heading text. */
  .about-copy { max-width: 50%; }
}

@media (max-width: 768px) {
  .container { padding: 0 24px; }

  /* Hero photo sits behind the text at low opacity — never cropped hard */
  .hero-photo {
    width: 100%;
    opacity: 0.16;
    -webkit-mask-image: linear-gradient(to bottom, black 0%, black 70%, transparent 100%);
    mask-image: linear-gradient(to bottom, black 0%, black 70%, transparent 100%);
  }

  .hero-inner { padding-top: 88px; padding-bottom: 80px; }
  .hero-copy { max-width: 100%; }
  .wordmark { margin-bottom: 28px; }

  .philosophy .container:first-child { padding-top: 72px; padding-bottom: 72px; }
  .products .container:first-child { padding-top: 72px; }

  .cards { grid-template-columns: 1fr; }
  .more { padding: 52px 0 72px; }

  .about-photo {
    position: static;
    width: calc(100% - 48px);
    height: 260px;
    margin: 0 24px;
    order: 2;
    -webkit-mask-image: none;
    mask-image: none;
    border-radius: 10px;
  }

  .about { display: flex; flex-direction: column; }
  .about-inner { padding-top: 72px; padding-bottom: 48px; }
  .about-copy { max-width: 100%; }
  .about-rule { display: none; }

  .contact .narrow { padding-top: 76px; padding-bottom: 88px; }

  .footer-inner {
    grid-template-columns: 1fr;
    justify-items: center;
    gap: 10px;
    text-align: center;
  }
  .footer-mark { order: 1; }
  .footer-tag { order: 2; text-align: center; }
  .copyright { order: 3; text-align: center; }
}
