/* ==========================================================================
   YAHYA AL SAYED — PREMIUM VIDEO EDITOR PORTFOLIO
   Design System & Master Stylesheet
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. GOOGLE FONTS & DESIGN TOKENS
   -------------------------------------------------------------------------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Poppins:ital,wght@0,400;0,500;0,600;0,700;0,800;1,400&display=swap');

:root {
  /* Color Palette - Dark Theme (User Palette: #FF4900, #DB5E2C, #A86043, #755446, #424242) */
  --primary: #FF4900;
  --primary-hover: #E04000;
  --primary-light: rgba(255, 73, 0, 0.15);
  --secondary: #DB5E2C;
  --secondary-light: rgba(219, 94, 44, 0.15);
  --accent: #FF4900;
  --accent-subtle: #A86043;
  --accent-glow: rgba(255, 73, 0, 0.35);
  
  --bg-dark: #121212;
  --bg-surface: #1E1E1E;
  --bg-surface-elevated: #424242;
  --bg-glass: rgba(30, 30, 30, 0.85);
  --bg-glass-card: rgba(66, 66, 66, 0.45);
  
  --text-main: #F8FAFC;
  --text-muted: #D4BDB4;
  --text-inverse: #121212;
  
  --border-light: rgba(255, 255, 255, 0.12);
  --border-glow: rgba(255, 73, 0, 0.4);
  --border-accent: rgba(219, 94, 44, 0.5);
  
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 10px 25px -5px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 20px 40px -15px rgba(0, 0, 0, 0.6);
  --shadow-glow: 0 0 35px rgba(255, 73, 0, 0.35);

  /* Spacing System (8-point grid) */
  --space-1: 8px;
  --space-2: 16px;
  --space-3: 24px;
  --space-4: 32px;
  --space-5: 40px;
  --space-6: 48px;
  --space-8: 64px;
  --space-10: 80px;
  --space-12: 96px;
  --space-16: 128px;

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-bounce: 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Light Theme Overrides */
[data-theme="light"] {
  --bg-dark: #FAFAF8;
  --bg-surface: #FFFFFF;
  --bg-surface-elevated: #F2ECE9;
  --bg-glass: rgba(255, 255, 255, 0.9);
  --bg-glass-card: rgba(242, 236, 233, 0.85);
  
  --text-main: #212121;
  --text-muted: #755446;
  --text-inverse: #FFFFFF;
  
  --border-light: rgba(66, 66, 66, 0.15);
  --border-glow: rgba(255, 73, 0, 0.25);
  --border-accent: rgba(219, 94, 44, 0.35);
  
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 25px -5px rgba(66, 66, 66, 0.08);
  --shadow-lg: 0 20px 40px -15px rgba(66, 66, 66, 0.12);
  --shadow-glow: 0 10px 30px rgba(255, 73, 0, 0.2);
}

/* --------------------------------------------------------------------------
   2. GLOBAL RESET & BASE STYLES
   -------------------------------------------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background-color var(--transition-normal), color var(--transition-normal);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Poppins', sans-serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-main);
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, textarea {
  font-family: inherit;
  font-size: inherit;
  border: none;
  outline: none;
  background: none;
}

button {
  cursor: pointer;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-dark);
}
::-webkit-scrollbar-thumb {
  background: var(--bg-surface-elevated);
  border-radius: var(--radius-full);
  border: 2px solid var(--bg-dark);
}
::-webkit-scrollbar-thumb:hover {
  background: var(--primary);
}

/* Container Utility */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--space-3);
}

@media (min-width: 768px) {
  .container {
    padding: 0 var(--space-5);
  }
}

/* Section Header Utility */
.section-header {
  text-align: center;
  max-width: 750px;
  margin: 0 auto var(--space-8) auto;
}

.section-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  background: var(--primary-light);
  border: 1px solid var(--border-glow);
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-bottom: var(--space-2);
}

.section-title {
  font-size: 2.25rem;
  margin-bottom: var(--space-2);
  letter-spacing: -0.5px;
}

