/* =========================================================
   ETHER — Engineering Team for High-Frequency Electronics and Radio
   Design tokens: oscilloscope / SDR-waterfall inspired
   ========================================================= */

:root {
  --bg: #0E1620;
  --panel: #16212E;
  --panel-raised: #1C2A39;
  --line: #2A3B4D;
  --accent: #0474C4;      /* signal blue — primary */
  --accent-dim: #035A98;
  --teal: #F2B84B;        /* amber — secondary, so it contrasts with the blue */
  --text: #E7EDF3;
  --text-muted: #A7B9C9;
  --on-accent: #FFFFFF;   /* text color drawn on top of an accent-filled button */

  --font-body: 'IBM Plex Sans', -apple-system, sans-serif;
  --font-mono: 'IBM Plex Mono', 'SFMono-Regular', monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  line-height: 1.6;
}

/* Remove Bootstrap's rounded corners everywhere — hard edges, like a chassis */
.btn, .card, .navbar, .form-control, .badge, img, .modal-content {
  border-radius: 0 !important;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dim); }

h1, h2, h3, h4 {
  font-family: var(--font-body);
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text);
}

/* "What we've been up to" style overview titles: brighter/bolder so they
   read clearly against the dark panel background. */
.card h3,
.project-card h3 {
  color: var(--text);
  font-weight: 700;
}

.mono {
  font-family: var(--font-mono);
  letter-spacing: 0.02em;
}

/* ---------- Trace lines: PCB-inspired section dividers ---------- */
.trace-divider {
  height: 1px;
  background: var(--line);
  position: relative;
  margin: 0;
}
.trace-divider::after {
  content: "";
  position: absolute;
  left: 2rem;
  top: -3px;
  width: 7px;
  height: 7px;
  background: var(--accent);
}

