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

:root {
    --primary-color: #6366f1;
    --secondary-color: #a855f7;
    --accent-color: #ec4899;
    --dark-bg: #0f172a;
    --light-text: #f1f5f9;
    --muted-text: #cbd5e1;
    --border-radius: 16px;
    --transition: all 0.3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 25%, #7e8ba3 50%, #4facfe 75%, #00d4ff 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: var(--light-text);
    min-height: 100vh;
    overflow-x: hidden;
    transition: background 0.4s ease, color 0.4s ease;
}

body.light-mode {
    background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 25%, #90caf9 50%, #64b5f6 75%, #42a5f5 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: #1a1a1a;
}

.container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.content {
    width: 100%;
    max-width: 500px;
    text-align: center;
    animation: fadeInDown 0.8s ease;
}

/* Animaciones */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes zoomHover {
    from {
        transform: scale(1);
    }
    to {
        transform: scale(1.1);
    }
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Avatar */
.avatar {
    margin-bottom: 30px;
    /* animation: float 3s ease-in-out infinite; */
}

.avatar-img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--light-text);
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.3);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

body.light-mode .avatar-img {
    border-color: #1a1a1a;
    box-shadow: 0 10px 40px rgba(42, 82, 152, 0.3);
}

/* Botón de tema */
.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid #ffffff;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    font-size: 1.3rem;
    cursor: pointer;
    transition: var(--transition);
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
}

.theme-toggle:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.1);
}

body.light-mode .theme-toggle {
    border-color: #1a1a1a;
    background: rgba(26, 26, 26, 0.1);
    color: #1a1a1a;
}

body.light-mode .theme-toggle:hover {
    background: rgba(26, 26, 26, 0.2);
}

.avatar-placeholder {
    width: 120px;
    height: 120px;
    margin: 0 auto;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 60px;
    box-shadow: 0 10px 40px rgba(99, 102, 241, 0.3);
    border: 3px solid var(--light-text);
    opacity: 0.9;
}

/* Nombre */
.name {
    font-family: 'Poppins', sans-serif;
    font-size: 2.5rem;
    font-weight: 400;
    margin-bottom: 3px;
    letter-spacing: -0.5px;
    animation: slideInUp 0.8s ease 0.1s both;
    color: #ffffff;
    transition: color 0.4s ease;
}

body.light-mode .name {
    color: #1a1a1a;
}

/* Profesión */
.profession {
    font-size: 1.1rem;
    margin-bottom: 10px;
    animation: slideInUp 0.8s ease 0.2s both;
    color: #ffffff;
    transition: color 0.4s ease;
}

body.light-mode .profession {
    color: #333333;
}

.profession .separator {
    margin: 0 8px;
    opacity: 0.5;
}

.profession .role {
    /* color: var(--primary-color); */
    font-weight: 400;
}

.profession .hobby {
    /* color: var(--secondary-color); */
    font-weight: 400;
}

/* Descripción */
.description {
    font-size: 1rem;
    color: var(--muted-text);
    margin-bottom: 40px;
    line-height: 1.6;
    max-width: 450px;
    margin-left: auto;
    margin-right: auto;
    animation: slideInUp 0.8s ease 0.3s both;
}

/* Contenedor de Enlaces */
.links-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 40px;
}

/* Botones de Enlaces */
.link-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 16px 24px;
    border: 2px solid #ffffff;
    border-radius: var(--border-radius);
    font-size: 1rem;
    font-weight: 400;
    text-decoration: none;
    cursor: pointer;
    transition: var(--transition);
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    position: relative;
    overflow: hidden;
    animation: slideInUp 0.8s ease both;
}

body.light-mode .link-button {
    border-color: #1a1a1a;
    color: #1a1a1a;
    background: rgba(26, 26, 26, 0.08);
}

body.light-mode .link-button:hover {
    background: rgba(26, 26, 26, 0.15);
    box-shadow: 0 10px 25px rgba(26, 26, 26, 0.2);
}

.link-button:nth-child(1) { animation-delay: 0.4s; }
.link-button:nth-child(2) { animation-delay: 0.5s; }
.link-button:nth-child(3) { animation-delay: 0.6s; }
.link-button:nth-child(4) { animation-delay: 0.7s; }
.link-button:nth-child(5) { animation-delay: 0.8s; }

.link-button i {
    font-size: 1.3rem;
    transition: var(--transition);
}

/* Estilos específicos de botones */
.link-button.portfolio {
    border-color: #ffffff;
    color: #ffffff;
}

.link-button.portfolio:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.3);
}

.link-button.instagram {
    border-color: #ffffff;
    color: #ffffff;
}

.link-button.instagram:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.3);
}

.link-button.github {
    border-color: #ffffff;
    color: #ffffff;
}

.link-button.github:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.3);
}

.link-button.whatsapp {
    border-color: #ffffff;
    color: #ffffff;
}

.link-button.whatsapp:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.3);
}

.link-button.linkedin {
    border-color: #ffffff;
    color: #ffffff;
}

.link-button.linkedin:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(255, 255, 255, 0.3);
}

/* Footer */
.footer {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    animation: slideInUp 0.8s ease 0.8s both;
    transition: color 0.4s ease, border-color 0.4s ease;
}

body.light-mode .footer {
    color: rgba(26, 26, 26, 0.7);
    border-top: 1px solid rgba(26, 26, 26, 0.1);
}

.heart {
    display: inline-block;
    animation: pulse 1.5s ease-in-out infinite;
    margin: 0 4px;
}

/* Responsive */
@media (max-width: 768px) {
    .theme-toggle {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }

    .name {
        font-size: 2rem;
    }

    .profession {
        font-size: 1rem;
    }

    .description {
        font-size: 0.95rem;
    }

    .link-button {
        padding: 14px 20px;
        font-size: 0.95rem;
    }

    .link-button i {
        font-size: 1.1rem;
    }

    .avatar-placeholder {
        width: 100px;
        height: 100px;
        font-size: 50px;
    }
}

@media (max-width: 480px) {
    .theme-toggle {
        width: 40px;
        height: 40px;
        font-size: 1rem;
        top: 15px;
        right: 15px;
    }

    .container {
        padding: 15px;
    }

    .name {
        font-size: 1.75rem;
    }

    .profession {
        font-size: 0.95rem;
    }

    .avatar-placeholder {
        width: 90px;
        height: 90px;
        font-size: 45px;
    }

    .links-container {
        gap: 10px;
    }

    .link-button {
        padding: 12px 18px;
        font-size: 0.9rem;
        gap: 10px;
    }

    .link-button i {
        font-size: 1rem;
    }

    .footer {
        font-size: 0.85rem;
    }
}
