/**
 * Portfolio Enhancements CSS
 * Wave animation, typewriter styles, and improved hover effects
 */

/* ===================================================================
 * Wave Animation for Emoji
 * ------------------------------------------------------------------- */
.wave {
    animation-name: wave-animation;
    animation-duration: 2.5s;
    animation-iteration-count: infinite;
    transform-origin: 70% 70%;
    display: inline-block;
}

@keyframes wave-animation {
    0% { transform: rotate(0deg); }
    10% { transform: rotate(14deg); }
    20% { transform: rotate(-8deg); }
    30% { transform: rotate(14deg); }
    40% { transform: rotate(-4deg); }
    50% { transform: rotate(10deg); }
    60% { transform: rotate(0deg); }
    100% { transform: rotate(0deg); }
}

/* ===================================================================
 * Intro Section Fixed Size (Prevent Layout Shift)
 * ------------------------------------------------------------------- */

.s-intro .text-huge-title {
    height: 600px; /* Fixed height for the entire title block */
}

/* ===================================================================
 * Typewriter Effect Styles
 * ------------------------------------------------------------------- */
.typewriter-text {
    color: var(--color-1, #eabe7c);
    font-weight: 600;
    display: inline-block;
}

.typewriter-text .Typewriter__wrapper {
    display: inline-block;
}

.typewriter-text .Typewriter__cursor {
    color: var(--color-1, #eabe7c);
    font-size: inherit;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 49% { opacity: 1; }
    50%, 100% { opacity: 0; }
}

/* ===================================================================
 * Enhanced Project Card Hover Effects
 * ------------------------------------------------------------------- */
.folio-list__item {
    transition: all 0.3s ease;
}

.folio-list__item:hover {
    transform: scale(1.03) translateY(-5px);
}

.folio-list__item-link {
    display: block;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.folio-list__item-pic {
    transition: transform 0.5s ease;
    overflow: hidden;
}

.folio-list__item:hover .folio-list__item-pic {
    transform: scale(1.05);
}

.folio-list__item-pic img {
    transition: filter 0.3s ease, opacity 0.3s ease;
}

.folio-list__item:hover .folio-list__item-pic img {
    filter: brightness(1.1);
    opacity: 0.9;
}

/* ===================================================================
 * Tech Stack Icons Enhancement (Optional)
 * ------------------------------------------------------------------- */
.tech-icons-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.tech-icon-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px 20px;
    background: rgba(234, 190, 124, 0.1);
    border: 2px solid rgba(234, 190, 124, 0.3);
    border-radius: 12px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.tech-icon-item:hover {
    transform: translateY(-5px) scale(1.05);
    border-color: var(--color-1, #eabe7c);
    box-shadow: 0 10px 25px rgba(234, 190, 124, 0.2);
}

.tech-icon-item i {
    font-size: 2rem;
    margin-right: 10px;
    color: var(--color-1, #eabe7c);
}

.tech-icon-item span {
    font-weight: 600;
    color: #fff;
}

/* ===================================================================
 * Smooth Scroll Enhancement
 * ------------------------------------------------------------------- */
html {
    scroll-behavior: smooth;
}

/* ===================================================================
 * Loading Animation Enhancement
 * ------------------------------------------------------------------- */
#preloader {
    transition: opacity 0.5s ease-out;
}

/* ===================================================================
 * Social Links Hover Enhancement
 * ------------------------------------------------------------------- */
.intro-social li a {
    position: relative;
    transition: all 0.3s ease;
}

.intro-social li a::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-1, #eabe7c);
    transition: width 0.3s ease;
}

.intro-social li a:hover::before {
    width: 100%;
}

.intro-social li a:hover {
    color: var(--color-1, #eabe7c);
    transform: translateY(-2px);
}

/* ===================================================================
 * Button Hover Enhancements
 * ------------------------------------------------------------------- */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}

/* ===================================================================
 * Timeline Bullet Animation
 * ------------------------------------------------------------------- */
.timeline__bullet {
    transition: all 0.3s ease;
}

.timeline__block:hover .timeline__bullet {
    transform: scale(1.3);
    box-shadow: 0 0 0 4px rgba(234, 190, 124, 0.2);
}

/* ===================================================================
 * Progress Bar Enhancement
 * ------------------------------------------------------------------- */
progress {
    transition: all 0.3s ease;
}

progress:hover {
    filter: brightness(1.2);
    transform: scaleX(1.02);
}

/* ===================================================================
 * Fade-in Animation for Sections
 * ------------------------------------------------------------------- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-on-scroll {
    animation: fadeInUp 0.8s ease-out;
}

/* ===================================================================
 * Mobile Responsiveness
 * ------------------------------------------------------------------- */
@media (max-width: 768px) {
    .wave {
        font-size: 1.5rem;
    }
    
    .tech-icons-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 15px;
    }
    
    .folio-list__item:hover {
        transform: scale(1.02) translateY(-3px);
    }
}

/* ===================================================================
 * Intro Tagline Styling
 * ------------------------------------------------------------------- */
.intro-tagline {
    margin-top: 30px;
    text-align: left;
    font-size: 1rem; /* Reset from h1 inheritance */
    line-height: 1.6; /* Reset from h1 inheritance */
    font-weight: 400; /* Reset from h1 inheritance */
}

.tagline-text {
    font-size: 1.1rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 12px;
    letter-spacing: 0.5px;
    line-height: 1.6;
}

.tagline-text .highlight {
    color: var(--color-1, #eabe7c);
    font-weight: 600;
}

.availability-status {
    font-size: 0.95rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.9);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    line-height: 1.4;
    padding: 8px 16px;
    background: rgba(74, 222, 128, 0.1);
    border: 1px solid rgba(74, 222, 128, 0.3);
    border-radius: 20px;
    margin-top: 5px;
    width: fit-content;
}

.status-indicator {
    width: 8px;
    height: 8px;
    background-color: #4ade80;
    border-radius: 50%;
    display: inline-block;
    animation: pulse 2s infinite;
}

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

@media (max-width: 768px) {
    .intro-tagline {
        margin-top: 20px;
    }
    
    .tagline-text {
        font-size: 0.95rem;
    }

    .availability-status {
        font-size: 0.85rem;
    }
}

@media (max-width: 600px) {
    .intro-tagline {
        margin-top: 15px;
    }
    
    .tagline-text {
        font-size: 0.85rem;
    }

    .availability-status {
        font-size: 0.75rem;
    }
}
