/* Page-specific layouts (loaded after site.css) */

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 1000;
  padding: 10px 16px;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
}

.skip-link:focus {
  left: 12px;
  top: 12px;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

nav a[aria-current="page"] {
  border-bottom-color: var(--accent);
}

.nav-wrap {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  gap: 12px;
}

.nav-wrap .brand {
  color: #fff;
  font-size: 22px;
  font-weight: 800;
}

main section {
  max-width: 960px;
  margin: 0 auto;
}

main section.hub-section {
  max-width: 1100px;
}

.badge-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 24px 0;
}

.badge {
  background: var(--gray);
  color: var(--navy);
  font-weight: 700;
  font-size: 14px;
  padding: 10px 14px;
  border-left: 4px solid var(--accent);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 20px;
  margin: 24px 0 32px;
}

.stats-grid div {
  background: var(--gray);
  padding: 20px;
  text-align: center;
}

.stats-grid strong {
  display: block;
  font-size: 32px;
  color: var(--accent);
  font-weight: 800;
}

.stats-grid span {
  font-size: 14px;
  color: var(--text);
}

.awards-list,
.award-timeline {
  list-style: none;
  margin: 0;
  padding: 0;
}

.award-timeline li {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 18px;
  padding: 16px 0;
  border-bottom: 1px solid #e6e9ee;
}

.award-timeline .year {
  font-weight: 800;
  color: var(--accent);
  font-size: 18px;
}

.award-timeline .detail {
  font-size: 15px;
  color: var(--text);
}

.bio-card {
  background: #fff;
  border: 1px solid #e6e9ee;
  border-radius: 6px;
  padding: 24px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

.bio-card h3 {
  color: var(--navy);
  margin-bottom: 14px;
}

.bio-card p {
  margin-bottom: 12px;
}

.contact-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 50px 20px;
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 40px;
  align-items: start;
}

.contact-wrap img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 8px;
}

.contact-wrap--no-map {
  grid-template-columns: minmax(240px, 360px) 1fr;
}

.hub-section {
  max-width: 1100px;
  margin: 0 auto;
  padding: 20px 20px 60px;
  background: #fff;
}

.hub-section .services {
  margin-top: 8px;
}

.hub-section .lead,
.hub-section .section-title,
.hub-section .section-sub {
  max-width: none;
}

.related-links {
  list-style: none;
  margin: 0 0 28px;
  padding: 0;
  display: grid;
  gap: 10px;
}

.related-links a {
  color: var(--navy);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

.related-links a:hover,
.related-links a:focus-visible {
  border-bottom-color: var(--accent);
}

.contact-wrap h3 {
  color: var(--navy);
  margin-bottom: 12px;
}

.contact-wrap a {
  color: var(--navy);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.map-embed iframe {
  width: 100%;
  min-height: 320px;
  border: 0;
  border-radius: 8px;
}

.sitemap-grid {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 20px 60px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 28px;
}

.sitemap-col h2 {
  color: var(--navy);
  font-size: 18px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 3px solid var(--accent);
  display: inline-block;
}

.sitemap-col ul {
  list-style: none;
}

.sitemap-col li {
  margin: 8px 0;
  font-size: 14px;
}

.sitemap-col a {
  color: var(--navy);
}

.sitemap-col a:hover {
  color: var(--accent);
  text-decoration: underline;
}

.sitemap-col .sub {
  margin-left: 14px;
  color: #5a6472;
}

.lead {
  text-align: left;
  margin: 0 0 18px;
  color: #5a6472;
}

.nf {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 24px;
  min-height: 60vh;
}

.nf .code {
  font-size: 96px;
  line-height: 1;
  font-weight: 800;
  color: var(--navy);
}

.nf .rule {
  width: 64px;
  height: 4px;
  background: var(--accent);
  border: 0;
  margin: 22px auto 26px;
}

.nf h1 {
  font-size: 26px;
  color: var(--navy);
  margin-bottom: 14px;
}

.nf .muted {
  color: #7c869c;
  font-size: 14px;
}

.nf .links {
  margin-top: 30px;
  font-size: 14px;
}

.nf .links a {
  color: var(--navy);
  margin: 0 10px;
  border-bottom: 1px solid #cfd6e4;
}

.figure-block {
  margin: 36px 0 0;
  text-align: center;
}

.figure-block img {
  width: 100%;
  max-width: 900px;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
  margin: 0 auto;
}

.figure-block figcaption {
  margin-top: 12px;
  font-size: 14px;
  color: #5a6472;
  font-style: italic;
}

.content p,
.content li,
.award-timeline .detail {
  max-width: 42rem;
  line-height: 1.65;
}

.hero,
.page-hero {
  animation: hero-in 0.55s ease both;
}

@keyframes hero-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 20px 0 8px;
}

.contact-actions .btn { text-align: center; }

.contact-actions .btn-secondary {
  background: transparent;
  color: var(--navy);
  border: 2px solid var(--navy);
}

.contact-actions .btn-secondary:hover {
  background: var(--navy);
  color: #fff;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 4px;
  background: transparent;
  cursor: pointer;
  padding: 10px 9px;
  flex-direction: column;
  justify-content: space-between;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: #fff;
  border-radius: 1px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; order: 3; }
  .mabadge { order: 2; }

  header nav {
    order: 4;
    width: 100%;
    display: none;
    background: var(--navy-dark);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding: 8px 0 14px;
  }

  header nav.is-open { display: block; }

  header nav > ul {
    flex-direction: column;
    gap: 0;
    padding: 0 8px;
  }

  header nav > ul > li > a {
    display: block;
    padding: 12px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .dropdown {
    position: static;
    min-width: 0;
    width: 100%;
    box-shadow: none;
    border-radius: 0;
    background: rgba(255, 255, 255, 0.06);
    transform: none;
    margin: 0 0 6px;
  }

  li.has-dropdown.is-open > .dropdown {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .dropdown a { color: #e8edf7; padding: 10px 18px; }
  .dropdown a:hover { background: rgba(255, 255, 255, 0.08); }
}

@media (max-width: 800px) {
  .contact-wrap,
  .contact-wrap--no-map { grid-template-columns: 1fr; }
  .award-timeline li { grid-template-columns: 56px 1fr; }
  .nf .code { font-size: 72px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero,
  .page-hero { animation: none; }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
