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

body {
  background-color: #121212;
  color: #fff;
  font-family: 'Inter', 'Segoe UI', Roboto, sans-serif;
  display: flex;
  min-height: 100vh;
  padding: 2rem;
  gap: 2rem;
}

.profile {
  background-color: #1b1b1b;
  border-radius: 16px;
  padding: 2rem;
  width: 300px;
  box-shadow: 0 0 20px rgba(0,0,0,0.4);
  flex-shrink: 0;
}

.profile-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.avatar-container img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 1rem;
}

.avatar-container h1 {
  font-size: 1.5rem;
  text-align: center;
  font-weight: 600;
}

.personalia-container {
  width: 100%;
  display: grid;
  gap: 1rem;
}

.personalia-container div {
  background-color: #222;
  padding: 1rem;
  border-radius: 12px;
}

.personalia-container h2 {
  font-size: 0.9rem;
  color: #CB748E;
  margin-bottom: 0.25rem;
}

.personalia-container p {
  font-size: 0.9rem;
  color: #ddd;
}

.media-container {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-top: 1rem;
}

.media-container img {
  width: 24px;
  height: 24px;
  filter: brightness(0) invert(1);
  opacity: 0.8;
  transition: opacity 0.2s;
}

.media-container img:hover {
  opacity: 1;
}

main {
  flex: 1;
  background-color: #1e1e1e;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 0 20px rgba(0,0,0,0.4);
  display: flex;
  flex-direction: column;
}

.content-section {
  flex: 1;
  overflow-y: auto;
  max-height: 100vh;
  padding-right: 1rem;
  scrollbar-width: thin;
  scrollbar-color: #CB748E #1e1e1e;
}

.content-section::-webkit-scrollbar {
  width: 8px;
}

.content-section::-webkit-scrollbar-track {
  background: #1e1e1e;
}

.content-section::-webkit-scrollbar-thumb {
  background-color: #CB748E;
  border-radius: 4px;
}

.section-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: #1e1e1e;
  padding: 1rem 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #333;
  backdrop-filter: blur(4px);
}

.section-header h2 {
  font-size: 1.4rem;
  text-transform: uppercase;
  color: #CB748E;
}

.section-nav ul {
  list-style: none;
  display: flex;
  gap: 1rem;
}

.section-nav a {
  color: #aaa;
  text-decoration: none;
  font-weight: 500;
  padding: 0.5rem 1rem;
  border-radius: 8px;
  position: relative;
  transition: color 0.2s, background-color 0.2s;
}

.section-nav a.active,
.section-nav a:hover {
  color: #CB748E;
  background-color: #333;
}

.section-nav a.active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 2px;
  background-color: #CB748E;
  border-radius: 2px;
}

#section-content {
  animation: fadeIn 0.25s ease;
}

.intro {
  margin-top: 2rem;
  margin-bottom: 2rem;
}

.tasks-container h3 {
  font-size: 1.2rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid #333;
  padding-bottom: 0.5rem;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}

.card-container {
  display: flex;
  background-color: #2a2a2a;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
  transition: transform 0.2s;
  gap: 1rem;
  align-items: center;
}

.card-container:hover {
  transform: translateY(-4px);
}

.card-container img {
  height: 80%;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  flex-shrink: 0;
}

.card-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.card-text h4 {
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.card-text p {
  color: #ccc;
  font-size: 0.95rem;
}

#cv-section {
  margin-top: 2rem;
  padding: 1rem 0;
}

#cv-section h2 {
  font-size: 1.6rem;
  margin-bottom: 1rem;
  color: #CB748E;
  border-bottom: 1px solid #333;
  padding-bottom: 0.5rem;
}

.cv-entry {
  margin-bottom: 2rem;
}

.cv-entry h3 {
  font-size: 1.2rem;
  color: #fff;
  margin-bottom: 0.25rem;
}

.cv-meta {
  font-size: 0.9rem;
  color: #aaa;
  font-style: italic;
  margin-bottom: 0.5rem;
}

.cv-entry ul,
.cv-skills,
.cv-additional {
  list-style-type: disc;
  padding-left: 1.5rem;
  margin-top: 0.5rem;
  margin-bottom: 2rem;
}

.cv-entry ul li,
.cv-skills li,
.cv-additional li {
  margin-bottom: 0.4rem;
  color: #ccc;
  font-size: 0.95rem;
}

