.content-area {
    flex: 1;
    background: white;
    padding: 40px;

    height: 100%;
    min-height: 0;
    overflow-y: auto; /* scroll uniquement ici */
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-bottom: 48px;
}

.project-card { cursor: pointer; }

.project-image {
    width: 100%;
    aspect-ratio: 13 / 8;      /* ✅ ratio 1300x800 */
    height: auto;              /* ✅ plus de hauteur fixe */
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
    background: #f3f4f6;
}


.airbnb-img {
    background: linear-gradient(135deg, #059669 0%, #10b981 50%, #34d399 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.airbnb-logo {
    width: 128px;
    height: 128px;
    background: linear-gradient(135deg, #f472b6 0%, #ec4899 100%);
    border-radius: 16px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
}

.spotify-img {
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 50%, #fbbf24 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.spotify-headphones {
    width: 80px;
    height: 80px;
    background: white;
    border-radius: 50%;
}

.spotify-logo {
    display: flex;
    align-items: center;
    gap: 8px;
}

.spotify-icon {
    width: 48px;
    height: 48px;
    background: #1DB954;
    border-radius: 50%;
    position: relative;
}

.spotify-text {
    font-size: 32px;
    font-weight: bold;
    color: #1DB954;
}

.project-title {
    font-size: 20px;
    font-weight: bold;
    color: #1a1a1a;
    margin-bottom: 12px;
}

.project-tags {
    display: flex;
    gap: 8px;
    margin-bottom: 12px;
}

.tag {
    padding: 6px 10px;
    background: #dbeafe;
    color: #1A4587;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
}

.project-description {
    color: #6b7280;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 12px;
}

.read-more {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #84a1c7;
    font-weight: 500;
    font-size: 14px;
    text-decoration: none;
}

.read-more:hover { color: #1A4587; }

.experience-date {
    color: #6b7280;
    font-size: 14px;
    margin-bottom: 8px;
}

.experience-title {
    font-size: 20px;
    font-weight: bold;
    color: #1a1a1a;
    margin-bottom: 16px;
}

.experience-description {
    color: #6b7280;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 16px;
}

.experience-tags { display: flex; gap: 8px; }

.experience-tag {
    padding: 6px 10px;
    background: #f3f4f6;
    color: #4b5563;
    border-radius: 4px;
    font-size: 13px;
}

/* scrollbar content */
.content-area::-webkit-scrollbar { width: 6px; }
.content-area::-webkit-scrollbar-track { background: transparent; }
.content-area::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
.content-area::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ================================
   Experiences — points clés (LIGHT)
================================= */
.xp-section { margin-top: 56px; }

.xp-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.xp-title {
    font-size: 22px;
    font-weight: 800;
    color: #1a1a1a;
    letter-spacing: -0.02em;
}

.xp-subtitle { font-size: 13px; color: #6b7280; }

.xp-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

.xp-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 20px;
    cursor: pointer;
    user-select: none;

    position: relative;           /* NEW */
    padding-bottom: 52px;         /* NEW : réserve de la place pour le pill */

    border: 1px solid #e5e7eb;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08);

    transition: transform 200ms ease,
                box-shadow 200ms ease,
                border-color 200ms ease;
}

.xp-card:hover {
    transform: translateY(-4px);
    border-color: #93c5fd;
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.14);
}

.xp-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.xp-left { display: flex; align-items: center; gap: 10px; }

.xp-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;

    display: flex;
    align-items: center;
    justify-content: center;

    background: #dbeafe;
    color: #1A4587;
}

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

.xp-card-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a1a;
}

.xp-pill {
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #dbeafe;
    color: #1A4587;
    font-weight: 500;

  position: absolute;           /* NEW */
  right: 16px;                  /* ajuste si besoin */
  bottom: 14px;                 /* ajuste si besoin */
  margin: 0;                    /* évite les décalages */
  white-space: nowrap;
}

