/* ===== STYLE.CSS - Design éco-conçu, responsive, accessible ===== */

/* Base & accessibilité */
:root {
  --bg: #f4f4f4;
  --text: #1c1c1c;
  --primary: #4285F4;
  --accent: #F4B400;
  --font-main: 'Inter', sans-serif;
}

* {
  box-sizing: border-box;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-main);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

.container {
  width: 90%;
  max-width: 960px;
  margin: auto;
  padding: 0.5rem 0;
}

header {
  text-align: center;
  background-color: #fff;
  padding: 2rem 1rem;
  border-bottom: 2px solid #e0e0e0;
}

.profile-pic {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 1rem;
}

.tagline {
  font-size: 1.2rem;
  color: var(--primary);
}

nav ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1rem;
}

nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: bold;
  border-bottom: 2px solid transparent;
}

nav a:hover,
nav a:focus {
  color: var(--primary);
  border-color: var(--accent);
}

h2 {
  font-size: 2rem;
  border-bottom: 2px solid var(--primary);
  padding-bottom: 0.5rem;
  margin-top: 3rem;
}

/* ===== DESIGN SECTION SKILLS AMÉLIORÉ ===== */

#skills {
  padding-bottom: 4rem;
}

/* On transforme la liste en grille de cartes */
.skills {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
  padding: 0;
  margin-top: 2rem;
  list-style: none;
}

/* Style de chaque carte de catégorie */
.skills li {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-radius: 16px;
  padding: 1.5rem;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  box-shadow: 0 4px 6px rgba(0,0,0,0.02);
  color: var(--text); /* Reset la couleur héritée */
  font-weight: normal; /* Reset */
}

.skills li:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.08);
  border-color: var(--primary);
}

/* Style des titres de catégories (ex: "Programming languages:") */
.skills li strong {
  display: block;
  color: var(--primary);
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
  border-left: 4px solid var(--accent);
  padding-left: 10px;
}

.skills li .clickable-card {
  text-decoration: none;
  color: inherit; /* Hérite de la couleur du li */
}

/* Optionnel : Transformer le texte brut en "Badges/Tags" visuels */
/* Si tu veux garder le texte tel quel, ignore ce qui suit. 
   Mais pour un effet visuel fort, on peut styliser le contenu. */

.skills li {
  line-height: 1.8;
  font-size: 0.95rem;
}

/* Media Query pour mobile */
@media (max-width: 600px) {
  .skills {
    grid-template-columns: 1fr;
  }
}

/* --- Section Contact Design --- */

.contact-grid {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap; /* Permet de passer sur plusieurs lignes sur mobile si besoin */
  margin-top: 2rem;
  justify-content: flex-start;
}

.contact-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0.8rem 1.5rem;
  border-radius: 12px;
  text-decoration: none;
  font-weight: 600;
  color: white;
  transition: transform 0.2s, box-shadow 0.2s, filter 0.2s;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* Couleurs spécifiques */
.contact-btn.email {
  background-color: #ea4335; /* Rouge Google/Email */
}

.contact-btn.phone {
  background-color: #34a853; /* Vert Appel/WhatsApp */
}

.contact-btn.linkedin {
  background-color: #0077b5; /* Bleu LinkedIn */
}

/* Effets au survol */
.contact-btn:hover {
  transform: translateY(-3px);
  filter: brightness(1.1);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
  color: white; /* Garde le texte blanc même si un style parent essaie de le changer */
}

.contact-btn i {
  font-size: 1.2rem;
}

/* Responsive : Boutons pleine largeur sur petits écrans */
@media (max-width: 600px) {
  .contact-grid {
    flex-direction: column;
    gap: 1rem;
  }
  
  .contact-btn {
    justify-content: center;
  }
}

.project {
  background-color: #fff;
  padding: 1rem;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.05);
  margin: 2rem 0;
}

.project img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 1rem 0;
}

.project a, 
#about a {
  color: var(--accent);
  text-decoration: none;
  font-weight: bold;
}

.project-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 2rem;
  margin: 1rem 0;
  flex-wrap: wrap;
}

.project-logos img,
.project-logos svg {
  flex: 1;
  width: auto;
  max-width: 120px;
  height: 50px;
  object-fit: contain;
}

.cta-button {
  display: inline-block;
  background-color: var(--primary);
  text-decoration: none;
  font-weight: bold;
  padding: 0.75rem 1.5rem;
  margin-top: 5px;
  border-radius: 8px;
  border: 2px solid var(--primary);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  transition: background-color 0.3s, color 0.3s;
  text-align: center;
  cursor: pointer;
}

.cta-button:hover,
.cta-button:focus,
#about .cta-button:hover,
#about .cta-button:focus {
  background-color: transparent;
  color: var(--primary);
  border-color: var(--accent);
}

.cta-button.outline {
  background-color: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.cta-button.outline:hover,
.cta-button.outline:focus {
  background-color: var(--primary);
  color: white;
}

footer {
  text-align: center;
  font-size: 0.9rem;
  color: #666;
  padding: 2rem 1rem;
  border-top: 1px solid #ddd;
  background-color: #fafafa;
  margin-top: 4rem;
}

@media (max-width: 600px) {
  h2 {
    font-size: 1.5rem;
  }

  nav ul {
    flex-direction: column;
    align-items: center;
  }
}
