/* ===== BASIC RESET AND VARIABLES ===== */
:root {
    /* Light theme */
    --light-bg: #F8F8F8;
    --light-text: #0f172a;
    --light-text-secondary: #182a55;
    --light-accent: #3b82f6;
    --light-card: #E8E8E8;
    --light-card-hover: #e2e8f0;

    /* Dark theme */
    --dark-bg: #0f172a;
    --dark-text: #f8fafc;
    --dark-text-secondary: #a7b8c9;
    --dark-accent: #60a5fa;
    --dark-card: #1e293b;
    --dark-card-hover: #334155;

    /* Common */
    --border-radius: 8px;
    --transition: all 0.3s ease;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

/* ===== GLOBAL STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Quicksand", sans-serif;
    line-height: 1.6;
    transition: var(--transition);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.light-theme {
    background-color: var(--light-bg);
    color: var(--light-text);

    a {
        color: var(--light-text-secondary);
        text-decoration: underline;
    }
}

.dark-theme {
    background-color: var(--dark-bg);
    color: var(--dark-text);

    a {
        color: var(--dark-text-secondary);
        text-decoration: underline;
    }
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* ===== HEADER ===== */
header {
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    transition: var(--transition);
    z-index: 1000;
}

.header-container {
    width: 95%;
    max-width: 1500px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    margin: 32px auto 0px auto;
    border-radius: 32px;
    z-index: 1000;
    backdrop-filter: blur(10px);
    transition: var(--transition);
}

/* ===== GLOBAL STYLES ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 80px 20px 0;
    /* Modifié ici : ajout du padding-top */
    width: 100%;
}

/* Style de base pour tous les containers */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

/* Style spécifique pour les containers des pages de projets et veilles */
.project-details .container,
.veille-details .container {
    padding-top: 80px;
}

/* OU une autre approche possible */
main.container {
    padding: 0 20px;
}

/* Ajouter une classe spécifique pour les pages de projets */
main.project-page {
    padding-top: 80px;
}

/* ===== SECTION STYLES ===== */
section {
    padding: 5rem 0;
    scroll-margin-top: 80px;
    /* Ajouté ici */
}


.light-theme .header-container {
    background-color: #3b83f693;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.dark-theme .header-container {
    background-color: rgba(36, 54, 94, 0.8);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.logo a {
    font-family: "Comfortaa", sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
}

.light-theme .logo a {
    color: var(--light-text);
}

.dark-theme .logo a {
    color: var(--dark-text);
}

.main-nav {
    display: flex;
    gap: 2rem;
}

.main-nav a {
    font-size: 1.3rem;
    text-decoration: none;
    position: relative;
    transition: var(--transition);
}

.light-theme .main-nav a {
    color: var(--light-text);
}

.dark-theme .main-nav a {
    color: var(--dark-text);
}

.light-theme .project-section {
    background-color: #cccccc;
}

.dark-theme .project-section {
    background-color: #1e293b;
}

.light-theme .task-card {
    background-color: #dddddd;
    border: 1px solid #ddd;
}

.dark-theme .task-card {
    background-color: #2c3d57;
    border: 1px solid #2c3d57;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 100%;
    height: 2px;
    background: currentColor;
    transform: scaleX(0);
    transition: transform 0.3s ease;
    transform-origin: center;
}

.main-nav a:hover::after {
    transform: scaleX(1);
}

/* ===== HERO SECTION ===== */
.hero-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 100vh;
    padding: 6rem 0 3rem;
    gap: 3rem;
}

.hero-content {
    flex: 1;
}

.hero-title {
    font-family: "Comfortaa", sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 2rem;
    line-height: 1.2;
}

