/* Elemental Color - Main Stylesheet */

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Skip Link (Accessibility) */
.skip-link {
  position: absolute;
  top: -100px;
  left: -100px;
  background: #333;
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 1000;
  text-decoration: none;
  border: none;
  border-radius: 0 0 4px 0;
  font-size: 0.85rem;
}

.skip-link:focus {
  top: 0;
  left: 0;
}

/* Screen Reader Only (Accessibility) */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: #fff;
  color: #000;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1rem;
}

h1 { font-size: 3rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }

p {
  margin-bottom: 1rem;
}

a {
  color: #000;
  text-decoration: none;
  border-bottom: 1px solid #000;
  transition: opacity 0.2s ease;
}

a:hover {
  opacity: 0.6;
}

/* Brand Name with Colored C */
.brand-name {
  font-weight: 700;
  white-space: nowrap;
}

.brand-c {
  transition: color 0.3s ease;
}

/* Layout */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

main {
  flex: 1;
}

/* Header / Navigation */
.site-header {
  padding: 1.5rem 0;
  border-bottom: 1px solid #000;
}

.site-header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.site-logo, .site-logo:visited {
  font-size: 1.25rem;
  font-weight: 700;
  border: none;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.site-logo:hover {
  opacity: 1;
}

.site-nav {
  display: flex;
  gap: 2rem;
}

.site-nav a {
  font-size: 0.875rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
}

/* Hero Section (Splash) */
.hero {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 4rem 2rem;
}

.hero h1 {
  font-size: 4rem;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
}

.hero .tagline {
  font-size: 1.25rem;
  font-weight: 400;
  color: #333;
  margin-bottom: 3rem;
}

.hero-nav {
  display: flex;
  gap: 2rem;
}

.hero-nav a {
  font-size: 1rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
  padding: 0.75rem 1.5rem;
  border: 2px solid #000;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.hero-nav a:hover {
  background-color: #000;
  color: #fff;
  opacity: 1;
}

/* Shipping CTA on Homepage */
.shipping-cta {
  margin-top: 3rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.8rem;
}

.shipping-cta-label {
  color: #888;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
}

.shipping-cta-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.6rem;
  background: #f8f8f8;
  border: 1px solid #eee;
  border-radius: 2px;
  color: #444;
  font-size: 0.75rem;
  letter-spacing: 0.02em;
  transition: all 0.15s ease;
}

.shipping-cta-item:hover {
  background: #f0f0f0;
  border-color: #ddd;
  opacity: 1;
}

.shipping-cta-swatch {
  width: 10px;
  height: 10px;
  border-radius: 1px;
  flex-shrink: 0;
}

/* Page Header */
.page-header {
  padding: 4rem 0 2rem;
  border-bottom: 1px solid #eee;
  margin-bottom: 3rem;
}

.page-header h1 {
  margin-bottom: 0.5rem;
}

.page-header .subtitle {
  color: #666;
  font-size: 1.125rem;
}

/* Content Sections */
.content-section {
  padding: 3rem 0;
}

.content-section + .content-section {
  border-top: 1px solid #eee;
}

.content-section h2 {
  margin-bottom: 1.5rem;
}

/* Pigment Controls */
.pigment-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid #eee;
}

.sort-label {
  font-size: 0.75rem;
  color: #888;
  letter-spacing: 0.05em;
}

.sort-select {
  font-family: inherit;
  font-size: 0.75rem;
  padding: 0.35rem 0.6rem;
  border: 1px solid #ddd;
  border-radius: 2px;
  background: #fff;
  color: #333;
  cursor: pointer;
}

.sort-select:focus {
  outline: none;
  border-color: #999;
}

/* Pigment Grid */
.pigment-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 2rem;
  padding: 2rem 0;
}

.pigment-card {
  border: 1px solid #eee;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.pigment-card:hover {
  border-color: #000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.pigment-card a {
  display: block;
  position: relative;
  border: none;
}

/* Under construction state */
.pigment-card.under-construction {
  filter: grayscale(100%) brightness(0.85);
  opacity: 0.6;
  pointer-events: none; /* hard-disable interaction */
  user-select: none;
}

