/* ---------------------------------------------------------------------
   Stanford Quantum Computing Association — design tokens & base styles
   ------------------------------------------------------------------- */

:root {
  --navy-950: #0a0f1c;
  --navy-900: #0f1830;
  --navy-800: #16213f;
  --navy-line: #29365c;

  --paper: #faf9f6;
  --paper-alt: #f1efe8;
  --ink: #14181f;
  --ink-soft: #525c6e;
  --line: #e3e0d7;

  --red: #a80c30;
  --red-dark: #7e0924;
  --cyan: #8fd9ff;

  --font-serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-sans: "IBM Plex Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;

  --container: 1120px;
  --radius: 10px;
  --nav-height: 68px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a {
  color: var(--red);
  text-decoration: none;
}
a:hover { text-decoration: underline; }

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 600;
  line-height: 1.15;
  margin: 0 0 0.5em;
  color: var(--ink);
}

h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); font-weight: 700; }
h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--red);
  margin: 0 0 0.9em;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

section { padding: 88px 0; }
@media (max-width: 720px) {
  section { padding: 56px 0; }
}

.section--alt { background: var(--paper-alt); }
.section--navy {
  background: var(--navy-950);
  color: #eef0f4;
}
.section--navy h2, .section--navy h3 { color: #fff; }
.section--navy p { color: #c3c9d6; }

.section-head {
  max-width: 640px;
  margin: 0 0 3rem;
}
.section-head.center { margin-inline: auto; text-align: center; }

.rule {
  width: 48px;
  height: 3px;
  background: var(--red);
  border: none;
  margin: 0 0 1.5rem;
}
.section-head.center .rule { margin-inline: auto; }

.lede {
  font-size: 1.1rem;
  color: var(--ink-soft);
}

/* Buttons ------------------------------------------------------------ */

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-family: var(--font-sans);
  font-weight: 500;
  font-size: 0.95rem;
  padding: 0.75em 1.5em;
  border-radius: 7px;
  background: var(--red);
  color: #fff;
  border: 1px solid var(--red);
  text-decoration: none;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.button:hover { background: var(--red-dark); border-color: var(--red-dark); text-decoration: none; }

.button--ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255,255,255,0.35);
}
.button--ghost:hover { background: rgba(255,255,255,0.08); border-color: rgba(255,255,255,0.6); }

