/* ============================================
   VARIABLES DE COULEURS
   ============================================ */
:root {
  --bg-color: #f8f7f5;
  --text-color: #3d3d3d;
  --text-light: #999;
  --accent-color: #d97060;
  --card-bg: #ffffff;
  --border-color: #e8e8e8;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  --shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.12);
}

/* ============================================
   RESET ET BASE
   ============================================ */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-color);
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Sora', sans-serif;
  font-weight: 600;
}

a {
  text-decoration: none;
  color: inherit;
  transition: color 0.3s ease;
}

a:hover {
  color: var(--accent-color);
}

button {
  cursor: pointer;
  border: none;
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s ease;
}

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

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

.fade-in-up {
  animation: fadeInUp 0.6s ease-out;
}

.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }
.stagger-6 { animation-delay: 0.6s; }

/* ============================================
   NAVIGATION
   ============================================ */
nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(248, 247, 245, 0.8);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border-color);
  padding: 0 2rem;
}

.nav-container {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.nav-logo {
  font-size: 1.25rem;
  font-weight: bold;
  color: var(--text-color);
}

.nav-links {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.875rem;
  color: var(--text-color);
  transition: color 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--accent-color);
}

/* ============================================
   CONTAINER
   ============================================ */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 768px) {
  .container {
    padding: 0 2rem;
  }
}

/* ============================================
   SECTION HERO
   ============================================ */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-image: url('../images/hero-bg.jpg');
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(248, 247, 245, 0.5), rgba(248, 247, 245, 0.3), rgba(248, 247, 245, 0.8));
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 48rem;
  padding: 0 1rem;
}

.hero-profile {
  width: 96px;
  height: 96px;
  margin: 0 auto 2rem;
  border-radius: 50%;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 4px solid var(--card-bg);
}

.hero-profile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
}

.hero-subtitle {
  font-size: 1.125rem;
  color: rgba(61, 61, 61, 0.7);
  margin-bottom: 1.5rem;
}

.hero-divider {
  width: 48px;
  height: 4px;
  background: var(--accent-color);
  margin: 2rem auto;
  border-radius: 2px;
}

.hero-description {
  font-size: 1rem;
  color: rgba(61, 61, 61, 0.6);
  margin-bottom: 2rem;
  line-height: 1.8;
}

.hero-btn {
  background: var(--accent-color);
  color: white;
  padding: 0.875rem 2rem;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  transition: background 0.3s ease;
}

.hero-btn:hover {
  background: #c85a4a;
}

/* ============================================
   SECTION PROJETS
   ============================================ */
.projects-section {
  padding: 5rem 0;
  background: var(--bg-color);
}

.section-header {
  text-align: center;
  margin-bottom: 4rem;
}

.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
}

.section-header p {
  font-size: 1.125rem;
  color: var(--text-light);
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
}

.project-card {
  background: var(--card-bg);
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.project-card:hover {
  box-shadow: var(--shadow-hover);
  transform: scale(1.05);
}

.project-card h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
  transition: color 0.3s ease;
}

.project-card:hover h3 {
  color: var(--accent-color);
}

.project-card p {
  font-size: 0.875rem;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.project-count {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--accent-color);
  font-size: 0.875rem;
  font-weight: 600;
  margin-top: auto;
}

.project-count::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent-color);
}

/* ============================================
   SECTION CTA
   ============================================ */
.cta-section {
  padding: 5rem 0;
  background: rgba(217, 112, 96, 0.1);
  text-align: center;
}

.cta-section h2 {
  font-size: 2rem;
  margin-bottom: 1.5rem;
  color: var(--text-color);
}

.cta-section p {
  font-size: 1.125rem;
  color: var(--text-light);
  margin-bottom: 2rem;
}

.cta-btn {
  background: var(--accent-color);
  color: white;
  padding: 0.875rem 2rem;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  display: inline-block;
  transition: background 0.3s ease;
}

.cta-btn:hover {
  background: #c85a4a;
}

/* ============================================
   SECTION ABOUT
   ============================================ */
.about-section {
  padding: 5rem 0;
  background: var(--bg-color);
}

.about-header {
  padding: 4rem 0;
  background: rgba(217, 112, 96, 0.1);
  margin-bottom: 4rem;
}

.about-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
}

.about-header p {
  font-size: 1.125rem;
  color: var(--text-light);
}

.about-content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

@media (max-width: 768px) {
  .about-content {
    grid-template-columns: 1fr;
  }
}

.about-image {
  width: 192px;
  height: 192px;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 4px solid var(--card-bg);
  margin: 0 auto;
}

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

.about-text h2 {
  font-size: 1.875rem;
  margin-bottom: 1.5rem;
  color: var(--text-color);
}

.about-text p {
  color: var(--text-light);
  margin-bottom: 1rem;
  line-height: 1.8;
}

.skills-section {
  margin: 4rem 0;
}

.skills-section h3 {
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 2rem;
  color: var(--text-color);
}

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

.skill-item {
  background: var(--card-bg);
  border-radius: 0.75rem;
  padding: 1rem;
  text-align: center;
  box-shadow: var(--shadow);
  transition: background 0.3s ease;
}

.skill-item:hover {
  background: rgba(217, 112, 96, 0.1);
}

/* ✅ Logos compétences (réduits) */
.skill-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 36px;          /* zone plus petite */
  margin-bottom: 8px;
}

.skill-icon img {
  width: 28px;           /* taille du logo */
  height: 28px;
  object-fit: contain;
  display: block;
}

.skill-name {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--text-color);
}

/* ✅ Mobile : 3 logos par ligne */
@media (max-width: 768px) {
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
  }
}

