/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --primary: #266867;
  --primary-dark: #1A4645;
  --bg-dark: #051821;
  --bg-dark-2: #0a2a2f;
  --text-light: #ffffff;
  --text-gray: #9ca3af;
  --glass-bg: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 255, 255, 0.1);
}

.light-mode {
  --bg-dark: #ffffff;
  --bg-dark-2: #f8fafc;
  --text-light: #111827;
  --text-gray: #6b7280;
  --glass-bg: rgba(0, 0, 0, 0.05);
  --glass-border: rgba(0, 0, 0, 0.1);
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  background: linear-gradient(135deg, var(--bg-dark), var(--bg-dark-2), var(--primary-dark));
  color: var(--text-light);
  min-height: 100vh;
  transition: background 0.5s ease, color 0.5s ease;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navigation */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  backdrop-filter: blur(20px);
  background: var(--glass-bg);
  border-bottom: 1px solid var(--glass-border);
}

.nav-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-light);
  text-decoration: none;
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-links {
  display: flex;
  gap: 2rem;
}

.nav-links a {
  color: var(--text-gray);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s;
}

.nav-links a:hover {
  color: var(--primary);
}

.theme-toggle {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  width: 44px;
  height: 44px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: all 0.3s;
}

.theme-toggle:hover {
  background: var(--primary);
}

.light-mode .sun-icon { display: none; }
.light-mode .moon-icon { display: block; }
body:not(.light-mode) .sun-icon { display: block; }
body:not(.light-mode) .moon-icon { display: none; }

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 6rem 1.5rem 2rem;
  position: relative;
}

.hero-content {
  max-width: 800px;
}