/* ---------- Navbar ---------- */
.navbar {
  background-color: var(--bg) !important;
  border-bottom: 1px solid var(--line);
  padding-top: 1rem;
  padding-bottom: 1rem;
}
.navbar-brand {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  color: var(--text) !important;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.navbar-brand .callsign {
  color: var(--accent);
}
.navbar-brand .brand-logo {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  display: block;
}
.nav-link {
  font-family: var(--font-body);
  color: var(--text-muted) !important;
  margin-left: 1.25rem;
  padding: 0.4rem 0 !important;
  border-bottom: 2px solid transparent;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.nav-link:hover,
.nav-link.active {
  color: var(--text) !important;
  border-bottom-color: var(--accent);
}
.navbar-toggler {
  border-color: var(--line) !important;
}
.navbar-toggler-icon {
  filter: invert(1);
}

/* ---------- Hero ---------- */
.hero {
  padding: 6rem 0 5rem;
  border-bottom: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}
.hero-callsign {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 1rem;
  letter-spacing: 0.08em;
  margin-bottom: 1rem;
}
.hero h1 {
  font-size: clamp(2.2rem, 4.5vw, 3.4rem);
  max-width: 26ch;
  margin-bottom: 1.25rem;
}
.hero p {
  color: var(--text-muted);
  font-size: 1.15rem;
}
.hero-photo {
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border: 1px solid var(--line);
}
.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
@media (max-width: 991px) {
  .hero-photo { margin-top: 2rem; max-width: 480px; }
}

/* Signature motion: a single frequency-sweep line under the hero */
.sweep-line {
  width: 100%;
  height: 2px;
  margin-top: 3rem;
  position: relative;
  background: var(--line);
  overflow: hidden;
}
.sweep-line::before {
  content: "";
  position: absolute;
  top: 0; left: -30%;
  width: 30%;
  height: 100%;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: sweep 4.5s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  .sweep-line::before { animation: none; left: 0; width: 100%; }
}
@keyframes sweep {
  0%   { left: -30%; }
  50%  { left: 100%; }
  100% { left: -30%; }
}

/* ---------- Section headings ---------- */
.section-label {
  font-family: var(--font-mono);
  color: var(--teal);
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
}
section {
  padding: 4.5rem 0;
}

/* ---------- Cards (activity / project highlights) ---------- */
.card {
  background-color: var(--panel);
  border: 1px solid var(--line);
  padding: 1.75rem;
  height: 100%;
  transition: border-color 0.15s ease;
}
.card:hover {
  border-color: var(--accent-dim);
}
/* When a .card is rendered as an <a> (whole card clickable), keep normal
   text colors instead of link-blue/underline, and show a pointer. */
a.card {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
a.card:hover {
  color: inherit;
}
a.card:hover .card-link {
  color: var(--accent-dim);
}
.card .freq-tag {
  font-family: var(--font-mono);
  color: var(--teal);
  font-size: 0.8rem;
  margin-bottom: 0.75rem;
  display: block;
}
.card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.6rem;
}
.card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 0;
}
.card .card-link {
  display: inline-block;
  margin-top: 1rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
}

/* ---------- Buttons ---------- */
.btn-signal {
  background-color: var(--accent);
  color: var(--on-accent);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  padding: 0.65rem 1.5rem;
  border: 1px solid var(--accent);
  transition: background-color 0.15s ease;
}
.btn-signal:hover {
  background-color: var(--accent-dim);
  border-color: var(--accent-dim);
  color: var(--on-accent);
}
.btn-outline-signal {
  background-color: transparent;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  padding: 0.65rem 1.5rem;
  border: 1px solid var(--line);
}
.btn-outline-signal:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* ---------- Footer ---------- */
footer {
  background-color: var(--panel);
  border-top: 1px solid var(--line);
  padding: 3rem 0 2rem;
  margin-top: 2rem;
}
footer .callsign-block {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
}
footer a {
  color: var(--text-muted);
}
footer a:hover {
  color: var(--accent);
}
footer .footer-heading {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-bottom: 0.9rem;
}
footer .copyright {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}

/* ---------- Member cards ---------- */
.member-card {
  background-color: var(--panel);
  border: 1px solid var(--line);
  transition: border-color 0.15s ease;
}
.member-card:hover {
  border-color: var(--accent-dim);
}
.member-photo {
  width: 100%;
  aspect-ratio: 1 / 1;
  background-color: var(--panel-raised);
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.member-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.member-photo .initials {
  font-family: var(--font-mono);
  font-size: 2.5rem;
  color: var(--accent-dim);
  letter-spacing: 0.05em;
}
.member-body {
  padding: 1.5rem;
}
.member-name-row {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.9rem;
}
.member-name-row h3 {
  font-size: 1.15rem;
  margin: 0;
}
.member-callsign {
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--accent);
  border-bottom: 1px dotted var(--accent-dim);
}
.member-role {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--teal);
  margin-bottom: 1rem;
}
.member-field {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text);
  margin-bottom: 0.7rem;
  line-height: 1.5;
}
.member-field .field-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  display: block;
  letter-spacing: 0.05em;
  margin-bottom: 0.2rem;
}
/* Inline variant: label and value on one line, e.g.
   "MEMBER SINCE  October 2025" instead of stacked. */
.member-field.inline {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.member-field.inline .field-label {
  display: inline;
  margin-bottom: 0;
}
.member-field a {
  color: var(--text);
}
.member-field a:hover {
  color: var(--accent);
}
.member-quote {
  border-left: 2px solid var(--accent-dim);
  padding-left: 0.9rem;
  margin-top: 1rem;
  font-size: 0.9rem;
  font-style: italic;
  color: var(--text);
}

/* ---------- Timeline (PCB trace styled) ---------- */
.timeline {
  position: relative;
  margin-top: 2rem;
  padding-left: 2rem;
}
.timeline::before {
  content: "";
  position: absolute;
  left: 5px;
  top: 6px;
  bottom: 6px;
  width: 1px;
  background: var(--line);
}
.timeline-item {
  position: relative;
  padding-bottom: 2.5rem;
}
.timeline-item:last-child {
  padding-bottom: 0;
}
.timeline-item::before {
  content: "";
  position: absolute;
  left: -2rem;
  top: 6px;
  width: 11px;
  height: 11px;
  background: var(--bg);
  border: 2px solid var(--accent);
}
.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
  margin-bottom: 0.4rem;
}
.timeline-item h3 {
  font-size: 1.1rem;
  margin-bottom: 0.4rem;
}
.timeline-item p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
}
.timeline-item a.timeline-link {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
}
.timeline-item a.timeline-link:hover {
  color: var(--accent-dim);
}

