@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,700;1,400&family=DM+Sans:opsz,wght@9..40,400;9..40,500;9..600&display=swap');

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

:root {
  --espresso:   #2c1810;
  --roast:      #6f3a1f;
  --crema:      #d4a96a;
  --latte:      #f5e6d0;
  --foam:       #faf6f0;
  --text:       #2a1a0e;
  --muted:      #7a5c44;
  --border:     #e0cdb8;
  --white:      #ffffff;
  --shadow-sm:  rgba(44, 24, 16, 0.08);
  --shadow-md:  rgba(44, 24, 16, 0.15);
}

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', system-ui, sans-serif;
  background: var(--foam);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.75;
}

/* ── NAV ──────────────────────────────────────────────── */
header {
  background: var(--espresso);
  padding: 0 2.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 16px rgba(0,0,0,0.35);
}

header .logo {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--crema);
  padding: 1.1rem 0;
  text-decoration: none;
  letter-spacing: .02em;
  white-space: nowrap;
}

nav { display: flex; gap: .1rem; }

nav a {
  color: rgba(245, 230, 208, 0.75);
  text-decoration: none;
  padding: .85rem 1.1rem;
  font-size: .88rem;
  font-weight: 500;
  letter-spacing: .04em;
  transition: color .2s;
  position: relative;
}

nav a::after {
  content: '';
  position: absolute;
  bottom: 0; left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 70%; height: 2px;
  background: var(--crema);
  transition: transform .25s ease;
  border-radius: 2px 2px 0 0;
}

nav a:hover        { color: var(--crema); }
nav a:hover::after { transform: translateX(-50%) scaleX(1); }
nav a.active       { color: var(--crema); }
nav a.active::after{ transform: translateX(-50%) scaleX(1); }

/* ── HERO ─────────────────────────────────────────────── */
.hero {
  background: linear-gradient(140deg, var(--espresso) 0%, #5c2d14 60%, var(--roast) 100%);
  color: var(--latte);
  padding: 5.5rem 2rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '☕';
  position: absolute;
  font-size: 20rem;
  opacity: 0.04;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  user-select: none;
}

.hero h1 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  margin-bottom: .65rem;
  color: var(--crema);
  text-shadow: 0 2px 16px rgba(0,0,0,0.3);
}

.hero p {
  font-size: 1.1rem;
  max-width: 580px;
  margin: 0 auto;
  opacity: .85;
  line-height: 1.7;
}

/* ── CONTENT ──────────────────────────────────────────── */
main {
  flex: 1;
  padding: 3.5rem 2rem;
  max-width: 900px;
  margin: 0 auto;
  width: 100%;
}

h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.9rem;
  color: var(--roast);
  margin: 2.75rem 0 .8rem;
}
main > h2:first-child { margin-top: 0; }

h3 { font-size: 1.1rem; color: var(--espresso); margin: 0 0 .4rem; font-weight: 600; }
p  { line-height: 1.8; margin-bottom: 1rem; }
em { color: var(--muted); }
strong { color: var(--espresso); }

.lead {
  font-size: 1.1rem;
  color: var(--muted);
  margin-bottom: 2rem;
}

/* ── CARDS ────────────────────────────────────────────── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
  margin: 1.75rem 0 2.5rem;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 3px solid var(--crema);
  border-radius: 10px;
  padding: 1.6rem;
  text-decoration: none;
  color: inherit;
  transition: box-shadow .25s, transform .25s, border-top-color .25s;
  display: block;
}

.card:hover {
  box-shadow: 0 8px 32px var(--shadow-md);
  transform: translateY(-4px);
  border-top-color: var(--roast);
}

.card .icon { font-size: 2.2rem; margin-bottom: .85rem; display: block; }
.card h3    { color: var(--roast); margin-bottom: .4rem; }
.card p     { margin: 0; font-size: .88rem; color: var(--muted); line-height: 1.6; }

/* ── STEPS ────────────────────────────────────────────── */
.steps { list-style: none; counter-reset: step; }

.steps li {
  counter-increment: step;
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  margin-bottom: 1rem;
  padding: 1.25rem 1.5rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  transition: box-shadow .2s;
}

.steps li:hover { box-shadow: 0 4px 16px var(--shadow-sm); }

.steps li::before {
  content: counter(step);
  min-width: 2.2rem;
  height: 2.2rem;
  background: var(--roast);
  color: var(--crema);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: .88rem;
  flex-shrink: 0;
}

/* ── TABLE ────────────────────────────────────────────── */
.table-wrap {
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 16px var(--shadow-sm);
  margin: 1.5rem 0 2rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: .93rem;
}

th {
  background: var(--espresso);
  color: var(--crema);
  padding: .85rem 1.2rem;
  text-align: left;
  font-weight: 600;
  font-size: .8rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

td {
  padding: .8rem 1.2rem;
  border-bottom: 1px solid var(--border);
  color: var(--text);
}

tr:last-child td { border-bottom: none; }
tr:nth-child(even) td { background: #fdf6ee; }
tbody tr { transition: background .15s; }
tbody tr:hover td { background: var(--latte); }

/* ── SPECS (recipe page) ──────────────────────────────── */
.specs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 1rem;
  margin: 1.75rem 0;
}

.spec-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1.1rem 1rem;
  text-align: center;
}

.spec-label {
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--muted);
  display: block;
  margin-bottom: .35rem;
}

.spec-value {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--roast);
}

/* ── DRINK HIGHLIGHT ──────────────────────────────────── */
.drink-banner {
  background: linear-gradient(150deg, var(--espresso) 0%, #5c2d14 100%);
  border-radius: 14px;
  padding: 2.5rem 2.75rem;
  color: var(--latte);
  margin-bottom: 2.75rem;
  display: flex;
  align-items: center;
  gap: 2rem;
  flex-wrap: wrap;
}

.drink-banner .big-icon { font-size: 5rem; flex-shrink: 0; line-height: 1; }

.drink-banner h2 {
  font-family: 'Playfair Display', Georgia, serif;
  color: var(--crema);
  font-size: 2rem;
  margin: 0 0 .5rem;
}

.drink-banner p { color: var(--latte); margin: 0; opacity: .85; line-height: 1.65; }

/* ingredients */
.ingredient-list {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: .6rem;
  margin: 1rem 0 2rem;
}

.ingredient-list li {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: .92rem;
}

.ingredient-list li::before {
  content: '·';
  font-size: 1.5rem;
  color: var(--crema);
  line-height: 1;
  flex-shrink: 0;
}

/* tip box */
.tip {
  background: linear-gradient(to right, #fef9f4, var(--white));
  border-left: 4px solid var(--crema);
  border-radius: 0 8px 8px 0;
  padding: 1.1rem 1.4rem;
  margin: 1.5rem 0;
  font-size: .93rem;
  color: var(--muted);
}

.tip strong { color: var(--roast); }

/* ── FOOTER ───────────────────────────────────────────── */
footer {
  background: var(--espresso);
  color: rgba(245, 230, 208, 0.7);
  text-align: center;
  padding: 2rem 2rem 1.75rem;
  font-size: .83rem;
}

.footer-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: .25rem 1.5rem;
  margin-top: .6rem;
}

footer a { color: var(--crema); text-decoration: none; transition: opacity .2s; }
footer a:hover { opacity: .7; }
