@font-face {
  font-family: "Geospace Source Sans";
  src: url("/brand/source-sans-regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Geospace Source Sans";
  src: url("/brand/source-sans-semibold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #f7f9fa;
  --surface: #ffffff;
  --surface-muted: #f1f6f9;
  --ink: #1f2b33;
  --muted: #5d6b74;
  --line: #cedbe2;
  --geospace-blue: #488cca;
  --geospace-blue-deep: #21669d;
  --geospace-teal: #067f81;
  --geospace-red: #dd1f26;
  --focus: #06bab5;
  --shadow: 0 12px 30px rgba(31, 57, 73, 0.08);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 16px/1.55 "Geospace Source Sans", "Source Sans Pro", Arial, sans-serif;
}

a { color: var(--geospace-blue-deep); text-underline-offset: 0.16em; }
a:hover { color: var(--geospace-teal); }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

.site-shell { width: min(1040px, calc(100% - 40px)); margin: 0 auto; padding: 32px 0 72px; }

.site-header {
  position: relative;
  overflow: hidden;
  min-height: 112px;
  display: flex;
  align-items: center;
  gap: 28px;
  margin-bottom: 32px;
  padding: 25px 30px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.site-header::after {
  content: "";
  position: absolute;
  z-index: 0;
  inset: 0 0 0 auto;
  width: min(48%, 440px);
  opacity: 0.13;
  background: right center / cover no-repeat url("/brand/geospace-background.png");
  pointer-events: none;
}

.brand-mark, .brand-copy { position: relative; z-index: 1; }
.brand-mark { display: block; width: min(250px, 42vw); height: auto; }
.brand-copy { border-left: 1px solid var(--line); padding-left: 24px; }
.brand-copy h1, .article-card h1, h2 {
  margin: 0;
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 500;
  line-height: 1.17;
}
.brand-copy h1 {
  font-family: "Geospace Source Sans", "Source Sans Pro", Arial, sans-serif;
  font-size: clamp(1.55rem, 3vw, 2.05rem);
  font-weight: 600;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}
.product-label { margin: 4px 0 0; color: var(--muted); font-size: 0.96rem; letter-spacing: 0.02em; }

.search-panel { margin: 0 0 28px; }
.search-form { display: flex; gap: 10px; margin: 0; }
.search-form input, .search-form select {
  min-width: 0;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--surface);
  color: var(--ink);
  font: inherit;
  padding: 11px 14px;
}
.search-form input { flex: 1; }
.search-form select { flex: 0 1 150px; }
.search-form input::placeholder { color: #74828c; }

.button, button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  border: 1px solid var(--geospace-blue-deep);
  border-radius: 2px;
  background: var(--geospace-blue-deep);
  color: #fff;
  cursor: pointer;
  font: 600 1rem/1.2 inherit;
  padding: 10px 17px;
  text-decoration: none;
}
.button:hover, button:hover { background: var(--geospace-teal); border-color: var(--geospace-teal); color: #fff; }
.button.secondary { background: var(--surface); border-color: var(--geospace-blue); color: var(--geospace-blue-deep); }
.button.secondary:hover { background: var(--surface-muted); color: var(--geospace-teal); }

.search-help, .subtle, .meta { color: var(--muted); }
.search-help { margin: 10px 0 0; font-size: 0.93rem; }
.query-error { margin: 18px 0; padding: 11px 14px; border-left: 4px solid var(--geospace-red); background: #fff5f5; color: #67171b; }
.empty-state { margin: 24px 0; padding: 18px; border: 1px dashed var(--line); color: var(--muted); }

.section-heading { margin: 32px 0 12px; font-size: 1.45rem; }
.article-card {
  margin: 14px 0;
  padding: 23px 25px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--geospace-blue);
  box-shadow: 0 2px 10px rgba(31, 57, 73, 0.04);
}
.article-card.related { border-left-color: var(--geospace-teal); }
.article-card h2 { margin: 7px 0 8px; font-size: 1.5rem; }
.article-card h2 a { color: inherit; text-decoration-color: #aac7dd; }
.article-card h2 a:hover { color: var(--geospace-blue-deep); }
.article-card p { margin: 8px 0; }
.article-meta { font-size: 0.92rem; }
.summary { color: #30424d; }
.match-context { margin-top: 14px !important; padding: 12px 14px; background: var(--surface-muted); border-left: 3px solid var(--geospace-teal); }
.evidence { font-size: 0.93rem; }
.terms { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.term { border: 1px solid #bad0df; border-radius: 999px; color: #48616f; padding: 2px 9px; font-size: 0.82rem; }
.actions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 17px; margin-top: 18px; }
.pdf-link { font-weight: 600; }

.back-link { display: inline-block; margin: 0 0 22px; font-weight: 600; text-decoration: none; }
.article-card.single { margin-top: 0; border-left-color: var(--geospace-blue); }
.article-card h1 { margin: 9px 0 10px; font-size: clamp(1.9rem, 4vw, 2.55rem); }
.pdf-action { margin-top: 22px; }

.site-nav { display: flex; gap: 4px; margin: -16px 0 28px; border-bottom: 1px solid var(--line); }
.site-nav a { padding: 8px 12px 10px; color: var(--muted); font-weight: 600; text-decoration: none; }
.site-nav a:hover, .site-nav a.active { color: var(--geospace-blue-deep); }
.site-nav a.active { border-bottom: 3px solid var(--geospace-teal); }
.catalog-heading { margin: 0 0 22px; }
.catalog-heading h2 { font-size: clamp(2rem, 4vw, 2.7rem); }
.eyebrow { margin: 0 0 5px; color: var(--geospace-blue-deep); font-size: .9rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; }
.catalog-heading .subtle, .catalog-heading .meta { margin: 8px 0; }
.issue-year { margin: 0 0 30px; }
.issue-year > h2 { margin: 0 0 12px; color: var(--geospace-blue-deep); font-size: 1.35rem; }
.issue-year-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 10px; }
.issue-tile { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; min-height: 92px; padding: 16px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--geospace-blue); color: var(--ink); text-decoration: none; box-shadow: 0 2px 10px rgba(31, 57, 73, .04); }
.issue-tile:hover { border-color: var(--geospace-teal); color: var(--geospace-blue-deep); }
.issue-tile-number { color: var(--geospace-blue-deep); font-weight: 700; white-space: nowrap; }
.issue-tile-body { display: grid; gap: 7px; }
.issue-tile-theme { font-family: Georgia, "Times New Roman", serif; font-size: 1.08rem; line-height: 1.25; }
.issue-tile-meta { color: var(--muted); font-size: .88rem; }
.issue-heading { padding: 25px; background: var(--surface); border-left: 4px solid var(--geospace-blue); box-shadow: 0 2px 10px rgba(31, 57, 73, .04); }
.issue-heading .button { margin-top: 13px; }
.contents-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.contents-item { display: grid; grid-template-columns: 94px minmax(0, 1fr); gap: 22px; padding: 17px 0; border-bottom: 1px solid var(--line); }
.contents-pages { color: var(--muted); font-size: .93rem; font-weight: 600; }
.contents-title { color: var(--ink); font-family: Georgia, "Times New Roman", serif; font-size: 1.25rem; line-height: 1.25; text-decoration-color: #aac7dd; }
.contents-title:hover { color: var(--geospace-blue-deep); }
.review-note { display: block; margin-top: 7px; color: #7a4c00; font-size: .86rem; }
.directory-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.directory-item { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.directory-item:hover { border-color: var(--geospace-blue); color: var(--geospace-blue-deep); }

@media (max-width: 600px) {
  .site-shell { width: min(100% - 24px, 1040px); padding: 20px 0 48px; }
  .site-header { display: block; min-height: 0; margin-bottom: 23px; padding: 22px; }
  .site-header::after { display: none; }
  .brand-mark { width: min(228px, 100%); }
  .brand-copy { margin-top: 17px; padding: 15px 0 0; border-top: 1px solid var(--line); border-left: 0; }
  .search-form { display: block; }
  .search-form input, .search-form select, .search-form button { width: 100%; margin-top: 9px; }
  .search-form input { margin-top: 0; }
  .article-card { padding: 19px; }
  .article-card h2 { font-size: 1.32rem; }
  .actions { align-items: stretch; }
  .actions .button { width: 100%; }
  .site-nav { margin: -9px 0 22px; }
  .issue-card { display: block; padding: 19px; }
  .issue-actions { margin-top: 15px; align-items: stretch; }
  .issue-actions .button { width: 100%; }
  .contents-item { grid-template-columns: 1fr; gap: 4px; }
  .directory-list { grid-template-columns: 1fr; }
}