.button--outline {
  background: transparent;
  color: var(--red);
  border-color: var(--red);
}
.button--outline:hover { background: var(--red); color: #fff; }

.button--small { padding: 0.5em 1.1em; font-size: 0.85rem; }

/* Nav ------------------------------------------------------------------ */

.site-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  background: rgba(10, 15, 28, 0.86);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.site-nav.is-scrolled {
  border-bottom-color: var(--navy-line);
  background: rgba(10, 15, 28, 0.97);
}

.site-nav__inner {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-nav__brand { display: flex; align-items: center; }
.site-nav__brand img { height: 28px; width: auto; }

.site-nav__menu {
  display: flex;
  align-items: center;
  gap: 2rem;
}
.site-nav__menu ul {
  display: flex;
  gap: 1.75rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.site-nav__menu a {
  color: #d6dae4;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
}
.site-nav__menu a:hover,
.site-nav__menu a.is-active {
  color: #fff;
}
.site-nav__menu a.is-active { border-bottom: 2px solid var(--red); padding-bottom: 4px; }

.site-nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px; height: 32px;
  background: none; border: none; cursor: pointer;
}
.site-nav__toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: #fff;
}

@media (max-width: 860px) {
  .site-nav__toggle { display: flex; }
  .site-nav__menu {
    position: absolute;
    top: var(--nav-height);
    left: 0; right: 0;
    background: var(--navy-950);
    border-bottom: 1px solid var(--navy-line);
    flex-direction: column;
    align-items: flex-start;
    padding: 1.25rem 24px 1.75rem;
    gap: 1.25rem;
    display: none;
  }
  .site-nav__menu.is-open { display: flex; }
  .site-nav__menu ul {
    flex-direction: column;
    gap: 1.1rem;
    width: 100%;
  }
}

/* Footer --------------------------------------------------------------- */

.site-footer {
  background: var(--navy-950);
  color: #aab2c3;
  padding: 56px 0 40px;
}
.site-footer__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
  text-align: center;
}
.site-footer__mark { margin: 0 auto 1rem; opacity: 0.85; }
.site-footer__tagline {
  font-family: var(--font-serif);
  color: #e2e6ee;
  font-size: 1.05rem;
  max-width: 420px;
  margin: 0 auto 1.5rem;
}
.site-footer__links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}
.site-footer__links a { color: #c7cddb; font-size: 0.9rem; }
.site-footer__links a:hover { color: #fff; }
.site-footer__meta { font-size: 0.82rem; color: #6f7995; }
.site-footer__meta a { color: #6f7995; }
.site-footer__meta a:hover { color: #aab2c3; }

/* Hero ------------------------------------------------------------------ */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  /* original: radial-gradient(ellipse 900px 600px at 50% 15%, rgba(45, 90, 150, 0.28), transparent 60%), var(--navy-950); */
  background:
    linear-gradient(to bottom, rgba(0, 10, 66, 0.8) 0%, rgba(0, 77, 125, 0.8) 100%),
    var(--navy-950);
}

.hero canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: calc(var(--nav-height) + 24px) 24px 40px;
  max-width: 760px;
}

.hero__mark {
  height: 42px;
  margin: 0 auto 2rem;
  opacity: 0.95;
}

.hero h1 {
  color: #fff;
  font-size: clamp(2.3rem, 5.4vw, 3.75rem);
  margin-bottom: 0.6em;
}
.hero h1 em {
  font-style: normal;
  color: var(--cyan);
}

.hero p {
  color: #b9c1d3;
  font-size: 1.15rem;
  max-width: 560px;
  margin: 0 auto 2.2rem;
}

.hero__actions {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* original: pill-shaped mouse-wheel cue
.hero__scroll-cue {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
  width: 20px;
  height: 32px;
  border: 1.5px solid rgba(255,255,255,0.35);
  border-radius: 12px;
}
.hero__scroll-cue::before {
  content: "";
  position: absolute;
  top: 6px; left: 50%;
  width: 3px; height: 6px;
  margin-left: -1.5px;
  background: rgba(255,255,255,0.7);
  border-radius: 2px;
  animation: scroll-cue 1.8s ease-in-out infinite;
}
@keyframes scroll-cue {
  0% { opacity: 1; transform: translateY(0); }
  70% { opacity: 0; transform: translateY(10px); }
  100% { opacity: 0; }
}
*/

.hero__scroll-cue {
  position: absolute;
  bottom: 40px;
  left: 50%;
  z-index: 2;
  display: inline-block;
  width: 20px;
  height: 20px;
  border-right: 2px solid #fff;
  border-bottom: 2px solid #fff;
  border-bottom-right-radius: 2px;
  transform: translateX(-50%) rotate(45deg);
  animation-duration: 2s;
  animation-name: scroll-cue-fade;
  animation-iteration-count: infinite;
  animation-timing-function: linear;
}
@keyframes scroll-cue-fade {
  0% { opacity: 0; }
  50% { opacity: 1; }
  100% { opacity: 0; }
}

/* Pillars (Provide / Prepare / Produce) -------------------------------- */

.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  margin-top: 3rem;
}
@media (max-width: 780px) {
  .pillars { grid-template-columns: 1fr; gap: 2.25rem; }
}
.pillar { border-top: 2px solid var(--line); padding-top: 1.5rem; }
.pillar .eyebrow { margin-bottom: 0.6em; }
.pillar p { color: var(--ink-soft); margin-bottom: 0; }

/* Circle grid (What to Expect) ------------------------------------------ */

.circle-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2.25rem 1.75rem;
  margin-top: 3rem;
}

.circle-item {
  text-align: center;
  flex: 0 0 calc((100% - 3 * 1.75rem) / 4);
}
@media (max-width: 900px) {
  .circle-item { flex-basis: calc((100% - 1.75rem) / 2); }
}
@media (max-width: 520px) {
  .circle-item { flex-basis: 100%; }
}
.circle-item__badge {
  width: 64px;
  height: 64px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.circle-item__badge::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--red);
}
.circle-item h3 {
  font-size: 1.02rem;
  margin-bottom: 0.4em;
}
.circle-item p {
  color: var(--ink-soft);
  font-size: 0.92rem;
  margin: 0;
}

/* Event cards (shared: home teaser + events page) ----------------------- */

.event-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
  margin-top: 2.5rem;
}
@media (max-width: 900px) {
  .event-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 620px) {
  .event-grid { grid-template-columns: 1fr; }
}

