/* THEME: Colors, Typography, Components (no layout)
   =========================== */
/* Palette and tokens */
:root {
  /* Colors */
  --mo-blue: #04304B;
  --mo-blue-contrast: #FFFFFF;
  --mo-blue-light: #9BBCFF;

  --mo-red: #B4202E;
  --mo-red-contrast: #FFFFFF;

  --text: #000000;
  --muted-text: #333333;

  --link: #0033CC;
  --link-visited: #0033CC;
  --link-hover: #000000;

  --border: #dddddd;
  --border-strong: #000000;
  --divider: #cacaca;

  --bg: #FFFFFF;
  --bg-soft: #f9f9f9;
  --footer-bg: #f5f5f5;

  /* Typography */
  --ff-serif: 'Palatino Linotype', Palatino, Baskerville, 'Book Antiqua', Georgia, serif;
  --base-size: 100%; /* was 110% */
  --h1-size: 1.75em;
  --h2-size: 1.5em;
  --h3-size: 1.3em;
  --h4-size: 1.2em;

  /* Spacing and shape */
  --radius: 8px;
  --space-1: 6px;
  --space-2: 10px;
  --space-3: 12px;
  --space-4: 15px;
  --space-5: 20px;
  --container-max: 1200px;
}

/* Base / Global theme
   =================== */
html, body {
  color: var(--text);
  background: var(--bg);
  font-family: var(--ff-serif);
  font-size: var(--base-size);
}

img {
  max-width: 100%;
  height: auto;
  border: 0;
  vertical-align: bottom;
}

/* Links */
a:link {
  color: var(--link);
  text-decoration: none;
}
a:visited { color: var(--link-visited); }
a:hover, a:focus {
  color: var(--link-hover);
  text-decoration: underline;
}

/* Headings */
h1, h2, h3, h4, h5 {
  font-variant: small-caps;
  color: var(--mo-blue);
  margin: 0;
}
h1 {
  font-size: var(--h1-size);
  border-bottom: 2px solid var(--mo-blue);
  padding-bottom: var(--space-5);
}
h2 { font-size: var(--h2-size); margin-top: 30px; }
h3 { font-size: var(--h3-size); margin-top: 24px; }
h4 { font-size: var(--h4-size); margin-top: 24px; }

/* Paragraph rhythm */
p { margin: 12px 0; line-height: 1.55em; }
.top { margin-top: var(--space-1); }

/* Lists used inside content areas */
ul.content, ol.content {
  margin: 0 0 1em 1em;
  padding-left: 1em;
  list-style-type: square;
}

/* Gray divider */
hr.gray {
  background-color: var(--divider);
  border: 0;
  height: 1px;
}

/* Drop cap (large) */
span.dropcap {
  font-family: var(--ff-serif);
  float: left;
  font-size: 5.75em;
  margin: 0 10px 0 0;
  padding: 0 .1em 0 0;
  display: block;
  line-height: .775em;
  color: var(--text);
  border-right: 1px solid var(--border-strong);
}
span.caps { font-variant: small-caps; }

/* Small dropcap (used in footer text occasionally) */
.dropcap-small {
  font-family: var(--ff-serif);
  float: left;
  font-size: 1.6em;
  line-height: 1;
  margin: 0 4px 0 0;
  color: inherit;
}

/* Emphasis helpers */
strong.MissouriBlue { color: var(--mo-blue); }
strong.MissouriRed  { color: var(--mo-red); }

/* Content highlight boxes */
.MissouriRedbox {
  padding: var(--space-3);
  background-color: var(--mo-red);
  color: var(--mo-red-contrast);
  border: 1px solid var(--border-strong);
  margin: var(--space-3) 0 0 0;
}
.MissouriBluebox {
  padding: var(--space-3);
  background-color: var(--mo-blue);
  color: var(--mo-blue-contrast);
  border: 1px solid var(--mo-blue);
  margin: var(--space-3) 0 0 0;
}
.MissouriBluebox a {
  display: block;
  padding: 1px 6px;
  color: var(--mo-blue-light) !important;
}
.MissouriBluebox a:hover { text-decoration: none; }

/* Link list variant */
.linklist {
  margin: 1em 0;
  padding: 0;
  list-style-type: none;
}
.linklist a {
  display: block;
  padding: 1px 6px;
  color: var(--link);
  border: 1px solid #FFFFFF;
}
.linklist a:hover {
  border-color: var(--border-strong);
  text-decoration: none;
}

/* Tables (theme only, no layout sizing beyond width:100%) */
table {
  border: thin solid var(--divider);
  border-collapse: collapse;
  width: 100%;
}
th, td { padding: 6px 8px; }
th {
  text-align: left;
  background-color: var(--divider);
  color: var(--text);
}
td { border-bottom: thin solid var(--divider); }
td.rightborder { border-right: thin solid var(--divider); }
td.MissouriBluebox { font-weight: bold; font-size: 1.1em; }

