/* Header */
header {
    position: relative;
    padding: 2rem;
    text-align: center;
    background: rgba(10, 14, 39, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 2px solid #00ffff;
    z-index: 10;
}

header img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    aspect-ratio: 1/1;
    border: 3px solid #00ffff;
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.4);
    margin-bottom: 1rem;
}

nav {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

nav a {
    color: #00ffff;
    text-decoration: none;
    font-weight: bold;
    padding: 0.5rem 1rem;
    border: 2px solid transparent;
    border-radius: 5px;
    transition: all 0.3s;
    position: relative;
}

nav a:hover {
    border-color: #00ffff;
    background: rgba(0, 255, 255, 0.1);
    transform: translateY(-2px);
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr) !important;
    grid-auto-rows: 160px;
    gap: 15px;
    max-width: 1000px;
    margin: 30px auto;
}

.skill-card {
    background: #0f172a;
    border: 1px solid #1e293b;
    padding: 10px;
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    text-align: left;
}

.skill-card h3 {
    color: #ffffff;
    font-size: 1.2rem;
    margin: 0;
    z-index: 2;
}

.skill-card p {
    color: #94a3b8;
    font-size: 0.85rem;
    margin: 0;
    z-index: 2;
    line-height: 1.4;
}


.theme-code {
    border-left: 5px solid #3b82f6;
}

.theme-code .bento-icon {
    color: #3b82f6;
}

.theme-gamedev {
    border-left: 5px solid #a855f7;
}

.theme-gamedev .bento-icon {
    color: #a855f7;
}

.theme-design {
    border-left: 5px solid #f43f5e;
}

.theme-design .bento-icon {
    color: #f43f5e;
}

.theme-tools {
    border-left: 5px solid #10b981;
}

.theme-tools .bento-icon {
    color: #10b981;
}

/* Progressbar Skills */
.skills-progressbar {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 2rem;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.skill-item {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.skill-header {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.skill-header i {
    font-size: 1.2rem;
    color: #00ffff;
}

.skill-header h3 {
    color: #f8fafc;
    font-size: 1rem;
    margin: 0;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(30, 41, 59, 0.7);
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid rgba(56, 189, 248, 0.2);
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, #00ffff);
    border-radius: 10px;
    width: 0%;
    transition: width 1.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.progress-fill.animated {
    width: 100%;
}

.level-label {
    font-size: 0.8rem;
    color: #94a3b8;
    font-weight: 600;
}

.theme-code::before {
    background: #3b82f6;
}

.theme-gamedev::before {
    background: #a855f7;
}

.theme-design::before {
    background: #f43f5e;
}

.theme-tools::before {
    background: #10b981;
}

.skill-card::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    width: var(--level, 0%);
    background: currentColor;
    opacity: 0.6;
    transition: width 1s ease-in-out;
}

#search-bar {
    margin-bottom: 2rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.search-container {
    position: relative;
    display: flex;
    gap: 1rem;
    align-items: center;
}

#search-input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    background: rgba(26, 26, 46, 0.7);
    border: 2px solid rgba(0, 255, 255, 0.3);
    border-radius: 10px;
    color: #fff;
    font-size: 1rem;
    transition: all 0.3s;
}

#search-input:focus {
    outline: none;
    border-color: #00ffff;
    box-shadow: 0 0 20px rgba(0, 255, 255, 0.3);
}

#search-input::placeholder {
    color: #888;
}

.search-icon {
    position: absolute;
    left: 1rem;
    color: #00ffff;
    font-size: 1.2rem;
    pointer-events: none;
}

#clear-search {
    padding: 0.8rem 1.5rem;
    background: rgba(255, 0, 255, 0.2);
    border: 2px solid #ff00ff;
    border-radius: 10px;
    color: #ff00ff;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: bold;
    white-space: nowrap;
}

#clear-search:hover {
    background: #ff00ff;
    color: #0a0e27;
    transform: scale(1.05);
}

.project-card.hidden {
    display: none;
}

.no-results {
    text-align: center;
    color: #888;
    font-size: 1.2rem;
    padding: 3rem;
    grid-column: 1 / -1;
}

.project-card {
    background: linear-gradient(135deg, rgba(26, 26, 46, 0.9), rgba(22, 33, 62, 0.9));
    padding: 2rem;
    border-radius: 15px;
    border: 2px solid rgba(0, 255, 255, 0.2);
    transition: all 0.4s;
    position: relative;
    overflow: hidden;

    display: flex;
    flex-direction: column;
}

.project-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(0, 255, 255, 0.1), transparent);
    transform: rotate(45deg);
    transition: all 0.6s;

    z-index: -1;
}

.project-card:hover::before {
    left: 100%;
}

.project-card:hover {
    transform: translateY(-10px);
    border-color: #ff00ff;
    box-shadow: 0 15px 40px rgba(255, 0, 255, 0.4);
}

.project-card h3 {
    color: #00ffff;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.project-card p {
    color: #ccc;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.project-card img {
    aspect-ratio: 16/9;
    width: 100%;
    object-fit: cover;
    border-radius: 10px;
    border: solid rgba(0, 255, 255, 0.3) 1px;

    position: relative;
    z-index: 2;
}

