/* ============================================================
   Etete Mart — design tokens
   Palette grounded in the product itself: churned butter gold,
   the deep clay of a jebena coffee pot, and highland green.
   Signature motif: a woven border pattern referencing the
   handwoven trim (tibeb) on a habesha netela shawl — used as
   a section divider, not decoration.
   ============================================================ */

:root {
  --bg: #FAF6EC;
  --bg-alt: #F0E9D6;
  --ink: #2A2015;
  --ink-soft: #6B5D48;
  --gold: #D9A441;
  --gold-deep: #B07C1E;
  --clay: #9C3F2B;
  --forest: #33473A;
  --forest-deep: #223027;
  --line: rgba(42, 32, 21, 0.14);
  --cream-card: #FFFDF7;

  --font-display: 'Fraunces', serif;
  --font-body: 'Public Sans', sans-serif;

  --radius: 4px;
  --max-w: 1120px;
}

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

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

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  margin: 0 0 0.5em 0;
  letter-spacing: -0.01em;
  color: var(--ink);
}

h1 { font-size: clamp(2.4rem, 5vw, 4rem); font-weight: 500; line-height: 1.05; }
h2 { font-size: clamp(1.8rem, 3.2vw, 2.6rem); line-height: 1.15; }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1em 0; color: var(--ink-soft); }

a { color: inherit; }

.eyebrow {
  font-family: var(--font-body);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--gold-deep);
  font-weight: 600;
}

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 28px;
}

/* ---------- header ---------- */

header.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(250, 246, 236, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 28px;
  max-width: var(--max-w);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: baseline;
  gap: 8px;
  text-decoration: none;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ink);
}

.brand span {
  font-family: var(--font-body);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold-deep);
  font-weight: 700;
}

nav.main-nav {
  display: flex;
  gap: 30px;
}

nav.main-nav a {
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--ink-soft);
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
}

nav.main-nav a:hover,
nav.main-nav a.active {
  color: var(--ink);
  border-color: var(--gold);
}

.nav-cta {
  background: var(--clay);
  color: #fff !important;
  padding: 10px 18px;
  border-radius: var(--radius);
  font-weight: 600;
  border: none !important;
}

.nav-cta:hover { background: #82311f; color: #fff !important; border-color: transparent !important; }

.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.menu-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  margin: 5px 0;
}

/* ---------- woven pattern divider (signature) ---------- */

.tibeb {
  height: 14px;
  width: 100%;
  background-image: repeating-linear-gradient(
    135deg,
    var(--gold) 0px, var(--gold) 6px,
    var(--clay) 6px, var(--clay) 12px,
    var(--forest) 12px, var(--forest) 18px,
    var(--bg) 18px, var(--bg) 20px
  );
  background-size: 28px 28px;
}

.tibeb.thin { height: 6px; }

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.15s;
  font-family: var(--font-body);
}

.btn-primary {
  background: var(--clay);
  color: #fff;
}
.btn-primary:hover { background: #82311f; transform: translateY(-1px); }

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

/* ---------- hero ---------- */

.hero {
  padding: 84px 0 70px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}

.hero h1 { margin-bottom: 0.35em; }
.hero .lede { font-size: 1.15rem; max-width: 46ch; }
.hero-actions { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }

.butter-mark {
  width: 100%;
  aspect-ratio: 4/3;
  border-radius: 6px;
  background: linear-gradient(155deg, #EFCB6E 0%, var(--gold) 45%, var(--gold-deep) 100%);
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 40px -18px rgba(42,32,21,0.35);
}
.butter-mark::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(115deg, rgba(255,255,255,0.16) 0 3px, transparent 3px 22px);
}
.butter-mark::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 14px;
  background-image: repeating-linear-gradient(
    90deg,
    var(--clay) 0 16px, var(--forest) 16px 32px
  );
}

/* ---------- sections ---------- */

section { padding: 70px 0; }
section.alt { background: var(--bg-alt); }

.section-head {
  max-width: 620px;
  margin-bottom: 44px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}

.card {
  background: var(--cream-card);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 28px;
}

.card h3 { margin-bottom: 0.4em; }
.card p { margin-bottom: 0; font-size: 0.95rem; }