#portfolio-section {
  margin-top: 2rem;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

.portfolio-card {
  background-color: #2a2a2a;
  border-radius: 12px;
  padding: 1rem;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
  transition: transform 0.2s;
  display: flex;
  flex-direction: column;
  align-items: left;
  text-align: left;
}

.portfolio-card:hover {
  transform: translateY(-4px);
}

.portfolio-card a {
  display: block;
  width: 100%;
  border-radius: 8px;
  overflow: hidden;
}

.portfolio-card a img {
  width: 100%;
  max-height: auto;
  object-fit: cover;
  transition: transform 0.3s ease, filter 0.3s ease;
  display: block;
}

.portfolio-card a:hover img {
  transform: scale(1.05);
  filter: brightness(1.1);
}

.portfolio-card h2 {
  font-size: 1.1rem;
  color: #fff;
  margin-top: 0.75rem;
  margin-bottom: 0.5rem;
}

.portfolio-description {
  font-size: 0.9rem;
  color: #ccc;
  margin-bottom: 0.75rem;
}

.portfolio-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  justify-content: center;
  width: fit-content;
}

.portfolio-links a {
  font-size: 0.85rem;
  color: #CB748E;
  text-decoration: none;
  background-color: #1e1e1e;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  transition: background-color 0.2s;
}

.portfolio-links a:hover {
  background-color: #333;
}

#cover-letter-section {
  margin-top: 2rem;
  background-color: #2a2a2a;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.cover-letter p {
  font-size: 0.95rem;
  color: #ccc;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.cover-letter strong {
  color: #fff;
}

.cover-letter a {
  color: #CB748E;
  text-decoration: none;
}

.cover-letter a:hover {
  text-decoration: underline;
}

#contact-section {
  margin-top: 2rem;
}

.contact-container {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  background-color: #2a2a2a;
  padding: 2rem;
  border-radius: 12px;
  box-shadow: 0 0 10px rgba(0,0,0,0.3);
}

.map-wrapper iframe {
  width: 100%;
  height: 300px;
  border-radius: 8px;
  box-shadow: 0 0 6px rgba(0,0,0,0.4);
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-form label {
  font-size: 0.9rem;
  color: #CB748E;
}

.contact-form input,
.contact-form textarea {
  background-color: #1e1e1e;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 0.75rem;
  color: #fff;
  font-size: 0.95rem;
  resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: #CB748E;
  background-color: #262626;
}

.contact-form button {
  background-color: #CB748E;
  color: #121212;
  font-weight: 600;
  border: none;
  border-radius: 8px;
  padding: 0.75rem 1.5rem;
  cursor: pointer;
  transition: background-color 0.2s;
  align-self: flex-start;
}

.contact-form button:hover {
  background-color: #e88ca6;
}

.fade-in {
  animation: fadeIn 0.25s ease forwards;
}

.fade-out {
  animation: fadeOut 0.15s ease forwards;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeOut {
  from { opacity: 1; transform: translateY(0); }
  to { opacity: 0; transform: translateY(4px); }
}

@media (max-width: 900px) {
  body {
    flex-direction: column;
    padding: 1rem;
  }

  .profile {
    width: 100%;
  }

  main {
    width: 100%;
  }

  .section-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  .section-nav ul {
    flex-wrap: wrap;
  }

  .card-grid {
    grid-template-columns: 1fr;
  }

  .card-container {
    flex-direction: column;
    text-align: center;
  }

  .card-container img {
    height: auto;
    width: 80px;
    margin-bottom: 1rem;
  }

  .card-text {
    align-items: center;
  }

  #cv-section h2 {
    font-size: 1.4rem;
  }

  .cv-entry h3 {
    font-size: 1rem;
  }

  .cv-meta {
    font-size: 0.85rem;
  }

  .cv-entry ul li,
  .cv-skills li,
  .cv-additional li {
    font-size: 0.9rem;
  }

  .portfolio-grid {
    grid-template-columns: 1fr;
  }

  .contact-container {
    padding: 1rem;
  }

  .contact-form button {
    width: 100%;
  }

  footer {
    min-height: 1px;
  }
}

@media (min-width: 1800px) {
  body {
    max-width: 1800px;
    margin: auto;
  }
}
