/* File: css/components/hero.css */

/*
 * ============================================
 *  HERO SECTION STYLES
 * ============================================
 *
 * The hero is the big, impactful section at the top of the home page.
 * It uses a two-column layout on desktop (content left, image right)
 * and stacks to single column on mobile.
 *
 * Special effects:
 * - Floating animated blobs in the background
 * - Grid overlay pattern
 * - Typing cursor animation
 * - Parallax-like depth with layered elements
 * - Social links fixed to left side
 * - Email fixed to right side
 */


/* ---- Hero Container ---- */
.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    padding: calc(var(--header-height) + var(--space-3xl)) 0 var(--space-3xl);
    overflow: hidden;
}

.hero__container {
    display: grid;
    grid-template-columns: 1fr 0.8fr;
    gap: var(--space-3xl);
    align-items: center;
    position: relative;
    z-index: 2;
}


/* ---- Background Decorations ---- */
.hero__bg-decorations {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;   /* Click-through — these are decorative only */
    z-index: 1;
}

/* Animated gradient blobs */
.hero__blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.15;
    animation: blobFloat 20s ease-in-out infinite;
}

.hero__blob--1 {
    width: 500px;
    height: 500px;
    background: var(--accent-primary);
    top: -10%;
    right: -5%;
    animation-delay: 0s;
}

.hero__blob--2 {
    width: 400px;
    height: 400px;
    background: var(--accent-secondary);
    bottom: -10%;
    left: -5%;
    animation-delay: -7s;
}

.hero__blob--3 {
    width: 300px;
    height: 300px;
    background: #a855f7;     /* Purple accent for visual variety */
    top: 40%;
    left: 40%;
    animation-delay: -14s;
}

@keyframes blobFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(30px, -50px) scale(1.1); }
    50% { transform: translate(-20px, 20px) scale(0.9); }
    75% { transform: translate(40px, 30px) scale(1.05); }
}

/* Subtle grid overlay pattern */
.hero__grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(var(--border-color) 1px, transparent 1px),
        linear-gradient(90deg, var(--border-color) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.3;
}


/* ---- Hero Content (Left Side) ---- */
.hero__content {
    position: relative;
    z-index: 2;
}

/* "Hello, I'm" greeting */
.hero__greeting {
    font-size: var(--fs-md);
    color: var(--accent-primary);
    font-family: var(--font-mono);
    margin-bottom: var(--space-md);
    display: flex;
    align-items: center;
    gap: var(--space-sm);
}

.hero__greeting-wave {
    display: inline-block;
    animation: wave 2.5s ease-in-out infinite;
    transform-origin: 70% 70%;
}

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

/* Name (big heading) */
.hero__name {
    font-size: var(--fs-hero);
    font-weight: 800;
    color: var(--text-heading);
    margin-bottom: var(--space-md);
    line-height: 1.1;
}

/* Typing animation wrapper */
.hero__title-wrapper {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: var(--space-xs);
    margin-bottom: var(--space-lg);
    font-size: var(--fs-2xl);
    font-weight: 600;
    min-height: 2.8rem;
}

.hero__title-prefix {
    color: var(--text-secondary);
}

.hero__typed-text {
    color: var(--accent-primary);
    font-family: var(--font-mono);
}

/* Blinking cursor after typed text */
.hero__cursor {
    color: var(--accent-primary);
    font-weight: 300;
    animation: cursorBlink 1s step-end infinite;
}

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

/* Description paragraph */
.hero__description {
    font-size: var(--fs-md);
    color: var(--text-secondary);
    max-width: 540px;
    margin-bottom: var(--space-xl);
    line-height: 1.8;
}

/* Action buttons row */
.hero__actions {
    display: flex;
    gap: var(--space-md);
    flex-wrap: wrap;
    margin-bottom: var(--space-3xl);
}

/* Quick stats row */
.hero__stats {
    display: flex;
    align-items: center;
    gap: var(--space-xl);
}

.hero__stat {
    text-align: center;
}

.hero__stat-number {
    font-size: var(--fs-2xl);
    font-weight: 800;
    color: var(--text-heading);
    display: inline;
}

.hero__stat-suffix {
    font-size: var(--fs-2xl);
    font-weight: 800;
    color: var(--accent-primary);
}

.hero__stat-label {
    display: block;
    font-size: var(--fs-sm);
    color: var(--text-secondary);
    margin-top: var(--space-xs);
    font-family: var(--font-mono);
}

.hero__stat-divider {
    width: 1px;
    height: 40px;
    background: var(--border-color);
}


