/**
 * BluePages civic theme tokens.
 * Page canvas matches the home and portal white theme in
 * static/css/ui11-home-portal-theme.css. Header and footer stay navy.
 * --theme-cream is light ink on that navy chrome (logo and footer links),
 * not the page background.
 */
:root {
  /* Locked civic palette */
  --theme-prussian: #0B2545;
  --theme-oxford: #13315C;
  --theme-yale: #134074;
  --theme-powder: #8DA9C4;
  --theme-cream: #EEF4ED;

  /* Same tokens as ui11-home-portal-theme.css. Do not add new hues. */
  --home-page-bg: #f4f6f9;
  --home-surface: #ffffff;
  --home-navy: #0b2545;
  --home-blue: #134074;
  --home-blue-hover: #0b2545;
  --home-muted: #5c6b7a;
  --home-line: #e3e8ef;
  --home-line-strong: #c9d4e1;
  --home-shadow: 0 1px 2px rgba(11, 37, 69, 0.06), 0 4px 14px rgba(11, 37, 69, 0.08);
  --home-shadow-hover: 0 2px 4px rgba(11, 37, 69, 0.08), 0 8px 22px rgba(11, 37, 69, 0.12);
  --home-radius: 12px;

  /* Prussian: header / footer / offer rail */
  --theme-header: var(--home-navy);
  --theme-footer: var(--home-navy);
  --theme-offer-rail: var(--home-navy);

  /* Navy headings, muted secondary text */
  --theme-heading: var(--home-navy);
  --theme-text: var(--home-navy);
  --theme-text-muted: var(--home-muted);

  /* Yale: buttons / sponsored badges */
  --theme-accent: var(--home-blue);
  --theme-accent-hover: var(--home-blue-hover);
  --theme-accent-contrast: #ffffff;
  --theme-accent-rgb: 19, 64, 116;
  --theme-sponsored: var(--home-blue);

  /* Powder stays the nav ink on navy. Cards use the home line and shadow. */
  --theme-nav: var(--theme-powder);
  --theme-chip: var(--home-surface);
  --theme-border: var(--home-line);
  --theme-line-strong: var(--home-line-strong);
  --theme-shadow: var(--home-shadow);

  /* Cool gray page, white cards */
  --theme-bg: var(--home-page-bg);
  --theme-surface: var(--home-surface);

  /* Status only (not brand) */
  --theme-success: #1f7a4d;
  --theme-error: #b42318;

  /* Convenience aliases (sites can use either) */
  --bg: var(--theme-bg);
  --surface: var(--theme-surface);
  --border: var(--theme-border);
  --text: var(--theme-text);
  --text-muted: var(--theme-text-muted);
  --accent: var(--theme-accent);
  --accent-hover: var(--theme-accent-hover);
  --success: var(--theme-success);

  /* Layout */
  --theme-max-width: 1100px;
  --theme-gutter: 1.5rem;
  --theme-radius: 8px;
  --theme-font: "DM Sans", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--theme-font);
  background: var(--theme-bg);
  color: var(--theme-text);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--theme-heading);
}

a {
  color: var(--theme-accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.32rem 0.7rem;
  border-radius: var(--theme-radius);
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  border: none;
  font-size: 0.875rem;
  font-family: inherit;
  transition: background 0.15s, color 0.15s;
}

.btn-primary {
  background: var(--theme-accent);
  color: var(--theme-surface);
}

.btn-primary:hover {
  background: var(--theme-accent-hover);
}

.btn-secondary {
  background: var(--theme-surface);
  color: var(--theme-text);
  border: 1px solid var(--theme-line-strong, var(--theme-border));
}

.btn-secondary:hover {
  border-color: var(--theme-accent);
  color: var(--theme-accent);
}

/* Form inputs */
input[type="text"],
input[type="search"],
input[type="email"],
input[type="url"],
textarea {
  padding: 0.6rem 0.9rem;
  border: 1px solid var(--theme-line-strong, var(--theme-border));
  border-radius: var(--theme-radius);
  background: var(--theme-surface);
  color: var(--theme-text);
  font-size: 1rem;
  font-family: inherit;
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--theme-accent);
}

/* Prose for markdown / long content */
.theme-prose {
  max-width: 65ch;
  color: var(--theme-text-muted);
}

.theme-prose h1,
.theme-prose h2,
.theme-prose h3 {
  color: var(--theme-heading);
  margin-top: 1.5em;
  margin-bottom: 0.5em;
}

.theme-prose h1 { font-size: 1.5rem; }
.theme-prose h2 { font-size: 1.25rem; }
.theme-prose h3 { font-size: 1.1rem; }

.theme-prose p {
  margin-bottom: 0.75rem;
}

.theme-prose ul,
.theme-prose ol {
  margin-bottom: 0.75rem;
  padding-left: 1.5rem;
}

.theme-prose li {
  margin-bottom: 0.25rem;
}

.theme-prose strong {
  color: var(--theme-text);
}

.theme-prose a {
  color: var(--theme-accent);
}

.theme-prose code {
  background: var(--theme-surface);
  padding: 0.15em 0.4em;
  border-radius: 4px;
  font-size: 0.9em;
}
