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

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    font-family:
        Inter,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        Helvetica,
        Arial,
        sans-serif;
    background: linear-gradient( 135deg, #F5EFD6 0%, #f7d1ff 50%, #f1b0ff 100%);
    color: #000000;
}

/*LANGUAGE SWITCHER*/
.language-switcher {
    position: fixed;
    top: 25px;
    right: 30px;
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    z-index: 1200;
}

.language-btn {
    border: none;
    background: transparent;
    color: #777777;
    padding: 7px 11px;
    border-radius: 7px;
    font-family: inherit;
    font-size: 0.75rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.language-btn:hover {
    color: #000000;
}

.language-btn.active {
    background: #000000;
    color: #ffffff;
}

.language-btn:active {
    transform: scale(0.95);
}

/*SIDEBAR*/
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 230px;
    height: 100vh;
    padding: 40px 25px;
    display: flex;
    flex-direction: column;
    background: rgba(255, 255, 255, 0.55);
    border-right: 1px solid rgba(0, 0, 0, 0.08);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    z-index: 1000;
}

.sidebar-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    margin-bottom: 60px;
    border-radius: 12px;
    overflow: hidden;
    background: #000000;
    flex-shrink: 0;
}

.sidebar-logo img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sidebar-nav a,
.sidebar-bottom a {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 14px;
    border-radius: 10px;
    color: #555555;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.sidebar-nav a i,
.sidebar-bottom a i {
    width: 20px;
    text-align: center;
    font-size: 1rem;
}

.sidebar-nav a:hover,
.sidebar-bottom a:hover {
    color: #000000;
    background: rgba(255, 255, 255, 0.7);
    transform: translateX(4px);
}

.sidebar-nav a.active {
    color: #000000;
    background: rgba(255, 255, 255, 0.85);
    font-weight: 600;
}

.sidebar-bottom {
    margin-top: auto;
}

/*MOBILE MENU*/
.menu-toggle {
    display: none;
    position: fixed;
    top: 20px;
    left: 20px;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.55);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    color: #000;
    font-size: 1.15rem;
    cursor: pointer;
    z-index: 1100;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: left 0.3s ease, right 0.3s ease, background 0.3s ease, transform 0.3s ease;
}

.menu-toggle.sidebar-open {
    left: auto;
    right: 20px;
}

/*MAIN PAGE*/
.skills-page {
    margin-left: 230px;
    min-height: 100vh;
    padding: 110px 70px 90px;
}

.skills-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

/*HEADER*/
.skills-header {
    max-width: 900px;
    padding-bottom: 30px;
}

.skills-header h1 {
    max-width: 850px;
    margin-bottom: 28px;
    font-size: clamp(3rem, 6vw, 5rem);
    line-height: 0.98;
    letter-spacing: -0.05em;
    font-weight: 600;
    color: #000000;
}

.skills-intro {
    max-width: 700px;
    font-size: 1.05rem;
    line-height: 1.8;
    color: #333333;
}

/*CERTIFICATIONS GRID*/
.certifications-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 22px;
    padding-top: 40px;
    border-top: 1px solid rgba(0, 0, 0, 0.12);
}

/*CERTIFICATE CARD*/
.certificate-card {
    position: relative;
    aspect-ratio: 4 / 3;
    overflow: hidden;
    border-radius: 14px;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);
    cursor: pointer;
}

.certificate-card > img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: contain;
    transition: transform 0.35s ease;
}

.certificate-card:hover > img {
    transform: scale(1.05);
}

/*HOVER OVERLAY*/
.certificate-overlay {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: flex-end;
    padding: 20px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.65) 55%, rgba(0, 0, 0, 0.08) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.certificate-card:hover .certificate-overlay {
    opacity: 1;
}

/*CERTIFICATE INFORMATION*/
.certificate-info {
    width: 100%;
    transform: translateY(12px);
    transition: transform 0.35s ease;
}

.certificate-card:hover .certificate-info {
    transform: translateY(0);
}

.certificate-info h2 {
    margin-bottom: 7px;
    color: #ffffff;
    font-size: 0.95rem;
    line-height: 1.35;
    font-weight: 600;
}

.certificate-info p {
    margin-bottom: 16px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.72rem;
    line-height: 1.4;
}

/*CERTIFICATE BUTTON*/
.certificate-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 7px;
    background: #ffffff;
    color: #000000;
    text-decoration: none;
    font-size: 0.68rem;
    font-weight: 600;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.certificate-link:hover {
    background: #000000;
    color: #ffffff;
    transform: translateY(-1px);
}

.certificate-link i {
    font-size: 0.65rem;
}

/*TABLET*/
@media (max-width: 1150px) {

    .certifications-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

/*MOBILE*/
@media (max-width: 850px) {

    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .language-switcher {
        top: 20px;
        right: 80px;
    }

    .skills-page {
        margin-left: 0;
        padding: 100px 30px 70px;
    }

    .skills-header {
        padding-bottom: 30px;
    }

    .skills-header h1 {
        font-size: clamp( 2.8rem, 10vw, 4rem);
    }

    .certifications-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 18px;
        padding-top: 35px;
    }

    .certificate-card > img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

    /* Overlay permanente no mobile */
    .certificate-overlay {
        opacity: 1;
        padding: 16px;
        background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.35) 70%, rgba(0, 0, 0, 0) 100%);
    }

    .certificate-info {
        transform: none;
    }
}

/*SMALL MOBILE*/
@media (max-width: 520px) {

    .skills-page {
        padding: 90px 20px 60px;
    }

    .skills-header h1 {
        font-size: 2.7rem;
    }

    .skills-intro {
        font-size: 0.95rem;
        line-height: 1.75;
    }

    .certifications-grid {
        grid-template-columns: 1fr;
        gap: 18px;
    }

    .certificate-card {
        aspect-ratio: 4 / 3;
    }

    .certificate-info h2 {
        font-size: 0.9rem;
    }

    .certificate-info p {
        margin-bottom: 12px;
        font-size: 0.7rem;
    }
}