/* Washington Baltimore Spotters Group
   Working theme: Clear Skies Club
   Clean community resource. Aviation-adjacent, not airline-marketing glossy.
   Palette and the masthead logo (images/8d32.jpg) are fixed:
   background #F7F9FC, surfaces white, text #1A2332, muted #5B6777,
   primary navy #0B3D91, accent sky #2F80C1, borders #D8DEE8.
   Rollback stylesheets (unchanged):
   css/2col_leftNav.css
   css/3col_rightNav.css
*/

:root {
  --bg: #F7F9FC;
  --surface: #ffffff;
  --text: #1A2332;
  --muted: #5B6777;
  --primary: #0B3D91;
  --primary-dark: #082f70;
  --accent: #2F80C1;
  --border: #D8DEE8;
  --tint: #E8F2FB;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(26, 35, 50, 0.05), 0 10px 28px rgba(11, 61, 145, 0.06);
  --max: 1120px;
  --font: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --focus: 3px solid var(--accent);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--accent);
  text-underline-offset: 0.16em;
}

a:hover {
  color: var(--primary);
}

:focus-visible {
  outline: var(--focus);
  outline-offset: 2px;
}

::selection {
  background: #d6e6f7;
  color: var(--text);
}

h1, h2, h3, h4, h5, h6 {
  line-height: 1.25;
  font-weight: 700;
}

p {
  margin: 0 0 0.85rem;
}

/* ----- Masthead ----- */

.site-header {
  position: relative;
  background: var(--surface);
  border-bottom: 3px solid var(--primary);
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  transform: translateY(-160%);
  background: var(--primary);
  color: #fff;
  padding: 0.45rem 0.75rem;
  border-radius: 8px;
  z-index: 30;
  text-decoration: none;
  font-weight: 700;
}

.skip-link:focus {
  transform: none;
}

.site-header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.95rem 1.25rem 1rem;
  display: flex;
  align-items: center;
  gap: 1.25rem 1.5rem;
}

.logo-link {
  flex: 0 0 auto;
  line-height: 0;
  border-radius: 4px;
}

.logo-link img {
  display: block;
  width: auto;
  height: auto;
  max-height: 120px;
}

.header-main {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem 0.75rem;
}

.header-main h1 {
  flex: 1 1 14rem;
  margin: 0;
  color: var(--primary);
  font-size: clamp(1.2rem, 2.1vw, 1.7rem);
  letter-spacing: -0.02em;
}

.nav-toggle-input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  border: 0;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 0.45rem;
  margin-left: auto;
  padding: 0.4rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--primary);
  font: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  display: block;
  width: 1rem;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  content: "";
}

.nav-toggle-bars {
  position: relative;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  position: absolute;
  left: 0;
}

.nav-toggle-bars::before { top: -5px; }
.nav-toggle-bars::after { top: 5px; }

.nav-toggle-input:focus-visible + .nav-toggle {
  outline: var(--focus);
  outline-offset: 2px;
}

.nav-toggle-input:checked + .nav-toggle {
  background: var(--tint);
}

