@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

:root {
  --bg-primary: #111827;
  --bg-secondary: #1f2937;
  --text-primary: #f3f4f6;
  --text-secondary: #9ca3af;
  --primary-color: #6366f1;
  --secondary-color: #4f46e5;
  --card-bg: rgba(17, 24, 39, 0.7);
  --card-border: rgba(255, 255, 255, 0.1);
  --glass-bg: rgba(255, 255, 255, 0.1);
  --glass-border: rgba(255, 255, 255, 0.2);
  --neuro-shadow-light: 8px 8px 16px rgba(0,0,0,0.1), -8px -8px 16px rgba(255,255,255,0.7);
  --neuro-shadow-dark: 8px 8px 16px rgba(0,0,0,0.5), -8px -8px 16px rgba(255,255,255,0.1);
}

:root.light {
  --bg-primary: #f8fafc;
  --bg-secondary: #ffffff;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --card-bg: rgba(255, 255, 255, 0.8);
  --card-border: rgba(99, 102, 241, 0.1);
  --glass-bg: rgba(255, 255, 255, 0.8);
  --glass-border: rgba(99, 102, 241, 0.2);
  --neuro-shadow-light: 8px 8px 16px rgba(99, 102, 241, 0.1), -8px -8px 16px rgba(255, 255, 255, 0.8);
  --neuro-shadow-dark: 8px 8px 16px rgba(99, 102, 241, 0.1), -8px -8px 16px rgba(255, 255, 255, 0.8);
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
  width: 100%;
  position: relative;
  word-wrap: break-word;
  -webkit-hyphens: auto;
  -ms-hyphens: auto;
  hyphens: auto;
}

.dark {
  --bg-primary: #121212;
  --text-primary: #f3f4f6;
  --text-secondary: #d1d5db;
  --primary-color: #6366f1;
  --secondary-color: #8b5cf6;
}

.light {
  --bg-primary: #f8fafc;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --primary-color: #4f46e5;
  --secondary-color: #7c3aed;
}

.glass-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  backdrop-filter: blur(10px);
  transition: all 0.3s ease;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.glass-card:hover {
  background: var(--card-bg);
  border-color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.neuro-card {
  border-radius: 1rem;
  background: var(--bg-primary);
  box-shadow: var(--neuro-shadow-light);
  transition: all 0.3s ease;
  border: 1px solid var(--card-border);
}

.dark .neuro-card {
  box-shadow: var(--neuro-shadow-dark);
}

.neuro-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.skill-icon {
  font-size: 2rem;
  transition: all 0.3s ease;
}

.skill-icon:hover {
  transform: scale(1.2);
  color: var(--primary-color);
}

.hero-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  z-index: -1;
}

.timeline-item {
  position: relative;
  padding-left: 2rem;
  margin-bottom: 2rem;
}

.timeline-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 2px;
  background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
}

.timeline-item::after {
  content: '';
  position: absolute;
  left: -0.5rem;
  top: 0;
  height: 1rem;
  width: 1rem;
  border-radius: 50%;
  background: var(--primary-color);
  border: 2px solid var(--bg-primary);
}

.project-card {
  overflow: hidden;
  position: relative;
  border-radius: 1rem;
  transition: all 0.3s ease;
  height: 250px;
  background: var(--bg-primary);
  width: 100%;
}

.project-card img {
  display: none;
}

.project-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  background: rgba(17, 24, 39, 0.95);
  overflow: hidden;
  width: 100%;
  height: 100%;
  opacity: 1;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 1rem;
  z-index: 2;
  box-sizing: border-box;
}

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

.project-overlay h3 {
  color: white;
  font-weight: 600;
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  transform: translateY(0);
  opacity: 1;
  transition: all 0.3s ease;
  width: 100%;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  line-height: 1.2;
}

