/* ========== RESET & BASE ========== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg: #0a0a0f;
    --bg2: #0f0f1a;
    --bg3: #13131f;
    --accent: #7c3aed;
    --accent2: #a855f7;
    --accent3: #06b6d4;
    --text: #e2e8f0;
    --text-muted: #94a3b8;
    --glass: rgba(255, 255, 255, 0.04);
    --glass-b: rgba(255, 255, 255, 0.08);
    --border: rgba(255, 255, 255, 0.07);
    --shadow: 0 25px 50px rgba(0, 0, 0, .5);
    --radius: 16px;
    --transition: .3s ease;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ========== SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--bg);
}

::-webkit-scrollbar-thumb {
    background: var(--accent);
    border-radius: 3px;
}

/* ========== UTILITIES ========== */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

.section {
    padding: 100px 0;
}

.section-tag {
    display: inline-block;
    background: linear-gradient(135deg, var(--accent), var(--accent3));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-size: .85rem;
    font-weight: 700;
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    margin-bottom: 60px;
    background: linear-gradient(135deg, #fff 40%, var(--text-muted));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 30px;
    border-radius: 50px;
    font-family: 'Outfit', sans-serif;
    font-size: .95rem;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent2));
    color: #fff;
    box-shadow: 0 0 30px rgba(124, 58, 237, .4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 0 50px rgba(124, 58, 237, .6);
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border: 1.5px solid var(--border);
    backdrop-filter: blur(10px);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-3px);
}

.btn-sm {
    padding: 8px 18px;
    font-size: .82rem;
    border-radius: 50px;
    background: var(--glass-b);
    border: 1px solid var(--border);
}

.btn-sm:hover {
    background: var(--accent);
    transform: translateY(-2px);
}

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

/* ========== NAVBAR ========== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 40px;
    transition: background .4s, backdrop-filter .4s, box-shadow .4s;
}

.navbar.scrolled {
    background: rgba(10, 10, 15, .85);
    backdrop-filter: blur(20px);
    box-shadow: 0 1px 0 var(--border);
}

.nav-logo {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: 1px;
}

.nav-logo span {
    color: var(--accent);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 36px;
}

.nav-links a {
    font-size: .95rem;
    font-weight: 500;
    color: var(--text-muted);
    position: relative;
    transition: color .3s;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), var(--accent3));
    transition: width .3s;
}

.nav-links a:hover {
    color: var(--text);
}

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

.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 4px;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: .3s;
}

/* ========== HERO ========== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: .25;
    animation: blobFloat 8s ease-in-out infinite;
}

.blob1 {
    width: 500px;
    height: 500px;
    background: var(--accent);
    top: -120px;
    left: -150px;
    animation-delay: 0s;
}

.blob2 {
    width: 400px;
    height: 400px;
    background: var(--accent3);
    bottom: -100px;
    right: -100px;
    animation-delay: -3s;
}

.blob3 {
    width: 300px;
    height: 300px;
    background: #f093fb;
    top: 40%;
    left: 60%;
    animation-delay: -5s;
}

@keyframes blobFloat {

    0%,
    100% {
        transform: translateY(0) scale(1);
    }

    50% {
        transform: translateY(-30px) scale(1.05);
    }
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 700px;
    padding: 24px;
}

.hero-greeting {
    font-size: 1.1rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.hero-name {
    font-size: clamp(3.5rem, 10vw, 7rem);
    font-weight: 800;
    line-height: 1;
    background: linear-gradient(135deg, #fff 20%, var(--accent2) 60%, var(--accent3));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 16px;
}

.hero-typewriter {
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
    font-weight: 600;
    color: var(--accent2);
    min-height: 2rem;
    margin-bottom: 20px;
}

.cursor {
    animation: blink 1s infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.hero-desc {
    color: var(--text-muted);
    font-size: 1.05rem;
    margin-bottom: 36px;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.hero-btns {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

.hero-socials {
    display: flex;
    gap: 16px;
    justify-content: center;
}

.hero-socials a {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--glass-b);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.hero-socials a svg {
    width: 20px;
    height: 20px;
}

.hero-socials a:hover {
    background: var(--accent);
    transform: translateY(-3px);
}

.hero-scroll {
    position: absolute;
    bottom: 32px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    font-size: .75rem;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: var(--text-muted);
}

.scroll-line {
    width: 1px;
    height: 50px;
    background: linear-gradient(to bottom, var(--accent), transparent);
    animation: scrollLine 2s ease-in-out infinite;
}

@keyframes scrollLine {
    0% {
        opacity: 1;
        transform: scaleY(1) translateY(0);
    }

    100% {
        opacity: 0;
        transform: scaleY(.5) translateY(10px);
    }
}

/* ========== ABOUT ========== */
.about {
    background: var(--bg2);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 60px;
    align-items: center;
}

