html,
body {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

*,
*::before,
*::after {
  box-sizing: inherit;
}

:root {
  --font-main: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-arabic: "Cairo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  /* Light theme (calm indigo/teal luxury) */
  --bg: #f3f4f6;
  --bg-elevated: #e5e7eb;
  --bg-soft: #f9fafb;
  --text: #374151;
  --text-heading: #111827;
  --muted: #6b7280;
  --primary: #5b5fc7;
  --primary-strong: #4f46e5;
  --secondary: #0ea89a;
  --secondary-strong: #0d9488;
  --accent: var(--primary);
  --accent-light: #a5b4fc;
  --accent-soft: rgba(91, 95, 199, 0.14);
  --border-soft: rgba(148, 163, 184, 0.4);
  --glass-surface: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(148, 163, 184, 0.4);
  --shadow-soft: 0 18px 45px rgba(15, 23, 42, 0.10);
  --shadow-md: 0 24px 60px rgba(15, 23, 42, 0.16);
  --radius-xl: 28px;
  --radius-lg: 24px;
  --radius-md: 16px;
  --blur: 24px;
}

html[data-theme="dark"] {
  --bg: #020617;
  --bg-elevated: #0b1120;
  --bg-soft: #0f172a;
  --text: #e5e7eb;
  --text-heading: #f9fafb;
  --muted: #9ca3af;
  --primary: #7679f7;
  --primary-strong: #818cf8;
  --secondary: #12c9b8;
  --secondary-strong: #2dd4bf;
  --accent: var(--primary);
  --accent-light: #818cf8;
  --accent-soft: rgba(118, 121, 247, 0.2);
  --border-soft: rgba(148, 163, 184, 0.25);
  --glass-surface: rgba(15, 23, 42, 0.85);
  --glass-border: rgba(148, 163, 184, 0.4);
  --shadow-soft: 0 18px 45px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 28px 70px rgba(0, 0, 0, 0.65);
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  background-attachment: fixed;
  transition: background 0.8s cubic-bezier(0.4, 0, 0.2, 1), color 0.8s ease;
  position: relative;
  overflow-x: hidden;
}

/* Animated gradient backdrop (blue/orange waves) */
body::before,
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -2;
}

html[data-theme="light"] body {
  background: radial-gradient(ellipse at top, #f9fafb 0%, #f3f4f6 45%, #e5e7eb 100%);
}

html[data-theme="light"] body::before {
  background: radial-gradient(ellipse 900px 600px at 12% 15%, rgba(99, 102, 241, 0.12), transparent 60%),
              radial-gradient(ellipse 720px 480px at 85% 20%, rgba(20, 184, 166, 0.14), transparent 58%),
              radial-gradient(ellipse 800px 520px at 50% 85%, rgba(99, 102, 241, 0.08), transparent 65%);
  opacity: 1;
  animation: softBlob 24s ease-in-out infinite;
  filter: blur(80px);
}

html[data-theme="light"] body::after {
  background: radial-gradient(ellipse 650px 400px at 20% 75%, rgba(20, 184, 166, 0.1), transparent 60%),
              radial-gradient(ellipse 580px 360px at 78% 80%, rgba(99, 102, 241, 0.09), transparent 62%);
  mix-blend-mode: normal;
  opacity: 0.85;
  animation: softBlob 28s ease-in-out infinite reverse;
  filter: blur(90px);
}

html[data-theme="dark"] body {
  background: radial-gradient(ellipse at top, #0b1120 0%, #020617 60%, #010409 100%);
}

html[data-theme="dark"] body::before {
  background: radial-gradient(ellipse 950px 620px at 15% 18%, rgba(99, 102, 241, 0.15), transparent 58%),
              radial-gradient(ellipse 780px 500px at 82% 22%, rgba(20, 184, 166, 0.14), transparent 60%),
              radial-gradient(ellipse 850px 540px at 48% 82%, rgba(99, 102, 241, 0.10), transparent 64%);
  opacity: 1;
  animation: softBlob 26s ease-in-out infinite;
  filter: blur(90px);
}

html[data-theme="dark"] body::after {
  background: radial-gradient(ellipse 700px 420px at 22% 72%, rgba(20, 184, 166, 0.12), transparent 62%),
              radial-gradient(ellipse 620px 380px at 80% 78%, rgba(99, 102, 241, 0.11), transparent 64%);
  opacity: 0.8;
  animation: softBlob 30s ease-in-out infinite reverse;
  mix-blend-mode: screen;
  filter: blur(100px);
}


.page-root {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

/* Containers */

.container {
  width: min(1120px, 100% - 32px);
  margin-inline: auto;
}

/* Navbar - Premium Glass Design */

.navbar {
  position: sticky;
  top: 12px;
  z-index: 30;
  width: min(1160px, calc(100% - 32px));
  margin: 12px auto 0;
  border-radius: 20px;
  background: rgba(15, 23, 42, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 8px 36px rgba(0, 0, 0, 0.15);
  transition: background 0.3s ease, border 0.3s ease, transform 0.3s ease;
}

html[data-theme="light"] .navbar {
  background: rgba(255, 255, 255, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.35);
  box-shadow: 0 8px 36px rgba(0, 0, 0, 0.15);
}

.navbar:hover {
  transform: translateY(-1px);
  border-color: rgba(255, 255, 255, 0.45);
}

html[data-theme="light"] .navbar:hover {
  border-color: rgba(255, 255, 255, 0.45);
}

.navbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 12px 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}

/* ========================================
   GLASS PHOTO COMPONENT - Modern UI/UX System
   ======================================== */

/* Base glass photo container */
.glass-photo {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(99,102,241,0.16), rgba(20,184,166,0.14));
  box-shadow: 0 18px 42px rgba(15,23,42,0.35);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: box-shadow 220ms ease-out, border-color 220ms ease-out, transform 220ms ease-out;
  isolation: isolate;
}

/* Glass reflection overlay */
.glass-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.18) 0%, transparent 60%);
  mix-blend-mode: overlay;
  opacity: 0.4;
  pointer-events: none;
  z-index: 2;
  transition: opacity 0.3s ease;
}

/* Hover state for container */
.glass-photo:hover {
  box-shadow: 0 24px 56px rgba(99,102,241,0.42);
  border-color: rgba(99,102,241,0.45);
}

.glass-photo:hover::after {
  opacity: 0.6;
}

/* Image inside glass frame */
.glass-photo img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: translateY(0) scale(1);
  transition: transform 220ms ease-out;
  position: relative;
  z-index: 1;
}

/* Hover effect on image */
.glass-photo:hover img {
  transform: translateY(-6px) scale(1.03);
}

/* ======= VARIANTS ======= */

/* Portrait variant (CV photo) */
.glass-photo--portrait {
  max-width: 320px;
  aspect-ratio: 3/4;
  margin-inline: auto;
}

/* Hero variant (large showcase images) */
.glass-photo--hero {
  max-width: 100%;
  aspect-ratio: 4/5;
}

@media (min-width: 768px) {
  .glass-photo--hero {
    aspect-ratio: 1/1;
  }
}

/* Thumbnail variant (video cards, small images) */
.glass-photo--thumb {
  aspect-ratio: 16/9;
  border-radius: 16px;
  box-shadow: 0 12px 32px rgba(15,23,42,0.28);
}

.glass-photo--thumb:hover {
  box-shadow: 0 16px 42px rgba(99,102,241,0.38);
}

/* Mini variant (small gallery items) */
.glass-photo--mini {
  aspect-ratio: 1/1;
  border-radius: 18px;
}

/* Gallery item variant */
.glass-photo--gallery {
  aspect-ratio: 4/3;
  width: 100%;
}

/* ======= ANIMATION ======= */

/* Floating animation */
@keyframes floatPhoto {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-6px); }
}

.glass-photo--floating {
  animation: floatPhoto 8s ease-in-out infinite;
}

/* Disable animation on hover to prevent conflict */
.glass-photo--floating:hover {
  animation-play-state: paused;
}

/* ========================================
   CV PORTRAIT CARD - Premium Floating Glass + Signature
   ======================================== */

.cv-portrait-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin: 36px auto;
}

.cv-portrait-glass {
  padding: 18px;
  border-radius: 28px;
  background: rgba(255,255,255,0.16);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255,255,255,0.28);
  box-shadow: 0 18px 48px rgba(0,0,0,0.35);
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

[data-theme="light"] .cv-portrait-glass {
  background: rgba(255,255,255,0.85);
  border: 1px solid rgba(200,200,200,0.5);
  box-shadow: 0 14px 42px rgba(50,50,50,0.18);
}

.cv-portrait-glass:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 64px rgba(0,0,0,0.40);
}

.cv-portrait-img {
  width: 260px;
  height: auto;
  border-radius: 20px;
  object-fit: cover;
  display: block;
}

.cv-signature {
  font-family: 'Dancing Script', 'Great Vibes', 'Poppins', cursive;
  font-size: 1.8rem;
  opacity: 0.9;
  letter-spacing: 1.5px;
  text-align: center;
  margin-top: 4px;
  color: #ffffff;
}

[data-theme="light"] .cv-signature {
  color: #222;
}

/* ========================================
   CONTACT PHOTO FRAME - Premium Glassmorphism
   ======================================== */

.contact-photo-frame {
  width: fit-content;
  margin: 0 auto;
  padding: 10px;
  border-radius: 22px;
  background: rgba(255,255,255,0.14);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255,255,255,0.35);
  box-shadow: 0 18px 42px rgba(0,0,0,0.35);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

html[data-theme="light"] .contact-photo-frame {
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 18px 42px rgba(15,23,42,0.2);
}

.contact-photo-frame:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 56px rgba(0,0,0,0.42);
}

html[data-theme="light"] .contact-photo-frame:hover {
  box-shadow: 0 24px 56px rgba(15,23,42,0.25);
}

.contact-photo-frame img {
  display: block;
  width: 180px;
  height: auto;
  border-radius: 16px;
  object-fit: cover;
}

/* ========================================
   GLASS IMAGE CARD - Blog & Works Pages
   ======================================== */

.glass-image-card {
  padding: 12px;
  border-radius: 20px;
  background: rgba(255,255,255,0.16);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.30);
  box-shadow: 0 12px 36px rgba(0,0,0,0.28);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  overflow: hidden;
}

html[data-theme="light"] .glass-image-card {
  background: rgba(255,255,255,0.85);
  border: 1px solid rgba(0,0,0,0.08);
  box-shadow: 0 12px 36px rgba(15,23,42,0.18);
}

.glass-image-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 48px rgba(0,0,0,0.38);
}

html[data-theme="light"] .glass-image-card:hover {
  box-shadow: 0 20px 48px rgba(15,23,42,0.24);
}

.glass-image-card img {
  width: 100%;
  height: auto;
  border-radius: 14px;
  object-fit: cover;
  display: block;
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .contact-photo-frame {
    padding: 8px;
    border-radius: 18px;
  }

  .contact-photo-frame img {
    width: 150px;
    border-radius: 12px;
  }

  .glass-image-card {
    padding: 10px;
    border-radius: 16px;
  }

  .glass-image-card img {
    border-radius: 12px;
  }
}

/* ======= LEGACY SUPPORT ======= */

/* Maintain backward compatibility with .image-frame */
.image-frame {
  position: relative;
  border-radius: 22px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(99,102,241,0.16), rgba(20,184,166,0.14));
  box-shadow: 0 18px 42px rgba(15,23,42,0.35);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: box-shadow 220ms ease-out;
}

.image-frame img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 220ms ease-out;
}

.image-frame:hover {
  box-shadow: 0 24px 56px rgba(99,102,241,0.42);
}

.image-frame:hover img {
  transform: translateY(-6px) scale(1.03);
}

/* Small variant (navbar logo) */
.image-frame-small {
  width: 44px;
  height: 44px;
  border-radius: 12px;
}

.image-frame-small img {
  object-fit: cover;
}

.brand-title {
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-size: 0.78rem;
}

.brand-subtitle {
  font-size: 0.7rem;
  color: var(--muted);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--glass-border);
  transition: all 0.3s ease;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

html[data-theme="light"] .nav-links {
  background: rgba(255, 255, 255, 0.75);
  border-color: rgba(255, 255, 255, 0.55);
}

