/* ============================================================
   Eslam Adel Mahmoud - Portfolio Styles
   Luxury Gold/Bronze theme · Dark + Light · RTL + LTR
   ============================================================ */

/* ============================================================
   PREMIUM V2 - Apple/Tesla style sophisticated palette
   Pure premium black + warm matte gold
   ============================================================ */
:root {
  /* Premium Warm Gold (refined matte, no shiny yellow) */
  --gold-50:  #F5EDD9;
  --gold-100: #E8D7AB;
  --gold-200: #D9BD7E;
  --gold-300: #C4A06A;   /* primary on light */
  --gold-400: #BD9E66;   /* primary brand */
  --gold-500: #A8854A;
  --gold-600: #8A6A36;

  /* Deep Charcoal/Black (warmer than pure black - premium feel) */
  --charcoal-50:  #18181B;
  --charcoal-100: #1C1C1F;   /* card bg */
  --charcoal-200: #232328;   /* card hover */
  --charcoal-300: #2C2C32;   /* elevated */
  --charcoal-400: #3A3A42;
  --charcoal-500: #4F4F58;

  --black-100:    #0E0E11;   /* secondary surface */
  --black-50:     #08080A;   /* main bg dark */
  --pure-black:   #000000;

  /* Warm Whites + Text */
  --white-pure:    #FFFFFF;
  --white-warm:    #FAFAF8;   /* light bg */
  --white-cream:   #F5F2EB;   /* warmer light surface */
  --ivory:         #F0EDE5;
  --text-light:    #F2EFE9;   /* primary text dark mode */
  --text-light-2:  #C8C5BC;   /* muted text dark mode */
  --text-light-3:  #8B8880;   /* dim text dark mode */

  /* Premium grays - warm not cool */
  --gray-warm-100: #E8E5DD;
  --gray-warm-200: #B8B5AD;
  --gray-warm-300: #7E7B73;
  --gray-warm-400: #5A574F;
  --gray-warm-500: #36332D;

  /* Effects - subtle and sophisticated */
  --gold-gradient: linear-gradient(135deg, #C4A06A 0%, #BD9E66 50%, #A8854A 100%);
  --gold-gradient-soft: linear-gradient(135deg, rgba(189,158,102,0.10) 0%, rgba(168,133,74,0.10) 100%);
  --shadow-gold: 0 8px 32px rgba(189,158,102,0.20);
  --shadow-gold-hover: 0 14px 40px rgba(189,158,102,0.30);
  --shadow-soft: 0 4px 16px rgba(0,0,0,0.20);
  --shadow-elevated: 0 20px 60px -15px rgba(0,0,0,0.6), 0 0 0 1px rgba(189,158,102,0.05);
  --shadow-card-light: 0 4px 24px rgba(0,0,0,0.06), 0 1px 4px rgba(0,0,0,0.04);
  --shadow-card-light-hover: 0 16px 40px rgba(168,133,74,0.10), 0 4px 12px rgba(0,0,0,0.06);

  /* Typography */
  --font-ar: 'Tajawal', 'Cairo', 'Segoe UI', sans-serif;
  --font-en: 'Inter', 'Segoe UI', sans-serif;
  --font-display: 'Playfair Display', 'Tajawal', serif;

  /* Sizes */
  --container: 1240px;
  --container-narrow: 960px;
  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 22px;
  --radius-xl: 32px;
  --header-h: 72px;
}

/* ---------- DARK MODE (Premium Black) ---------- */
[data-theme="dark"] {
  --bg:               var(--black-50);
  --bg-2:             var(--black-100);
  --bg-3:             var(--charcoal-100);
  --bg-card:          var(--charcoal-100);
  --bg-card-hover:    var(--charcoal-200);
  --bg-elevated:      var(--charcoal-300);

  --text:             var(--text-light);
  --text-muted:       var(--text-light-2);
  --text-dim:         var(--text-light-3);

  --border:           rgba(189,158,102,0.12);
  --border-strong:    rgba(189,158,102,0.30);

  --accent:           var(--gold-400);
  --accent-hover:     var(--gold-300);
  --accent-soft:      rgba(189,158,102,0.08);

  --shadow:           var(--shadow-elevated);
  --navbar-bg:        rgba(8,8,10,0.85);
  --card-glow:        rgba(189,158,102,0.04);

  color-scheme: dark;
}

/* ---------- LIGHT MODE (Warm Cream Premium) ---------- */
[data-theme="light"] {
  --bg:               var(--white-warm);
  --bg-2:             var(--white-pure);
  --bg-3:             var(--white-cream);
  --bg-card:          var(--white-pure);
  --bg-card-hover:    var(--white-cream);
  --bg-elevated:      var(--white-pure);

  --text:             var(--charcoal-50);
  --text-muted:       var(--gray-warm-400);
  --text-dim:         var(--gray-warm-300);

  --border:           rgba(168,133,74,0.15);
  --border-strong:    rgba(168,133,74,0.32);

  --accent:           var(--gold-500);
  --accent-hover:     var(--gold-600);
  --accent-soft:      rgba(168,133,74,0.07);

  --shadow:           var(--shadow-card-light);
  --navbar-bg:        rgba(250,250,248,0.92);
  --card-glow:        rgba(168,133,74,0.03);

  color-scheme: light;
}

/* Smooth transition between themes */
body, .navbar, .btn, .stat-card, .expertise-card, .client-card, .timeline-card,
.cert-card, .contact-card, .contact-form, .blog-card, .tool-card, .service-card,
.package-card, .modal-content, .chatbot-window, .form-group input, .form-group textarea {
  transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

/* ---------- RESET / BASE ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

body {
  font-family: var(--font-ar);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  overflow-x: hidden;
  transition: background 0.4s ease, color 0.4s ease;
}

html[lang="en"] body { font-family: var(--font-en); }

a { color: inherit; text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--accent); }
img { max-width: 100%; height: auto; display: block; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; }

.container { max-width: var(--container); margin: 0 auto; padding: 0 24px; position: relative; z-index: 2; }

/* ---------- LOADER ---------- */
.loader {
  position: fixed; inset: 0;
  background: var(--bg);
  z-index: 9999;
  display: grid; place-items: center;
  transition: opacity 0.5s, visibility 0.5s;
}
.loader.hidden { opacity: 0; visibility: hidden; }
.loader-content { text-align: center; }
.loader-circle {
  width: 80px; height: 80px;
  border: 3px solid var(--border);
  border-top-color: var(--accent);
  border-radius: 50%;
  margin: 0 auto 16px;
  animation: spin 0.8s linear infinite;
}
.loader-text {
  font-family: var(--font-display);
  font-size: 32px; font-weight: 900;
  background: var(--gold-gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- BACKGROUND DECORATION ---------- */
.bg-decoration {
  position: fixed; inset: 0;
  pointer-events: none; z-index: 0;
  overflow: hidden;
}
.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  opacity: 0.15;
  animation: float 20s ease-in-out infinite;
}
.bg-orb-1 {
  width: 500px; height: 500px;
  background: var(--gold-400);
  top: -150px; left: -150px;
}
.bg-orb-2 {
  width: 400px; height: 400px;
  background: var(--bronze);
  bottom: -100px; right: -100px;
  animation-delay: -7s;
}
.bg-orb-3 {
  width: 350px; height: 350px;
  background: var(--gold-500);
  top: 40%; left: 60%;
  animation-delay: -14s;
}
@keyframes float {
  0%, 100% { transform: translate(0,0) scale(1); }
  33% { transform: translate(50px,-30px) scale(1.1); }
  66% { transform: translate(-30px,40px) scale(0.95); }
}

/* ---------- NAVBAR ---------- */
.navbar {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--header-h);
  background: var(--navbar-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  z-index: 100;
  transition: all 0.3s;
}
.navbar.scrolled { box-shadow: var(--shadow); }
.nav-container {
  display: flex; align-items: center; justify-content: space-between;
  height: 100%;
}

.logo { display: flex; align-items: center; gap: 12px; }
.logo-mark {
  display: inline-grid; place-items: center;
  width: 44px; height: 44px;
  background: var(--gold-gradient);
  color: #000;
  font-weight: 900; font-size: 18px;
  border-radius: 12px;
  box-shadow: var(--shadow-gold);
  font-family: var(--font-display);
}
.logo-text {
  font-weight: 700; font-size: 18px;
  background: var(--gold-gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}

.nav-menu {
  display: flex; gap: 8px;
}
.nav-menu a {
  padding: 8px 16px;
  border-radius: 10px;
  font-weight: 500; font-size: 15px;
  position: relative;
  transition: all 0.2s;
}
.nav-menu a:hover { background: var(--bg-card-hover); color: var(--accent); }
.nav-menu a.active { color: var(--accent); }
.nav-menu a.active::after {
  content: ''; position: absolute;
  left: 50%; bottom: 0;
  transform: translateX(-50%);
  width: 20px; height: 2px;
  background: var(--gold-gradient);
  border-radius: 2px;
}

.nav-actions { display: flex; align-items: center; gap: 8px; }
.icon-btn {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 14px; font-weight: 600;
  transition: all 0.2s;
}
.icon-btn:hover {
  border-color: var(--accent);
  background: var(--bg-card-hover);
  color: var(--accent);
  transform: translateY(-2px);
}
#langToggle { width: auto; padding: 0 16px; }

.mobile-only { display: none; }

/* ---------- BUTTONS ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 600; font-size: 15px;
  cursor: pointer;
  transition: all 0.3s;
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn-primary {
  background: var(--gold-gradient);
  color: #000;
  box-shadow: var(--shadow-gold);
}
.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-gold-hover);
  color: #000;
}
.btn-outline {
  background: transparent;
  border-color: var(--accent);
  color: var(--accent);
}
.btn-outline:hover {
  background: var(--accent);
  color: var(--bg);
  transform: translateY(-3px);
}
.btn-block { width: 100%; justify-content: center; }

/* ---------- HERO ---------- */
.hero {
  min-height: 100vh;
  padding-top: calc(var(--header-h) + 40px);
  padding-bottom: 80px;
  display: flex; align-items: center;
  position: relative;
}
.hero-container {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 60px;
  align-items: center;
}
.hero-greeting {
  font-size: 18px; font-weight: 500;
  color: var(--accent);
  margin-bottom: 16px;
  letter-spacing: 1px;
}
.hero-name {
  font-family: var(--font-display);
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 20px;
  background: linear-gradient(135deg, var(--text) 0%, var(--accent) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
html[lang="ar"] .hero-name {
  font-family: var(--font-ar);
}
.hero-title {
  font-size: clamp(16px, 2vw, 20px);
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 20px;
  line-height: 1.5;
}
.hero-tagline {
  font-size: 16px;
  color: var(--text-muted);
  margin-bottom: 36px;
  max-width: 560px;
  line-height: 1.7;
}
.hero-actions {
  display: flex; gap: 16px;
  margin-bottom: 36px;
  flex-wrap: wrap;
}
.hero-social {
  display: flex; gap: 16px;
}
.hero-social a {
  width: 44px; height: 44px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--bg-card);
  border: 1px solid var(--border);
  font-size: 18px;
  transition: all 0.3s;
}
.hero-social a:hover {
  background: var(--gold-gradient);
  color: #000;
  transform: translateY(-4px) rotate(-5deg);
  box-shadow: var(--shadow-gold);
}

/* Hero image */
.hero-image { display: flex; justify-content: center; }
.hero-image-wrapper {
  position: relative;
  width: 380px; height: 380px;
  max-width: 100%;
}
.hero-image-glow {
  position: absolute; inset: -20px;
  background: var(--gold-gradient);
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.5;
  animation: pulse 4s ease-in-out infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 0.4; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(1.05); }
}
.hero-image-frame {
  position: relative;
  width: 100%; height: 100%;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid transparent;
  background:
    linear-gradient(var(--bg), var(--bg)) padding-box,
    var(--gold-gradient) border-box;
  box-shadow: var(--shadow-gold);
  display: grid; place-items: center;
}
.hero-image-frame img {
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-image-frame.placeholder {
  background: var(--gold-gradient);
}
.placeholder-text {
  font-family: var(--font-display);
  font-size: 120px; font-weight: 900;
  color: #000;
}
.hero-badge {
  position: absolute;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  padding: 12px 18px;
  display: flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 14px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
  animation: floatBadge 3s ease-in-out infinite;
}
.hero-badge i { color: var(--accent); font-size: 18px; }
.hero-badge small { color: var(--text-muted); font-weight: 500; font-size: 12px; }
.hero-badge-1 {
  top: 20%;
  inset-inline-start: -30px;
}
.hero-badge-2 {
  bottom: 20%;
  inset-inline-end: -30px;
  animation-delay: -1.5s;
}
@keyframes floatBadge {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.hero-scroll {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
  color: var(--text-muted);
  font-size: 13px;
  animation: bounce 2s infinite;
}
.hero-scroll i { font-size: 16px; }
@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(-10px); }
}

/* ---------- SECTIONS ---------- */
.section {
  padding: 100px 0;
  position: relative;
}
.section-alt { background: var(--bg-2); }

.section-header {
  text-align: center;
  margin-bottom: 64px;
}
.section-tag {
  display: inline-block;
  padding: 6px 16px;
  background: var(--gold-gradient-soft);
  border: 1px solid var(--border-strong);
  border-radius: 100px;
  color: var(--accent);
  font-size: 13px; font-weight: 600;
  margin-bottom: 16px;
  letter-spacing: 0.5px;
}
.section-title {
  font-family: var(--font-display);
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 900;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--text) 0%, var(--accent) 100%);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
html[lang="ar"] .section-title { font-family: var(--font-ar); }
.section-divider {
  width: 80px; height: 4px;
  margin: 0 auto;
  background: var(--gold-gradient);
  border-radius: 2px;
}

/* ---------- ABOUT ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 60px;
  align-items: start;
}
.about-intro {
  font-size: 17px;
  margin-bottom: 20px;
  line-height: 1.9;
  color: var(--text);
}
.about-extra {
  font-size: 16px;
  color: var(--text-muted);
  margin-bottom: 32px;
  line-height: 1.8;
}
.about-languages h4 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--accent);
  margin-bottom: 16px;
}
.languages-list {
  display: flex; flex-direction: column; gap: 16px;
}
.lang-item {
  display: flex; flex-direction: column; gap: 6px;
}
.lang-item-head {
  display: flex; justify-content: space-between;
  font-size: 14px; font-weight: 600;
}
.lang-bar {
  height: 6px;
  background: var(--bg-3);
  border-radius: 100px;
  overflow: hidden;
}
.lang-bar-fill {
  height: 100%;
  background: var(--gold-gradient);
  border-radius: 100px;
  transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.stat-card {
  padding: 32px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.4s;
}
.stat-card::before {
  content: ''; position: absolute;
  top: 0; left: 0; right: 0; height: 3px;
  background: var(--gold-gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s;
}
.stat-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-gold);
}
.stat-card:hover::before { transform: scaleX(1); }
.stat-number {
  font-family: var(--font-display);
  font-size: 48px; font-weight: 900;
  background: var(--gold-gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 8px;
}
.stat-label {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 500;
}

/* ---------- EXPERTISE ---------- */
.expertise-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 24px;
}
.expertise-card {
  padding: 36px 28px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.4s;
}
.expertise-card::before {
  content: ''; position: absolute; inset: 0;
  background: var(--gold-gradient-soft);
  opacity: 0;
  transition: opacity 0.4s;
}
.expertise-card:hover {
  transform: translateY(-8px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-gold);
}
.expertise-card:hover::before { opacity: 1; }
.expertise-card > * { position: relative; z-index: 1; }
.expertise-icon {
  width: 72px; height: 72px;
  background: var(--gold-gradient);
  border-radius: 20px;
  display: grid; place-items: center;
  font-size: 32px;
  margin: 0 auto 20px;
  box-shadow: var(--shadow-gold);
  transition: transform 0.4s;
}
.expertise-card:hover .expertise-icon {
  transform: rotate(-8deg) scale(1.05);
}
.expertise-title {
  font-size: 19px; font-weight: 700;
  margin-bottom: 12px;
  color: var(--text);
}
.expertise-desc {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ---------- CAREER TIMELINE ---------- */
.timeline {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  padding: 0 20px;
}
.timeline::before {
  content: ''; position: absolute;
  top: 0; bottom: 0;
  inset-inline-start: 30px;
  width: 2px;
  background: linear-gradient(to bottom, var(--accent), transparent);
}
.timeline-item {
  position: relative;
  padding-inline-start: 80px;
  padding-bottom: 48px;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-dot {
  position: absolute;
  inset-inline-start: 22px;
  top: 6px;
  width: 18px; height: 18px;
  background: var(--gold-gradient);
  border-radius: 50%;
  box-shadow: 0 0 0 4px var(--bg), 0 0 0 6px var(--accent), var(--shadow-gold);
}
.timeline-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: all 0.3s;
}
.timeline-card:hover {
  border-color: var(--border-strong);
  transform: translateX(0);
  box-shadow: var(--shadow);
}
html[dir="rtl"] .timeline-card:hover { transform: translateX(-8px); }
html[dir="ltr"] .timeline-card:hover { transform: translateX(8px); }

.timeline-period {
  display: inline-block;
  padding: 4px 12px;
  background: var(--gold-gradient-soft);
  border-radius: 100px;
  color: var(--accent);
  font-size: 13px; font-weight: 600;
  margin-bottom: 12px;
}
.timeline-role {
  font-size: 20px; font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}
.timeline-company {
  font-size: 15px; font-weight: 600;
  color: var(--accent);
  margin-bottom: 4px;
}
.timeline-location {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
}
.timeline-bullets {
  display: flex; flex-direction: column; gap: 8px;
}
.timeline-bullets li {
  position: relative;
  padding-inline-start: 20px;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
}
.timeline-bullets li::before {
  content: '▸';
  position: absolute;
  inset-inline-start: 0;
  color: var(--accent);
  font-weight: bold;
}

/* ---------- CLIENTS ---------- */
.clients-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}
.client-card {
  padding: 28px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.4s;
}
.client-card:hover {
  transform: translateY(-6px) scale(1.02);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-gold);
}
.client-icon {
  width: 60px; height: 60px;
  background: var(--gold-gradient-soft);
  border: 1px solid var(--border-strong);
  border-radius: 16px;
  display: grid; place-items: center;
  font-size: 28px;
  margin: 0 auto 16px;
}
.client-name {
  font-size: 16px; font-weight: 700;
  margin-bottom: 6px;
  color: var(--text);
}
.client-category {
  font-size: 13px;
  color: var(--text-muted);
}
.client-flag {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  font-size: 18px;
  opacity: 0.7;
}

/* ---------- SKILLS ---------- */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px 40px;
  max-width: 1000px;
  margin: 0 auto;
}
.skill-item {
  display: flex; flex-direction: column; gap: 10px;
}
.skill-head {
  display: flex; justify-content: space-between;
  font-size: 15px; font-weight: 600;
}
.skill-percent { color: var(--accent); }
.skill-bar {
  height: 8px;
  background: var(--bg-3);
  border-radius: 100px;
  overflow: hidden;
  position: relative;
}
.skill-bar-fill {
  height: 100%;
  background: var(--gold-gradient);
  border-radius: 100px;
  width: 0;
  transition: width 1.5s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}
