@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Outfit:wght@400;500;600;700;800&display=swap');

/* --- Reset & Base Styles --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Color Tokens (Hex) */
    --primary-color: #38BDF8;    /* Celeste */
    --secondary-color: #2563EB;  /* Azul Real */
    --accent-color: #0EA5E9;     /* Celeste Hover */
    
    /* Gradients */
    --gradient-primary: linear-gradient(135deg, #38BDF8 0%, #2563EB 100%);
    --gradient-accent: linear-gradient(135deg, #0EA5E9 0%, #38BDF8 100%);
    --gradient-dark: linear-gradient(180deg, #0F172A 0%, #0d1322 100%);
    
    /* Layout */
    --nav-height: 80px;
    --transition-smooth: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-bounce: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Dark Mode Variables (Default) */
.dark-mode {
    --bg-color: #0F172A;         /* Fondo oscuro Slate */
    --bg-secondary: #1E293B;   /* Slate secundario */
    --card-bg: rgba(30, 41, 59, 0.65);
    --card-hover-bg: rgba(51, 65, 85, 0.85);
    --text-color: #ffffff;       /* Texto blanco */
    --text-secondary: #94A3B8;   /* Texto secundario Slate-400 */
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-border-hover: rgba(255, 255, 255, 0.18);
    --glow-color: rgba(56, 189, 248, 0.15);
    --shadow-color: rgba(0, 0, 0, 0.5);
    --input-bg: rgba(15, 23, 42, 0.8);
}

/* Light Mode Variables */
.light-mode {
    --bg-color: #F8FAFC;
    --bg-secondary: #FFFFFF;
    --card-bg: rgba(255, 255, 255, 0.75);
    --card-hover-bg: rgba(241, 245, 249, 0.9);
    --text-color: #0F172A;
    --text-secondary: #64748B;
    --glass-border: rgba(15, 23, 42, 0.08);
    --glass-border-hover: rgba(15, 23, 42, 0.15);
    --glow-color: rgba(37, 99, 235, 0.08);
    --shadow-color: rgba(15, 23, 42, 0.04);
    --input-bg: rgba(255, 255, 255, 0.95);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color 0.5s ease, color 0.5s ease;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    letter-spacing: -0.02em;
}

/* --- Particles & Backgrounds --- */
#particles-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* --- Container --- */
.container {
    width: 100%;
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 120px 0;
    position: relative;
}

.section-title {
    font-size: 2.8rem;
    text-align: center;
    margin-bottom: 20px;
    background: var(--gradient-accent);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto 60px;
}

/* --- Glassmorphism Card Style --- */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    box-shadow: 0 8px 32px 0 var(--shadow-color);
    transition: var(--transition-smooth);
}

.glass-card:hover {
    background: var(--card-hover-bg);
    border-color: var(--glass-border-hover);
    box-shadow: 0 20px 40px 0 var(--shadow-color), 0 0 20px 0 var(--glow-color);
}

/* --- Header / Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    z-index: 1000;
    background: transparent;
    border-bottom: 1px solid transparent;
    transition: var(--transition-smooth);
}

.navbar.scrolled {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    height: 70px;
    border-bottom: 1px solid var(--glass-border);
    box-shadow: 0 10px 30px var(--shadow-color);
}

.nav-container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 24px;
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-family: 'Outfit', sans-serif;
    font-size: 1.7rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
    transition: var(--transition-bounce);
}

.logo:hover {
    transform: scale(1.03);
    filter: brightness(1.1);
}

.nav-logo {
    height: 38px;
    width: 38px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
    box-shadow: 0 0 10px var(--glow-color);
    transition: var(--transition-bounce);
}

.logo:hover .nav-logo {
    transform: rotate(360deg);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 32px;
    align-items: center;
}

.nav-menu a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: var(--transition-smooth);
    position: relative;
    padding: 6px 0;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: var(--transition-smooth);
    border-radius: 2px;
}

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

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

.nav-actions {
    display: flex;
    gap: 16px;
    align-items: center;
}

/* Theme Toggle Button */
.theme-toggle {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px var(--shadow-color);
    transition: var(--transition-bounce);
}

.theme-toggle:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    transform: rotate(45deg) scale(1.1);
    box-shadow: 0 0 15px var(--glow-color);
}

.theme-toggle:hover svg {
    stroke: #ffffff;
}

.theme-toggle svg {
    width: 20px;
    height: 20px;
    stroke: var(--text-color);
    fill: none;
    transition: stroke 0.3s ease;
}

.icon-moon {
    display: none;
}

.light-mode .icon-sun {
    display: none;
}

.light-mode .icon-moon {
    display: block;
}

/* Hamburger Menu Button */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1100;
}

