/* Creating section-specific styles */
/* Modern hero section with enhanced visual effects */
.hero-modern {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background: var(--background);
  padding: 100px 0;
  overflow: hidden;
}

.hero-background {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  overflow: hidden;
}

.gradient-sphere {
  position: absolute;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
  top: -200px;
  right: -200px;
  border-radius: 50%;
  opacity: 0.1;
  animation: floatSphere 20s ease-in-out infinite;
}

.gradient-sphere.second {
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, var(--accent) 0%, transparent 70%);
  top: auto;
  bottom: -100px;
  left: -100px;
  animation-delay: -10s;
}

.grid-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: linear-gradient(var(--border) 1px, transparent 1px),
                    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 50px 50px;
  opacity: 0.1;
}

[data-theme="dark"] .grid-overlay {
  opacity: 0.05;
}

[data-theme="dark"] .glass-nav {
  background: rgba(10, 25, 47, 0.85);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  border-bottom: 1px solid rgba(100, 255, 218, 0.1);
}

[data-theme="dark"] .nav-link:hover {
  background: rgba(100, 255, 218, 0.1);
}

[data-theme="dark"] .logo-symbol {
  background: linear-gradient(135deg, var(--accent), #4a9eff);
}

[data-theme="dark"] .theme-toggle.modern {
  background: rgba(100, 255, 218, 0.05);
}

[data-theme="dark"] .theme-toggle.modern:hover {
  background: rgba(100, 255, 218, 0.1);
}

.hero-content-modern {
  position: relative;
  z-index: 2;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 6rem;
  align-items: center;
}

.hero-visual {
  position: relative;
}

.image-container {
  position: relative;
  z-index: 2;
}

.image-frame {
  position: relative;
  width: 450px;
  height: 550px;
  border-radius: 30px;
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  background: var(--card);
  display: flex;
  align-items: center;
  justify-content: center;
}

.portrait-modern {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.5s ease;
  background: var(--card);
}

.image-effects {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  display: none;
}

.effect-circle {
  position: absolute;
  width: 300px;
  height: 300px;
  border: 2px solid var(--primary);
  border-radius: 50%;
  top: -100px;
  right: -100px;
  opacity: 0.1;
  animation: rotateCircle 20s linear infinite;
}

.effect-line {
  position: absolute;
  width: 150px;
  height: 3px;
  background: var(--primary);
  bottom: 40px;
  left: -20px;
  opacity: 0.3;
}

.floating-elements {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
}

.tech-badge {
  position: absolute;
  padding: 0.8rem 1.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-weight: 500;
  color: var(--primary);
  box-shadow: var(--shadow-lg);
  animation: floatBadge 6s ease-in-out infinite;
}

.tech-badge::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, var(--primary));
  filter: blur(8px);
  opacity: 0;
  border-radius: 20px;
  transform: translateX(-100%);
  animation: meteorTrail 6s ease-in-out infinite;
}

.tech-badge:nth-child(1) {
  top: 20%;
  left: -80px;
  animation-delay: 0s;
}

.tech-badge:nth-child(2) {
  top: 50%;
  right: -60px;
  animation-delay: -2s;
}

.tech-badge:nth-child(3) {
  bottom: 20%;
  left: -40px;
  animation-delay: -4s;
}

/* Enhanced hero text with modern badge */
.hero-text-container {
  padding-right: 2rem;
}

.badge-container {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
}

.hero-badge-modern {
  display: inline-block;
  background: var(--primary);
  color: var(--primary-foreground);
  padding: 0.8rem 1.5rem;
  border-radius: 25px;
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-badge-modern.secondary {
  background: var(--secondary);
  color: var(--primary);
}

.badge-dot {
  width: 6px;
  height: 6px;
  background: var(--primary);
  border-radius: 50%;
}

.hero-title {
  font-size: 4.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.1;
}

.greeting {
  display: block;
  font-size: 1.8rem;
  color: var(--muted-foreground);
  margin-bottom: 0.5rem;
}

.name {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  display: flex;
  align-items: center;
  min-height: 1.2em;
  font-family: "Space Grotesk", monospace;
}

.cursor {
  display: inline-block;
  width: 3px;
  margin-left: 4px;
  background: var(--primary);
  animation: cursorBlink 1s infinite;
}

@keyframes cursorBlink {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0;
  }
}

