/* ============================================
   Rivergate Coffee Roasters — Stylesheet
   Warm, grounded, small-batch craft aesthetic
   ============================================ */

:root {
  --ink: #2b1c14;
  --bg: #faf5ee;
  --accent: #b5502e;
  --muted: #8a7361;
  --surface: #f0e4d4;

  --font-head: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'Inter', 'Helvetica Neue', Arial, sans-serif;

  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2.5rem;
  --space-5: 4rem;
  --space-6: 6rem;

  --radius: 6px;
  --shadow: 0 4px 14px rgba(43, 28, 20, 0.12);
  --border: 1px solid rgba(43, 28, 20, 0.14);
}

/* ============ Reset & base ============ */

* ,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1.05rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--font-head);
  color: var(--ink);
  line-height: 1.15;
  margin: 0 0 var(--space-2);
  font-weight: 600;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.6vw, 2.4rem); }
h3 { font-size: clamp(1.25rem, 2.6vw, 1.6rem); }
h4 { font-size: 1.1rem; }

p {
  margin: 0 0 var(--space-2);
  color: var(--ink);
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-color: rgba(181, 80, 46, 0.35);
  text-underline-offset: 3px;
  transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

a:hover {
  color: #8f3e22;
  text-decoration-color: currentColor;
}

ul {
  margin: 0 0 var(--space-2);
  padding-left: 1.2rem;
}

li {
  margin-bottom: 0.4rem;
}

/* ============ Layout helpers ============ */

.container {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 var(--space-3);
}

.section {
  padding: var(--space-5) 0;
}

.section-alt {
  padding: var(--space-5) 0;
  background-color: var(--surface);
}

/* ============ Site header & nav ============ */

.site-header {
  background-color: var(--bg);
  border-bottom: var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  padding-top: var(--space-2);
  padding-bottom: var(--space-2);
}

.brand {
  font-family: var(--font-head);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand:hover {
  color: var(--accent);
}

/* Nav toggle only shows a label — real checkbox/JS not assumed,
   so nav itself stays visible & wraps on mobile (no hiding). */
.nav-toggle {
  display: none;
}

.site-nav {
  width: 100%;
  order: 3;
  margin-top: var(--space-2);
}

.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-3);
}

.site-nav li {
  margin: 0;
}

.site-nav a {
  display: inline-block;
  color: var(--ink);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.4rem 0.15rem;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

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

.site-nav a.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

@media (min-width: 640px) {
  .site-header .container {
    flex-wrap: nowrap;
  }

  .site-nav {
    width: auto;
    order: 2;
    margin-top: 0;
  }

  .site-nav ul {
    gap: var(--space-3);
  }
}

/* ============ Hero ============ */

.hero {
  padding: var(--space-6) 0 var(--space-5);
  background:
    radial-gradient(circle at 85% 10%, rgba(181, 80, 46, 0.08), transparent 55%),
    var(--bg);
  border-bottom: var(--border);
  text-align: left;
}

.hero-title {
  max-width: 18ch;
  margin-bottom: var(--space-2);
}

.hero-sub {
  font-size: 1.2rem;
  color: var(--muted);
  max-width: 46ch;
  margin-bottom: var(--space-3);
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: var(--space-2);
}

.lead {
  font-size: 1.15rem;
  color: var(--ink);
  max-width: 62ch;
}

/* ============ Grids ============ */

.grid {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: 1fr;
}

.grid-2 {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: 1fr;
}

.grid-3 {
  display: grid;
  gap: var(--space-3);
  grid-template-columns: 1fr;
}

@media (min-width: 700px) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 980px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============ Card ============ */

.card {
  background-color: var(--surface);
  border: var(--border);
  border-radius: var(--radius);
  padding: var(--space-3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--ink);
}

.card-body {
  color: var(--muted);
  margin-bottom: 0;
}

/* ============ Feature ============ */

.feature {
  padding: var(--space-2) 0;
}

.feature-title {
  font-family: var(--font-head);
  font-size: 1.15rem;
  margin-bottom: 0.4rem;
  color: var(--ink);
}

/* ============ Stats ============ */

.stat {
  text-align: center;
  padding: var(--space-3) var(--space-2);
}

.stat-num {
  display: block;
  font-family: var(--font-head);
  font-size: clamp(2rem, 5vw, 2.8rem);
  color: var(--accent);
  font-weight: 600;
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label {
  color: var(--muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ============ Quote ============ */

.quote {
  border-left: 4px solid var(--accent);
  padding: var(--space-2) var(--space-3);
  font-family: var(--font-head);
  font-size: 1.3rem;
  font-style: italic;
  color: var(--ink);
  margin: var(--space-3) 0;
}

.quote-attr {
  display: block;
  margin-top: var(--space-2);
  font-family: var(--font-body);
  font-style: normal;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--muted);
}

/* ============ Lists with checks ============ */

.list-checks {
  list-style: none;
  padding-left: 0;
}

.list-checks li {
  position: relative;
  padding-left: 1.8rem;
  margin-bottom: 0.6rem;
}

.list-checks li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--accent);
  font-weight: 700;
}

/* ============ CTA block ============ */

.cta {
  background-color: var(--ink);
  color: var(--bg);
  border-radius: var(--radius);
  padding: var(--space-4);
  text-align: center;
}

.cta h2,
.cta h3,
.cta p {
  color: var(--bg);
}

.cta .btn-ghost {
  border-color: var(--bg);
  color: var(--bg);
}

.cta .btn-ghost:hover {
  background-color: var(--bg);
  color: var(--ink);
}

/* ============ Buttons ============ */

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius);
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background-color: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-primary:hover {
  background-color: #8f3e22;
  border-color: #8f3e22;
  color: #fff;
}

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

.btn-ghost:hover {
  background-color: var(--ink);
  color: var(--bg);
}

/* ============ Footer ============ */

.site-footer {
  background-color: var(--surface);
  border-top: var(--border);
  padding: var(--space-4) 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer a {
  color: var(--muted);
  text-decoration: underline;
  text-decoration-color: rgba(138, 115, 97, 0.4);
}

.site-footer a:hover {
  color: var(--accent);
}

/* ============ Misc refinements ============ */

::selection {
  background-color: var(--accent);
  color: #fff;
}

img {
  max-width: 100%;
  display: block;
}

hr {
  border: none;
  border-top: var(--border);
  margin: var(--space-4) 0;
}

/* Focus states for accessibility */
a:focus-visible,
.btn:focus-visible,
.site-nav a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}