.nav-links a {
  position: relative;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 999px;
  text-decoration: none;
  color: #f1f5f9;
  transition: color 0.25s ease, background 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

html[data-theme="light"] .nav-links a {
  color: #1f2937;
}

.nav-links a::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(20, 184, 166, 0.15));
  opacity: 0;
  transition: opacity 0.25s ease;
  z-index: -1;
}

.nav-links a:hover {
  color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(25, 46, 80, 0.18);
}

.nav-links a:hover::after {
  opacity: 1;
}

.nav-links a.active {
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  box-shadow: 0 10px 26px rgba(99, 102, 241, 0.35);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* Language Toggle - Premium Glass Pill with Flag Icons */
/* ========================================
   LANGUAGE SELECTOR - Glass UI System
   ======================================== */

.language-selector {
  position: relative;
}

/* Glass Language Toggle Button - 50px Circle */
.language-toggle-glass {
  position: relative;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 0;
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: visible;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

html[data-theme="light"] .language-toggle-glass {
  background: rgba(255, 255, 255, 0.25);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.language-toggle-glass:hover {
  transform: scale(1.06) translateY(-2px);
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(0, 0, 0, 0.35);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.18);
}

html[data-theme="light"] .language-toggle-glass:hover {
  background: rgba(255, 255, 255, 0.35);
  border-color: rgba(255, 255, 255, 0.45);
}

.language-toggle-glass:focus {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* Flag Icon Inside Button */
.language-toggle-glass .flag-icon {
  width: 24px;
  height: 24px;
  display: block;
  pointer-events: none;
}

/* Language Dropdown Menu - Glass Container */
.language-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  border-radius: 14px;
  background: rgba(15, 23, 42, 0.85);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border: 1px solid rgba(255, 255, 255, 0.25);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
  padding: 8px;
  opacity: 0;
  transform: translateY(-8px) scale(0.95);
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: none;
  z-index: 100;
}

html[dir="rtl"] .language-dropdown {
  right: auto;
  left: 0;
}

html[data-theme="light"] .language-dropdown {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.12);
}

.language-dropdown:not([hidden]) {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

/* Language Option Item */
.language-option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 10px;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.9rem;
  font-weight: 500;
  transition: all 0.2s ease;
  position: relative;
  cursor: pointer;
}

html[data-theme="light"] .language-option {
  color: rgba(15, 23, 42, 0.9);
}

.language-option:hover {
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 1);
  transform: translateX(4px);
}

html[dir="rtl"] .language-option:hover {
  transform: translateX(-4px);
}

html[data-theme="light"] .language-option:hover {
  background: rgba(0, 0, 0, 0.06);
  color: rgba(15, 23, 42, 1);
}

/* Active Language Indicator */
.language-option.active {
  background: rgba(99, 102, 241, 0.2);
  color: #818cf8;
  font-weight: 600;
}

html[data-theme="light"] .language-option.active {
  background: rgba(99, 102, 241, 0.12);
  color: #6366f1;
}

.language-option.active::after {
  content: "✓";
  position: absolute;
  right: 14px;
  font-size: 0.9rem;
  color: #818cf8;
}

html[dir="rtl"] .language-option.active::after {
  right: auto;
  left: 14px;
}

html[data-theme="light"] .language-option.active::after {
  color: #6366f1;
}

/* Small Flag Icons in Dropdown */
.flag-icon-small {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

/* Theme Toggle - Premium 40px Circular Glass Button */
.theme-toggle {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.15);
  padding: 0;
  cursor: pointer;
  outline: none;
  transition: all 0.3s ease;
  -webkit-appearance: none;
  appearance: none;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

html[data-theme="light"] .theme-toggle {
  background: rgba(255, 255, 255, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

/* Sun icon for light mode */
.theme-toggle::before {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%);
  box-shadow: 0 0 12px rgba(251, 191, 36, 0.6);
  transition: all 0.3s ease;
  transform: scale(0) rotate(-180deg);
  opacity: 0;
}

/* Moon icon for dark mode */
.theme-toggle::after {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
  box-shadow: 0 0 12px rgba(186, 230, 253, 0.6);
  transition: all 0.3s ease;
  transform: scale(1) rotate(0deg);
  opacity: 1;
}

html[data-theme="light"] .theme-toggle::before {
  transform: scale(1) rotate(0deg);
  opacity: 1;
}

html[data-theme="light"] .theme-toggle::after {
  transform: scale(0) rotate(180deg);
  opacity: 0;
}

.theme-toggle:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 255, 255, 0.45);
  background: rgba(255, 255, 255, 0.2);
}

html[data-theme="light"] .theme-toggle:hover {
  background: rgba(255, 255, 255, 0.45);
}

html[data-theme="light"] .theme-toggle:hover {
  box-shadow: 0 6px 18px rgba(251, 191, 36, 0.4),
              0 0 20px rgba(251, 191, 36, 0.35),
              inset 0 1px 0 rgba(255, 255, 255, 0.8);
  border-color: rgba(251, 191, 36, 0.5);
}

.theme-toggle:focus {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* HERO */

.hero {
  position: relative;
  padding-block: 56px 40px;
  overflow: hidden;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  inset: -40%;
  opacity: 0.6;
  filter: blur(20px);
  animation: orbitHero 40s linear infinite;
  z-index: -2;
}

html[data-theme="light"] .hero::before {
  background:
    radial-gradient(circle at 10% 15%, rgba(99, 102, 241, 0.14), transparent 45%),
    radial-gradient(circle at 85% 20%, rgba(20, 184, 166, 0.12), transparent 50%),
    radial-gradient(circle at 50% 100%, rgba(99, 102, 241, 0.08), transparent 50%);
}

html[data-theme="dark"] .hero::before {
  background:
    radial-gradient(circle at 10% 15%, rgba(99, 102, 241, 0.2), transparent 45%),
    radial-gradient(circle at 85% 20%, rgba(20, 184, 166, 0.18), transparent 50%),
    radial-gradient(circle at 50% 100%, rgba(99, 102, 241, 0.12), transparent 50%);
}

.hero::after {
  mix-blend-mode: screen;
  opacity: 0.4;
  animation-direction: reverse;
}

html[data-theme="light"] .hero::after {
  background:
    radial-gradient(circle at 20% 10%, rgba(255, 255, 255, 0.6), transparent 45%),
    radial-gradient(circle at 85% 15%, rgba(255, 255, 255, 0.45), transparent 50%);
}

html[data-theme="dark"] .hero::after {
  background:
    radial-gradient(circle at 20% 10%, rgba(99, 102, 241, 0.12), transparent 50%),
    radial-gradient(circle at 85% 15%, rgba(20, 184, 166, 0.1), transparent 55%);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 32px;
  align-items: center;
}

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

.hero-title {
  font-size: clamp(2.2rem, 4vw, 2.9rem);
  letter-spacing: -0.03em;
  margin-bottom: 10px;
  animation: titleFadeUp 0.8s ease-out;
}

.hero-gradient-text {
  display: inline-block;
  background: linear-gradient(120deg, var(--primary) 0%, var(--secondary) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 6s ease infinite;
}

html[data-theme="light"] .hero-gradient-text {
  background: linear-gradient(120deg, var(--primary) 0%, var(--secondary) 100%);
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-lead {
  font-size: 0.98rem;
  line-height: 1.7;
  color: var(--muted);
  margin-bottom: 18px;
  transition: color 0.6s ease;
}

.eyebrow {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--primary);
  margin-bottom: 8px;
  animation: fadeInSlideRight 0.6s ease-out 0.2s backwards;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 16px;
}

.btn {
  border-radius: 999px;
  padding: 9px 18px;
  font-size: 0.85rem;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease,
    border-color 0.22s ease,
    color 0.22s ease;
  animation: fadeInScale 0.6s ease-out 0.4s backwards;
}

.hero-actions .btn:nth-child(2) {
  animation-delay: 0.5s;
}

.btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  color: #ffffff;
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.35);
  font-weight: 600;
}

html[data-theme="light"] .btn.primary {
  box-shadow: 0 8px 20px rgba(99, 102, 241, 0.3);
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(99, 102, 241, 0.45);
}

.btn.ghost {
  border-color: var(--primary);
  background: transparent;
  color: var(--primary);
  transition: all 0.22s ease;
}

html[data-theme="light"] .btn.ghost {
  background: rgba(99, 102, 241, 0.05);
  color: var(--primary-strong);
  border-color: var(--primary);
}

.btn.ghost:hover {
  border-color: var(--secondary);
  background: rgba(20, 184, 166, 0.12);
  color: var(--secondary-strong);
}

.btn:hover {
  transform: translateY(-1px);
}

.hero-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  border-radius: 999px;
  border: 1px solid rgba(99, 102, 241, 0.3);
  background: rgba(99, 102, 241, 0.12);
  color: var(--primary-strong);
  font-size: 0.75rem;
  padding: 5px 12px;
  transition: all 0.25s ease;
}

html[data-theme="light"] .chip {
  border-color: rgba(99, 102, 241, 0.25);
  background: rgba(99, 102, 241, 0.1);
  color: var(--primary-strong);
}

.chip:hover {
  background: rgba(99, 102, 241, 0.18);
  border-color: var(--primary);
  transform: scale(1.05);
}

.hero-title {
  font-size: clamp(1.8rem, 3vw + 1rem, 2.8rem);
  margin: 0 0 12px 0;
  line-height: 1.2;
  color: var(--text);
  animation: titleFadeUp 0.7s ease-out;
}

.hero-title .hero-gradient-text {
  display: block;
  background: linear-gradient(120deg, var(--primary), color-mix(in srgb, var(--primary) 60%, #ffffff 40%), var(--secondary));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-mini {
  height: 120px;
}

/* Sections */

.section {
  padding-block: 48px;
}

.section-header {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 24px;
}

.section-title {
  font-size: 1.3rem;
  margin: 0;
}

.section-subtitle {
  margin: 0;
  font-size: 0.92rem;
  color: var(--muted);
}

/* Hero imagery helpers */

/* Hero photo layout */
.hero-aside {
  display: grid;
  gap: 14px;
  justify-items: center;
  align-content: start;
}

.hero-photo-frame {
  width: 100%;
  max-width: 360px;
}

.hero-photo-row {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  width: 100%;
  max-width: 360px;
}

.hero-mini {
  aspect-ratio: 1;
  width: 100%;
}

.btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #ffffff;
  box-shadow: 0 14px 32px rgba(25, 46, 80, 0.28);
  font-weight: 700;
}

html[data-theme="light"] .btn.primary {
  box-shadow: 0 12px 28px rgba(25, 46, 80, 0.18);
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 18px 40px rgba(25, 46, 80, 0.28);
}

.btn.ghost {
  border-color: var(--glass-border);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  transition: all 0.22s ease;
}

html[data-theme="light"] .btn.ghost {
  background: rgba(255,255,255,0.78);
  color: #1c2534;
  border-color: rgba(255, 255, 255, 0.6);
}

.btn.ghost:hover {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--primary) 12%, transparent);
  color: var(--accent);
}

.card {
  border-radius: 16px;
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.12);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.card-visible {
  opacity: 1;
  transform: translateY(0);
}

.card:hover {
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.18);
  border-color: color-mix(in srgb, var(--primary) 30%, #ffffff 70%);
  transform: translateY(-3px);
}

.card-title {
  font-size: 1rem;
  margin-bottom: 6px;
  transition: color 0.3s ease;
}

.card-meta {
  font-size: 0.86rem;
  color: var(--muted);
  margin-bottom: 10px;
  transition: color 0.3s ease;
}

.card-text {
  font-size: 0.92rem;
  line-height: 1.6;
}

.card-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.86rem;
  margin-top: 12px;
  color: var(--accent);
  text-decoration: none;
  transition: all 0.25s ease;
}

.card-link:hover {
  transform: translateX(4px);
}

.links-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 12px;
}

.links-list a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.84rem;
  color: var(--accent);
  text-decoration: none;
  transition: all 0.25s ease;
  padding: 6px 10px;
  border-radius: 4px;
  border: 1px solid transparent;
}

.links-list a:hover {
  transform: translateX(4px);
  background-color: color-mix(in srgb, var(--accent) 15%, transparent);
  border-color: var(--accent);
}

.links-list a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Gallery */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.gallery-item {
  height: 180px;
  opacity: 0;
  transform: scale(0.9);
  animation: fadeInScale 0.5s ease-out forwards;
}

