/* Base Styles */
:root {
    --primary-color: #3498db;
    --secondary-color: #2c3e50;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --text-color: #333;
    --bg-color: #f9f9f9;
    --card-bg: #ffffff;
    --header-bg: rgba(255, 255, 255, 0.95);
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    --transition: all 0.3s ease;
}

/* Dark Theme */
[data-theme="dark"] {
    --primary-color: #4da8ff;
    --secondary-color: #1a2530;
    --accent-color: #ff6b6b;
    --light-color: #dcdde1;
    --dark-color: #1a1a1a;
    --text-color: #f5f5f5;
    --bg-color: #121212;
    --card-bg: #1e1e1e;
    --header-bg: rgba(30, 30, 30, 0.95);
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

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

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
}

section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 50px;
    position: relative;
    color: var(--secondary-color);
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 30px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: var(--transition);
    cursor: pointer;
    border: none;
    font-size: 0.9rem;
}

.primary-btn {
    background-color: var(--primary-color);
    color: white;
}

.primary-btn:hover {
    background-color: #2980b9;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.secondary-btn {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.secondary-btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Header Styles */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--header-bg);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

header.scrolled {
    padding: 10px 0;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
}

.logo {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
    cursor: pointer;
}

.nav-links {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--dark-color);
    font-weight: 600;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary-color);
}

.nav-links a:hover::after {
    width: 100%;
}

.burger {
    display: none;
    cursor: pointer;
}

.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--dark-color);
    margin: 5px;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.8), rgba(44, 62, 80, 0.9)), url('../images/hero-bg.jpg');
    background-size: cover;
    background-position: center;
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 10px;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero h2 {
    font-size: 2rem;
    margin-bottom: 20px;
    font-weight: 400;
    color: var(--light-color);
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
}

.social-links {
    display: flex;
    gap: 15px;
}

.social-links a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    transition: var(--transition);
}

.social-links a:hover {
    background-color: white;
    color: var(--primary-color);
    transform: translateY(-3px);
}

/* About Section */
.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.about-image {
    position: relative;
}

.profile-image {
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
}

.profile-image:hover {
    transform: scale(1.02);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.about-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

/* Skills Section */
.skills-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.skill-category {
    background-color: var(--card-bg);
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.skill-category:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.skill-category h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
    position: relative;
    padding-bottom: 10px;
}

.skill-category h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 50px;
    height: 3px;
    background-color: var(--primary-color);
    border-radius: 2px;
}

