.about {
  width: 100%;
  max-width: 950px;
  margin-left: auto;
  margin-right: auto;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

:root {
  --fond: #f5f5f5;
  --texte: #26363c;
  --texteblanc: #ffffff;
  --jaune: #adf28d;
  --rouge: #f69696;
  --bleu: #0053ad;
  --gris: #6d6d6d;
  --grishover: #686868;
  
  --apple-blue: #085bab;
  --apple-purple: #6a4c93;
  --apple-pink: #e91e63;
  --apple-orange: #ff6d00;
  --apple-mint: #00acc1;
  --apple-green: #4caf50;
  --apple-teal: #085bab;
  --apple-indigo: #3f51b5;
  --apple-cyan: #00bcd4;
  --apple-violet: #9c27b0;
  --apple-gray: #8E8E93;
  
  /* Light mode specific */
  --nav-bg: rgba(255, 255, 255, 0.25);
  --nav-bg-hover: rgba(255, 255, 255, 0.35);
  --nav-cursor-bg: rgba(255, 255, 255, 0.9);
  --dropdown-bg: rgba(255, 255, 255, 0.35);
  --dropdown-hover: rgba(255, 255, 255, 0.6);
  --contact-bg: rgba(255, 255, 255, 0.5);
  --footer-bg: rgba(255, 255, 255, 0.6);
  --card-border: rgba(161, 161, 161, 0.15);
  --noise-bg: #ffffff;
  --noise-opacity: 40%;
  --skill-border: rgba(38, 54, 60, 0.15);
}

/* Dark Mode Variables */
html.dark-mode,
body.dark-mode {
  --fond: #0a0e14;
  --texte: #e6e8eb;
  --texteblanc: #ffffff;
  --jaune: #adf28d;
  --rouge: #f69696;
  --bleu: #4a9eff;
  --gris: #aeaeae;
  --grishover: #c5c8ce;
  
  --apple-blue: #4a9eff;
  --apple-purple: #2b7ddc;
  --apple-pink: #f472b6;
  --apple-orange: #fb923c;
  --apple-mint: #22d3ee;
  --apple-green: #4ade80;
  --apple-teal: #438bde;
  --apple-indigo: #818cf8;
  --apple-cyan: #70b0f9;
  --apple-violet: #1774dd;
  --apple-gray: #9ca3af;
  
  /* Dark mode specific */
  --nav-bg: rgba(20, 25, 35, 0.7);
  --nav-bg-hover: rgba(50, 60, 75, 0.8);
  --nav-cursor-bg: rgba(50, 60, 75, 0.9);
  --dropdown-bg: rgba(20, 25, 35, 0.7);
  --dropdown-hover: rgba(50, 60, 75, 0.8);
  --contact-bg: rgba(20, 25, 35, 0.6);
  --footer-bg: rgba(20, 25, 35, 0.6);
  --card-border: rgba(255, 255, 255, 0.1);
  --noise-bg: #1a1f2e;
  --noise-opacity: 15%;
  --skill-border: rgba(230, 232, 235, 0.2);
}
html {
  scroll-behavior: smooth;
  overflow-x: clip;
}
body {
  height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  justify-content: flex-start;
  align-items: center;
  background-color: var(--fond);
  line-height: 1.5;
  font-family: ui-sans-serif, system-ui, sans-serif, Apple Color Emoji, Segoe UI Emoji, Segoe UI Symbol, Noto Color Emoji;
  font-feature-settings: normal;
  font-variation-settings: normal;
  scroll-behavior: smooth;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}


h1, h2, h3, h4 {
  font-size: inherit;
  font-weight: inherit;
  margin: 0;
}
h2 {
  font-size: 1rem;
}
a {
  text-decoration-line: none;
  text-decoration-color: var(--gris);
  text-decoration-thickness: 2px;
  text-underline-offset: 4.5px;
  color: rgb(0, 0, 0);
  transition: text-decoration-line 0.8s ease;
}
a:hover {
  text-decoration-color: var(--grishover);
}
body::before,
body::after {
  position: absolute;
  left: 0;
  top: 0;
  content: '';
  width: 100%;
  height: 100%;
  z-index: -1;
  opacity: var(--noise-opacity);
}
body::before {
  background: var(--noise-bg);
  filter: url(#noiseFilter);
  position: fixed;
}
img {
  border-radius: 10px;
  max-width: 100%;
  height: 100%;
}

/* Hero Section */
.hero-main {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 15vh;
  text-align: center;
  position: relative;
  width: 100%;
  max-width: 950px;
  margin-left: auto;
  margin-right: auto;
  background-image: linear-gradient(90deg, rgba(40,37,34,0.08) 1px, transparent 1px);
  background-size: 30px 30px;
  background-position: 0 0;
  background-repeat: repeat;
  transition: all 0.5s ease;
}

body.dark-mode .hero-main {
  background-image: linear-gradient(90deg, rgba(230,232,235,0.1) 1px, transparent 1px);
}

.hero-main.pattern-1 {
  background-image:
    linear-gradient(90deg, rgba(40,37,34,0.08) 1px, transparent 1px);
  background-size: 30px 30px;
  background-position: 0 0;
  background-repeat: repeat;
}

body.dark-mode .hero-main.pattern-1 {
  background-image:
    linear-gradient(90deg, rgba(230,232,235,0.08) 1px, transparent 1px);
}

.hero-main {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 15vh;
  text-align: left;
  position: relative;
}

.hero-content {
  max-width: 1000px;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
  margin-top: 1rem;
}

@media only screen and (max-width: 768px) {
  .hero-content {
    max-width: 100%;
    padding: 0 1rem;
  }
}

.hero-greeting {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  color: var(--gris);
  margin-bottom: 1rem;
  font-weight: 400;
  opacity: 0.8;
}

.hero-name {
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 700;
  background: linear-gradient(135deg, var(--apple-teal) 0%, var(--apple-cyan) 25%, var(--apple-cyan) 50%, var(--apple-violet) 75%, var(--apple-purple) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.hero-typewriter {
  font-size: clamp(1.5rem, 4vw, 2.5rem);
  color: var(--gris);
  margin-bottom: 2rem;
  min-height: clamp(1.5rem, 4vw, 2.5rem);
  display: flex;
  align-items: center;
  gap: 0.2rem;
  line-height: 1;
}

.typewriter-text {
  font-weight: 500;
  line-height: 1;
}

.cursor {
  color: var(--apple-teal);
  animation: blink 1s infinite;
  font-weight: 300;
}

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

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.3rem);
  color: var(--gris);
  font-weight: 400;
  line-height: 1.6;
  opacity: 0.8;
}

.unique-hero-title {
  background: linear-gradient(135deg, #667eea, #9d7bc9, #f093fb, #f5576c);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: uniqueGlow 4s ease-in-out infinite alternate;
}

@keyframes uniqueGlow {
  from { filter: brightness(1); }
  to { filter: brightness(1.2); }
}

@media only screen and (max-width: 768px) {
  .hero-main {
    min-height: 35vh;
    padding: 0 1rem;
    background-position: center 0;
  }
  
  .hero-typewriter {
    margin-bottom: 2rem;
  }
}

#about {
  padding-top: 2rem;
  width: 100%;
  max-width: 950px;
  margin-left: auto;
  margin-right: auto;
}
.competence-about {
  margin-top: 4rem;
  padding-bottom: 4rem;
  position: relative;
}
.skills-professional-container {
  max-width: 1000px;
  margin: 0;

}

@media only screen and (max-width: 1024px) {
  .skills-professional-container {
    max-width: 100%;
    padding: 0 1rem;
  }
}
.skills-header-professional {
  text-align: left;
  margin-bottom: 0rem;
  position: relative;
  z-index: 10;
}
.skills-title-professional {
  font-size: clamp(2.5rem, 4vw, 3.2rem);
  font-weight: 600;
  background: linear-gradient(135deg, var(--apple-teal) 0%, var(--apple-cyan) 25%, var(--apple-cyan) 50%, var(--apple-violet) 75%, var(--apple-purple) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.02em;
}
.skills-title-professional2 {
  font-size: clamp(2.5rem, 4vw, 3.2rem);
  font-weight: 600;
  background: linear-gradient(135deg, var(--apple-teal) 0%, var(--apple-cyan) 25%, var(--apple-cyan) 50%, var(--apple-violet) 75%, var(--apple-purple) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  letter-spacing: -0.02em;
  margin-bottom: 0.4rem;
}
.skills-description-professional {
  font-size: 1.1rem;
  color: var(--gris);
  margin: 0 auto;
  max-width: 800px;
  line-height: 1.7;
  font-weight: 400;
  margin: 0;
}
.skills-description-professional2 {
  font-size: 1.1rem;
  color: var(--gris);
  margin: 0 auto;
  max-width: 800px;
  line-height: 1.7;
  font-weight: 400;
  margin: 0;
}
.skills-clean {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  margin-bottom: 4rem;
}
.skills-section-clean {
  text-align: left;
}
.skills-category-clean {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--texte);
  margin-bottom: 1rem;
  opacity: 0.8;
  letter-spacing: -0.01em;
  margin-top: 2rem;
}
.skills-category-clean2 {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--texte);
  margin-bottom: 1rem;
  opacity: 0.8;
  letter-spacing: -0.01em;
}
.skills-list-clean {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: 1rem;
  max-width: 1000px;
  margin: 0;
  line-height: 1;
}

@media only screen and (max-width: 768px) {
  .skills-list-clean {
    max-width: 100%;
    gap: 0.75rem;
  }
}
.skill-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-bottom: 0.4rem;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--skill-border);
  border-radius: 0;
  font-size: 0.9rem;
  font-weight: 400;
  color: var(--gris);
  cursor: default;
  text-align: center;
  white-space: nowrap;
  min-height: 32px;
  box-sizing: border-box;
  position: relative;
}
@media only screen and (max-width: 768px) {
  .skills-clean {
    gap: 2rem;
  }
  .skills-list-clean {
    gap: 0.5rem;
  }
  .skill-item {
    font-size: 0.85rem;
    padding: 0.4rem 0.8rem;
  }
}
@media only screen and (max-width: 480px) {
  .skills-category-clean {
    font-size: 1.1rem;
  }
  .skill-item {
    font-size: 0.8rem;
    padding: 0.35rem 0.7rem;
  }
}
.stats-professional {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  padding: 2rem 0;
  margin-top: 2rem;
  border-top: 1px solid var(--skill-border);
}
.stat-professional {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.stat-number-professional {
  font-size: 2.2rem;
  font-weight: 700;
  background: linear-gradient(135deg, var(--apple-blue) 0%, var(--apple-teal) 25%, var(--apple-cyan) 50%, var(--apple-mint) 75%, var(--apple-green) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1;
}
.stat-label-professional {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--gris);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.stat-divider {
  width: 1px;
  height: 3rem;
  background: linear-gradient(180deg, transparent, var(--skill-border), transparent);
}
@media only screen and (max-width: 768px) {
  .competence-about {
    padding-bottom: 1rem;
  }
  .skills-professional-container {
  margin-top: 1rem;

  }
  .skills-header-professional {
    margin-bottom: 0;
    
  }
  .contact-title-wrapper{
    margin-bottom: 1rem;
  }
  .skills-professional-layout {
    gap: 2.5rem;
    margin-bottom: 3rem;
  }
  .skills-category-header {
    gap: 0.75rem;
  }
  .category-icon {
    width: 40px;
    height: 40px;
    font-size: 1.3rem;
  }
  .category-title {
    font-size: 1.1rem;
  }
  .skills-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 1rem;
  }
  .skill-card {
    padding: 1.2rem;
  }
  .skill-icon {
    width: 40px;
    height: 40px;
    font-size: 1.6rem;
    margin-bottom: 0.6rem;
  }
  .skill-name {
    font-size: 0.9rem;
  }
  .skill-level {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
  }
  .stats-professional {
    gap: 1.5rem;
    flex-wrap: wrap;
  }
  .stat-divider {
    display: none;
  }
  .stat-number-professional {
    font-size: 2rem;
    background: linear-gradient(135deg, var(--apple-teal) 0%, var(--apple-mint) 50%, var(--apple-blue) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
  }
  .stat-label-professional {
    font-size: 0.85rem;
  }
}
@media only screen and (max-width: 480px) {
  .skills-professional-container {
    padding: 0 1rem;
  }
  
  .skills-category-header {
    gap: 0.5rem;
  }
  .category-icon {
    width: 35px;
    height: 35px;
    font-size: 1.2rem;
  }
  .category-title {
    font-size: 1rem;
  }
  .skills-grid {
    grid-template-columns: 1fr;
    gap: 0.8rem;
  }
  .skill-card {
    padding: 1rem;
    flex-direction: row;
    text-align: left;
    align-items: center;
    gap: 1rem;
  }
  .skill-icon {
    width: 35px;
    height: 35px;
    font-size: 1.4rem;
    margin-bottom: 0;
    flex-shrink: 0;
  }
  .skill-content {
    display: flex;
    flex-direction: column;
    flex: 1;
  }
  .skill-name {
    font-size: 0.85rem;
    margin-bottom: 0.3rem;
  }
  .skill-level {
    font-size: 0.7rem;
    padding: 0.2rem 0.5rem;
    align-self: flex-start;
  }
  .category-line {
    width: 100%;
    margin-left: 0;
  }
  .skills-list {
    gap: 0.5rem;
  }
  .skill-item {
    font-size: 0.85rem;
    padding: 0.4rem 0.7rem;
  }
}
.petit-texte-about {
  margin-top: 3rem;
}
.dropdown {
  position: fixed;
  top: 5%;
  right: max(1rem, min(2rem, calc((100vw - 100px) / 2)));
  display: inline-block;
  background: var(--dropdown-bg);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  border-radius: 22px;
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
  z-index: 998;
  height: 56px;
  width: 58px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

@media (hover: none), (pointer: coarse) {
  a,
  button,
  [role="button"],
  input,
  select,
  textarea,
  summary {
    -webkit-tap-highlight-color: transparent;
  }

  a:focus,
  button:focus,
  [role="button"]:focus,
  input:focus,
  select:focus,
  textarea:focus,
  summary:focus,
  a:active,
  button:active {
    outline: none;
    box-shadow: none;
  }
}

.dropdown.nav-hidden {
  transform: translateY(-120%);
  opacity: 0;
  pointer-events: none;
}
.dropdown-content {
  margin-top: 0.5rem;
  display: none;
  position: absolute;
  background: var(--dropdown-bg);
  z-index: 1;
  border-radius: 22px;
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  top: 100%;
  right: 0;
  width: 58px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  overflow: hidden;
}
.dropdown-content a {
  color: var(--texte);
  height: 56px;
  padding: 0;
  text-decoration: none;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: background 0.2s ease;
}
.dropdown-content a:hover {
  background: var(--dropdown-hover);
  color: var(--texte);
}
.dropdown:hover .dropdown-content {
  display: block;
  opacity: 1;
  visibility: visible;
}
.dropbtn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--texte);
  height: 56px;
  width: 100%;
  padding: 0;
  border-radius: 22px;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: background 0.2s ease;
}
.dropdown:hover .dropbtn {
  background: var(--dropdown-hover);
}
.lang-text {
  user-select: none;
}
.active-flag{
  background: var(--dropdown-hover) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}
.active-flag-middle{
  background: var(--dropdown-hover) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

body.dark-mode .active-flag {
  background: rgba(50, 60, 75, 0.95) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,0.4);
}

body.dark-mode .active-flag-middle {
  background: rgba(50, 60, 75, 0.95) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,0.4);
}
header #menu.sticky a {
  color: var(--texte);
}
header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  padding: 0 2rem;
}
header>:first-child :first-child {
  color: var(--couleur-1)
}
#menu {
  border-radius: 30px;
  -webkit-backdrop-filter: blur(18px) saturate(170%);
  backdrop-filter: blur(18px) saturate(170%);
  position: fixed;
  z-index: 9999;
  top: 5%;
  left: 50%;
  transform: translateX(-50%);
  -webkit-transform: translateX(-50%);
  will-change: transform;
  transition: transform 0.3s ease, opacity 0.3s ease, background 0.6s ease, backdrop-filter 0.6s ease, box-shadow 0.6s ease;
  background: var(--nav-bg);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  border: 1px solid var(--card-border);
  display: flex;
  justify-content: center;
  align-items: center;
  width: auto;
  padding: 8px;
  max-width: calc(100vw - 4rem);
  min-width: fit-content;
}
#menu.nav-hidden {
  transform: translate(-50%, -120%);
  opacity: 0;
  pointer-events: none;
}
header #menu .nav-links {
  display: flex;
  gap: 1rem;
  justify-content: center;
  align-items: center;
  position: relative;
}
.nav-cursor {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 100px;
  height: 40px;
  background: var(--nav-cursor-bg);
  border-radius: 22px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07);
  transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  pointer-events: none;
  z-index: -1;
}
header #menu a {
  width: 100px;
  height: 40px;
  text-decoration: none !important;
  border-radius: 22px;
  text-align: center;
  flex-shrink: 0;
  font-size: 12px;
  line-height: 40px;
  color: var(--texte) !important;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: color 0.3s ease, box-shadow 0.3s ease;
  position: relative;
  border-bottom: none !important;
}
header #menu a.active {
  color: var(--texte) !important;
  font-weight: 600;
  text-decoration: none !important;
  border-bottom: none !important;
}
header #menu a:hover:not(.active) {
  background: rgba(255, 255, 255, 0.1) !important;
  border-radius: 22px;
  box-shadow: none;
  color: var(--texte) !important;
  text-decoration: none !important;
  border-bottom: none !important;
}
header #menu div a.active {
  color: var(--texte) !important;
  text-decoration: none !important;
  border-bottom: none !important;
}
header #menu.nav-contrast-dark a,
header #menu.nav-contrast-dark a.active,
header #menu.nav-contrast-dark div a.active,
header #menu.nav-contrast-dark a:hover:not(.active) {
  color: #ffffff !important;
}
header #menu.nav-contrast-dark a:hover:not(.active) {
  background: rgba(255, 255, 255, 0.16) !important;
}
header #menu.nav-contrast-dark .nav-cursor {
  background: rgba(0, 0, 0, 0.35);
}
header #menu.nav-contrast-light a,
header #menu.nav-contrast-light a.active,
header #menu.nav-contrast-light div a.active,
header #menu.nav-contrast-light a:hover:not(.active) {
  color: #10151b !important;
}
header #menu.nav-contrast-light a:hover:not(.active) {
  background: rgba(0, 0, 0, 0.08) !important;
}
header #menu.nav-contrast-light .nav-cursor {
  background: rgba(255, 255, 255, 0.9);
}
body.dark-mode header #menu.nav-contrast-light a,
body.dark-mode header #menu.nav-contrast-light a.active,
body.dark-mode header #menu.nav-contrast-light div a.active,
body.dark-mode header #menu.nav-contrast-light a:hover:not(.active) {
  color: #e6e8eb !important;
}
body.dark-mode header #menu.nav-contrast-light a:hover:not(.active) {
  background: rgba(255, 255, 255, 0.16) !important;
}
body.dark-mode header #menu.nav-contrast-light .nav-cursor {
  background: rgba(50, 60, 75, 0.9);
}
header #menu.sticky {
  background: var(--nav-bg-hover);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  position: fixed;
  z-index: 9999;
}
header #menu.sticky a {
  color: var(--texte);
}
@media only screen and (max-width: 1000px) {
  #menu {
    display: none;
  }
  .dropdown {
    display: block;
    position: fixed;
    top: 5%;
    right: 1rem;
    background: var(--dropdown-bg);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
    border-radius: 22px;
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
    z-index: 9998;
    height: 56px;
    width: 56px;
    transition: transform 0.3s ease, opacity 0.3s ease;
  }
  .dropdown.nav-hidden {
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
  }
  .dropdown-content {
    margin-top: 0.5rem;
    display: none;
    position: absolute;
    background: var(--dropdown-bg);
    z-index: 1;
    border-radius: 22px;
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
    top: 100%;
    right: 0;
    width: 56px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    overflow: hidden;
  }
  .dropdown-content a {
    color: var(--texte);
    height: 56px;
    padding: 0;
    text-decoration: none;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: background 0.2s ease;
  }
  .dropdown-content a:hover {
    background: var(--dropdown-hover);
    color: var(--texte);
  }
  .dropdown:hover .dropdown-content {
    display: block;
    opacity: 1;
    visibility: visible;
  }
  .dropdown.mobile-open .dropdown-content {
    display: block;
    opacity: 1;
    visibility: visible;
  }
  .dropdown.mobile-open .dropbtn {
    background: var(--dropdown-hover);
  }
  .dropbtn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: var(--texte);
    height: 56px;
    width: 100%;
    padding: 0;
    border-radius: 22px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background 0.2s ease;
    -webkit-appearance: none;
    appearance: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }
  .dropdown-content a {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
  }
  .dropbtn:focus,
  .dropbtn:focus-visible,
  .dropbtn:active,
  .dropdown-content a:focus,
  .dropdown-content a:focus-visible,
  .dropdown-content a:active {
    outline: none;
    box-shadow: none;
  }
  .active-flag {
  background: var(--dropdown-hover) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  }
  .active-flag-middle {
  background: var(--dropdown-hover) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,0.08);
  }
}

