/* Terroir Ceramics — plain, warm, studio-like. No framework. */
:root {
  --bg: #faf7f1;
  --card: #ffffff;
  --ink: #2b2620;
  --muted: #6f6558;
  --line: #e5ddd0;
  --accent: #8a5a33;
  --accent-soft: #f5f0e8;
  --good: #3d6b4f;
  --warn: #a33d2e;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  line-height: 1.55;
}
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
a { color: var(--accent); }
h1, h2, h3 { line-height: 1.25; }
h2 { font-size: 1.7rem; margin: 1.2em 0 0.4em; }
h3 { font-size: 1.25rem; margin: 1.4em 0 0.4em; }

/* Header */
.site-header { background: var(--card); border-bottom: 1px solid var(--line); padding: 18px 0 0; }
.brand h1 { margin: 0; font-size: 1.9rem; letter-spacing: 0.02em; }
.tagline { margin: 2px 0 14px; color: var(--muted); font-style: italic; }
.tabs { display: flex; gap: 4px; flex-wrap: wrap; }
.tabs button {
  font-family: inherit; font-size: 1rem;
  background: none; border: none; border-bottom: 3px solid transparent;
  padding: 8px 14px; cursor: pointer; color: var(--muted);
}
.tabs button.active { color: var(--ink); border-bottom-color: var(--accent); font-weight: bold; }

/* Pages */
.tab-page { display: none; padding-bottom: 40px; }
.tab-page.active { display: block; }
.intro { max-width: 640px; color: var(--muted); }

/* Hero */
.hero { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: 28px; align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; color: var(--muted); margin: 0 0 6px; }
.hero img { width: 100%; border-radius: 10px; display: block; }
.hero-text h2 { font-size: 2rem; margin-top: 0; }
@media (max-width: 720px) { .hero { grid-template-columns: 1fr; } }

/* Studio photo strip */
.studio-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 28px; }
.studio-grid figure { margin: 0; }
.studio-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; display: block; }
.studio-grid figcaption { text-align: center; color: var(--muted); font-size: 0.9rem; margin-top: 6px; }
@media (max-width: 720px) { .studio-grid { grid-template-columns: 1fr 1fr; } }
.studio-note { background: var(--accent-soft); border: 1px solid var(--line); border-radius: 10px; padding: 18px 22px; margin-top: 28px; }
.studio-note h3 { margin-top: 0; }

/* Buttons */
.button {
  display: inline-block; font-family: inherit; font-size: 1rem;
  background: var(--accent); color: #fff; border: none; border-radius: 6px;
  padding: 10px 18px; cursor: pointer; text-decoration: none;
}
.button:hover { opacity: 0.9; }
.button.secondary { background: #fff; color: var(--accent); border: 1px solid var(--accent); }
.button:disabled { opacity: 0.5; cursor: default; }

/* Product grid */
.product-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; margin-top: 18px; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; cursor: pointer; }
.card img { width: 100%; aspect-ratio: 1; object-fit: cover; display: block; }
.card-body { padding: 12px 14px 16px; }
.card-body h3 { margin: 0 0 4px; font-size: 1.1rem; }
.card-body p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.price { font-size: 1.15rem; font-weight: bold; margin: 8px 0 0; }
.price-note { font-size: 0.85rem; color: var(--muted); }
.badge { display: inline-block; font-size: 0.8rem; font-weight: bold; padding: 2px 8px; border-radius: 20px; margin-top: 8px; }
.badge.reserved { background: #f3e2c7; color: #7a5410; }
.badge.sold { background: #e8d5d5; color: var(--warn); }
.votes-line { font-size: 0.85rem; color: var(--muted); margin-top: 6px; }

/* Making / how it works */
.making { margin-top: 40px; }
.making video { width: 100%; max-width: 560px; border-radius: 10px; display: block; background: #000; }
.caption { color: var(--muted); font-size: 0.9rem; }
.how-drop { background: var(--accent-soft); border: 1px solid var(--line); border-radius: 10px; padding: 18px 22px; margin-top: 32px; }
.how-drop h3 { margin-top: 0; }
.how-drop ol { margin: 0; padding-left: 20px; }
.how-drop li { margin-bottom: 8px; }

/* Forms */
.form { max-width: 560px; margin-top: 12px; }
.form label { display: block; margin-bottom: 12px; font-weight: bold; font-size: 0.95rem; }
.form input, .form textarea {
  display: block; width: 100%; margin-top: 4px; padding: 10px;
  font-family: inherit; font-size: 1rem;
  border: 1px solid var(--line); border-radius: 6px; background: #fff;
}
.form-msg { color: var(--good); min-height: 1.2em; }
.form-msg.error { color: var(--warn); }

/* Modal */
.modal { position: fixed; inset: 0; background: rgba(0,0,0,0.55); display: flex; align-items: flex-start; justify-content: center; padding: 30px 16px; overflow-y: auto; z-index: 50; }
.modal[hidden] { display: none; }
.modal-box { background: #fff; border-radius: 12px; max-width: 860px; width: 100%; padding: 20px; display: grid; grid-template-columns: 1fr 1fr; gap: 22px; position: relative; }
.modal-box > img { width: 100%; border-radius: 8px; display: block; }
.modal-close { position: absolute; top: 8px; right: 14px; background: none; border: none; font-size: 1.8rem; cursor: pointer; color: var(--muted); }
.modal-info h3 { margin-top: 0; }
.modal-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
@media (max-width: 720px) { .modal-box { grid-template-columns: 1fr; } }

/* Manage */
.manage-tabs { display: flex; gap: 4px; flex-wrap: wrap; margin: 16px 0; }
.manage-tabs button {
  font-family: inherit; font-size: 0.95rem; background: #fff;
  border: 1px solid var(--line); border-radius: 20px; padding: 6px 14px; cursor: pointer;
}
.manage-tabs button.active { background: var(--accent); color: #fff; border-color: var(--accent); }
.mtab-page { display: none; }
.mtab-page.active { display: block; }
table { width: 100%; border-collapse: collapse; background: #fff; font-size: 0.95rem; }
th, td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--accent-soft); }
.demo-notice { background: #fdf3d7; border: 1px solid #e8d28a; border-radius: 8px; padding: 10px 14px; }
.mini { font-size: 0.85rem; padding: 5px 10px; }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }
input.price-edit { width: 90px; padding: 6px; font-family: inherit; border: 1px solid var(--line); border-radius: 6px; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 24px 0 32px; color: var(--muted); text-align: center; }