@media (min-width: 768px) {
  .section-title {
    font-size: 3rem;
  }
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* Gradient Text Effect */
.gradient-text {
  background: linear-gradient(135deg, #FFFFFF 0%, var(--accent) 50%, var(--primary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

[data-theme="light"] .gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 60%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* --------------------------------------------------------------------------
   3. NAVIGATION BAR
   -------------------------------------------------------------------------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  padding: var(--space-3) 0;
  transition: padding var(--transition-fast), background-color var(--transition-fast), backdrop-filter var(--transition-fast);
}

.navbar.scrolled {
  padding: var(--space-2) 0;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-light);
  box-shadow: var(--shadow-md);
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  font-size: 1.35rem;
  color: var(--text-main);
}

.logo-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.1rem;
  box-shadow: var(--shadow-glow);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  list-style: none;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link:hover, .nav-link.active {
  color: var(--text-main);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -6px;
  left: 0;
  width: 0;
  height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: var(--radius-full);
  transition: width var(--transition-fast);
}

.nav-link:hover::after, .nav-link.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: var(--space-2);
}

/* Theme Switcher Button */
.theme-toggle {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: transform var(--transition-bounce), background-color var(--transition-fast);
}

.theme-toggle:hover {
  transform: rotate(20deg) scale(1.08);
  border-color: var(--primary);
  color: var(--accent);
}

.nav-cta {
  padding: 10px 22px;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-weight: 600;
  font-size: 0.9rem;
  box-shadow: 0 4px 20px rgba(79, 70, 229, 0.4);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.nav-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(79, 70, 229, 0.6);
}

/* Mobile Nav Toggle */
.mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  z-index: 1001;
  padding: 5px;
}

.mobile-toggle span {
  width: 25px;
  height: 3px;
  background: var(--text-main);
  border-radius: 3px;
  transition: var(--transition-fast);
}

@media (max-width: 992px) {
  .mobile-toggle {
    display: flex;
  }
  
  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 80%;
    max-width: 380px;
    height: 100vh;
    background: var(--bg-surface);
    box-shadow: var(--shadow-lg);
    flex-direction: column;
    justify-content: center;
    gap: var(--space-4);
    padding: var(--space-5);
    transition: right var(--transition-normal);
    z-index: 1000;
  }

  .nav-menu.active {
    right: 0;
  }
  
  .nav-link {
    font-size: 1.2rem;
  }
}

/* --------------------------------------------------------------------------
   4. HERO SECTION
   -------------------------------------------------------------------------- */
.hero {
  min-height: 100vh;
  padding-top: 140px;
  padding-bottom: var(--space-10);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.hero-bg-shapes {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}

.glow-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.45;
  animation: orbFloat 14s infinite ease-in-out alternate;
}

.glow-orb-1 {
  width: 450px;
  height: 450px;
  background: var(--primary);
  top: 10%;
  left: -10%;
}

.glow-orb-2 {
  width: 400px;
  height: 400px;
  background: var(--secondary);
  bottom: 10%;
  right: -5%;
  animation-delay: -5s;
}

.glow-orb-3 {
  width: 300px;
  height: 300px;
  background: var(--accent);
  top: 40%;
  left: 45%;
  animation-delay: -9s;
  opacity: 0.25;
}

@keyframes orbFloat {
  0% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(40px, -60px) scale(1.1); }
  100% { transform: translate(-30px, 40px) scale(0.9); }
}

/* Floating Motion Graphics Icons */
.floating-element {
  position: absolute;
  padding: 12px 20px;
  border-radius: var(--radius-md);
  background: var(--bg-glass-card);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  font-weight: 600;
  box-shadow: var(--shadow-md);
  animation: floatMotion 6s infinite ease-in-out alternate;
}

.float-1 { top: 22%; right: 12%; animation-delay: 0s; }
.float-2 { bottom: 25%; left: 8%; animation-delay: -2s; }
.float-3 { top: 60%; right: 6%; animation-delay: -4s; }

@keyframes floatMotion {
  0% { transform: translateY(0px) rotate(0deg); }
  100% { transform: translateY(-20px) rotate(3deg); }
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: center;
  position: relative;
  z-index: 1;
}

@media (min-width: 992px) {
  .hero-grid {
    grid-template-columns: 1.2fr 0.8fr;
  }
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  background: var(--primary-light);
  border: 1px solid var(--border-glow);
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: var(--space-3);
}