.hamburger span {
    width: 100%;
    height: 3px;
    background: var(--text-color);
    border-radius: 3px;
    transition: var(--transition-bounce);
}

/* Hamburger active transformation */
.hamburger.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--nav-height);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 15%;
    left: 10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(0, 212, 255, 0.15) 0%, transparent 70%);
    filter: blur(40px);
    pointer-events: none;
    z-index: -1;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: 10%;
    right: 5%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.12) 0%, transparent 70%);
    filter: blur(50px);
    pointer-events: none;
    z-index: -1;
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    gap: 64px;
    align-items: center;
}

.hero-image {
    display: flex;
    justify-content: center;
}

.image-wrapper {
    position: relative;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    padding: 6px;
    background: var(--gradient-primary);
    box-shadow: 0 20px 40px var(--shadow-color);
    animation: floatProfile 6s ease-in-out infinite;
}

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

.profile-photo {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid var(--bg-color);
    background-color: var(--bg-secondary);
}

/* Glowing Aura around profile photo */
.image-wrapper::after {
    content: '';
    position: absolute;
    top: -15px;
    left: -15px;
    right: -15px;
    bottom: -15px;
    background: var(--gradient-primary);
    border-radius: 50%;
    z-index: -2;
    filter: blur(25px);
    opacity: 0.4;
}

.hero-text {
    text-align: left;
}

.hero-name {
    font-size: 3.8rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 12px;
    letter-spacing: -0.03em;
}

.hero-title {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 24px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    max-width: 600px;
    line-height: 1.7;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
    padding: 16px 36px;
    border-radius: 100px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition-bounce);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--gradient-primary);
    color: #ffffff;
    box-shadow: 0 8px 30px rgba(0, 212, 255, 0.25);
}

.btn-primary:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 15px 35px rgba(0, 212, 255, 0.4);
    filter: brightness(1.05);
}

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

.btn-secondary:hover {
    background: var(--gradient-primary);
    color: #ffffff;
    border-color: transparent;
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 10px 25px var(--glow-color);
}

/* --- About Section --- */
.about-content {
    max-width: 860px;
    margin: 0 auto;
    padding: 50px 40px;
    text-align: center;
}

.about-content p {
    font-size: 1.3rem;
    color: var(--text-secondary);
    line-height: 1.85;
    font-weight: 300;
}

/* --- Services Section --- */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.service-card {
    padding: 48px 36px;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    position: relative;
    overflow: hidden;
}

.service-icon {
    width: 64px;
    height: 64px;
    border-radius: 18px;
    background: rgba(0, 212, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 28px;
    border: 1px solid rgba(0, 212, 255, 0.2);
    transition: var(--transition-bounce);
}

.service-card:hover .service-icon {
    background: var(--gradient-primary);
    transform: scale(1.1) rotate(5deg);
    border-color: transparent;
    box-shadow: 0 8px 20px var(--glow-color);
}

.service-icon svg {
    width: 32px;
    height: 32px;
    stroke: var(--primary-color);
    transition: stroke 0.3s ease;
}

.service-card:hover .service-icon svg {
    stroke: #ffffff;
}

.service-card h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 16px;
    line-height: 1.3;
}