.xp-text {
    font-size: 14px;
    color: #4b5563;
    line-height: 1.6;
    margin-bottom: 12px;
}

.xp-cta {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #3b82f6;
    font-weight: 500;
}

.xp-chevron {
    width: 14px;
    height: 14px;
    transition: transform 200ms ease;
}

.xp-details {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 250ms ease, opacity 200ms ease;
}

.xp-list {
    margin-top: 10px;
    padding-left: 18px;
    font-size: 13px;
    color: #4b5563;
}

.xp-card.is-open { border-color: #60a5fa; }
.xp-card.is-open .xp-details { max-height: 220px; opacity: 1; }
.xp-card.is-open .xp-chevron { transform: rotate(90deg); }

/* ============================
   Mobile sticky topbar (collée + full width)
   -> on retire le padding du scroll container
============================ */
@media (max-width: 1024px) {

    /* ✅ Sticky doit coller au haut du conteneur scrollable */
    .content-area {
        padding: 0;
    }

    /* ✅ On remet l'espacement sur le contenu (pas sur la topbar) */
    .content-area > *:not(.mobile-topbar) {
        padding-left: 24px;
        padding-right: 24px;
    }

    /* Un peu d’air sous la topbar pour le premier bloc */
    .content-area > .sidebar {
        padding-top: 16px;
    }

    .mobile-topbar {
        position: sticky;
        top: 0;
        z-index: 30;

        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;

        width: 100%;
        margin: 0;
        border-radius: 0;

        background: #ffffff;
        border-bottom: 1px solid #e5e7eb;
        box-shadow: 0 10px 22px rgba(0, 0, 0, 0.10);

        padding: 10px 14px;

        opacity: 0;
        transform: translateY(-8px);
        pointer-events: none;
        transition: opacity 200ms ease, transform 200ms ease;
    }

    .mobile-topbar.is-visible {
        opacity: 1;
        transform: translateY(0);
        pointer-events: auto;
    }

    .mobile-topbar-left {
        display: flex;
        align-items: center;
        gap: 10px;
        min-width: 0;
    }

    .mobile-topbar-avatar {
        width: 34px;
        height: 34px;
        border-radius: 10px;

        display: flex;
        align-items: center;
        justify-content: center;

        color: white;
        font-weight: 800;
        font-size: 14px;

        background: linear-gradient(135deg, #60a5fa 0%, #1A4587 100%);
        flex-shrink: 0;
    }

    .mobile-topbar-meta {
        display: flex;
        flex-direction: column;
        line-height: 1.1;
        min-width: 0;
    }

    .mobile-topbar-name {
        font-weight: 800;
        font-size: 13px;
        color: #1a1a1a;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .mobile-topbar-role {
        font-size: 12px;
        color: #6b7280;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }


    .mobile-topbar-right {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .mobile-topbar-right svg {
        width: 20px;
        height: 20px;
        color: #666;
        cursor: pointer;
        transition: color 0.2s;
    }

    .mobile-topbar-right svg:hover { color: #1A4587; }

    .mobile-topbar-right .email-btn {
        margin-left: 0;
        padding: 6px 10px;
        border-radius: 999px;
    }

    /* responsive cards */
    .projects-grid { grid-template-columns: 1fr; }
    .xp-grid { grid-template-columns: 1fr; }
}

/* desktop: topbar hidden */
@media (min-width: 1025px) {
    .mobile-topbar { display: none; }
}

/* ============================
   Project carousel (auto slide)
============================ */
.project-image.project-carousel {
  /* hérite de .project-image (ratio + taille) */
}

.carousel-track {
  height: 100%;
  width: 100%;
  display: flex;
  will-change: transform;
  transition: transform 650ms cubic-bezier(.22,.8,.2,1);
}

.carousel-track img {
  flex: 0 0 100%;
  width: 100%;
  height: 100%;
  object-fit: contain;       /* ✅ pas de découpe */
  background: #f3f4f6;       /* fond propre si bandes */
  display: block;
}

.project-carousel::after {
  content: "";
  position: absolute;
  inset: 0;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.25);
  pointer-events: none;
}

/* ============================
   Contact — Safari clean / premium
============================ */

.contact-section{
  margin-top: 42px;
}


.contact-card{
  border-radius: 18px;
  border: 1px solid #e5e7eb;
  background: #ffffff;
  box-shadow: 0 10px 22px rgba(0,0,0,.06);
  padding: 18px 18px 16px 18px;
  overflow: hidden;
  position: relative;  
}

.contact-head{
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.contact-title{
  margin: 0;
  font-size: 18px;
  font-weight: 900;
  color: #111827;
  letter-spacing: -0.01em;
}

.contact-subtitle{
  margin: 6px 0 0 0;
  font-size: 13px;
  color: #6b7280;
  line-height: 1.5;
}

.contact-mark{
  color: #1A4587;
  font-size: 14px;
  opacity: .9;
  user-select: none;
}

.contact-form{
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-row{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

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

.label{
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #6b7280;
}

.input,
.textarea{
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background: #ffffff;
  padding: 10px 12px;
  font-size: 14px;
  color: #111827;
  outline: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}

.textarea{
  resize: vertical;
  min-height: 120px;
}

.input:focus,
.textarea:focus{
  border-color: #93c5fd;
  box-shadow: 0 0 0 4px rgba(59,130,246,.12);
}

.contact-actions{
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 2px;
}

.btn{
  border-radius: 999px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  border: 1px solid transparent;
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease, border-color .12s ease;
}

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

.btn.primary{
  background: #1A4587;
  color: #dbeafe;
  border-color: #1A4587;
  box-shadow: 0 10px 18px rgba(0,0,0,.08);
}

.btn.primary:hover{
  box-shadow: 0 14px 22px rgba(0,0,0,.12);
}

.btn.ghost{
  background: #ffffff;
  color: #1A4587;
  border-color: #e5e7eb;
}

.btn.ghost:hover{
  border-color: #93c5fd;
  box-shadow: 0 10px 18px rgba(0,0,0,.06);
}

.contact-foot{
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2px;
}

.contact-note{
  font-size: 12px;
  color: #6b7280;
}

.btn.loading{
  opacity: 0.8;
  cursor: wait;
  position: relative;
}

.btn.loading::after{
  content: "";
  position: absolute;
  right: 12px;
  top: 50%;
  width: 14px;
  height: 14px;
  margin-top: -7px;
  border: 2px solid rgba(255,255,255,.6);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

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

/* Mobile */
@media (max-width: 640px){
  .contact-card{ padding: 16px; }
  .contact-row{ grid-template-columns: 1fr; }
  .contact-actions{ flex-direction: column; align-items: stretch; }
  .btn{ width: 100%; }
}


/* Responsive */
@media (max-width: 1024px){
  .contact-grid{
    grid-template-columns: 1fr;
  }
  .contact-title{ font-size: 24px; }
}

/* KPI in mobile topbar (reuse sidebar KPI styles) */
@media (max-width: 1024px){
  .mobile-topbar-meta{
    min-width: 0;
  }

  /* la ligne KPI doit être compacte dans la topbar */
  .mobile-topbar-kpi.sidebar-kpis{
    margin: 2px 0 0 0;      /* pas d’espace vertical inutile */
    font-size: 12px;        /* plus petit que la sidebar */
    line-height: 1.2;
    gap: 1px;               /* espace entre items */
    white-space: nowrap;    /* reste sur 1 ligne */
    overflow: hidden;
    text-overflow: ellipsis;
  }

  /* séparateur plus discret en topbar */
  .mobile-topbar-kpi .kpi-separator{
    margin: 0 6px;
    opacity: .55;
  }

  /* animation un peu plus légère dans la topbar */
  .mobile-topbar-kpi .kpi-sweep{
    animation: kpiSweep 2.4s linear infinite, kpiHue 10s ease-in-out infinite;
  }
}