/* ============================================================================
 * UTILITIES — CSP-safe classes replacing inline style="..." attributes
 * Auto-generated during Phase 3 CSP hardening.
 * ============================================================================ */

/* Text colors */
.u-text-muted { color: var(--muted); }
.u-text-accent { color: var(--accent); }
.u-text-inherit { color: inherit; }

/* Inline link styles (underline via border-bottom, inherit color) */
.u-link-inline {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
.u-link-inline-faded {
  /* Was: opacity: 0.7 compounded with footer's already-faded text (~49% effective)
     Now: inherit parent color; footer already applies its own fade. WCAG AA passes. */
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
.u-link-accent {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}
.u-border-none { border-bottom: none; }

/* Display / visibility */
.u-hidden { display: none; }

/* Text sizes */
.u-fs-11 { font-size: 11px; }
.u-fs-12 { font-size: 12px; }
.u-fs-13 { font-size: 13px; }
.u-fs-15 { font-size: 15px; }
.u-fs-095 { font-size: 0.95rem; }

/* Spacing (margins) */
.u-mt-6 { margin-top: 6px; }
.u-mt-8 { margin-top: 8px; }
.u-mt-10 { margin-top: 10px; }
.u-mt-12 { margin-top: 12px; }
.u-mt-20 { margin-top: 20px; }
.u-mt-125 { margin-top: 1.25rem; }
.u-mt-2 { margin-top: 2rem; }
.u-mb-6 { margin-bottom: 6px; }
.u-mb-8 { margin-bottom: 8px; }
.u-mb-10 { margin-bottom: 10px; }
.u-mb-12 { margin-bottom: 12px; }
.u-mb-14 { margin-bottom: 14px; }
.u-mb-16 { margin-bottom: 16px; }
.u-mb-17 { margin-bottom: 1.7rem; }
.u-mb-24 { margin-bottom: 24px; }
.u-my-0 { margin-top: 0; margin-bottom: 0; }

.u-signup-legal {
  margin-top: 1.25rem;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
  line-height: 1.5;
}

.u-panel-note {
  background: white;
  border: 1px solid #d0cab8;
  border-radius: 6px;
  padding: 16px;
  margin-bottom: 16px;
}
.u-panel-note-hidden {
  display: none;
  background: white;
  border: 1px solid #d0cab8;
  border-radius: 6px;
  padding: 16px;
  margin-bottom: 16px;
}
.u-panel-error {
  display: none;
  padding: 12px;
  background: #fdf4f0;
  border-left: 3px solid #c8553d;
  border-radius: 3px;
  margin-top: 10px;
  font-size: 13px;
  color: #c8553d;
}
.u-loading-state {
  padding: 24px;
  text-align: center;
  color: #6b6b66;
}

/* Debug-quote specific layouts */
.u-flex-row {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  flex-wrap: wrap;
}
.u-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}
.u-input-wide {
  flex: 1;
  min-width: 300px;
  padding: 10px;
  border: 1px solid #d0cab8;
  border-radius: 4px;
  font-family: 'SF Mono', monospace;
  font-size: 13px;
}
.u-flex-fixed-200 { flex: 0 0 200px; }
.u-w-100-max-400 { width: 100%; max-width: 400px; }

.u-section-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 8px;
  color: #6b6b66;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.u-code-mark {
  background: #ebe6db;
  padding: 2px 4px;
  border-radius: 2px;
}

.u-font-normal-style { font-style: normal; }

.u-muted-hint {
  font-size: 12px;
  color: #6b6b66;
  margin-top: 6px;
}
.u-progress-note {
  margin: 16px 0;
  font-size: 13px;
  color: #6b6b66;
}
.u-results-margin { margin-top: 20px; }

/* Finishes color swatches (index.html) */
.swatch-paper    { background: #f4f1ea; }
.swatch-ink      { background: #1c1c1a; }
.swatch-warm     { background: #c9a577; }
.swatch-cool     { background: #9aaab8; }
.swatch-neutral  { background: #c4c5c2; }
.swatch-terracotta { background: #d05a2a; }
.swatch-jade     { background: #1f4a3a; }
.swatch-sage     { background: #2d6450; }
.swatch-plum     { background: #4a3a7a; }
.swatch-slate    { background: #4a90b8; }
.swatch-graphite { background: #4d4d4a; }
.swatch-blush    { background: #d4a8b4; }

/* Consent-related copy in signup */
.u-consent-fine {
  color: var(--muted);
  font-size: 0.95rem;
}

/* Utility classes for JS-injected content (Phase 3 CSP hardening) */
.u-text-error { color: #c8553d; }
.u-text-success { color: #2d8a44; font-weight: 600; }
.u-text-success-italic { color: #2d8a44; font-style: italic; }
.u-text-right { text-align: right; }
.u-text-hint { font-size: 11px; color: #6b6b66; }
.u-text-hint-caps {
  font-size: 11px;
  color: #6b6b66;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.u-text-small-muted { color: #6b6b66; font-size: 12px; }
.u-text-tiny-muted { color: #6b6b66; font-size: 11px; }
.u-metric-value {
  font-size: 24px;
  font-weight: 600;
  margin-top: 4px;
}
.u-metric-value-success {
  font-size: 24px;
  font-weight: 600;
  margin-top: 4px;
  color: #2d8a44;
}
.u-metric-label {
  font-size: 14px;
  font-weight: 600;
  margin-top: 4px;
}
.u-card-white {
  background: white;
  border: 1px solid #d0cab8;
  border-radius: 6px;
  padding: 14px;
}
.u-toast-info {
  padding: 12px;
  color: #6b6b66;
  font-size: 13px;
}
.u-toast-error {
  background: #fdf4f0;
  border-left: 3px solid #c8553d;
  padding: 12px 16px;
  color: #c8553d;
  font-size: 13px;
}
.u-bg-warm { background: #fdf4f0; }
.u-code-block {
  padding: 10px 12px;
  background: #ebe6db;
  border-radius: 4px;
  font-size: 12px;
  margin-bottom: 12px;
  color: #333;
}

/* Skip link — visible on keyboard focus for accessibility */
.skip-link {
  position: absolute;
  left: -10000px;
  top: 8px;
  z-index: 1000;
  padding: 12px 20px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body, sans-serif);
  font-size: 14px;
  text-decoration: none;
  border-radius: 4px;
}
.skip-link:focus {
  left: 16px;
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