.social-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.social-links a {
    text-decoration: none;
    font-size: 1.1rem;
    font-weight: 600;
    padding: 0.5rem 1rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.light-theme .social-links a {
    background-color: var(--light-accent);
    color: white;
}

.dark-theme .social-links a {
    background-color: var(--dark-accent);
    color: var(--dark-bg);
}

.social-links a:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

.hero-description {
    flex: 1;
    font-size: 1.2rem;
    line-height: 1.8;
}

.hero-description p {
    margin-bottom: 1rem;
}

/* ===== SECTION STYLES ===== */
section {
    padding: 5rem 0;
    scroll-margin-top: 5rem;
}

.section-title {
    font-family: "Comfortaa", sans-serif;
    font-size: 3rem;
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    transition: var(--transition);
}

.light-theme .section-title::after {
    background-color: var(--light-accent);
}

.dark-theme .section-title::after {
    background-color: var(--dark-accent);
}

/* ===== CARD CONTAINERS ===== */
.card-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

/* ===== PROJECT CARDS ===== */
.project-card,
.veille-card {
    display: block;
    text-decoration: none;
    border-radius: var(--border-radius);
    overflow: hidden;
    transition: var(--transition);
    height: 200px;
    box-shadow: var(--shadow);
}

.light-theme .project-card,
.light-theme .veille-card {
    background-color: #dddddd;
}

.dark-theme .project-card,
.dark-theme .veille-card {
    background-color: #2c3d57;
}

.project-card:hover,
.veille-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.card-inner {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 1.5rem;
    position: relative;
    text-align: center;
    transition: var(--transition);
}

.card-inner h3 {
    font-family: "Comfortaa", sans-serif;
    font-size: 1.3rem;
    margin-bottom: 1rem;
    transition: var(--transition);
}

.light-theme .card-inner h3 {
    color: var(--light-text);
}

.dark-theme .card-inner h3 {
    color: var(--dark-text);
}

.card-hover {
    position: absolute;
    top: 0;
    left: 0;
    padding-top: 10%;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.486);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: var(--transition);
    color: white;
    font-weight: 600;
}

.project-card:hover .card-hover,
.veille-card:hover .card-hover {
    opacity: 1;
}

/* ===== SKILLS SECTION ===== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.skills-category {
    padding: 2rem;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.light-theme .skills-category {
    background-color: var(--light-card);
    box-shadow: var(--shadow);
}

.dark-theme .skills-category {
    background-color: var(--dark-card);
    box-shadow: var(--shadow);
}

.skills-category h3 {
    font-family: "Comfortaa", sans-serif;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.skills-category ul {
    list-style: none;
}

.skills-category li {
    padding: 0.5rem 0;
    text-align: center;
    font-size: 1.1rem;
}

.comp-link {
    text-align: center;
    margin-top: 3rem;
}

.comp-link a {
    display: inline-block;
    text-decoration: none;
    padding: 0.8rem 1.5rem;
    border-radius: var(--border-radius);
    font-weight: 600;
    transition: var(--transition);
}

.light-theme .comp-link a {
    background-color: var(--light-accent);
    color: white;
}

.dark-theme .comp-link a {
    background-color: var(--dark-accent);
    color: var(--dark-bg);
}

.comp-link a:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow);
}

/* ===== FOOTER ===== */
footer {
    margin-top: auto;
    position: relative;
    padding: 3rem 0 1rem;
    text-align: center;
}

.footer-wave {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.footer-wave svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 50px;
}

.light-theme .footer-wave .shape-fill {
    fill: var(--light-accent);
}

.dark-theme .footer-wave .shape-fill {
    fill: var(--dark-accent);
}

.footer-content {
    margin-top: 2rem;
    font-size: 1rem;
}

/* ===== THEME TOGGLE ===== */
.theme-toggle {
    position: relative;
    width: 50px;
    height: 25px;
    border-radius: 25px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 5px;
    box-shadow: var(--shadow);
}

.light-theme .theme-toggle {
    background-color: var(--light-card);
}

.dark-theme .theme-toggle {
    background-color: var(--dark-card);
}

