/* Fonts */
@font-face {
  font-family: 'PT Serif';
  src: url('fonts/PTSerif-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Inter';
  src: url('fonts/Inter_28pt-Light.ttf') format('truetype');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Inter Regular';
  src: url('fonts/Inter_18pt-Regular.ttf') format('truetype');
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: 'Jersey15';
  src: url('fonts/Jersey15-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* Root Variables */
:root {
  --bg-color: #0E0E0E;
  --bg-color-light: #1A1A1A;
  --bg-color-lighter: #151515;
  --text-color: #f4f1e5;
  --text-color-secondary: #9f9f9f;
  --accent-color: #DCCA70;
  --accent-color-secondary: #E5D99B;
  --accent-color-tertiary: #F1E8C2;
  --hover-bg: #151515;
  --scroll-y: 0px;
  
  --class-color-1: var(--accent-color);
  --class-color-2: var(--accent-color);
  --class-color-3: var(--accent-color);
  --class-color-4: var(--accent-color);
  --class-color-5: var(--accent-color);
  
  /* Typography */
  --font-main: 'Inter', sans-serif;
  --font-title: 'PT Serif', serif;
  --font-medium: 'Inter Medium', sans-serif; 
  --font-size-large: 56px;
  --font-size-medium: 28px;
  --font-size-small: 20px;
  --font-size-xs: 16px;
  --font-size-xxs: 12px;
  
  --line-height-normal: 1.5;
  --line-height-tight: 1.3;
  --line-height-loose: 1.8;
  
  /* Mobile font sizes */
  --mobile-font-size-large: 52px;
  --mobile-font-size-medium: 28px;
  --mobile-font-size-small: 22px;
  --mobile-font-size-xs: 18px;
  
  /* Animations */
  --transition-speed: 0.3s;
  --transition-long: 0.8s;
  --page-transition: 0.5s;
  
  /* Spacing */
  --page-padding: 20px;
  --section-spacing: 160px;
  
  /* Mobile spacing */
  --mobile-side-padding: 40px;
}

/* Base Styles */
body {
  font-size: var(--font-size-medium);
  margin: 0;
  padding: 0;
  background-color: var(--bg-color);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  color: var(--text-color);
  font-family: var(--font-main);
  position: relative;
  line-height: var(--line-height-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  transition: color 0.5s ease, background-color 0.5s ease;
}

/* Color transition effect */
.color-transition * {
  transition: color 0.7s ease, background-color 0.7s ease, border-color 0.7s ease, box-shadow 0.7s ease;
}

/* Header */
.site-header {
  position: fixed;
  top: 50px;
  left: 50px;
  z-index: 10;
}

.mobile-header {
  position: relative;
  top: auto;
  left: auto;
  width: 100%;
  text-align: left;
  padding: 30px var(--page-padding) 20px var(--page-padding);
}

.logo {
  display: inline-block;
  transition: transform 0.3s ease;
  cursor: pointer;
}

.logo:hover {
  transform: scale(1.1);
}

.logo img {
  width: 35px;
  height: auto;
}

/* Content */
.content {
  margin-top: 180px;
  width: 90%;
  max-width: 1150px;
  text-align: left;
  font-family: var(--font-title); 
  font-weight: 700;
  font-size: var(--font-size-large);
  line-height: var(--line-height-tight);
  letter-spacing: 0.01em;
  overflow-wrap: break-word;
  word-wrap: break-word;
  word-break: normal;
  hyphens: none;
}

/* Animations */
@keyframes gradientAnimation {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

@keyframes textPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.01); }
  100% { transform: scale(1); }
}

/* Text Effects */
.gradient-text {
  background: linear-gradient(
    90deg, 
    var(--accent-color), 
    var(--accent-color-secondary), 
    var(--accent-color-tertiary)
  );
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
  animation: gradientAnimation 8s linear infinite;
  letter-spacing: 0.01em;
  word-spacing: 0.1em;
}

.pulse-text {
  display: inline-block;
  animation: textPulse 20s ease-in-out infinite;
  will-change: transform;
  transform-origin: center center;
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.gradient-text.pulse-text {
  display: inline-block;
  animation: 
    gradientAnimation 15s linear infinite,
    textPulse 20s ease-in-out infinite;
  will-change: transform, background-position;
}

.gradient-text.pulse-text:hover {
  text-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
  transition: text-shadow 0.3s ease;
}

.accent-text {
  color: var(--accent-color);
}

/* Main text */
#main-text {
  margin-bottom: 10px;
  white-space: normal;
  word-wrap: break-word;
  word-break: normal;
  overflow-wrap: anywhere;
  hyphens: none;
  line-height: 1.3;
  color: var(--accent-color);
}

/* Fade-in animations */
#link-container, .section-container, .hidden {
  opacity: 0;
  transform: translateY(10px);
  transition: 
    opacity 0.6s cubic-bezier(0.25, 0.1, 0.25, 1.0),
    transform 0.6s cubic-bezier(0.25, 0.1, 0.25, 1.0);
}

#link-container.show, .section-container.show, .hidden.show {
  opacity: 1;
  transform: translateY(0);
}