.hero-subtitle-modern {
  font-size: 1.8rem;
  color: var(--foreground);
  font-weight: 600;
  margin-bottom: 1.5rem;
  opacity: 0;
  animation: fadeInUp 0.8s ease-out 0.6s forwards;
}

.hero-description-modern {
  font-size: 1.2rem;
  margin-bottom: 3rem;
  color: var(--muted-foreground);
  line-height: 1.8;
  opacity: 0;
  animation: fadeInUp 0.8s ease-out 0.8s forwards;
}

.hero-cta {
  display: flex;
  gap: 1.5rem;
  opacity: 0;
  animation: fadeInUp 0.8s ease-out 1s forwards;
}

.cta-button {
  position: relative;
  padding: 1rem 2rem;
  border-radius: 12px;
  font-weight: 600;
  text-decoration: none;
  overflow: hidden;
  transition: all 0.3s ease;
}

.cta-button.primary {
  background: var(--primary);
  color: var(--primary-foreground);
}

.cta-button.secondary {
  background: var(--secondary);
  color: var(--primary);
}

.button-effect {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, transparent 40%, rgba(255,255,255,0.2) 50%, transparent 60%);
  transform: translateX(-100%);
  transition: transform 0.6s;
}

.cta-button:hover .button-effect {
  transform: translateX(100%);
}

/* Enhanced about section with modern card design */
.about {
  padding: 100px 0;
  background: var(--muted);
}

.about-content-centered {
  display: flex;
  justify-content: center;
  align-items: center;
  max-width: 900px;
  margin: 0 auto;
}

.about-card {
  background: var(--card);
  border-radius: calc(var(--radius) * 2);
  padding: 3rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}

.about-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

.about-text-centered {
  text-align: center;
}

.about-section {
  margin-bottom: 2.5rem;
}

.about-section h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.about-section p {
  font-size: 1.1rem;
  line-height: 1.8;
  color: var(--muted-foreground);
}

/* Enhanced skills section with progress bars */
.skills-section {
  margin-top: 3rem;
}

.skills-section h4 {
  font-size: 1.3rem;
  margin-bottom: 2rem;
  color: var(--foreground);
}

.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
  justify-content: center;
}

.skill-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem;
  background: var(--background);
  border-radius: var(--radius);
  transition: all 0.3s ease;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
  opacity: 0;
  transform: translateY(20px);
  animation: skillPulse 2s ease-in-out infinite;
}

.skill-item.animate-in {
  opacity: 1;
  transform: translateY(0);
}

.skill-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.skill-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.skill-item span {
  font-weight: 600;
  color: var(--foreground);
  margin-bottom: 1rem;
}

.skill-progress {
  width: 100%;
  height: 6px;
  background: var(--border);
  border-radius: 3px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, var(--chart-1), var(--chart-2));
  border-radius: 3px;
  transition: width 1s ease-in-out;
}

/* Modern portfolio section with enhanced cards and timeline */
.portfolio {
  padding: 100px 0;
  background: var(--background);
}

.project-connector {
  position: relative;
  display: flex;
  align-items: flex-start;
  margin: 40px 0;
  margin-left: -40px;
  padding-left: 0;
  padding-top: 180px;
}

.project-connector::before {
  content: '';
  position: absolute;
  left: 0;
  top: 180px;
  width: 100px;
  height: 2px;
  background: var(--primary);
  opacity: 0.7;
  z-index: 2;
}

.project-connector.with-card::before {
  width: 450px;
}

.project-connector .project-card {
  margin-left: 450px;
  transform-origin: left center;
}

/* Timeline Container */
.timeline-container {
  position: relative;
  max-width: 1200px;
  margin: 40px auto;
  padding: 20px;
  display: flex;
}

/* Timeline Left Side (Years) */
.timeline-years {
  position: relative;
  width: 200px;
  padding-right: 40px;
}

/* Timeline Bar */
.timeline-bar {
  position: absolute;
  top: 0;
  right: 20px;
  width: 4px;
  height: 100%;
  background: var(--border);
}

/* Progress Bar */
.timeline-progress {
  position: fixed; /* Fixed position um beim Scrollen fixiert zu bleiben */
  top: initial;
  bottom: 75%; /* Von unten aus gemessen, um am Ende des 1. Jahres zu bleiben */
  right: 20px;
  width: 4px;
  height: 25%;
  background: var(--primary);
  transition: height 1s ease-in-out;
  z-index: 2;
}

