html {
  background-color: #131518;
  font-size: 18px;
  height: 100%;
  margin: 0;
}

body {
  font-family: "Palatino Linotype", "Book Antiqua", Palatino, serif;
  font-size: 1.25rem;
  margin: 0;
  padding: 1rem 0 3rem 0;
  background: url("../img/My_Tartan_Tile.png?v=1");
  color: #eee;
  line-height: 1.6;
  min-height: 100vh;
}

/* --------------------------------------------------
   TYPOGRAPHY
-------------------------------------------------- */

h1, h2, h3, h4 {
  margin: 0 auto 0.75em auto;
  max-width: 95%;
}

h1 { font-size: 1.8rem; color: #eee; }
h2 { font-size: 1.2rem; color: #eee; }
h3 { font-size: 1.0rem; color: #ddd; }
h4 { font-size: 0.75rem; color: #ddd; }

h2, h3, h4 {
  text-transform: uppercase;
}

h2:first-letter,
h3:first-letter,
h4:first-letter {
  font-size: 1.3em;
}

p, a {
  max-width: 90%;
  margin: 0 auto 1em auto;
  padding-bottom: 0.5em;
  font-size: 1rem;
}

a {
  color: rgba(41,137,216,1);
  text-decoration: none;
  font-size: 0.9rem;
}

a:hover {
  text-decoration: underline;
}

ul {
  max-width: 85%;
  margin: 0 auto 1em auto;
  padding-left: 1.25em;
  font-size: 0.95rem;
}

ol {
  max-width: 85%;
  margin: 0 auto 1em auto;
  padding-left: 1.25em;
  font-size: 0.95rem;
}

li {
  margin-bottom: 0.75em;
}

/* --------------------------------------------------
   LAYOUT
-------------------------------------------------- */

/* Fluid, centered container */
.centerAllContent {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Hexgrid panel */
.centerBody {
  background: #131518 url("../img/hexgrid.png") repeat;
  /*box-shadow: 0 0 2px 1px #202429;*/
  border-radius: 12px;
}

/* Optional centered callout block */
.centered {
  max-width: 75%;
  margin: 1.5rem auto;
  text-align: center;
  font-size: 0.9rem;
  background-color: rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 1rem;
}

.math {
  max-width: 75%;
  margin: 0 2rem 1rem 0;
  padding: 0.75rem;
  
  text-align: center;
  font-size: 0.9rem;
  
  border-radius: 8px;
}

/* --------------------------------------------------
   HEADER
-------------------------------------------------- */

header {
  padding: 2rem 1rem 1rem 1rem;
  text-align: center;
}

header img {
  width: 100%;
  border-radius: 8px;
}

.splash {
    max-width:320px;
}

@media (min-width: 400px) {
    .splash {
        max-width:280px;
    }
}

/* --------------------------------------------------
   NAVIGATION
-------------------------------------------------- */

nav.primary ul {
  display: flex;
  gap: 0.25rem;
  list-style: none;
  margin: 0 auto;
  padding: 0;
}

nav.primary li {
  flex: 1;
  align-items: center;
  justify-content: center;
  padding: 0.25rem;
  margin-bottom: 0;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 0;
  transition: background 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

nav.primary a,
nav.primary a:hover,
nav.primary a:focus,
nav.primary a:active {
  text-decoration: none;
  font-size: 0.9rem;
  color: #eee;
}

nav.primary li:not(.active):hover {
  background: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
  
}

nav.primary li.active {
  background: rgba(255, 255, 255, 0.2);
  box-shadow: inset 0 0 0.75rem rgba(255, 255, 255, 0.25);
}

nav.primary li:first-child {
  border-radius: 0.5rem 0 0 0.5rem;
}

nav.primary li:last-child {
  border-radius: 0 0.5rem 0.5rem 0;
}




nav.primary li.domain-active {
  outline: 1px solid rgba(255, 255, 255, 0.25);
  outline-offset: -2px;
}

nav.breadcrumb {
    text-align:center;
}

nav.breadcrumb ul,
nav.breadcrumbs ul {
    margin: 0.25em auto;
    padding-left:0;
}

nav.breadcrumb li,
nav.breadcrumbs li {
    list-style: none;
    margin:0;
}

nav.breadcrumb a,
nav.breadcrumbs a {
    margin:0;
    padding:0;
    text-decoration: none;
    font-size: 0.8rem;
    color: #eee;
}

nav.breadcrumb a:focus,
nav.breadcrumbs a:focus {
  color: #fff;
  outline: none;
  text-decoration: none;
}

nav.breadcrumb a:hover,
nav.breadcrumbs a:hover {
  color: #e0c78a;
  outline: none;
  text-decoration: none;
}

nav.breadcrumb a::before,
nav.breadcrumbs a::before {
  content: "⮝" ;
}



/* Container */
.sectionnav {
  margin: 0.25rem 0;
  padding: 0 0.5rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
}

/* Toggle Button */
.sectionnav-toggle {
  display: inline-block;
  padding: 0.5rem 0;
  font-size: 0.95rem;
  font-weight: 500;
  color: #ccc;
  background: none;
  border: none;
  cursor: pointer;
  transition: color 0.2s ease;
  width: 100%;
}

.sectionnav-toggle:focus {
  color: #fff;
  outline: none;
}

.sectionnav-toggle:hover {
  color: #e0c78a;
  outline: none;
}

/* List Wrapper */
.sectionnav-list {
  margin-top: 1rem;
}

/* Grid */
.sectionnav-list .subnav {
  list-style: none;
  margin: 0 auto;
  padding: 0;
  display: grid;
  gap: 0.35rem 0.75rem;
  grid-template-columns: repeat(1, 1fr);
}

@media (min-width: 480px) {
  .sectionnav-list .subnav {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 768px) {
  .sectionnav-list .subnav {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .sectionnav-list .subnav {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* Links */
.sectionnav-list .subnav a {
  display: block;
  padding: 0.5rem 0.75rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 0.25rem;
  color: #ccc;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.sectionnav-list .subnav a:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.subnav li {
      margin-bottom: 0;
}

.sectionnav-toggle::before,
.sectionnav-toggle::after {
  content: "▾";
  opacity: 0.7;
  transition: transform 0.2s ease;
  font-size:1.25rem;
}

.sectionnav-toggle[aria-expanded="true"]::before,
.sectionnav-toggle[aria-expanded="true"]::after {
  content: " ▴";
}

nav button, nav li, nav a {
  user-select: none;
  -webkit-user-select: none; /* Safari */
  -ms-user-select: none;     /* Old Edge */
  -webkit-user-drag: none; /* Safari & WebKit */
  user-drag: none;         /* Standardized but not widely supported */
}


.bottom-nav {
    margin:0 1rem;
}

.bottom-nav,
.sibling-nav {
  display: flex;
}

.bottom-nav a,
.sibling-nav a {
    margin:0;
    padding:0;
    padding-right:0.25rem;
    text-decoration: none;
    font-size: 0.85rem;
    color: #eee;
}

.bottom-nav a:focus,
.sibling-nav a:focus {
  color: #fff;
  outline: none;
  text-decoration: none;
}

.bottom-nav a:hover,
.sibling-nav a:hover {
  color: #e0c78a;
  outline: none;
  text-decoration: none;
}

.bottom-nav .next-link,
.sibling-nav .next-link {
  margin-left: auto;
  text-align: right;
  padding-right:0;
  padding-left:0.25rem;
}


/* --------------------------------------------------
   MAIN CONTENT
-------------------------------------------------- */

main {
  padding: 1rem 0;
}

main > p {
  padding: 0 0.5rem 1rem;
}

main>section>section {
    margin-left:2rem;
}

strong {
    color: #c78ae0;
}

/* -----
   NEWS ARTICLES
----- */

.timestamp {
    font-size:0.7em;
}

.story {
    min-height:400px;
}

.story .image {
    float:left;
    width:300px;
    margin:0px 0px 0px 1em;
}

.story .image img {
    width:272px;
}

.example p {
    font-size:0.9em;
}

.fact {
    text-align:left;
}

/* --------------------------------------------------
   FOOTER
-------------------------------------------------- */

footer.legal {
  text-align: center;
  padding: 0;
  margin-top: 1rem;
  color: #eee;
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #131518;
  box-shadow: 0 -2px 8px 0 #909294;
}

footer.legal>p {
  padding: 0;
  margin: 0;
  max-width: 100%;
}

/* --------------------------------------------------
   UTILITY
-------------------------------------------------- */

.initialism {
    display: inline-block;
    color:#eee;
}
.initialism::first-letter {
    font-size:1.2rem;
    color:#75d5b9;
}

.asof {
  font-size:0.75rem;
}

.alert {
  color: #FFEB00;
}

#contact-form form {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;

  max-width: 600px;
  margin: 0 auto; /* centers the form */
  width: 80%;    /* ensures it scales on mobile */
  
  background: rgba(255, 255, 255, 0.1);
  border-radius: 0.5rem;
  padding:1rem;
}

#contact-form input,
#contact-form select,
#contact-form textarea,
#contact-form button {
  width: 90%;
}




.events-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.events-list li {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-light, #ddd);
  display: flex;
  flex-direction: column;
}

.events-list li span {
  font-weight: 600;
  color: var(--accent, #555);
  margin-bottom: 0.25rem;
}


.policy-table {
    margin: 0 auto;
    font-size: clamp(0.6rem, 2.0vw, 0.9rem);
}

.policy-table th {
    padding:0.1rem;
}

.policy-table td {
    text-align:center;
}

.policy-table td:first-of-type {
    text-align:left;
}

input[name="affiliation"],
input[name="supporting_document"] {
  display:none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.form-spacer {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.form-error {
  background: #ffe6e6;
  border-left: 4px solid #b00020;
  padding: 1rem;
  margin-bottom: 1.5rem;
  color: #b00020;
  font-size: 0.95rem;
}


/* --------------------------------------------------
    FORMULA
-------------------------------------------------- */

.math {
  text-decoration: none;
  color: #75d5b9;
  font-weight:500;
  border: #75d5b9 1px solid;
}

.centered .math {
    margin:0.5rem auto;
}

abbr[title] {
  text-decoration: none;
  border-bottom: none;
  color: #75d5b9;
  font-weight:500;
}

/* --------------------------------------------------
   RESPONSIVE TWEAKS
-------------------------------------------------- */

@media (max-width: 768px) {
  body {
    font-size: 1.1rem;
  }

  .centered {
    max-width: 90%;
  }
  
  main>section>section .centered,.math {
    margin: 0 2rem 1rem 0;
    padding: 0.75rem;
  }

}

@media (max-width: 480px) {
  h1 { font-size: 1.5rem; }
  h2 { font-size: 1.25rem; }
  h3 { font-size: 1.1rem; }
}

@media (max-width: 400px) {
    nav.primary ul {
        max-width:100%;
    }
    
    nav.primary a,
    nav.primary a:hover,
    nav.primary a:focus,
    nav.primary a:active {
        font-size: 0.75rem;
    }
    
    footer.legal>p {
        font-size:0.85rem;
    }
}