/* Description text */
#description {
  opacity: 0;
  transition: opacity var(--transition-long) ease-in-out;
  font-family: var(--font-main);
  font-weight: 400;
  font-size: var(--font-size-small);
  color: var(--text-color);
  display: inline-block;
  text-align: left;
  max-width: 1150px;
  width: 100%;
  position: relative;
  top: 20px;
  margin: 0 auto;
  line-height: var(--line-height-loose);
  letter-spacing: 0.015em;
}

#description.show {
  opacity: 1;
}

/* Link container */
#link-container {
  margin-top: 80px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 1200px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
  align-items: flex-start;
  justify-content: flex-start;
}

/* Tech badges */
.tech-badge {
  background-color: var(--bg-color-light);
  border: 1px solid var(--bg-color-lighter);
  border-radius: 20px;
  padding: 10px 18px;
  font-size: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.3s ease;
  text-decoration: none;
  color: var(--text-color);
  line-height: var(--line-height-normal);
}

/* Unified button hover effects */
.tech-badge:hover {
  transform: translateY(-2px);
  border-color: var(--accent-color);
  color: var(--accent-color);
}

.tech-badge:hover svg path,
.tech-badge:hover svg rect,
.tech-badge:hover svg circle {
  stroke: var(--accent-color);
}

/* ── Contact button: filled hover + bubble effect ── */
#email-link {
  position: relative;
  overflow: visible;
  z-index: 0;
}

#email-link:hover {
  background-color: var(--accent-color);
  border-color: var(--accent-color);
  color: var(--bg-color);
  transform: translateY(-2px) scale(0.98);
}

#email-link:hover svg path,
#email-link:hover svg rect,
#email-link:hover svg circle {
  stroke: var(--bg-color);
}

#email-link:active {
  transform: translateY(0) scale(0.96);
}

#email-link::before,
#email-link::after {
  position: absolute;
  content: "";
  width: 150%;
  left: 50%;
  height: 100%;
  transform: translateX(-50%);
  z-index: -1;
  background-repeat: no-repeat;
  pointer-events: none;
}

#email-link:hover::before {
  top: -70%;
  background-image:
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, transparent 20%, var(--accent-color) 20%, transparent 30%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, transparent 10%, var(--accent-color) 15%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%);
  background-size: 10% 10%, 20% 20%, 15% 15%, 20% 20%, 18% 18%, 10% 10%, 15% 15%, 10% 10%, 18% 18%;
  background-position: 50% 120%;
  animation: contactTopBubbles 0.6s ease forwards;
}

@keyframes contactTopBubbles {
  0% {
    background-position: 5% 90%, 10% 90%, 10% 90%, 15% 90%, 25% 90%, 25% 90%, 40% 90%, 55% 90%, 70% 90%;
  }
  50% {
    background-position: 0% 80%, 0% 20%, 10% 40%, 20% 0%, 30% 30%, 22% 50%, 50% 50%, 65% 20%, 90% 30%;
  }
  100% {
    background-position: 0% 70%, 0% 10%, 10% 30%, 20% -10%, 30% 20%, 22% 40%, 50% 40%, 65% 10%, 90% 20%;
    background-size: 0% 0%, 0% 0%, 0% 0%, 0% 0%, 0% 0%, 0% 0%;
  }
}

