/* Advanced Styles for Walter Betancur Website */

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

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

@keyframes particle {
    0% {
        transform: translateY(0) translateX(0) scale(1);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) translateX(100px) scale(0);
        opacity: 0;
    }
}

/* Animation Classes */
.animate-fade-in {
    animation: fadeIn 1s ease-out;
}

.animate-slide-up {
    animation: slideUp 0.8s ease-out;
}

.delay-1 {
    animation-delay: 0.2s;
    opacity: 0;
    animation-fill-mode: forwards;
}

.delay-2 {
    animation-delay: 0.4s;
    opacity: 0;
    animation-fill-mode: forwards;
}

.delay-3 {
    animation-delay: 0.6s;
    opacity: 0;
    animation-fill-mode: forwards;
}

.animate-in {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ============================================
   HERO SECTION ENHANCEMENTS
   ============================================ */

.hero-badge {
    display: inline-block;
    background: rgba(255, 200, 0, 0.15);
    color: var(--mostaza);
    padding: 0.6rem 1.5rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    border: 2px solid var(--mostaza);
    margin-bottom: 1.5rem;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--blanco-crema);
    color: var(--blanco-crema);
}

.btn-outline:hover {
    background: var(--blanco-crema);
    color: var(--verde-fondo);
}

.btn-icon {
    margin-left: 0.5rem;
    transition: transform 0.3s;
}

.btn:hover .btn-icon {
    transform: translateX(5px);
}

.hero-stats {
    display: flex;
    gap: 3rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-stats .stat-item {
    text-align: center;
}

.hero-stats .stat-item h3 {
    font-size: 3rem;
    font-weight: 800;
    color: var(--mostaza);
    margin-bottom: 0.5rem;
    line-height: 1;
}

.hero-stats .stat-item p {
    color: var(--blanco-crema);
    font-size: 0.95rem;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    cursor: pointer;
    z-index: 10;
    text-align: center;
    transition: opacity 0.3s;
}

.scroll-indicator span {
    display: block;
    width: 24px;
    height: 40px;
    border: 2px solid var(--blanco-crema);
    border-radius: 20px;
    margin: 0 auto 10px;
    position: relative;
}

.scroll-indicator span::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 8px;
    background: var(--blanco-crema);
    border-radius: 2px;
    animation: scroll 2s infinite;
}

.scroll-indicator p {
    color: var(--blanco-crema);
    font-size: 0.85rem;
    font-weight: 500;
}

@keyframes scroll {
    0% {
        transform: translateX(-50%) translateY(0);
        opacity: 0;
    }
    40% {
        opacity: 1;
    }
    80% {
        transform: translateX(-50%) translateY(20px);
        opacity: 0;
    }
    100% {
        opacity: 0;
    }
}

/* Particles */
.hero-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
}

.particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--blanco-crema);
    border-radius: 50%;
    opacity: 0;
    animation: particle linear infinite;
}

/* ============================================
   HEADER ENHANCEMENTS
   ============================================ */