.project-overlay p {
  color: #e5e7eb;
  font-size: 0.9rem;
  margin-bottom: 1rem;
  transform: translateY(0);
  opacity: 1;
  text-align: center;
  transition: all 0.3s ease;
  width: 100%;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.project-overlay .flex {
  transform: translateY(0);
  opacity: 1;
  transition: all 0.3s ease;
  width: 90%;
  justify-content: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.project-overlay .flex.space-x-3 {
  margin-top: 1.5rem;
}

.project-overlay .rounded-full {
  background: rgba(79, 70, 229, 0.3);
  border: 1px solid rgba(99, 102, 241, 0.5);
  backdrop-filter: blur(4px);
  padding: 0.25rem 0.75rem;
  font-size: 0.8rem;
  margin: 0.25rem;
}

.project-overlay .flex.space-x-3 a {
  padding: 0.5rem 1.25rem;
  font-size: 0.875rem;
  transition: all 0.3s ease;
  border: 1px solid transparent;
  min-width: 120px;
  text-align: center;
}

.project-overlay .flex.space-x-3 a:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.slide-in-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: all 0.5s ease;
}

.slide-in-right {
  opacity: 0;
  transform: translateX(50px);
  transition: all 0.5s ease;
}

.slide-in-up {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.5s ease;
}

.visible {
  opacity: 1;
  transform: translate(0);
}

.skill-card {
  transform-style: preserve-3d;
  perspective: 1000px;
  animation: float 3s ease-in-out infinite;
  background: var(--card-bg);
  border-radius: 0.75rem;
  backdrop-filter: blur(10px);
  padding: 1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 60px;
  border: 1px solid var(--card-border);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.skill-card:hover {
  transform: translateY(-5px);
  background: var(--glass-bg);
  border-color: var(--primary-color);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.skill-card h4 {
  font-size: 1.1rem;
  margin: 0;
  font-weight: 500;
}

.grid.grid-cols-2.md\:grid-cols-4 {
  gap: 0.75rem;
}

.skills-section {
  margin-top: -2rem;
  padding-top: 1rem;
  margin-bottom: 3rem;
  padding: 2.5rem;
  border-radius: 1rem;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.skills-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  opacity: 0.8;
}

.skills-section:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  border-color: var(--primary-color);
}

.skills-section h3 {
  margin-bottom: 1.5rem;
  font-size: 1.5rem;
  color: var(--text-primary);
  opacity: 0.9;
  position: relative;
  padding-bottom: 0.5rem;
}

.skills-section h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 50px;
  height: 2px;
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  border-radius: 2px;
}

.skills-section .grid {
  margin-top: 2rem;
  padding-top: 1rem;
}

.skill-card:hover .skill-icon {
  filter: drop-shadow(0 0 8px currentColor);
  transform: scale(1.1);
  transition: all 0.3s ease;
}

#theme-toggle {
  transition: all 0.3s ease;
}

#theme-toggle i {
  transition: all 0.3s ease;
}

.dark #theme-toggle i {
  color: var(--text-primary);
}

.light #theme-toggle i {
  color: #f59e0b;
}

.light .project-card {
  background: var(--bg-primary);
  border: 1px solid var(--card-border);
}

.light .project-overlay {
  background: rgba(248, 250, 252, 0.95);
}

.light .project-overlay h3 {
  color: var(--text-primary);
}

.light .project-overlay p {
  color: var(--text-secondary);
}

.light .project-overlay .rounded-full {
  background: rgba(79, 70, 229, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.2);
  color: var(--primary-color);
}

.light .timeline-item::before {
  background: linear-gradient(to bottom, var(--primary-color), var(--secondary-color));
}

.light .timeline-item::after {
  background: var(--primary-color);
  border: 2px solid var(--bg-primary);
}

.light input, .light textarea {
  background: var(--bg-secondary);
  border-color: var(--card-border);
  color: var(--text-primary);
}

.light input:focus, .light textarea:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.1);
}

.light .text-gray-300 {
  color: var(--text-secondary);
}

.light .text-gray-400 {
  color: var(--text-secondary);
}

.light .bg-gray-800 {
  background-color: var(--bg-secondary);
}

.light .bg-gray-900 {
  background-color: var(--bg-primary);
}

.light .border-gray-800 {
  border-color: var(--card-border);
}

.light .hover\:bg-gray-700:hover {
  background-color: rgba(79, 70, 229, 0.1);
}

.light .hover\:text-white:hover {
  color: var(--primary-color);
}

.light .text-gray-300,
.light .text-gray-400,
.light .text-gray-500 {
  color: #64748b;
}

.light .text-gray-600,
.light .text-gray-700,
.light .text-gray-800,
.light .text-gray-900 {
  color: #1e293b;
}

.light .text-white {
  color: #1e293b;
}

.light .text-indigo-400 {
  color: #6366f1;
}

.light .text-indigo-300 {
  color: #4f46e5;
}