@media only screen and (max-width: 480px) {
  .dropdown {
    right: 1rem !important;
    height: 56px !important;
    width: 56px !important;
    transition: transform 0.3s ease, opacity 0.3s ease !important;
  }
  .dropdown.nav-hidden {
    transform: translateY(-120%) !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }
  
  .dropbtn {
    height: 56px !important;
    width: 100% !important;
    padding: 0 !important;
    font-size: 12px !important;
  }
  
  .dropdown-content {
    width: 56px !important;
  }
  
  .dropdown-content a {
    height: 56px !important;
    padding: 0 !important;
    font-size: 12px !important;
  }
}
.inside {
  width: 100%;
  max-width: 950px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
}

@media only screen and (max-width: 1024px) {
  .inside {
    min-width: auto;
    max-width: 100%;
    padding: 0 1rem;
  }
}
.tout {
  margin: 0 auto;
  width: 100%;
  max-width: 950px;
  padding-top: 6rem;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.hero {
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  align-items: center;
  width: 950px;
  height: auto;
  padding: 4rem;
  margin-top: 3rem;
  gap: 3rem;
  position: relative;
  border-radius: 8px;
  background: var(--fond);
  border: 1px solid var(--card-border);
  transition: all 0.15s ease;
}

@media only screen and (max-width: 1024px) {
  .hero {
    width: 100%;
    max-width: 950px;
    padding: 2rem;
    gap: 2rem;
  }
}

@media only screen and (max-width: 768px) {
  .hero {
    flex-direction: column;
    padding: 1.5rem;
    gap: 1.5rem;
    margin-top: 2rem;
  }
}

.hero::before {
  content: '';
  position: absolute;
  top: -1px;
  left: -1px;
  right: -1px;
  bottom: -1px;
  background: linear-gradient(135deg, var(--apple-teal) 0%, var(--apple-cyan) 20%, var(--apple-mint) 40%, var(--apple-green) 60%, var(--apple-purple) 80%, var(--apple-violet) 100%);
  background-size: 300% 300%;
  z-index: -1;
  border-radius: 8px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hero:hover::before {
  opacity: 0.6;
  animation: gradientFlow 6s cubic-bezier(0.25, 0.46, 0.45, 0.94) infinite;
}

@keyframes gradientFlow {
  0% {
    background-position: 0% 50%;
  }
  20% {
    background-position: 50% 80%;
  }
  40% {
    background-position: 100% 50%;
  }
  60% {
    background-position: 150% 20%;
  }
  80% {
    background-position: 200% 50%;
  }
  100% {
    background-position: 250% 50%;
  }
}

.hero::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--fond);
  z-index: -1;
  border-radius: 7px;
}

