/* Modern CSS Reset & Fonts */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap");

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

html {
  scroll-behavior: smooth;
  color-scheme: dark light;
}

/* Theme Variables */
:root {
  /* Dark Theme (Default) */
  --bg-color: #03001e;
  --bg-gradient: radial-gradient(
    circle at 50% 50%,
    #03001e 0%,
    #7303c0 50%,
    #4ade80 100%
  );
  --bg-flat: #060214;

  --text-primary: #f3f4f6;
  --text-secondary: #9ca3af;
  --primary: #8b5cf6;
  --primary-glow: rgba(139, 92, 246, 0.35);
  --secondary: #4ade80;
  --secondary-glow: rgba(74, 222, 128, 0.35);
  --accent: #00f2fe;

  --glass-bg: rgba(15, 10, 30, 0.65);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-shadow: rgba(0, 0, 0, 0.35);

  --card-hover-bg: rgba(255, 255, 255, 0.03);
}

[data-theme="light"] {
  --bg-color: #f3f4f6;
  --bg-gradient: radial-gradient(
    circle at 50% 50%,
    #f3f4f6 0%,
    #d1fae5 60%,
    #a7f3d0 100%
  );
  --bg-flat: #f8fafc;

  --text-primary: #1f2937;
  --text-secondary: #4b5563;
  --primary: #6366f1;
  --primary-glow: rgba(99, 102, 241, 0.25);
  --secondary: #10b981;
  --secondary-glow: rgba(16, 185, 129, 0.25);
  --accent: #0891b2;

  --glass-bg: rgba(255, 255, 255, 0.75);
  --glass-border: rgba(0, 0, 0, 0.06);
  --glass-shadow: rgba(31, 41, 55, 0.08);

  --card-hover-bg: rgba(99, 102, 241, 0.04);
}

/* Base Body Styles */
body {
  font-family: "Inter", sans-serif;
  background-color: var(--bg-flat);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
  transition:
    background-color 0.5s ease,
    color 0.5s ease;
  padding-top: 100px; /* Space for the shrinking header */
}

/* Background Glow Effects */
.bg-glows {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.glow-1,
.glow-2 {
  position: absolute;
  border-radius: 50%;
  filter: blur(120px);
  opacity: 0.35;
  transition: opacity 0.5s ease;
}

.glow-1 {
  top: -10%;
  right: 10%;
  width: 45vw;
  height: 45vw;
  background: radial-gradient(circle, var(--primary) 0%, transparent 70%);
}

.glow-2 {
  bottom: -10%;
  left: 10%;
  width: 50vw;
  height: 50vw;
  background: radial-gradient(circle, var(--secondary) 0%, transparent 70%);
}

/* Glassmorphism General Rule */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border: 1px solid var(--glass-border);
  box-shadow: 0 8px 32px 0 var(--glass-shadow);
  position: relative;
  overflow: hidden;
}

/* --- Interactive Spotlight Effect --- */
.glass::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: inherit;
  padding: 1px; /* border thickness */
  background: radial-gradient(
    250px circle at var(--mouse-x, 0px) var(--mouse-y, 0px),
    rgba(74, 222, 128, 0.35),
    transparent 80%
  );
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 2;
}

.glass::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  border-radius: inherit;
  background: radial-gradient(
    300px circle at var(--mouse-x, 0px) var(--mouse-y, 0px),
    rgba(74, 222, 128, 0.05),
    transparent 80%
  );
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: -1;
}

/* Enable transitions for spotlight on hover */
.glass:hover::before,
.glass:hover::after {
  opacity: 1;
}

/* Disable smooth transition scaling for motion-sensitive users */
@media (prefers-reduced-motion: reduce) {
  .glass::before,
  .glass::after {
    transition: none !important;
  }
}

/* --- Header / Navigation --- */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100px;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 8%;
  transition: border-bottom-color 0.3s ease;
  /* Scroll Timeline hook */
  animation: shrink-header auto linear both;
  animation-timeline: scroll(block root);
  animation-range: 0px 100px;
}