.skill-bar-fill::after {
  content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmer 2s infinite;
}
@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

/* ---------- CERTIFICATES ---------- */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin-bottom: 60px;
}
.cert-card {
  padding: 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  display: flex; gap: 16px; align-items: center;
  transition: all 0.3s;
}
.cert-card:hover {
  border-color: var(--border-strong);
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}
.cert-icon {
  width: 56px; height: 56px;
  background: var(--gold-gradient);
  border-radius: 14px;
  display: grid; place-items: center;
  font-size: 24px;
  flex-shrink: 0;
  box-shadow: var(--shadow-gold);
}
.cert-name {
  font-size: 15px; font-weight: 700;
  margin-bottom: 4px;
  color: var(--text);
}
.cert-issuer {
  font-size: 13px;
  color: var(--text-muted);
}

.education-block {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}
.education-block h3 {
  font-family: var(--font-display);
  font-size: 24px;
  margin-bottom: 20px;
  color: var(--accent);
}
html[lang="ar"] .education-block h3 { font-family: var(--font-ar); }
.education-item {
  display: flex; flex-direction: column; gap: 6px;
  align-items: center;
}
.education-degree { font-size: 17px; font-weight: 700; }
.education-year { color: var(--accent); font-weight: 600; }
.education-grade { font-size: 14px; color: var(--text-muted); }

