/* Tago Brews — warm/rustic homebrew theme */

:root {
  --malt-100: #faf3e4;
  --malt-200: #f1e3c6;
  --malt-300: #e3cd9c;
  --wood-700: #4a2f1f;
  --wood-800: #382215;
  --wood-900: #241209;
  --copper-400: #d98c3a;
  --copper-500: #c26f28;
  --copper-600: #a35a1f;
  --hop-600: #5a7247;
  --text-main: #2b1b12;
  --text-muted: #6d5a48;
  --card-bg: #fffaf0;
  --border-soft: #e3cd9c;
  --shadow: 0 6px 20px rgba(56, 34, 21, 0.12);
  --radius: 14px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Source Sans 3', system-ui, -apple-system, sans-serif;
  color: var(--text-main);
  background: var(--malt-100);
  background-image:
    radial-gradient(circle at 15% 0%, rgba(210, 150, 80, 0.15), transparent 45%),
    radial-gradient(circle at 100% 20%, rgba(90, 114, 71, 0.10), transparent 40%);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: 'Fraunces', Georgia, serif;
  color: var(--wood-900);
  line-height: 1.15;
  margin: 0 0 0.5em;
}

a { color: var(--copper-600); text-decoration: none; }
a:hover { text-decoration: underline; }

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Header */
.site-header {
  background: var(--card-bg);
  border-bottom: 1px solid var(--border-soft);
  box-shadow: 0 2px 12px rgba(56, 34, 21, 0.08);
  position: sticky;
  top: 0;
  z-index: 20;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 700;
  font-size: 1.35rem;
  color: var(--wood-900) !important;
}
.brand:hover { text-decoration: none; opacity: 0.9; }
.brand-mark { height: 40px; width: auto; display: block; }

.site-nav { display: flex; gap: 22px; flex-wrap: wrap; }
.site-nav a {
  color: var(--wood-700) !important;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
}
.site-nav a:hover, .site-nav a.active {
  text-decoration: none;
  border-bottom-color: var(--copper-400);
  color: var(--wood-900) !important;
}

/* Hero */
.hero {
  padding: 72px 0 56px;
  text-align: center;
}
.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
}
.hero .tagline {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 620px;
  margin: 0.5em auto 0;
}
.hero .hero-actions {
  margin-top: 28px;
  display: flex;
  gap: 14px;
  justify-content: center;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  cursor: pointer;
}
.btn-primary {
  background: var(--copper-500);
  color: #fff !important;
}
.btn-primary:hover { background: var(--copper-600); text-decoration: none; }
.btn-outline {
  background: transparent;
  border-color: var(--wood-700);
  color: var(--wood-800) !important;
}
.btn-outline:hover { background: var(--wood-800); color: #fff !important; text-decoration: none; }
.btn-small { padding: 8px 16px; font-size: 0.85rem; }
.btn-danger { background: #a3341f; color: #fff !important; }
.btn-danger:hover { background: #7f2717; }

/* Sections */
section { padding: 56px 0; }
section.alt { background: var(--malt-200); }
.section-head { text-align: center; margin-bottom: 36px; }
.section-head p { color: var(--text-muted); max-width: 560px; margin: 0.4em auto 0; }

/* Cards / grid */
.grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
}

.batch-card h3 { margin-bottom: 4px; }
.batch-meta { color: var(--text-muted); font-size: 0.9rem; margin-bottom: 10px; }
.batch-stats {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  font-size: 0.85rem;
  color: var(--wood-700);
  margin: 10px 0;
}
.batch-stats strong { color: var(--wood-900); }

.status-pill {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #fff;
}
.status-planning { background: #8a7a67; }
.status-fermenting { background: var(--copper-500); }
.status-conditioning { background: var(--hop-600); }
.status-kegged { background: #6a4a2a; }
.status-finished { background: #3e5a2c; }

.brewing-now {
  border: 2px solid var(--copper-400);
  background: linear-gradient(160deg, var(--card-bg), var(--malt-200));
}
.brewing-now h2 { margin-top: 12px; }
.brewing-upcoming { border-color: var(--border-soft); opacity: 0.92; }
.sync-note { color: var(--text-muted); font-size: 0.8rem; margin: 12px 0 0; }

/* Projects */
.project-card { display: flex; flex-direction: column; gap: 8px; }
.project-card .project-tag {
  align-self: flex-start;
  background: var(--malt-300);
  color: var(--wood-800);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  text-transform: uppercase;
}

/* Forms */
form.stack { display: flex; flex-direction: column; gap: 16px; max-width: 560px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-weight: 600; font-size: 0.9rem; }
input, select, textarea {
  font-family: inherit;
  font-size: 1rem;
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: #fff;
  color: var(--text-main);
}
textarea { min-height: 120px; resize: vertical; }
input:focus, select:focus, textarea:focus {
  outline: 2px solid var(--copper-400);
  outline-offset: 1px;
}
.form-actions { display: flex; gap: 12px; align-items: center; }
.error-box {
  background: #fdeceb;
  border: 1px solid #e2a89f;
  color: #7f2717;
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 18px;
}
.notice-box {
  background: #eef4e7;
  border: 1px solid #c3d6ad;
  color: #3e5a2c;
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 18px;
}

/* Tables / detail */
.detail-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}
.admin-bar {
  background: var(--wood-800);
  color: var(--malt-100);
}
.admin-bar .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 24px;
  font-size: 0.85rem;
}
.admin-bar a { color: var(--malt-200) !important; font-weight: 600; }

/* Footer */
.site-footer {
  background: var(--wood-900);
  color: var(--malt-300);
  margin-top: 40px;
}
.footer-inner {
  padding: 26px 24px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.85rem;
}
.footer-links a { color: var(--malt-200) !important; }

.empty-state {
  text-align: center;
  color: var(--text-muted);
  padding: 40px 20px;
}

@media (max-width: 640px) {
  .header-inner { flex-direction: column; gap: 10px; }
  .site-nav { justify-content: center; }
}