.pulse-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
  animation: pulseGlow 2s infinite;
}

@keyframes pulseGlow {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(1.4); }
}

.hero-name {
  font-size: 3.25rem;
  letter-spacing: -1.5px;
  margin-bottom: var(--space-1);
}

@media (min-width: 768px) {
  .hero-name { font-size: 4.5rem; }
}

@media (min-width: 1200px) {
  .hero-name { font-size: 5.25rem; }
}

.hero-subtitle {
  font-size: 1.35rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: var(--space-4);
  letter-spacing: -0.2px;
}

@media (min-width: 768px) {
  .hero-subtitle { font-size: 1.75rem; }
}

.hero-bio {
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1.75;
  max-width: 640px;
  margin-bottom: var(--space-5);
}

.hero-btns {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 32px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 1rem;
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #FFFFFF;
  box-shadow: 0 10px 30px rgba(79, 70, 229, 0.4);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(79, 70, 229, 0.6);
}

.btn-outline {
  background: var(--bg-glass-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-light);
  color: var(--text-main);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--accent);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* Hero Parallax Visual Canvas */
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero-card-stack {
  position: relative;
  width: 100%;
  max-width: 440px;
  aspect-ratio: 4/5;
  border-radius: var(--radius-lg);
  padding: 12px;
  background: linear-gradient(135deg, var(--border-glow), rgba(255, 255, 255, 0.05));
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  transform-style: preserve-3d;
  transition: transform 0.1s ease-out;
}

.hero-video-frame {
  width: 100%;
  height: 100%;
  border-radius: var(--radius-md);
  overflow: hidden;
  position: relative;
}

.hero-video-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%;
  filter: brightness(0.95);
}

.hero-video-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(11, 15, 25, 0.9) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-4);
}

.edit-badge {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-radius: var(--radius-md);
  background: rgba(18, 24, 38, 0.85);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border-light);
}

.edit-badge-icon {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--bg-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

/* --------------------------------------------------------------------------
   5. ABOUT ME SECTION
   -------------------------------------------------------------------------- */
.about {
  padding: var(--space-10) 0;
  position: relative;
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  align-items: center;
}

@media (min-width: 992px) {
  .about-grid {
    grid-template-columns: 0.9fr 1.1fr;
  }
}

.about-img-container {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-glow);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  aspect-ratio: 4/5;
}

.about-img-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%;
  display: block;
  transition: transform 0.6s ease;
}

.about-img-container:hover img {
  transform: scale(1.04);
}

.about-experience-badge {
  position: absolute;
  bottom: var(--space-4);
  right: var(--space-4);
  padding: 16px 24px;
  border-radius: var(--radius-md);
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  border: 1px solid var(--border-accent);
  box-shadow: var(--shadow-md);
}

.exp-number {
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}

.exp-text {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 500;
}

.about-content h3 {
  font-size: 2rem;
  margin-bottom: var(--space-3);
  letter-spacing: -0.5px;
}

.about-content p {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: var(--space-3);
}

.countries-list {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin: var(--space-4) 0;
}

.country-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  font-size: 0.9rem;
  font-weight: 500;
}

.philosophy-quote {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--primary-light);
  border-left: 4px solid var(--accent);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--text-main);
  margin-top: var(--space-4);
}

/* --------------------------------------------------------------------------
   6. ACHIEVEMENTS SECTION (COUNTERS)
   -------------------------------------------------------------------------- */
.achievements {
  padding: var(--space-8) 0;
  background: var(--bg-surface);
  border-y: 1px solid var(--border-light);
  position: relative;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-4);
}

@media (min-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (min-width: 1024px) {
  .stats-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

.stat-card {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--bg-glass-card);
  backdrop-filter: blur(10px);
  border: 1px solid var(--border-light);
  text-align: center;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.stat-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.stat-value {
  font-size: 2.75rem;
  font-weight: 800;
  color: var(--accent);
  font-family: 'Poppins', sans-serif;
  line-height: 1.1;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* --------------------------------------------------------------------------
   7. SKILLS SECTION
   -------------------------------------------------------------------------- */
.skills {
  padding: var(--space-10) 0;
}

.skills-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-4);
}

@media (min-width: 768px) {
  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1200px) {
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.skill-category-card {
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.skill-category-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md), 0 0 20px rgba(79, 70, 229, 0.15);
  border-color: var(--border-glow);
}

.category-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: var(--space-4);
}