/* Optional overlay badge */
.pigment-card.under-construction::after {
  content: "coming soon";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;

  color: #444;
  background: rgba(255, 255, 255, 0.6);
  backdrop-filter: blur(2px);
}

.pigment-card-image {
  aspect-ratio: 4/3;
  background-color: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

/* Pigment Status Badges */
.pigment-badge {
  position: absolute;
  top: 8px;
  right: 8px;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.25rem 0.5rem;
  border-radius: 2px;
}

.pigment-badge--shipping {
  background: rgba(34, 139, 34, 0.9);
  color: #fff;
}

.pigment-badge--dev {
  background: rgba(100, 100, 100, 0.85);
  color: #fff;
}

/* Inactive pigment card styling */
.pigment-card--inactive {
  opacity: 0.7;
}

.pigment-card--inactive .pigment-card-swatch {
  filter: grayscale(40%);
}

/* Shipping Indicator (near purchase) */
.shipping-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  margin-top: 0.75rem;
  padding: 0.4rem 0.7rem;
  background: #f0f7f0;
  border: 1px solid #d4e8d4;
  border-radius: 2px;
  font-size: 0.7rem;
  color: #2d6a2d;
  letter-spacing: 0.03em;
  transition: all 0.15s ease;
}

.shipping-indicator:hover {
  background: #e5f2e5;
  border-color: #c0dcc0;
  opacity: 1;
}

