/* ============================================
   HERO SECTION — Matching Reference Design
   ============================================ */

.hero-section {
    padding: 3rem 0 1.5rem;
    background: transparent;
    color: var(--text-primary);
    position: relative;
    overflow: hidden;
    border-radius: 0;
    box-shadow: none;
    margin: 0;
    min-height: 480px;
}

/* Hero Content — Two Columns */
.hero-content {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 2rem;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
    position: relative;
    z-index: 2;
}

/* ============================================
   LEFT COLUMN — Text
   ============================================ */

.hero-text {
    flex: 1;
    min-width: 300px;
    padding-top: 2rem;
}

/* "Hello, I'm" pill badge */
.hero-greeting {
    display: inline-block;
    background: #ede9fe;
    border: 1px solid #ddd6fe;
    color: #6d28d9;
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1.2rem;
}

/* Name heading — animated gradient text */
.hero-text h1 {
    font-size: 3.8rem;
    line-height: 1.1;
    margin-bottom: 0.6rem;
    font-weight: 800;
    font-family: var(--font-heading);
    text-align: left;
    border-bottom: none;
    display: block;
    background: linear-gradient(135deg,
            #0f172a 0%,
            #4f46e5 50%,
            #7c3aed 100%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: shimmerText 8s ease-in-out infinite;
}

/* Subtitle — SOFTWARE ENGINEER with typewriter cursor */
.hero-text h2 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent-purple);
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 1.2rem;
    display: inline-block;
    min-height: 1.5em;
}

/* Blinking cursor */
.hero-text h2::after {
    content: '|';
    color: var(--accent-purple);
    font-weight: 400;
    animation: blink 0.7s step-end infinite;
    margin-left: 2px;
}

.hero-text h2.typing-done::after {
    display: none;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* Description paragraph */
.hero-text p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    line-height: 1.75;
    margin-bottom: 1.5rem;
    max-width: 480px;
}

/* ============================================
   RIGHT COLUMN — Framed Portrait Photo
   ============================================ */

.hero-image {
    flex: 0 0 480px;
    position: relative;
    z-index: 1;
    margin-right: -24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    height: 480px;
    margin-top: 1.5rem;
    left: -28px; /* Shifted 26px to the left */
}

.hero-image-wrapper {
    width: 100%;
    max-width: 380px;
    height: auto;
    aspect-ratio: 1 / 1;
    position: relative;
    overflow: visible;
}

.hero-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    border-radius: 28px;
    border: 2px solid rgba(99, 102, 241, 0.2);
    box-shadow: 0 20px 40px -15px rgba(99, 102, 241, 0.2), 0 0 0 8px rgba(255, 255, 255, 0.9);
    background: linear-gradient(135deg, rgba(238, 242, 255, 0.9) 0%, rgba(245, 243, 255, 0.9) 100%);
}

/* Ambient glow behind image */
.hero-image::before {
    content: '';
    position: absolute;
    top: 10%;
    left: -15%;
    width: 95%;
    height: 80%;
    border-radius: 50%;
    background: radial-gradient(ellipse,
            rgba(99, 102, 241, 0.15) 0%,
            rgba(124, 58, 237, 0.08) 40%,
            transparent 70%);
    z-index: -1;
    filter: blur(35px);
    animation: glowPulse 4s ease-in-out infinite;
}

/* Orbit Rings Animation */
.orbit-ring {
    position: absolute;
    top: 40%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    pointer-events: none;
    z-index: -1;
}

.ring-1 {
    width: 440px;
    height: 440px;
    border: 1px dashed rgba(99, 102, 241, 0.25);
    animation: rotateCW 20s linear infinite;
}

.ring-1::after {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: var(--accent-purple);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-purple);
}

@keyframes rotateCW {
    from {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    to {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}



/* ============================================
   HERO BOTTOM — Social (left) + Stats (right)
   ============================================ */

/* hero-bottom removed - stats bar moved inside hero-image */

/* Social Icons */
.hero-social {
    display: flex;
    gap: 0.75rem;
}

.hero-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid var(--border-card);
    border-radius: 50%;
    color: var(--text-secondary);
    font-size: 1.15rem;
    transition: var(--transition);
    text-decoration: none;
    background: transparent;
}

.hero-social a:hover {
    color: var(--accent-purple-light);
    border-color: var(--accent-purple);
    background: rgba(124, 58, 237, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(124, 58, 237, 0.2);
}

/* Mobile-only Download CV Button (hidden on desktop) */
.hero-download-cv {
    display: none;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.7rem 1.8rem;
    background: linear-gradient(135deg, var(--accent-purple) 0%, var(--accent-purple-light) 100%);
    color: white;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    box-shadow: 0 4px 15px var(--accent-purple-glow);
    margin-top: 1rem;
}

.hero-download-cv:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px var(--accent-purple-glow);
}

/* ============================================
   STATS BAR — Right-aligned
   ============================================ */

.stats-bar {
    position: absolute;
    bottom: 90px;
    right: -28px;
    left: auto;
    transform: none;
    width: max-content;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 0;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid var(--border-card);
    border-radius: 16px;
    padding: 0.9rem 1.1rem;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.08), 0 0 0 1px rgba(99, 102, 241, 0.06);
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0 1rem;
    border-right: 1px solid var(--border-subtle);
}