/* Year Markers */
.year-marker {
  position: relative;
  height: 25%;
  min-height: 300px;
  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding-right: 40px;
  padding-top: 20px;
  z-index: 1; /* Unter der Timeline-Progress */
}

.year-marker::before {
  content: '';
  position: absolute;
  right: 16px;
  top: 45px; /* Angepasst an das neue padding-top */
  width: 12px;
  height: 12px;
  background: var(--background);
  border: 2px solid var(--primary);
  border-radius: 50%;
  z-index: 3;
}

.year-marker.current::before {
  background: var(--primary);
}

.year-marker span {
  font-weight: 600;
  color: var(--foreground);
}

/* Timeline Content */
.timeline-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding-left: 40px;
  min-height: 1600px;
}

/* Project Cards in Timeline */
.project-year-section {
  position: relative;
  height: 25%;
  min-height: 400px; /* Erhöht für mehr Platz */
  padding: 20px 0;
  margin-bottom: 40px;
  display: flex;
  flex-direction: column;
}

/* Zeitpunkt-Markierung */
.year-progress {
  position: relative;
  margin: 20px 0;
}

.timeline-point {
  position: relative;
  padding: 8px 16px;
  background: var(--primary);
  color: var(--primary-foreground);
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
  display: inline-block;
  margin-bottom: 20px;
}

/* Projekte am Ende des Jahres */
.projects-grid.end-of-year {
  margin-top: 40px;
}

.project-date {
  margin-top: 15px;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.9);
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding-top: 10px;
}

.project-year-section h3 {
  color: var(--primary);
  margin-bottom: 20px;
  font-size: 1.2rem;
}

.projects-grid {
  display: flex;
  justify-content: flex-start;
  gap: 2rem;
}

/* Connecting Line to Projects */
.project-connector {
  position: relative;
  display: flex;
  align-items: flex-start;
  margin: 40px 0;
  margin-left: -40px;
  padding-left: 0;
  padding-top: 180px; /* Weiter nach unten verschoben, um am Ende des 1. Lehrjahres zu sein */
}

.project-connector::before {
  content: '';
  position: absolute;
  left: 0;
  top: 180px; /* Weiter nach unten verschoben */
  width: 200px; /* Standardbreite verringert */
  height: 2px;
  background: var(--primary);
  opacity: 0.7;
  z-index: 2;
}

.project-connector.with-card::before {
  width: 600px; /* Kürzere Linie für Verbindungen mit Karte */
}

.project-connector .project-card {
  margin-left: 600px; /* Angepasst an die neue Linienbreite */
  transform-origin: left center;
}

.project-card {
  position: relative;
  width: 280px;
  background: var(--card);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  cursor: pointer;
  opacity: 0;
  animation: slideInBottom 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              box-shadow 0.3s ease,
              transform 0.3s ease;
  transform-origin: left center;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

.project-card.expanded {
  width: 800px;
  transform: translateY(0);
}

.project-inner {
  position: relative;
  width: 100%;
  padding: 25px;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-title {
  font-size: 1.6rem;
  color: var(--foreground);
  text-align: center;
  margin: 0 0 1.5rem 0;
  font-weight: 700;
  width: 100%;
}

.project-image {
  width: 140px;
  height: 140px;
  margin: 0 auto;
  background: var(--background);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 20px;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-content {
  width: 100%;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.project-card.expanded .project-image {
  width: calc(100% + 50px);
  height: 250px;
  margin: 1.5rem -25px;
  border-radius: 0;
}

.project-card.expanded .project-content {
  max-height: 800px;
  opacity: 1;
  padding: 0;
}

.project-card.expanded .project-title {
  font-weight: 800;
  letter-spacing: 0.02em;
}

.project-card.expanded .project-description {
  font-weight: 500;
  letter-spacing: 0.01em;
}

.project-card.expanded .project-status {
  font-weight: 600;
  letter-spacing: 0.02em;
}

.project-card.expanded .project-skills li {
  font-weight: 600;
  letter-spacing: 0.01em;
}

.expand-button {
  position: absolute;
  top: 50%;
  right: 15px;
  transform: translateY(-50%);
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--primary);
  border: none;
  color: var(--primary-foreground);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 2;
}

.expand-button svg {
  width: 14px;
  height: 14px;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card.expanded .expand-button {
  transform: translateY(-50%) rotate(180deg);
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

.project-card.animate-in {
  opacity: 1;
}

.project-logo {
  width: 120px;
  height: 120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--card);
  border-radius: 12px;
  overflow: hidden;
}

.project-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 15px;
}

.project-title {
  text-align: center;
  color: var(--foreground);
  font-size: 1.6rem;
  font-weight: 700;
  margin-top: 0.75rem;
  line-height: 1.3;
}

.project-details {
  width: 100%;
  padding: 2rem;
  background: var(--background);
  border-radius: calc(var(--radius) * 2);
  margin-top: 1.25rem;
  text-align: center;
}

.project-status {
  display: inline-block;
  padding: 0.5rem 1.25rem;
  background: var(--primary);
  color: var(--primary-foreground);
  border-radius: 20px;
  font-size: 1.1rem;
  font-weight: 500;
  margin-bottom: 1.5rem;
}

.project-description {
  color: var(--muted-foreground);
  line-height: 1.7;
  font-size: 1.1rem;
  margin-bottom: 2rem;
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 25px;
  transition: padding 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.project-card.expanded .project-image img {
  padding: 15px;
}

.project-card:hover .project-image img {
  transform: scale(1.1);
}

.project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.95), rgba(59, 130, 246, 0.95));
  color: white;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  opacity: 0;
  transition: all 0.3s ease;
  backdrop-filter: blur(10px);
}

.project-card:hover .project-overlay {
  opacity: 1;
}

.project-content h4 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: white;
}

