/* EarthandGalaxy shared styles: fonts, tokens, base, nav, badge, footer.
   Font file paths are relative to this file, so keep style.css in the same folder as the fonts. */

/* ---------- Fonts ---------- */
@font-face {
  font-family: Inter;
  src: url("Inter-VariableFont_opsz,wght.ttf");
  font-weight: 100 900;   /* variable font: tells the browser the real weight range */
  font-display: swap;
}

/* ---------- Tokens ---------- */
:root {
  --accent: aqua;
  --accent-hover: lime;
  --nav-h: 42px;
  --font-body: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Purple text outline (8-direction text-shadow), used on blog post titles */
  --purple: #800080;
  --outline-purple: 0.04em 0 var(--purple), 0 0.04em var(--purple), -0.04em 0 var(--purple), 0 -0.04em var(--purple),
    -0.04em -0.04em var(--purple), -0.04em 0.04em var(--purple), 0.04em -0.04em var(--purple), 0.04em 0.04em var(--purple);
}

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }
html, body { margin: 0; }
body {
  font-family: var(--font-body);
  background: black;
  color: white;
  cursor: url("Water_Normal1.png"), auto;
  overscroll-behavior: none;
}
a { text-decoration: none; }
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent-hover);
  outline-offset: 2px;
}

/* ---------- Nav ---------- */
.topnav {
  position: relative;
  z-index: 100;
  display: flex;
  flex-wrap: wrap;
  background-color: black;
  box-shadow: 0 1px 0 rgb(0 255 255 / 0.3);
}
.topnav a,
.topnav .icon {
  padding: calc((var(--nav-h) - 20px) / 2) 13px;
  font-size: 14px;
  line-height: 20px;
  color: var(--accent);
  text-align: center;
  box-shadow: inset 0 -2px 0 transparent;
  transition: color 0.15s, box-shadow 0.15s;
}
.topnav a[aria-current="page"] {
  color: var(--accent-hover);
  box-shadow: inset 0 -2px 0 var(--accent-hover);
}
.topnav .icon {
  display: none;
  margin-left: auto;
  border: 0;
  background: none;
  font: inherit;
  cursor: pointer;
}

/* Hamburger drawn in CSS so burger and X are the same size */
.bars,
.bars::before,
.bars::after {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 1px;
  background-color: currentColor;
  transition: transform 0.25s ease, top 0.25s ease, background-color 0.25s ease;
}
.bars { position: relative; }
.bars::before,
.bars::after { content: ""; position: absolute; left: 0; }
.bars::before { top: -7px; }
.bars::after  { top: 7px; }
.topnav.responsive .bars { background-color: transparent; }
.topnav.responsive .bars::before { top: 0; transform: rotate(45deg); }
.topnav.responsive .bars::after  { top: 0; transform: rotate(-45deg); }

.links,
.links-inner { display: contents; }

.topnav a:active,
.topnav .icon:active {
  color: var(--accent-hover);
  background-color: rgb(255 255 255 / 0.06);
}
@media (hover: hover) {
  .topnav a:hover,
  .topnav .icon:hover {
    color: var(--accent-hover);
    box-shadow: inset 0 -2px 0 var(--accent-hover);
  }
}

@media (max-width: 600px) {
  :root { --nav-h: 48px; }
  .topnav a { font-size: 16px; }
  .topnav .icon {
    display: flex;
    align-items: center;
    height: var(--nav-h);
    padding-block: 0;
  }
  .links {
    display: grid;
    grid-template-rows: 0fr;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: black;
    box-shadow: 0 8px 16px rgb(0 0 0 / 0.5);
    visibility: hidden;
    transition: grid-template-rows 0.25s ease, visibility 0s linear 0.25s;
  }
  .topnav.responsive .links {
    grid-template-rows: 1fr;
    visibility: visible;
    transition-delay: 0s;
  }
  .links-inner {
    display: block;
    min-height: 0;
    overflow: hidden;
  }
  .links a {
    display: block;
    box-sizing: border-box;
    width: 100%;
    text-align: center;
    border-top: 1px solid rgb(0 255 255 / 0.15);
  }
}

/* ---------- Badge ---------- */
.badge-link {
  display: block;
  width: 140px;
  max-width: 100%;
  margin: 1.5rem auto 0;
}
.badge {
  display: block;
  width: 140px;
  max-width: 100%;
  height: auto;
}

/* ---------- Footer ---------- */
.site-footer {
  max-width: 930px;
  margin: 0 auto;
  padding: 1.5rem 1rem 2.5rem;
  font-size: 0.85rem;
  text-align: center;
  color: rgb(255 255 255 / 0.6);
}
.site-footer a { color: var(--accent); }
.site-footer p { margin: 0 0 0.5em; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .topnav a, .topnav .icon, .links,
  .bars, .bars::before, .bars::after { transition: none; }
}