.category-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  background: var(--primary-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.category-title {
  font-size: 1.25rem;
}

.skill-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.skill-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.skill-info {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
  font-weight: 500;
}

.skill-name {
  color: var(--text-main);
}

.skill-pct {
  color: var(--accent);
  font-weight: 600;
}

.skill-bar-bg {
  width: 100%;
  height: 8px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  overflow: hidden;
  position: relative;
}

.skill-bar-fill {
  height: 100%;
  border-radius: var(--radius-full);
  background: linear-gradient(90deg, var(--primary), var(--accent));
  width: 0%;
  transition: width 1.5s cubic-bezier(0.1, 0.42, 0.16, 1);
}

/* --------------------------------------------------------------------------
   8. PROJECTS SECTION
   -------------------------------------------------------------------------- */
.projects {
  padding: var(--space-10) 0;
  background: var(--bg-dark);
}

.project-filters {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: var(--space-6);
}

.project-filter-btn {
  padding: 10px 24px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.95rem;
  transition: all var(--transition-fast);
  cursor: pointer;
}

.project-filter-btn:hover, .project-filter-btn.active {
  background: var(--primary);
  color: #FFFFFF;
  border-color: var(--primary);
  box-shadow: 0 4px 20px rgba(255, 73, 0, 0.4);
  transform: translateY(-2px);
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

@media (min-width: 768px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1200px) {
  .projects-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.project-card {
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform var(--transition-normal), box-shadow var(--transition-normal), border-color var(--transition-normal);
}

.project-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  border-color: var(--border-glow);
}

.project-img-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
}

.project-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-card:hover .project-img-wrapper img {
  transform: scale(1.08);
}

.project-category-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(8px);
  color: var(--accent);
  font-size: 0.8rem;
  font-weight: 600;
  border: 1px solid var(--border-light);
}

.project-body {
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.project-title {
  font-size: 1.35rem;
  margin-bottom: var(--space-1);
}

.project-desc {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: var(--space-3);
  flex-grow: 1;
}

.tech-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: var(--space-4);
}

.tech-tag {
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-elevated);
  color: var(--text-muted);
  font-size: 0.78rem;
  font-weight: 500;
}

.btn-view-project {
  width: 100%;
  padding: 10px;
  border-radius: var(--radius-md);
  background: var(--primary-light);
  border: 1px solid var(--border-glow);
  color: var(--text-main);
  font-weight: 600;
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.btn-view-project:hover {
  background: var(--primary);
  color: #fff;
}

/* --------------------------------------------------------------------------
   9. EXPERIENCE SECTION (VERTICAL TIMELINE)
   -------------------------------------------------------------------------- */
.experience {
  padding: var(--space-10) 0;
  background: var(--bg-surface);
}

.timeline {
  position: relative;
  max-width: 850px;
  margin: 0 auto;
  padding: var(--space-4) 0;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 20px;
  width: 3px;
  background: linear-gradient(to bottom, var(--primary), var(--accent), var(--secondary));
  border-radius: var(--radius-full);
}

@media (min-width: 768px) {
  .timeline::before {
    left: 50%;
    transform: translateX(-50%);
  }
}

.timeline-item {
  position: relative;
  margin-bottom: var(--space-6);
  width: 100%;
}

.timeline-item:last-child {
  margin-bottom: 0;
}

.timeline-dot {
  position: absolute;
  top: 0;
  left: 12px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--accent);
  border: 4px solid var(--bg-surface);
  box-shadow: 0 0 12px var(--accent);
  z-index: 2;
}

@media (min-width: 768px) {
  .timeline-dot {
    left: 50%;
    transform: translateX(-50%);
  }
}