.hero-greeting {
  color: var(--primary);
  font-weight: 500;
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

.hero-name {
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 800;
  margin-bottom: 1rem;
  background: linear-gradient(to right, var(--text-light), var(--text-gray));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-title {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  font-weight: 700;
  margin-bottom: 1.5rem;
  min-height: 3rem;
}

.hero-title span {
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.cursor {
  animation: blink 1s infinite;
}

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

.hero-description {
  color: var(--text-gray);
  font-size: 1.125rem;
  line-height: 1.75;
  margin-bottom: 2rem;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  color: white;
  text-decoration: none;
  border-radius: 9999px;
  font-weight: 600;
  transition: transform 0.3s, box-shadow 0.3s;
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 40px rgba(38, 104, 103, 0.4);
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  width: 24px;
  height: 40px;
  border: 2px solid var(--glass-border);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  padding-top: 8px;
}

.scroll-dot {
  width: 4px;
  height: 8px;
  background: var(--primary);
  border-radius: 2px;
  animation: scroll 2s infinite;
}

@keyframes scroll {
  0%, 100% { transform: translateY(0); opacity: 1; }
  50% { transform: translateY(12px); opacity: 0.5; }
}

/* Section Titles */
.section-title {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 700;
  text-align: center;
  margin-bottom: 1.5rem;
}

.gradient-text {
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.section-subtitle {
  color: var(--text-gray);
  text-align: center;
  font-size: 1.25rem;
  max-width: 600px;
  margin: 0 auto 3rem;
}

/* About Section */
.about {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 5rem 1.5rem;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

.about-slideshow {
  position: relative;
}

.slideshow-container {
  border-radius: 1.5rem;
  overflow: hidden;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
}

.slideshow-container {
  position: relative;
}

.slideshow-container img {
  width: 100%;
  height: 400px;
  object-fit: cover;
  display: block;
  border-radius: 1rem;
}

.slideshow-caption {
  text-align: center;
  padding: 1rem 0;
}

.slideshow-caption h4 {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.slideshow-caption p {
  color: var(--text-gray);
}

.slideshow-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: all 0.3s;
  backdrop-filter: blur(10px);
}

.slideshow-arrow:hover {
  background: var(--primary);
}

.slideshow-arrow.left { left: 1rem; }
.slideshow-arrow.right { right: 1rem; }

.slideshow-dots {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
}

.slideshow-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--glass-border);
  cursor: pointer;
  transition: all 0.3s;
}

.slideshow-dot.active {
  width: 2rem;
  border-radius: 4px;
  background: var(--primary);
}

.about-text h3 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
}

.about-text p {
  color: var(--text-gray);
  font-size: 1.125rem;
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

/* Skills Section */
.skills {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding: 5rem 1.5rem;
}

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

.skills-box {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1.5rem;
  padding: 2rem;
  backdrop-filter: blur(20px);
}

.skills-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.skills-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.skills-header h3 {
  font-size: 1.25rem;
  font-weight: 700;
}

.skills-list {
  list-style: none;
}

.skills-list li {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.5rem 0;
  font-weight: 500;
}

.skills-list li::before {
  content: '';
  width: 8px;
  height: 8px;
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  border-radius: 50%;
}

.clients-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: center;
}

.clients-cloud span {
  font-weight: 500;
  transition: color 0.3s;
  cursor: default;
}

.clients-cloud span:hover {
  color: var(--primary);
}

/* Projects Section */
.projects {
  padding: 5rem 1.5rem;
}

.carousel {
  max-width: 900px;
  margin: 0 auto;
}

.carousel-main {
  position: relative;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1.5rem;
  overflow: hidden;
  aspect-ratio: 16/9;
}

.carousel-main video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: all 0.3s;
  backdrop-filter: blur(10px);
}

.carousel-arrow:hover {
  background: var(--primary);
}

.carousel-arrow.left { left: 1rem; }
.carousel-arrow.right { right: 1rem; }

.project-info {
  padding: 1.5rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0 0 1.5rem 1.5rem;
  margin-top: -1.5rem;
}

.project-info h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

.project-info p {
  color: var(--text-gray);
  margin-bottom: 1rem;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.project-tags span {
  padding: 0.25rem 0.75rem;
  background: rgba(38, 104, 103, 0.2);
  color: var(--primary);
  border-radius: 9999px;
  font-size: 0.875rem;
}

.thumbnails {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.75rem;
  margin-top: 1rem;
}

.thumbnail {
  aspect-ratio: 16/9;
  border-radius: 0.75rem;
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all 0.3s;
}

.thumbnail:hover {
  border-color: var(--glass-border);
}

.thumbnail.active {
  border-color: var(--primary);
  box-shadow: 0 0 20px rgba(38, 104, 103, 0.4);
}

.thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Testimonials Section */
.testimonials {
  padding: 5rem 1.5rem;
}

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

.testimonial-card {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1.5rem;
  padding: 2rem;
  backdrop-filter: blur(20px);
  transition: transform 0.3s;
}

.testimonial-card:hover {
  transform: translateY(-5px);
}

.testimonial-stars {
  color: #fbbf24;
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.testimonial-quote {
  color: var(--text-gray);
  font-style: italic;
  line-height: 1.75;
  margin-bottom: 1.5rem;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.testimonial-author img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.testimonial-author h4 {
  font-weight: 600;
}

.testimonial-author p {
  color: var(--text-gray);
  font-size: 0.875rem;
}

/* Contact Section */
.contact {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5rem 1.5rem;
}

.contact-cards {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 600px;
  margin: 0 auto 2rem;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 1rem;
  padding: 1.5rem;
  backdrop-filter: blur(20px);
}

.contact-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(to right, var(--primary), var(--primary-dark));
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.contact-label {
  color: var(--text-gray);
  font-size: 0.875rem;
}

.contact-value {
  font-weight: 600;
  font-size: 1.125rem;
}

.social-links {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.social-link {
  width: 56px;
  height: 56px;
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: all 0.3s;
}

.social-link:hover {
  background: var(--primary);
  transform: scale(1.1);
}

/* Footer */
.footer {
  border-top: 1px solid var(--glass-border);
  padding: 2rem 1.5rem;
  text-align: center;
  color: var(--text-gray);
}

/* Responsive */
@media (max-width: 1024px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .skills-grid {
    grid-template-columns: 1fr;
  }
  
  .testimonials-grid {
    grid-template-columns: 1fr;
  }
  
  .thumbnails {
    grid-template-columns: repeat(4, 1fr);
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .thumbnails {
    grid-template-columns: repeat(3, 1fr);
  }
}