.projet-img {
  padding: 15px;
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  height: 90%;
  max-width: 50%;
  max-height: 100%;
  opacity: 1;
  filter: grayscale(100%);
  transition: all 0.2s cubic-bezier(.32, .52, .56, .4);
}

.projet-img img {
  transition: all 0.15s ease;
}

.hero:hover .projet-img img {
  filter: brightness(1.1) contrast(1.05);
}
.hero:hover .projet-img {
  filter: grayscale(0%);
  transform: translateY(-50%) translateX(3px) scale(1.01);
  transition: all 0.15s cubic-bezier(.32, .52, .56, .4);
}
.hero:hover h1 {
  background: linear-gradient(135deg, var(--apple-violet) 0%, var(--apple-purple) 25%, var(--apple-cyan) 50%, var(--apple-teal) 75%, var(--apple-mint) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  transition: all 0.15s ease;
}
.hero:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
  border: 1px solid transparent;
}

.hero-link {
  text-decoration: none;
  color: inherit;
  display: block;
  transition: all 0.15s ease;
  cursor: pointer;
}

.hero-link:hover {
  text-decoration: none;
  color: inherit;
}

.hero h1 {
  transition: all 0.15s ease;
}
.hero-text {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  gap: 3em;
}
.descr {
  flex-direction: row;
  display: flex;
  font-size: 1rem;
  padding-right: 1rem;
}
.projet-descr {
  padding-right: 0.8rem;
  color: var(--gris);
}

/* Section Dividers */
.section-divider {
  width: 100%;
  margin: 4rem 0 2rem 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.section-divider::before,
.section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--skill-border);
}

.section-category {
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: var(--texte);
  margin: 0;
  padding: 0.5rem 1.5rem;
  background: transparent;
  border: none;
  white-space: nowrap;
}

body.dark-mode .section-category {
  background: transparent;
}

/* Enhanced Project Cards */
.hero-card {
  position: relative;
  width: 950px;
  height: 500px;
  margin-top: 3rem;
  border-radius: 16px;
  background: transparent;
  overflow: hidden;
  transition: box-shadow 0.1s ease;
  --bg-image: none;
}

.hero-card-bg-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
  border-radius: 16px;
  pointer-events: none;
  transform: scale(1);
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

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

.hero-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: var(--bg-image, none);
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transform: scale(1);
  transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 0;
  border-radius: 16px;
  pointer-events: none;
}

.hero-card::after {
  content: '';
  position: absolute;
  top: -1px;
  left: -1px;
  right: -1px;
  bottom: -1px;
  background: rgba(0, 0, 0, 0.1);
  z-index: -1;
  border-radius: 16px;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.hero-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.hero-card:hover::before {
  transform: scale(1.05);
}

.hero-card:hover::after {
  opacity: 1;
}

.hero-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.7) 0%, rgba(0, 0, 0, 0.3) 40%, transparent 70%);
  transition: all 0.3s ease;
  z-index: 1;
}

