/* ---- Original page (neon-3d-tubes-cursor-trail/style.css), unchanged ---- */

body, html, #app {
  margin: 0;
  width: 100%;
  height: 100%;
}

body {
  touch-action: none;
}

#app {
  height: 100%;
  font-family: "Montserrat", serif;
}

#app a {
  text-decoration: none;
  color: #fff;
}

.hero {
  position: relative;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

h1, h2, p {
  margin: 0;
  padding: 0;
  color: white;
  text-shadow: 0 0 20px rgba(13, 13, 18, 1);
  line-height: 100%;
  user-select: none;
}

h1 {
  font-size: 80px;
  font-weight: 700;
  text-transform: uppercase;
}

h2 {
  font-size: 60px;
  font-weight: 500;
  text-transform: uppercase;
}

#canvas {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  overflow: hidden;
}

/* ---- CampusTech additions ------------------------------------------------ */

/* Three solid colours for all text and the pull cord, per theme:
   --ink (headings, names, links), --muted (body copy, nav, mission, cord),
   --faint (credits, placeholder underlines). */
:root {
  --page: #0d0d12;
  --ink: #f4f4f6;
  --muted: #98989b;
  --faint: #5e5e62;
  --halo: rgba(13, 13, 18, 1); /* text shadow, keeps copy readable over the tubes */

  /* Pull cord (light mode switch): position and colour via its CSS variables. */
  --pullcord-top: 0px;
  --pullcord-right: clamp(1.25rem, 6vw, 5rem);
  --pullcord-z: 20;
  --pullcord-ink: var(--muted);
}

:root[data-theme="light"] {
  --page: #fff;
  --ink: #2d2e36;
  --muted: #818286;
  --faint: #bcbcbf;
  --halo: rgba(255, 255, 255, 1);
}

/* The page scrolls past the first screen, so vertical panning stays native;
   touches are still tracked through touch events in tubes.js. */
body {
  touch-action: pan-y;
  background: var(--page);
  font-family: "Montserrat", sans-serif;
  color: var(--ink);
  transition: background-color 0.35s ease, color 0.35s ease;
}

h1,
h2,
p {
  color: var(--ink);
  text-shadow: 0 0 20px var(--halo);
}

#app a {
  color: var(--ink);
}

/* #app stays exactly one screen: the tubes size their canvas to it. */
#app {
  height: 100vh;
  height: 100svh;
}

.bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  /* The bloom pass paints pure black; lighten lets the off-black page show
     through there while the bright tubes stay as they are. */
  mix-blend-mode: lighten;
}

#canvas {
  pointer-events: none;
}

/* ScrollSmoother pins the wrapper; keep it above the tubes and see-through. */
#smooth-wrapper {
  position: relative;
  z-index: 1;
}

/* Same size and weight as the link under the title on the original page. */
.tagline {
  font-size: clamp(13px, 3.8vw, 16px);
  font-weight: 500;
  line-height: 1.4;
  text-align: center;
  color: var(--muted);
}

/* The hero is one heading ("Campus Tech") for search engines and screen readers,
   drawn exactly like the original two lines: CAMPUS at 80px/700, TECH at 60px/500,
   10px apart. */
/* The heading and tagline sit in one block, centred on the page as a whole. */
.hero-text {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.hero h1 {
  text-align: center; /* TECH is a block inside the heading; centre it under CAMPUS */
}

/* Default (html.hero-left): all three lines start at CAMPUS's left edge; the block is
   still centred on the page. */
.hero-left .hero-text {
  align-items: flex-start;
}

.hero-left .hero h1,
.hero-left .hero .tagline {
  text-align: left;
}

/* Toggle between the two layouts, bottom left, only while the hero is on screen. */
.hero-align {
  position: fixed;
  left: 12px;
  bottom: 12px;
  z-index: 30;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--faint);
  cursor: pointer;
  transition: color 0.2s, opacity 0.3s;
}