.project-card a {
    color: rgb(146, 164, 251);
}

.project-card a:hover {
    text-decoration: underline;
    color: #00ffff;
}

.tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;

    position: relative;
    z-index: 2;
}

.tech-tag {
    background: rgba(255, 0, 255, 0.2);
    color: #ff00ff;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    border: 1px solid #ff00ff;
}

.date-tag {
    display: block;
    width: fit-content;
    position: relative;

    margin-left: auto;
    margin-top: auto;
    margin-bottom: 0;

    background: #0a0e27;
    color: #00ffff;
    padding: 0.3rem 0.8rem;
    border-radius: 1px;
    font-size: 0.85rem;
    border: 1px solid #00ffff;
}

.date-tag::after {
    content: "Dernier commit le " attr(data-date);
    position: absolute;
    bottom: 120%;
    /* au-dessus */
    right: 0;

    background: #000;
    color: #fff;
    padding: 0.3rem 0.6rem;
    font-size: 0.75rem;
    border-radius: 4px;

    opacity: 0;
    pointer-events: none;
    white-space: nowrap;
    transition: opacity 0.2s ease;
}

.date-tag:hover::after {
    opacity: 1;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
    flex-wrap: wrap;
}

.social-links a {
    color: #00ffff;
    font-size: 1.2rem;
    text-decoration: none;
    padding: 1rem 2rem;
    border: 2px solid #00ffff;
    border-radius: 10px;
    transition: all 0.3s;
}

.social-links a:hover {
    background: #00ffff;
    color: #0a0e27;
    transform: scale(1.1);
}

footer {
    text-align: center;
    padding: 2rem;
    color: #666;
    border-top: 1px solid rgba(0, 255, 255, 0.3);
}

@keyframes balancier {
    0% {
        transform: rotate(-30deg) scale(0.8);
    }

    50% {
        transform: rotate(30deg) scale(1.1);
    }

    100% {
        transform: rotate(-30deg) scale(0.8);
    }
}

.container-logos {
    display: grid;
    grid-template-columns: 1fr;
    justify-items: center;
    align-items: end;

    margin: 0px 0;
    height: auto;
    overflow: hidden;
    padding: 3em;
}

.logo1,
.logo2 {
    grid-column: 1;
    grid-row: 1;

    object-fit: cover;
    border-radius: 50px;
    border: solid rgba(0, 255, 255, 0.3) 1px;

    transform-origin: bottom center;
    animation: balancier 3s ease-in-out infinite;
}

.logo1 {
    width: 15vw;
    transform: rotate(-30deg);
    z-index: 3;
}

.logo2 {
    width: 20vw;
    transform: rotate(30deg);
    z-index: 2;
    opacity: 0.3;
    animation-delay: -1.5s;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 768px) {
    .timeline::before {
        left: 20px;
    }

    .timeline-item,
    .timeline-item:nth-child(even) {
        flex-direction: column;
        justify-content: flex-start;
        padding-left: 80px;
    }

    .timeline-marker {
        left: 20px;
    }

    .timeline-content {
        width: 100%;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 12px;
    }

    nav {
        margin-top: 0rem;
        gap: 0.5rem;
    }

    nav a {
        padding: 0.5rem 0.2rem;
        border: 1px solid transparent;
        border-radius: 5px;
        position: relative;
    }

    nav a:hover {
        transform: translateY(-1px);
    }
}

@media (max-width: 768px) {
    .bento-grid {
        gap: 5px;
        padding: 5px;
        grid-auto-rows: 100px !important;
    }

    .skill-card {
        padding: 7px;
        border-radius: 12px;
    }

    .skill-card::after,
    .skill-card.large::after,
    .skill-card.medium::after {
        height: 1px;
    }

    .skill-card h3 {
        font-size: 1.1rem;
        margin-bottom: 2px;
    }

    .skill-card p {
        font-size: 0.8rem;
        line-height: 1.2;
    }

    .bento-icon {
        font-size: 1.5rem;
        top: 8px;
        right: 8px;
    }
}

@media (max-width: 768px) {
    .project-card {
        padding: 1rem !important;
        min-height: auto;
    }

    .project-card h3 {
        font-size: 1rem !important;
        margin-bottom: 0.5rem;
    }

    .project-card p {
        font-size: 1rem !important;
        display: -webkit-box;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .tech-tag {
        font-size: 0.8rem !important;
        padding: 0.2rem 0.5rem !important;
    }

    .date-tag {
        font-size: 0.6rem !important;
        padding: 0.2rem 0.4rem !important;
    }
}

@media (max-width: 768px) {
    .social-links {
        gap: 1rem;
    }

    .social-links a {
        font-size: 1rem;
        padding: 1rem 1rem;
        border: 1px solid #00ffff;
        border-radius: 7px;
    }
}

@media (max-width: 768px) {
    .skills-progressbar {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    footer {
        padding: 0.7rem;
    }
}