.hero-card:hover .hero-card-overlay {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0.2) 40%, transparent 70%);
}

.hero-card-content {
  position: absolute;
  top: 2.5rem;
  left: 2.5rem;
  z-index: 2;
}

.hero-card-title {
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  margin: 0 0 1rem 0;
  line-height: 1.1;
  transition: all 0.3s ease;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.hero-card:hover .hero-card-title {
  color: white;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
}

.hero-card-meta {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.hero-card-category,
.hero-card-year,
.hero-card-type {
  display: inline-block;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.95rem;
  font-weight: 500;
  line-height: 1.4;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

.hero-card-category {
  font-weight: 600;
  color: rgba(255, 255, 255, 1);
}

.hero-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

@media only screen and (max-width: 1024px) {
  .hero-card {
    width: 100%;
    max-width: 950px;
    height: 450px;
  }
  
  .hero-card-content {
    top: 2rem;
    left: 2rem;
  }
  
  .hero-card-title {
    font-size: 2.2rem;
  }
}

@media only screen and (max-width: 768px) {
  .hero-card {
    height: 400px;
    margin-top: 2rem;
    border-radius: 12px;
  }
  
  .hero-card::before {
    border-radius: 12px;
  }
  
  .hero-card-content {
    top: 1.5rem;
    left: 1.5rem;
  }
  
  .hero-card-title {
    font-size: 1.8rem;
  }
  
  .hero-card-category,
  .hero-card-year,
  .hero-card-type {
    font-size: 0.85rem;
  }
}

@media only screen and (max-width: 480px) {
  .hero-card {
    height: 350px;
    border-radius: 8px;
  }
  
  .hero-card::before {
    border-radius: 8px;
  }
  
  .hero-card-content {
    top: 1.25rem;
    left: 1.25rem;
  }
  
  .hero-card-title {
    font-size: 1.6rem;
  }
}
.buttons {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  gap: 2em;
}
.button {
  padding: 1em 3em;
  border: 1px solid var(--texte);
  font-size: 15px;
  border-radius: 12px;
}
.primary {
  background-color: var(--texte);
  color: var(--texteblanc);
}
#contact {
  margin-top: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  min-height: 0vh;
}
.contact-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}
.contact-greeting {
  font-size: 1.5rem;
  color: var(--gris);
  margin-bottom: 2rem;
  font-weight: 400;
}
.contact-title-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1.4;
  margin-bottom: 1rem;
}
.contact-emoji {
  font-size: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.main-email {
  margin-bottom: 1rem;
}
.email-link {
  font-size: clamp(1rem, 2.5vw, 2rem);
  font-weight: 600;
  color: var(--texte);
  text-decoration: none;
  border-bottom: none;
  line-height: 1.2;
  transition: all 0.3s ease;
  word-break: break-all;
}
.email-link:hover {
 background: linear-gradient(135deg, var(--apple-teal) 0%, var(--apple-cyan) 25%, var(--apple-cyan) 50%, var(--apple-violet) 75%, var(--apple-purple) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  border-bottom: none;
}
.contact-text {
  margin-bottom: 1rem;
}
.contact-text p {
  font-size: 1.1rem;
  color: var(--gris);
  margin-bottom: 1rem;
}
.cv-link {
  color: var(--texte);
  text-decoration: underline;
  font-weight: 500;
  transition: color 0.3s ease;
}
.cv-link:hover {
  background: linear-gradient(135deg, var(--apple-blue) 0%, var(--apple-teal) 33%, var(--apple-cyan) 66%, var(--apple-mint) 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.social-links {
  display: flex;
  gap: 2rem;
  margin-bottom: 4rem;
}
.social-link {
  color: var(--gris);
  text-decoration: underline;
  font-size: 1rem;
  transition: color 0.3s ease;
}
.social-link:hover {
  color: var(--texte);
}
.copyright {
  margin-top: auto;
}
.copyright p {
  color: var(--gris);
  font-size: 0.9rem;
}
.gras{
  font-weight: 600;
}
.contact {
  display: flex;
  width: 50%;
  align-items: center;
  padding-top: 1rem;
}
.project-date {
  padding-right: 0.4rem;
  color: #0053ad;
}
.project-date-2 {
  padding-right: 0.4rem;
  color: var(--gris);
}
.project-date:hover {
  color: var(--apple-teal);
}
/* SEO-friendly */
.project-links-seo {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.project-links-seo h2,
.project-links-seo ul,
.project-links-seo li,
.project-links-seo a {
  display: block;
}

.footer {
  width: 100%;
  max-width: 950px;
  margin: 4rem auto 0 auto;
  background: var(--footer-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 15px 15px 0 0;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem 2rem 1.5rem 2rem;
  text-align: center;
  position: relative;
}

.footer-taille {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.footer-taille h3 {
  color: var(--texte);
  font-weight: 400;
  line-height: 1.6;
  opacity: 0.7;
  font-size: 0.9rem;
}
@media only screen and (max-width: 1000px) {
  .inside {
      max-width: 100%;
      min-width: auto;
      padding: 1rem;
  }
  .tout {
      padding-top: 6rem;
  }
  .hero {
      flex-direction: column;
      width: 100%;
      padding: 2rem;
      margin-top: 4rem;
      gap: 2rem;
  }
  .projet-img {
      position: static;
      transform: none;
      height: auto;
      max-width: 100%;
      opacity: 1;
      filter: grayscale(0%);
  }
  .hero:hover .projet-img {
      filter: grayscale(0%);
      transform: none;
  }
  .nav-links {
      flex-direction: column;
      gap: 0.5rem;
  }
  .dropdown-content {
      position: static;
      top: auto;
      right: auto;
      width: 100%;
  }
  .list-skills {
      grid-template-columns: 1fr;
  }
  .footer {
      max-width: 100%;
      padding: 1.5rem 1rem 1rem 1rem;
      margin: 3rem auto 0 auto;
  }
}
@media only screen and (max-width: 768px) {
  #work {
    width: 100%;
  }

  .about .skills-professional-container {
    padding: 0;
  }

  #work > .skills-professional-container {
    width: 100%;
    padding: 0;
  }

  #work > .hero-link {
    width: 100%;
  }

  body {
    padding: 0 0.5rem;
    font-size: 0.9rem;
  }

  .section-divider {
    margin: 3rem 0 1.5rem 0;
    padding: 0;
    justify-content: center;
  }

  .section-divider::before,
  .section-divider::after {
    content: none;
    display: none;
  }

  .section-category {
    font-size: 0.9rem;
    letter-spacing: 0.08em;
    padding: 0;
    white-space: normal;
    text-align: center;
    line-height: 1.25;
    max-width: 100%;
  }
  
  header {
      padding: 0 0.5rem;
  }
  .tout {
      padding-top: 1rem;
  }
  #menu {
      width: calc(100% - 1rem);
      padding: 8px;
      top: 3%;
  }
  .hero {
      padding: 1rem;
  }
  .projet-img {
      filter: grayscale(0%);
  }
  .hero:hover .projet-img {
      filter: grayscale(0%);
      transform: none;
  }
  .contact {
      width: 100%;
      flex-direction: column;
      align-items: flex-start;
  }
  .contact-container {
      padding: 0 1rem;
  }
  .contact-greeting {
      font-size: 1.2rem;
      margin-bottom: 2rem;
  }
  
  .skills-description-professional {
    font-size: 1rem;
    line-height: 1.6;
  }
  
  .skills-title-professional {
    font-size: clamp(1.3rem, 5vw, 2.5rem);
    margin-bottom: 0;
  }
  
  .skills-title-professional2 {
    font-size: clamp(1.3rem, 5vw, 2.5rem);
    margin-bottom: 0.4rem;
  }
  
  h3 {
    font-size: 1.1rem;
    line-height: 1.5;
  }
  
  p {
    font-size: 0.9rem;
    line-height: 1.5;
  }
  
  .hero-subtitle {
    font-size: 1rem;
    line-height: 1.5;
  }
  
  .main-email {
      margin-bottom: 3rem;
  }
  .email-link {
      font-size: clamp(0.9rem, 4vw, 1.5rem);
  }
  .social-links {
      flex-direction: column;
      gap: 1rem;
      margin-bottom: 2rem;
  }
  .footer {
      padding: 1.5rem 1rem 1rem 1rem;
  }
}
@media only screen and (max-width: 480px) {
  h1, h2, h3, h4 {
      font-size: 0.9rem;
  }

  .section-category {
    font-size: 0.82rem;
    letter-spacing: 0.06em;
  }

  .hero {
      padding: 0.5rem;
  }
  .buttons {
      flex-direction: column;
      gap: 1em;
  }
  .button {
      padding: 0.8em 2em;
  }
  .footer {
      padding: 1.2rem 0.8rem 0.8rem 0.8rem;
      margin: 2rem auto 0 auto;
  }
}
.burger-menu {
  display: none;
  flex-direction: column;
  justify-content: space-around;
  width: 30px;
  height: 24px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 10;
}
.burger-line {
  width: 30px;
  height: 3px;
  background: var(--texte);
  display: block;
  border-radius: 3px;
  transition: all 0.3s ease;
}
.burger-menu.active .burger-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.burger-menu.active .burger-line:nth-child(2) {
  opacity: 0;
}
.burger-menu.active .burger-line:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}
@media only screen and (max-width: 768px) {
  .nav-links {
      display: none;
      flex-direction: column;
      width: 100%;
  }
  .nav-links.active {
      display: flex;
  }
  .burger-menu {
      display: flex;
  }
  header {
      flex-direction: column;
      align-items: flex-start;
  }
  #menu {
      width: 100%;
  }
}
.links:hover{
  color: var(--apple-teal);
}
.contact-me {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: start;
  width: 100%;
  padding-top: 2rem;
  gap: 1rem;
}
.italique {
  font-style: normal;
  padding-bottom: 2rem;
}
.blur-background {
  position: relative;
  width: 200px;
  height: 60px;
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border-radius: 15px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.1s;
  cursor: pointer;
  transition: 0.6 ease;
}
.blur-background:hover {
  transform: scale(1.05);
}
.blur-background:active {
  transform: scale(0.95);
}
.button-text {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  color: #000000;
  font-size: 16px;
  font-weight: 600;
  background: none;
  border: none;
  cursor: pointer;
}

/* Sticky footer */
html, body {
  height: 100%;
}
.inside {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.tout {
  flex: 1 0 auto;
  display: flex;
  flex-direction: column;
}
.footer {
  margin-top: auto;
}

/* Contact Section */

#contact {
    padding: 4rem 2rem;
    text-align: center;
    width: 100%;
    max-width: 950px;
    margin: 2rem auto;
    border-radius: 15px;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.contact-container {
    max-width: 600px;
    margin: 0 auto;
}

.contact-title {
    font-size: 2.5rem;
    font-weight: 650;
    color: var(--texte);
    margin-bottom: 0;
    text-align: center;
}

.contact-description {
    font-size: 1.1rem;
    color: var(--grishover);
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

.contact-email-button {
    display: inline-block;
    background-color: transparent;
    color: var(--bleu);
    padding: 1rem 2.5rem;
    border: 2px solid var(--bleu);
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    letter-spacing: 0.01em;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.contact-email-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--bleu);
    transition: left 0.3s ease;
    z-index: -1;
}

.contact-email-button:hover {
    color: var(--texteblanc);
    border-color: var(--bleu);
}

.contact-email-button:hover::before {
    left: 0;
}

.contact-socials {
    margin-top: 3rem;
    display: flex;
    justify-content: center;
    gap: 2rem;
}

.contact-socials .social-link {
    color: var(--gris);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.contact-socials .social-link:hover {
    color: var(--texte);
    text-decoration: underline;
}

.hero-main { align-items: center; text-align: center; min-height: 15vh; }
.hero-content { display: flex; flex-direction: column; align-items: center; gap: 0.5rem; }

.hero-main::before {
  content: '';
  position: absolute;
  top: 5%;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 900px);
  height: 50%;
  pointer-events: none;
  z-index: -2;
}

.hero-greeting { margin-bottom: 0.75rem; }
.hero-name { background-size: 200% 200%; animation: gradientShift 12s ease-in-out infinite; }

.hero-typewriter {
  font-size: clamp(1.1rem, 2.4vw, 1.4rem); 
  color: var(--texte); 
  margin-bottom: 1.25rem; 
  min-height: 2rem; 
  display: flex; 
  align-items: center; 
  gap: 0.2rem; 
}

.typewriter-text 
{ font-weight: 600; 
  background-image: linear-gradient(90deg, var(--apple-teal), var(--apple-cyan), var(--apple-violet)); background-position: 0 100%; 
  background-repeat: no-repeat; 
  background-size: 100% 0.12em; 
  padding-bottom: 0.2em; 
}
.cursor { font-weight: 500; 
}

.hero-content > * { opacity: 0; transform: translateY(6px); animation: fadeUp 0.8s ease forwards; }
.hero-content > *:nth-child(1) { animation-delay: 0.05s; }
.hero-content > *:nth-child(2) { animation-delay: 0.15s; }
.hero-content > *:nth-child(3) { animation-delay: 0.30s; }
.hero-content > *:nth-child(4) { animation-delay: 0.45s; }

@keyframes gradientShift { 0% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } 100% { background-position: 0% 50%; } }
@keyframes drift { 0% { transform: translateX(-50%) translateY(0); } 50% { transform: translateX(-50%) translateY(10px); } 100% { transform: translateX(-50%) translateY(0); } }
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

@media only screen and (max-width: 768px) {
  .hero-main { min-height: 20vh; }
  .hero-typewriter { margin-bottom: 1.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-content > * { animation: none; opacity: 1; transform: none; }
  .hero-name { animation: none; }
  .hero-main::before { animation: none; }
  .cursor { animation: none; }
}

/* Loading Screen */
.loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--fond);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10000;
  opacity: 1;
  transition: opacity 0.6s ease-out;
}