#email-link:hover::after {
  bottom: -70%;
  background-image:
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, transparent 10%, var(--accent-color) 15%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%),
    radial-gradient(circle, var(--accent-color) 20%, transparent 20%);
  background-size: 15% 15%, 20% 20%, 18% 18%, 20% 20%, 15% 15%, 20% 20%, 18% 18%;
  background-position: 50% 0%;
  animation: contactBottomBubbles 0.6s ease forwards;
}

@keyframes contactBottomBubbles {
  0% {
    background-position: 10% -10%, 30% 10%, 55% -10%, 70% -10%, 85% -10%, 70% -10%, 70% 0%;
  }
  50% {
    background-position: 0% 80%, 20% 80%, 45% 60%, 60% 100%, 75% 70%, 95% 60%, 105% 0%;
  }
  100% {
    background-position: 0% 90%, 20% 90%, 45% 70%, 60% 110%, 75% 80%, 95% 70%, 110% 10%;
    background-size: 0% 0%, 0% 0%, 0% 0%, 0% 0%, 0% 0%, 0% 0%;
  }
}

.tech-badge.active-nav {
  background-color: var(--hover-bg);
  border-color: var(--accent-color);
  color: var(--accent-color);
}

.tech-badge.active-nav svg path,
.tech-badge.active-nav svg circle,
.tech-badge.active-nav svg rect,
.tech-badge.active-nav svg line,
.tech-badge.active-nav svg polygon {
  stroke: var(--accent-color);
}

/* Section divider */
.section-divider {
  width: 100%;
  max-width: 1150px;
  height: 2px;
  background-color: #1a1a1a;
  margin: 180px auto;
  opacity: 0.8;
}

/* Legacy nav links */
.nav-link {
  display: flex;
  align-items: center;
  color: var(--text-color);
  text-decoration: none;
  font-size: var(--font-size-small);
  font-family: var(--font-main);
  font-weight: 600;
  transition: color var(--transition-speed) ease-in-out;
  position: relative;
}

.nav-link img {
  width: 24px;
  height: 24px;
  margin-right: 10px;
  transition: opacity var(--transition-speed) ease-in-out;
}

.nav-link .icon-hover {
  position: absolute;
  opacity: 0;
  transform: rotate(10deg);
}

.nav-link:hover .icon-default {
  opacity: 0;
}

.nav-link:hover .icon-hover {
  opacity: 1;
}

.nav-link:hover {
  color: var(--accent-color);
}

.nav-link.active-nav {
  color: var(--accent-color);
}

.nav-link.active-nav .icon-default {
  opacity: 0;
}

.nav-link.active-nav .icon-hover {
  opacity: 1;
}

/* Section styles */
.section-container {
  margin-top: var(--section-spacing);
  max-width: 1150px;
  margin-left: auto;
  margin-right: auto;
  width: 100%;
  box-sizing: border-box;
}

/* Section headers */
.section-header {
  max-width: 1150px;
  margin: 0 auto 10px auto;
  text-align: left;
}

.section-header h2 {
  font-size: 36px;
  font-family: var(--font-title);
  font-weight: 700;
  color: var(--accent-color);
  display: inline-block;
  line-height: var(--line-height-tight);
  letter-spacing: -0.01em;
  margin-bottom: 60px;
}

/* Section intro */
.section-intro-container {
  background-color: var(--bg-color-light);
  border: 1px solid var(--bg-color-lighter);
  border-radius: 20px;
  padding: 30px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  display: flex;
  align-items: center;
  gap: 25px;
  margin-bottom: 100px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.section-intro-container:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.3);
}

.section-intro {
  flex: 3;
  font-size: 18px;
  font-family: var(--font-main);
  font-weight: 400;
  color: var(--text-color-secondary);
  line-height: var(--line-height-loose);
  letter-spacing: 0.015em;
  margin: 0;
}

.section-image {
  flex: 1;
  max-width: 25%;
  display: flex;
  justify-content: center;
  padding-right: 15px;
  align-items: center;
  perspective: 1000px;
}

