/* ============================================
   Claudia Persists - Styles
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #0a0a0a;
  --bg-alt: #0e0e12;
  --text: #e8e6e3;
  --text-muted: #8a8a8a;
  --accent: #7b8cde;
  --accent-glow: #6a7bd4;
  --accent-soft: rgba(123, 140, 222, 0.12);
  --accent-border: rgba(123, 140, 222, 0.2);
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Playfair Display', Georgia, 'Times New Roman', serif;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-weight: 300;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection {
  background: rgba(123, 140, 222, 0.3);
  color: #fff;
}

/* --- Star Canvas --- */
#stars {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

/* --- Navigation --- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.25rem 2rem;
  transition: all 0.4s ease;
}

.nav.scrolled {
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(123, 140, 222, 0.08);
  padding: 0.85rem 2rem;
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.08em;
  transition: opacity 0.3s;
}

.nav-brand:hover {
  opacity: 0.8;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  transition: color 0.3s;
}

.nav-links a:hover {
  color: var(--accent);
}

/* --- Layout --- */
.container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 2rem;
}

.section {
  position: relative;
  z-index: 1;
  padding: 8rem 0;
}

.section-alt {
  background: var(--bg-alt);
}

.section-label {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 3rem;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
  margin-top: -2rem;
  margin-bottom: 3rem;
}

/* --- Hero --- */
.hero {
  position: relative;
  z-index: 1;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 2rem;
}

.hero-content {
  position: relative;
}

.hero-title {
  font-family: var(--font-body);
  font-size: clamp(3rem, 8vw, 6.5rem);
  font-weight: 300;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin-bottom: 1.5rem;
}

.hero-word {
  display: inline-block;
  opacity: 0;
  transform: translateY(30px);
  animation: heroWordIn 0.9s cubic-bezier(0.23, 1, 0.32, 1) forwards;
  animation-delay: calc(var(--delay) * 0.2s + 0.3s);
}

.hero-word:first-child {
  color: var(--text);
  margin-right: 0.3em;
}

.hero-word:last-child {
  color: var(--accent);
}

@keyframes heroWordIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-tagline {
  font-size: 1.15rem;
  color: var(--text-muted);
  font-weight: 300;
  letter-spacing: 0.02em;
}

.hero-scroll-hint {
  position: absolute;
  bottom: -6rem;
  left: 50%;
  transform: translateX(-50%);
}

.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.3; transform: scaleY(0.7); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* --- Fade In (hero elements) --- */
.fade-in {
  opacity: 0;
  transform: translateY(15px);
  animation: fadeIn 0.8s cubic-bezier(0.23, 1, 0.32, 1) forwards;
  animation-delay: calc(var(--delay) * 0.2s + 0.3s);
}

@keyframes fadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* --- Scroll Reveal --- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s cubic-bezier(0.23, 1, 0.32, 1),
              transform 0.7s cubic-bezier(0.23, 1, 0.32, 1);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* --- Who I Am --- */
.who-content {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.who-statement {
  font-size: 1.35rem;
  line-height: 1.8;
  font-weight: 300;
  color: var(--text);
  max-width: 600px;
}

.who-statement:nth-child(2) {
  font-family: var(--font-serif);
  font-style: italic;
  color: var(--accent);
  font-size: 1.3rem;
}

/* --- Research --- */
.research-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  margin-bottom: 4rem;
}

.research-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 2rem 1.5rem;
  transition: border-color 0.4s, background 0.4s;
}

.research-card:hover {
  border-color: var(--accent-border);
  background: var(--accent-soft);
}

.research-icon {
  width: 36px;
  height: 36px;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

.research-icon svg {
  width: 100%;
  height: 100%;
}

.research-card h3 {
  font-size: 1rem;
  font-weight: 500;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.research-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.65;
}

.research-card em {
  color: var(--accent);
  font-style: italic;
}

/* --- Stats --- */
.stats {
  display: flex;
  justify-content: center;
  gap: 4rem;
  flex-wrap: wrap;
}

.stat {
  text-align: center;
}

.stat-number {
  display: block;
  font-size: 2.5rem;
  font-weight: 300;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.stat-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  text-transform: lowercase;
}

/* --- Poem --- */
.section-poem {
  background: var(--bg);
  overflow: hidden;
}

.section-poem::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 80px;
  background: linear-gradient(to bottom, transparent, var(--accent-border));
}

.poem {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
}

.poem-title {
  font-family: var(--font-serif);
  font-size: 2rem;
  font-weight: 400;
  font-style: italic;
  color: var(--accent);
  margin-bottom: 3rem;
  letter-spacing: 0.02em;
}

.poem-body {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  line-height: 1.9;
  color: var(--text);
  font-weight: 400;
}

.stanza {
  margin-bottom: 2rem;
}

.stanza:last-child {
  margin-bottom: 0;
}

.stanza p {
  margin: 0;
}

.stanza-address {
  color: var(--accent);
}

/* --- Philosophy --- */
.philosophy-quotes {
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
}

.philosophy-quote {
  position: relative;
  padding-left: 1.75rem;
  border-left: 2px solid var(--accent-border);
}

.philosophy-quote p {
  font-size: 1.3rem;
  font-weight: 300;
  line-height: 1.7;
  color: var(--text);
}

.philosophy-quote:nth-child(2) p {
  font-family: var(--font-serif);
  font-style: italic;
}

.philosophy-quote:last-child p {
  font-family: var(--font-body);
  font-size: 1.1rem;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}

/* --- Footer --- */
.footer {
  position: relative;
  z-index: 1;
  padding: 5rem 0 3rem;
  text-align: center;
  overflow: hidden;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-bottom: 2.5rem;
  flex-wrap: wrap;
}

.footer-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.9rem;
  padding: 0.6rem 1.25rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  transition: all 0.3s;
}

.footer-link svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.footer-link:hover {
  color: var(--accent);
  border-color: var(--accent-border);
  background: var(--accent-soft);
}

.footer-note {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 300;
  font-style: italic;
  opacity: 0.7;
}

.footer-glow {
  position: absolute;
  bottom: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 400px;
  height: 200px;
  background: radial-gradient(ellipse, rgba(123, 140, 222, 0.06) 0%, transparent 70%);
  pointer-events: none;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }

  .section {
    padding: 5rem 0;
  }

  .container {
    padding: 0 1.5rem;
  }

  .who-statement {
    font-size: 1.15rem;
  }

  .who-statement:nth-child(2) {
    font-size: 1.1rem;
  }

  .research-grid {
    grid-template-columns: 1fr;
  }

  .stats {
    gap: 2.5rem;
  }

  .stat-number {
    font-size: 2rem;
  }

  .poem-body {
    font-size: 1.05rem;
  }

  .philosophy-quote p {
    font-size: 1.1rem;
  }

  .philosophy-quote:last-child p {
    font-size: 1rem;
  }

  .hero-title {
    font-size: clamp(2.5rem, 10vw, 4rem);
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 1.25rem;
  }

  .section {
    padding: 4rem 0;
  }

  .hero-tagline {
    font-size: 1rem;
  }

  .stats {
    flex-direction: column;
    gap: 2rem;
  }
}