.shipping-dot {
  width: 6px;
  height: 6px;
  background: #2d6a2d;
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* EC TBD Section */
.ec-tbd-section {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 3px;
  padding: 1.5rem;
  margin-top: 1rem;
}

.ec-tbd-section h3 {
  font-size: 0.9rem;
  color: #666;
  margin-bottom: 0.5rem;
}

.ec-tbd-intro {
  font-size: 0.8rem;
  color: #888;
  margin-bottom: 0.75rem;
}

.ec-tbd-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

.ec-tbd-list li {
  font-size: 0.7rem;
  color: #666;
  background: #f0f0f0;
  padding: 0.25rem 0.5rem;
  border-radius: 2px;
}

/* Small purchase button */
.btn-sm {
  font-size: 0.7rem;
  padding: 0.3rem 0.6rem;
}

.btn-purchase {
  background: #000;
  color: #fff;
  border: none;
  margin-left: auto;
}

.btn-purchase:hover {
  background: #333;
  opacity: 1;
}

/* RMSB download button */
.btn-rmsb {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.btn-rmsb svg {
  flex-shrink: 0;
}

/* RMSB link in safety section */
.rmsb-link {
  margin-top: 1rem;
  font-size: 0.85rem;
}

.rmsb-link a {
  color: #666;
  text-decoration: none;
  border-bottom: 1px solid #ccc;
}

.rmsb-link a:hover {
  color: #333;
  border-bottom-color: #333;
}

/* Batch Accordion Cards */
.batch-accordion {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.batch-card {
  border: 1px solid #eee;
  border-radius: 3px;
  background: #fff;
}

.batch-card--shipping {
  border-color: #d4e8d4;
  background: #fafff9;
}

.batch-card-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  cursor: pointer;
  list-style: none;
}

.batch-card-header::-webkit-details-marker {
  display: none;
}

.batch-card-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.batch-number {
  font-weight: 600;
  font-size: 0.9rem;
}

.batch-card-summary {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  color: #888;
  font-size: 0.75rem;
}

.batch-date-short {
  color: #666;
}

.batch-stat {
  padding: 0.15rem 0.4rem;
  background: #f5f5f5;
  border-radius: 2px;
  font-size: 0.65rem;
}

.batch-card-chevron {
  width: 16px;
  height: 16px;
  position: relative;
  flex-shrink: 0;
}

.batch-card-chevron::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  border-right: 1.5px solid #999;
  border-bottom: 1.5px solid #999;
  transform: translate(-50%, -70%) rotate(45deg);
  transition: transform 0.2s ease;
}

.batch-card[open] .batch-card-chevron::before {
  transform: translate(-50%, -30%) rotate(-135deg);
}

.batch-card-content {
  padding: 0 1rem 1rem;
  border-top: 1px solid #eee;
}

.batch-card--shipping .batch-card-content {
  border-top-color: #d4e8d4;
}

.batch-actions-row {
  display: flex;
  justify-content: flex-end;
  padding: 0.5rem 0;
  margin-bottom: 0.5rem;
}

/* Data Source Chips */
.data-chip {
  display: inline-flex;
  align-items: center;
  font-size: 0.55rem;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.15rem 0.35rem;
  border-radius: 2px;
  margin-left: 0.3rem;
  vertical-align: middle;
}

.data-chip--ref {
  background: #f0f0f0;
  color: #666;
}

.data-chip--ec {
  background: #e8f4e8;
  color: #2d6a2d;
}

.data-chip--method {
  background: #f5f0e8;
  color: #8a6d3b;
}

.pigment-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pigment-card-swatch {
  width: 100%;
  height: 100%;
}

.pigment-card-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.pigment-card-content {
  padding: 1.5rem;
}

.pigment-card h3 {
  margin-bottom: 0.5rem;
}

.pigment-card p {
  color: #666;
  font-size: 0.875rem;
  margin-bottom: 0;
}

/* Pigment Detail */
.pigment-hero {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  padding: 3rem 0;
  align-items: start;
}

.pigment-hero-media-column {
  display: flex;
  flex-direction: column;
}

.pigment-hero-image {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.pigment-hero-image:focus {
  outline: 2px solid #4B6BA5;
  outline-offset: 2px;
}

.pigment-hero-media {
  display: none;
  width: 100%;
  height: auto;
  max-height: 500px;
  object-fit: contain;
}

.pigment-hero-media.active {
  display: block;
}

.pigment-hero-image img.pigment-hero-img {
  width: 100%;
  height: auto;
  max-height: 500px;
  object-fit: contain;
}

/* Media Preview Belt */
.media-preview-belt {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
  flex-wrap: wrap;
}

.media-thumb {
  width: 60px;
  height: 60px;
  padding: 0;
  border: 1px solid #ddd;
  border-radius: 3px;
  background: #f5f5f5;
  cursor: pointer;
  opacity: 0.5;
  transition: opacity 0.15s ease, border-color 0.15s ease;
  overflow: hidden;
  position: relative;
}

.media-thumb:hover {
  opacity: 0.8;
}

.media-thumb.active {
  opacity: 1;
  border-color: #333;
}

.media-thumb img,
.media-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-thumb-video-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 0.7rem;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,0.5);
  pointer-events: none;
}

/* Keep square aspect for swatch fallback */
.pigment-hero-image:has(.pigment-swatch-large) {
  aspect-ratio: 1;
}

.pigment-swatch-large {
  width: 100%;
  height: 100%;
}

.pigment-hero-content h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.pigment-formula {
  font-size: 1.5rem;
  color: #666;
  margin-bottom: 1.5rem;
}

.pigment-hex {
  font-family: monospace;
  font-size: 1rem;
  color: #999;
  margin-bottom: 2rem;
}

