/* =====================================================
   DishTrack™ — Site Stylesheet
   Palette: Fiesta Scarlet + warm editorial
   ===================================================== */

/* --- Fonts & Reset --- */
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  background: #faf8f4;
  color: #2c2c2c;
}

/* --- Top Nav --- */
.site-nav {
  background: #c42400;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.site-nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 3.25rem;
}

.site-nav-logo {
  color: #fff;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.15rem;
  font-weight: bold;
  text-decoration: none;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.site-nav-logo:hover { color: #fde8e8; }

.site-nav-links {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.site-nav-links a {
  color: rgba(255,255,255,0.88);
  text-decoration: none;
  font-size: 0.88rem;
  padding: 0.4rem 0.7rem;
  border-radius: 4px;
  transition: background 0.15s, color 0.15s;
}

.site-nav-links a:hover,
.site-nav-links a.active {
  background: rgba(255,255,255,0.18);
  color: #fff;
}

/* --- Page Header --- */
.page-header {
  background: linear-gradient(135deg, #c42400 0%, #a81e00 100%);
  color: #fff;
  padding: 3rem 1.5rem 2.5rem;
  text-align: center;
}

.page-header h1 {
  margin: 0 0 0.5rem;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 2.4rem;
  font-weight: normal;
  letter-spacing: 0.01em;
  line-height: 1.2;
}

.page-header p {
  margin: 0;
  font-size: 1.05rem;
  color: rgba(255,255,255,0.85);
}

/* --- Main Content --- */
main {
  max-width: 960px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
}

main.wide {
  max-width: 1100px;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: normal;
  color: #1a1a1a;
  margin-top: 2rem;
  margin-bottom: 0.5rem;
}

h1 { font-size: 2rem; }
h2 {
  font-size: 1.45rem;
  color: #c42400;
  border-bottom: 2px solid #e9e0d3;
  padding-bottom: 0.3rem;
}
h3 { font-size: 1.15rem; color: #2c2c2c; }
h4 { font-size: 1rem; color: #444; }

p { margin: 0.75rem 0; }

a { color: #26619c; text-decoration: none; }
a:hover { text-decoration: underline; color: #1d4a78; }

ul, ol { padding-left: 1.5rem; }
li { margin-bottom: 0.3rem; }

code {
  background: #f0ebe4;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.9em;
  color: #5a3a1a;
}

pre {
  background: #f0ebe4;
  padding: 1.1em 1.25em;
  border-radius: 6px;
  overflow-x: auto;
  border-left: 3px solid #e9e0d3;
  font-size: 0.9em;
}

hr {
  border: none;
  border-top: 1px solid #e9e0d3;
  margin: 2rem 0;
}

/* --- Notice / Callout --- */
.notice {
  background: #fffbf5;
  border: 1px solid #e9d8c4;
  border-left: 4px solid #c42400;
  padding: 1rem 1.25rem;
  border-radius: 0 6px 6px 0;
  margin: 1.25rem 0;
}

/* --- Cards --- */
.card {
  background: #fff;
  border: 1px solid #e9e0d3;
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1.25rem;
  box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}

/* --- Buttons --- */
.btn {
  display: inline-block;
  background: #26619c;
  color: #fff !important;
  padding: 0.5em 1.2em;
  border-radius: 5px;
  text-decoration: none !important;
  font-size: 0.95rem;
  transition: background 0.15s;
}
.btn:hover { background: #1d4a78; }

.btn-red {
  background: #c42400;
}
.btn-red:hover { background: #a81e00; }

.back-button {
  display: inline-block;
  background: #26619c;
  color: #fff !important;
  padding: 0.45em 1em;
  border-radius: 5px;
  text-decoration: none !important;
  font-weight: bold;
  font-size: 0.9rem;
  margin-bottom: 1.75rem;
  transition: background 0.15s;
}
.back-button:hover { background: #1d4a78; }

/* --- Tables --- */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0 1.5rem;
  font-size: 0.95rem;
}

th {
  background: #f0ebe4;
  text-align: left;
  padding: 0.6rem 0.75rem;
  border-bottom: 2px solid #e9e0d3;
  font-family: Georgia, serif;
  font-weight: normal;
  color: #444;
}

td {
  padding: 0.5rem 0.75rem;
  border-bottom: 1px solid #f0ebe4;
  vertical-align: middle;
}

tr:last-child td { border-bottom: none; }
tr:hover td { background: #fdf8f3; }

/* --- Color Swatch --- */
.swatch {
  display: inline-block;
  width: 18px;
  height: 18px;
  border-radius: 3px;
  border: 1px solid rgba(0,0,0,0.15);
  vertical-align: middle;
  margin-right: 8px;
  flex-shrink: 0;
}

.color-name-cell {
  display: flex;
  align-items: center;
}

/* --- Catalog Page --- */
.version-badge {
  display: inline-block;
  background: #26619c;
  color: #fff;
  font-size: 0.8rem;
  padding: 0.2em 0.75em;
  border-radius: 99px;
  margin-left: 0.5rem;
  vertical-align: middle;
  font-family: system-ui, sans-serif;
}

.catalog-stats {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin: 1.5rem 0 2rem;
}

.stat-box {
  background: #fff;
  border: 1px solid #e9e0d3;
  border-radius: 8px;
  padding: 1rem 1.5rem;
  text-align: center;
  min-width: 120px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.stat-box .stat-num {
  font-family: Georgia, serif;
  font-size: 2rem;
  color: #c42400;
  display: block;
  line-height: 1.1;
}

.stat-box .stat-label {
  font-size: 0.8rem;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.category-heading {
  background: linear-gradient(90deg, #f0ebe4, #faf8f4);
  border-left: 4px solid #26a69a;
  padding: 0.5rem 0.75rem;
  border-radius: 0 4px 4px 0;
  margin: 2rem 0 0.75rem;
  font-family: Georgia, serif;
  font-size: 1.05rem;
  color: #1a1a1a;
}

/* --- Gallery --- */
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin: 1.5rem 0;
}

.gallery figure {
  margin: 0;
  text-align: center;
  background: #fff;
  border: 1px solid #e9e0d3;
  border-radius: 8px;
  padding: 1rem;
  box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.gallery img {
  max-width: 100%;
  border-radius: 4px;
}

.gallery figcaption {
  margin-top: 0.6rem;
  font-size: 0.9rem;
  color: #777;
  font-style: italic;
}

/* --- Store Badges --- */
.store-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin: 1rem 0;
}

/* --- Footer --- */
.site-footer {
  background: #2c2c2c;
  color: #aaa;
  text-align: center;
  padding: 1.5rem 1rem;
  font-size: 0.85rem;
  margin-top: 3rem;
}

.site-footer a { color: #c9a080; }
.site-footer a:hover { color: #e0b898; text-decoration: underline; }

/* --- Responsive --- */
@media (max-width: 640px) {
  .page-header h1 { font-size: 1.7rem; }
  .site-nav-links a { font-size: 0.8rem; padding: 0.35rem 0.5rem; }
  .catalog-stats { gap: 1rem; }
  .gallery { grid-template-columns: 1fr; }
}