.gallery-item:nth-child(1) { animation-delay: 0.1s; }
.gallery-item:nth-child(2) { animation-delay: 0.2s; }
.gallery-item:nth-child(3) { animation-delay: 0.3s; }
.gallery-item:nth-child(4) { animation-delay: 0.4s; }
.gallery-item:nth-child(5) { animation-delay: 0.5s; }

.gallery-item:hover .image-frame {
  transform: scale(1.05);
}

/* Layout helpers */

.two-column-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.1fr);
  gap: 24px;
}

/* CV / Timeline */

.timeline {
  display: grid;
  gap: 14px;
}

.timeline-item {
  position: relative;
  padding-left: 18px;
  border-left: 2px dashed var(--border-soft);
  transition: border-color 0.3s ease;
}

.timeline-title {
  font-size: 0.96rem;
  margin-bottom: 4px;
}

.timeline-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 6px;
}

.skills-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 6px;
}

.skills-list li {
  font-size: 0.88rem;
}

.skill-bars {
  display: grid;
  gap: 10px;
}

.skill-row {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.skill-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
}

.skill-track {
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.12);
  overflow: hidden;
  box-shadow: inset 0 2px 4px rgba(15, 23, 42, 0.08);
  transition: background 0.3s ease;
}

html[data-theme="light"] .skill-track {
  background: rgba(99, 102, 241, 0.1);
}

.skill-fill {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--primary) 0%, color-mix(in srgb, var(--primary) 60%, var(--secondary) 40%) 50%, var(--secondary) 100%);
  box-shadow: 0 0 12px rgba(99, 102, 241, 0.5);
  transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Contact */

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.form-grid label {
  font-size: 0.8rem;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.form-grid .full {
  grid-column: 1 / -1;
}

input,
textarea {
  border-radius: 10px;
  border: 1px solid var(--border-soft);
  background: var(--bg-soft);
  color: var(--text);
  padding: 8px 10px;
  font-family: inherit;
  font-size: 0.86rem;
  transition: all 0.25s ease;
}

html[data-theme="light"] input,
html[data-theme="light"] textarea {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(174, 194, 224, 0.4);
}

html[data-theme="dark"] input,
html[data-theme="dark"] textarea {
  background: rgba(30, 38, 54, 0.65);
  border-color: rgba(99, 102, 241, 0.28);
}

input:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 14px rgba(99, 102, 241, 0.4);
}

select {
  border-radius: 10px;
  border: 1px solid var(--border-soft);
  background: var(--bg-soft);
  color: var(--text);
  padding: 8px 10px;
  font-family: inherit;
  font-size: 0.86rem;
  transition: all 0.25s ease;
  cursor: pointer;
}

html[data-theme="light"] select {
  background: rgba(255, 255, 255, 0.95);
  border-color: rgba(174, 194, 224, 0.4);
}

html[data-theme="dark"] select {
  background: rgba(30, 38, 54, 0.65);
  border-color: rgba(99, 102, 241, 0.28);
}

select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 14px rgba(99, 102, 241, 0.4);
}

/* Contact Methods Grid */
.contact-methods-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-block-start: 28px;
}

.contact-method-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 28px 20px;
  text-align: center;
  text-decoration: none;
  color: var(--text);
  border-radius: 18px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.contact-method-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(99, 102, 241, 0.3);
}

.contact-icon {
  width: 56px;
  height: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.15), rgba(20, 184, 166, 0.15));
  transition: all 0.3s ease;
}

.contact-method-card:hover .contact-icon {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.3), rgba(20, 184, 166, 0.3));
  transform: scale(1.1);
}

.contact-icon svg {
  width: 28px;
  height: 28px;
  color: var(--primary);
}

.contact-method-card h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 0;
  color: var(--text);
}

.contact-method-card p {
  font-size: 0.85rem;
  margin: 0;
  opacity: 0.75;
}

/* Contact Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-block-start: 20px;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
}

.contact-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.88rem;
  font-weight: 500;
}

.form-full {
  grid-column: 1 / -1;
}

.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
}

.contact-form button {
  margin-inline-start: auto;
}

@media (max-width: 600px) {
  .form-row {
    grid-template-columns: 1fr;
  }
  
  .contact-methods-grid {
    grid-template-columns: 1fr;
  }
}

/* Footer */

.site-footer {
  padding-block: 20px;
  border-top: 1px solid var(--glass-border);
  background: var(--glass-surface);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  transition: all 0.6s ease;
}

html[data-theme="light"] .site-footer {
  background: var(--glass-surface);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--muted);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-links a {
  text-decoration: none;
  color: inherit;
  font-size: 0.8rem;
}

/* Video cards */

.video-card .video-embed {
  margin-top: 10px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border-soft);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.video-card:hover .video-embed {
  border-color: var(--accent);
  box-shadow: 0 8px 24px rgba(235, 65, 255, 0.18);
}

.video-card iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: none;
}

/* Simple FAQ */

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  border-radius: var(--radius-md);
  background: var(--bg-soft);
  padding: 10px 12px;
  border: 1px solid var(--border-soft);
  font-size: 0.86rem;
  transition: all 0.25s ease;
}

.faq-item summary {
  cursor: pointer;
  font-weight: 600;
  padding: 8px 0;
  user-select: none;
  transition: color 0.25s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

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

.faq-item summary::marker {
  color: var(--accent);
}

.faq-item[open] {
  background: var(--accent-soft);
  border-color: var(--accent);
}

.faq-item p {
  margin: 8px 0 0 0;
  line-height: 1.6;
  animation: expandFade 0.3s ease-out;
}

html[data-theme="light"] .faq-item {
  background: rgba(240, 245, 251, 0.8);
  border-color: rgba(174, 194, 224, 0.3);
}

html[data-theme="dark"] .faq-item {
  background: rgba(25, 35, 75, 0.35);
  border-color: rgba(255, 79, 185, 0.22);
}

.faq-item:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

/* Utilities */

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

.gradient-text {
  background: linear-gradient(120deg, var(--primary) 0%, var(--secondary) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: gradientShift 6s ease infinite;
}

.mt-2 { margin-top: 8px; }
.mt-3 { margin-top: 12px; }
.mt-4 { margin-top: 16px; }

/* Arabic font */
html[lang="ar"] body {
  font-family: var(--font-arabic);
}

/* Animations */

@keyframes orbitGlow {
  0% { transform: translate3d(0,0,0) scale(1); }
  50% { transform: translate3d(0,-12px,0) scale(1.04); }
  100% { transform: translate3d(0,10px,0) scale(1.02); }
}

@keyframes orbitHero {
  0% { transform: translate3d(0,0,0) rotate(0deg); }
  100% { transform: translate3d(0,0,0) rotate(360deg); }
}

@keyframes liquidWave {
  0% {
    background-position: 0 0, 0 0, 0 0;
  }
  25% {
    background-position: -100px -20px, 2% 0, -1% 0;
  }
  50% {
    background-position: -200px 0, 0 0, 1% 0;
  }
  75% {
    background-position: -100px 20px, -2% 0, -1% 0;
  }
  100% {
    background-position: 0 0, 0 0, 0 0;
  }
}

@keyframes glowFloat {
  0%, 100% {
    filter: brightness(1) blur(1px);
  }
  50% {
    filter: brightness(1.1) blur(1.5px);
  }
}

@keyframes nebulaDrift {
  0%, 100% {
    filter: brightness(1) blur(0.5px) saturate(0.95);
    transform: translate(0, 0);
  }
  25% {
    filter: brightness(1.05) blur(0.8px) saturate(1);
    transform: translate(10px, -10px);
  }
  50% {
    filter: brightness(1) blur(0.5px) saturate(1.05);
    transform: translate(0, 15px);
  }
  75% {
    filter: brightness(0.95) blur(0.6px) saturate(0.95);
    transform: translate(-10px, 5px);
  }
}

@keyframes nebulaGlow {
  0%, 100% {
    opacity: 0.7;
    filter: blur(0px);
  }
  50% {
    opacity: 0.85;
    filter: blur(1px);
  }
}

@keyframes softBlob {
  0%, 100% {
    transform: translate(0, 0) scale(1);
  }
  33% {
    transform: translate(2%, -3%) scale(1.04);
  }
  66% {
    transform: translate(-3%, 2%) scale(0.98);
  }
}

@media (prefers-reduced-motion: reduce) {
  body::after { animation: none !important; }
  body::before { animation: none !important; }
  .hero-title, .btn, .card { transition: none !important; }
}

/* Glassmorphism helpers */
.glass {
  background: var(--glass-surface);
  border: 1px solid var(--glass-border);
  backdrop-filter: blur(var(--blur)) saturate(1.05);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(1.05);
  box-shadow: var(--shadow-soft);
  border-radius: 18px;
  padding: 20px;
}

/* Hero glass specifics */
.hero .hero-content .glass-hero {
  padding: 28px;
}

/* ========================================
   YOUTUBE SECTION - Modern Featured + Grid
   ======================================== */

/* Section Title & Description */
.yt-section-title {
  font-size: 2.2rem;
  font-weight: 700;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #6366f1, #14b8a6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.yt-section-desc {
  font-size: 1.05rem;
  line-height: 1.7;
  margin-bottom: 20px;
  opacity: 0.9;
  max-width: 820px;
}

.yt-section-desc strong {
  color: var(--accent, #6366f1);
}

/* Category Label */
.yt-category-label {
  margin-bottom: 35px;
  opacity: 0.75;
  font-size: 0.95rem;
  letter-spacing: 0.4px;
  text-align: center;
}

[dir="rtl"] .yt-category-label {
  direction: rtl;
}

/* Featured Video Card */
.yt-featured {
  margin-bottom: 48px;
}

.yt-featured-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 24px;
  min-height: 320px;
}

.yt-featured-thumb {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 16/9;
  cursor: pointer;
}

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

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

.yt-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.95);
  border: none;
  color: #6366f1;
  font-size: 1.8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 4px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  z-index: 10;
}

.yt-play-btn:hover {
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 12px 32px rgba(99, 102, 241, 0.5);
}

[data-theme="light"] .yt-play-btn {
  background: rgba(255, 255, 255, 1);
  color: #6366f1;
}

.yt-featured-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: 8px;
}

[dir="rtl"] .yt-featured-info {
  text-align: right;
}

.yt-featured-title {
  font-size: 1.7rem;
  font-weight: 700;
  margin: 0;
  line-height: 1.3;
}

.yt-featured-desc {
  font-size: 1rem;
  line-height: 1.6;
  margin: 0;
  opacity: 0.85;
}

.yt-featured-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  width: fit-content;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.35);
}

.yt-featured-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(99, 102, 241, 0.5);
}

/* Video Grid */
.yt-grid {
  margin-top: 32px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
}

.yt-card {
  cursor: pointer;
  padding: 0;
  overflow: hidden;
  border-radius: 20px;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.yt-card:hover {
  border-color: rgba(99, 102, 241, 0.6);
  box-shadow: 0 24px 56px rgba(99, 102, 241, 0.25);
}

.yt-thumb {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
}

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

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

.yt-duration {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.85);
  color: #fff;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  z-index: 5;
}

[dir="rtl"] .yt-duration {
  right: auto;
  left: 8px;
}

.yt-meta {
  padding: 16px;
}

[dir="rtl"] .yt-meta {
  text-align: right;
}

.yt-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 0;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* CTA Buttons */
.yt-cta-box {
  margin-top: 45px;
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.yt-cta {
  padding: 12px 22px;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.yt-cta.primary {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.35);
}

.yt-cta.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(99, 102, 241, 0.5);
}

.yt-cta.secondary {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: var(--text, #fff);
  backdrop-filter: blur(10px);
}

.yt-cta.secondary:hover {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(99, 102, 241, 0.5);
  transform: translateY(-2px);
}

[data-theme="light"] .yt-cta.secondary {
  background: rgba(255, 255, 255, 0.6);
  border-color: rgba(0, 0, 0, 0.15);
  color: #111827;
}

[data-theme="light"] .yt-cta.secondary:hover {
  background: rgba(255, 255, 255, 0.9);
  border-color: rgba(99, 102, 241, 0.4);
}

/* Glass Effect for Cards */
.glass {
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 20px;
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.30);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

[data-theme="light"] .glass {
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid rgba(200, 200, 200, 0.4);
  box-shadow: 0 10px 26px rgba(15, 23, 42, 0.18);
}

.glass:hover {
  transform: translateY(-4px);
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.40);
}