.skill-items {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.skill-item {
    margin-bottom: 15px;
}

.skill-name {
    font-weight: 600;
    margin-bottom: 5px;
}

.skill-bar {
    height: 10px;
    background-color: #eee;
    border-radius: 5px;
    overflow: hidden;
}

.skill-level {
    height: 100%;
    background-color: var(--primary-color);
    border-radius: 5px;
    position: relative;
}

/* Taekwondo Section */
.taekwondo {
    background-color: #f5f5f5;
}

.taekwondo-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.taekwondo-image {
    position: relative;
}

.taekwondo-img {
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: var(--transition);
}

.taekwondo-img:hover {
    animation: taekwondoKick 1.5s ease;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.taekwondo-text h3 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: var(--secondary-color);
}

.taekwondo-text p {
    margin-bottom: 20px;
    font-size: 1.1rem;
}

.taekwondo-values {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.value {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 20px;
    background-color: var(--card-bg);
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.value:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.value i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.value:hover i {
    transform: scale(1.2) rotate(360deg);
    color: var(--accent-color);
    transition: transform 0.6s ease, color 0.3s ease;
}

.value h4 {
    font-size: 1.2rem;
    color: var(--secondary-color);
}

/* Taekwondo Gallery */
.taekwondo-gallery {
    margin-top: 50px;
}

.taekwondo-gallery h3 {
    font-size: 1.8rem;
    margin-bottom: 25px;
    color: var(--secondary-color);
    text-align: center;
}

.gallery-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.gallery-item {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    height: 250px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.gallery-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.gallery-item:hover img {
    transform: scale(1.1);
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    padding: 20px;
    color: white;
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
    transform: translateY(0);
}

.gallery-overlay span {
    font-size: 1.1rem;
    font-weight: 600;
}

/* Animation spéciale pour la section Taekwondo */
@keyframes taekwondoKick {
    0% {
        transform: rotate(0deg) translateX(0);
    }
    25% {
        transform: rotate(15deg) translateX(10px);
    }
    50% {
        transform: rotate(0deg) translateX(0);
    }
    75% {
        transform: rotate(-15deg) translateX(-10px);
    }
    100% {
        transform: rotate(0deg) translateX(0);
    }
}

/* Projects Section */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.project-card {
    background-color: var(--card-bg);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.project-image {
    height: 200px;
    overflow: hidden;
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

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

.project-info {
    padding: 20px;
}

.project-info h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.project-info p {
    margin-bottom: 15px;
    color: #666;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.project-tags span {
    background-color: #eee;
    color: var(--secondary-color);
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.project-links {
    display: flex;
    gap: 15px;
}

.project-links a {
    display: flex;
    align-items: center;
    gap: 5px;
    font-weight: 600;
    font-size: 0.9rem;
}

.projects-more {
    text-align: center;
    margin-top: 40px;
}

/* Timeline Section */
.timeline {
   
    padding: 80px 0;
}

.timeline-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 40px 0;
}

.timeline-container::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: var(--primary-color);
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    width: 50%;
    padding: 20px 40px;
    box-sizing: border-box;
    margin-bottom: 50px;
}

.timeline-item:nth-child(odd) {
    left: 0;
}

.timeline-item:nth-child(even) {
    left: 50%;
}

.timeline-dot {
    position: absolute;
    width: 20px;
    height: 20px;
    background-color: var(--accent-color);
    border-radius: 50%;
    top: 20px;
    z-index: 1;
    box-shadow: 0 0 0 4px var(--primary-color);
}

.timeline-item:nth-child(odd) .timeline-dot {
    right: -10px;
}

.timeline-item:nth-child(even) .timeline-dot {
    left: -10px;
}

.timeline-date {
    position: absolute;
    top: 18px;
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--primary-color);
}

.timeline-item:nth-child(odd) .timeline-date {
    right: -120px;
}

.timeline-item:nth-child(even) .timeline-date {
    left: -120px;
}

.timeline-content {
    padding: 25px;
    background-color: var(--card-bg);
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.timeline-content:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.timeline-content h3 {
    margin-bottom: 10px;
    font-size: 1.3rem;
    color: var(--secondary-color);
}

.timeline-content p {
    color: var(--text-color);
    line-height: 1.6;
}

/* Timeline Responsive */
@media screen and (max-width: 768px) {
    .timeline-container::after {
        left: 40px;
    }
    
    .timeline-item {
        width: 100%;
        padding-left: 80px;
        padding-right: 20px;
        left: 0 !important;
    }
    
    .timeline-dot {
        left: 31px !important;
        right: auto !important;
    }
    
    .timeline-date {
        position: relative;
        top: -5px;
        left: 0 !important;
        right: auto !important;
        margin-bottom: 10px;
        display: inline-block;
    }
}

/* Contact Section */
.contact {
    background-color: #f5f5f5;
}

.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.contact-item {
    background-color: var(--card-bg);
    padding: 25px;
    border-radius: 10px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: center;
}

.contact-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.contact-item i {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.contact-item h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--secondary-color);
}

.contact-item a {
    color: var(--primary-color);
    transition: var(--transition);
}

.contact-item a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

.contact-form {
    background-color: var(--card-bg);
    padding: 30px;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.download-cv {
    margin-top: 30px;
    text-align: center;
}

.download-cv .btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 25px;
    font-weight: 600;
    transition: var(--transition);
}

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

.download-cv .btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--secondary-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

/* Footer */
footer {
    background-color: var(--secondary-color);
    color: white;
    padding: 40px 0;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-logo {
    font-size: 2rem;
    font-weight: 700;
    color: white;
}

.footer-social {
    display: flex;
    gap: 15px;
}

.footer-social a {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    font-size: 1.2rem;
    transition: var(--transition);
}

.footer-social a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

/* Theme Switch */
.theme-switch {
    display: flex;
    align-items: center;
    margin-right: 20px;
}

.theme-switch i {
    color: var(--dark-color);
    font-size: 1.2rem;
}

.theme-switch .fa-sun {
    color: #f1c40f;
    margin-right: 8px;
}

.theme-switch .fa-moon {
    color: #34495e;
    margin-left: 8px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider {
    background-color: var(--primary-color);
}

input:focus + .slider {
    box-shadow: 0 0 1px var(--primary-color);
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

/* Responsive Styles */
@media screen and (max-width: 992px) {
    .about-content,
    .taekwondo-content,
    .contact-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .about-image,
    .taekwondo-image {
        order: -1;
    }
    
    .hero h1 {
        font-size: 3rem;
    }
    
    .hero h2 {
        font-size: 1.6rem;
    }
}

@media screen and (max-width: 768px) {
    .nav-links {
        position: absolute;
        right: 0;
        top: 80px;
        background-color: white;
        width: 100%;
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        transform: translateY(-150%);
        transition: transform 0.5s ease;
        z-index: 999;
    }
    
    .nav-links.active {
        transform: translateY(0);
    }
    
    .nav-links li {
        margin: 15px 0;
    }
    
    .burger {
        display: block;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero h2 {
        font-size: 1.4rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        gap: 15px;
    }
    
    .contact-info {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
}

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

.animated {
    animation: fadeInUp 0.6s ease forwards;
}

/* Burger Animation */
.toggle .line1 {
    transform: rotate(-45deg) translate(-5px, 6px);
}

.toggle .line2 {
    opacity: 0;
}

.toggle .line3 {
    transform: rotate(45deg) translate(-5px, -6px);
}