/* ---------- About page content blocks ---------- */
.about-lead {
  font-size: 1.2rem;
  color: var(--text);
}
.about-body {
  color: var(--text-muted);
}
.about-body p {
  margin-bottom: 1.25rem;
}
.about-body h3 {
  font-size: 1.05rem;
  margin: 2rem 0 0.75rem;
  color: var(--text);
}
.about-body h3:first-child {
  margin-top: 0;
}
/* A link that stays in the normal text color instead of orange, but keeps
   a subtle underline so it still reads as clickable. */
.plain-link {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-underline-offset: 3px;
}
.plain-link:hover {
  color: inherit;
  text-decoration-color: var(--text-muted);
}
.post-inline-images {
  margin: 1.75rem 0;
}
.post-inline-images img {
  width: 100%;
  height: auto;
  max-height: 480px;
  object-fit: cover;
  display: block;
  border: 1px solid var(--line);
  cursor: zoom-in;
}
.post-inline-images figcaption {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.6rem;
}

/* ---------- Activity feed / blog posts ---------- */
.activity-tabs {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}
.activity-tabs a {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
  border: 1px solid var(--line);
  padding: 0.5rem 1rem;
}
.activity-tabs a:hover {
  color: var(--text);
  border-color: var(--accent-dim);
}

.post {
  border: 1px solid var(--line);
  background-color: var(--panel);
  margin-bottom: 3rem;
  scroll-margin-top: 90px;
}
.post-header {
  padding: 2rem 2rem 1.5rem;
  border-bottom: 1px solid var(--line);
}
.post-tag {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  padding: 0.25rem 0.6rem;
  display: inline-block;
  margin-bottom: 1rem;
  border: 1px solid var(--teal);
  color: var(--teal);
}
.post-header h2 {
  font-size: 1.6rem;
  margin-bottom: 1rem;
}
.post-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}
.post-meta .meta-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  display: block;
  letter-spacing: 0.04em;
  margin-bottom: 0.2rem;
}
.post-meta .meta-value {
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}
.post-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 2px;
  background-color: var(--line);
}
.post-gallery img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}
.post-body {
  padding: 2rem;
  color: var(--text-muted);
}
.post-body p {
  margin-bottom: 1.1rem;
  max-width: 72ch;
}
.post-body p:last-child {
  margin-bottom: 0;
}
.post-equipment {
  font-size: 0.9rem;
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
}
.post-equipment .meta-label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
  display: block;
}
.post-equipment ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: 0;
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}
.post-equipment li {
  margin-bottom: 0.3rem;
}

/* ---------- Project overview cards (Activity index) ---------- */
.project-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 3.5rem;
}
@media (max-width: 900px) {
  .project-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .project-grid { grid-template-columns: 1fr; }
}
.project-card {
  background-color: var(--panel);
  border: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  transition: border-color 0.15s ease;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
.project-card:hover {
  border-color: var(--accent-dim);
  color: inherit;
}
.project-card h3 {
  color: var(--text);
}
.project-card .project-thumb {
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.project-card .project-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.project-card-body {
  padding: 1.4rem;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.project-card .post-tag {
  align-self: flex-start;
  margin-bottom: 0.9rem;
}
.project-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}
.project-card .project-date {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}
.project-card p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.1rem;
  flex: 1;
}
.project-card .card-link {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
}

/* ---------- Project detail page ---------- */
.detail-header {
  padding: 4rem 0 2.5rem;
  border-bottom: 1px solid var(--line);
}
.detail-header .back-link {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text-muted);
  display: inline-block;
  margin-bottom: 1.5rem;
}
.detail-header .back-link:hover {
  color: var(--accent);
}
.detail-header h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  max-width: 45ch;
  margin: 1rem 0 1.5rem;
}

.full-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 3px;
  background-color: var(--line);
  margin-bottom: 1.25rem;
}
.full-gallery img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  display: block;
  cursor: zoom-in;
}

