/* =============================================
   MynDev — Site Vitrine
   Charte graphique : CLAUDE.md
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700;900&display=swap');

:root {
  --red:    #F2385A;
  --dark:   #1E2235;
  --light:  #F5F5F0;
  --white:  #FFFFFF;
  --gray:   #6B7280;
  --border: #E5E7EB;
  --shadow: 0 4px 24px rgba(30,34,53,0.10);
  --radius: 12px;
  --transition: 0.3s ease;
}

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

/* Accessibilité — labels visibles uniquement aux lecteurs d'écran */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--light);
  color: var(--dark);
  line-height: 1.6;
  overflow-x: hidden;
}

/* ── UTILITAIRES ── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section-title {
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 12px;
}
.section-title span { color: var(--red); }
.section-subtitle {
  font-size: 1.05rem;
  color: var(--gray);
  margin-bottom: 48px;
  max-width: 600px;
}
.btn {
  display: inline-block;
  padding: 14px 32px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: var(--transition);
  cursor: pointer;
  border: none;
}
.btn-primary { background: var(--red); color: var(--white); }
.btn-primary:hover { background: #d42e4d; transform: translateY(-2px); box-shadow: 0 8px 24px rgba(242,56,90,0.35); }
.btn-outline { background: transparent; color: var(--white); border: 2px solid var(--white); }
.btn-outline:hover { background: var(--white); color: var(--dark); }

/* ── HEADER ── */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: rgba(30,34,53,0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  transition: var(--transition);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}
.header-logo img {
  height: 38px;
  width: auto;
  display: block;
}
nav { display: flex; align-items: center; gap: 8px; }
nav a {
  color: rgba(255,255,255,0.80);
  text-decoration: none;
  font-size: 0.90rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: 6px;
  transition: var(--transition);
}
nav a:hover, nav a.active { color: var(--white); background: rgba(242,56,90,0.18); }
.nav-cta {
  background: var(--red) !important;
  color: var(--white) !important;
  padding: 9px 20px !important;
}
.nav-cta:hover { background: #d42e4d !important; }

/* Burger */
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  background: none;
  border: none;
}
.burger span {
  display: block;
  width: 24px; height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: var(--transition);
}
.burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── HERO ── */
#hero {
  min-height: 100vh;
  background: linear-gradient(135deg, var(--dark) 0%, #2d3250 60%, #1a1d2e 100%);
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
}
#hero::before {
  content: '';
  position: absolute;
  top: -20%; right: -10%;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(242,56,90,0.15) 0%, transparent 70%);
  pointer-events: none;
}
#hero::after {
  content: '';
  position: absolute;
  bottom: -10%; left: -5%;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(242,56,90,0.08) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content {
  position: relative;
  z-index: 1;
  max-width: 700px;
  padding-top: 80px;
}
.hero-logo {
  display: block;
  height: 160px;
  width: auto;
  margin-bottom: 32px;
}
@media (max-width: 768px) {
  .hero-logo { height: 64px; margin-bottom: 24px; }
}

.hero-badge {
  display: block;
  width: fit-content;
  background: rgba(242,56,90,0.15);
  color: var(--red);
  border: 1px solid rgba(242,56,90,0.3);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 24px;
}
.hero-title {
  font-size: clamp(2.2rem, 6vw, 4rem);
  font-weight: 900;
  color: var(--white);
  line-height: 1.15;
  margin-bottom: 20px;
}
.hero-title span { color: var(--red); }
.hero-desc {
  font-size: clamp(1rem, 2.5vw, 1.15rem);
  color: rgba(255,255,255,0.72);
  margin-bottom: 40px;
  max-width: 540px;
}
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* ── RÉALISATIONS ── */
#realisations { padding: 100px 0; background: var(--light); }
.project-block {
  margin-bottom: 80px;
  background: var(--white);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.project-block:last-child { margin-bottom: 0; }

.project-header {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  align-items: stretch;
}
.project-info {
  padding: 48px 48px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.project-logo-wrap {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
}
.project-icon {
  width: 56px; height: 56px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--white);
  flex-shrink: 0;
}
.project-icon.gestresid { background: #1a4a8a; }
.project-icon.proteines { background: #2a9d8f; }

.project-name {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--dark);
}
.project-client {
  font-size: 0.82rem;
  color: var(--gray);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 2px;
}
.project-desc {
  font-size: 1rem;
  color: var(--gray);
  margin-bottom: 24px;
  line-height: 1.7;
}
.project-features {
  list-style: none;
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.project-features li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.92rem;
  color: var(--dark);
}
.project-features li::before {
  content: '';
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--red);
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 7px;
}
.tech-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tech-badge {
  background: var(--light);
  color: var(--dark);
  border: 1px solid var(--border);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
}

/* Caroussel */
.project-carousel-wrap {
  background: #0f1322;
  padding: 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}
.carousel-track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  cursor: grab;
  padding-bottom: 4px;
}
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track.grabbing { cursor: grabbing; }
.carousel-slide {
  flex: 0 0 calc(100% - 0px);
  scroll-snap-align: start;
  border-radius: 10px;
  overflow: hidden;
  background: #1a1d2e;
}
.carousel-slide img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  transition: transform 0.3s ease;
}
.carousel-slide img:hover { transform: scale(1.02); }

.carousel-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
}
.carousel-dots {
  display: flex;
  gap: 8px;
}
.dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,0.25);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  padding: 0;
}
.dot.active { background: var(--red); width: 24px; border-radius: 4px; }
.carousel-btn {
  background: rgba(255,255,255,0.10);
  border: 1px solid rgba(255,255,255,0.15);
  color: var(--white);
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: var(--transition);
  font-size: 0.9rem;
}
.carousel-btn:hover { background: var(--red); border-color: var(--red); }
.carousel-arrows { display: flex; gap: 8px; }