@keyframes shrink-header {
  to {
    height: 70px;
    background: var(--glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
    box-shadow: 0 4px 20px var(--glass-shadow);
  }
}

.logo {
  font-family: "Outfit", sans-serif;
  font-size: 1.5rem;
  font-weight: 700;
  text-decoration: none;
  /* background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent; */
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

nav a {
  text-decoration: none;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.3s ease;
  position: relative;
}

nav a::after {
  content: "";
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
}

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

nav a:hover::after {
  width: 100%;
}

/* Control Buttons Wrapper */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

/* Language Selection Button */
.lang-btn {
  background: var(--glass-bg);
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  font-size: 0.8rem;
  font-weight: 700;
  cursor: pointer;
  padding: 0.5rem 0.9rem;
  border-radius: 20px;
  transition: all 0.3s ease;
}

.lang-btn:hover {
  border-color: var(--secondary);
  background: var(--primary);
  transform: translateY(-2px);
}

/* Theme Toggle Button */
.theme-btn {
  background: transparent;
  border: 1px solid var(--glass-border);
  color: var(--text-primary);
  cursor: pointer;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  transition: all 0.3s ease;
}

.theme-btn:hover {
  background: var(--primary);
  border-color: var(--secondary);
  transform: rotate(15deg);
}

.theme-btn .fa-sun {
  display: none;
}

[data-theme="light"] .theme-btn .fa-moon {
  display: none;
}

[data-theme="light"] .theme-btn .fa-sun {
  display: block;
}

/* Hamburger Menu (Mobile) */
.menu-toggle {
  display: none;
  font-size: 1.5rem;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
}

/* --- Main Sections --- */
section {
  padding: 6rem 8%;
  min-height: calc(100vh - 100px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Section Scroll Reveal (Scroll-driven animations) */
@media (prefers-reduced-motion: no-preference) {
  @supports ((animation-timeline: view()) and (animation-range: entry)) {
    @keyframes reveal-in {
      from {
        opacity: 0;
        transform: translateY(60px);
      }
      to {
        opacity: 1;
        transform: translateY(0);
      }
    }

    .scroll-reveal {
      /* Handled by IntersectionObserver and .revealed class below */
    }
  }
}

/* Section Scroll Reveal (IntersectionObserver based) */
.scroll-reveal {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 1.2s cubic-bezier(0.16, 1, 0.3, 1),
    transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.scroll-reveal.revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Specific Animations on reveal */
#about.revealed .about-details {
  animation: slideFromLeft 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
#about.revealed .about-stats {
  animation: slideFromRight 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

#skills.revealed .skills-category {
  opacity: 0;
  animation: zoomInReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
#skills.revealed .skills-category:nth-child(1) {
  animation-delay: 0.1s;
}
#skills.revealed .skills-category:nth-child(2) {
  animation-delay: 0.25s;
}
#skills.revealed .skills-category:nth-child(3) {
  animation-delay: 0.4s;
}
#skills.revealed .skills-category:nth-child(4) {
  animation-delay: 0.55s;
}
#skills.revealed .skills-category:nth-child(5) {
  animation-delay: 0.7s;
}

#project-skills.revealed .comp-card {
  opacity: 0;
  animation: slideUpReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
#project-skills.revealed .comp-card:nth-child(1) {
  animation-delay: 0.1s;
}
#project-skills.revealed .comp-card:nth-child(2) {
  animation-delay: 0.2s;
}
#project-skills.revealed .comp-card:nth-child(3) {
  animation-delay: 0.3s;
}
#project-skills.revealed .comp-card:nth-child(4) {
  animation-delay: 0.4s;
}
#project-skills.revealed .comp-card:nth-child(5) {
  animation-delay: 0.5s;
}
#project-skills.revealed .comp-card:nth-child(6) {
  animation-delay: 0.6s;
}

#certifications.revealed .cert-card {
  opacity: 0;
  animation: zoomInReveal 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
#certifications.revealed .cert-card:nth-child(1) {
  animation-delay: 0.15s;
}
#certifications.revealed .cert-card:nth-child(2) {
  animation-delay: 0.35s;
}

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

@keyframes slideFromRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

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

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

.section-title {
  font-family: "Outfit", sans-serif;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 3.5rem;
  text-align: center;
  position: relative;
}