.light .bg-gray-800 {
  background-color: #f1f5f9;
}

.light .bg-gray-900 {
  background-color: #f8fafc;
}

.light .border-gray-800 {
  border-color: #e2e8f0;
}

.light .hover\:bg-gray-700:hover {
  background-color: rgba(79, 70, 229, 0.1);
}

.light .hover\:text-white:hover {
  color: #4f46e5;
}

.light .project-overlay {
  background: rgba(248, 250, 252, 0.95);
}

.light .project-overlay h3 {
  color: #1e293b;
}

.light .project-overlay p {
  color: #64748b;
}

.light .project-overlay .rounded-full {
  background: rgba(79, 70, 229, 0.1);
  border: 1px solid rgba(79, 70, 229, 0.2);
  color: #4f46e5;
}

.light .timeline-item::before {
  background: linear-gradient(to bottom, #4f46e5, #7c3aed);
}

.light .timeline-item::after {
  background: #4f46e5;
  border: 2px solid #f8fafc;
}

.light input, .light textarea {
  background: #ffffff;
  border-color: #e2e8f0;
  color: #1e293b;
}

.light input:focus, .light textarea:focus {
  border-color: #4f46e5;
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.1);
}

.light .bg-indigo-900 {
  background-color: rgba(79, 70, 229, 0.1);
}

.light .text-indigo-300 {
  color: #4f46e5;
}

.light .bg-gradient-to-r {
  background-image: linear-gradient(to right, #4f46e5, #7c3aed);
}

.light .text-gray-100,
.light .text-gray-200 {
  color: #1e293b;
}

@keyframes float {
  0% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
  100% { transform: translateY(0px); }
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 80%;
  max-width: 300px;
  height: 100vh;
  background: var(--bg-primary);
  z-index: 1000;
  transition: right 0.3s ease;
  overflow-y: auto;
  padding-top: 4rem;
  box-shadow: -2px 0 5px rgba(0, 0, 0, 0.1);
}

.mobile-menu.active {
  right: 0;
}

.mobile-menu-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.mobile-menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-menu .nav-link {
  display: block;
  padding: 1rem 2rem;
  color: var(--text-primary);
  font-size: 1.1rem;
  border-bottom: 1px solid var(--card-border);
  transition: all 0.3s ease;
}

.mobile-menu .nav-link:hover {
  background: var(--card-bg);
  color: var(--primary-color);
}

.mobile-menu .nav-link.active {
  background: var(--card-bg);
  color: var(--primary-color);
}

.mobile-menu-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 1001;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
  transition: all 0.3s ease;
  background: none;
  border: none;
  padding: 0.5rem;
}

.mobile-menu-close:hover {
  color: var(--primary-color);
  transform: rotate(90deg);
}

header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 900;
  background: var(--bg-primary);
  backdrop-filter: blur(10px);
}

main {
  padding-top: 4rem;
}

.apps-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  height: 100vh;
  z-index: 1000;
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  opacity: 0;
  visibility: hidden;
}

.apps-menu.active {
  right: 0;
  opacity: 1;
  visibility: visible;
}

.apps-menu-content {
  background: rgba(17, 24, 39, 0.7);
  border-radius: 1rem;
  padding: 1.5rem;
  width: 340px;
  margin-top: 4rem;
  margin-right: 1rem;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(4px);
  transform: translateY(-20px) scale(0.95);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.apps-menu.active .apps-menu-content {
  transform: translateY(0) scale(1);
}

.apps-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.apps-menu-header h3 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-primary);
  background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.apps-menu-close {
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 1.25rem;
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0.5rem;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.apps-menu-close:hover {
  color: var(--primary-color);
  transform: rotate(90deg);
  background: rgba(255, 255, 255, 0.1);
}

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

.app-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.25rem;
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  color: var(--text-primary);
  position: relative;
  overflow: hidden;
}

.app-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(45deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  transform: translateX(-100%);
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.app-item:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--primary-color);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.app-item:hover::before {
  transform: translateX(100%);
}