.loading-screen.hidden {
  opacity: 0;
  pointer-events: none;
}

.loading-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2rem;
}

.loading-logo {
  width: 120px;
  height: auto;
  max-height: 120px;
  object-fit: contain;
  animation: logoFloat 2s ease-in-out infinite;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.1));
}

@keyframes logoFloat {
  0%, 100% {
    transform: translateY(0px) scale(1);
    opacity: 1;
  }
  50% {
    transform: translateY(-10px) scale(1.05);
    opacity: 0.9;
  }
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(38, 54, 60, 0.1);
  border-top-color: var(--apple-teal);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

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

/* Disable scrolling during loading */
html.loading,
body.loading {
  overflow: hidden;
  height: 100%;
}

/* Hide main content during loading */
body.loading .inside {
  opacity: 0;
  pointer-events: none;
}

@media (prefers-reduced-motion: reduce) {
  .loading-logo {
    animation: none;
    transform: none;
  }
  .loading-spinner {
    animation: none;
  }
}

/* Dark Mode Toggle Button */
.dark-mode-toggle {
  position: fixed;
  top: 5%;
  right: calc(max(1rem, min(2rem, calc((100vw - 100px) / 2))) + 70px);
  display: inline-block;
  background: var(--dropdown-bg);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
  border-radius: 22px;
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  backdrop-filter: blur(20px) saturate(180%);
  z-index: 10040;
  height: 56px;
  width: 58px;
  transition: transform 0.3s ease, opacity 0.3s ease;
  border: none;
  cursor: pointer;
  pointer-events: auto;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  -webkit-appearance: none;
  appearance: none;
  outline: none;
}

.dark-mode-toggle:focus,
.dark-mode-toggle:focus-visible,
.dark-mode-toggle:active {
  outline: none;
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.06);
}

.dark-mode-toggle.nav-hidden {
  transform: translateY(-120%);
  opacity: 0;
  pointer-events: none;
}

.dark-mode-toggle:hover {
  background: var(--dropdown-hover);
}

.dark-mode-toggle,
.ai-assistant-bar__shell,
.ai-assistant-bar__send,
.ai-assistant-bar__chip {
  -webkit-tap-highlight-color: transparent;
}

@media (hover: none), (pointer: coarse) {
  .dark-mode-toggle:focus,
  .dark-mode-toggle:focus-visible,
  .dark-mode-toggle:active,
  .ai-assistant-bar__shell:focus,
  .ai-assistant-bar__shell:focus-visible,
  .ai-assistant-bar__shell:active,
  .ai-assistant-bar__send:focus,
  .ai-assistant-bar__send:focus-visible,
  .ai-assistant-bar__send:active,
  .ai-assistant-bar__chip:focus,
  .ai-assistant-bar__chip:focus-visible,
  .ai-assistant-bar__chip:active {
    outline: none !important;
    box-shadow: none !important;
  }
}