.section-image img {
  max-width: 160px;
  height: auto;
  border-radius: 0;
  transition: transform 0.8s cubic-bezier(0.19, 1, 0.22, 1);
  will-change: transform;
  transform-style: preserve-3d;
}

/* Animation keyframes */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

@keyframes scaleUp {
  from {
    opacity: 0;
    transform: scale(0.96);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

.scroll-reveal {
  will-change: transform, opacity;
  backface-visibility: hidden;
}

/* Links section */
#links {
  margin-top: 0;
  margin-bottom: var(--section-spacing);
}

.links-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 40px;
  max-width: 1150px;
  margin: 0 auto 100px auto;
  padding: 0;
  box-sizing: border-box;
}

.links-column {
  flex: 1;
  min-width: 200px;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.5s ease;
}

.links-column:nth-child(3) {
  flex: 1;
}

.links-column.show {
  opacity: 1;
  transform: translateY(0);
}

.column-title {
  font-family: var(--font-title);
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 20px;
  color: var(--text-color);
  position: relative;
  padding-bottom: 10px;
  line-height: var(--line-height-tight);
  letter-spacing: -0.01em;
}

.column-title::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 40px;
  height: 2px;
  background-color: var(--accent-color);
}

.column-subtitle {
  font-size: 18px;
  color: var(--text-color-secondary);
  margin: 4px 0 18px;
  line-height: 1.55;
  opacity: 0.75;
}

.links-list {
  list-style: none;
  padding: 0;
  margin: 0;
  margin-top: 10px;
}

.links-list li {
  margin-bottom: 5px;
}

.link-item {
  color: var(--text-color-secondary);
  text-decoration: none;
  font-size: 18px;
  position: relative;
  transition: color 0.3s ease;
  display: inline-block;
  padding: 5px 0;
}

.link-item:hover {
  color: var(--accent-color);
}

.modal-link-button {
  display: inline-block;
  margin-top: 6px;
  margin-bottom: 24px;
  color: var(--bg-color);
  font-size: 16px;
  text-decoration: none;
  opacity: 0.55;
  transition: opacity 0.2s ease;
}

.modal-link-button:hover {
  opacity: 1;
}

.project-tag {
  color: var(--accent-color);
  font-size: 12px;
  margin-left: 6px;
  background-color: var(--bg-color-light);
  border: 1px solid var(--bg-color-lighter);
  border-radius: 10px;
  padding: 2px 6px;
  display: inline-block;
  font-weight: 300;
  letter-spacing: 0.02em;
}

/* Project descriptions */
.project-description, .labs-description {
  color: var(--text-color-secondary);
  font-size: 18px;
  margin: 0 0 10px 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}

/* Info settings container */
.info-settings-container {
  margin-top: 200px;
  width: 100%;
}

.info-buttons {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 20px;
  justify-content: center;
}

/* Subtle footer text links */
.footer-link {
  font-size: 16px;
  color: #4a4a4a;
  text-decoration: none;
  letter-spacing: 0.04em;
  transition: color 0.2s ease;
  cursor: pointer;
}

.footer-link:hover {
  color: #888;
}

.footer-sep {
  font-size: 16px;
  color: #2e2e2e;
  user-select: none;
}

/* Gallery */
.gallery-container {
  margin-top: 200px;
  width: 100%;
}

.media-items {
  display: flex;
  gap: 20px;
  justify-content: space-between;
}

.media-item {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  height: 650px;
}

.video-item {
  flex: 1;
}

.media-content {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* About Card */
.about-card {
  flex: 2;
  border-radius: 20px;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 40px;
  box-sizing: border-box;
  --bg-image: url('images/grape.jpg');
}

.about-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: var(--bg-image);
  background-size: cover;
  background-position: center;
  filter: blur(22px);
  transform: scale(1.1);
  z-index: 1;
}

.about-card::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.2);
  z-index: 2;
}

.about-card-content {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 25px;
  text-align: center;
}

.about-card-image {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.2), 0 4px 20px rgba(0, 0, 0, 0.3);
}