.timeline-content {
  margin-left: 50px;
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  background: var(--bg-dark);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.timeline-content:hover {
  transform: translateY(-3px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

@media (min-width: 768px) {
  .timeline-item:nth-child(odd) .timeline-content {
    margin-left: 0;
    margin-right: calc(50% + 30px);
    text-align: right;
  }
  .timeline-item:nth-child(even) .timeline-content {
    margin-left: calc(50% + 30px);
  }
}

.timeline-role {
  font-size: 1.3rem;
  margin-bottom: 4px;
}

.timeline-date {
  display: inline-block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: var(--space-2);
}

.timeline-achievements {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   10. SERVICES SECTION
   -------------------------------------------------------------------------- */
.services {
  padding: var(--space-10) 0;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-4);
}

.service-card {
  padding: var(--space-4);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: center;
  gap: 16px;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.service-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: var(--primary-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.service-title {
  font-size: 1.05rem;
  font-weight: 600;
}

/* --------------------------------------------------------------------------
   11. WORKFLOW SECTION (HORIZONTAL TIMELINE)
   -------------------------------------------------------------------------- */
.workflow {
  padding: var(--space-10) 0;
  background: var(--bg-surface);
}

.workflow-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: var(--space-3);
  position: relative;
  margin-bottom: var(--space-6);
}

.workflow-step {
  text-align: center;
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--bg-dark);
  border: 1px solid var(--border-light);
  position: relative;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.workflow-step:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
}

.step-number {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto var(--space-2) auto;
}

.step-label {
  font-size: 0.9rem;
  font-weight: 600;
}

.delivery-note {
  text-align: center;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-full);
  background: var(--primary-light);
  border: 1px solid var(--border-glow);
  color: var(--accent);
  font-weight: 600;
  max-width: 500px;
  margin: 0 auto;
}

/* --------------------------------------------------------------------------
   12. STYLES ENJOYED, IDEAL CLIENTS, WHY WORK WITH ME
   -------------------------------------------------------------------------- */
.badges-section {
  padding: var(--space-8) 0;
}

.badges-wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--space-2);
}

.style-badge {
  padding: 10px 22px;
  border-radius: var(--radius-full);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-main);
  transition: transform var(--transition-fast), background-color var(--transition-fast), border-color var(--transition-fast);
}

.style-badge:hover {
  transform: scale(1.06);
  background: var(--primary-light);
  border-color: var(--accent);
  color: var(--accent);
}

.ideal-clients, .why-me {
  padding: var(--space-10) 0;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--space-4);
}

.info-card {
  padding: var(--space-4);
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  border: 1px solid var(--border-light);
  text-align: center;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.info-card:hover {
  transform: translateY(-5px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.info-card-icon {
  font-size: 2.2rem;
  margin-bottom: var(--space-2);
}

.info-card-title {
  font-size: 1.15rem;
  margin-bottom: 6px;
}

/* Career Goal Banner */
.career-goal {
  padding: var(--space-8) 0;
}

.career-banner {
  padding: var(--space-6);
  border-radius: var(--radius-lg);
  background: linear-gradient(135deg, var(--bg-surface-elevated), var(--bg-dark));
  border: 1px solid var(--border-glow);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  text-align: center;
  max-width: 900px;
  margin: 0 auto;
  position: relative;
  overflow: hidden;
}

.career-banner::before {
  content: '“';
  position: absolute;
  top: -20px;
  left: 20px;
  font-size: 10rem;
  color: var(--primary-light);
  font-family: serif;
  line-height: 1;
  pointer-events: none;
}

.career-text {
  font-size: 1.25rem;
  line-height: 1.8;
  font-weight: 500;
  color: var(--text-main);
  position: relative;
  z-index: 1;
}

/* --------------------------------------------------------------------------
   13. CONTACT SECTION
   -------------------------------------------------------------------------- */
.contact {
  padding: var(--space-10) 0;
  background: var(--bg-surface);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
}

@media (min-width: 992px) {
  .contact-grid {
    grid-template-columns: 1fr 1.2fr;
  }
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.contact-method {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: var(--space-3);
  border-radius: var(--radius-md);
  background: var(--bg-dark);
  border: 1px solid var(--border-light);
}

.contact-method-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: var(--primary-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
}

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

.contact-val {
  font-size: 1.05rem;
  font-weight: 600;
}

.social-links {
  display: flex;
  gap: 12px;
  margin-top: var(--space-2);
}

.social-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--bg-dark);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: transform var(--transition-bounce), border-color var(--transition-fast), color var(--transition-fast);
}

.social-btn:hover {
  transform: translateY(-4px);
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 15px rgba(34, 211, 238, 0.4);
}

/* Contact Form */
.contact-form {
  padding: var(--space-5);
  border-radius: var(--radius-lg);
  background: var(--bg-dark);
  border: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-group label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-muted);
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  transition: border-color var(--transition-fast);
}

.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

textarea.form-input {
  min-height: 130px;
  resize: vertical;
}

/* --------------------------------------------------------------------------
   14. FOOTER & BACK TO TOP
   -------------------------------------------------------------------------- */
.footer {
  padding: var(--space-5) 0;
  border-top: 1px solid var(--border-light);
  background: var(--bg-dark);
  text-align: center;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
}

@media (min-width: 768px) {
  .footer-content {
    flex-direction: row;
  }
}

.back-to-top {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary-light);
  border: 1px solid var(--border-glow);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  transition: transform var(--transition-bounce);
}

