/* EPA Chemical Compliance Audit - Base Styles */

/* Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Merriweather:ital,wght@0,400;0,700;0,900;1,400&family=Inter:wght@400;500;600;700&display=swap');

/* CSS Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img, svg {
  max-width: 100%;
  display: block;
}

a {
  color: var(--color-primary);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

ul, ol {
  list-style: none;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  color: var(--color-text);
  font-weight: 700;
}

h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-4xl); }
h3 { font-size: var(--text-3xl); }
h4 { font-size: var(--text-2xl); }
h5 { font-size: var(--text-xl); }
h6 { font-size: var(--text-lg); }

p {
  margin-bottom: 1rem;
}

p:last-child {
  margin-bottom: 0;
}

/* Container */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-px);
}

@media (min-width: 768px) {
  .container {
    padding: 0 1.5rem;
  }
}

/* Section spacing */
.section {
  padding: var(--space-16) 0;
}

.section-lg {
  padding: var(--space-20) 0;
}

.section-xl {
  padding: var(--space-24) 0;
}

.section-alt {
  background-color: var(--color-bg-alt);
}

.section-dark {
  background-color: var(--color-bg-dark);
  color: var(--color-text-on-dark);
}

.section-dark h1,
.section-dark h2,
.section-dark h3,
.section-dark h4,
.section-dark h5,
.section-dark h6 {
  color: var(--color-text-on-dark);
}

/* Typography utilities */
.text-xs { font-size: var(--text-xs); }
.text-sm { font-size: var(--text-sm); }
.text-base { font-size: var(--text-base); }
.text-lg { font-size: var(--text-lg); }
.text-xl { font-size: var(--text-xl); }
.text-2xl { font-size: var(--text-2xl); }
.text-3xl { font-size: var(--text-3xl); }

.text-primary { color: var(--color-primary); }
.text-accent { color: var(--color-accent); }
.text-danger { color: var(--color-danger); font-weight: 700; }
.text-warning { color: var(--color-warning); }
.text-muted { color: var(--color-text-muted); }
.text-secondary { color: var(--color-text-secondary); }

.font-heading { font-family: var(--font-heading); }
.font-mono { font-family: var(--font-mono); }
.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.uppercase { text-transform: uppercase; letter-spacing: 0.05em; }

/* Layout utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-4 { gap: var(--space-4); }
.gap-6 { gap: var(--space-6); }
.gap-8 { gap: var(--space-8); }

.grid { display: grid; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 767px) {
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
}

@media (min-width: 768px) and (max-width: 1023px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

/* Margin/padding utilities */
.mt-4 { margin-top: var(--space-4); }
.mt-6 { margin-top: var(--space-6); }
.mt-8 { margin-top: var(--space-8); }
.mb-4 { margin-bottom: var(--space-4); }
.mb-6 { margin-bottom: var(--space-6); }
.mb-8 { margin-bottom: var(--space-8); }
.mb-12 { margin-bottom: var(--space-12); }

/* Skip to content */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  background: var(--color-primary);
  color: var(--color-text-on-dark);
  padding: var(--space-2) var(--space-4);
  z-index: 9999;
  font-size: var(--text-sm);
}

.skip-link:focus {
  top: var(--space-4);
}

/* Regulatory citation block */
.regulatory-citation {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  border-left: 4px solid var(--color-primary);
  padding: var(--space-4) var(--space-6);
  margin: var(--space-6) 0;
  background-color: var(--color-bg-alt);
  color: var(--color-text-secondary);
}

/* Penalty amount */
.penalty-amount {
  color: var(--color-danger);
  font-weight: 700;
  font-size: 1.1em;
}

/* CAS number */
.cas-number {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
}

/* Divider */
.divider {
  border: none;
  border-top: 1px solid var(--color-border);
  margin: var(--space-8) 0;
}

/* Section header */
.section-header {
  margin-bottom: var(--space-12);
}

.section-header h2 {
  margin-bottom: var(--space-4);
}

.section-header p {
  font-size: var(--text-lg);
  color: var(--color-text-secondary);
  max-width: 640px;
  margin: 0 auto;
}

/* Main content offset for fixed nav */
main {
  padding-top: 64px;
}

/* Responsive font sizes */
@media (max-width: 767px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.5rem; }

  .section { padding: var(--space-12) 0; }
  .section-lg { padding: var(--space-16) 0; }
  .section-xl { padding: var(--space-20) 0; }
}