.service-card p {
    color: var(--text-secondary);
    font-size: 0.98rem;
    line-height: 1.6;
}

/* --- Portfolio Section --- */
.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 40px;
}

.portfolio-card {
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: var(--transition-smooth);
    box-shadow: 0 10px 30px var(--shadow-color);
}

.portfolio-card:hover {
    transform: translateY(-8px);
    border-color: var(--glass-border-hover);
    box-shadow: 0 20px 40px var(--shadow-color), 0 0 25px var(--glow-color);
}

.portfolio-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
    position: relative;
    border-bottom: 1px solid var(--glass-border);
}

.portfolio-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.portfolio-card:hover .portfolio-image img {
    transform: scale(1.05);
}

.portfolio-content {
    padding: 32px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.portfolio-tag {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--primary-color);
    margin-bottom: 12px;
}

.portfolio-content h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    line-height: 1.25;
}

.portfolio-content p {
    color: var(--text-secondary);
    margin-bottom: 28px;
    font-size: 0.95rem;
    line-height: 1.6;
    flex-grow: 1;
}

.portfolio-content .btn {
    padding: 12px 24px;
    font-size: 0.9rem;
    width: 100%;
    border-radius: 12px;
}

/* --- Why Work With Me Section --- */
.why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 30px;
}

.why-item {
    padding: 36px 28px;
    border-radius: 20px;
    text-align: left;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.why-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(0, 212, 255, 0.1);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    border: 1px solid rgba(0, 212, 255, 0.2);
    box-shadow: 0 4px 10px rgba(0, 212, 255, 0.1);
}

.why-item:hover .why-icon {
    background: var(--gradient-primary);
    color: #ffffff;
    border-color: transparent;
    box-shadow: 0 6px 15px var(--glow-color);
}

.why-item h3 {
    font-size: 1.25rem;
    font-weight: 600;
}

/* --- Social Section --- */
.social-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
}

.social-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    padding: 32px 20px;
    border-radius: 20px;
    text-decoration: none;
    color: var(--text-color);
    border: 1px solid var(--glass-border);
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
}

.social-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, var(--color) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.social-btn:hover {
    transform: translateY(-8px);
    border-color: var(--color);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25), 0 0 15px var(--color);
}

.social-btn:hover::before {
    opacity: 0.12;
}

.social-btn svg {
    width: 36px;
    height: 36px;
    color: var(--color);
    transition: var(--transition-bounce);
}

.social-btn:hover svg {
    transform: scale(1.15);
}

.social-btn span {
    font-weight: 600;
    font-size: 0.95rem;
}

/* --- Contact Section --- */
.contact-content {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 64px;
}

.contact-form {
    padding: 48px;
}

.form-group {
    margin-bottom: 28px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 16px 20px;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    color: var(--text-color);
    font-size: 1rem;
    outline: none;
    transition: var(--transition-smooth);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 15px var(--glow-color);
    background: var(--card-hover-bg);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 24px;
    justify-content: center;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 32px;
}

.contact-icon {
    width: 60px;
    height: 60px;
    background: rgba(0, 212, 255, 0.1);
    border: 1px solid rgba(0, 212, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: var(--transition-bounce);
}

.contact-item:hover .contact-icon {
    background: var(--gradient-primary);
    transform: scale(1.08);
    border-color: transparent;
    box-shadow: 0 8px 20px var(--glow-color);
}

.contact-icon svg {
    width: 26px;
    height: 26px;
    stroke: var(--primary-color);
    fill: none;
    transition: stroke 0.3s ease;
}

.contact-item:hover .contact-icon svg {
    stroke: #ffffff;
}

.contact-item h4 {
    font-size: 1.15rem;
    margin-bottom: 6px;
}

.contact-item p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* --- Footer --- */
.footer {
    background: var(--bg-secondary);
    padding: 60px 0;
    position: relative;
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
    text-align: center;
}

.footer-name {
    font-size: 1.8rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.footer-content p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

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

.footer-social a {
    width: 44px;
    height: 44px;
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-color);
    box-shadow: 0 4px 12px var(--shadow-color);
    transition: var(--transition-bounce);
}

.footer-social a:hover {
    background: var(--gradient-primary);
    color: #ffffff;
    border-color: transparent;
    transform: translateY(-4px) scale(1.1);
    box-shadow: 0 8px 20px var(--glow-color);
}

.footer-social svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

/* --- Floating Utilities --- */
.floating-whatsapp {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: #25D366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: var(--transition-bounce);
    animation: floatButton 4s ease-in-out infinite;
}

@keyframes floatButton {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-8px) scale(1.03);
    }
}