.stat-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-top: 10px;
}
.stat-row .stat { border-left: 2px solid var(--gold); padding-left: 14px; }
.stat .num {
  font-family: var(--font-display);
  font-size: 2.1rem;
  color: var(--forest-deep);
  display: block;
  line-height: 1;
  margin-bottom: 4px;
}
.stat .label { font-size: 0.82rem; color: var(--ink-soft); }

/* ---------- product placeholder blocks ---------- */

.product-visual {
  aspect-ratio: 1/1;
  border-radius: 6px;
  position: relative;
  overflow: hidden;
  margin-bottom: 16px;
}
.product-visual::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 10px;
  background-image: repeating-linear-gradient(90deg, var(--clay) 0 12px, var(--forest) 12px 24px);
}
.pv-1 { background: linear-gradient(160deg, #F0CD70, var(--gold-deep)); }
.pv-2 { background: linear-gradient(160deg, #E9D9A8, #B49353); }
.pv-3 { background: linear-gradient(160deg, #F4E2A0, var(--gold)); }

/* ---------- table ---------- */

table.specs {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.94rem;
}
table.specs th, table.specs td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}
table.specs th {
  color: var(--ink-soft);
  font-weight: 600;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* ---------- forms ---------- */

form.quote-form {
  display: grid;
  gap: 18px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink);
}

input, select, textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--cream-card);
  font-family: var(--font-body);
  font-size: 0.95rem;
  color: var(--ink);
}
input:focus, select:focus, textarea:focus {
  outline: 2px solid var(--gold);
  outline-offset: 1px;
  border-color: var(--gold);
}

textarea { resize: vertical; min-height: 110px; }

.form-note {
  font-size: 0.82rem;
  color: var(--ink-soft);
}

#form-status {
  font-size: 0.9rem;
  padding: 12px 14px;
  border-radius: var(--radius);
  display: none;
}
#form-status.show { display: block; }
#form-status.ok { background: #E3ECE3; color: var(--forest-deep); }
#form-status.err { background: #F4DEDA; color: var(--clay); }

/* ---------- footer ---------- */

footer {
  background: var(--forest-deep);
  color: #EDE7D6;
  padding: 54px 0 30px;
  margin-top: 40px;
}
footer h4 { color: #fff; font-size: 1rem; }
footer a { color: #C9C0A5; text-decoration: none; font-size: 0.92rem; }
footer a:hover { color: #fff; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 34px;
}
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 20px;
  font-size: 0.82rem;
  color: #9C927A;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
}

/* ---------- product add-to-quote ---------- */

.product-add-row {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}
.qty-input {
  width: 90px;
  flex-shrink: 0;
}
.btn-add {
  flex: 1;
  padding: 12px 14px;
  font-size: 0.88rem;
}
.btn-add.added {
  background: var(--forest);
  color: #fff;
  border-color: var(--forest);
}
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
}

.nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  margin-left: 8px;
  border-radius: 999px;
  background: rgba(255,255,255,0.9);
  color: var(--clay);
  font-size: 0.72rem;
  font-weight: 700;
  vertical-align: middle;
}
.nav-badge:empty { display: none; }

.selection-bar {
  position: sticky;
  bottom: 20px;
  margin-top: 40px;
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--forest-deep);
  color: #fff;
  padding: 16px 22px;
  border-radius: 8px;
  box-shadow: 0 12px 30px -12px rgba(0,0,0,0.4);
}
.selection-bar.show { display: flex; }
.selection-bar span { font-weight: 600; font-size: 0.95rem; }

.selection-summary ul {
  list-style: none;
  padding: 0;
  margin: 10px 0 0 0;
  display: grid;
  gap: 8px;
}
.selection-summary li {
  display: flex;
  justify-content: space-between;
  font-size: 0.92rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 8px;
}

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .hero { grid-template-columns: 1fr; padding-top: 50px; }
  .grid-3 { grid-template-columns: 1fr; }
  .grid-2 { grid-template-columns: 1fr; }
  .stat-row { grid-template-columns: 1fr 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }

  nav.main-nav {
    position: fixed;
    top: 68px;
    left: 0; right: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--line);
    flex-direction: column;
    padding: 18px 28px;
    gap: 4px;
    display: none;
  }
  nav.main-nav.open { display: flex; }
  nav.main-nav a { padding: 10px 0; border-bottom: none; }
  .menu-toggle { display: block; }
  .nav-cta { margin-top: 10px; display: inline-block; width: fit-content; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn-primary:hover { transform: none; }
}
