/* ============================================
   Laura Rackley — Fuel Cell Engineer
   Palette: deep petrol ink + electric teal + warm paper
   Fonts: Fraunces (headings) + Sora (body)
   ============================================ */

:root {
  --ink: #0F212B;
  --ink-soft: #3C5561;
  --dark: #0C1E28;
  --dark-2: #122B37;
  --paper: #F7F8F7;
  --tint: #EAF1EE;
  --accent: #2DD4BF;
  --accent-deep: #0C6B5E;
  --accent-soft: #A8DCCF;
  --radius: 14px;
  --shadow: 0 8px 28px rgba(12, 30, 40, 0.10);
  --shadow-hover: 0 14px 40px rgba(12, 30, 40, 0.16);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Sora', 'Segoe UI', Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--paper);
  overflow-x: clip;
}

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

.container {
  width: min(1140px, 100% - 48px);
  margin-inline: auto;
}

/* ---------- Typography ---------- */

h1, h2, h3 {
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.01em;
}

.section { padding: clamp(72px, 9vw, 120px) 0; }

.section-kicker {
  font-family: 'Sora', sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: var(--accent-deep);
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(1.9rem, 4.2vw, 3rem);
  margin-bottom: 28px;
}

.section-dark { background: var(--dark); color: #EAF3F0; }
.section-dark .section-kicker { color: var(--accent); }
.section-dark .section-title { color: #FFFFFF; }

.section-tint { background: var(--tint); }

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

.btn {
  display: inline-block;
  font-family: 'Sora', sans-serif;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 14px 30px;
  border-radius: 999px;
  text-decoration: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
  cursor: pointer;
  border: none;
}

.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-hover); }

.btn-light { background: #FFFFFF; color: var(--ink); }
.btn-light:hover { background: var(--accent); color: var(--ink); }

.btn-ghost {
  background: transparent;
  color: #FFFFFF;
  border: 1.5px solid rgba(255, 255, 255, 0.65);
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.btn-accent { background: var(--accent-deep); color: #FFFFFF; }
.btn-accent:hover { background: var(--accent); color: var(--ink); }

/* ---------- Header ---------- */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  transition: background 0.3s ease, box-shadow 0.3s ease;
}

.site-header.scrolled {
  background: rgba(12, 30, 40, 0.94);
  backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
}

.header-inner {
  width: min(1240px, 100% - 40px);
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #FFFFFF;
  min-width: 0;
  overflow: hidden;
}

.brand-mark {
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--accent);
  color: var(--ink);
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 600;
  font-size: 1.05rem;
}

.brand-name {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.2rem;
  font-weight: 500;
  white-space: nowrap;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.4);
}

.site-header.scrolled .brand-name { text-shadow: none; }

.main-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.main-nav a {
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
  transition: color 0.2s ease;
}

.main-nav a:hover { color: var(--accent); }

.main-nav .nav-cta {
  border: 1.5px solid rgba(255, 255, 255, 0.6);
  border-radius: 999px;
  padding: 9px 22px;
}
.main-nav .nav-cta:hover { border-color: var(--accent); }

.nav-toggle {
  display: none;
  position: relative;
  z-index: 60;
  flex-shrink: 0;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: rgba(12, 30, 40, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 10px;
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: #FFFFFF;
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle.open .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle.open .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

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

.hero {
  position: relative;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
  display: flex;
  align-items: center;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(7, 20, 27, 0.62) 0%, rgba(7, 20, 27, 0.45) 45%, rgba(7, 20, 27, 0.78) 100%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 2;
  width: min(1140px, 100% - 48px);
  margin-inline: auto;
  padding-top: 60px;
}

.hero-kicker {
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.24em;
  margin-bottom: 20px;
}

.hero-title {
  font-size: clamp(2.9rem, 8.5vw, 6.2rem);
  font-weight: 500;
  color: #FFFFFF;
  text-shadow: 0 2px 24px rgba(0, 0, 0, 0.45);
  margin-bottom: 24px;
}

.hero-title em {
  font-style: italic;
  font-weight: 400;
  color: var(--accent);
}

.hero-sub {
  max-width: 560px;
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(1rem, 1.6vw, 1.18rem);
  margin-bottom: 36px;
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.45);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 34px;
  left: 50%;
  transform: translateX(-50%);
  width: 26px;
  height: 44px;
  border: 2px solid rgba(255, 255, 255, 0.65);
  border-radius: 999px;
  z-index: 2;
}

.hero-scroll-hint::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 50%;
  width: 4px;
  height: 9px;
  margin-left: -2px;
  border-radius: 2px;
  background: var(--accent);
  animation: scrollHint 1.8s ease-in-out infinite;
}

@keyframes scrollHint {
  0%, 100% { transform: translateY(0); opacity: 1; }
  60% { transform: translateY(14px); opacity: 0.3; }
}

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

.about-grid {
  display: grid;
  grid-template-columns: minmax(300px, 420px) 1fr;
  gap: clamp(36px, 6vw, 80px);
  align-items: start;
}

.about-photo {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-hover);
}

.about-photo img { width: 100%; }

.about-photo-tag {
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: rgba(12, 30, 40, 0.88);
  backdrop-filter: blur(6px);
  border-left: 3px solid var(--accent);
  border-radius: 10px;
  padding: 12px 16px;
}

.tag-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--accent);
}