/* ---------- CONTACT ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 40px;
  align-items: start;
}
.contact-info {
  display: flex; flex-direction: column; gap: 16px;
}
.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex; gap: 16px; align-items: center;
  transition: all 0.3s;
}
.contact-card:hover {
  border-color: var(--border-strong);
  transform: translateX(0);
  box-shadow: var(--shadow);
}
html[dir="rtl"] .contact-card:hover { transform: translateX(-6px); }
html[dir="ltr"] .contact-card:hover { transform: translateX(6px); }
.contact-icon {
  width: 52px; height: 52px;
  background: var(--gold-gradient);
  border-radius: 14px;
  display: grid; place-items: center;
  font-size: 22px;
  flex-shrink: 0;
  box-shadow: var(--shadow-gold);
}
.contact-card-content h4 {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.contact-card-content p {
  font-size: 15px;
  font-weight: 600;
}

.contact-social {
  display: flex; gap: 12px;
  padding-top: 8px;
}
.contact-social a {
  width: 48px; height: 48px;
  display: grid; place-items: center;
  border-radius: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  font-size: 20px;
  transition: all 0.3s;
}
.contact-social a:hover {
  background: var(--gold-gradient);
  color: #000;
  transform: translateY(-4px);
  box-shadow: var(--shadow-gold);
}

.contact-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
  display: flex; flex-direction: column; gap: 20px;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}
.form-group input,
.form-group textarea {
  padding: 14px 16px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font: inherit;
  font-size: 15px;
  transition: all 0.2s;
}
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent);
  background: var(--bg-2);
  box-shadow: 0 0 0 3px var(--gold-gradient-soft);
}
.form-group textarea { resize: vertical; min-height: 120px; }

/* ---------- FOOTER ---------- */
.footer {
  background: var(--bg-2);
  border-top: 1px solid var(--border);
  padding: 40px 0;
}
.footer-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}
.footer-brand {
  display: flex; align-items: center; gap: 12px;
}
.footer-brand p {
  font-weight: 700;
  background: var(--gold-gradient);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.footer-rights, .footer-made {
  font-size: 14px;
  color: var(--text-muted);
}

/* ---------- FLOATING BUTTONS ---------- */
.floating-btn {
  position: fixed;
  width: 56px; height: 56px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 24px;
  z-index: 90;
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
  transition: all 0.3s;
  cursor: pointer;
  bottom: 24px;
}
.floating-whatsapp {
  background: #25D366;
  color: #fff;
  inset-inline-start: 24px;
}
.floating-whatsapp:hover {
  transform: scale(1.1) rotate(8deg);
  color: #fff;
}
.floating-chat {
  background: var(--gold-gradient);
  color: #000;
  inset-inline-end: 24px;
  position: fixed;
  border: none;
}
.floating-chat:hover {
  transform: scale(1.1);
}
.chat-pulse {
  position: absolute; inset: 0;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.5;
  animation: chatPulse 2s ease-out infinite;
  z-index: -1;
}
@keyframes chatPulse {
  0% { transform: scale(1); opacity: 0.5; }
  100% { transform: scale(1.6); opacity: 0; }
}

/* ---------- CHATBOT WINDOW ---------- */
.chatbot-window {
  position: fixed;
  bottom: 96px;
  inset-inline-end: 24px;
  width: 380px;
  max-width: calc(100vw - 48px);
  height: 560px;
  max-height: calc(100vh - 140px);
  background: var(--bg-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
  display: flex; flex-direction: column;
  z-index: 95;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px) scale(0.95);
  transform-origin: bottom right;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
html[dir="rtl"] .chatbot-window { transform-origin: bottom left; }
.chatbot-window.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}
.chatbot-header {
  padding: 20px;
  background: var(--gold-gradient);
  color: #000;
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
  display: flex; justify-content: space-between; align-items: center;
}
.chatbot-header-info {
  display: flex; gap: 12px; align-items: center;
}
.chatbot-avatar {
  width: 44px; height: 44px;
  background: rgba(0,0,0,0.15);
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 20px;
}
.chatbot-header h4 {
  font-size: 16px; font-weight: 700;
  margin-bottom: 2px;
}
.chatbot-header p {
  font-size: 12px;
  opacity: 0.8;
}
.chatbot-close {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border-radius: 8px;
  background: rgba(0,0,0,0.1);
  color: #000;
  transition: background 0.2s;
}
.chatbot-close:hover { background: rgba(0,0,0,0.25); }

.chatbot-messages {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex; flex-direction: column; gap: 12px;
  scroll-behavior: smooth;
}
.chatbot-messages::-webkit-scrollbar { width: 6px; }
.chatbot-messages::-webkit-scrollbar-thumb { background: var(--border); border-radius: 100px; }

.chat-msg {
  max-width: 85%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.6;
  word-wrap: break-word;
  animation: msgIn 0.3s ease-out;
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.chat-msg-bot {
  background: var(--bg-3);
  color: var(--text);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}
html[dir="rtl"] .chat-msg-bot {
  border-bottom-left-radius: 16px;
  border-bottom-right-radius: 4px;
}
.chat-msg-user {
  background: var(--gold-gradient);
  color: #000;
  align-self: flex-end;
  border-bottom-right-radius: 4px;
  font-weight: 500;
}
html[dir="rtl"] .chat-msg-user {
  border-bottom-right-radius: 16px;
  border-bottom-left-radius: 4px;
}
.chat-msg-typing {
  display: inline-flex; gap: 4px; align-items: center;
}
.chat-msg-typing span {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  animation: typingDot 1.4s infinite ease-in-out;
}
.chat-msg-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-msg-typing span:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingDot {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-6px); opacity: 1; }
}