[data-theme="light"] .glass:hover {
  box-shadow: 0 16px 38px rgba(15, 23, 42, 0.25);
}

/* Modal Player Improvements */
.yt-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1200;
  animation: fadeIn 0.2s ease;
}

.yt-modal.open {
  display: flex;
}

.yt-modal .backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 6, 16, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.yt-modal .player {
  width: min(1100px, 95%);
  aspect-ratio: 16/9;
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  z-index: 1201;
  box-shadow: 0 24px 80px rgba(5, 2, 20, 0.9);
  animation: slideUp 0.3s ease;
}

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

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

/* Responsive */
@media (max-width: 1024px) {
  .yt-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .yt-featured-card {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .yt-section-title {
    font-size: 1.8rem;
  }

  .yt-featured-title {
    font-size: 1.4rem;
  }

  .yt-cta-box {
    flex-direction: column;
    align-items: stretch;
  }

  .yt-cta {
    text-align: center;
    justify-content: center;
  }
}

@media (max-width: 600px) {
  .yt-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .yt-featured-card {
    padding: 16px;
  }

  .yt-section-title {
    font-size: 1.6rem;
  }
}

/* OLD Video Grid (Legacy - Keep for backwards compatibility) */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
}

.video-card {
  padding: 14px;
  border-radius: 16px;
  position: relative;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: linear-gradient(145deg, rgba(255,255,255,0.06), rgba(255,255,255,0.03));
  border: 1px solid rgba(255,255,255,0.08);
  box-shadow: 0 18px 50px rgba(5, 2, 20, 0.6);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.video-card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 24px 60px rgba(99, 102, 241, 0.35);
  border-color: rgba(99, 102, 241, 0.4);
}

.video-card .thumb-wrap {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  isolation: isolate;
}

.video-card .thumb-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.28), rgba(20, 184, 166, 0.24));
  opacity: 0;
  transition: opacity 0.25s ease;
}

.video-card:hover .thumb-wrap::after { opacity: 1; }

.video-card .thumb {
  width: 100%;
  aspect-ratio: 16/9;
  object-fit: cover;
  display: block;
  border-radius: 14px;
}

.video-card .play-badge {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 1.2rem;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.2s ease, transform 0.2s ease;
  text-shadow: 0 8px 30px rgba(0,0,0,0.6);
}

.video-card:hover .play-badge { opacity: 1; transform: scale(1.05); }

.video-card h4 { margin: 0; font-size: 1.05rem; }
.video-card p { margin: 0; color: var(--muted); font-size: 0.9rem; }

.card-meta {
  font-size: 0.85rem;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 999px;
  width: fit-content;
}

/* Modal player */
.yt-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1200;
}
.yt-modal.open { display: flex; }
.yt-modal .backdrop {
  position: absolute; inset: 0; background: rgba(4,6,16,0.7);
}
.yt-modal .player {
  width: min(1100px, 95%);
  aspect-ratio: 16/9;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  z-index: 1201;
  box-shadow: 0 18px 60px rgba(5, 2, 20, 0.8);
}

/* YouTube channel hub */
.channel-hero {
  position: relative;
  overflow: hidden;
  border-radius: 28px;
}

.channel-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(900px 600px at 15% 20%, rgba(99, 102, 241, 0.18), transparent 50%),
              radial-gradient(700px 500px at 85% 40%, rgba(20, 184, 166, 0.16), transparent 55%);
  filter: blur(0.5px);
  z-index: 0;
  opacity: 0.9;
}

.channel-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 28px;
  align-items: center;
}

.channel-hero-copy .hero-title { margin-bottom: 8px; }
.channel-hero-copy .hero-lead { margin: 0 0 12px 0; color: var(--text); opacity: 0.95; }
.hero-lead-en { color: var(--muted); font-size: 0.98rem; }

.channel-hero-media { display: grid; gap: 12px; }
.hero-media-card { padding: 0; overflow: hidden; border-radius: 18px; }
.hero-media-card img { width: 100%; display: block; border-radius: 16px; }
.hero-media-row { display: grid; grid-template-columns: repeat(2, minmax(120px,1fr)); gap: 10px; }
.hero-media-mini img { width: 100%; height: 100%; object-fit: cover; border-radius: 14px; display: block; }

.badge-pill {
  position: absolute;
  bottom: 14px;
  inset-inline: 14px;
  padding: 8px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-size: 0.9rem;
  box-shadow: 0 10px 30px rgba(0,0,0,0.4);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 10px;
}

.glass-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: 14px;
  text-decoration: none;
  color: var(--text);
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(255,255,255,0.06);
  box-shadow: 0 14px 40px rgba(5,2,20,0.4);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.glass-btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  color: #fff;
  border-color: rgba(255,255,255,0.25);
}

.glass-btn:hover { transform: translateY(-2px); box-shadow: 0 18px 50px rgba(99, 102, 241, 0.4); }
.glass-btn.ghost { background: rgba(255,255,255,0.03); }

.stats-strip {
  padding: 10px 0;
}

.stats-grid.compact {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px,1fr));
  gap: 12px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px;
}

.stat-icon { font-size: 1.2rem; }

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}

.testimonial {
  display: flex;
  gap: 12px;
  padding: 14px;
  border-radius: 16px;
}

.testimonial .avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: #fff;
  font-weight: 700;
}

.testimonial-name { margin: 0 0 6px 0; font-size: 0.95rem; }
.testimonial-quote { margin: 0; color: var(--muted); line-height: 1.6; font-size: 0.92rem; }

.channel-cta {
  border-radius: 22px;
  padding: 28px 0;
}

.channel-cta-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

@media (max-width: 640px) {
  .channel-hero-grid { grid-template-columns: 1fr; }
  .channel-cta-inner { flex-direction: column; align-items: flex-start; }
}

/* small tweaks to existing glass-like card appearance */
.card {
  border-radius: 16px;
  background: linear-gradient(160deg, rgba(255,255,255,0.06), rgba(255,255,255,0.03));
  border: 1px solid rgba(255,255,255,0.12);
  box-shadow: 0 14px 40px rgba(5, 2, 20, 0.38);
  backdrop-filter: blur(10px) saturate(1.05);
  -webkit-backdrop-filter: blur(10px) saturate(1.05);
}

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

@keyframes gradientShift {
  0% {
    background-position: 0% center;
  }
  50% {
    background-position: 100% center;
  }
  100% {
    background-position: 0% center;
  }
}

@keyframes fadeInScale {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes fadeInSlideRight {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Dynamic text fade transitions */
@keyframes textFadeIn {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

.dynamic-text {
  opacity: 1;
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.dynamic-text.fade-out {
  animation: textFadeOut 0.4s ease forwards;
}

.dynamic-text.fade-in {
  animation: textFadeIn 0.4s ease forwards;
}

@keyframes expandFade {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes floatFrame {
  0%, 100% {
    transform: translateY(0) translateZ(0);
  }
  50% {
    transform: translateY(-8px) translateZ(0);
  }
}

/* Section entrance animations */

.section-animated {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.section-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Card staggered animation */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 18px;
}

.cards-grid .card:nth-child(1) { animation-delay: 0s; }
.cards-grid .card:nth-child(2) { animation-delay: 0.1s; }
.cards-grid .card:nth-child(3) { animation-delay: 0.2s; }
.cards-grid .card:nth-child(n+4) { animation-delay: 0.3s; }

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Additional transition utilities */
*:not(.theme-toggle) {
  transition: background-color 0.35s ease, color 0.35s ease, border-color 0.35s ease;
}

/* Professional hover states for interactive elements */
a, button {
  position: relative;
}

/* Keyboard accessibility - Focus states */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.nav-links a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 0;
}

.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Enhance navbar stickiness with improved backdrop */
.navbar {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

html[data-theme="dark"] .navbar {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

@media (max-width: 860px) {
  .navbar-inner {
    flex-wrap: wrap;
  }
  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .two-column-layout {
    grid-template-columns: minmax(0, 1fr);
  }
  .section-grid.three-columns {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* CV Page Enhancements */

.cv-portrait-card {
  width: min(340px, 38vw);
  aspect-ratio: 3 / 4;
  padding: 10px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-soft);
}

.cv-portrait {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius-lg) - 6px);
}

.cv-portrait-minis {
  display: flex;
  gap: 12px;
  margin-top: 12px;
  flex-wrap: wrap;
}

.cv-portrait-mini {
  width: 98px;
  aspect-ratio: 1;
  padding: 6px;
  border-radius: var(--radius-md);
  overflow: hidden;
  display: block;
}

.cv-portrait-mini img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius-md) - 4px);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 16px;
  margin-bottom: 2rem;
}

.stat-card {
  text-align: center;
  padding: 24px 16px;
  border-radius: 16px;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-card:hover {
  transform: translateY(-4px);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 8px;
  font-variant-numeric: tabular-nums;
}

.stat-label {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* Timeline Vertical */

.timeline-vertical {
  position: relative;
  padding: 20px 0;
}

.timeline-vertical::before {
  content: '';
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--primary), var(--secondary));
  border-radius: 999px;
}

.timeline-item {
  margin-bottom: 32px;
  position: relative;
  margin-left: 0;
  margin-right: 0;
  display: flex;
  gap: 20px;
}

.timeline-dot {
  position: absolute;
  left: 50%;
  top: 24px;
  transform: translateX(-50%);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border: 2.5px solid var(--glass-surface);
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
  z-index: 10;
}

.timeline-item:nth-child(odd) {
  margin-left: 0;
  padding-right: calc(50% + 40px);
  text-align: right;
}

.timeline-item:nth-child(even) {
  margin-left: calc(50% + 40px);
  padding-left: 0;
  text-align: left;
}

.timeline-content {
  padding: 16px;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 8px;
}

.timeline-year {
  font-size: 0.85rem;
  opacity: 0.7;
  white-space: nowrap;
}

.timeline-description {
  font-size: 0.95rem;
  line-height: 1.6;
  margin: 12px 0;
}

.timeline-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.tag {
  font-size: 0.75rem;
  padding: 4px 12px;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.14);
  color: inherit;
  border: 1px solid rgba(99, 102, 241, 0.28);
}

/* Skills Categories Grid */

.skills-categories {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.skill-category {
  padding: 24px;
  border-radius: 16px;
}

.category-title {
  font-size: 1.2rem;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Languages - glass rows with animated bars */

.cv-languages {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin-top: 8px;
}

.language-item {
  position: relative;
  padding: 18px 20px;
  border-radius: 18px;
  border: 1px solid var(--glass-border);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.12), rgba(99, 102, 241, 0.08));
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  overflow: hidden;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.language-item::before {
  content: "";
  position: absolute;
  inset: -30% auto auto 55%;
  width: 220px;
  height: 220px;
  background: radial-gradient(circle, rgba(99, 102, 241, 0.14), transparent 55%);
  z-index: -1;
  transform: rotate(18deg);
}

.language-meta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.language-flag {
  font-size: 1.8rem;
}

.language-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.language-name {
  font-size: 1.05rem;
  font-weight: 700;
}

.language-level {
  font-size: 0.92rem;
  color: var(--muted);
}

.language-bar {
  position: relative;
  height: 14px;
  border-radius: 999px;
  background: linear-gradient(120deg, rgba(99, 102, 241, 0.16), rgba(20, 184, 166, 0.12));
  border: 1px solid var(--glass-border);
  overflow: hidden;
}

.language-bar::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.12), transparent 55%);
  pointer-events: none;
}

.language-bar-fill {
  position: absolute;
  inset-block: 2px;
  inset-inline-start: 2px;
  height: calc(100% - 4px);
  width: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  box-shadow: 0 10px 30px rgba(99, 102, 241, 0.35), inset 0 0 0 1px rgba(255, 255, 255, 0.14);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 700;
  padding-inline: 10px;
  transition: width 0.9s ease;
}

.language-percent {
  opacity: 0.92;
}

/* ============================================================================
   Blog Page - Projects, Articles, Gallery, Collaboration Sections
   ============================================================================ */

/* Cards Grid - responsive layout for projects and blog articles */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  animation: fadeInUp 0.6s ease;
}

.project-card,
.blog-card {
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  overflow: hidden;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.project-card:hover,
.blog-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 24px 48px rgba(99, 102, 241, 0.18);
}