.about-avatar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.avatar-ring {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    padding: 4px;
    background: linear-gradient(135deg, var(--accent), var(--accent3));
    position: relative;
}

.avatar-inner {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--bg3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    font-weight: 800;
    color: var(--accent2);
}

.about-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--glass);
    border: 1px solid var(--border);
    backdrop-filter: blur(10px);
    padding: 8px 18px;
    border-radius: 50px;
    font-size: .85rem;
    font-weight: 600;
}

.about-text p {
    color: var(--text-muted);
    margin-bottom: 16px;
    font-size: 1.05rem;
}

.about-text strong {
    color: var(--text);
}

.about-stats {
    display: flex;
    gap: 40px;
    margin: 30px 0;
}

.stat {
    text-align: center;
}

.stat-num {
    font-size: 2.2rem;
    font-weight: 800;
    background: linear-gradient(135deg, var(--accent), var(--accent3));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stat-label {
    display: block;
    font-size: .82rem;
    color: var(--text-muted);
    letter-spacing: 1px;
}

/* ========== SKILLS ========== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 48px;
}

.skill-category-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--accent2);
    display: flex;
    align-items: center;
    gap: 12px;
}

.skill-category-title::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border);
}

.skill-card {
    background: var(--glass);
    border: 1px solid var(--border);
    backdrop-filter: blur(12px);
    border-radius: var(--radius);
    padding: 28px;
    transition: var(--transition);
}

.skill-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
    box-shadow: 0 0 30px rgba(124, 58, 237, .2);
}

.skill-icon {
    font-size: 2rem;
    margin-bottom: 12px;
}

.skill-card h3 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 14px;
}

.skill-bar {
    height: 6px;
    background: var(--glass-b);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 6px;
}

.skill-fill {
    height: 100%;
    width: 0%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--accent), var(--accent3));
    transition: width 1.2s ease;
}

.skill-pct {
    font-size: .8rem;
    color: var(--text-muted);
}

/* ========== PROJECTS ========== */
.projects {
    background: var(--bg2);
}

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

.project-card {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: var(--transition);
}

.project-card:hover {
    border-color: var(--accent);
    transform: translateY(-6px);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .4);
}

.project-img {
    height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3.5rem;
}

.project-body {
    padding: 24px;
}

.project-body h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.project-body p {
    font-size: .9rem;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.project-tags span {
    font-size: .75rem;
    padding: 4px 12px;
    border-radius: 50px;
    background: var(--glass-b);
    border: 1px solid var(--border);
    color: var(--accent2);
}

.project-links {
    display: flex;
    gap: 10px;
}

/* ========== CONTACT ========== */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 50px;
    align-items: start;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.info-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--glass);
    border: 1px solid var(--border);
    backdrop-filter: blur(10px);
    border-radius: var(--radius);
    padding: 20px 24px;
    transition: var(--transition);
}

.info-card:hover {
    border-color: var(--accent);
    transform: translateX(4px);
}

.info-icon {
    font-size: 1.8rem;
    flex-shrink: 0;
}

.info-card h4 {
    font-size: .85rem;
    color: var(--text-muted);
    margin-bottom: 2px;
}