.header.scrolled {
    background-color: rgba(57, 93, 83, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.header-hidden {
    transform: translateY(-100%);
}

.header {
    transition: all 0.3s ease;
}

/* ============================================
   SECTION SUBTITLE
   ============================================ */

.section-subtitle {
    display: inline-block;
    color: var(--mostaza);
    font-weight: 600;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 1rem;
}

/* ============================================
   ABOUT SECTION ENHANCEMENTS
   ============================================ */

.about-image-container {
    position: relative;
}

.about-image-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50%;
    background: linear-gradient(to top, rgba(57, 93, 83, 0.8), transparent);
    border-radius: 20px;
}

.about-badge {
    position: absolute;
    bottom: -30px;
    right: 30px;
    background: var(--mostaza);
    color: var(--verde-fondo);
    padding: 1.5rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(255, 200, 0, 0.3);
    text-align: center;
    min-width: 140px;
}

.about-badge svg {
    margin-bottom: 0.5rem;
}

.about-badge p {
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.3;
    margin: 0;
}

.about-values {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin: 2rem 0;
}

.value-item {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    padding: 1.5rem;
    background: var(--gris-claro);
    border-radius: 15px;
    transition: transform 0.3s, box-shadow 0.3s;
}

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

.value-item svg {
    flex-shrink: 0;
    color: var(--verde-fondo);
}

.value-item h4 {
    color: var(--verde-fondo);
    margin-bottom: 0.3rem;
    font-size: 1.1rem;
}

.value-item p {
    margin: 0;
    color: #666;
    font-size: 0.95rem;
}

/* ============================================
   PROPOSALS SECTION
   ============================================ */

.proposals {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.proposals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.proposal-card {
    background: var(--blanco);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
    overflow: hidden;
}

.proposal-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(to right, var(--verde-fondo), var(--mostaza));
}

.proposal-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.proposal-number {
    position: absolute;
    top: 20px;
    right: 20px;
    font-size: 3rem;
    font-weight: 800;
    color: rgba(57, 93, 83, 0.05);
    line-height: 1;
}

.proposal-icon {
    color: var(--verde-fondo);
    margin-bottom: 1.5rem;
    display: block;
}

.proposal-card h3 {
    color: var(--verde-fondo);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.proposal-card > p {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.proposal-list {
    list-style: none;
    margin-bottom: 1.5rem;
}

.proposal-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    margin-bottom: 0.8rem;
    color: #555;
    font-size: 0.95rem;
    line-height: 1.5;
}

.proposal-list li svg {
    flex-shrink: 0;
    color: var(--mostaza);
    margin-top: 2px;
}

/* ============================================
   PROJECTS SECTION
   ============================================ */

.projects-section {
    background: var(--blanco);
}

.projects-section .section-header p {
    color: white !important;
}

.projects-tabs {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 0.75rem 2rem;
    border: none;
    background: white;
    color: #395d53;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: 'Poppins', sans-serif;
    font-size: 0.95rem;
    position: relative;
    border-radius: 50px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tab-btn:hover {
    background: #ffc800;
    color: white;
    box-shadow: 0 4px 12px rgba(255, 200, 0, 0.3);
    transform: translateY(-2px);
}

.tab-btn.active {
    background: #395d53;
    color: white;
    box-shadow: 0 4px 15px rgba(57, 93, 83, 0.4);
}

.tab-btn.active::before {
    content: '✓ ';
    margin-right: 0.3rem;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

.projects-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-item-modern {
    background: var(--blanco);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.project-item-modern:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.project-image-modern {
    position: relative;
    height: 250px;
    overflow: hidden;
}

.project-image-modern img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

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

.project-status {
    position: absolute;
    top: 15px;
    right: 15px;
    padding: 0.5rem 1.2rem;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    backdrop-filter: blur(10px);
}

.project-status.en-curso {
    background: rgba(255, 200, 0, 0.9);
    color: var(--verde-fondo);
}

.project-status.completado {
    background: rgba(40, 167, 69, 0.9);
    color: white;
}

.project-status.proximo {
    background: rgba(0, 123, 255, 0.9);
    color: white;
}

.project-info-modern {
    padding: 2rem;
}

.project-info-modern h3 {
    color: var(--verde-fondo);
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.project-info-modern p {
    color: #666;
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.project-progress {
    margin-bottom: 1.5rem;
}

.progress-bar {
    height: 8px;
    background: #e0e0e0;
    border-radius: 10px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(to right, var(--verde-fondo), var(--mostaza));
    border-radius: 10px;
    transition: width 1s ease;
}

.project-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: #777;
}

.project-meta span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.project-meta svg {
    color: var(--mostaza);
    flex-shrink: 0;
}

/* ============================================
   ACHIEVEMENTS TIMELINE
   ============================================ */

.achievements {
    background: var(--verde-fondo);
    color: var(--blanco-crema);
}

.achievements .section-header h2,
.achievements .section-header .section-subtitle {
    color: var(--blanco-crema);
}

.achievements .divider {
    background: linear-gradient(to right, var(--mostaza), var(--blanco-crema));
}

.achievements-timeline {
    position: relative;
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 0;
}

.achievements-timeline::before {
    content: '';
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 4px;
    height: 100%;
    background: rgba(251, 255, 198, 0.2);
}

.timeline-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    position: relative;
}

.timeline-item:nth-child(odd) {
    flex-direction: row;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-marker {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 20px;
    background: var(--mostaza);
    border: 4px solid var(--verde-fondo);
    border-radius: 50%;
    z-index: 2;
}

.timeline-content {
    width: calc(50% - 40px);
    background: rgba(251, 255, 198, 0.1);
    padding: 2rem;
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(251, 255, 198, 0.2);
}

.timeline-date {
    display: inline-block;
    background: var(--mostaza);
    color: var(--verde-fondo);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.timeline-content h3 {
    color: var(--blanco-crema);
    font-size: 1.3rem;
    margin-bottom: 0.8rem;
}

.timeline-content p {
    color: rgba(251, 255, 198, 0.9);
    line-height: 1.7;
}

.timeline-hidden {
    opacity: 0;
    transform: translateX(-50px);
}

.timeline-item:nth-child(even).timeline-hidden {
    transform: translateX(50px);
}

/* ============================================
   GALLERY
   ============================================ */

.gallery {
    background: var(--gris-claro);
}

.gallery-filter {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.7rem 1.8rem;
    border: none;
    background: var(--blanco);
    color: var(--verde-fondo);
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Poppins', sans-serif;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.filter-btn:hover {
    background: var(--verde-fondo);
    color: var(--blanco-crema);
}

.filter-btn.active {
    background: var(--mostaza);
    color: var(--verde-fondo);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.gallery-item {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    transition: opacity 0.3s, transform 0.3s;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

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

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(57, 93, 83, 0.95), transparent);
    padding: 2rem 1.5rem 1.5rem;
    transform: translateY(100%);
    transition: transform 0.3s;
}

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

.gallery-overlay h4 {
    color: var(--blanco-crema);
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.gallery-overlay p {
    color: var(--mostaza);
    font-size: 0.9rem;
    margin: 0;
}

/* ============================================
   CONTACT ENHANCEMENTS
   ============================================ */

.contact-items {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2rem;
}

.contact-item {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
    padding: 1.5rem;
    background: var(--gris-claro);
    border-radius: 15px;
    transition: transform 0.3s;
}

.contact-item:hover {
    transform: translateX(10px);
}

.contact-item svg {
    flex-shrink: 0;
    color: var(--verde-fondo);
}

.social-media {
    padding: 2rem;
    background: var(--gris-claro);
    border-radius: 15px;
}

.social-media h4 {
    color: var(--verde-fondo);
    margin-bottom: 1rem;
}

.social-links-modern {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--verde-fondo);
    color: var(--blanco-crema);
    border-radius: 50%;
    transition: all 0.3s;
}

.social-link:hover {
    background: var(--mostaza);
    color: var(--verde-fondo);
    transform: translateY(-5px);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* ============================================
   BACK TO TOP BUTTON
   ============================================ */

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--mostaza);
    color: var(--verde-fondo);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(255, 200, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background: var(--verde-fondo);
    color: var(--blanco-crema);
    transform: translateY(-5px);
}

/* ============================================
   FOOTER ENHANCEMENTS
   ============================================ */

.footer-quote {
    font-style: italic;
    color: rgba(251, 255, 198, 0.8);
    margin-top: 1rem;
    font-size: 0.95rem;
}

.footer-social {
    display: flex;
    gap: 1rem;
}

.footer-social a {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(251, 255, 198, 0.1);
    border-radius: 50%;
    transition: all 0.3s;
}

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

.footer-social svg {
    color: var(--blanco-crema);
}

.footer-social a:hover svg {
    color: var(--verde-fondo);
}

.heart {
    color: #ff6b6b;
    animation: heartbeat 1.5s infinite;
}

@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    10%, 30% { transform: scale(0.9); }
    20%, 40%, 60%, 80% { transform: scale(1.1); }
    50%, 70% { transform: scale(1.05); }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 768px) {
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-stats {
        gap: 2rem;
    }

    .hero-stats .stat-item h3 {
        font-size: 2.5rem;
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
        justify-content: center;
    }

    .about-content {
        grid-template-columns: 1fr;
    }

    .about-badge {
        right: 20px;
        bottom: -20px;
    }

    .proposals-grid,
    .projects-grid-modern {
        grid-template-columns: 1fr;
    }

    .achievements-timeline::before {
        left: 30px;
    }

    .timeline-item {
        flex-direction: column !important;
        align-items: flex-start;
        padding-left: 60px;
    }

    .timeline-marker {
        left: 30px;
        transform: translateX(0);
    }

    .timeline-content {
        width: 100%;
    }

    .gallery-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

@media (max-width: 480px) {
    .hero-badge {
        font-size: 0.8rem;
        padding: 0.5rem 1rem;
    }

    .section-subtitle {
        font-size: 0.85rem;
    }

    .proposal-card,
    .project-info-modern {
        padding: 1.5rem;
    }

    .tab-btn {
        padding: 0.7rem 1.5rem;
        font-size: 0.9rem;
    }
}