/* Project Card Styling */
.project-image {
  position: relative;
  width: 100%;
  height: 240px;
  overflow: hidden;
}

.project-image .glass-photo {
  width: 100%;
  height: 100%;
}

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

.project-content {
  flex: 1;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0;
}

.card-meta {
  font-size: 0.9rem;
  color: var(--muted);
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.card-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
  flex: 1;
}

.project-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: auto;
}

.tag {
  display: inline-block;
  padding: 6px 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(20, 184, 166, 0.08));
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 20px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
  transition: all 0.25s ease;
}

.tag:hover {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(20, 184, 166, 0.12));
  border-color: rgba(99, 102, 241, 0.3);
}

/* Blog Article Cards */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  animation: fadeInUp 0.6s ease 0.1s both;
}

.blog-image {
  position: relative;
  width: 100%;
  height: 220px;
  overflow: hidden;
}

.blog-image .glass-photo {
  width: 100%;
  height: 100%;
}

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

.blog-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.blog-meta {
  font-size: 0.85rem;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin: 0;
}

.blog-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--foreground);
  line-height: 1.4;
  margin: 0;
}

.blog-text {
  font-size: 0.93rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin: 0;
  flex: 1;
}

.blog-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--primary);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.9rem;
  transition: all 0.25s ease;
  margin-top: auto;
}

.blog-link:hover {
  gap: 12px;
  color: var(--secondary);
  transform: translateX(2px);
}

/* Gallery Grid - Large image layout */
.gallery-grid-large {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  animation: fadeInUp 0.6s ease 0.15s both;
}

.gallery-grid-large figure {
  margin: 0;
  border-radius: 16px;
  overflow: hidden;
  aspect-ratio: 1;
  transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-grid-large figure:hover {
  transform: scale(1.04);
  box-shadow: 0 20px 40px rgba(99, 102, 241, 0.16);
}

.gallery-grid-large img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Collaboration Section */
.collab-panel {
  padding: 48px;
  border-radius: 24px;
  text-align: center;
  animation: fadeInUp 0.6s ease 0.2s both;
}

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

#collab-title {
  font-size: 2.5rem;
  margin-bottom: 12px;
  animation: fadeInDown 0.5s ease 0.2s both;
}

.collab-intro {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin: 16px 0 32px 0;
  line-height: 1.6;
}

.collab-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin: 32px 0;
}

.collab-item {
  padding: 20px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(20, 184, 166, 0.06));
  border: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

.collab-item:hover {
  transform: translateY(-4px);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(20, 184, 166, 0.1));
  border-color: rgba(99, 102, 241, 0.3);
}

.collab-item h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 8px 0;
}

.collab-item p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
}

.collab-closing {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-top: 32px;
  line-height: 1.6;
}

.collab-cta {
  color: var(--primary);
  font-weight: 700;
  text-decoration: none;
  transition: all 0.25s ease;
}

.collab-cta:hover {
  color: var(--secondary);
  text-decoration: underline;
}

/* Social Icons Section */
.social-bar {
  padding: 40px;
  border-radius: 20px;
  text-align: center;
  animation: fadeInUp 0.6s ease 0.25s both;
}

.social-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 24px 0;
}

.social-icons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(56px, 1fr));
  gap: 16px;
  max-width: 500px;
  margin: 0 auto;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(20, 184, 166, 0.08));
  border: 1.5px solid var(--glass-border);
  color: var(--primary);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  margin: 0 auto;
  text-decoration: none;
}

.social-icon:hover {
  color: var(--secondary);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.18), rgba(20, 184, 166, 0.12));
  border-color: var(--secondary);
  transform: translateY(-4px) scale(1.08);
  box-shadow: 0 12px 24px rgba(99, 102, 241, 0.2);
}

.social-icon svg {
  width: 24px;
  height: 24px;
  stroke-width: 2;
}

/* Section Header - for consistent styling */
.section-header {
  text-align: center;
  margin-bottom: 48px;
  animation: fadeInDown 0.5s ease both;
}

.section-title {
  font-size: 2.2rem;
  font-weight: 800;
  margin: 0 0 12px 0;
  letter-spacing: -0.5px;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.5;
}

/* Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

/* Responsive adjustments */
@media (max-width: 768px) {
  .collab-panel {
    padding: 32px 24px;
  }

  #collab-title {
    font-size: 2rem;
  }

  .section-title {
    font-size: 1.8rem;
  }

  .cards-grid,
  .blog-grid {
    gap: 20px;
  }

  .social-icons-grid {
    grid-template-columns: repeat(3, 1fr);
  }

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

  .project-image,
  .blog-image {
    height: 200px;
  }
}

.cv-languages[dir="rtl"] .language-item {
  text-align: right;
}

.cv-languages[dir="rtl"] .language-meta {
  flex-direction: row-reverse;
}

.cv-languages[dir="rtl"] .language-text {
  text-align: right;
}

.cv-languages[dir="rtl"] .language-bar-fill {
  inset-inline-start: auto;
  inset-inline-end: 2px;
  justify-content: flex-start;
  flex-direction: row-reverse;
}

/* Contact Buttons */

.contact-buttons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
}

.btn-contact {
  padding: 16px 20px;
  border-radius: 12px;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 500;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: 1px solid rgba(99, 102, 241, 0.32);
}

.btn-contact:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.35);
}

.btn-contact span {
  font-size: 1.2rem;
}

/* ========================================
   CV SOCIAL MEDIA SECTION - Glassmorphism
   ======================================== */

.cv-social-section {
  margin-top: 28px;
  text-align: center;
  padding: 20px 0;
}

.cv-social-title {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 18px;
  opacity: 0.9;
  color: inherit;
}

.cv-social-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 12px 18px;
  margin-top: 10px;
}

.cv-social-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  background: rgba(255,255,255,0.15);
  border: 1px solid rgba(255,255,255,0.35);
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  color: #fff;
  text-decoration: none;
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  position: relative;
}

html[data-theme="light"] .cv-social-icon {
  background: rgba(255,255,255,0.85);
  border: 1px solid rgba(0,0,0,0.08);
  color: #333;
  box-shadow: 0 4px 16px rgba(15,23,42,0.12);
}

.cv-social-icon:hover {
  transform: translateY(-4px) scale(1.06);
  box-shadow: 0 10px 26px rgba(0,0,0,0.35);
  background: rgba(255,255,255,0.25);
}

html[data-theme="light"] .cv-social-icon:hover {
  background: #ffffff;
  box-shadow: 0 8px 24px rgba(15,23,42,0.18);
}

.cv-social-icon svg {
  width: 24px;
  height: 24px;
  stroke: currentColor;
  display: block;
  flex-shrink: 0;
}

/* Platform-specific hover colors (optional subtle enhancements) */
.cv-social-icon.youtube:hover {
  border-color: rgba(255, 0, 0, 0.5);
}

.cv-social-icon.instagram:hover {
  border-color: rgba(225, 48, 108, 0.5);
}

.cv-social-icon.telegram:hover {
  border-color: rgba(0, 136, 204, 0.5);
}

.cv-social-icon.github:hover {
  border-color: rgba(36, 41, 46, 0.5);
}

html[data-theme="light"] .cv-social-icon.github:hover {
  border-color: rgba(36, 41, 46, 0.3);
}

.cv-social-icon.facebook:hover {
  border-color: rgba(24, 119, 242, 0.5);
}

.cv-social-icon.linkedin:hover {
  border-color: rgba(0, 119, 181, 0.5);
}

/* Mobile Responsive */
@media (max-width: 640px) {
  .cv-social-section {
    margin-top: 20px;
    padding: 16px 0;
  }

  .cv-social-title {
    font-size: 1.1rem;
    margin-bottom: 14px;
  }

  .cv-social-bar {
    gap: 10px 14px;
  }

  .cv-social-icon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
  }

  .cv-social-icon svg {
    width: 22px;
    height: 22px;
  }
}

@media (max-width: 1024px) {
  .timeline-vertical::before {
    left: 24px;
  }

  .timeline-item:nth-child(odd),
  .timeline-item:nth-child(even) {
    margin-left: 0;
    margin-right: 0;
    padding-left: 64px;
    padding-right: 0;
    text-align: left;
  }

  .timeline-dot {
    left: 24px;
  }
}

@media (max-width: 640px) {
  .nav-links {
    display: none;
  }
  .section-grid.three-columns {
    grid-template-columns: minmax(0, 1fr);
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .skills-categories {
    grid-template-columns: 1fr;
  }
  .cv-languages {
    grid-template-columns: 1fr;
  }
  .contact-buttons-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .cv-portrait-card {
    width: min(280px, 70vw);
  }
  .cv-portrait-mini {
    width: 88px;
  }
}

/* ============================================================================
   Blog Page - Text-Focused Layout Styles
   ============================================================================ */

/* Text section container */
.blog-text-section {
  padding: 32px;
  border-radius: 20px;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.blog-text-item,
.blog-article-item {
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(99, 102, 241, 0.12);
}

.blog-text-item:last-child,
.blog-article-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.blog-text-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 8px 0;
  line-height: 1.3;
}

.blog-text-meta,
.article-meta {
  font-size: 0.88rem;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
  margin: 0 0 16px 0;
}

.blog-text-content {
  font-size: 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin: 0 0 16px 0;
}

.blog-text-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.blog-article-item h3 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 8px 0;
  line-height: 1.3;
}

.blog-article-item p {
  font-size: 0.98rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 8px 0;
}

/* Collaboration detailed list */
.collab-list-detailed {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
  margin: 32px 0;
}

.collab-detail-item {
  padding: 24px;
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(20, 184, 166, 0.06));
  border: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

.collab-detail-item:hover {
  transform: translateY(-4px);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.12), rgba(20, 184, 166, 0.1));
  border-color: rgba(99, 102, 241, 0.3);
}

.collab-detail-item h4 {
  font-size: 1.08rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0 0 10px 0;
  line-height: 1.3;
}

.collab-detail-item p {
  font-size: 0.94rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.6;
}

/* Minimal social icons */
.social-minimal {
  text-align: center;
}

.social-icons-minimal {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.social-icons-minimal a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.1), rgba(20, 184, 166, 0.08));
  border: 1px solid var(--glass-border);
  color: var(--primary);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
}

.social-icons-minimal a:hover {
  color: var(--secondary);
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.16), rgba(20, 184, 166, 0.12));
  border-color: var(--secondary);
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 16px rgba(99, 102, 241, 0.2);
}

.social-icons-minimal svg {
  width: 20px;
  height: 20px;
  stroke-width: 2;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .blog-text-section {
    padding: 24px 20px;
    gap: 28px;
  }

  .blog-text-title {
    font-size: 1.2rem;
  }

  .collab-list-detailed {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .social-icons-minimal {
    gap: 12px;
  }

  .social-icons-minimal a {
    width: 36px;
    height: 36px;
  }

  .social-icons-minimal svg {
    width: 18px;
    height: 18px;
  }
}

/* ======= TECH & CONTENT SECTION ======= */

.tech-content-section {
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  padding: 48px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.tech-content-title {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.tech-content-description {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text);
  margin-bottom: 32px;
  max-width: 700px;
}

.tech-content-description-en {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--text);
  opacity: 0.85;
  margin-bottom: 40px;
}

/* Thumbnail grid */
.thumbnail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-top: 32px;
}

.thumbnail-item {
  position: relative;
  overflow: hidden;
}

.glass-photo--thumb {
  width: 100%;
  height: 100%;
  border-radius: 24px;
  box-shadow: 0 16px 48px rgba(15,23,42,0.32);
  transition: all 280ms cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-photo--thumb:hover {
  transform: scale(1.03) translateY(-4px);
  box-shadow: 0 24px 64px rgba(99,102,241,0.45);
}

.glass-photo--thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Floating subtle animation */
@keyframes floatSubtle {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-3px);
  }
}

.glass-photo--thumb {
  animation: floatSubtle 4s ease-in-out infinite;
}

.glass-photo--thumb:nth-child(2) {
  animation-delay: 0.2s;
}

.glass-photo--thumb:nth-child(3) {
  animation-delay: 0.4s;
}

.glass-photo--thumb:nth-child(4) {
  animation-delay: 0.1s;
}

.glass-photo--thumb:nth-child(5) {
  animation-delay: 0.3s;
}

.glass-photo--thumb:nth-child(6) {
  animation-delay: 0.5s;
}