.info-card a,
.info-card span {
    font-size: .95rem;
    font-weight: 500;
    color: var(--text);
    transition: color .3s;
}

.info-card a:hover {
    color: var(--accent2);
}

/* FORM */
.contact-form {
    background: var(--glass);
    border: 1px solid var(--border);
    backdrop-filter: blur(12px);
    border-radius: var(--radius);
    padding: 40px;
}

.form-group {
    margin-bottom: 20px;
}

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

.form-group input,
.form-group textarea {
    width: 100%;
    background: rgba(255, 255, 255, .04);
    border: 1.5px solid var(--border);
    border-radius: 10px;
    padding: 14px 18px;
    font-family: 'Outfit', sans-serif;
    font-size: .95rem;
    color: var(--text);
    transition: border-color .3s, box-shadow .3s;
    resize: none;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(124, 58, 237, .15);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #475569;
}

.form-status {
    margin-top: 14px;
    font-size: .9rem;
    font-weight: 600;
    text-align: center;
}

.form-status.success {
    color: #4ade80;
}

.form-status.error {
    color: #f87171;
}

/* ========== FOOTER ========== */
.footer {
    background: var(--bg2);
    border-top: 1px solid var(--border);
    padding: 48px 0;
}

.footer-content {
    text-align: center;
}

.footer-logo {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 8px;
}

.footer-logo span {
    color: var(--accent);
}

.footer p {
    color: var(--text-muted);
    font-size: .9rem;
    margin-bottom: 6px;
}

.footer-copy {
    font-size: .8rem;
    opacity: .6;
}

/* ========== BACK TO TOP ========== */
.back-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    z-index: 999;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--accent2));
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
    box-shadow: 0 0 20px rgba(124, 58, 237, .5);
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition);
}

.back-top.visible {
    opacity: 1;
    transform: translateY(0);
}

.back-top:hover {
    transform: translateY(-4px) scale(1.05);
}

/* ========== SCROLL REVEAL ========== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: .7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
    .nav-links {
        display: none;
        flex-direction: column;
        position: fixed;
        top: 0;
        right: -100%;
        width: 260px;
        height: 100vh;
        background: rgba(15, 15, 26, .98);
        backdrop-filter: blur(20px);
        padding: 90px 32px 32px;
        gap: 24px;
        transition: right .4s ease;
        border-left: 1px solid var(--border);
    }

    .nav-links.open {
        display: flex;
        right: 0;
    }

    .hamburger {
        display: flex;
    }

    .about-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .about-stats {
        justify-content: center;
    }

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

    .navbar {
        padding: 16px 24px;
    }
}

@media (max-width: 480px) {
    .hero-btns {
        flex-direction: column;
        align-items: center;
    }

    .contact-form {
        padding: 28px 20px;
    }
}

/* ========== SUCCESS MODAL ========== */
.modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: all;
}

.modal-box {
    background: var(--bg3);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 48px 40px;
    max-width: 420px;
    width: 90%;
    text-align: center;
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(124, 58, 237, 0.2);
    transform: scale(0.85) translateY(20px);
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal-box {
    transform: scale(1) translateY(0);
}

.modal-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
}

.modal-icon svg {
    width: 100%;
    height: 100%;
}

/* Animate the circle stroke drawing */
.modal-circle {
    stroke-dasharray: 157;
    stroke-dashoffset: 157;
    transition: stroke-dashoffset 0.6s ease 0.2s;
}

.modal-overlay.active .modal-circle {
    stroke-dashoffset: 0;
}

/* Animate the checkmark drawing */
.modal-check {
    stroke-dasharray: 50;
    stroke-dashoffset: 50;
    transition: stroke-dashoffset 0.5s ease 0.7s;
}

.modal-overlay.active .modal-check {
    stroke-dashoffset: 0;
}

.modal-title {
    font-size: 1.6rem;
    font-weight: 800;
    margin-bottom: 12px;
    background: linear-gradient(135deg, #fff, var(--accent2));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.modal-msg {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 32px;
    line-height: 1.6;
}

.modal-close {
    min-width: 160px;
}