.hero-align:hover,
.hero-align:focus-visible {
  color: var(--ink);
}

.nav-scrolled .hero-align {
  opacity: 0;
  pointer-events: none;
}

.hero-align .when-left,
.hero-left .hero-align .when-center {
  display: none;
}

.hero-left .hero-align .when-left {
  display: block;
}

.hero h1 .hero-sub {
  display: block;
  margin-top: 10px;
  font-weight: 500;
  line-height: 100%; /* its own, not the 80px inherited from CAMPUS */
}

/* Fluid type: every size scales smoothly with the screen between a minimum and
   its full size (the original 80px / 60px on wide screens), with no jumps. */
.hero h1 {
  font-size: clamp(42px, 15.5vw, 80px);
}

.hero h1 .hero-sub {
  font-size: clamp(32px, 11.6vw, 60px);
}

/* Pull cord: flat knob in the main text colour (white on dark, charcoal on
   light), no gradient, outline or shadow. The rope keeps the muted tone. */
#cord svg g[filter] {
  filter: none;
}

#cord svg circle {
  fill: var(--ink);
  stroke: none;
}

/* Nav: visible while the page is still, fades out while scrolling. */
.nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 16px;
  /* main.js sets --nav-left/--nav-right so the links are centred on the page when
     they fit and shifted just clear of the pull cord when they don't. */
  padding: 18px var(--nav-right, calc(var(--pullcord-right) + 2.5rem)) 18px var(--nav-left, 16px);
  font-family: "Montserrat", sans-serif;
  /* Grows slowly so the six links stay on one line for as long as possible;
     full size (13px, 0.12em) only on wide screens. */
  font-size: clamp(10px, calc(0.6vw + 7.5px), 13px);
  font-weight: 500;
  letter-spacing: clamp(0.03em, calc(0.16vw - 0.03em), 0.12em);
  text-transform: uppercase;
  text-shadow: 0 0 20px var(--halo);
  transform: translateY(-12px);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav.show {
  transform: none;
  opacity: 1;
  pointer-events: auto;
}

/* Past the first screen, content scrolls under the nav. With smooth scrolling
   the content layer is pinned to the viewport, so its top strip is masked out:
   headings vanish under the links while the tubes (a separate layer) stay
   visible. Without it (reduced motion, some touch setups) a band in the page
   colour is painted behind the nav instead. On the hero neither applies. */
/* Only while the nav is showing (it hides during scrolling): the strip under it
   fades in together with the nav, animated through two registered properties so
   the content's top edge never pops. */
@property --nav-fade {
  syntax: "<length>";
  inherits: true;
  initial-value: 0px;
}

@property --nav-soft {
  syntax: "<length>";
  inherits: true;
  initial-value: 0px;
}

html.pinned #smooth-wrapper {
  /* 0px / 0px = no mask at all; --nav-h is the nav's real height (main.js). */
  -webkit-mask-image: linear-gradient(to bottom, transparent var(--nav-fade), #000 calc(var(--nav-fade) + var(--nav-soft)));
  mask-image: linear-gradient(to bottom, transparent var(--nav-fade), #000 calc(var(--nav-fade) + var(--nav-soft)));
  transition: --nav-fade 0.3s ease, --nav-soft 0.3s ease;
}

html.pinned.nav-shown #smooth-wrapper {
  --nav-fade: var(--nav-h, 60px);
  --nav-soft: 32px;
}