/* ===== Info Grid ===== */
.info-grid {
  display: grid;
  gap: 1.5rem;
  margin: 2rem 0;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* Desktop-ish: 3 columns */
@media (min-width: 900px) {
  .info-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* Tablet-ish: 2 columns */
@media (min-width: 600px) and (max-width: 899px) {
  .info-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Phone: 1 column */
@media (max-width: 599px) {
  .info-grid {
    grid-template-columns: 1fr;
  }
}

/* span helper */
.info-item.span-2 { grid-column: span 2; }

/* =========================
   Info tile semantic accents
   ========================= */

/* Base card */
.info-item {
  background: #fafafa;
  padding: 1rem;
  border-radius: 2px;
  position: relative;
}

/* Shared accent mechanism */
.info-item[class*="type-"] {
  border-left: 2px solid transparent;
  background-clip: padding-box;
}

/* Scientific / Chemical (default neutral) */
.info-item.type-scientific,
.info-item.type-chemical {
  border-left-color: #d6d6d6;
  background-color: #fafafa;
}

/* Optical */
.info-item.type-optical {
  border-left-color: #8fa8c8;
  background-color: #f7f9fc;
}

/* Physical */
.info-item.type-physical {
  border-left-color: #b7b0a6;
  background-color: #f9f8f6;
}

/* Safety */
.info-item.type-safety {
  border-left-color: #c4847a;
  background-color: #fcf9f8;
}

/* Standards / Compliance */
.info-item.type-standards {
  border-left-color: #a0a0a0;
  background-color: #f8f8f8;
}

/* Identifiers / Classification */
.info-item.type-identifiers,
.info-item.type-classification {
  border-left-color: #c2c2c2;
  background-color: #fafafa;
}

/* Subtle text tuning for procedural sections */
.info-item.type-safety .k,
.info-item.type-standards .k {
  opacity: 0.75;
}

.info-item.type-safety .v {
  color: #444;
}

/* Testing */
.info-item.type-testing {
  border-left-color: #7a9cc4;
  background-color: #f8f9fc;
}

.info-item dt {
  font-size: 0.75rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
  color: #666;
  margin-bottom: 0.4rem;
}

/* ---- dual-value layout ---- */

.info-item dd.dual {
  display: grid;
  gap: 0.6rem;
}

.info-item dd.dual .row {
  display: grid;
  grid-template-columns: 3rem 1fr;
  grid-template-areas:
    "k v"
    "note note";
  column-gap: 0.6rem;
  row-gap: 0.15rem;
}

/* REF / EC label */
.info-item dd.dual .k {
  grid-area: k;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  opacity: 0.65;
}

/* value */
.info-item dd.dual .v {
  grid-area: v;
  font-size: 0.75rem;
  font-weight: 500;
  color: rgba(0,0,0,0.78);
}

/* note gets its OWN ROW */
.info-item dd.dual .note {
  grid-area: note;
  font-size: 0.75rem;
  line-height: 1.35;
  opacity: 0.6;
  white-space: normal;
  overflow-wrap: break-word;
}

/* If you mark TBD with a class, make it intentionally quiet */
.info-item dd.dual .v.is-tbd {
  color: rgba(0,0,0,0.45);
  font-weight: 400;
}


/* Testing Sections */
.testing-section {
  padding: 2rem 0;
  border-bottom: 1px solid #eee;
}

.testing-section:last-child {
  border-bottom: none;
}

.testing-section h3 {
  margin-bottom: 1rem;
}

.testing-section p {
  color: #333;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 1rem 2rem;
  font-size: 0.875rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
  border: 2px solid #000;
  background-color: transparent;
  color: #000;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.btn:hover {
  background-color: #000;
  color: #fff;
  opacity: 1;
}

.btn-primary {
  background-color: #000;
  color: #fff;
}

.btn-primary:hover {
  background-color: #333;
}

.btn-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* --- Coming soon button state --- */
.btn--coming-soon {
  position: relative;
  opacity: 0.5;
  pointer-events: none;
  cursor: default;
  filter: grayscale(60%);
}

.btn--coming-soon::after {
  content: "coming soon";
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #5a7a9a;
  background: rgba(255,255,255,0.85);
  text-shadow: none;
}

/* Pigment Selector */
.pigment-selector {
  max-width: 400px;
  margin: 2rem 0;
}

.pigment-selector select {
  width: 100%;
  padding: 1rem;
  font-size: 1rem;
  border: 2px solid #000;
  background-color: #fff;
  cursor: pointer;
}

/* =========================
   References (PDP)
   ========================= */

.references {
  margin-top: 2.5rem;
}

.references h2 {
  margin-bottom: 1rem;
  text-transform: lowercase;
}

.references .ref-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 1rem;
}

.references .ref-block {
  background: #fafafa;
  padding: 1rem;
}

.references .ref-block h3 {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  color: #555;
}

.ref-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.ref-list li {
  padding: 0.6rem 0;
  border-top: 1px solid #eee;
}

.ref-list li:first-child {
  border-top: none;
  padding-top: 0;
}

.ref-list a {
  color: #111;
  text-decoration: none;
  font-weight: 600;
  line-height: 1.25;
}

.ref-list a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.ref-meta {
  margin-top: 0.3rem;
  font-size: 0.85rem;
  line-height: 1.35;
  color: #666;
}

.ref-pill {
  display: inline-block;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  color: #666;
  background: #fff;
  border: 1px solid #eee;
  padding: 0.15rem 0.4rem;
  margin-right: 0.5rem;
  border-radius: 999px;
  vertical-align: middle;
}
.ref-link {
  display: inline-flex;
  align-items: baseline;
  gap: 0.5rem;
  text-decoration: none; /* kill default underline */
}

.ref-link:hover .ref-text,
.ref-link:focus-visible .ref-text {
  text-decoration: underline;
}

.ref-badge {
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
  background: #f0f0f0;
  color: #555;
  flex-shrink: 0;
}

.ref-text {
  text-decoration: none;
}



/* =========================
   Footer (simple, single-line)
   ========================= */

.site-footer {
  margin-top: 4rem;
  padding: 2rem 0;
  border-top: 1px solid #eee;
  color: #666;
  font-size: 0.85rem;
}

.site-footer .footer-line {
  max-width: 1100px;      /* match main content width */
  margin: 0 auto;
  padding: 0 1.25rem;

  text-align: center;
  line-height: 1.6;
}

.site-footer a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid #ddd;
}

.site-footer a:hover {
  opacity: 0.7;
}

.site-footer .heart {
  color: #e53935;
}





/* Back Link */
.back-link {
  margin-bottom: 1.5rem;
}

.back-link a {
  font-size: 0.875rem;
  color: #666;
  border-bottom-color: #ccc;
}

.back-link a:hover {
  color: #000;
  border-bottom-color: #000;
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .hero-nav {
    flex-direction: column;
    gap: 1rem;
  }

  .pigment-hero {
    grid-template-columns: 1fr;
  }

  .site-header .container {
    flex-direction: column;
    gap: 1rem;
  }

  .site-nav {
    gap: 1rem;
  }

  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
}

/* Dev Build Indicator */
.dev-indicator {
  position: fixed;
  bottom: 10px;
  right: 10px;
  background: rgba(90, 122, 154, 0.9);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.35rem 0.6rem;
  border-radius: 2px;
  z-index: 9999;
  pointer-events: none;
}

/* Utility Classes */
.text-center { text-align: center; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }


/* =========================
   Legal / Policy pages
   (scoped so it won't touch other pages)
   ========================= */

body.legal-page .legal-content {
  max-width: 820px;
  margin: 0 auto;
  padding: 3rem 1.25rem;
}

/* Headings: smaller + calmer than site hero */
body.legal-page .legal-content h1 {
  font-size: 2rem;
  margin: 0 0 0.25rem;
  letter-spacing: -0.01em;
}

body.legal-page .legal-content .meta {
  color: #666;
  margin: 0 0 2rem;
}

/* Section headers: quiet, catalog-ish */
body.legal-page .legal-content h2 {
  font-size: 1.1rem;
  margin: 2rem 0 0.5rem;
  text-transform: lowercase;
  letter-spacing: 0.04em;
}

/* Lists: a touch more breathing room */
body.legal-page .legal-content ul {
  padding-left: 1.25rem;
  margin: 0.5rem 0 1rem;
}

body.legal-page .legal-content li {
  margin: 0.25rem 0;
}

/* Divider */
body.legal-page .legal-content hr {
  border: 0;
  border-top: 1px solid #eee;
  margin: 2rem 0;
}

/* Links: keep your brand style but soften */
body.legal-page .legal-content a {
  border-bottom-color: #ccc;
}

body.legal-page .legal-content a:hover {
  opacity: 0.7;
}

/* =========================
   Tabs (Pigment Detail)
   ========================= */

.tab-nav {
  display: flex;
  gap: 0;
  border-bottom: 1px solid #eee;
  margin-bottom: 0;
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 100;
}

.tab-btn {
  padding: 1rem 2rem;
  font-size: 0.875rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  color: #666;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.tab-btn:hover {
  color: #000;
}

.tab-btn.active {
  color: #000;
  border-bottom-color: #000;
}

.tab-btn:focus-visible {
  outline: 2px solid #000;
  outline-offset: -2px;
}

.tab-panel {
  display: none;
}

.tab-panel.active {
  display: block;
}

/* =========================
   Exemplar Gallery
   ========================= */

.exemplar-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.exemplar-card {
  background: #fafafa;
  border-radius: 2px;
  overflow: hidden;
  border-left: 2px solid #8fa8c8;
}

.exemplar-image {
  aspect-ratio: 16/10;
  overflow: hidden;
  background-color: #eee;
}

.exemplar-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.exemplar-card:hover .exemplar-image img {
  transform: scale(1.02);
}

.exemplar-info {
  padding: 1.25rem;
}

.exemplar-title {
  font-size: 1rem;
  font-weight: 500;
  margin: 0 0 1rem 0;
  line-height: 1.3;
}

.exemplar-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.75rem;
  margin: 0;
}