.section-title::after {
  content: "";
  display: block;
  width: 50px;
  height: 4px;
  background: var(--primary);
  margin: 0.5rem auto 0;
  border-radius: 2px;
}

/* --- Hero Section --- */
#hero {
  flex-direction: row;
  align-items: center;
  gap: 4rem;
  padding-top: 2rem;
}

.hero-content {
  flex: 1.2;
}

.hero-subtitle {
  font-family: "Outfit", sans-serif;
  font-size: 1.1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--secondary);
  margin-bottom: 1rem;
}

.hero-title {
  font-family: "Outfit", sans-serif;
  font-size: 3.5rem;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.typed-text {
  color: var(--secondary);
  text-shadow: 0 0 10px rgba(74, 222, 128, 0.35);
  border-right: 2px solid var(--secondary);
  padding-right: 5px;
  animation: blink 0.75s step-end infinite;
}

@keyframes blink {
  from,
  to {
    border-color: transparent;
  }
  50% {
    border-color: var(--secondary);
  }
}

.hero-desc {
  color: var(--text-secondary);
  font-size: 1.1rem;
  margin-bottom: 2.5rem;
  max-width: 580px;
}

.hero-btns {
  display: flex;
  gap: 1rem;
}

.btn {
  padding: 0.8rem 2rem;
  border-radius: 30px;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.12) 0%,
    rgba(255, 255, 255, 0.04) 100%
  );
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text-primary);
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 1px 0 0 rgba(255, 255, 255, 0.25) inset,
    0 4px 15px var(--glass-shadow);
  position: relative;
  overflow: hidden;
}

[data-theme="light"] .btn-primary {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.08) 0%,
    rgba(0, 0, 0, 0.03) 100%
  );
  border-color: rgba(0, 0, 0, 0.12);
  color: var(--text-primary);
  box-shadow:
    0 1px 0 0 rgba(255, 255, 255, 0.6) inset,
    0 4px 15px rgba(0, 0, 0, 0.05);
}

.btn-primary::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -60%;
  width: 130%;
  height: 200%;
  background: linear-gradient(
    45deg,
    transparent 45%,
    rgba(255, 255, 255, 0.2) 50%,
    transparent 55%
  );
  transform: rotate(-45deg) translate(-100%, -100%);
  transition: transform 0.8s cubic-bezier(0.165, 0.84, 0.44, 1);
  pointer-events: none;
}

.btn-primary:hover::after {
  transform: rotate(-45deg) translate(100%, 100%);
}

.btn-primary:hover {
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.18) 0%,
    rgba(255, 255, 255, 0.06) 100%
  );
  box-shadow:
    0 1px 0 0 rgba(255, 255, 255, 0.35) inset,
    0 0 20px var(--secondary-glow);
  border-color: rgba(74, 222, 128, 0.4);
  transform: translateY(-3px);
}

[data-theme="light"] .btn-primary:hover {
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0.12) 0%,
    rgba(0, 0, 0, 0.06) 100%
  );
  box-shadow:
    0 1px 0 0 rgba(255, 255, 255, 0.8) inset,
    0 0 15px var(--secondary-glow);
  border-color: rgba(16, 185, 129, 0.4);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: var(--text-primary);
  border: 1px solid var(--glass-border);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.btn-secondary:hover {
  background: var(--card-hover-bg);
  border-color: rgba(74, 222, 128, 0.3);
  box-shadow: 0 0 15px rgba(74, 222, 128, 0.15);
  transform: translateY(-3px);
}

/* Profile Picture & Rotating Frame */
.hero-img {
  flex: 0.8;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
  min-height: 400px;
}

.img-container2 {
  width: 100%;
  max-width: 450px;
  aspect-ratio: 1 / 1;
  position: relative;
  animation: float 6s ease-in-out infinite;
  display: flex;
  justify-content: center;
  align-items: center;
}

.img-container2 img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  /* border-radius: 24px; */
  /* border: 1px solid var(--glass-border); */
  /* box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35); */
}

/* 6 Floating Badges (Tags) around the avatar */
.floating-badge {
  position: absolute;
  padding: 0.4rem 0.8rem;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  font-weight: 600;
  box-shadow: 0 8px 32px 0 var(--glass-shadow);
  animation: float 6s ease-in-out infinite;
  white-space: nowrap;
}