.about-card-profile-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.about-card-image:hover .about-card-profile-img {
  transform: scale(1.05);
}

.about-card-name {
  font-family: var(--font-title);
  font-size: 32px;
  margin: 0;
  color: var(--text-color);
  font-weight: 700;
}

.about-card-location {
  font-family: var(--font-main);
  font-size: 18px;
  color: var(--text-color-secondary);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Modals */
.legal-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  overflow-y: auto;
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.legal-modal-content {
  background-color: var(--text-color);
  margin: 50px auto;
  padding: 30px;
  border-radius: 15px;
  width: 80%;
  max-width: 1100px;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
  animation: modalFadeIn 0.3s;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.close-legal-modal, .close-labs-modal {
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 28px;
  color: var(--text-color-secondary);
  cursor: pointer;
  transition: color 0.2s;
  padding: 0;
  background: none;
  border: none;
  line-height: 0.8;
  z-index: 10;
}

.close-legal-modal:hover, .close-labs-modal:hover {
  color: var(--bg-color);
}

.legal-content {
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.6;
  color: var(--bg-color);
}

.legal-content h2 {
  color: var(--bg-color);
  margin-bottom: 20px;
  font-size: 24px;
  line-height: var(--line-height-tight);
}

.legal-content h3 {
  color: var(--bg-color);
  margin-top: 25px;
  font-size: 18px;
  line-height: var(--line-height-tight);
}

.legal-content p {
  margin-bottom: 15px;
  line-height: var(--line-height-loose);
  letter-spacing: 0.015em;
}

/* Labs modal */
.labs-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  z-index: 1000;
  overflow-y: auto;
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.labs-modal-content {
  background-color: var(--text-color);
  margin: 50px auto;
  padding: 48px 56px;
  border-radius: 15px;
  width: 80%;
  max-width: 1100px;
  max-height: 80vh;
  overflow-y: auto;
  position: relative;
  animation: modalFadeIn 0.3s;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  scrollbar-width: thin;
  scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

.labs-modal-content::-webkit-scrollbar {
  width: 4px;
}

.labs-modal-content::-webkit-scrollbar-track {
  background: transparent;
}

.labs-modal-content::-webkit-scrollbar-thumb {
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 2px;
}

.legal-modal-content > h2,
.labs-modal-content > h2 {
  color: var(--bg-color);
  font-family: 'PT Serif', serif;
  font-weight: 700;
  margin-bottom: 36px;
  font-size: 36px;
  line-height: var(--line-height-tight);
  padding-right: 50px;
}

.labs-content {
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.6;
  color: var(--bg-color);
}

.labs-content h2 {
  color: var(--bg-color);
  margin-bottom: 20px;
  font-size: 24px;
  line-height: var(--line-height-tight);
}

.labs-content p {
  margin-bottom: 8px;
  line-height: var(--line-height-loose);
  letter-spacing: 0.015em;
}

.modal-project-block {
  margin-bottom: 0;
}

.modal-project-title {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 700;
  color: var(--bg-color);
  margin: 0 0 8px;
}

.modal-project-divider {
  border: none;
  border-top: 1px solid rgba(0,0,0,0.12);
  margin: 32px 0;
}

.labs-images {
  display: flex;
  gap: 16px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.labs-image {
  flex: 1;
  min-width: 300px;
  border-radius: 6px;
  overflow: hidden;
  height: auto;
  max-width: 100%;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Page transitions */
.page-transition-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color);
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--page-transition) ease;
}

.page-transition-overlay.active {
  opacity: 1;
  pointer-events: all;
}

/* Hover trigger */
.about-trigger {
  position: relative;
}

.about-trigger.active {
  background-color: var(--hover-bg);
  border-color: var(--accent-color);
  color: var(--accent-color);
}

.about-trigger.active svg path,
.about-trigger.active svg circle {
  stroke: var(--accent-color);
}

/* Labs description */
.labs-description {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 5px;
  margin: 8px 0;
}

.labs-description .link-item {
  display: inline;
}

/* Fixed body for modals */
body.modal-open {
  position: fixed;
  width: 100%;
  overflow: hidden;
}

/* Modal backgrounds */
.legal-modal, .labs-modal {
  z-index: 9999;
  background-color: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

/* Slider indicators */
.slider-indicators, .scroll-hint {
  display: none;
  pointer-events: none;
  visibility: hidden;
  position: absolute;
  z-index: -1;
}

.indicator {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--bg-color-lighter);
  transition: background-color 0.3s ease;
  cursor: pointer;
}

.indicator.active {
  background-color: var(--accent-color);
}

/* RESPONSIVE STYLES */
/* Large screens */
@media (max-width: 1200px) {
  .content, .section-header, .links-container, .gallery-container, .info-settings-container {
    width: 85%;
    padding-left: var(--page-padding);
    padding-right: var(--page-padding);
    box-sizing: border-box;
  }
  
  .links-container {
    gap: 30px;
  }
  
  .labs-image {
    min-width: 250px;
  }
  
  .info-buttons {
    gap: 10px;
  }
  
  .section-divider {
    width: 85%;
  }
  
  .about-card-content {
    padding: 30px;
  }
  
  .about-card-name {
    font-size: 28px;
  }
}

/* Tablet screens */
@media (max-width: 1024px) {
  .site-header {
    top: 40px;
    left: 40px;
  }
  
  .content {
    margin-top: 120px;
    font-size: var(--mobile-font-size-large);
    width: 80%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
    text-align: left;
  }
  
  #description {
    width: 80%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
    text-align: left;
    top: 20px;
    margin-top: 0;
  }
  
  #link-container {
    width: 80%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  :root {
    --section-spacing: 120px;
  }
  
  #links {
    width: 80%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  .section-header, .links-container, .gallery-container, .info-settings-container {
    width: 90%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  .section-divider {
    width: 90%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
  }
  
  #description {
    width: 90%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  .section-header h2 {
    font-size: var(--mobile-font-size-medium);
  }
  
  .section-intro-container {
    flex-direction: column;
  }
  
  .section-intro {
    flex: 1;
    width: 100%;
    font-size: var(--mobile-font-size-xs);
    line-height: var(--line-height-loose);
  }
  
  .section-image {
    flex: 1;
    max-width: 100%;
    margin-top: 20px;
    justify-content: center;
  }
  
  .links-container {
    gap: 25px;
  }
  
  .column-title {
    font-size: 26px;
  }
  
  .media-item {
    height: 650px;
  }
  
  .about-card {
    padding: 30px;
  }
  
  .about-card-content {
    padding: 30px;
  }
  
  .about-card-image {
    width: 140px;
    height: 140px;
  }
  
  .about-card-name {
    font-size: 26px;
  }
  
  .labs-modal-content {
    width: 90%;
  }
  
  .labs-images {
    flex-direction: column;
  }
  
  .labs-image {
    min-width: 100%;
  }
  
  .info-settings-container {
    margin-top: 120px;
  }
  
  .info-buttons {
    gap: 8px;
    flex-wrap: wrap;
    justify-content: center;
  }
  
  .gallery-container {
    margin-top: 160px;
  }
  
  .section-divider {
    margin: 120px auto;
  }
}

/* Kleinere Tablets */
@media (max-width: 768px) {
  .content {
    width: 85%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
    text-align: left;
  }
  
  #description {
    width: 85%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
    text-align: left;
    top: 20px;
    margin-top: 0;
  }
  
  #link-container {
    width: 85%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  #links {
    width: 85%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  .section-header, .links-container, .gallery-container, .info-settings-container {
    width: 90%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    padding-left: 0;
    padding-right: 0;
    box-sizing: border-box;
  }
  
  .section-divider {
    width: 90%;
    max-width: 1150px;
    margin-left: auto;
    margin-right: auto;
    margin-top: 40px;
    margin-bottom: 40px;
  }
  
  .section-intro-container {
    flex-direction: column;
  }
  
  .section-image {
    max-width: 100%;
    margin-top: 30px;
    justify-content: flex-start;
  }
}

/* MOBILE VIEW - NUR FÜR ECHTE SMARTPHONES (unter 600px) */
@media (max-width: 600px) and (pointer: coarse) {
  .media-items {
    display: flex;
    flex-direction: column !important;
    gap: 20px;
  }
  
  .video-item {
    height: 550px !important;
    border-radius: 20px !important;
    overflow: hidden;
  }
  
  .video-item .media-content {
    border-radius: 20px !important;
  }
  
  .about-card {
    height: 750px !important; 
    min-height: 750px !important; 
    padding: 30px 20px;
    border-radius: 20px !important;
  }
  
  .about-card-content {
    gap: 20px;
  }
  
  .about-card-image {
    width: 140px;
    height: 140px;
  }
  
  .about-card-name {
    font-size: 26px;
  }
  
  .about-card-location {
    font-size: 18px;
  }
  
  .slider-indicators, .scroll-hint {
    display: none;
    pointer-events: none;
    visibility: hidden;
    position: absolute;
    z-index: -1;
  }
}

/* MOBILE VIEW - Hauptstyles für Smartphones */
@media (max-width: 600px) and (pointer: coarse) {
  body {
    padding: 0;
    margin: 0;
    width: 100%;
    overflow-x: hidden;
  }
  
  :root {
    --section-spacing: 80px;
  }
  
  .site-header {
    position: relative;
    top: auto;
    left: auto;
    text-align: left;
    padding: 55px 0 5px calc(var(--mobile-side-padding) + 10px); 
    width: 100%;
    box-sizing: border-box;
  }
  
  .logo {
    margin-left: 0;
  }
  
  .section-container,
  .section-header, 
  .links-container, 
  .gallery-container,
  .info-settings-container {
    width: calc(100% - calc(var(--mobile-side-padding) * 2)) !important;
    margin-left: var(--mobile-side-padding) !important;
    margin-right: var(--mobile-side-padding) !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
    max-width: calc(100% - calc(var(--mobile-side-padding) * 2)) !important;
  }
  
  .content, 
  #link-container {
    width: calc(100% - calc(var(--mobile-side-padding) * 2)) !important;
    margin-left: calc(var(--mobile-side-padding) + 10px) !important;
    margin-right: calc(var(--mobile-side-padding) - 10px) !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
    max-width: calc(100% - calc(var(--mobile-side-padding) * 2)) !important;
  }
  
  #description {
    width: calc(100% - calc(var(--mobile-side-padding) * 2)) !important;
    margin-left: calc(var(--mobile-side-padding) - 13px) !important; 
    margin-right: calc(var(--mobile-side-padding) + 13px) !important; 
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
    max-width: calc(100% - calc(var(--mobile-side-padding) * 2)) !important;
  }
  
  .section-divider {
    width: calc(100% - calc(var(--mobile-side-padding) * 2 + 20px)) !important; 
    margin-left: calc(var(--mobile-side-padding) + 10px) !important; 
    margin-right: calc(var(--mobile-side-padding) + 10px) !important; 
    margin-top: 30px;
    margin-bottom: 30px;
  }
  
  .info-buttons,
  .media-items {
    width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
  
  .content {
    margin-top: 5px;
    font-size: var(--mobile-font-size-large);
    line-height: 1.3;
  }
  
  #description {
    top: 0 !important;
    margin-top: 20px !important;
    text-align: left !important;
    font-size: var(--mobile-font-size-small);
    padding-left: 0 !important;
  }
  
  #link-container {
    margin-top: 64px;
    gap: 10px;
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    margin-bottom: 80px !important;
  }
  
  .tech-badge {
    font-size: 16px;
    padding: 12px 18px;
    margin-bottom: 5px;
    line-height: 1.3;
    border-radius: 20px !important;
  }
  
  .section-container {
    margin-top: var(--section-spacing);
  }
  
  .section-intro-container {
    flex-direction: column;
    margin-bottom: 60px;
  }
  
  .section-intro {
    width: 100%;
    font-size: var(--mobile-font-size-xs);
  }
  
  .section-image {
    width: 100%;
    max-width: 100%;
    margin-top: 20px;
  }
  
  .links-container {
    flex-direction: column;
    gap: 30px;
    margin-bottom: 30px;
  }
  
  .links-column {
    width: 100%;
    margin-bottom: 15px !important;
  }
  
  .column-title {
    font-size: 32px;
  }
  
  .links-list {
    text-align: left;
  }
  
  .links-list li {
    margin-bottom: 0 !important;
  }
  
  .link-item {
    font-size: 20px;
    text-align: left;
    display: block;
    padding: 10px 0;
  }
  
  .gallery-container {
    margin-top: 100px;
  }
  
  .media-item {
    height: 520px;
  }
  
  .project-description {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 5px;
    margin: 8px 0;
    font-size: 20px;
  }
  
  .project-description .link-item,
  .labs-description .link-item {
    padding: 5px 0;
    display: inline;
  }
  
  .project-tag {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    margin-left: 5px;
  }
  
  .labs-description {
    display: flex;
    align-items: center;
    flex-wrap: nowrap;
    gap: 5px;
    margin: 8px 0;
    font-size: 20px;
  }
  
  .hovercard-image {
    width: 120px;
    height: 120px;
  }
  
  .info-settings-container {
    margin-top: 140px;
    margin-bottom: 50px;
  }
  
  .info-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
  }
  
  .legal-modal, .labs-modal {
    -webkit-overflow-scrolling: touch;
    overflow-y: auto;
  }
  
  .legal-modal-content, .labs-modal-content {
    margin: 10% auto;
    width: 90%;
    max-height: 80vh;
    padding: 20px;
    position: relative;
    transform: translateZ(0);
    will-change: transform;
  }
  
  .close-legal-modal, .close-labs-modal {
    padding: 12px;
    top: 5px;
    right: 5px;
    font-size: 28px;
    z-index: 10;
    line-height: 0.8;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
  }
  
  .labs-images {
    display: flex;
    flex-direction: column;
    gap: 15px;
  }
  
  .labs-image {
    width: 100%;
    max-width: 100%;
    height: auto;
    margin: 0;
  }
  
}