/* Responsive thumbnail grid */
@media (max-width: 1024px) {
  .thumbnail-grid {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
  }

  .tech-content-section {
    padding: 40px;
  }
}

@media (max-width: 768px) {
  .thumbnail-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 16px;
  }

  .tech-content-section {
    padding: 32px 24px;
  }

  .tech-content-title {
    font-size: 1.6rem;
  }

  .tech-content-description {
    font-size: 0.95rem;
  }

  .tech-content-description-en {
    font-size: 0.9rem;
  }
}

@media (max-width: 480px) {
  .thumbnail-grid {
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
  }

  .tech-content-section {
    padding: 24px 16px;
  }

  .tech-content-title {
    font-size: 1.4rem;
  }
}

/* ======= ORBIT YOUTUBE HERO ======= */

.orbit-hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  overflow: hidden;
}

/* Orbit container - holds the center and rotating items */
.orbit-container {
  position: relative;
  width: 100%;
  max-width: 700px;
  height: 600px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Center glass card */
.orbit-center {
  position: relative;
  z-index: 10;
  background: linear-gradient(135deg, rgba(99,102,241,0.12), rgba(20,184,166,0.10));
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  padding: 48px 40px;
  max-width: 380px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(15,23,42,0.35);
  transition: all 320ms cubic-bezier(0.4, 0, 0.2, 1);
}

.orbit-center:hover {
  box-shadow: 0 30px 80px rgba(99,102,241,0.35);
  border-color: rgba(99,102,241,0.5);
}

/* Center logo/image */
.orbit-center-image {
  width: 100px;
  height: 100px;
  margin: 0 auto 24px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(99,102,241,0.2), rgba(20,184,166,0.2));
  border: 2px solid var(--glass-border);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(99,102,241,0.25);
}

.orbit-center-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Center title */
.orbit-center-title {
  font-size: 1.5rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

/* Center description */
.orbit-center-desc {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text);
  margin-bottom: 28px;
  opacity: 0.9;
}

/* Center buttons */
.orbit-actions {
  display: flex;
  gap: 12px;
  flex-direction: column;
}

.orbit-btn {
  padding: 12px 24px;
  border-radius: 12px;
  border: none;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 280ms ease;
  text-decoration: none;
  display: inline-block;
  text-align: center;
}

.orbit-btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-strong));
  color: white;
  box-shadow: 0 8px 20px rgba(99,102,241,0.3);
}

.orbit-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(99,102,241,0.45);
}

.orbit-btn-secondary {
  background: rgba(99,102,241,0.12);
  color: var(--primary);
  border: 1px solid var(--primary);
}

.orbit-btn-secondary:hover {
  background: rgba(99,102,241,0.22);
  box-shadow: 0 8px 20px rgba(99,102,241,0.2);
}

/* Orbit ring - the circular path */
.orbit-ring {
  position: absolute;
  width: 450px;
  height: 450px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  border: 1px solid rgba(99,102,241,0.15);
  border-radius: 50%;
  z-index: 5;
}

/* Orbit items - thumbnails rotating around */
.orbit-items {
  position: absolute;
  width: 450px;
  height: 450px;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 8;
}

@keyframes orbitRotate {
  from {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  to {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}

.orbit-items {
  animation: orbitRotate 40s linear infinite;
}

/* Individual orbit item */
.orbit-item {
  position: absolute;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  overflow: hidden;
  z-index: 9;
}

/* Position items around the circle (6 items = 60deg spacing) */
.orbit-item:nth-child(1) {
  transform: translate(-50%, -50%) rotate(0deg) translateY(-225px) rotate(0deg);
}

.orbit-item:nth-child(2) {
  transform: translate(-50%, -50%) rotate(60deg) translateY(-225px) rotate(-60deg);
}

.orbit-item:nth-child(3) {
  transform: translate(-50%, -50%) rotate(120deg) translateY(-225px) rotate(-120deg);
}

.orbit-item:nth-child(4) {
  transform: translate(-50%, -50%) rotate(180deg) translateY(-225px) rotate(-180deg);
}

.orbit-item:nth-child(5) {
  transform: translate(-50%, -50%) rotate(240deg) translateY(-225px) rotate(-240deg);
}

.orbit-item:nth-child(6) {
  transform: translate(-50%, -50%) rotate(300deg) translateY(-225px) rotate(-300deg);
}

/* Orbit item glass frame */
.orbit-frame {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(99,102,241,0.16), rgba(20,184,166,0.14));
  border: 1.5px solid var(--glass-border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(15,23,42,0.32);
  transition: all 240ms cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.orbit-item:hover .orbit-frame {
  transform: scale(1.1);
  box-shadow: 0 16px 48px rgba(99,102,241,0.42);
  border-color: rgba(99,102,241,0.5);
}

/* Orbit item image */
.orbit-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Orbit icon overlay */
.orbit-icon {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  background: rgba(0,0,0,0.5);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 15;
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.2);
  transition: all 240ms ease;
}

.orbit-frame:hover .orbit-icon {
  background: rgba(99,102,241,0.7);
  box-shadow: 0 4px 12px rgba(99,102,241,0.4);
}

.orbit-icon svg {
  width: 18px;
  height: 18px;
  stroke: white;
  fill: none;
  stroke-width: 2;
}

/* Responsive behavior */
@media (max-width: 1200px) {
  .orbit-container {
    height: 500px;
  }

  .orbit-ring {
    width: 380px;
    height: 380px;
  }

  .orbit-items {
    width: 380px;
    height: 380px;
  }

  .orbit-item:nth-child(1) {
    transform: translate(-50%, -50%) rotate(0deg) translateY(-190px) rotate(0deg);
  }

  .orbit-item:nth-child(2) {
    transform: translate(-50%, -50%) rotate(60deg) translateY(-190px) rotate(-60deg);
  }

  .orbit-item:nth-child(3) {
    transform: translate(-50%, -50%) rotate(120deg) translateY(-190px) rotate(-120deg);
  }

  .orbit-item:nth-child(4) {
    transform: translate(-50%, -50%) rotate(180deg) translateY(-190px) rotate(-180deg);
  }

  .orbit-item:nth-child(5) {
    transform: translate(-50%, -50%) rotate(240deg) translateY(-190px) rotate(-240deg);
  }

  .orbit-item:nth-child(6) {
    transform: translate(-50%, -50%) rotate(300deg) translateY(-190px) rotate(-300deg);
  }

  .orbit-center {
    padding: 40px 32px;
  }

  .orbit-center-title {
    font-size: 1.4rem;
  }
}

/* Tablet layout - simplified, tighter spacing */
@media (max-width: 768px) {
  .orbit-hero {
    min-height: 500px;
    padding: 40px 16px;
  }

  .orbit-container {
    height: 420px;
    max-width: 100%;
  }

  .orbit-ring {
    width: 300px;
    height: 300px;
  }

  .orbit-items {
    width: 300px;
    height: 300px;
  }

  .orbit-item {
    width: 80px;
    height: 80px;
  }

  .orbit-item:nth-child(1) {
    transform: translate(-50%, -50%) rotate(0deg) translateY(-150px) rotate(0deg);
  }

  .orbit-item:nth-child(2) {
    transform: translate(-50%, -50%) rotate(60deg) translateY(-150px) rotate(-60deg);
  }

  .orbit-item:nth-child(3) {
    transform: translate(-50%, -50%) rotate(120deg) translateY(-150px) rotate(-120deg);
  }

  .orbit-item:nth-child(4) {
    transform: translate(-50%, -50%) rotate(180deg) translateY(-150px) rotate(-180deg);
  }

  .orbit-item:nth-child(5) {
    transform: translate(-50%, -50%) rotate(240deg) translateY(-150px) rotate(-240deg);
  }

  .orbit-item:nth-child(6) {
    transform: translate(-50%, -50%) rotate(300deg) translateY(-150px) rotate(-300deg);
  }

  .orbit-center {
    padding: 32px 24px;
    max-width: 320px;
  }

  .orbit-center-title {
    font-size: 1.2rem;
  }

  .orbit-center-desc {
    font-size: 0.9rem;
  }

  .orbit-center-image {
    width: 80px;
    height: 80px;
    margin-bottom: 16px;
  }

  .orbit-icon {
    width: 28px;
    height: 28px;
  }

  .orbit-icon svg {
    width: 16px;
    height: 16px;
  }

  .orbit-actions {
    gap: 10px;
  }

  .orbit-btn {
    font-size: 0.9rem;
    padding: 10px 18px;
  }
}

/* Mobile layout - horizontal scroll */
@media (max-width: 480px) {
  .orbit-hero {
    min-height: auto;
    padding: 32px 16px;
  }

  .orbit-container {
    position: static;
    width: 100%;
    height: auto;
    max-width: 100%;
    flex-direction: column;
    gap: 24px;
  }

  /* Hide orbit ring and animation on mobile */
  .orbit-ring {
    display: none;
  }

  /* Convert orbit-items to horizontal scroll layout */
  .orbit-items {
    position: static;
    width: 100%;
    height: auto;
    transform: none !important;
    animation: none !important;
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 8px 0;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
  }

  .orbit-item {
    position: static;
    transform: none !important;
    width: 70px;
    height: 70px;
    border-radius: 12px;
    flex-shrink: 0;
    scroll-snap-align: center;
  }

  .orbit-frame {
    border-radius: 12px;
  }

  .orbit-center {
    width: 100%;
    padding: 24px 16px;
    max-width: 100%;
    order: -1;
  }

  .orbit-center-title {
    font-size: 1.1rem;
  }

  .orbit-center-desc {
    font-size: 0.85rem;
    margin-bottom: 16px;
  }

  .orbit-center-image {
    width: 70px;
    height: 70px;
    margin: 0 auto 12px;
  }

  .orbit-icon {
    width: 24px;
    height: 24px;
    top: 4px;
    right: 4px;
  }

  .orbit-icon svg {
    width: 14px;
    height: 14px;
  }

  .orbit-actions {
    flex-direction: row;
    gap: 8px;
  }

  .orbit-btn {
    flex: 1;
    font-size: 0.85rem;
    padding: 10px 12px;
  }
}

/* RTL/LTR support */
html[dir="rtl"] .orbit-item:hover .orbit-icon {
  left: 8px;
  right: auto;
}

html[dir="rtl"] .orbit-icon {
  right: auto;
  left: 8px;
}

/* Dark/Light mode adjustments */
html[data-theme="light"] .orbit-center {
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
}

html[data-theme="light"] .orbit-frame {
  background: linear-gradient(135deg, rgba(99,102,241,0.1), rgba(20,184,166,0.08));
}

/* ═════════════════════════════════════════════════════════════
   YOUTUBE PAGE ORBIT HERO (CLEAN & SIMPLE)
   ═════════════════════════════════════════════════════════════ */

/* Main hero container */
.youtube-simple-hero {
  padding: 80px 0;
  position: relative;
}

.youtube-simple-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

/* Text card (left/right depending on language) */
.youtube-hero-card {
  background: linear-gradient(135deg, rgba(var(--glass-bg-rgb), 0.6), rgba(var(--glass-bg-rgb), 0.4));
  border: 1.5px solid rgba(var(--glass-border-rgb), 0.2);
  backdrop-filter: blur(20px);
  border-radius: 24px;
  padding: 40px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.12);
}

.youtube-hero-title {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 20px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.youtube-hero-desc {
  font-size: 1.125rem;
  line-height: 1.7;
  color: var(--color-text-secondary);
  margin-bottom: 28px;
}

.youtube-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.youtube-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 12px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 280ms cubic-bezier(0.4, 0, 0.2, 1);
  border: 1.5px solid transparent;
}

.youtube-hero-btn-primary {
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: white;
  box-shadow: 0 4px 12px rgba(99,102,241,0.25);
}

.youtube-hero-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(99,102,241,0.35);
}

.youtube-hero-btn-secondary {
  background: rgba(var(--glass-bg-rgb), 0.5);
  color: var(--color-text);
  border-color: rgba(var(--glass-border-rgb), 0.2);
  backdrop-filter: blur(10px);
}

.youtube-hero-btn-secondary:hover {
  background: rgba(var(--glass-bg-rgb), 0.7);
  border-color: var(--color-primary);
}

