/* ============================================================
   Design tokens — Sum Science
   ============================================================ */
:root {
  --cream:      #FAFBF6;
  --navy:       #1C2440;
  --navy-soft:  #5C6688;

  --bio:        #2E9E5B;
  --bio-bg:     #E3F5E9;
  --phys:       #3457D5;
  --phys-bg:    #E5E9FB;
  --chem:       #E08A2B;
  --chem-bg:    #FBEEDD;
  --earth:      #B25F35;
  --earth-bg:   #F5E6DD;
  --psych:      #D65C79;
  --psych-bg:   #FBEAEE;

  --font-display: "Fredoka", sans-serif;
  --font-body: "Inter", sans-serif;

  --shadow: 0 2px 8px rgba(28,36,64,0.06), 0 12px 28px -12px rgba(28,36,64,0.18);
}

* { box-sizing: border-box; }

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; }
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--cream);
  color: var(--navy);
  font-family: var(--font-body);
  font-size: 17px;
  position: relative;
  overflow-x: hidden;
}

/* ============================================================
   Floating background icons
   ============================================================ */
.floating-icons {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

.float-icon {
  position: absolute;
  opacity: 0.16;
  animation-name: floatIcon;
  animation-timing-function: ease-in-out;
  animation-iteration-count: infinite;
  user-select: none;
}

@keyframes floatIcon {
  0%, 100% { transform: translateY(0) rotate(-4deg); }
  50%      { transform: translateY(calc(-1 * var(--drift))) rotate(4deg); }
}

/* ============================================================
   Hub layout
   ============================================================ */
.hub {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  padding: 48px 28px 56px;
}

.back-link {
  display: inline-block;
  margin-bottom: 32px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 14px;
  color: var(--navy-soft);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease, color 0.15s ease;
}
.back-link:hover { color: var(--navy); border-color: var(--navy-soft); }

.hero {
  text-align: center;
  margin-bottom: 56px;
}

.eyebrow {
  margin: 0 0 8px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--navy-soft);
}

.wordmark {
  margin: 0 0 18px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(52px, 9vw, 88px);
  letter-spacing: -0.01em;
  color: var(--navy);
  line-height: 1.1;
}

.tagline {
  margin: 0 auto;
  max-width: 50ch;
  font-size: 19px;
  line-height: 1.6;
  color: var(--navy-soft);
}

/* ============================================================
   Tiles
   ============================================================ */
.tiles {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.tile {
  display: flex;
  align-items: center;
  gap: 22px;
  background: #FFFFFF;
  border-radius: 22px;
  padding: 22px 26px;
  text-decoration: none;
  box-shadow: var(--shadow);
  border: 1px solid rgba(28,36,64,0.06);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 12px rgba(28,36,64,0.08), 0 18px 36px -14px rgba(28,36,64,0.26);
}

.tile-icon {
  flex-shrink: 0;
  width: 64px;
  height: 64px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
}

.tile-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.tile-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 21px;
  color: var(--navy);
}

.tile-subtitle {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--navy-soft);
}

.tile-arrow {
  flex-shrink: 0;
  font-size: 23px;
  font-weight: 600;
  transition: transform 0.18s ease;
}

.tile:hover .tile-arrow {
  transform: translateX(4px);
}

/* accent variants */
.tile-bio .tile-icon { background: var(--bio-bg); }
.tile-bio .tile-arrow { color: var(--bio); }

.tile-phys .tile-icon { background: var(--phys-bg); }
.tile-phys .tile-arrow { color: var(--phys); }

.tile-chem .tile-icon { background: var(--chem-bg); }
.tile-chem .tile-arrow { color: var(--chem); }

.tile-earth .tile-icon { background: var(--earth-bg); }
.tile-earth .tile-arrow { color: var(--earth); }

.tile-psych .tile-icon { background: var(--psych-bg); }
.tile-psych .tile-arrow { color: var(--psych); }

/* ============================================================
   Footer
   ============================================================ */
.hub-footer {
  margin-top: 48px;
  text-align: center;
  font-size: 15px;
  color: var(--navy-soft);
}

.contact-link {
  display: inline-block;
  margin-top: 12px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 15px;
  color: var(--chem);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.15s ease;
}
.contact-link:hover { border-color: var(--chem); }

@media (max-width: 480px) {
  .tile { padding: 18px; gap: 16px; }
  .tile-icon { width: 52px; height: 52px; font-size: 25px; border-radius: 14px; }
  .tile-title { font-size: 18px; }
  .tile-subtitle { font-size: 13.5px; }
}