.app-item i {
  font-size: 1.75rem;
  margin-bottom: 0.75rem;
  transition: all 0.3s ease;
  background: linear-gradient(45deg, #FF6B6B, #4ECDC4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

.app-item:nth-child(1) i {
  background: linear-gradient(45deg, #FF6B6B, #FF8E53);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.app-item:nth-child(2) i {
  background: linear-gradient(45deg, #4ECDC4, #45B7D1);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.app-item:nth-child(3) i {
  background: linear-gradient(45deg, #96E6A1, #D4FC79);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.app-item:nth-child(4) i {
  background: linear-gradient(45deg, #A8EDEA, #FED6E3);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.app-item:hover i {
  transform: scale(1.1);
  filter: drop-shadow(0 0 12px rgba(0, 0, 0, 0.2));
}

.app-item span {
  font-size: 0.875rem;
  text-align: center;
  font-weight: 500;
  transition: all 0.3s ease;
}

.app-item:hover span {
  color: var(--primary-color);
}

.light .apps-menu-content {
  background: rgba(248, 250, 252, 0.7);
  border: 1px solid rgba(99, 102, 241, 0.1);
}

.light .app-item {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(99, 102, 241, 0.1);
}

.light .app-item:hover {
  background: rgba(255, 255, 255, 0.8);
  border-color: var(--primary-color);
}

.light .apps-menu-header {
  border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.grid-icon {
  width: 24px;
  height: 24px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  gap: 2px;
  padding: 2px;
}

.grid-icon span {
  width: 4px;
  height: 4px;
  background-color: var(--text-primary);
  border-radius: 50%;
  display: block;
  margin: auto;
  transition: background-color 0.3s ease;
}

.mobile-menu-button:hover .grid-icon span {
  background-color: var(--text-primary);
}

.light .grid-icon span {
  background-color: #5f6368;
}

.light .mobile-menu-button:hover .grid-icon span {
  background-color: #202124;
}

.timeline-date {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.timeline-date .date {
  font-weight: 500;
  color: var(--primary-color);
}

.timeline-date .location {
  position: relative;
  padding-left: 0.5rem;
}

.timeline-date .location::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 4px;
  background-color: var(--text-secondary);
  border-radius: 50%;
}

@media (max-width: 768px) {
  .container {
    width: 100%;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  section {
    width: 100%;
    padding-left: 0.5rem;
    padding-right: 0.5rem;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  h1 {
    font-size: 2rem !important;
    line-height: 1.3;
  }

  h2 {
    font-size: 1.75rem !important;
    line-height: 1.3;
  }

  h3 {
    font-size: 1.25rem !important;
    line-height: 1.3;
  }

  h4 {
    font-size: 1.1rem !important;
    line-height: 1.3;
  }

  .project-overlay {
    padding: 0.75rem;
    width: 100%;
    overflow-x: hidden;
  }

  .project-overlay h3 {
    width: 100%;
    padding: 0;
    font-size: 1rem;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
  }

  .project-overlay p {
    width: 100%;
    padding: 0;
    font-size: 0.85rem;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
  }

  .timeline-item {
    padding-left: 1.25rem;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
    margin-bottom: 1.5rem;
  }

  .timeline-item h3 {
    font-size: 1.1rem !important;
    line-height: 1.3;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    margin-bottom: 0.25rem;
  }

  .timeline-item h4 {
    font-size: 1rem !important;
    line-height: 1.3;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
    margin-bottom: 0.25rem;
  }

  .timeline-item p {
    font-size: 0.85rem;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
  }

  .timeline-item::before {
    left: 0;
    top: 0;
    height: 100%;
    width: 2px;
  }

  .timeline-item::after {
    left: -0.4rem;
    top: 0.25rem;
    height: 0.8rem;
    width: 0.8rem;
  }

  .skill-card {
    padding: 0.5rem;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .skill-card h4 {
    font-size: 0.85rem;
    line-height: 1.4;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
  }

  .contact-form input,
  .contact-form textarea {
    padding: 0.5rem;
    font-size: 0.85rem;
    width: 100%;
    box-sizing: border-box;
    word-wrap: break-word;
    overflow-wrap: break-word;
  }

  .grid {
    width: 100%;
    gap: 0.5rem;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .grid > * {
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .project-card {
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .project-overlay .flex {
    width: 100%;
    padding: 0;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    box-sizing: border-box;
    overflow-x: hidden;
  }

  .project-overlay .flex.space-x-3 {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
  }

  .project-overlay .flex.space-x-3 a {
    min-width: auto;
    padding: 0.5rem;
    white-space: normal;
    text-align: center;
    word-wrap: break-word;
    overflow-wrap: break-word;
    font-size: 0.8rem;
  }

  .skills-section h3 {
    margin-bottom: 2rem;
  }

  .skills-section .grid {
    margin-top: 1.5rem;
    padding-top: 0.75rem;
  }

  .skills-section {
    margin-top: -1.5rem;
    padding-top: 0.75rem;
    margin-bottom: 2.5rem;
    padding: 2rem;
  }

  .skill-card {
    padding: 0.5rem;
    min-height: 40px;
  }

  .skill-icon {
    font-size: 0.9rem;
  }

  .skill-card h4 {
    font-size: 0.6rem;
    line-height: 1.2;
    margin: 0;
  }

  .apps-menu-content {
    width: 90%;
    max-width: 320px;
    margin-right: 0.5rem;
    margin-top: 3.5rem;
    padding: 1.25rem;
  }

  .app-item {
    padding: 1rem;
  }

  .app-item i {
    font-size: 1.5rem;
  }

  .app-item span {
    font-size: 0.8rem;
  }

  .timeline-date {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.25rem;
    margin-top: 0.5rem;
  }
  
  .timeline-date .date {
    font-size: 0.8rem;
  }
  
  .timeline-date .location {
    font-size: 0.75rem;
    padding-left: 0;
  }

  .timeline-date .location::before {
    display: none;
  }
}

@media (max-width: 640px) {
  .container {
    padding-left: 0.25rem;
    padding-right: 0.25rem;
  }

  section {
    padding-left: 0.25rem;
    padding-right: 0.25rem;
  }

  h1 {
    font-size: 1.75rem !important;
  }

  h2 {
    font-size: 1.5rem !important;
  }

  h3 {
    font-size: 1.1rem !important;
  }

  h4 {
    font-size: 1rem !important;
  }

  .project-overlay h3 {
    font-size: 0.9rem;
  }

  .project-overlay p {
    font-size: 0.8rem;
  }

  .timeline-item h3 {
    font-size: 0.85rem !important;
  }

  .timeline-item h4 {
    font-size: 0.8rem !important;
  }

  .timeline-item p {
    font-size: 0.75rem;
  }

  .timeline-item {
    margin-bottom: 1.25rem;
  }

  .skill-card h4 {
    font-size: 0.8rem;
  }

  .contact-form input,
  .contact-form textarea {
    font-size: 0.8rem;
  }

  .skills-section h3 {
    margin-bottom: 1.75rem;
  }

  .skills-section .grid {
    margin-top: 1.25rem;
    padding-top: 0.5rem;
  }

  .skills-section {
    margin-top: -1.5rem;
    padding-top: 0.5rem;
    margin-bottom: 2.5rem;
    padding: 2rem;
  }

  .skill-card {
    padding: 0.4rem;
    min-height: 35px;
  }

  .skill-icon {
    font-size: 0.85rem;
  }

  .skill-card h4 {
    font-size: 0.55rem;
  }
}

html, body {
  overflow-x: hidden;
  width: 100%;
  position: relative;
  word-wrap: break-word;
  -webkit-hyphens: auto;
  -ms-hyphens: auto;
  hyphens: auto;
}

* {
  max-width: 100%;
  box-sizing: border-box;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

section {
  padding: 2rem 0;
  position: relative;
}

.skills-section {
  margin-top: -2rem;
  padding-top: 1rem;
  margin-bottom: 3rem;
  padding: 2.5rem;
}

#contact {
  margin-top: -3rem;
  padding-top: 0.5rem;
}

@media (max-width: 768px) {
  section {
    padding: 1.5rem 0;
  }

  .skills-section {
    margin-top: -1.5rem;
    padding-top: 0.75rem;
    margin-bottom: 2.5rem;
    padding: 2rem;
  }

  #contact {
    margin-top: -2.5rem;
    padding-top: 0.5rem;
  }
}

.created-by {
  text-align: center;
  padding: 1rem 0;
}

.created-by p {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin: 0;
}

.created-by a {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: 500;
  transition: all 0.3s ease;
}

.created-by a:hover {
  color: var(--secondary-color);
}

.light .created-by p {
  color: var(--text-secondary);
}

.light .created-by a {
  color: var(--primary-color);
}

.light .created-by a:hover {
  color: var(--secondary-color);
}

@media (max-width: 768px) {
  .created-by {
    padding: 0.75rem 0;
  }
  
  .created-by p {
    font-size: 0.8rem;
  }
} 