/* ---- Hero Visual (Right Side — Image/Avatar) ---- */
.hero__visual {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.hero__image-wrapper {
    position: relative;
    width: 350px;
    height: 400px;
}

/* Placeholder avatar (before you add your real photo) */
.hero__image-placeholder {
    width: 100%;
    height: 100%;
    border-radius: var(--radius-lg);
    overflow: hidden;
    position: relative;
    z-index: 2;
}

.hero__avatar-placeholder {
    width: 100%;
    height: 100%;
    background: var(--accent-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 6rem;
    font-weight: 800;
    color: var(--text-on-accent);
    font-family: var(--font-mono);
    opacity: 0.8;
}

/* When you replace with a real image */
.hero__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: var(--radius-lg);
}

/* Decorative border around image */
.hero__image-border {
    position: absolute;
    top: 20px;
    left: 20px;
    width: 100%;
    height: 100%;
    border: 2px solid var(--accent-primary);
    border-radius: var(--radius-lg);
    z-index: 1;
    transition: all var(--transition-base);
}

.hero__image-wrapper:hover .hero__image-border {
    top: 15px;
    left: 15px;
}

/* Decorative dots pattern */
.hero__image-dots {
    position: absolute;
    bottom: -15px;
    right: -15px;
    width: 80px;
    height: 80px;
    z-index: 1;
    background-image: radial-gradient(var(--accent-primary) 2px, transparent 2px);
    background-size: 12px 12px;
    opacity: 0.6;
}


/* ---- Side Elements (Social Links & Email) ---- */
/*
 * These are positioned fixed on the left and right sides of the viewport.
 * They stay in place as you scroll, but only appear on desktop (hidden on mobile).
 */

.hero__social-sidebar,
.hero__email-sidebar {
    position: fixed;
    bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-lg);
    z-index: var(--z-dropdown);
}

.hero__social-sidebar {
    left: 40px;
}

.hero__email-sidebar {
    right: 40px;
}

.hero__social-line {
    width: 1px;
    height: 90px;
    background: var(--text-secondary);
}

.hero__social-link {
    color: var(--text-secondary);
    transition: all var(--transition-fast);
    padding: var(--space-xs);
}

.hero__social-link:hover {
    color: var(--accent-primary);
    transform: translateY(-3px);
}

.hero__email-link {
    font-size: var(--fs-xs);
    font-family: var(--font-mono);
    letter-spacing: 0.1em;
    color: var(--text-secondary);
    writing-mode: vertical-rl;   /* Text flows vertically */
    transition: all var(--transition-fast);
}

.hero__email-link:hover {
    color: var(--accent-primary);
    transform: translateY(-3px);
}


/* ---- Scroll Down Indicator ---- */
.hero__scroll-indicator {
    position: absolute;
    bottom: var(--space-xl);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    animation: scrollBounce 2s ease-in-out infinite;
}

.hero__scroll-mouse {
    width: 24px;
    height: 38px;
    border: 2px solid var(--text-secondary);
    border-radius: 12px;
    position: relative;
}

.hero__scroll-wheel {
    width: 4px;
    height: 8px;
    background: var(--accent-primary);
    border-radius: var(--radius-full);
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollWheel 2s ease-in-out infinite;
}

.hero__scroll-text {
    font-size: var(--fs-xs);
    color: var(--text-secondary);
    font-family: var(--font-mono);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

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

@keyframes scrollWheel {
    0% { opacity: 1; top: 6px; }
    100% { opacity: 0; top: 20px; }
}


/* ==========================================
   RESPONSIVE — HERO
   ========================================== */

@media (max-width: 1024px) {
    .hero__container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero__content {
        order: 2;
    }

    .hero__visual {
        order: 1;
    }

    .hero__greeting {
        justify-content: center;
    }

    .hero__description {
        margin-left: auto;
        margin-right: auto;
    }

    .hero__actions {
        justify-content: center;
    }

    .hero__stats {
        justify-content: center;
    }

    .hero__title-wrapper {
        justify-content: center;
    }

    .hero__image-wrapper {
        width: 250px;
        height: 300px;
    }

    /* Hide side elements on tablet */
    .hero__social-sidebar,
    .hero__email-sidebar {
        display: none;
    }
}

@media (max-width: 640px) {
    .hero {
        padding-top: calc(var(--header-height) + var(--space-xl));
    }

    .hero__name {
        font-size: var(--fs-3xl);
    }

    .hero__title-wrapper {
        font-size: var(--fs-lg);
        min-height: 2rem;
    }

    .hero__description {
        font-size: var(--fs-base);
    }

    .hero__stats {
        gap: var(--space-md);
    }

    .hero__stat-number {
        font-size: var(--fs-xl);
    }

    .hero__stat-suffix {
        font-size: var(--fs-xl);
    }

    .hero__image-wrapper {
        width: 200px;
        height: 240px;
    }

    .hero__scroll-indicator {
        display: none;
    }

    .hero__actions {
        flex-direction: column;
        align-items: center;
    }
}