/* Update markers */
.newupdate { font-weight: bold; font-style: italic; }
.newupdatestrike { font-weight: normal; font-style: italic; text-decoration: line-through; color: var(--mo-red); }
.update2010 { font-weight: bold; font-style: italic; color: #006600; }
.update2010strike { font-weight: normal; font-style: italic; text-decoration: line-through; color: #006600; }

/* Superscripts/subscripts */
.superscript { font-size: x-small; vertical-align: top; }
.subscript   { font-size: x-small; vertical-align: bottom; }

/* Header/Menubar skin (visuals only)
   =========================== */
#logodiv {
  border-bottom: 1px solid #cccccc;
  max-width: var(--container-max);
  margin: 0 auto;
  background-color: transparent;
  gap: 10px;
}
#menubar {
  background-color: var(--mo-blue);
  padding: 0;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Main content (background only; layout belongs elsewhere) */
#maincontent {
  background-color: #FFFFFF;
  padding: var(--space-5);
  overflow-wrap: anywhere;
}

/* Right/left widgets (visuals only) */
.widget-header {
  background-color: var(--mo-blue);
  color: var(--mo-blue-contrast);
  padding: 15px 20px;
  font-weight: bold;
  font-size: 1.1rem;
  font-variant: small-caps;
  border-radius: 6px 6px 0 0;
}

/* Footer theming (light blocks + dark copyright bar)
   =========================== */
/* Light 4-block section */
#site-footer {
  background: var(--footer-bg);
  color: var(--text);
  border-top: 0;
}
#site-footer .footer-title {
  margin: 0 0 10px 0;
  font-size: 1.05em;
  color: var(--mo-blue);
  font-variant: small-caps;
  border-bottom: 2px solid var(--mo-red);
  padding-bottom: 6px;
}
#site-footer .footer-links { list-style: none; margin: 0; padding: 0; }
#site-footer .footer-links li { margin: 6px 0; }
#site-footer .footer-contact { line-height: 1.2; margin: 0; }
#site-footer .footer-usage { margin: 0; line-height: 1.15; }
#site-footer .footer-usgenweb { line-height: 1.25; text-align: center; margin: 0; }
#site-footer .usgenweb-logo { display: block; margin: 0 auto 8px auto; height: auto; line-height: 1.2; }

/* Links inside footer (light area) */
#site-footer a { color: var(--link); }
#site-footer a:hover, #site-footer a:focus { color: var(--link-hover); text-decoration: underline; }

/* Blue accent bar across top of footer */
#site-footer .footer-accent {
  height: 6px;
  background: var(--mo-blue);
}

/* Dark copyright bar */
#site-footer #copyright.footer-copyright-dark {
  background: var(--mo-blue);
  color: #dfe7f3;
  text-align: center;
  padding: 18px 20px;
  border-top: 3px solid var(--mo-red);
  font-size: 0.85rem; /* small, readable */
  line-height: 1.4;
}
#site-footer #copyright.footer-copyright-dark a { color: var(--mo-blue-light); }
#site-footer #copyright.footer-copyright-dark a:hover,
#site-footer #copyright.footer-copyright-dark a:focus { color: var(--mo-blue-contrast); }

/* Keep the headline on one line (desktop); relax on tiny screens */
#site-footer #copyright .copyright-line.nowrap {
  white-space: nowrap;
  display: inline-block;
  margin: 0;
}
@media (max-width: 480px) {
  #site-footer #copyright .copyright-line.nowrap {
    white-space: normal;
  }
}

/* Breadcrumb (theme)
   =========================== */
#crumb, .crumb {
  font-weight: bold;
  margin-bottom: 16px;
  color: var(--muted-text);
}
#crumb a, #crumb a:visited, .crumb a, .crumb a:visited {
  font-weight: normal;
  color: #535FAC;
  text-decoration: none;
}
#crumb a:hover, #crumb a:active, #crumb a:focus,
.crumb a:hover, .crumb a:active, .crumb a:focus {
  font-weight: normal;
  color: var(--muted-text);
  text-decoration: underline;
}
#crumb a + a::before, .crumb a + a::before {
  content: "›";
  margin: 0 6px;
  color: #999;
}

/* Footer image float tweak (light area only)
   =========================== */
#site-footer .footer-usage-img { float: right; margin: 0 0 8px 12px; }
@media (max-width: 900px) {
  #site-footer .footer-usage-img { float: none; display: block; margin: 0 auto 10px auto; }
}
