/* ===== VARIABLES ===== */
:root {
  --primary-color: #007bff;
  --secondary-color: #0056b3;
  --bg-light: #f9f9f9;
  --bg-dark: #121212;
  --text-dark: #222;
  --text-light: #fff;
  --font-main: 'Poppins', sans-serif;
}

/* ===== DARK MODE ===== */
body.dark {
  --bg-light: var(--bg-dark);
  --text-dark: #f5f5f5;
  --text-light: #f5f5f5;
  --primary-color: #1e90ff;
  --secondary-color: #87cefa;
}

/* ===== RESET ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  font-family: var(--font-main);
  color: var(--text-dark);
  background: var(--bg-light);
  line-height: 1.6;
  transition: background 0.3s, color 0.3s;
}

/* ===== NAVBAR ===== */
header {
  background: var(--text-light);
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  position: sticky;
  top: 0;
  z-index: 100;
}
body.dark header { background: #1c1c1c; }

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
}

.logo {
  font-size: 1.5rem;
  font-weight: bold;
  color: var(--primary-color);
}

/* ===== NAV LINKS ===== */
.nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none; /* ✅ enlève les puces */
  margin: 0;
  padding: 0;
}

.nav-links li {
  list-style: none; /* ✅ double sécurité : pas de points */
}

.nav-links a {
  color: var(--text-dark);
  text-decoration: none;
  font-weight: 500;
  transition: color 0.3s;
}

.nav-links a:hover {
  color: var(--primary-color);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.menu-toggle,
#theme-toggle {
  font-size: 1.5rem;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-dark);
}

#theme-toggle:hover {
  color: var(--primary-color);
}

/* ===== HERO ===== */
.hero {
  height: 100vh;
  background: linear-gradient(to right, #002b5b, #0056b3);
  color: var(--text-light);
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 2rem;
}

.hero h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.hero p {
  max-width: 600px;
  margin: 0 auto 2rem;
}

.btn {
  display: inline-block;
  background: var(--primary-color);
  color: var(--text-light);
  padding: 0.8rem 1.5rem;
  border-radius: 5px;
  text-decoration: none;
  transition: background 0.3s;
}

.btn:hover {
  background: var(--secondary-color);
}

.btn-secondary {
  background: transparent;
  border: 1px solid var(--text-light);
}

/* ===== SECTION GENERALE ===== */
.section {
  padding: 4rem 2rem;
  max-width: 1100px;
  margin: auto;
}

.section h2 {
  text-align: center;
  color: var(--primary-color);
  margin-bottom: 2rem;
}

/* ===== À PROPOS ===== */
.about-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2rem;
}

.about-img img {
  width: 220px;
  height: 220px;
  border-radius: 50%;
  object-fit: cover;
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.about-text {
  flex: 1;
  font-style:normal;
}

.about-text p {
  margin-bottom: 1rem;
}

.about-text ul {
  list-style: none;
  line-height: 1.8;
  margin-bottom: 1rem;
  padding-left: 0;
}

/* ===== PROJETS ===== */
.project-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.project-card {
  background: var(--text-light);
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 100%;
}
.project-img { 
  background: var(--text-light);
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  padding: 1.5rem;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 100%
  
}
.project-img img{
  border-radius: 8px;
}

body.dark .project-card {
  background: #1e1e1e;
}

/* ===== TABLE ===== */
.skills-table table {
  width: 100%;
  border-collapse: collapse;
}

.skills-table th,
.skills-table td {
  border: 1px solid #ddd;
  padding: 1rem;
  text-align: left;
}

.skills-table th {
  background: var(--primary-color);
  color: white;
}

/* ===== CONTACT ===== */
.contact-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 2rem;
  font-size: 1.1rem;
}

.contact-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

.contact-form {
  background: var(--text-light);
  padding: 2rem;
  border-radius: 10px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  width: 100%;
  max-width: 600px;
  display: flex;
  flex-direction: column;
  gap: 1.2rem;
}

body.dark .contact-form {
  background: #1e1e1e;
}

.form-group label {
  font-weight: 600;
  margin-bottom: 0.4rem;
  display: block;
  color: var(--text-dark);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 1rem;
  background: var(--bg-light);
  color: var(--text-dark);
}

body.dark .form-group input,
body.dark .form-group textarea {
  background: #2a2a2a;
  color: var(--text-light);
  border: 1px solid #444;
}

.contact-form .btn {
  align-self: center;
  width: 150px;
}

/* ===== SOCIAL LINKS ===== */
.socials {
  display: flex;
  justify-content: center;
  gap: 2rem;
}

.social-link {
  font-size: 1.1rem;
  text-decoration: none;
  color: var(--primary-color);
  font-weight: 600;
  transition: color 0.3s, transform 0.3s;
}

.social-link:hover {
  color: var(--secondary-color);
  transform: translateY(-3px);
}


.contact-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
}

.contact-form {
  width: 100%;
  max-width: 500px;
}

.social-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 20px;
}

.social-icons a {
  font-size: 1.8rem;
  color: #333;
  transition: color 0.3s;
}

.social-icons a:hover {
  color: #0073b1; /* Couleur au survol, change selon ton design */
}


/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .nav-links {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 70px;
    right: 0;
    width: 200px;
    background: var(--text-light);
    padding: 1rem;
    border-radius: 5px;
  }

  .nav-links.show {
    display: flex;
  }

  .about-container {
    flex-direction: column;
    text-align: center;
  }
}

/* ===== FADE-IN ===== */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.fade-in.show {
  opacity: 1;
  transform: translateY(0);
}

/* ===== FOOTER ===== */
footer {
  background: var(--text-dark);
  color: var(--text-light);
  text-align: center;
  padding: 1rem;
}
body.dark footer{
  color: #1e1e1e;
  font-weight: bold;
}