.floating-whatsapp:hover {
    transform: scale(1.1);
    box-shadow: 0 12px 35px rgba(37, 211, 102, 0.6);
}

.floating-whatsapp svg {
    width: 32px;
    height: 32px;
    fill: #ffffff;
}

.scroll-top {
    position: fixed;
    bottom: 105px;
    right: 35px;
    width: 50px;
    height: 50px;
    background: var(--card-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-bounce);
    z-index: 998;
    box-shadow: 0 4px 20px var(--shadow-color);
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    transform: translateY(-6px);
    background: var(--gradient-primary);
    border-color: transparent;
    box-shadow: 0 8px 25px var(--glow-color);
}

.scroll-top:hover svg {
    stroke: #ffffff;
}

.scroll-top svg {
    width: 22px;
    height: 22px;
    stroke: var(--text-color);
    fill: none;
    transition: stroke 0.3s ease;
}

/* --- Scroll Animations (Intersection Observer Classes) --- */
.reveal {
    opacity: 0;
    transition: opacity 0.8s ease, transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-up {
    transform: translateY(50px);
}

.reveal-left {
    transform: translateX(-50px);
}

.reveal-right {
    transform: translateX(50px);
}

.reveal.active {
    opacity: 1;
    transform: translate(0);
}

/* Stagger delays for grid lists (up to 10 elements) */
.reveal.active.delay-1  { transition-delay: 0.1s; }
.reveal.active.delay-2  { transition-delay: 0.2s; }
.reveal.active.delay-3  { transition-delay: 0.3s; }
.reveal.active.delay-4  { transition-delay: 0.4s; }
.reveal.active.delay-5  { transition-delay: 0.5s; }
.reveal.active.delay-6  { transition-delay: 0.6s; }
.reveal.active.delay-7  { transition-delay: 0.7s; }
.reveal.active.delay-8  { transition-delay: 0.8s; }
.reveal.active.delay-9  { transition-delay: 0.9s; }
.reveal.active.delay-10 { transition-delay: 1.0s; }

/* --- Custom Toast Notification --- */
.toast-container {
    position: fixed;
    bottom: 30px;
    left: 30px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.toast {
    background: var(--card-bg);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid var(--glass-border);
    box-shadow: 0 10px 40px var(--shadow-color);
    padding: 16px 24px;
    border-radius: 16px;
    color: var(--text-color);
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 300px;
    max-width: 450px;
    pointer-events: auto;
    animation: toastIn 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
    transition: var(--transition-smooth);
}

.toast.removing {
    animation: toastOut 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.toast-success {
    border-left: 4px solid #25D366;
}

.toast-error {
    border-left: 4px solid #EF4444;
}

.toast-icon {
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.toast-success .toast-icon { color: #25D366; }
.toast-error .toast-icon { color: #EF4444; }

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

@keyframes toastOut {
    to {
        opacity: 0;
        transform: translateY(20px) scale(0.9);
    }
}

/* --- Media Queries --- */
@media (max-width: 1024px) {
    .hero-content {
        gap: 40px;
    }
    .hero-name {
        font-size: 3.2rem;
    }
    .hero-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 968px) {
    .section {
        padding: 80px 0;
    }

    .section-title {
        font-size: 2.3rem;
    }

    .hero {
        padding-top: 100px;
        min-height: auto;
        padding-bottom: 60px;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 48px;
    }

    .hero-image {
        order: -1;
    }

    .hero-text {
        text-align: center;
    }

    .hero-description {
        margin: 0 auto 32px;
    }

    .hero-buttons {
        justify-content: center;
    }

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

    /* Responsive Mobile Menu Drawer */
    .nav-menu {
        position: fixed;
        top: 0;
        right: 0;
        width: 300px;
        height: 100vh;
        background: var(--bg-secondary);
        border-left: 1px solid var(--glass-border);
        box-shadow: -10px 0 30px var(--shadow-color);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 32px;
        padding: 40px;
        transform: translateX(100%);
        transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        z-index: 1050;
    }

    .nav-menu.active {
        transform: translateX(0);
    }

    .hamburger {
        display: flex;
    }
}

@media (max-width: 640px) {
    .container {
        padding: 0 16px;
    }

    .section-title {
        font-size: 2rem;
    }

    .hero-name {
        font-size: 2.4rem;
    }

    .hero-title {
        font-size: 1.3rem;
    }

    .image-wrapper {
        width: 260px;
        height: 260px;
    }

    .contact-form {
        padding: 24px;
    }

    .social-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .floating-whatsapp {
        width: 50px;
        height: 50px;
        bottom: 20px;
        right: 20px;
    }
    
    .floating-whatsapp svg {
        width: 26px;
        height: 26px;
    }

    .scroll-top {
        bottom: 80px;
        right: 25px;
        width: 44px;
        height: 44px;
    }
    
    .scroll-top svg {
        width: 18px;
        height: 18px;
    }
}

/* Modal de Detalles del Proyecto */
.project-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    padding: 20px;
}

.project-modal.active {
    opacity: 1;
    pointer-events: auto;
}

.project-modal-content {
    position: relative;
    width: 100%;
    max-width: 960px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 20px;
    padding: 40px;
    transform: translateY(30px) scale(0.95);
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.project-modal.active .project-modal-content {
    transform: translateY(0) scale(1);
}

.project-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 2.2rem;
    cursor: pointer;
    transition: color 0.3s ease;
    z-index: 10;
    line-height: 1;
}

.project-modal-close:hover {
    color: var(--text-color);
}

.project-modal-body {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 40px;
}

.project-modal-image {
    width: 100%;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.4);
    height: fit-content;
}

.project-modal-image img {
    width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

.project-modal-info h3 {
    font-size: 2rem;
    margin-top: 10px;
    margin-bottom: 15px;
    font-weight: 700;
    color: var(--text-color);
    letter-spacing: -0.5px;
}

.project-modal-info p {
    color: var(--text-secondary);
    line-height: 1.6;
    margin-bottom: 25px;
    font-size: 0.95rem;
}

.project-modal-info h4 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--text-color);
    border-left: 3px solid var(--primary-color);
    padding-left: 10px;
    text-transform: none;
    letter-spacing: normal;
}

.modal-tech-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 25px;
}

.modal-tech-badge {
    background: rgba(56, 189, 248, 0.1);
    color: var(--primary-color);
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 500;
    border: 1px solid rgba(56, 189, 248, 0.15);
}

.modal-features-list {
    list-style: none;
    padding: 0;
    margin-bottom: 30px;
}

.modal-features-list li {
    position: relative;
    padding-left: 24px;
    color: var(--text-secondary);
    margin-bottom: 8px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.modal-features-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

.modal-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.modal-buttons .btn {
    padding: 12px 24px;
    font-size: 0.95rem;
}

/* Responsividad del Modal */
@media (max-width: 768px) {
    .project-modal-body {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .project-modal-content {
        padding: 30px 20px;
        max-height: 95vh;
    }
}
