:root {
  --bg-color: #121212;
  --text-color: #e0e0e0;
  --link-color: #64b5f6;
  --hr-color: #333;
}

body.light {
  --bg-color: #f8f8f8;
  --text-color: #121212;
  --link-color: #1a73e8;
  --hr-color: #ccc;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  max-width: 800px;
  margin: auto;
  padding: 30px 20px;
  transition: background 0.3s ease, color 0.3s ease;
}

.toggle {
  position: absolute;
  top: 10px;
  right: 10px;
  cursor: pointer;
  background: none;
  color: var(--text-color);
  border: 2px solid var(--text-color);
  border-radius: 5px;
  padding: 5px 10px;
  font-size: 0.9em;
  z-index: 1000;
}

.header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 30px;
}

.header img {
  border-radius: 50%;
  object-fit: cover;
  width: 150px;
  height: 200px;
  margin-bottom: 20px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

@media (min-width: 600px) {
  .header {
    flex-direction: row;
    align-items: center;
  }

  .header img {
    margin-right: 20px;
    margin-bottom: 0;
  }
}

h2, h3 {
  margin-top: 0;
  color: var(--text-color);
}

a {
  color: var(--link-color);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

ul {
  padding-left: 1.2em;
}

li {
  margin-bottom: 10px;
}

hr {
  border: 1px solid var(--hr-color);
  margin: 30px 0;
}

.section {
  margin-bottom: 40px;
}

.social-links {
  margin-top: 50px;
  text-align: center;
}

.social-links a {
  text-decoration: none;
  margin-right: 20px;
  color: var(--text-color);
}

.social-links a:hover {
  text-decoration: underline;
}

.nav-bar {
  text-align: center;
  margin-bottom: 30px;
}

.nav-bar a {
  margin: 0 15px;
  color: var(--link-color);
  text-decoration: none;
  font-weight: bold;
}

.nav-bar a:hover {
  text-decoration: underline;
}

/* Fade-in animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section,
.header,
hr,
p,
.social-links {
  opacity: 0;
  animation: fadeIn 0.6s ease forwards;
}

.section:nth-of-type(1) { animation-delay: 0.3s; }
.section:nth-of-type(2) { animation-delay: 0.6s; }
.section:nth-of-type(3) { animation-delay: 0.9s; }
.header { animation-delay: 0.1s; }
hr { animation-delay: 1.2s; }
p { animation-delay: 1.5s; }
.social-links { animation-delay: 1.8s; }

/* Experience cards */
.experience-cards {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
  margin-top: 20px;
}

.experience-card {
  background-color: #1e1e1e;
  border-radius: 12px;
  padding: 20px;
  width: 220px;
  text-align: center;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.experience-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.experience-card img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  margin-bottom: 12px;
  filter: brightness(0) invert(1); /* makes dark logos light */
}

.experience-card h4 {
  margin: 10px 0 5px;
  font-size: 1em;
  color: whitesmoke;
}

.experience-card p {
  font-size: 0.9em;
  color: #aaa;
  margin: 0;
}