.floating-badge i {
  color: var(--secondary);
}

/* Positioning the 6 badges */
.badge-1 {
  top: 0%;
  left: -8%;
  animation-delay: 0s;
}
.badge-2 {
  top: 15%;
  right: -8%;
  animation-delay: 1s;
}
.badge-3 {
  top: 45%;
  left: -15%;
  animation-delay: 2s;
}
.badge-4 {
  top: 60%;
  right: -15%;
  animation-delay: 3s;
}
.badge-5 {
  bottom: -2%;
  left: -5%;
  animation-delay: 4s;
}
.badge-6 {
  bottom: 8%;
  right: -5%;
  animation-delay: 5s;
}

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

/* --- About Section --- */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 4rem;
  align-items: center;
}

.about-details p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  justify-self: center;
  width: 100%;
  max-width: 440px;
}

.stat-card {
  padding: 2rem;
  border-radius: 20px;
  text-align: center;
  transition: transform 0.3s ease;
}

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

.stat-card h3 {
  font-family: "Outfit", sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 0.2rem;
}

.stat-card p {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
}

/* --- Projects Section --- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2.5rem;
}

.project-card {
  border-radius: 20px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 40px rgba(74, 222, 128, 0.1);
}

.project-img {
  width: 100%;
  height: 200px;
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.08) 0%,
    rgba(74, 222, 128, 0.08) 100%
  );
  position: relative;
  overflow: hidden;
}

.project-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
  display: block;
}

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

.project-img::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(
    circle,
    rgba(255, 255, 255, 0.1) 0%,
    transparent 80%
  );
}

.project-img i {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 3.5rem;
  opacity: 0.8;
  color: var(--secondary);
  transition: transform 0.3s ease;
}

.project-card:hover .project-img i {
  transform: translate(-50%, -50%) scale(1.1);
}

.project-info {
  padding: 1.8rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

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

.tag {
  background: rgba(74, 222, 128, 0.1);
  color: var(--secondary);
  padding: 0.25rem 0.75rem;
  border-radius: 15px;
  font-size: 0.75rem;
  font-weight: 600;
}

.project-title {
  font-family: "Outfit", sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.8rem;
}

.project-desc {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.project-links {
  display: flex;
  gap: 1rem;
}

.project-link {
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: color 0.3s ease;
}

.project-link:hover {
  color: var(--secondary);
}

/* --- Skills Section --- */
.skills-container {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}

.skills-category {
  padding: 2.5rem;
  border-radius: 24px;
}

