/* Custom styles with color variables */
:root {
  --heading-color: #e8e8ec;
  --subheading-color: #4A90E2;
  --body-color: #ffffff;
  --accent-color: #4A90E2;
  --date-color: #4A90E2;
  --button-color: #4A90E2;
  --bulk-text-color: #c4c4c4;
  --details-text-color: #c4c4c4;
}

body {
  font-family: 'Inter', sans-serif;
  background: url('../images/richard-bg.jpg') no-repeat center fixed;
  background-size: cover;
  overflow-x: hidden;
  color: var(--body-color);
  background-color: #2d2d2d;
  min-height: 100vh;
}

.background-fixed {
  display: none; /* Hidden on desktop */
}

@media (max-width: 768px) {
  body {
    background: none; /* Remove body background on mobile */
    background-color: #2d2d2d; /* Fallback */
  }
  .background-fixed {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: url('../images/richard-bg.jpg') no-repeat center center;
    background-size: cover;
    z-index: -1; /* Behind content */
  }
}

.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

html {
  scroll-behavior: smooth;
}

.content-container {
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

.underline-turquoise {
  border-bottom: 1px solid var(--accent-color);
}

#about, #career, #contact {
  background-color: rgba(0, 0, 0, 0.7);
}
#home, #education, #writings {
  background-color: rgba(0, 0, 0, 0.4);
}

.heading {
  color: var(--heading-color);
  font-weight: 500;
  transition: text-shadow 0.3s ease;
}

.heading.glow {
  animation: heading-glow 1.4s cubic-bezier(0.4, 0, 0.2, 1) 0.5s;
}

@keyframes heading-glow {
  0% { text-shadow: 0 0 0 var(--accent-color); }
  40% { text-shadow: 0 0 8px var(--accent-color), 0 0 15px var(--accent-color); }
  100% { text-shadow: 0 0 0 var(--accent-color); }
}

.subheading {
  color: var(--subheading-color);
  font-weight: 300;
}

.body-text {
  color: var(--bulk-text-color);
  font-weight: 300;
}

.date-text {
  color: var(--date-color);
  font-weight: 300;
}

.accent {
  color: var(--accent-color);
}

.accent:hover {
  color: color-mix(in srgb, var(--accent-color), #ffffff 20%);
}

.details-text {
  color: var(--details-text-color);
  font-weight: 300;
}

.about-content {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.about-text {
  flex: 1;
  text-align: left;
}

.about-image {
  flex-shrink: 0;
  width: 150px;
  height: auto;
  border: 1px solid var(--accent-color);
  background-color: #3b83f621;
  padding: 0px;
}

.about-details {
  width: 100%;
}

@media (max-width: 768px) {
  .about-content {
    flex-direction: column;
    text-align: center;
  }
  .about-image {
    margin: 0 auto;
  }
  .about-details {
    margin-top: 1rem;
  }
}

nav a {
  color: var(--heading-color);
}

nav a:hover {
  color: var(--accent-color);
  transition: color 0.3s ease;
}

.edu-logo {
  width: 90px;
  height: auto;
  margin-right: 10px;
  filter: brightness(1.8) contrast(1.5);
}

.edu-logo.hidden {
  display: none;
}