/* Orbit container (right/left depending on language) */
.youtube-orbit-wrapper {
  position: relative;
  width: 100%;
  max-width: 500px;
  height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

/* Center element (portrait or logo) */
.youtube-orbit-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(20,184,166,0.12));
  border: 3px solid rgba(var(--glass-border-rgb), 0.3);
  backdrop-filter: blur(20px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.15);
  overflow: hidden;
  z-index: 2;
}

.youtube-orbit-center img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Orbiting items container */
.youtube-orbit-ring {
  position: absolute;
  width: 100%;
  height: 100%;
  animation: simpleOrbitRotate 100s linear infinite;
}

/* Individual orbit items (3-4 thumbnails) */
.youtube-orbit-thumb {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(99,102,241,0.12), rgba(20,184,166,0.1));
  border: 2.5px solid rgba(var(--glass-border-rgb), 0.25);
  backdrop-filter: blur(15px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  transition: all 320ms cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  animation: youtubeThumbFloat 6s ease-in-out infinite;
}

.youtube-orbit-thumb:hover {
  transform: scale(1.03);
  border-color: var(--color-primary);
  box-shadow: 0 6px 28px rgba(99,102,241,0.3);
}

.youtube-orbit-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Play icon overlay */
.youtube-thumb-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 32px;
  height: 32px;
  background: rgba(255,255,255,0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.85;
  transition: all 280ms cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

.youtube-orbit-thumb:hover .youtube-thumb-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

.youtube-thumb-play svg {
  width: 14px;
  height: 14px;
  fill: var(--color-primary);
  margin-left: 2px;
}

/* Positioning for 4 items (quarters) */
.youtube-orbit-thumb:nth-child(1) {
  transform: translate(-50%, -50%) rotate(0deg) translateY(-180px) rotate(0deg);
  animation-delay: 0s;
}

.youtube-orbit-thumb:nth-child(2) {
  transform: translate(-50%, -50%) rotate(90deg) translateY(-180px) rotate(-90deg);
  animation-delay: 1.5s;
}

.youtube-orbit-thumb:nth-child(3) {
  transform: translate(-50%, -50%) rotate(180deg) translateY(-180px) rotate(-180deg);
  animation-delay: 3s;
}

.youtube-orbit-thumb:nth-child(4) {
  transform: translate(-50%, -50%) rotate(270deg) translateY(-180px) rotate(-270deg);
  animation-delay: 4.5s;
}

/* Animations */
@keyframes simpleOrbitRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes youtubeThumbFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* Responsive - Tablet */
@media (max-width: 1024px) {
  .youtube-simple-grid {
    gap: 40px;
  }

  .youtube-hero-card {
    padding: 32px;
  }

  .youtube-hero-title {
    font-size: 1.75rem;
  }

  .youtube-orbit-wrapper {
    max-width: 400px;
    height: 400px;
  }

  .youtube-orbit-center {
    width: 140px;
    height: 140px;
  }

  .youtube-orbit-thumb {
    width: 80px;
    height: 80px;
  }

  .youtube-orbit-thumb:nth-child(1) {
    transform: translate(-50%, -50%) rotate(0deg) translateY(-140px) rotate(0deg);
  }

  .youtube-orbit-thumb:nth-child(2) {
    transform: translate(-50%, -50%) rotate(90deg) translateY(-140px) rotate(-90deg);
  }

  .youtube-orbit-thumb:nth-child(3) {
    transform: translate(-50%, -50%) rotate(180deg) translateY(-140px) rotate(-180deg);
  }

  .youtube-orbit-thumb:nth-child(4) {
    transform: translate(-50%, -50%) rotate(270deg) translateY(-140px) rotate(-270deg);
  }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
  .youtube-simple-hero {
    padding: 60px 0;
  }

  .youtube-simple-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .youtube-hero-card {
    padding: 28px;
  }

  .youtube-hero-title {
    font-size: 1.5rem;
  }

  .youtube-hero-desc {
    font-size: 1rem;
  }

  .youtube-hero-actions {
    flex-direction: column;
  }

  .youtube-hero-btn {
    width: 100%;
    justify-content: center;
  }

  /* Hide orbit animation on mobile, show simple row */
  .youtube-orbit-wrapper {
    max-width: 100%;
    height: auto;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    padding: 20px 0;
  }

  .youtube-orbit-center {
    position: static;
    transform: none;
    width: 120px;
    height: 120px;
    margin: 0 auto 20px;
  }

  .youtube-orbit-ring {
    position: static;
    display: flex;
    gap: 12px;
    animation: none;
    width: auto;
    height: auto;
    padding: 0 20px;
  }

  .youtube-orbit-thumb {
    position: static;
    transform: none !important;
    animation: none;
    flex-shrink: 0;
    width: 90px;
    height: 90px;
  }
}

/* RTL Support */
html[dir="rtl"] .youtube-hero-card {
  text-align: right;
}

html[dir="rtl"] .youtube-thumb-play svg {
  margin-left: 0;
  margin-right: 2px;
}

/* Light Mode */
html[data-theme="light"] .youtube-hero-card {
  background: linear-gradient(135deg, rgba(255,255,255,0.8), rgba(255,255,255,0.6));
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
}

html[data-theme="light"] .youtube-orbit-center {
  background: linear-gradient(135deg, rgba(99,102,241,0.1), rgba(20,184,166,0.08));
  box-shadow: 0 8px 32px rgba(0,0,0,0.1);
}

html[data-theme="light"] .youtube-orbit-thumb {
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
}

html[data-theme="light"] .youtube-thumb-play {
  background: rgba(255,255,255,0.98);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ═══════════════════════════════════════════════════════════════
   CINEMATIC HOME HERO - Premium Tech Creator Experience
   ═══════════════════════════════════════════════════════════════ */

/* Hero Container */
.cinematic-hero {
  padding: 100px 0 120px;
  position: relative;
  overflow: hidden;
}

/* Hero Layout - Two Column */
.cinematic-hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 100px;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
}

/* Left Side - Text Content */
.cinematic-hero-content {
  display: flex;
  flex-direction: column;
  gap: 24px;
  z-index: 2;
  position: relative;
}

.cinematic-hero-eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  opacity: 0.9;
  animation: fadeSlideIn 0.8s ease-out;
}

.cinematic-hero-title {
  font-size: 2.75rem;
  font-weight: 800;
  line-height: 1.15;
  color: var(--color-text);
  margin: 0;
  animation: fadeSlideIn 0.8s ease-out 0.1s backwards;
}

.cinematic-hero-title .gradient-text {
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.cinematic-hero-paragraph {
  font-size: 1.25rem;
  line-height: 2;
  color: var(--color-text-secondary);
  margin: 0;
  animation: fadeSlideIn 0.9s ease-out 0.2s backwards;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.cinematic-hero-paragraph-secondary {
  font-size: 1.08rem;
  line-height: 1.95;
  color: var(--color-text-secondary);
  margin: 0;
  opacity: 0.85;
  animation: fadeSlideIn 0.9s ease-out 0.35s backwards;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

/* Rotating Tagline Component */
.cinematic-hero-tagline {
  position: relative;
  min-height: 36px;
  margin-top: 16px;
  animation: fadeSlideIn 0.8s ease-out 0.4s backwards;
}

.tagline-text {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  font-size: 1.15rem;
  font-weight: 600;
  font-style: italic;
  letter-spacing: 0.02em;
  color: var(--color-primary);
  opacity: 0;
  animation: taglineFade 21s infinite;
  text-align: start;
}

html[dir="rtl"] .tagline-text {
  text-align: start;
}

.tagline-text:nth-child(1) { animation-delay: 0s; }
.tagline-text:nth-child(2) { animation-delay: 3.5s; }
.tagline-text:nth-child(3) { animation-delay: 7s; }
.tagline-text:nth-child(4) { animation-delay: 10.5s; }
.tagline-text:nth-child(5) { animation-delay: 14s; }
.tagline-text:nth-child(6) { animation-delay: 17.5s; }

@keyframes taglineFade {
  0%, 100% { opacity: 0; transform: translateY(8px); }
  5%, 14% { opacity: 1; transform: translateY(0); }
  19% { opacity: 0; transform: translateY(-8px); }
}

/* CTA Buttons */
.cinematic-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 32px;
  animation: fadeSlideIn 0.8s ease-out 0.5s backwards;
}

.cinematic-hero-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  border-radius: 14px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 300ms cubic-bezier(0.4, 0, 0.2, 1);
  border: 1.5px solid transparent;
  position: relative;
  overflow: hidden;
}

.cinematic-hero-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.2), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.cinematic-hero-btn:hover::before {
  opacity: 1;
}

/* Primary Button - YouTube CTA with Light/Dark Visibility */
.cinematic-hero-btn-primary {
  background: rgba(255, 255, 255, 0.9);
  color: #111827;
  border-color: rgba(255, 255, 255, 0.95);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

html[data-theme="light"] .cinematic-hero-btn-primary {
  background: rgba(255, 255, 255, 0.35);
  color: #111827;
  border-color: rgba(0, 0, 0, 0.1);
  box-shadow: 0 4px 16px rgba(99, 102, 241, 0.2);
}

.cinematic-hero-btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(99, 102, 241, 0.5),
              0 0 20px rgba(99, 102, 241, 0.3);
  background: rgba(255, 255, 255, 1);
}

html[data-theme="light"] .cinematic-hero-btn-primary:hover {
  background: rgba(255, 255, 255, 0.55);
  box-shadow: 0 8px 28px rgba(99, 102, 241, 0.35),
              0 0 20px rgba(99, 102, 241, 0.25);
  border-color: rgba(99, 102, 241, 0.3);
}

/* Secondary Button */
.cinematic-hero-btn-secondary {
  background: rgba(99, 102, 241, 0.15);
  color: var(--color-text);
  border-color: rgba(99, 102, 241, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.cinematic-hero-btn-secondary:hover {
  background: rgba(99, 102, 241, 0.25);
  border-color: var(--color-primary);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(99, 102, 241, 0.3);
}

/* Right Side - Portrait + Floating Icons */
.cinematic-hero-visual {
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  min-height: 500px;
}

@keyframes portraitFloat {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-12px); }
}

/* ═══════════════════════════════════════════════════════════════
   STABLE ORBIT SYSTEM (NO JS, ALWAYS VISIBLE)
   ═══════════════════════════════════════════════════════════════ */

/* ========================================
   HERO PORTRAIT + HORIZONTAL ICON ROW
   ======================================== */

.hero-portrait-container {
  position: relative;
  width: max-content;
  margin: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 18px;
}

/* Portrait Frame - Keep Original Glow & Style */
.hero-portrait-frame {
  position: relative;
  z-index: 2;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(99,102,241,0.25), rgba(20,184,166,0.2));
  border: 3px solid rgba(99, 102, 241, 0.4);
  box-shadow: 0 20px 60px rgba(99, 102, 241, 0.35),
              0 0 40px rgba(20, 184, 166, 0.2),
              inset 0 0 0 1px rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  animation: portraitFloat 6s ease-in-out infinite;
}

.hero-portrait-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.2) 0%, transparent 60%);
  mix-blend-mode: overlay;
  opacity: 0.5;
  pointer-events: none;
}

.hero-portrait-frame img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  position: relative;
  z-index: 1;
}

/* Horizontal Icon Row Under Portrait */
.hero-icon-row {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px 16px;
  max-width: 420px;
  margin-left: auto;
  margin-right: auto;
}

/* Glass Skill Pills with Icon + Label (Horizontal Compact Layout) */
.hero-skill-pill {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 16px;
  border: 1px solid rgba(255,255,255,0.35);
  background: rgba(255,255,255,0.16);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  color: #ffffff;
  font-size: 0.9rem;
  font-weight: 500;
  line-height: 1.3;
  cursor: default;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

html[data-theme="light"] .hero-skill-pill {
  background: rgba(255,255,255,0.9);
  border: 1px solid rgba(0,0,0,0.08);
  color: #111827;
  box-shadow: 0 4px 14px rgba(15,23,42,0.12);
}

.hero-skill-pill .pill-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.hero-skill-pill .pill-icon svg {
  width: 20px;
  height: 20px;
  stroke-width: 2.2;
  stroke: currentColor;
  display: block;
}

.hero-skill-pill .pill-label {
  font-size: 0.9rem;
  line-height: 1.3;
  white-space: normal;
}

/* Hover Effect */
.hero-skill-pill:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(0,0,0,0.32);
  background: rgba(255,255,255,0.22);
}