.exemplar-field {
  padding: 0;
}

.exemplar-field dt {
  font-size: 0.7rem;
  text-transform: lowercase;
  letter-spacing: 0.08em;
  color: #888;
  margin-bottom: 0.2rem;
}

.exemplar-field dd {
  font-size: 0.75rem;
  color: #333;
  margin: 0;
  line-height: 1.3;
  font-weight: 500;
}

.exemplar-description {
  margin: 1rem 0 0 0;
  padding-top: 1rem;
  border-top: 1px solid #eee;
  font-size: 0.85rem;
  color: #555;
  line-height: 1.5;
}

@media (max-width: 599px) {
  .exemplar-gallery {
    grid-template-columns: 1fr;
  }
}

/* Placeholder message */
.placeholder-message {
  color: #666;
  font-style: italic;
  padding: 2rem 0;
}

/* =========================
   Batch Data Tab
   ========================= */

.batch-section {
  padding: 1rem 0;
}

.batch-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.batch-header h3 {
  margin: 0;
}

.batch-select {
  padding: 0.6rem 2rem 0.6rem 1rem;
  font-size: 0.8rem;
  font-family: inherit;
  letter-spacing: 0.02em;
  border: 1px solid #ccc;
  border-radius: 2px;
  background: #fafafa url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E") no-repeat right 0.75rem center;
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  min-width: 280px;
}