.nav::before {
  content: "";
  position: absolute;
  inset: 0 0 -28px;
  z-index: -1;
  background: linear-gradient(to bottom, var(--page) calc(100% - 28px), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

html:not(.pinned) .nav.scrolled::before {
  opacity: 1;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  transition: color 0.2s;
}

.nav a:hover,
.nav a.active {
  color: var(--ink);
}

/* Links wrap onto a second line when they don't fit, so none is ever clipped. */
.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px clamp(12px, 3vw, 28px);
  justify-content: flex-start;
}

/* Medium screens: slightly tighter text so all six links usually fit on one line. */
@media (max-width: 900px) {
  .nav-links {
    column-gap: 16px;
  }
}

@media (max-width: 520px) {
  .nav-links {
    gap: 14px;
  }
}

@media (max-width: 360px) {
  .nav-links {
    gap: 6px 9px;
  }
}

/* Sections: plain text over the tubes, one screen each. */
.sections {
  position: relative;
}

.sections section {
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 80px 16px;
  box-sizing: border-box;
  text-align: center;
}

.sections h2 {
  font-size: clamp(40px, 9vw, 60px);
  margin-bottom: 10px;
}

.sections p,
.sections li {
  font-size: clamp(16px, 2.4vw, 20px);
  line-height: 1.5;
  color: var(--muted);
  text-shadow: 0 0 20px var(--halo);
  overflow-wrap: anywhere;
}

.sections ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}

.sections li b,
.sections li > a {
  font-weight: 700;
  color: var(--ink);
  margin-right: 12px;
}

.sections a {
  color: var(--ink);
  text-underline-offset: 4px;
}

/* Small heading inside a section (e.g. Past: Products / Presidents). */
.sections .label {
  margin-top: 12px;
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.sections .note {
  font-size: 14px;
}

/* Team is stacked on every screen (name above role) so every name shares the same
   centre line. */
#team li > b,
#team li > a {
  display: block;
  width: fit-content;
  margin: 0 auto;
}

/* From 560px wide, people sit side by side in fixed-width columns: as many per
   row as fit (2 on large phones and small tablets, 3 on tablets, 4 on laptops and
   up, capped at 4), and the last row stays centred. Below 560px: one column. */
@media (min-width: 560px) {
  #team ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 28px 40px;
    max-width: 1000px; /* 4 x 220px + 3 x 40px */
  }

  #team li {
    width: 220px;
  }
}

/* A name that links to a profile (LinkedIn): same weight and colour as the other
   names, with only a faint underline as the hint; it firms up on hover. */
.sections a.person {
  text-decoration: underline;
  text-decoration-color: var(--faint);
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
  transition: text-decoration-color 0.2s;
}

.sections a.person:hover,
.sections a.person:focus-visible {
  text-decoration-color: currentColor;
}

/* Contact: a row of brand icons. Live links in the muted tone (ink on hover);
   accounts that don't exist yet are faint and not clickable. */
.socials {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 22px;
  margin-top: 6px;
}

.socials a,
.socials .soon {
  display: inline-flex;
  width: 24px;
  height: 24px;
}

.socials svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.sections .socials a {
  color: var(--muted);
  transition: color 0.2s, transform 0.2s;
}

.sections .socials a:hover,
.sections .socials a:focus-visible {
  color: var(--ink);
  transform: translateY(-2px);
}

.sections .socials a.soon {
  color: var(--faint);
}

.sections .socials a.soon:hover,
.sections .socials a.soon:focus-visible {
  color: var(--muted);
}

/* Xiaohongshu's mark is a wordmark; drawn as its app icon: a rounded square with
   the wordmark knocked out in the page colour, so it matches the other icons. */
.socials .knockout {
  fill: var(--page);
}

/* Phones: keep all seven icons on one line. */
@media (max-width: 400px) {
  .socials {
    gap: 14px;
  }

  .socials a,
  .socials .soon {
    width: 22px;
    height: 22px;
  }
}

/* Narrow screens: tighter sections, product names on their own line. */
@media (max-width: 520px) {
  .sections section {
    padding: 72px 20px;
  }

  .sections li b,
  .sections li > a {
    display: block;
    margin-right: 0;
  }
}

/* Open seat link ("Apply now"): dashed underline in the link's own colour. */
.sections a.dashed {
  text-decoration: underline dashed;
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
}

/* Placeholders: a faint dashed underline so they are easy to spot and replace. */
.ph {
  text-decoration: underline dashed var(--faint);
  text-underline-offset: 5px;
}