.event-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.event-card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: var(--paper-alt);
  overflow: hidden;
}
.event-card__media img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.event-card__date {
  position: absolute;
  top: 12px; left: 12px;
  background: var(--navy-950);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  padding: 0.35em 0.65em;
  border-radius: 5px;
}
.event-card__body { padding: 1.35rem 1.4rem 1.5rem; }
.event-card__meta {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--red);
  margin-bottom: 0.5em;
}
.event-card h3 { font-size: 1.1rem; margin-bottom: 0.4em; }
.event-card p { color: var(--ink-soft); font-size: 0.95rem; margin-bottom: 0; }

.section-foot { text-align: center; margin-top: 3rem; }

/* About page ------------------------------------------------------------- */

.page-header {
  background: var(--navy-950);
  color: #fff;
  padding: calc(var(--nav-height) + 64px) 0 64px;
  text-align: center;
}
.page-header .eyebrow { color: var(--cyan); }
.page-header h1 { color: #fff; }
.page-header p { color: #b9c1d3; max-width: 560px; margin: 0 auto; }

.team-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 2.5rem 1.75rem;
  margin-top: 2.5rem;
}
@media (max-width: 900px) { .team-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px) { .team-grid { grid-template-columns: repeat(2, 1fr); } }

.team-card { text-align: center; }
.team-card__photo {
  width: 128px; height: 128px;
  border-radius: 50%;
  overflow: hidden;
  margin: 0 auto 1rem;
  border: 1px solid var(--line);
}
.team-card__photo img { width: 100%; height: 100%; object-fit: cover; }
.team-card h3 { font-size: 1rem; margin-bottom: 0.15em; }
.team-card .role {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--red);
  margin-bottom: 0.3em;
}
.team-card .major { color: var(--ink-soft); font-size: 0.85rem; margin: 0; }

.team-grid--members .team-card__photo { width: 96px; height: 96px; }

.team-empty {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  color: var(--ink-soft);
  margin-top: 2.5rem;
}

/* What We've Done -------------------------------------------------------- */

.history-year {
  padding: 56px 0;
  border-top: 1px solid var(--line);
}
.history-year:first-of-type { border-top: none; }

.history-year__head {
  display: flex;
  align-items: baseline;
  gap: 1.25rem;
  margin-bottom: 2.5rem;
}
.history-year__head h2 {
  font-size: clamp(2.2rem, 4vw, 3rem);
  color: var(--red);
  margin: 0;
}
.history-year__head .rule { margin: 0; flex: 1; height: 1px; background: var(--line); width: auto; }

.history-list {
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.history-item {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 1.25rem;
  background: #fff;
  padding: 1.25rem 1.4rem;
  align-items: center;
}
@media (max-width: 560px) {
  .history-item { grid-template-columns: 64px 1fr; }
}
.history-item__thumb {
  width: 96px; height: 72px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--paper-alt);
}
@media (max-width: 560px) {
  .history-item__thumb { width: 64px; height: 48px; }
}
.history-item__thumb img { width: 100%; height: 100%; object-fit: cover; }
.history-item h3 { font-size: 1rem; margin-bottom: 0.25em; }
.history-item p { color: var(--ink-soft); font-size: 0.92rem; margin: 0; }

/* Join page --------------------------------------------------------------- */

.join-panel {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
}
.join-panel .button { font-size: 1rem; padding: 0.85em 2em; margin-top: 0.5rem; }
.join-note {
  margin-top: 2.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.92rem;
}

/* Misc utility ------------------------------------------------------------ */

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
@media (max-width: 780px) {
  .two-col { grid-template-columns: 1fr; gap: 2rem; }
}