.chatbot-suggestions {
  padding: 0 20px 12px;
  display: flex; gap: 8px; flex-wrap: wrap;
}
.chat-suggestion {
  padding: 6px 12px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: 12px;
  color: var(--text-muted);
  transition: all 0.2s;
}
.chat-suggestion:hover {
  background: var(--gold-gradient-soft);
  color: var(--accent);
  border-color: var(--border-strong);
}

.chatbot-input-area {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
  display: flex; gap: 10px;
  background: var(--bg-2);
}
.chatbot-input-area input {
  flex: 1;
  padding: 12px 16px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: 100px;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  transition: all 0.2s;
}
.chatbot-input-area input:focus {
  outline: none;
  border-color: var(--accent);
}
.chatbot-input-area button {
  width: 44px; height: 44px;
  background: var(--gold-gradient);
  color: #000;
  border-radius: 50%;
  display: grid; place-items: center;
  font-size: 16px;
  transition: transform 0.2s;
  flex-shrink: 0;
}
.chatbot-input-area button:hover { transform: scale(1.08); }
.chatbot-input-area button:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.chatbot-footer {
  padding: 8px 20px 12px;
  text-align: center;
  font-size: 11px;
  color: var(--text-dim);
}

/* ---------- AOS-LIKE ANIMATIONS ---------- */
[data-aos] {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
[data-aos="fade-left"] { transform: translateX(30px); }
[data-aos="fade-right"] { transform: translateX(-30px); }
html[dir="rtl"] [data-aos="fade-left"] { transform: translateX(-30px); }
html[dir="rtl"] [data-aos="fade-right"] { transform: translateX(30px); }
[data-aos].animated {
  opacity: 1;
  transform: translate(0, 0);
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 900px) {
  .hero-container,
  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .hero { text-align: center; padding-top: calc(var(--header-h) + 20px); }
  .hero-content { order: 2; }
  .hero-image { order: 1; }
  .hero-image-wrapper { width: 280px; height: 280px; }
  .hero-actions, .hero-social { justify-content: center; }
  .hero-badge-1 { inset-inline-start: -10px; }
  .hero-badge-2 { inset-inline-end: -10px; }
  .placeholder-text { font-size: 90px; }

  .form-row { grid-template-columns: 1fr; }

  .nav-menu {
    position: fixed;
    top: var(--header-h);
    inset-inline-end: 0;
    width: 280px;
    height: calc(100vh - var(--header-h));
    background: var(--bg-2);
    border-inline-start: 1px solid var(--border);
    flex-direction: column;
    padding: 20px;
    gap: 4px;
    transform: translateX(100%);
    transition: transform 0.3s;
    box-shadow: -10px 0 30px rgba(0,0,0,0.2);
  }
  html[dir="rtl"] .nav-menu { transform: translateX(-100%); }
  .nav-menu.open { transform: translateX(0); }
  .nav-menu a { padding: 14px 16px; }
  .mobile-only { display: grid; }
  #langToggle span { display: inline; }

  .section { padding: 64px 0; }
  .section-header { margin-bottom: 40px; }

  .timeline { padding: 0; }
  .timeline-item { padding-inline-start: 60px; }
  .timeline::before { inset-inline-start: 20px; }
  .timeline-dot { inset-inline-start: 12px; }

  .floating-btn { width: 50px; height: 50px; font-size: 20px; }
  .chatbot-window {
    width: calc(100vw - 32px);
    inset-inline-end: 16px;
    bottom: 80px;
    height: 70vh;
  }

  .stats-grid { gap: 12px; }
  .stat-card { padding: 24px 16px; }
  .stat-number { font-size: 36px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .btn { padding: 12px 20px; font-size: 14px; }
  .hero-name { font-size: 36px; }
  .contact-form { padding: 24px; }
}

/* ---------- SELECTION ---------- */
::selection { background: var(--accent); color: #000; }