.back-to-top:hover {
  transform: translateY(-5px);
  background: var(--primary);
  color: #fff;
}

/* --------------------------------------------------------------------------
   15. PROJECT MODAL SHOWCASE
   -------------------------------------------------------------------------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(11, 15, 25, 0.85);
  backdrop-filter: blur(16px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-3);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-card {
  width: 100%;
  max-width: 800px;
  max-height: 90vh;
  overflow-y: auto;
  border-radius: var(--radius-lg);
  background: var(--bg-surface);
  border: 1px solid var(--border-glow);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  padding: var(--space-5);
  position: relative;
  transform: scale(0.9);
  transition: transform var(--transition-bounce);
}

.modal-overlay.active .modal-card {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-light);
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}

.modal-close:hover {
  background: var(--primary);
  color: #fff;
}

/* Video Player Simulator & Shorts Embed inside Modal */
.video-player-sim {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: var(--space-4);
  background: #000;
}

/* --------------------------------------------------------------------------
   YouTube Thumbnail Player — avoids embed restrictions (Error 153)
   Click-to-open-YouTube approach for reliable playback
   -------------------------------------------------------------------------- */
.vertical-short-embed {
  position: relative;
  width: 100%;
  max-width: 320px;
  aspect-ratio: 9/16;
  margin: 0 auto var(--space-4) auto;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #000;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6);
  border: 1px solid var(--border-glow);
}

.horizontal-video-embed {
  position: relative;
  width: 100%;
  max-width: 560px;
  aspect-ratio: 16/9;
  margin: 0 auto var(--space-4) auto;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #000;
  box-shadow: 0 12px 35px rgba(0, 0, 0, 0.6);
  border: 1px solid var(--border-glow);
}

/* Clickable YouTube thumbnail player */
.yt-thumb-player {
  position: relative;
  width: 100%;
  height: 100%;
  cursor: pointer;
  display: block;
  overflow: hidden;
}

.yt-thumb-player img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}

.yt-thumb-player:hover img {
  transform: scale(1.04);
}

/* Play button overlay */
.yt-play-btn {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  background: rgba(0, 0, 0, 0.42);
  transition: background 0.25s ease;
}

.yt-thumb-player:hover .yt-play-btn {
  background: rgba(0, 0, 0, 0.22);
}

.yt-play-icon {
  drop-shadow(0 0 20px rgba(255,0,0,0.7));
  filter: drop-shadow(0 4px 12px rgba(0,0,0,0.6));
  transition: transform 0.2s ease;
}

.yt-thumb-player:hover .yt-play-icon {
  transform: scale(1.12);
}

.yt-play-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 4px rgba(0,0,0,0.8);
  letter-spacing: 0.03em;
  background: rgba(0,0,0,0.55);
  padding: 4px 12px;
  border-radius: 50px;
}

/* --------------------------------------------------------------------------
   16. ANIMATIONS & OBSERVER REVEALS
   -------------------------------------------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

/* --------------------------------------------------------------------------
   17. COMPREHENSIVE MOBILE & TABLET RESPONSIVENESS
   -------------------------------------------------------------------------- */

/* --- Project filter pills: scroll on mobile --- */
.project-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: var(--space-5);
  padding: 0 4px;
}