html[data-theme="light"] .hero-skill-pill:hover {
  background: #ffffff;
  box-shadow: 0 8px 22px rgba(15,23,42,0.18);
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .hero-portrait-frame {
    width: 220px;
    height: 220px;
  }

  .hero-icon-row {
    gap: 10px 14px;
    max-width: 360px;
  }

  .hero-skill-pill {
    padding: 9px 12px;
    font-size: 0.85rem;
  }

  .hero-skill-pill .pill-icon svg {
    width: 18px;
    height: 18px;
  }

  .hero-skill-pill .pill-label {
    font-size: 0.85rem;
  }
}

@media (max-width: 640px) {
  .hero-icon-row {
    grid-template-columns: 1fr;
    max-width: 320px;
  }
}

@media (max-width: 480px) {
  .hero-portrait-frame {
    width: 180px;
    height: 180px;
  }

  .hero-icon-row {
    gap: 8px 12px;
    max-width: 280px;
  }

  .hero-skill-pill {
    padding: 8px 10px;
    font-size: 0.8rem;
  }

  .hero-skill-pill .pill-icon svg {
    width: 16px;
    height: 16px;
  }

  .hero-skill-pill .pill-label {
    font-size: 0.8rem;
  }
}

/* ═══════════════════════════════════════════════════════════════
   END CINEMATIC HOME HERO
   ═══════════════════════════════════════════════════════════════ */

/* Tech Shots Section */
.tech-shots-section {
  padding: 60px 0;
  position: relative;
}

.tech-shots-header {
  text-align: center;
  margin-bottom: 40px;
}

.tech-shots-title {
  font-size: 1.75rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 12px;
}

.tech-shots-subtitle {
  font-size: 1rem;
  color: var(--color-text-secondary);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

.tech-shots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  max-width: 1000px;
  margin: 0 auto;
}

.tech-shot-item {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
  border: 1.5px solid rgba(var(--glass-border-rgb), 0.2);
  backdrop-filter: blur(12px);
  transition: all 320ms cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.tech-shot-item:hover {
  transform: scale(1.05);
  border-color: var(--color-primary);
  box-shadow: 0 8px 24px rgba(99,102,241,0.25);
}

.tech-shot-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.tech-shot-play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  background: rgba(255,255,255,0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.9;
  transition: all 280ms cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
}

.tech-shot-item:hover .tech-shot-play-icon {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

.tech-shot-play-icon svg {
  width: 20px;
  height: 20px;
  fill: var(--color-primary);
  margin-left: 3px;
}

/* Responsive - Tablet */
@media (max-width: 1024px) {
  .home-hero-grid {
    gap: 40px;
  }

  .home-hero-title {
    font-size: 2rem;
  }

  .home-hero-photo {
    max-width: 380px;
  }

  .tech-shots-grid {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
  }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
  .home-hero {
    padding: 60px 0;
  }

  .home-hero-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .home-hero-photo-container {
    order: -1;
  }

  .home-hero-photo {
    max-width: 320px;
  }

  .home-hero-title {
    font-size: 1.75rem;
  }

  .home-hero-paragraph {
    font-size: 1rem;
  }

  .home-hero-actions {
    flex-direction: column;
  }

  .home-hero-btn {
    width: 100%;
    justify-content: center;
  }

  .tech-shots-section {
    padding: 40px 0;
  }

  .tech-shots-title {
    font-size: 1.5rem;
  }

  .tech-shots-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}

/* RTL Support */
html[dir="rtl"] .home-hero-content {
  text-align: right;
}

html[dir="rtl"] .tech-shots-header {
  text-align: center;
}

html[dir="rtl"] .tech-shot-play-icon svg {
  margin-left: 0;
  margin-right: 3px;
}

/* Light Mode */
html[data-theme="light"] .home-hero-photo {
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
}

html[data-theme="light"] .tech-shot-item {
  background: linear-gradient(135deg, rgba(99,102,241,0.05), rgba(20,184,166,0.04));
}

html[data-theme="light"] .tech-shot-play-icon {
  background: rgba(255,255,255,0.98);
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

/* ═════════════════════════════════════════════════════════════
   CV MODERN TIMELINE
   ═════════════════════════════════════════════════════════════ */

/* Timeline Container */
.cv-timeline {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding: 40px 0;
}

/* Vertical Line */
.cv-timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: linear-gradient(180deg, 
    rgba(99,102,241,0.2) 0%, 
    rgba(99,102,241,0.6) 50%, 
    rgba(99,102,241,0.2) 100%
  );
  transform: translateX(-50%);
  animation: timelineGrow 1.5s ease-out;
}

@keyframes timelineGrow {
  from {
    height: 0;
    opacity: 0;
  }
  to {
    height: 100%;
    opacity: 1;
  }
}

/* Timeline Item */
.cv-timeline-item {
  position: relative;
  margin-bottom: 48px;
  opacity: 0;
  animation: timelineFadeIn 0.6s ease-out forwards;
}

.cv-timeline-item:nth-child(1) { animation-delay: 0.2s; }
.cv-timeline-item:nth-child(2) { animation-delay: 0.4s; }
.cv-timeline-item:nth-child(3) { animation-delay: 0.6s; }
.cv-timeline-item:nth-child(4) { animation-delay: 0.8s; }
.cv-timeline-item:nth-child(5) { animation-delay: 1s; }
.cv-timeline-item:nth-child(6) { animation-delay: 1.2s; }

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

/* Timeline Node (Dot) */
.cv-timeline-node {
  position: absolute;
  left: 50%;
  top: 24px;
  width: 16px;
  height: 16px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  border: 3px solid var(--color-bg);
  border-radius: 50%;
  transform: translateX(-50%);
  z-index: 10;
  box-shadow: 0 0 0 4px rgba(99,102,241,0.2);
  transition: all 320ms cubic-bezier(0.4, 0, 0.2, 1);
}

.cv-timeline-item:hover .cv-timeline-node {
  transform: translateX(-50%) scale(1.3);
  box-shadow: 0 0 0 8px rgba(99,102,241,0.3);
}

/* Timeline Card */
.cv-timeline-card {
  width: calc(50% - 40px);
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
  border: 1px solid rgba(var(--glass-border-rgb), 0.2);
  border-radius: 16px;
  padding: 24px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: 0 8px 32px rgba(15,23,42,0.15);
  transition: all 320ms cubic-bezier(0.4, 0, 0.2, 1);
}

.cv-timeline-card:hover {
  border-color: rgba(99,102,241,0.4);
  box-shadow: 0 12px 40px rgba(99,102,241,0.25);
  transform: translateY(-2px);
}

/* Alternate Left/Right */
.cv-timeline-item:nth-child(odd) .cv-timeline-card {
  margin-left: auto;
  margin-right: 40px;
}

.cv-timeline-item:nth-child(even) .cv-timeline-card {
  margin-left: 40px;
  margin-right: auto;
}

/* Timeline Icon */
.cv-timeline-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, rgba(99,102,241,0.15), rgba(20,184,166,0.12));
  border-radius: 10px;
  font-size: 1.25rem;
  margin-bottom: 12px;
  transition: all 280ms ease;
}

.cv-timeline-item:hover .cv-timeline-icon {
  transform: scale(1.1) rotate(5deg);
}

/* Timeline Year Badge */
.cv-timeline-year {
  display: inline-block;
  padding: 6px 14px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  color: white;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(99,102,241,0.3);
}

/* Timeline Title */
.cv-timeline-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--color-text);
  margin-bottom: 8px;
  line-height: 1.4;
}

/* Timeline Description */
.cv-timeline-card-desc {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--color-text-secondary);
  margin-bottom: 0;
}

.cv-timeline-card-desc ul {
  list-style: none;
  padding: 0;
  margin: 8px 0 0 0;
}

.cv-timeline-card-desc li {
  position: relative;
  padding-left: 24px;
  margin-bottom: 6px;
}

.cv-timeline-card-desc li::before {
  content: '▸';
  position: absolute;
  left: 0;
  color: var(--color-primary);
  font-weight: 700;
}

/* Skills Section - Modern Chips */
.cv-skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 32px;
}

.cv-skill-category {
  background: linear-gradient(135deg, rgba(99,102,241,0.08), rgba(20,184,166,0.06));
  border: 1px solid rgba(var(--glass-border-rgb), 0.2);
  border-radius: 16px;
  padding: 28px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition: all 320ms ease;
}

.cv-skill-category:hover {
  border-color: rgba(99,102,241,0.4);
  box-shadow: 0 12px 32px rgba(99,102,241,0.2);
  transform: translateY(-4px);
}

.cv-skill-category-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.cv-skill-category-icon {
  font-size: 1.75rem;
  animation: skillIconFloat 3s ease-in-out infinite;
}

@keyframes skillIconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}

.cv-skill-category-title {
  font-size: 1.25rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin: 0;
}

.cv-skill-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.cv-skill-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: rgba(99,102,241,0.12);
  border: 1px solid rgba(99,102,241,0.25);
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--color-text);
  transition: all 240ms ease;
  cursor: default;
}

.cv-skill-chip:hover {
  background: rgba(99,102,241,0.2);
  border-color: rgba(99,102,241,0.4);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(99,102,241,0.25);
}

.cv-skill-chip svg {
  width: 14px;
  height: 14px;
  fill: var(--color-primary);
}

/* Responsive - Tablet */
@media (max-width: 1024px) {
  .cv-timeline::before {
    left: 32px;
  }

  .cv-timeline-node {
    left: 32px;
  }

  .cv-timeline-card {
    width: calc(100% - 80px);
    margin-left: 80px !important;
    margin-right: 0 !important;
  }

  .cv-skills-grid {
    grid-template-columns: 1fr;
  }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
  .cv-timeline {
    padding: 20px 0;
  }

  .cv-timeline::before {
    left: 20px;
  }

  .cv-timeline-node {
    left: 20px;
    width: 12px;
    height: 12px;
  }

  .cv-timeline-card {
    width: calc(100% - 60px);
    margin-left: 60px !important;
    padding: 20px;
  }

  .cv-timeline-icon {
    width: 32px;
    height: 32px;
    font-size: 1rem;
  }

  .cv-timeline-card-title {
    font-size: 1rem;
  }

  .cv-timeline-card-desc {
    font-size: 0.9rem;
  }

  .cv-skill-category {
    padding: 20px;
  }
}

/* RTL Support */
html[dir="rtl"] .cv-timeline-card-desc li {
  padding-left: 0;
  padding-right: 24px;
}

html[dir="rtl"] .cv-timeline-card-desc li::before {
  left: auto;
  right: 0;
}

html[dir="rtl"] .cv-timeline-item:nth-child(odd) .cv-timeline-card {
  margin-left: 40px;
  margin-right: auto;
}

html[dir="rtl"] .cv-timeline-item:nth-child(even) .cv-timeline-card {
  margin-left: auto;
  margin-right: 40px;
}

@media (max-width: 1024px) {
  html[dir="rtl"] .cv-timeline-card {
    margin-left: 0 !important;
    margin-right: 80px !important;
  }
}

@media (max-width: 768px) {
  html[dir="rtl"] .cv-timeline-card {
    margin-left: 0 !important;
    margin-right: 60px !important;
  }
}

/* Light Mode */
html[data-theme="light"] .cv-timeline-card {
  background: linear-gradient(135deg, rgba(99,102,241,0.05), rgba(20,184,166,0.04));
  box-shadow: 0 8px 32px rgba(0,0,0,0.08);
}

html[data-theme="light"] .cv-skill-category {
  background: linear-gradient(135deg, rgba(99,102,241,0.05), rgba(20,184,166,0.04));
  box-shadow: 0 4px 16px rgba(0,0,0,0.06);
}

html[data-theme="light"] .cv-skill-chip {
  background: rgba(99,102,241,0.08);
  border-color: rgba(99,102,241,0.2);
}

/* ========================================
   LANGUAGE SELECTOR - Mobile Responsive
   ======================================== */

@media (max-width: 768px) {
  .language-toggle-glass {
    width: 44px;
    height: 44px;
  }

  .language-toggle-glass .flag-icon {
    width: 20px;
    height: 20px;
  }

  .language-dropdown {
    min-width: 140px;
    padding: 6px;
  }

  .language-option {
    padding: 8px 12px;
    font-size: 0.85rem;
  }

  .flag-icon-small {
    width: 18px;
    height: 18px;
  }
}