/* ---- Light mode (pulled cord) -------------------------------------------- */

/* Light mode: the tubes' layer is removed (display: none also pauses their
   renderer) and the dither trail takes over. */
.trail {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: 0;
  pointer-events: none;
  display: none;
}

:root[data-theme="light"] .trail {
  display: block;
}

:root[data-theme="light"] .bg {
  display: none;
}

/* Static stand-in when the effect cannot run or motion is reduced. */
body.no-tubes {
  background:
    radial-gradient(60vw 50vh at 25% 25%, rgba(249, 103, 251, 0.22), transparent 70%),
    radial-gradient(50vw 50vh at 75% 35%, rgba(105, 88, 213, 0.28), transparent 70%),
    radial-gradient(60vw 40vh at 50% 85%, rgba(83, 188, 40, 0.16), transparent 70%), var(--page);
  background-attachment: fixed;
}

body.no-tubes .bg {
  display: none;
}

/* ---- Link preview (hover on an outbound link) ----------------------------- */

.preview {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 30;
  width: 320px;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--faint);
  border-radius: 10px;
  overflow: hidden;
  background: var(--page);
  pointer-events: none;
  opacity: 0;
  scale: 0.96;
  transition: opacity 0.18s ease, scale 0.18s ease;
  will-change: transform;
}

.preview.show {
  opacity: 1;
  scale: 1;
}

.preview img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

/* ---- Sub pages (past.html) ------------------------------------------------ */

/* No hero on sub pages: the first section starts right away. */
.subpage .sections section:first-child {
  padding-top: 120px;
}

/* ---- Reading pages (privacy, terms, articles) ------------------------------ */

.sections section.prose {
  display: block;
  max-width: 680px;
  margin: 0 auto;
  padding: 120px 20px 96px;
  text-align: left;
}

.prose h1 {
  font-size: clamp(32px, 6vw, 48px);
  line-height: 1.15;
  text-transform: none;
  margin-bottom: 12px;
}

.prose h2 {
  font-size: clamp(20px, 3vw, 24px);
  font-weight: 700;
  text-transform: none;
  line-height: 1.3;
  margin: 36px 0 10px;
}

.sections .prose p,
.sections .prose li {
  font-size: clamp(15px, 4.2vw, 17px);
  line-height: 1.7;
  margin: 0 0 14px;
  text-align: left;
}

.sections .prose ul,
.sections .prose ol {
  display: block;
  margin: 0 0 14px;
  padding-left: 22px;
  list-style: disc;
}

.sections .prose ol {
  list-style: decimal;
}

.prose .meta {
  font-size: 14px;
  color: var(--faint);
}

.prose .crumbs {
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.prose .crumbs a {
  color: var(--muted);
  text-decoration: none;
}

.prose .cards {
  display: grid;
  gap: 22px;
  margin-top: 24px;
}

.prose .cards h2 {
  margin: 0 0 4px;
}

.prose .cards h2 a {
  text-decoration: none;
}

.prose .cards h2 a:hover {
  text-decoration: underline;
}

.prose dt {
  font-weight: 700;
  color: var(--ink);
  margin-top: 16px;
}

.prose dd {
  margin: 4px 0 0;
  color: var(--muted);
  line-height: 1.7;
}


/* The original effect makes headings and paragraphs unselectable; reading pages
   should allow copying text. */
.prose,
.prose * {
  user-select: text;
}

/* ---- Footer: legal links, disclaimer and credits at the very end of every page ---- */

.site-footer {
  position: relative;
  max-width: 720px;
  margin: 0 auto;
  padding: 28px 20px 32px;
  text-align: center;
  border-top: 1px solid color-mix(in srgb, var(--faint) 35%, transparent);
}

.site-footer p {
  margin: 0 0 6px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--faint);
  text-shadow: none;
  user-select: text;
}

.site-footer a {
  color: var(--muted);
  text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus-visible {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}