.dark-mode-toggle svg,
.dark-mode-toggle img {
  width: 24px;
  height: 24px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.dark-mode-toggle .sun-icon {
  filter: invert(0);
}

body.dark-mode .dark-mode-toggle .sun-icon {
  filter: invert(1);
}

.dark-mode-toggle .moon-icon {
  fill: var(--texte);
  stroke: none;
}

.dark-mode-toggle .sun-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.dark-mode-toggle .moon-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

body:not(.dark-mode) .dark-mode-toggle .sun-icon {
  opacity: 1;
}

body:not(.dark-mode) .dark-mode-toggle .moon-icon {
  opacity: 0;
}

body.dark-mode .dark-mode-toggle .sun-icon {
  opacity: 0;
}

body.dark-mode .dark-mode-toggle .moon-icon {
  opacity: 1;
}

@media only screen and (max-width: 1000px) {
  .dark-mode-toggle {
    right: calc(1rem + 62px);
    width: 56px;
    height: 56px;
  }
}

@media only screen and (max-width: 480px) {
  .dark-mode-toggle {
    right: calc(1rem + 62px) !important;
    width: 56px !important;
    height: 56px !important;
  }
}

/* === AI ASSISTANT BAR === */
.ai-assistant-bar {
  --ai-bar-collapsed-width: 360px;
  --ai-bar-expanded-width: 640px;
  --ai-bar-collapsed-height: 42px;
  --ai-bar-expanded-height: 52px;
  --ai-response-max-height: min(42vh, 360px);
  --ai-response-max-height-long: min(72vh, 620px);
  --ai-response-max-height-mobile: clamp(180px, calc(var(--ai-bar-vv-height, 100vh) - 250px), 58vh);
  --ai-response-max-height-mobile-long: clamp(240px, calc(var(--ai-bar-vv-height, 100vh) - 210px), 72vh);
  --ai-bar-vv-offset: 0px;
  --ai-bar-vv-height: 100vh;
  --ai-bar-bottom: calc(24px + env(safe-area-inset-bottom, 0px) + var(--ai-bar-vv-offset));
  --ai-bar-bottom: calc(24px + env(safe-area-inset-bottom, 0px) + max(0px, calc(100vh - 100dvh)) + var(--ai-bar-vv-offset));
  --ai-text: var(--texte);
  --ai-surface: var(--nav-bg);
  --ai-surface-strong: var(--nav-bg);
  --ai-surface-hover: rgba(255, 255, 255, 0.1);
  --ai-rainbow-fill: #f8fafc;
  --ai-border: var(--card-border);
  --ai-cta-surface: var(--nav-bg-hover);
  --ai-cta-hover: var(--dropdown-hover);
  --ai-local-text: var(--ai-text);
  --ai-local-surface: var(--ai-surface);
  --ai-local-surface-strong: var(--ai-surface-strong);
  --ai-local-surface-hover: var(--ai-surface-hover);
  --ai-local-border: var(--ai-border);
  --ai-local-cta-surface: var(--ai-cta-surface);
  --ai-local-cta-hover: var(--ai-cta-hover);
  position: fixed;
  right: 0;
  bottom: 0;
  width: 0;
  height: 0;
  z-index: 10030;
  pointer-events: auto;
}

.ai-assistant-bar.is-expanded {
  inset: 0;
  right: auto;
  bottom: auto;
  width: auto;
  height: auto;
  z-index: 10050;
}

.ai-assistant-bar.ai-contrast-dark {
  --ai-text: #ffffff;
  --ai-surface-hover: rgba(255, 255, 255, 0.16);
  --ai-rainbow-fill: #101620;
  --ai-cta-surface: rgba(255, 255, 255, 0.12);
  --ai-cta-hover: rgba(255, 255, 255, 0.2);
}

.ai-assistant-bar.ai-contrast-light {
  --ai-text: #10151b;
  --ai-surface-hover: rgba(0, 0, 0, 0.08);
  --ai-rainbow-fill: #f8fafc;
  --ai-cta-surface: rgba(0, 0, 0, 0.06);
  --ai-cta-hover: rgba(0, 0, 0, 0.12);
}

body.dark-mode .ai-assistant-bar.ai-contrast-light {
  --ai-text: #e6e8eb;
  --ai-surface-hover: rgba(255, 255, 255, 0.16);
  --ai-rainbow-fill: #1d232d;
  --ai-cta-surface: rgba(255, 255, 255, 0.12);
  --ai-cta-hover: rgba(255, 255, 255, 0.2);
}

.ai-assistant-bar .ai-local-contrast-dark {
  --ai-local-text: #ffffff;
  --ai-local-surface-hover: rgba(255, 255, 255, 0.16);
  --ai-local-cta-surface: rgba(255, 255, 255, 0.12);
  --ai-local-cta-hover: rgba(255, 255, 255, 0.2);
}

.ai-assistant-bar .ai-local-contrast-light {
  --ai-local-text: #10151b;
  --ai-local-surface-hover: rgba(0, 0, 0, 0.08);
  --ai-local-cta-surface: rgba(0, 0, 0, 0.06);
  --ai-local-cta-hover: rgba(0, 0, 0, 0.12);
}

body.dark-mode .ai-assistant-bar .ai-local-contrast-light {
  --ai-local-text: #e6e8eb;
  --ai-local-surface-hover: rgba(255, 255, 255, 0.16);
  --ai-local-cta-surface: rgba(255, 255, 255, 0.12);
  --ai-local-cta-hover: rgba(255, 255, 255, 0.2);
}

.ai-assistant-bar__backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  opacity: 0;
  pointer-events: none;
  background: rgba(0, 0, 0, 0.06);
  -webkit-backdrop-filter: blur(4px) saturate(110%);
  backdrop-filter: blur(4px) saturate(110%);
  transition: opacity 200ms ease;
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__backdrop {
  opacity: 1;
  pointer-events: auto;
}

.ai-assistant-bar__stack {
  position: fixed;
  left: 50%;
  bottom: var(--ai-bar-bottom);
  z-index: 1;
  transform: translateX(-50%) translateY(16px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  opacity: 0;
  pointer-events: auto;
}

/* Delay entrance so the hero lands first and the bar reveals calmly after. */
.ai-assistant-bar.is-ready .ai-assistant-bar__stack {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  transition: transform 260ms ease-out, opacity 260ms ease-out;
}

.ai-assistant-bar.nav-hidden .ai-assistant-bar__stack {
  opacity: 0;
  transform: translateX(-50%) translateY(16px);
  pointer-events: none;
}

@media only screen and (min-width: 769px) {
  .ai-assistant-bar {
    --ai-bar-collapsed-width: 58px;
    --ai-bar-collapsed-height: 56px;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__stack {
    left: auto;
    right: max(1rem, min(2rem, calc((100vw - 100px) / 2)));
    transform: translateY(16px);
    align-items: flex-end;
    transition: transform 260ms ease-out, opacity 260ms ease-out;
  }

  .ai-assistant-bar.is-ready:not(.is-expanded) .ai-assistant-bar__stack {
    transform: translateY(0);
  }

  .ai-assistant-bar.nav-hidden:not(.is-expanded) .ai-assistant-bar__stack {
    transform: translateY(16px);
  }

  .ai-assistant-bar.is-expanded .ai-assistant-bar__stack {
    left: 50%;
    right: auto;
    transform: translateX(-50%) translateY(0);
    align-items: center;
    transition: transform 290ms cubic-bezier(0.22, 0.9, 0.3, 1), opacity 240ms ease-out;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell {
    width: fit-content;
    min-width: var(--ai-bar-collapsed-width);
    max-width: var(--ai-bar-collapsed-width);
    justify-content: flex-start;
    gap: 0;
    padding: 0 20px;
    overflow: hidden;
    transition: max-width 290ms cubic-bezier(0.22, 0.9, 0.3, 1), border-radius 290ms cubic-bezier(0.22, 0.9, 0.3, 1), box-shadow 200ms ease;
    will-change: max-width;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__icon svg {
    width: 18px;
    height: 18px;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__form {
    flex: 0 1 auto;
    width: auto;
    max-width: 0;
    min-width: 0;
    opacity: 0;
    pointer-events: none;
    overflow: hidden;
    margin-left: 0;
    transition: opacity 190ms ease-out, max-width 290ms cubic-bezier(0.22, 0.9, 0.3, 1);
    will-change: max-width, opacity;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__placeholder {
    opacity: 0;
    text-align: left;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__send {
    display: none;
  }
}

@media only screen and (min-width: 769px) and (hover: hover) and (pointer: fine) {
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:focus-visible,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek {
    width: fit-content;
    max-width: min(var(--ai-bar-expanded-width), calc(100vw - 32px));
    gap: 16px;
    padding: 0 32px 0 24px;
    justify-content: flex-start;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover .ai-assistant-bar__form,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:focus-visible .ai-assistant-bar__form,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek .ai-assistant-bar__form {
    flex: 0 1 auto;
    width: auto;
    max-width: calc(var(--ai-bar-expanded-width) - 90px);
    opacity: 1;
    margin-left: 0;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover .ai-assistant-bar__placeholder,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:focus-visible .ai-assistant-bar__placeholder,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek .ai-assistant-bar__placeholder {
    width: auto;
    opacity: 1;
    text-align: left;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover .ai-assistant-bar__icon,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:focus-visible .ai-assistant-bar__icon,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek .ai-assistant-bar__icon {
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover .ai-assistant-bar__icon svg,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:focus-visible .ai-assistant-bar__icon svg,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek .ai-assistant-bar__icon svg {
    width: 16px;
    height: 16px;
  }
}

.ai-assistant-bar__response-slot {
  width: var(--ai-bar-expanded-width);
  max-width: calc(100vw - 32px);
  margin-bottom: 10px;
  min-height: 0;
  max-height: var(--ai-response-max-height);
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  border-radius: 22px;
  border: 1px solid color-mix(in srgb, var(--ai-local-text, var(--ai-text)) 10%, transparent);
  background: color-mix(in srgb, var(--ai-local-surface, var(--ai-surface)) 90%, transparent);
  -webkit-backdrop-filter: blur(18px) saturate(170%);
  backdrop-filter: blur(18px) saturate(170%);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  opacity: 0;
  transform: translateY(8px);
  transform-origin: center bottom;
  pointer-events: none;
  transition: opacity 175ms ease, transform 175ms ease, margin-bottom 175ms ease;
}

.ai-assistant-bar.has-long-response .ai-assistant-bar__response-slot {
  max-height: var(--ai-response-max-height-long);
}

.ai-assistant-bar.is-expanded.has-response .ai-assistant-bar__response-slot {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.ai-assistant-bar.is-overlay-closing.has-response .ai-assistant-bar__response-slot {
  opacity: 0;
  transform: translateY(24px);
  margin-bottom: 0;
  pointer-events: none;
}

.ai-assistant-bar__chips {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  width: var(--ai-bar-expanded-width);
  max-width: calc(100vw - 32px);
  gap: 8px;
  margin-bottom: 12px;
  opacity: 0;
  transform: translateY(8px);
  transform-origin: center bottom;
  pointer-events: none;
  transition: opacity 175ms ease, transform 175ms ease, margin-bottom 175ms ease;
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__chips {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.ai-assistant-bar.is-overlay-closing .ai-assistant-bar__chips {
  opacity: 0;
  transform: translateY(20px);
  margin-bottom: 0;
  pointer-events: none;
}

.ai-assistant-bar__disclaimer {
  width: var(--ai-bar-expanded-width);
  max-width: calc(100vw - 32px);
  margin: 8px 0 0;
  padding: 0 2px;
  font-size: 12px;
  line-height: 1.35;
  font-family: inherit;
  font-weight: 400;
  letter-spacing: 0.005em;
  text-align: left;
  color: var(--ai-local-text, var(--ai-text));
  opacity: 0;
  transform: translateY(6px);
  transform-origin: center bottom;
  pointer-events: none;
  transition: opacity 175ms ease, transform 175ms ease, margin 175ms ease;
}

.ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__disclaimer {
  display: none;
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__disclaimer {
  opacity: 0.72;
  transform: translateY(0);
}

.ai-assistant-bar.is-overlay-closing .ai-assistant-bar__disclaimer {
  opacity: 0;
  transform: translateY(14px);
  margin: 0;
  pointer-events: none;
}

body.dark-mode .ai-assistant-bar.is-expanded .ai-assistant-bar__disclaimer {
  opacity: 0.8;
}

.ai-assistant-bar__chip {
  border: 1px solid var(--ai-local-border, var(--ai-border));
  border-radius: 12px;
  background: var(--ai-local-surface-strong, var(--ai-surface-strong));
  -webkit-backdrop-filter: blur(18px) saturate(170%);
  backdrop-filter: blur(18px) saturate(170%);
  color: var(--ai-local-text, var(--ai-text));
  font-size: 0.8rem;
  line-height: 1.2;
  padding: 10px 16px;
  white-space: nowrap;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  transition: background-color 120ms ease, border-color 120ms ease, box-shadow 120ms ease;
}

.ai-assistant-bar__chip:hover,
.ai-assistant-bar__chip:focus-visible {
  border-color: var(--ai-local-border, var(--ai-border));
  background: var(--ai-local-surface-hover, var(--ai-surface-hover));
  box-shadow: none;
  outline: none;
}

.ai-assistant-bar__shell {
  width: var(--ai-bar-collapsed-width);
  max-width: calc(100vw - 32px);
  height: var(--ai-bar-collapsed-height);
  border-radius: 999px;
  border: 1px solid var(--ai-local-border, var(--ai-border));
  background: var(--ai-local-surface, var(--ai-surface));
  -webkit-backdrop-filter: blur(18px) saturate(170%);
  backdrop-filter: blur(18px) saturate(170%);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
  color: var(--ai-local-text, var(--ai-text));
  display: flex;
  align-items: center;
  gap: 0.42rem;
  padding: 0 0.72rem;
  pointer-events: auto;
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  outline: none;
  
}

.ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell {
  opacity: 0.8;
  cursor: pointer;
}

.ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover {
  opacity: 0.95;
}

.ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek-instant,
.ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek-instant .ai-assistant-bar__form,
.ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek-instant .ai-assistant-bar__placeholder {
  transition: none !important;
}

@media (hover: hover) and (pointer: fine) {
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell.is-intro-peek {
    border-color: transparent;
    background-image:
      linear-gradient(var(--ai-rainbow-fill), var(--ai-rainbow-fill)),
      linear-gradient(110deg, #4285f4, #34a853, #fbbc05, #ea4335, #a142f4, #4285f4);
    background-origin: border-box, border-box;
    background-clip: padding-box, border-box;
    background-size: 100% 100%, 220% 220%;
    background-position: 0 0, 0% 50%;
    animation: aiBarRainbowStroke 1.6s linear infinite;
  }
}

@media (hover: none), (pointer: coarse) {
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:active,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:focus-visible {
    border-color: var(--ai-local-border, var(--ai-border)) !important;
    background: var(--ai-local-surface, var(--ai-surface)) !important;
    animation: none !important;
  }
}

/* Use a smooth ease-out curve for fluid open/close in both directions. */
.ai-assistant-bar__shell {
  transition:
    width 305ms cubic-bezier(0.22, 0.9, 0.3, 1),
    height 305ms cubic-bezier(0.22, 0.9, 0.3, 1),
    border-radius 290ms cubic-bezier(0.22, 0.9, 0.3, 1),
    box-shadow 200ms ease;
  will-change: width, height, border-radius;
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__shell {
  width: var(--ai-bar-expanded-width);
  height: var(--ai-bar-expanded-height);
}

.ai-assistant-bar.is-expanded.has-response .ai-assistant-bar__shell {
  border-color: var(--ai-local-border, var(--ai-border));
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.ai-assistant-bar__shell:focus-visible {
  outline: none;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

.ai-assistant-bar__shell:focus,
.ai-assistant-bar__input:focus,
.ai-assistant-bar-card__cta:focus {
  outline: none;
}

.ai-assistant-bar__input:focus-visible {
  outline: none;
}

.ai-assistant-bar-card__cta:focus-visible {
  outline: none;
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--apple-cyan) 55%, transparent);
}

.ai-assistant-bar__icon {
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--ai-local-text, var(--ai-text));
  user-select: none;
  pointer-events: none;
}

.ai-assistant-bar__icon svg {
  width: 16px;
  height: 16px;
  display: block;
}

.ai-assistant-bar__form {
  position: relative;
  flex: 1;
  min-width: 0;
  height: 100%;
  display: flex;
  align-items: center;
}

.ai-assistant-bar__placeholder {
  width: 100%;
  text-align: center;
  font-size: 0.86rem;
  color: var(--ai-local-text, var(--ai-text));
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: opacity 180ms ease;
}

.ai-assistant-bar__input {
  position: absolute;
  inset: 0;
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--ai-local-text, var(--ai-text));
  font-size: 16px;
  text-align: left;
  padding-left: 12px;
  padding-right: 42px;
  opacity: 0;
  pointer-events: none;
  outline: none;
}

.ai-assistant-bar__input::placeholder {
  color: color-mix(in srgb, var(--ai-local-text, var(--ai-text)) 52%, transparent);
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__placeholder {
  opacity: 0;
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__input {
  opacity: 1;
  pointer-events: auto;
  cursor: text;
}

.ai-assistant-bar__send {
  width: 24px;
  height: 24px;
  border: 1px solid var(--ai-local-border, var(--ai-border));
  border-radius: 999px;
  background: var(--ai-local-cta-surface, var(--ai-cta-surface));
  color: var(--ai-local-text, var(--ai-text));
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  z-index: 2;
  padding: 0;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.92);
  transition: opacity 140ms ease, transform 140ms ease, background 140ms ease;
}

.ai-assistant-bar__send-icon {
  width: 13px;
  height: 13px;
  flex: 0 0 13px;
  display: block;
  object-fit: contain;
  pointer-events: none;
  filter: none;
  transition: filter 140ms ease;
}

body.dark-mode .ai-assistant-bar__send-icon,
.ai-assistant-bar.ai-contrast-dark .ai-assistant-bar__send-icon,
.ai-assistant-bar .ai-local-contrast-dark .ai-assistant-bar__send-icon {
  filter: brightness(0) saturate(100%) invert(1);
}

.ai-assistant-bar__send:hover {
  background: var(--ai-local-cta-hover, var(--ai-cta-hover));
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__send {
  opacity: 1;
  pointer-events: auto;
  transform: scale(1);
}

.ai-assistant-bar.is-expanded .ai-assistant-bar__send:disabled {
  opacity: 0.46;
  pointer-events: none;
  cursor: default;
  transform: scale(1);
  background: color-mix(in srgb, var(--ai-local-cta-surface, var(--ai-cta-surface)) 78%, transparent);
  color: color-mix(in srgb, var(--ai-local-text, var(--ai-text)) 54%, transparent);
}

.ai-assistant-bar-card {
  border-radius: inherit;
  border: 0;
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
  box-shadow: none;
  padding: 0.84rem 0.95rem 0.86rem;
  color: var(--ai-local-text, var(--ai-text));
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 200ms ease, transform 200ms ease;
}

.ai-assistant-bar-card.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.ai-assistant-bar-card__question {
  margin: 0;
  font-size: 11px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ai-local-text, var(--ai-text));
  opacity: 0.64;
}

.ai-assistant-bar-card__answer {
  margin: 0.65rem 0 0;
  font-size: 16px;
  line-height: 1.5;
  color: var(--ai-local-text, var(--ai-text));
  opacity: 0.92;
  overflow-wrap: anywhere;
  word-break: break-word;
  max-height: none;
  overflow: visible;
  padding-right: 0;
}

.ai-assistant-bar-card__answer strong {
  font-weight: 700;
  color: inherit;
}

.ai-assistant-bar-loader {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
}

.ai-assistant-bar-loader__dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--apple-cyan) 70%, white 30%);
  animation: aiBarDotPulse 600ms ease-in-out infinite;
}

.ai-assistant-bar-loader__dot:nth-child(2) {
  animation-delay: 100ms;
}

.ai-assistant-bar-loader__dot:nth-child(3) {
  animation-delay: 200ms;
}

.ai-assistant-bar-card__divider {
  margin: 0.62rem 0 0.56rem;
  height: 1px;
  background: color-mix(in srgb, var(--ai-local-text, var(--ai-text)) 14%, transparent);
}

.ai-assistant-bar-card__cta {
  display: inline-block;
  background-color: transparent;
  color: var(--bleu);
  padding: 0.64rem 1.55rem;
  border: 2px solid var(--bleu);
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
  letter-spacing: 0.01em;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
  cursor: pointer;
}

.ai-assistant-bar-card__cta::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--bleu);
  transition: left 0.3s ease;
  z-index: -1;
}

.ai-assistant-bar-card__cta span {
  position: relative;
  z-index: 1;
}

.ai-assistant-bar-card__cta:hover {
  color: var(--texteblanc);
  border-color: var(--bleu);
}

.ai-assistant-bar-card__cta:hover::before {
  left: 0;
}

.ai-assistant-bar.ai-contrast-dark .ai-assistant-bar-card__cta,
.ai-assistant-bar-card__cta.ai-local-contrast-dark {
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.86);
}

.ai-assistant-bar.ai-contrast-dark .ai-assistant-bar-card__cta::before,
.ai-assistant-bar-card__cta.ai-local-contrast-dark::before {
  background: #ffffff;
}

.ai-assistant-bar.ai-contrast-dark .ai-assistant-bar-card__cta:hover,
.ai-assistant-bar-card__cta.ai-local-contrast-dark:hover {
  color: #10151b;
  border-color: #ffffff;
}

.ai-assistant-bar-card__cta svg {
  display: none;
}

.hero-card.ai-assistant-highlight {
  animation: aiAssistantCardHighlight 1.25s ease;
}

@keyframes aiAssistantCardHighlight {
  0% {
    box-shadow: 0 0 0 color-mix(in srgb, var(--apple-cyan) 0%, transparent);
  }
  45% {
    box-shadow:
      0 0 0 2px color-mix(in srgb, var(--apple-cyan) 45%, transparent),
      0 16px 34px color-mix(in srgb, var(--apple-cyan) 28%, transparent);
  }
  100% {
    box-shadow: 0 0 0 color-mix(in srgb, var(--apple-cyan) 0%, transparent);
  }
}

@keyframes aiBarDotPulse {
  0%,
  100% {
    opacity: 0.35;
    transform: scale(0.75);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

@keyframes aiBarRainbowStroke {
  0% {
    background-position: 0 0, 0% 50%;
  }
  100% {
    background-position: 0 0, 200% 50%;
  }
}

@media only screen and (max-width: 768px) {
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__backdrop {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
  }

  .ai-assistant-bar.is-expanded .ai-assistant-bar__backdrop {
    display: block;
  }

  .ai-assistant-bar {
    --ai-bar-collapsed-width: 56px;
    --ai-bar-collapsed-height: 56px;
    --ai-bar-expanded-width: calc(100vw - 16px);
    --ai-bar-expanded-width: calc(100svw - 16px);
    --ai-bar-expanded-height: 52px;
    --ai-bar-bottom: calc(4px + max(0px, calc(env(safe-area-inset-bottom, 0px) - 20px)) + var(--ai-bar-vv-offset));
  }

  .ai-assistant-bar:not(.is-expanded) {
    --ai-bar-bottom: calc(10px + max(0px, calc(env(safe-area-inset-bottom, 0px) - 20px)));
    inset: auto;
    left: 0;
    bottom: 0;
    width: 0;
    height: 0;
  }

  .ai-assistant-bar__stack {
    left: auto;
    right: 8px;
    transform: translateY(16px);
    align-items: flex-end;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__stack {
    right: 1rem;
  }

  .ai-assistant-bar__response-slot,
  .ai-assistant-bar__chips,
  .ai-assistant-bar__disclaimer,
  .ai-assistant-bar__shell {
    max-width: calc(100vw - 16px);
  }

  .ai-assistant-bar__shell {
    flex: 0 0 auto;
    transition:
      width 305ms cubic-bezier(0.22, 0.9, 0.3, 1),
      height 305ms cubic-bezier(0.22, 0.9, 0.3, 1),
      border-radius 290ms cubic-bezier(0.22, 0.9, 0.3, 1),
      box-shadow 200ms ease;
  }

  .ai-assistant-bar.is-ready .ai-assistant-bar__stack {
    transform: translateY(0);
  }

  .ai-assistant-bar.nav-hidden .ai-assistant-bar__stack {
    transform: translateY(16px);
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell {
    width: var(--ai-bar-collapsed-width);
    max-width: var(--ai-bar-collapsed-width);
    height: var(--ai-bar-collapsed-height);
    justify-content: center;
    gap: 0;
    padding: 0;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__form,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__send {
    display: none;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__response-slot,
  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__chips {
    display: none;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__icon {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__icon svg {
    width: 18px;
    height: 18px;
  }

  .ai-assistant-bar.is-expanded .ai-assistant-bar__stack {
    align-items: stretch;
    width: var(--ai-bar-expanded-width);
    max-width: calc(100vw - 16px);
    height: auto;
    min-height: 0;
    max-height: calc(var(--ai-bar-vv-height, 100vh) - env(safe-area-inset-top, 0px) - 8px);
    overflow: hidden;
    justify-content: flex-end;
  }

  .ai-assistant-bar.is-expanded .ai-assistant-bar__shell {
    width: var(--ai-bar-expanded-width);
    min-width: var(--ai-bar-expanded-width);
    max-width: var(--ai-bar-expanded-width);
    height: var(--ai-bar-expanded-height);
    min-height: var(--ai-bar-expanded-height);
  }

  .ai-assistant-bar__response-slot {
    max-height: min(var(--ai-response-max-height-mobile), calc(var(--ai-bar-vv-height, 100vh) - 240px));
  }

  .ai-assistant-bar.is-expanded.has-long-response .ai-assistant-bar__chips {
    display: none;
  }

  .ai-assistant-bar.has-long-response .ai-assistant-bar__response-slot {
    max-height: min(var(--ai-response-max-height-mobile-long), calc(var(--ai-bar-vv-height, 100vh) - env(safe-area-inset-top, 0px) - 74px));
  }

  .ai-assistant-bar-card__answer {
    max-height: none;
    overflow: visible;
  }

  .ai-assistant-bar__chips {
    flex-wrap: wrap;
    max-width: calc(100vw - 16px);
  }

  .ai-assistant-bar__chip {
    white-space: normal;
    text-align: center;
  }

  .ai-assistant-bar.is-expanded .ai-assistant-bar__send {
    opacity: 1;
    pointer-events: auto;
    transform: scale(1);
  }
}

@media (prefers-reduced-motion: reduce) {
  .ai-assistant-bar__backdrop,
  .ai-assistant-bar__stack,
  .ai-assistant-bar__shell,
  .ai-assistant-bar__chips,
  .ai-assistant-bar__disclaimer,
  .ai-assistant-bar__response-slot,
  .ai-assistant-bar-card,
  .ai-assistant-bar__placeholder {
    transition: none;
  }

  .ai-assistant-bar:not(.is-expanded) .ai-assistant-bar__shell:hover {
    animation: none;
  }

  .hero-card.ai-assistant-highlight {
    animation: none;
  }
}