/* ---------- Lightbox ---------- */
.lightbox-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(6, 10, 15, 0.92);
  z-index: 1050;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.lightbox-overlay.active {
  display: flex;
}
.lightbox-overlay img {
  max-width: 100%;
  max-height: 90vh;
  border: 1px solid var(--line);
}
.lightbox-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  font-family: var(--font-mono);
  color: var(--text);
  background: transparent;
  border: 1px solid var(--line);
  padding: 0.5rem 0.9rem;
  cursor: pointer;
  font-size: 0.85rem;
}
.lightbox-close:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.lightbox-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-family: var(--font-mono);
  font-size: 1.8rem;
  line-height: 1;
  color: var(--text);
  background: transparent;
  border: 1px solid var(--line);
  width: 48px;
  height: 48px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
}
.lightbox-nav:hover {
  border-color: var(--accent);
  color: var(--accent);
}
.lightbox-prev {
  left: 1.5rem;
}
.lightbox-next {
  right: 1.5rem;
}
.lightbox-counter {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-muted);
}
@media (max-width: 700px) {
  .lightbox-nav { width: 40px; height: 40px; font-size: 1.4rem; }
  .lightbox-prev { left: 0.5rem; }
  .lightbox-next { right: 0.5rem; }
}

/* ---------- Reading column width ---------- */
/* Container scales toward ~70% of viewport width on larger screens, i.e.
   about 15% margin on each side, instead of the old ~25%-per-side column.
   Text stays left-aligned. Capped on very wide/ultrawide monitors. */
@media (min-width: 992px) {
  .container {
    max-width: min(1720px, 70vw);
  }
}

/* ---------- Supporters page ---------- */
.supporter-logos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}
@media (max-width: 900px) {
  .supporter-logos { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
  .supporter-logos { grid-template-columns: 1fr; }
}
.supporter-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  padding: 1.25rem;
  transition: opacity 0.15s ease, transform 0.15s ease;
  /* No card/background — logos sit directly on the page. Some logos need
     different ink colors depending on the theme (e.g. light text that
     only reads on a dark page), so each such logo ships as two files —
     a "dark" variant and a "light" variant — and CSS below shows only
     the one that matches the current theme. */
}
.supporter-logo:hover {
  opacity: 0.85;
  transform: translateY(-2px);
  color: var(--text);
}
.supporter-logo img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}
/* Pages are always dark now, so only the dark-page variant of each logo is
   shown (the "-light" files stay in images/logos/sponsors/ but are unused). */
.supporter-logo .logo-light {
  display: none;
}
.supporter-logo .wordmark {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-align: center;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
}

.people-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}
@media (max-width: 700px) {
  .people-grid { grid-template-columns: 1fr; }
}
.people-card {
  display: block;
  background-color: var(--panel);
  border: 1px solid var(--line);
  padding: 1.5rem 1.75rem;
  transition: border-color 0.15s ease;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
.people-card:hover {
  border-color: var(--accent-dim);
  color: inherit;
}
.people-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.4rem;
}
.people-card .people-role {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 0.75rem;
}
.people-card .people-link {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent);
}
.people-card:hover .people-link {
  color: var(--accent-dim);
}

.thanks-list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}
.thanks-list li {
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
  color: var(--text-muted);
  font-size: 0.95rem;
}
.thanks-list li:last-child {
  border-bottom: none;
}
.thanks-list strong {
  color: var(--text);
  font-weight: 600;
}
.thanks-list a {
  font-family: var(--font-mono);
}

/* ---------- Utility ---------- */
.square-marker {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: var(--accent);
  margin-right: 0.6rem;
  vertical-align: middle;
}


/* Under-construction banner (home page) */
.construction-banner{background:var(--teal);color:#1a1200;text-align:center;padding:1.4rem 0;font-size:1.25rem;line-height:1.4;border-bottom:3px solid rgba(0,0,0,.25)}
.construction-banner strong{display:block;font-size:1.7rem;margin-bottom:.25rem}
@media(max-width:576px){.construction-banner strong{font-size:1.3rem}.construction-banner{font-size:1.05rem}}