.site-nav {
  flex: 1 0 100%;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a {
  display: inline-block;
  padding: 0.38rem 0.8rem;
  border-radius: 999px;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
}

.site-nav a:hover {
  background: var(--tint);
  color: var(--primary);
}

.site-nav a[aria-current="page"] {
  background: var(--primary);
  color: #fff;
}

.site-nav a[aria-current="page"]:hover {
  color: #fff;
  background: var(--primary-dark);
}

@media (min-width: 761px) {
  .nav-toggle-input {
    display: none;
  }
}

@media (max-width: 760px) {
  .site-header-inner {
    align-items: flex-start;
  }

  .logo-link img {
    max-height: 92px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
  }

  .nav-toggle-input:checked ~ .site-nav {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    gap: 0;
    border: 1px solid var(--border);
    border-radius: 10px;
    overflow: hidden;
    background: var(--surface);
  }

  .site-nav a {
    display: block;
    border-radius: 0;
    border-bottom: 1px solid var(--border);
    padding: 0.7rem 0.9rem;
  }

  .site-nav li:last-child a {
    border-bottom: 0;
  }
}

@media (max-width: 560px) {
  .site-header-inner {
    flex-direction: column;
  }
}

/* ----- Page layout ----- */

.layout {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2.75rem;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 1.35rem;
  align-items: start;
}

.layout-single {
  grid-template-columns: minmax(0, 1fr);
}

main {
  min-width: 0;
}

@media (max-width: 860px) {
  .layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

.feature,
.story {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.25rem 1.35rem 1.15rem;
  margin: 0 0 1rem;
}

.feature table h3 {
  margin: 0.35rem 0;
  font-size: 0.98rem;
  color: var(--primary);
}

.feature > h3,
.story > h3 {
  margin: 0 0 0.75rem;
  color: var(--primary);
  font-size: 1.35rem;
  letter-spacing: -0.02em;
}

.feature h5,
.story h5,
h5 {
  margin: 1.05rem 0 0.3rem;
  color: var(--primary);
  font-size: 1.02rem;
}

.feature ul,
.story ul {
  margin: 0.35rem 0 0.85rem;
  padding-left: 1.2rem;
}

.feature li,
.story li {
  margin: 0.35rem 0;
}

.style2,
.style10 {
  font-size: inherit;
}

center {
  display: block;
  text-align: center;
}

/* ----- Homepage resource cards ----- */

.section-label {
  margin: 0.35rem 0 0.65rem;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.resource-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.85rem;
  margin-bottom: 1rem;
}

.resource-card {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  min-height: 9.5rem;
  padding: 1rem 1.05rem 0.95rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 4px solid var(--primary);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  color: inherit;
  text-decoration: none;
}

.resource-card:hover {
  border-color: var(--accent);
  border-top-color: var(--accent);
  color: inherit;
}

.resource-card .code {
  color: var(--primary);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.resource-card .name {
  color: var(--text);
  font-weight: 600;
}

.resource-card .go {
  margin-top: auto;
  padding-top: 0.65rem;
  color: var(--accent);
  font-size: 0.92rem;
  font-weight: 700;
}

@media (max-width: 720px) {
  .resource-grid {
    grid-template-columns: 1fr;
  }

  .resource-card {
    min-height: 0;
  }
}

/* ----- Airport spotting cards ----- */

.airport {
  scroll-margin-top: 1rem;
}

.airport-overview {
  display: block;
  width: 100%;
  height: auto;
  margin: 0.15rem 0 1rem;
  border-radius: 8px;
}

.airport-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.15rem 1.25rem;
  align-items: start;
}

.airport-copy p:last-child {
  margin-bottom: 0;
}

.airport-docs {
  display: flex;
  gap: 0.75rem;
}

.doc-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  width: 158px;
  color: var(--primary);
  font-size: 0.92rem;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
}

.doc-card img {
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
}

.doc-card small {
  color: var(--muted);
  font-weight: 600;
}

.doc-card:hover {
  color: var(--accent);
}

@media (max-width: 800px) {
  .airport-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .airport-docs {
    flex-wrap: wrap;
  }
}

/* ----- About gallery ----- */

.about-gallery {
  display: grid;
  grid-template-columns: minmax(140px, 240px) minmax(0, 1fr) minmax(140px, 220px);
  gap: 1rem 1.15rem;
  align-items: start;
}

.about-gallery img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.about-gallery p {
  margin: 0;
}

.about-gallery .span-rest {
  grid-column: 2 / span 2;
}

@media (max-width: 760px) {
  .about-gallery {
    grid-template-columns: minmax(0, 1fr);
  }

  .about-gallery .span-rest {
    grid-column: auto;
  }
}

.link-banner img {
  display: block;
  max-width: min(100%, 480px);
  height: auto;
  margin: 0.35rem 0 1rem;
  border: 1px solid var(--border);
  border-radius: 6px;
}

textarea,
input[type="text"],
input[type="email"] {
  font: inherit;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.55rem 0.7rem;
  width: min(100%, 40rem);
}

textarea {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.88rem;
  min-height: 5.5rem;
}

input[type="submit"] {
  font: inherit;
  font-weight: 700;
  color: #fff;
  background: var(--primary);
  border: 0;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  cursor: pointer;
}

input[type="submit"]:hover {
  background: var(--primary-dark);
}

/* Link directories that are still tables (content preserved). */
table.link-directory {
  width: 100%;
  border-collapse: collapse;
}

table.link-directory td {
  padding: 0.6rem 0.75rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

table.link-directory tr:hover td {
  background: #f4f8fc;
}

table.link-directory td:first-child {
  font-weight: 700;
  width: 40%;
}

form table {
  border-collapse: collapse;
}

form table td {
  padding: 0.35rem 0.6rem 0.35rem 0;
  vertical-align: middle;
}

/* ----- Sidebar ----- */

.sidebar {
  min-width: 0;
}

.sidebar .relatedLinks {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 0.9rem 0.95rem 0.45rem;
  margin: 0 0 0.85rem;
}

.sidebar .relatedLinks h3 {
  margin: 0 0 0.45rem;
  color: var(--primary);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.sidebar .relatedLinks ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar .relatedLinks li {
  margin: 0;
  border-top: 1px solid var(--border);
}

.sidebar .relatedLinks a {
  display: block;
  padding: 0.45rem 0.1rem;
  color: var(--text);
  text-decoration: none;
  font-size: 0.95rem;
}

.sidebar .relatedLinks a:hover {
  color: var(--accent);
}

/* ----- Footer ----- */

.site-footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  color: var(--muted);
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 1.4rem 1.25rem 2rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 1.1rem;
}

.footer-links a {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--accent);
}

.copyright {
  margin: 0.7rem 0 0;
  font-size: 0.92rem;
}

.footer-split {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(200px, 0.7fr);
  gap: 1.25rem 1.75rem;
  align-items: start;
  margin-top: 1.15rem;
  padding-top: 1.15rem;
  border-top: 1px solid var(--border);
}

.disclaimer {
  list-style: none;
  margin: 0;
  padding: 0;
}

.disclaimer li {
  margin: 0 0 0.5rem;
  color: var(--muted);
  font-size: 0.92rem;
}

.social-links {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.55rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.social-links a {
  font-weight: 700;
  text-decoration: none;
}

.social-links img {
  display: block;
  width: 40px;
  height: 40px;
}

@media (max-width: 700px) {
  .footer-split {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
