:root {
  --fg: #2b1810;
  --muted: #8a7563;
  --border: #e8dcc6;
  --accent: #b8542d;
  --bg: #faf3e7;
  --max: 70ch;
}

* { box-sizing: border-box; }

html { font-size: 17px; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: var(--fg);
  background: var(--bg);
}

.site-header,
main,
.site-footer {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
}

.site-header {
  border-bottom: 1px solid var(--border);
  padding-top: 2rem;
  padding-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: var(--fg);
}
.site-logo {
  width: 56px;
  height: 56px;
  display: block;
}
.site-tagline {
  font-size: 0.95rem;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.lang-switcher {
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  color: var(--muted);
}
.lang-switcher a {
  color: var(--muted);
  text-decoration: none;
}
.lang-switcher a:hover {
  color: var(--accent);
  text-decoration: underline;
}
.lang-switcher .lang-current {
  color: var(--fg);
  font-weight: 600;
}
.lang-switcher .lang-sep {
  margin: 0 0.4rem;
  color: var(--border);
}

.site-footer {
  border-top: 1px solid var(--border);
  margin-top: 3rem;
  color: var(--muted);
  font-size: 0.9rem;
}

/* Ledger pages need a wider reading area for dense tables. */
body.page-ledger .site-header,
body.page-ledger main,
body.page-ledger .site-footer {
  max-width: min(96vw, 1200px);
}

body.page-ledger main table {
  display: block;
  width: 100%;
  overflow-x: auto;
  white-space: nowrap;
}

h1, h2, h3 {
  line-height: 1.25;
  margin-top: 2rem;
  margin-bottom: 0.6rem;
}

h1 { font-size: 1.9rem; }
h2 { font-size: 1.35rem; }
h3 { font-size: 1.1rem; }

a { color: var(--accent); }
a:hover { text-decoration: underline; }

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

.brew-header h1 { margin-bottom: 0.2rem; }
.brew-style {
  color: var(--muted);
  margin-top: 0;
  font-style: italic;
}

.brew-stats {
  border-collapse: collapse;
  margin: 1.5rem 0;
  width: 100%;
  font-size: 0.95rem;
}
.brew-stats th,
.brew-stats td {
  text-align: left;
  padding: 0.45rem 0.75rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
.brew-stats th {
  width: 10rem;
  font-weight: 500;
  color: var(--muted);
}

.brew-body { margin-top: 1.5rem; }

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 0.75rem;
  margin-top: 1rem;
}
.photo-grid figure { margin: 0; }

.brew-index {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  margin-top: 1rem;
}
.brew-index th,
.brew-index td {
  text-align: left;
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid var(--border);
}
.brew-index th {
  font-weight: 500;
  color: var(--muted);
}

.page-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0;
}
.page-list li {
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
}

.brew-style-inline,
.brew-abv-inline {
  color: var(--muted);
  font-size: 0.92rem;
}

.brew-date-inline {
  color: var(--muted);
  font-size: 0.92rem;
  font-variant-numeric: tabular-nums;
  margin-right: 0.4rem;
}