@media (max-width: 600px) {
  .project-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 8px;
    gap: 8px;
    scrollbar-width: none;
  }
  .project-filters::-webkit-scrollbar { display: none; }

  .project-filter-btn {
    white-space: nowrap;
    flex-shrink: 0;
    font-size: 0.8rem;
    padding: 7px 14px;
  }

  /* Projects grid: single column on small screens */
  .projects-grid {
    grid-template-columns: 1fr !important;
    gap: var(--space-4);
  }

  /* Hero section adjustments */
  .hero-title {
    font-size: clamp(2rem, 9vw, 3.5rem);
  }
  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .hero-actions .btn {
    text-align: center;
    justify-content: center;
  }

  /* Modal: full-screen on mobile */
  .modal-card {
    width: 100vw !important;
    max-width: 100vw !important;
    min-height: 100dvh;
    border-radius: 0 !important;
    margin: 0;
    overflow-y: auto;
  }
  .modal-overlay {
    align-items: flex-start;
  }

  /* Vertical embed: slightly smaller on mobile */
  .vertical-short-embed {
    max-width: 260px;
  }

  /* Section headings */
  .section-title {
    font-size: clamp(1.6rem, 7vw, 2.4rem);
  }

  /* Nav: smaller logo on mobile */
  .nav-logo { font-size: 1.1rem; }

  /* Contact section grid */
  .contact-grid {
    grid-template-columns: 1fr !important;
  }

  /* Stats row wrapping */
  .hero-stats {
    gap: var(--space-3);
  }
  .hero-stat-value {
    font-size: 1.8rem;
  }

  /* Experience timeline */
  .timeline-content {
    padding: var(--space-3) !important;
  }

  /* Skill bars: fix overflow */
  .skills-grid {
    grid-template-columns: 1fr !important;
  }

  /* Services section */
  .services-grid {
    grid-template-columns: 1fr !important;
  }

  /* Footer */
  .footer-links {
    flex-direction: column;
    align-items: center;
    gap: var(--space-3);
  }
}

/* --- Tablet (600px – 991px) --- */
@media (min-width: 601px) and (max-width: 991px) {
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .modal-card {
    width: 92vw !important;
    max-width: 680px !important;
  }

  .hero-title {
    font-size: clamp(2.5rem, 7vw, 4rem);
  }

  .contact-grid {
    grid-template-columns: 1fr !important;
  }

  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .skills-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* --- Make images not overflow on any screen --- */
img {
  max-width: 100%;
  height: auto;
}

/* --- Touch target minimum size for accessibility --- */
.btn-view-project,
.project-filter-btn,
.nav-link,
.theme-toggle-btn {
  min-height: 40px;
}

/* --------------------------------------------------------------------------
   18. PREMIUM CONTACT CTA CARD (replaces form)
   -------------------------------------------------------------------------- */
.contact-cta-card {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
  background: var(--surface);
  border: 1px solid var(--border-glow);
  border-radius: var(--radius-lg);
  padding: var(--space-6) var(--space-5);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.35);
}

.contact-cta-btns {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: var(--space-4);
}

.cta-big-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.25s ease;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.cta-whatsapp {
  background: linear-gradient(135deg, #25D366, #128C7E);
  color: #fff;
  box-shadow: 0 6px 24px rgba(37, 211, 102, 0.35);
}
.cta-whatsapp:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(37, 211, 102, 0.5);
  color: #fff;
}

.cta-email {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  box-shadow: 0 6px 24px rgba(255, 73, 0, 0.3);
}
.cta-email:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 32px rgba(255, 73, 0, 0.45);
  color: #fff;
}

.cta-big-btn i {
  font-size: 1.2rem;
}

/* Styled divider */
.cta-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: var(--space-3) 0;
  color: var(--text-muted);
  font-size: 0.85rem;
}
.cta-divider::before,
.cta-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}
.cta-divider span {
  white-space: nowrap;
  padding: 0 4px;
}

@media (max-width: 480px) {
  .contact-cta-card {
    padding: var(--space-4) var(--space-3);
  }
  .cta-big-btn {
    width: 100%;
    justify-content: center;
    padding: 14px 24px;
    font-size: 0.95rem;
  }
  .contact-cta-btns {
    flex-direction: column;
    gap: 12px;
  }
}