.batch-select:hover {
  border-color: #999;
}

.batch-select:focus {
  outline: 2px solid #000;
  outline-offset: 2px;
}

.batch-data {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.batch-data[hidden] {
  display: none;
}

.batch-overview,
.batch-charge,
.batch-synthesis,
.batch-events,
.batch-product {
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #eee;
}

.batch-product {
  border-bottom: none;
}

.batch-data h4 {
  font-size: 0.875rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
  color: #666;
  margin-bottom: 1rem;
}

.batch-meta {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 1rem;
}

.batch-notes {
  font-size: 0.85rem;
  color: #555;
  margin-top: 1rem;
  line-height: 1.5;
}

.batch-info-grid {
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
}

.batch-info-grid .info-item dd {
  font-size: 1rem;
  font-weight: 500;
}

/* Stoichiometry Table */
.stoich-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
  margin: 1rem 0;
}

.stoich-table th,
.stoich-table td {
  padding: 0.75rem 1rem;
  text-align: left;
  border-bottom: 1px solid #eee;
}

.stoich-table th {
  font-size: 0.75rem;
  text-transform: lowercase;
  letter-spacing: 0.08em;
  color: #666;
  font-weight: normal;
}

.stoich-table tbody tr:hover {
  background-color: #fafafa;
}

.reagent-note {
  font-size: 0.75rem;
  color: #888;
}

.error-pos {
  color: #2a7d2a;
}

.error-neg {
  color: #8b4513;
}