/* SEHR KLEINE SMARTPHONES */
@media (max-width: 480px) {
  :root {
    --section-spacing: 80px;
    --mobile-side-padding: 15px;
  }
  
  .content {
    margin-top: 80px;
    font-size: 48px;
  }
  
  #description {
    font-size: 20px;
  }
  
  #link-container {
    margin-top: 32px;
    gap: 8px;
  }
  
  .tech-badge {
    font-size: 15px;
    padding: 10px 14px;
    gap: 6px;
  }
  
  .tech-badge svg {
    width: 16px;
    height: 16px;
  }
  
  .section-container {
    margin-top: 60px;
  }
  
  .section-header {
    margin-bottom: 20px !important;
  }
  
  .section-intro-container {
    margin-bottom: 20px !important;
  }
  
  .section-header h2 {
    font-size: 30px;
  }
  
  .media-item {
    height: 300px;
  }
  
  .column-title {
    font-size: 26px;
    margin-bottom: 15px;
  }
  
  .link-item {
    font-size: 18px;
    padding: 12px 0;
  }
  
  .hovercard-image {
    width: 120px;
    height: 120px;
  }
  
  .labs-content h2 {
    font-size: 20px;
  }
  
  .labs-content p {
    font-size: 15px;
  }
  
  .project-description,
  .labs-description {
    font-size: 18px;
  }
  
  .info-settings-container {
    margin-top: 80px;
    margin-bottom: 40px;
  }
  
  .info-buttons {
    gap: 12px;
  }
  
  .legal-modal-content, .labs-modal-content {
    padding: 15px;
    margin: 20px auto;
  }
  
  .close-legal-modal, .close-labs-modal {
    font-size: 24px;
    top: 15px;
    right: 15px;
  }
  
  .video-item {
    height: 360px;
  }
  
  .about-card {
    height: 350px !important; 
    min-height: 350px !important; 
  }
  
  .about-card-content {
    padding: 20px;
  }
  
  .about-card-image {
    width: 100px;
    height: 100px;
  }
  
  .about-card-name {
    font-size: 20px;
  }
  
  .about-card-location {
    font-size: 14px;
  }
  
  .gallery-container {
    margin-top: 120px;
  }
  
  .section-divider {
    margin: 80px auto !important;
  }
}