.skills-category h3 {
  font-family: "Outfit", sans-serif;
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.skills-category h3 i {
  color: var(--secondary);
}

.skills-list {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.skill-badge {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1.5rem;
  border-radius: 16px;
  font-weight: 500;
  font-size: 0.95rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.skill-badge:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 4px 15px var(--secondary-glow);
}

/* --- New Section: Compétences Projet (Project Competencies) --- */
.comp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
}

.comp-card {
  padding: 2.2rem;
  border-radius: 24px;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.comp-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 8px 30px var(--secondary-glow);
}

.comp-icon {
  width: 54px;
  height: 54px;
  border-radius: 14px;
  background: var(--secondary-glow);
  color: var(--secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.comp-card h3 {
  font-family: "Outfit", sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.3;
}

.comp-card p {
  color: var(--text-secondary);
  font-size: 0.92rem;
  line-height: 1.6;
}

/* --- New Section: Certifications --- */
.cert-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
}

.cert-card {
  padding: 2.2rem;
  border-radius: 24px;
  display: flex;
  align-items: center;
  gap: 1.8rem;
  transition: transform 0.3s ease;
}

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

.cert-badge {
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: var(--secondary-glow);
  color: var(--secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
}

.cert-info h3 {
  font-family: "Outfit", sans-serif;
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.4rem;
}

.cert-info p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* --- Contact Section --- */
.contact-container {
  display: grid;
  grid-template-columns: 1fr 1.3fr;
  gap: 4rem;
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.contact-desc {
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.contact-methods {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  padding: 1.2rem;
  border-radius: 16px;
  transition: transform 0.3s ease;
}

.contact-card:hover {
  transform: translateX(5px);
}

.contact-icon {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: var(--secondary-glow);
  color: var(--secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
}

.contact-details h4 {
  font-family: "Outfit", sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  margin-bottom: 0.2rem;
}

.contact-details p {
  font-size: 1rem;
  font-weight: 500;
}

.contact-form {
  padding: 2.5rem;
  border-radius: 24px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
}

.form-group input,
.form-group textarea {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--glass-border);
  padding: 0.9rem 1.2rem;
  border-radius: 12px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  transition: all 0.3s ease;
  outline: none;
}

[data-theme="light"] .form-group input,
[data-theme="light"] .form-group textarea {
  background: rgba(0, 0, 0, 0.02);
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 10px var(--secondary-glow);
  background: rgba(255, 255, 255, 0.05);
}

.contact-form .btn {
  align-self: flex-start;
  border: none;
  cursor: pointer;
}

/* Form Submit Loading Spinner */
.btn-loader {
  display: none;
  width: 18px;
  height: 18px;
  border: 2px solid rgba(6, 2, 20, 0.25);
  border-top-color: #060214;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

[data-theme="light"] .btn-loader {
  border-color: rgba(255, 255, 255, 0.25);
  border-top-color: #ffffff;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.btn.submitting {
  pointer-events: none;
  opacity: 0.8;
}

.btn.submitting .btn-loader {
  display: inline-block;
}

/* --- Interactive Toast Notification --- */
.toast-container {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 9999;
  pointer-events: none;
}

.toast {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1rem 1.8rem;
  border-radius: 16px;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  pointer-events: auto;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

.toast-icon {
  color: var(--secondary);
  font-size: 1.2rem;
}

.toast-message {
  font-size: 0.95rem;
  font-weight: 500;
}

/* --- Footer --- */
footer {
  border-top: 1px solid var(--glass-border);
  padding: 2.5rem 8%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  background: var(--bg-flat);
}

.footer-socials {
  display: flex;
  gap: 1.5rem;
}

.social-link {
  color: var(--text-secondary);
  font-size: 1.2rem;
  transition: all 0.3s ease;
}

.social-link:hover {
  color: var(--primary);
  transform: translateY(-2px);
}

.footer-text {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* --- Responsive Adaptations --- */
@media (max-width: 992px) {
  header {
    padding: 0 5%;
  }

  section {
    padding: 5rem 5%;
  }

  #hero {
    flex-direction: column-reverse;
    text-align: center;
    gap: 3.5rem;
    padding-top: 0;
  }

  .hero-desc {
    margin: 0 auto 2rem;
  }

  .hero-btns {
    justify-content: center;
  }

  .img-container2 {
    width: 100%;
    max-width: 240px;
    aspect-ratio: 1 / 1;
    justify-self: center;
  }

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

  .hero-img {
    min-height: 380px;
  }

  .badge-1 {
    top: -2%;
    left: 0%;
  }
  .badge-2 {
    top: 12%;
    right: 0%;
  }
  .badge-3 {
    top: 40%;
    left: -8%;
  }
  .badge-4 {
    top: 58%;
    right: -8%;
  }
  .badge-5 {
    bottom: -2%;
    left: 5%;
  }
  .badge-6 {
    bottom: 8%;
    right: 5%;
  }

  .about-grid {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

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

  .contact-container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }

  nav {
    position: fixed;
    top: 100px;
    left: 0;
    width: 100%;
    background: var(--bg-flat);
    border-bottom: 1px solid var(--glass-border);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    align-items: center;
    transform: translateY(-150%);
    opacity: 0;
    transition:
      transform 0.4s ease,
      opacity 0.4s ease;
    pointer-events: none;
    z-index: 999;
  }

  nav.active {
    transform: translateY(0);
    opacity: 1;
    pointer-events: all;
  }

  header.active-nav {
    background: var(--bg-flat) !important;
  }

  body.menu-open {
    overflow: hidden;
  }

  .comp-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

.text-blanc {
  color: var(--text-primary);
}