/* Chart Container */
.chart-container {
  position: relative;
  width: 100%;
  height: 300px;
  margin: 1rem 0;
  background: #fafafa;
  border-radius: 2px;
}

.batch-chart {
  width: 100%;
  height: 100%;
}

/* Events Timeline */
.events-timeline {
  list-style: none;
  padding: 0;
  margin: 0;
}

.event-item {
  display: flex;
  gap: 1.5rem;
  padding: 1rem 0;
  border-bottom: 1px solid #f0f0f0;
}

.event-item:last-child {
  border-bottom: none;
}

.event-time {
  flex-shrink: 0;
  width: 3rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #666;
  text-align: right;
}

.event-content {
  flex: 1;
}

.event-desc {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.event-notes {
  font-size: 0.8rem;
  color: #666;
  margin: 0;
  line-height: 1.4;
}

/* Product Notes */
.product-notes {
  list-style: disc;
  padding-left: 1.5rem;
  margin-top: 1rem;
}

.product-notes li {
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 0.5rem;
  line-height: 1.4;
}

/* Batch Title Block */
.batch-title-block {
  margin-bottom: 1rem;
}

.batch-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.batch-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 0.25rem 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.batch-date {
  font-size: 0.85rem;
  color: #666;
  margin: 0;
}

.btn-download-pdf {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.75rem;
  font-size: 0.7rem;
  font-family: inherit;
  letter-spacing: 0.08em;
  text-transform: lowercase;
  text-decoration: none;
  color: #666;
  background: #f5f5f5;
  border: 1px solid #ddd;
  border-radius: 2px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-download-pdf:hover {
  color: #333;
  background: #eee;
  border-color: #ccc;
}

.btn-download-pdf svg {
  flex-shrink: 0;
}

/* Batch Shipping Status */
.batch-status-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background-color: #f8faf8;
  border-left: 2px solid #6a9a6a;
  margin-bottom: 0;
  border-radius: 0 2px 2px 0;
}

.status-indicator {
  width: 8px;
  height: 8px;
  background-color: #6a9a6a;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-text {
  font-size: 0.8rem;
  color: #5a7a5a;
  letter-spacing: 0.02em;
}

.batch-active-badge {
  display: inline-block;
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #5a7a5a;
  background-color: #e8f0e8;
  padding: 0.15rem 0.5rem;
  border-radius: 2px;
  margin-left: 0.5rem;
  vertical-align: middle;
}

/* Subtle accent for shipping batch container */
.batch-data.batch-shipping {
  position: relative;
}

.batch-data.batch-shipping::before {
  content: "";
  position: absolute;
  top: 0;
  left: -1rem;
  bottom: 0;
  width: 2px;
  background: linear-gradient(to bottom, #6a9a6a 0%, transparent 100%);
  opacity: 0.4;
}

/* Batch Section Header with Photo */
.batch-section-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem;
  margin-bottom: 1rem;
}

.batch-section-header > div:first-child {
  flex: 1;
}

.batch-section-header h4 {
  margin-bottom: 0.5rem;
}

.batch-photo-placeholder {
  flex-shrink: 0;
  width: 100px;
  height: 100px;
  border-radius: 2px;
  overflow: hidden;
}

.batch-photo-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.25;
  position: relative;
}

.placeholder-label {
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #fff;
  text-shadow: 0 1px 2px rgba(0,0,0,0.3);
  text-align: center;
  padding: 0.25rem;
}

/* Additional Images Gallery */
.batch-images {
  padding-top: 1.5rem;
  border-top: 1px solid #eee;
  margin-top: 1.5rem;
}

.batch-images h4 {
  margin-bottom: 1rem;
}

.batch-image-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 1rem;
}

.batch-image-item {
  margin: 0;
}

.batch-image-item img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 2px;
  background-color: #f5f5f5;
}

.batch-image-item figcaption {
  font-size: 0.75rem;
  color: #666;
  margin-top: 0.5rem;
  line-height: 1.3;
}

@media (max-width: 599px) {
  .batch-section-header {
    flex-direction: column;
  }
  
  .batch-photo-placeholder {
    width: 80px;
    height: 80px;
  }
}