/* Caption */
.slide-caption {
  text-align: center;
  color: rgba(255,255,255,0.45);
  font-size: 0.78rem;
  margin-top: 8px;
  font-style: italic;
}

/* Projet "coming soon" */
.project-coming {
  opacity: 0.6;
  filter: grayscale(30%);
}
.coming-overlay {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #0f1322;
  border-radius: var(--radius);
  min-height: 260px;
}
.coming-text {
  text-align: center;
  color: rgba(255,255,255,0.5);
}
.coming-text .soon { font-size: 3rem; margin-bottom: 12px; }
.coming-text p { font-size: 0.9rem; }

/* ── À PROPOS ── */
#apropos {
  padding: 100px 0;
  background: var(--dark);
  color: var(--white);
}
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.about-text .section-title { color: var(--white); }
.about-text .section-subtitle { color: rgba(255,255,255,0.55); margin-bottom: 24px; }
.about-desc {
  font-size: 1rem;
  color: rgba(255,255,255,0.72);
  line-height: 1.8;
  margin-bottom: 32px;
}
.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.stat-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 20px;
  text-align: center;
}
.stat-value {
  font-size: 2rem;
  font-weight: 900;
  color: var(--red);
  line-height: 1;
  margin-bottom: 6px;
}
.stat-label {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.55);
  font-weight: 500;
}
.about-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}
.about-card {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 20px;
  padding: 40px;
  text-align: center;
  max-width: 360px;
  width: 100%;
}
.about-avatar {
  width: 90px; height: 90px;
  background: var(--red);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem;
  font-weight: 900;
  color: var(--white);
  margin: 0 auto 20px;
  letter-spacing: -1px;
}
.about-name {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 6px;
}
.about-role {
  font-size: 0.88rem;
  color: var(--red);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 20px;
}
.about-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
.about-tag {
  background: rgba(242,56,90,0.12);
  color: var(--red);
  border: 1px solid rgba(242,56,90,0.25);
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
}

/* ── TECHNOLOGIES ── */
#technologies { padding: 100px 0; background: var(--light); }
.tech-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 16px;
}
.tech-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 16px;
  text-align: center;
  transition: var(--transition);
}
.tech-card:hover {
  border-color: var(--red);
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(242,56,90,0.12);
}
.tech-icon {
  font-size: 2rem;
  margin-bottom: 10px;
  display: block;
}
.tech-name {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 4px;
}
.tech-role {
  font-size: 0.75rem;
  color: var(--gray);
}

/* ── CONTACT ── */
#contact {
  padding: 100px 0;
  background: var(--dark);
  color: var(--white);
  text-align: center;
}
#contact .section-title { color: var(--white); }
#contact .section-subtitle { color: rgba(255,255,255,0.55); margin: 0 auto 40px; }
.contact-form {
  max-width: 540px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%;
  padding: 14px 18px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 8px;
  color: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  outline: none;
  transition: var(--transition);
}
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: rgba(255,255,255,0.35); }
.contact-form input:focus,
.contact-form textarea:focus { border-color: var(--red); background: rgba(255,255,255,0.08); }
.contact-form textarea { resize: vertical; min-height: 130px; }

/* ── LIGHTBOX ── */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0,0,0,0.92);
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
}
.lightbox.open { display: flex; }
.lightbox img {
  max-width: 94vw;
  max-height: 92vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(0,0,0,0.7);
  user-select: none;
}
.lightbox-close {
  position: fixed;
  top: 20px; right: 24px;
  color: rgba(255,255,255,0.7);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  background: none;
  border: none;
  transition: color 0.2s;
  z-index: 1001;
}
.lightbox-close:hover { color: var(--red); }
.carousel-slide img { cursor: zoom-in; }

/* ── FOOTER ── */
footer {
  background: #0f1322;
  padding: 28px 0;
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}
footer img { height: 28px; }
footer p {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.40);
}
footer a { color: var(--red); text-decoration: none; }

/* ── RESPONSIVE TABLET ── */
@media (max-width: 1024px) {
  .project-header { grid-template-columns: 1fr; }
  .project-carousel-wrap { padding: 24px; }
  .about-grid { grid-template-columns: 1fr; gap: 48px; }
  .about-visual { order: -1; }
}

/* ── RESPONSIVE MOBILE ── */
@media (max-width: 768px) {
  nav { display: none; position: fixed; top: 68px; left: 0; right: 0; background: rgba(30,34,53,0.98); flex-direction: column; padding: 16px; gap: 4px; border-bottom: 1px solid rgba(255,255,255,0.08); }
  nav.open { display: flex; }
  nav a { padding: 12px 16px; width: 100%; border-radius: 8px; }
  .burger { display: flex; }
  .hero-actions { flex-direction: column; align-items: flex-start; }
  .hero-actions .btn { width: 100%; text-align: center; }
  .project-info { padding: 28px 24px; }
  .project-carousel-wrap { padding: 16px; }
  .about-stats { grid-template-columns: 1fr 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .footer-inner { justify-content: center; text-align: center; }
  #realisations, #apropos, #technologies, #contact { padding: 64px 0; }
  .tech-grid { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .hero-title { font-size: 2rem; }
  .about-stats { grid-template-columns: 1fr; }
  .tech-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .tech-card { padding: 16px 8px; }
  .tech-icon { font-size: 1.5rem; }
}