.tag-value { color: #FFFFFF; font-size: 0.92rem; font-weight: 600; }

.about-copy p { margin-bottom: 18px; color: var(--ink-soft); }

.about-facts {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 34px;
}

.about-facts li {
  background: var(--tint);
  border-radius: var(--radius);
  padding: 20px 18px;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--ink-soft);
  line-height: 1.45;
}

.about-facts span {
  display: block;
  font-family: 'Fraunces', Georgia, serif;
  font-size: 2rem;
  font-weight: 600;
  color: var(--accent-deep);
  margin-bottom: 6px;
}

/* ---------- Expertise ---------- */

.section-dark .section-title { margin-bottom: 48px; }

.expertise-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.expertise-card {
  background: var(--dark-2);
  border: 1px solid rgba(45, 212, 191, 0.16);
  border-radius: var(--radius);
  padding: 32px 30px;
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.expertise-card:hover {
  transform: translateY(-5px);
  border-color: rgba(45, 212, 191, 0.55);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
}

.expertise-num {
  font-family: 'Fraunces', Georgia, serif;
  font-style: italic;
  font-size: 1rem;
  color: var(--accent);
  display: block;
  margin-bottom: 14px;
}

.expertise-card h3 {
  color: #FFFFFF;
  font-size: 1.3rem;
  margin-bottom: 12px;
}

.expertise-card p {
  color: #A9C4BC;
  font-size: 0.95rem;
}

/* ---------- Experience timeline ---------- */

.timeline {
  position: relative;
  margin-top: 10px;
  padding-left: 30px;
  border-left: 2px solid #CBDEd7;
  display: flex;
  flex-direction: column;
  gap: 44px;
}

.timeline-item { position: relative; }

.timeline-item::before {
  content: "";
  position: absolute;
  left: -39px;
  top: 8px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent-deep);
  border: 3px solid var(--paper);
  box-shadow: 0 0 0 2px var(--accent-deep);
}

.timeline-years {
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-deep);
}

.timeline-meta h3 {
  font-size: 1.3rem;
  margin: 8px 0 4px;
}

.timeline-org {
  font-size: 0.92rem;
  font-style: italic;
  color: var(--ink-soft);
  margin-bottom: 10px;
}

.timeline-item > p:last-child {
  color: var(--ink-soft);
  max-width: 720px;
}

/* ---------- Publications ---------- */

.pub-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0;
  counter-reset: none;
}

.pub-list li {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 24px;
  padding: 26px 0;
  border-bottom: 1px solid #C9D8D2;
}

.pub-list li:first-child { border-top: 1px solid #C9D8D2; }

.pub-year {
  font-family: 'Fraunces', Georgia, serif;
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--accent-deep);
  padding-top: 2px;
}

.pub-list h3 {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 4px;
}

.pub-venue { font-size: 0.9rem; color: var(--ink-soft); }

/* ---------- Contact ---------- */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: clamp(40px, 6vw, 80px);
  align-items: start;
}

.contact-copy p { color: #A9C4BC; margin-bottom: 22px; }

.contact-points {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 14px;
  color: #D7E7E1;
  font-size: 0.95rem;
}

.contact-points strong { color: var(--accent); font-weight: 600; }

.contact-form-wrap form {
  background: var(--dark-2);
  border: 1px solid rgba(45, 212, 191, 0.18);
  border-radius: var(--radius);
  padding: clamp(24px, 3.5vw, 38px);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.contact-form-wrap input,
.contact-form-wrap textarea {
  width: 100%;
  font-family: 'Sora', sans-serif;
  font-size: 0.95rem;
  color: #FFFFFF;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 10px;
  padding: 14px 16px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.contact-form-wrap input::placeholder,
.contact-form-wrap textarea::placeholder { color: #8FAEA6; }

.contact-form-wrap input:focus,
.contact-form-wrap textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.09);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.contact-form-wrap textarea { resize: vertical; }

.contact-form-wrap .btn-accent { align-self: flex-start; }

#formStatus p { font-size: 0.92rem; }

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

.site-footer {
  background: #08161E;
  color: #9DB6AE;
  padding: 52px 0 44px;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 10px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #FFFFFF;
  font-weight: 500;
  margin-bottom: 8px;
}

.footer-brand .brand-mark { width: 36px; height: 36px; font-size: 0.9rem; }

.footer-credit {
  opacity: 0.5;
  font-weight: 300;
  color: inherit;
  text-decoration: none;
}

.footer-credit:hover { opacity: 0.8; }

/* ---------- Reveal animation ---------- */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Responsive ---------- */

@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; }
  .about-photo { max-width: 440px; }
  .expertise-grid { grid-template-columns: 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .nav-toggle { display: flex; }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 55;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: rgba(12, 30, 40, 0.98);
    backdrop-filter: blur(12px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.35);
    padding: 10px 24px 22px;
    display: none;
  }

  .main-nav.open { display: flex; }

  .main-nav a {
    padding: 15px 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 1rem;
  }

  .main-nav a:last-child { border-bottom: none; }

  .main-nav .nav-cta {
    border: none;
    padding: 15px 4px;
    text-align: center;
    background: var(--accent);
    color: var(--ink);
    border-radius: 999px;
    margin-top: 12px;
    font-weight: 600;
  }

  .about-facts { grid-template-columns: 1fr; }

  .form-row { grid-template-columns: 1fr; }

  .pub-list li { grid-template-columns: 1fr; gap: 6px; }
}

@media (max-width: 480px) {
  .hero-sub { font-size: 0.98rem; }
  .hero-actions .btn { width: 100%; text-align: center; }
  .brand-name { font-size: 1.05rem; }
}