.project-content p {
  margin-bottom: 1.5rem;
  opacity: 0.9;
  line-height: 1.6;
}

.project-tools {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.5rem;
}

.project-tools span {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.3rem 0.8rem;
  border-radius: calc(var(--radius) / 2);
  font-size: 0.8rem;
  font-weight: 500;
}

.project-links {
  display: flex;
  gap: 1rem;
}

.project-link {
  color: white;
  text-decoration: none;
  font-weight: 600;
  padding: 0.5rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: calc(var(--radius) / 2);
  transition: all 0.3s ease;
}

.project-link:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* Enhanced contact section */
.contact {
  padding: 100px 0;
  background: var(--muted);
}

.contact-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: start;
}

.contact-info h3 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
  color: var(--foreground);
}

.contact-info p {
  font-size: 1.1rem;
  margin-bottom: 2rem;
  color: var(--muted-foreground);
  line-height: 1.7;
}

.contact-details {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem;
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.contact-item:hover {
  transform: translateX(5px);
  box-shadow: var(--shadow-md);
}

.contact-icon {
  font-size: 1.5rem;
  width: 40px;
  text-align: center;
}

.contact-item div {
  display: flex;
  flex-direction: column;
}

.contact-label {
  font-weight: 600;
  color: var(--primary);
  font-size: 0.9rem;
}

.contact-value {
  color: var(--foreground);
  font-size: 1rem;
}

/* Certifications Section */
.certifications {
  padding: 100px 0;
  background: var(--background);
}

.certifications-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.cert-card {
  background: var(--card);
  border-radius: 20px;
  padding: 2rem;
  transition: all 0.3s ease;
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.cert-card.planned::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  opacity: 0.5;
}

.cert-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.cert-content {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cert-icon {
  width: 48px;
  height: 48px;
  background: var(--secondary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.lock-icon {
  width: 24px;
  height: 24px;
  color: var(--primary);
  opacity: 0.8;
}

.cert-card h3 {
  font-size: 1.5rem;
  color: var(--foreground);
  margin-bottom: 0.5rem;
}

.cert-status {
  color: var(--primary);
  font-size: 0.9rem;
  font-weight: 500;
}

.cert-details {
  margin-top: 1rem;
}

.cert-details p {
  color: var(--muted-foreground);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.cert-skills {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cert-skills li {
  background: var(--secondary);
  color: var(--primary);
  padding: 0.5rem 1rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}

/* Modern footer */
.footer {
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 2rem 0;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer p {
  color: var(--muted-foreground);
  font-size: 0.9rem;
}

.social-links {
  display: flex;
  gap: 1.5rem;
}

.social-link {
  color: var(--muted-foreground);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.3s ease;
  padding: 0.5rem 1rem;
  border-radius: calc(var(--radius) / 2);
}

.social-link:hover {
  color: var(--primary);
  background: var(--muted);
}