@media (max-width: 420px) {
  .skills-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  .skill-name {
    font-size: 0.8rem;
  }
}

.qualities-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.quality-card {
  background: var(--card-bg);
  border-radius: 1rem;
  padding: 2rem;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.quality-card:hover {
  box-shadow: var(--shadow-hover);
}

.quality-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--accent-color);
}

.quality-card h4 {
  font-size: 1.125rem;
  margin-bottom: 0.75rem;
  color: var(--text-color);
}

.quality-card p {
  font-size: 0.875rem;
  color: var(--text-light);
  line-height: 1.6;
}

/* ============================================
   SECTION CONTACT
   ============================================ */
.contact-section {
  padding: 5rem 0;
  background: var(--bg-color);
}

.contact-header {
  padding: 4rem 0;
  background: rgba(217, 112, 96, 0.1);
  margin-bottom: 4rem;
}

.contact-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
}

.contact-header p {
  font-size: 1.125rem;
  color: var(--text-light);
}

.contact-content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 3rem;
}

@media (max-width: 768px) {
  .contact-content {
    grid-template-columns: 1fr;
  }
}

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

.contact-item {
  display: flex;
  gap: 1rem;
}

.contact-icon {
  font-size: 1.5rem;
  color: var(--accent-color);
  margin-top: 0.25rem;
}

.contact-item h3 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
  color: var(--text-color);
}

.contact-item p,
.contact-item a {
  font-size: 0.875rem;
  color: var(--text-light);
}

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

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

.form-group label {
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--text-color);
}

.form-group input,
.form-group textarea {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: var(--card-bg);
  color: var(--text-color);
  font-family: 'Poppins', sans-serif;
  transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px rgba(217, 112, 96, 0.1);
}

.form-group textarea {
  resize: none;
  min-height: 150px;
}

.submit-btn {
  background: var(--accent-color);
  color: white;
  padding: 0.875rem 2rem;
  border-radius: 0.5rem;
  font-size: 1rem;
  font-weight: 600;
  width: 100%;
  transition: background 0.3s ease;
}

.submit-btn:hover {
  background: #c85a4a;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
  background: rgba(61, 61, 61, 0.05);
  border-top: 1px solid var(--border-color);
  padding: 2rem 0;
  text-align: center;
  color: var(--text-light);
  font-size: 0.875rem;
}

/* ============================================
   SECTION PAGE HEADER
   ============================================ */
.page-header {
  padding: 4rem 0;
  background: rgba(217, 112, 96, 0.1);
  margin-bottom: 4rem;
}

.page-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--text-color);
}

.page-header p {
  font-size: 1.125rem;
  color: var(--text-light);
}

/* ============================================
   BACK BUTTON
   ============================================ */
.back-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  background: transparent;
  color: var(--text-color);
  font-weight: 600;
  transition: all 0.3s ease;
}

.back-button:hover {
  border-color: var(--accent-color);
  color: var(--accent-color);
}

/* ============================================
   PROJECTS PAGE GRID
   ============================================ */
.projects-page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.project-page-card {
  background: var(--card-bg);
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  cursor: pointer;
}

.project-page-card:hover {
  box-shadow: var(--shadow-hover);
}

.project-image {
  position: relative;
  height: 192px;
  overflow: hidden;
  background: rgba(217, 112, 96, 0.1);
}

.project-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.project-page-card:hover .project-image img {
  transform: scale(1.1);
}

.project-image::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.3), transparent);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-page-card:hover .project-image::after {
  opacity: 1;
}

.project-info {
  padding: 1.5rem;
}

.project-info h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  color: var(--text-color);
  transition: color 0.3s ease;
}

.project-page-card:hover .project-info h3 {
  color: var(--accent-color);
}

.project-info p {
  font-size: 0.875rem;
  color: var(--text-light);
  line-height: 1.6;
  margin-bottom: 1rem;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2.5rem;
  }

  .section-header h2 {
    font-size: 2rem;
  }

  .nav-links {
    gap: 1rem;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================
   BURGER MENU (MOBILE)
   ========================= */

.burger {
  display: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 10px;
  border-radius: 10px;
}

.burger span {
  display: block;
  width: 26px;
  height: 2px;
  margin: 6px 0;
  background: #111;
  transition: transform .25s ease, opacity .25s ease;
}

/* Mobile */
@media (max-width: 768px) {
  .burger {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
  }

  .nav-container {
    position: relative;
  }

  /* Le menu devient un panneau déroulant */
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;

    display: none;
    flex-direction: column;
    gap: 0;

    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);

    padding: 12px;
    border-radius: 16px;
    margin-top: 10px;

    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
  }

  .nav-links li a {
    display: block;
    padding: 12px 10px;
  }

  .nav-links.open {
    display: flex;
  }

  .burger.open span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }
  .burger.open span:nth-child(2) {
    opacity: 0;
  }
  .burger.open span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }
}

/* ======================================
   PROJECT DETAIL (PAGES PROJETS)
   ====================================== */

.project-detail {
  padding: 4rem 0;
}

.project-detail .container {
  max-width: 1100px;
}

.project-detail h1 {
  margin-bottom: .5rem;
}

.project-detail .project-desc {
  opacity: .8;
  margin-bottom: 2rem;
}

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

.gallery-item {
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255,255,255,0.6);
  box-shadow: 0 10px 30px rgba(0,0,0,0.06);
}

.gallery-item img,
.gallery-item video {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

/* Pour éviter le bleu + soulignement sur tes cartes devenues <a> */
.project-page-card {
  text-decoration: none;
  color: inherit;
  display: block;
  cursor: pointer;
}

@media (max-width: 900px) {
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 560px) {
  .gallery-grid { grid-template-columns: 1fr; }
}