.stat-item:last-child {
    border-right: none;
}

.stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: #ede9fe;
    color: #6d28d9;
    font-size: 1rem;
    flex-shrink: 0;
}

.stat-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    white-space: nowrap;
}

.stat-info p {
    font-size: 0.72rem;
    color: var(--text-secondary);
    white-space: nowrap;
}

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

@media (max-width: 992px) {
    .hero-content {
        gap: 1.5rem;
    }

    .hero-text h1 {
        font-size: 3rem;
    }

    .hero-image {
        flex: 0 0 420px;
        height: 420px;
        margin-top: 1.5rem;
    }

    .hero-image-wrapper {
        width: 100%;
        max-width: 320px;
        height: auto;
    }

    .stats-bar {
        width: max-content;
        right: 25px;
        /* Positioned 25px from the right edge on tablets (shifted 15px right in total) */
        left: auto;
        transform: none;
        bottom: 70px;
        /* Moved 15px upwards on tablets in total */
        padding: 0.75rem;
    }

    .stats-bar .stat-item {
        padding: 0 0.75rem;
        gap: 0.5rem;
    }

    .stats-bar .stat-icon {
        width: 32px;
        height: 32px;
        font-size: 0.9rem;
    }

    .stats-bar .stat-info h3 {
        font-size: 0.95rem;
    }

    .stats-bar .stat-info p {
        font-size: 0.65rem;
    }

    .ring-1 {
        width: 360px;
        height: 360px;
    }
}

@media (max-width: 768px) {
    .hero-section {
        padding: 2rem 0 1rem;
        min-height: auto;
        overflow: visible;
    }

    .hero-content {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }

    .hero-text {
        min-width: auto;
        text-align: center;
        padding-top: 0;
    }

    .hero-text h1 {
        font-size: 2.2rem;
        text-align: center;
    }

    .hero-text h2 {
        letter-spacing: 3px;
    }

    .hero-text p {
        max-width: 100%;
    }

    .hero-image {
        flex: none;
        width: 100%;
        height: auto;
        margin-right: 0;
        margin-top: 0;
        left: 0; /* Reset shift on mobile */
        gap: 1.5rem;
    }

    .hero-image-wrapper {
        width: 100%;
        max-width: 260px;
        height: auto;
        border-radius: 20px;
        overflow: visible;
    }

    .hero-image-wrapper img {
        border-radius: 20px;
    }

    .hero-social {
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.6rem;
    }

    .hero-download-cv {
        display: inline-flex;
    }

    .stats-bar {
        position: relative;
        bottom: auto;
        left: auto;
        right: auto;
        transform: none;
        flex-direction: column;
        width: 100%;
        max-width: 100%;
        gap: 0;
        margin-top: 1rem;
    }

    .stat-item {
        border-right: none;
        border-bottom: 1px solid var(--border-subtle);
        padding: 0.9rem 1.5rem;
        justify-content: flex-start;
        width: 100%;
    }

    .stat-item:last-child {
        border-bottom: none;
    }

    .ring-1 {
        width: 300px;
        height: 300px;
    }

    /* Ensure no horizontal overflow from orbit rings */
    .hero-image::before {
        left: 0;
        width: 80%;
    }
}

@media (max-width: 576px) {
    .hero-text h1 {
        font-size: 1.8rem;
    }

    .hero-text h2 {
        font-size: 0.85rem;
        letter-spacing: 2px;
    }

    .hero-text p {
        font-size: 0.92rem;
    }

    .hero-image-wrapper {
        width: 100%;
        max-width: 220px;
        height: auto;
    }

    .ring-1 {
        width: 250px;
        height: 250px;
    }

    .stat-item {
        padding: 0.75rem 1rem;
    }

    .stat-icon {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }

    .stat-info h3 {
        font-size: 0.9rem;
    }

    .stat-info p {
        font-size: 0.6rem;
    }

    .hero-social a {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
}

@media (max-width: 380px) {
    .hero-text h1 {
        font-size: 1.55rem;
    }

    .hero-section {
        padding: 1.5rem 0 0.5rem;
    }
}