.theme-toggle .toggle-circle {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 17px;
    height: 17px;
    border-radius: 50%;
    background-color: var(--light-accent);
    transition: var(--transition);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.dark-theme .theme-toggle .toggle-circle {
    background-color: var(--dark-accent);
    transform: translateX(25px);
}

.theme-toggle .icon {
    font-size: 0.8rem;
    color: var(--light-text-secondary);
    transition: var(--transition);
}

.light-theme .theme-toggle .icon.sun {
    opacity: 1;
}

.light-theme .theme-toggle .icon.moon {
    opacity: 0;
}

.dark-theme .theme-toggle .icon.sun {
    opacity: 0;
}

.dark-theme .theme-toggle .icon.moon {
    opacity: 1;
}

@media (max-width: 768px) {
    header {
        padding: 1rem;
    }

    .header-container {
        margin: 8px auto 0px auto;
    }

    .main-nav {
        gap: 1rem;
    }

    .main-nav a {
        font-size: 0.9rem;
    }

    .logo a {
        font-size: 2rem;
    }

    .hero-section {
        flex-direction: column;
        text-align: center;
        padding-top: 8rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .social-links {
        justify-content: center;
        gap: 1rem;
    }

    .social-links a {
        font-size: 0.9rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .header-container {
        margin: 0px auto 0px auto;
    }

    .logo a {
        font-size: 1.8rem;
    }

    .stage-title {
        text-align: center;
    }

    .hero-title {
        font-size: 2rem;
    }

    .card-container {
        grid-template-columns: 1fr;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }
}

/* Add a mobile menu functionality if needed */
.mobile-menu-toggle {
    display: none;
}

@media (max-width: 576px) {
    .mobile-menu-toggle {
        display: block;
        font-size: 1.5rem;
        cursor: pointer;
    }

    .main-nav.active {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        padding: 1rem;
        gap: 1rem;
    }

    .light-theme .main-nav.active {
        background-color: var(--light-bg);
    }

    .dark-theme .main-nav.active {
        background-color: var(--dark-bg);
    }
}

/* Styles pour les cartes de compétences */
.skills-cards {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 1rem;
}

.skill-card {
    background-color: var(--light-card);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 1rem;
    transition: var(--transition);
    flex: 1 1 calc(33.333% - 1rem);
    text-align: center;
}

.skill-card a {
    text-decoration: none;
    color: var(--light-text);
    font-weight: 600;
}

.skill-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.dark-theme .skill-card {
    background-color: var(--dark-card);
}

.dark-theme .skill-card a {
    color: var(--dark-text);
}

.resultat {
    text-decoration: none;
    color: inherit;
    display: block;
    padding: 15px;
    transition: all 0.3s ease;
}

.resultat:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.dynamic-title {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    border-left: 4px solid #3498db;
    padding-left: 10px;
}

/* Style pour le titre "2ème année BTS SIO" */
.stage-title {
    font-size: 2rem;
    text-transform: uppercase;
    font-weight: bold;
    margin-bottom: 1.5rem;
}

/* Style pour le titre "Contexte & Objectifs" */
.context-title {
    font-size: 1.8rem;
    color: #2c3e50;
    font-weight: bold;
    border-left: 4px solid #e74c3c;
    padding-left: 10px;
    margin-bottom: 1rem;
}

.highlight {
    color: #e74c3c;
    font-weight: bold;
}

.date {
    color: #8e44ad;
    font-style: italic;
}

.tech-list {
    list-style: none;
    padding: 0;
}

.tech-list li {
    margin: 0.5rem 0;
    font-size: 1.1rem;
}

.tech-list li i {
    margin-right: 8px;
    color: #3498db;
}

.icon-php::before {
    content: "🐘";
    /* Example icon for PHP */
}

.icon-vue::before {
    content: "🌐";
    /* Example icon for Vue.js */
}

.icon-db::before {
    content: "🗄️";
    /* Example icon for database */
}

.icon-git::before {
    content: "🔧";
    /* Example icon for Git */
}

.icon-filezilla::before {
    content: "📂";
    /* Example icon for FileZilla */
    margin-right: 8px;
    color: #e74c3c;
    /* Optional: FileZilla-themed color */
}

/* Conteneur des cartes */
.task-cards {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 1rem;
}

/* Style des cartes */
.task-card {
    border-radius: 8px;
    padding: 1rem;
    flex: 1 1 calc(33.333% - 1rem);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Titre des cartes */
.task-card h4 {
    font-size: 1.2rem;
    color: #3498db;
    margin-bottom: 0.5rem;
}

/* Texte des cartes */
.task-card p {
    font-size: 1rem;
    line-height: 1.5;
}

/* Effet au survol */
.task-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.15);
}

.project-section {
    background-color: #ec7575;
    margin: 1rem 0;
    padding: 10px;
    border-radius: 20px;
    scroll-margin-top: 5rem;
}

/* ===== BUTTON STYLES ===== */
.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    border-radius: var(--border-radius);
    transition: var(--transition);
    cursor: pointer;
    border: none;
    margin: 0.5rem 0;
}

/* Light theme button */
.light-theme .btn {
    background-color: var(--light-accent);
    color: var(--light-text);
    box-shadow: var(--shadow);
}

.light-theme .btn:hover {
    background-color: #2563eb;
    /* Slightly darker shade for hover */
    transform: translateY(-3px);
}

/* Dark theme button */
.dark-theme .btn {
    background-color: var(--dark-accent);
    color: var(--light-text);
    box-shadow: var(--shadow);
}

.dark-theme .btn:hover {
    background-color: #3b82f6;
    /* Slightly lighter shade for hover */
    transform: translateY(-3px);
}

.image-gallery {
    display: flex;
    flex-wrap: wrap;
    /* Empêche les images de passer à la ligne */
    justify-content: space-between;
    /* Éloigne les images horizontalement */
    align-items: stretch;
    /* Étire les images pour qu'elles prennent la hauteur maximale */
    height: 100%;
    /* Définit une hauteur pour la div */
}

.image-gallery img {
    object-fit: cover;
    /* Maintient le ratio d'aspect tout en remplissant l'espace */
    flex: 1;
    /* Permet aux images de s'étirer également */
    max-width: 100%;
    /* Limite la largeur pour éviter qu'elles ne soient trop grandes */
    border-radius: 20px;
    margin: 0.5rem 0;
    /* Supprime les marges pour un meilleur alignement */
}

.skills-list {
    list-style-type: none;
    /* Supprime les puces par défaut */
    padding: 0;
    /* Supprime le padding par défaut */
    margin: 0;
    /* Supprime le margin par défaut */
}

.skills-list li {
    background-color: #dddddd;
    /* Couleur de fond pour le thème clair */
    border-radius: 5px;
    /* Coins arrondis */
    padding: 10px 15px;
    /* Espacement interne */
    margin-bottom: 10px;
    /* Espacement entre les éléments */
    font-size: 16px;
    /* Taille de police */
    font-family: 'Quicksand', sans-serif;
    /* Police cohérente avec le reste du site */
    display: flex;
    /* Permet d'aligner les icônes et le texte */
    align-items: center;
    /* Aligne verticalement les éléments */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    /* Légère ombre pour un effet de relief */
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
    /* Animation au survol */
}

.dark-theme .skills-list li {
    background-color: #2c3d57;
    /* Couleur de fond pour le thème sombre */
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    /* Légère ombre pour le thème sombre */
}

.skills-list li:hover {
    transform: translateY(-3px);
    /* Légère élévation au survol */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    /* Accentuation de l'ombre au survol */
}

.dark-theme .skills-list li:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    /* Accentuation de l'ombre au survol pour le thème sombre */
}

.skills-list li strong {
    color: var(--light-text);
    /* Couleur du texte en gras pour le thème clair */
    margin-right: 10px;
    /* Espacement entre le texte en gras et le reste */
}

.dark-theme .skills-list li strong {
    color: var(--dark-text);
    /* Couleur du texte en gras pour le thème sombre */
}

.skills-list li::before {
    content: "✔";
    /* Icône ou symbole avant chaque élément */
    color: #4caf50;
    /* Couleur verte pour l'icône */
    font-size: 18px;
    /* Taille de l'icône */
    margin-right: 10px;
    /* Espacement entre l'icône et le texte */
}