@import url('https://fonts.googleapis.com/css2?family=Bree+Serif&family=Caveat:wght@400;700&family=Lobster&family=Monoton&family=Open+Sans:ital,wght@0,400;0,700;1,400;1,700&family=Playfair+Display+SC:ital,wght@0,400;0,700;1,700&family=Playfair+Display:ital,wght@0,400;0,700;1,700&family=Roboto:ital,wght@0,400;0,700;1,400;1,700&family=Source+Sans+Pro:ital,wght@0,400;0,700;1,700&family=Work+Sans:ital,wght@0,400;0,700;1,700&display=swap');

/* ══════════════════════════════════════
   CSS VARIABLES
══════════════════════════════════════ */
:root {
    --bg: #03050f;
    --surface: #080d1e;
    --border: rgba(56, 189, 248, 0.15);
    --accent: #38bdf8;
    --accent2: #818cf8;
    --accent3: #34d399;
    --text: #e2e8f0;
    --muted: #64748b;
    --glow: 0 0 30px rgba(56, 189, 248, 0.25);
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Syne', sans-serif;
    overflow-x: hidden;
    cursor: none;
}

/* ══════════════════════════════════════
   NOISE OVERLAY
══════════════════════════════════════ */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.03'/%3E%3C/svg%3E");
    pointer-events: none;
    z-index: 0;
    opacity: 0.4;
}

/* ══════════════════════════════════════
   CUSTOM CURSOR
══════════════════════════════════════ */
#cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 12px;
    height: 12px;
    background: var(--accent);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: transform 0.1s, background 0.2s;
    mix-blend-mode: screen;
}

#cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    width: 36px;
    height: 36px;
    border: 1.5px solid var(--accent);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9998;
    transform: translate(-50%, -50%);
    transition: transform 0.18s ease, opacity 0.2s;
    opacity: 0.6;
}

/* ══════════════════════════════════════
   BACKGROUND BLOBS
══════════════════════════════════════ */
.blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    pointer-events: none;
    z-index: 0;
    opacity: 0.18;
}

.blob1 {
    width: 500px;
    height: 500px;
    background: var(--accent);
    top: -120px;
    left: -120px;
    animation: drift 12s ease-in-out infinite alternate;
}

.blob2 {
    width: 400px;
    height: 400px;
    background: var(--accent2);
    bottom: -100px;
    right: -80px;
    animation: drift 15s ease-in-out infinite alternate-reverse;
}

.blob3 {
    width: 300px;
    height: 300px;
    background: var(--accent3);
    top: 50%;
    left: 55%;
    animation: drift 18s ease-in-out infinite alternate;
}

@keyframes drift {
    0% {
        transform: translate(0, 0) scale(1);
    }

    100% {
        transform: translate(40px, 30px) scale(1.1);
    }
}

/* ══════════════════════════════════════
   NAV
══════════════════════════════════════ */
nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 60px;
    background: rgba(3, 5, 15, 0.7);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid var(--border);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-logo img {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: 2px solid var(--accent);
    box-shadow: var(--glow);
    object-fit: cover;
}

.nav-logo span {
    font-size: 0.85rem;
    font-family: 'Space Mono', monospace;
    color: var(--accent);
    letter-spacing: 0.1em;
}

.nav-links {
    display: flex;
    gap: 4px;
}

.nav-links a {
    font-family: 'Space Mono', monospace;
    font-size: 0.72rem;
    color: var(--muted);
    text-decoration: none;
    letter-spacing: 0.06em;
    padding: 7px 12px;
    border-radius: 6px;
    border: 1px solid transparent;
    transition: all 0.25s;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--accent);
    border-color: var(--border);
    background: rgba(56, 189, 248, 0.05);
}

/* Hamburger (mobile) */
.nav-hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: none;
}

.nav-hamburger span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
    transition: all 0.3s;
}

/* ══════════════════════════════════════
   SECTIONS SHARED
══════════════════════════════════════ */
section {
    position: relative;
    z-index: 1;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    color: var(--accent);
    letter-spacing: 0.2em;
    text-transform: uppercase;
    display: block;
    margin-bottom: 12px;
}

.section-header h2 {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
}

.section-header p {
    color: var(--muted);
    margin-top: 12px;
    max-width: 480px;
    margin-inline: auto;
    line-height: 1.6;
}

/* ══════════════════════════════════════
   HERO
══════════════════════════════════════ */
#home {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    padding: 120px 60px 60px;
    gap: 40px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    color: var(--accent);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    border: 1px solid var(--border);
    border-radius: 100px;
    padding: 6px 16px;
    margin-bottom: 24px;
    background: rgba(56, 189, 248, 0.06);
}

.hero-badge::before {
    content: '';
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent3);
    animation: pulse 1.5s ease infinite;
}

@keyframes pulse {

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

    50% {
        opacity: 0.4;
        transform: scale(0.7);
    }
}

.hero-left h1 {
    font-size: clamp(2.5rem, 5vw, 4.2rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.02em;
}

.hero-left h1 .name {
    background: linear-gradient(120deg, var(--accent), var(--accent2));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.typing-wrap {
    margin-top: 18px;
    font-family: 'Space Mono', monospace;
    font-size: 1rem;
    color: var(--muted);
    min-height: 1.5em;
    display: flex;
    align-items: center;
    gap: 4px;
}

.typing-wrap::before {
    content: '> ';
    color: var(--accent3);
}

#typing {
    color: var(--text);
}

#cursor-blink {
    display: inline-block;
    width: 2px;
    height: 1em;
    background: var(--accent);
    animation: blink 0.8s step-end infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

.hero-desc {
    margin-top: 20px;
    color: var(--muted);
    line-height: 1.7;
    max-width: 460px;
    font-size: 0.95rem;
}

.hero-btns {
    display: flex;
    gap: 14px;
    margin-top: 32px;
    flex-wrap: wrap;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    font-family: 'Space Mono', monospace;
    letter-spacing: 0.05em;
    background: linear-gradient(135deg, var(--accent), var(--accent2));
    color: #03050f;
    border: none;
    cursor: none;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(56, 189, 248, 0.35);
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 28px;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 700;
    font-family: 'Space Mono', monospace;
    letter-spacing: 0.05em;
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
    cursor: none;
    text-decoration: none;
    transition: all 0.2s;
}

.btn-secondary:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(56, 189, 248, 0.05);
}

.hero-stats {
    display: flex;
    gap: 32px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid var(--border);
}

.stat-num {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--accent);
    line-height: 1;
}

.stat-label {
    font-size: 0.7rem;
    color: var(--muted);
    font-family: 'Space Mono', monospace;
    letter-spacing: 0.1em;
    margin-top: 4px;
}

/* Avatar */
.hero-right {
    display: flex;
    justify-content: center;
    align-items: center;
}

.avatar-wrap {
    position: relative;
    width: 320px;
    height: 320px;
}

.avatar-ring {
    position: absolute;
    inset: -18px;
    border-radius: 50%;
    border: 1px solid transparent;
    background: linear-gradient(var(--bg), var(--bg)) padding-box,
        linear-gradient(135deg, var(--accent), var(--accent2), var(--accent3)) border-box;
    animation: spin 8s linear infinite;
}

.avatar-ring2 {
    position: absolute;
    inset: -36px;
    border-radius: 50%;
    border: 1px solid var(--border);
    animation: spin 14s linear infinite reverse;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.avatar-wrap img {
    width: 320px;
    height: 320px;
    border-radius: 50%;
    object-fit: cover;
    position: relative;
    z-index: 1;
    box-shadow: 0 0 60px rgba(56, 189, 248, 0.2);
}

.avatar-tag {
    position: absolute;
    bottom: -10px;
    right: -10px;
    z-index: 2;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 10px 16px;
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    color: var(--accent3);
    display: flex;
    align-items: center;
    gap: 6px;
}

.avatar-tag::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--accent3);
    animation: pulse 1.5s ease infinite;
}

/* ══════════════════════════════════════
   ABOUT
══════════════════════════════════════ */
#about {
    padding: 100px 60px;
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 48px;
    max-width: 1100px;
    margin: 0 auto;
    align-items: start;
}

.about-text p {
    color: var(--muted);
    line-height: 1.8;
    margin-bottom: 18px;
    font-size: 0.95rem;
}

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

.about-details {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 28px;
}

.detail-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: var(--muted);
}

.detail-item svg {
    width: 16px;
    height: 16px;
    color: var(--accent);
    flex-shrink: 0;
}

.sub-heading {
    font-size: 1rem;
    font-weight: 700;
    color: var(--accent);
    font-family: 'Space Mono', monospace;
    letter-spacing: 0.08em;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.edu-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 20px;
    margin-bottom: 14px;
    transition: border-color 0.25s;
}

.edu-card:hover {
    border-color: var(--accent);
}

.edu-icon {
    font-size: 1.6rem;
    flex-shrink: 0;
}

.edu-title {
    font-size: 0.95rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.edu-sub {
    font-size: 0.8rem;
    color: var(--accent3);
    margin-bottom: 4px;
    font-family: 'Space Mono', monospace;
}

.edu-place {
    font-size: 0.82rem;
    color: var(--muted);
    margin-bottom: 4px;
}

.edu-year {
    font-size: 0.75rem;
    color: var(--muted);
    font-family: 'Space Mono', monospace;
}

/* ══════════════════════════════════════
   SKILLS
══════════════════════════════════════ */
#skills {
    padding: 100px 60px;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 16px;
    max-width: 1000px;
    margin: 0 auto;
}

.skill-card {
    position: relative;
    overflow: hidden;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 28px 24px;
    cursor: none;
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.skill-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.07), transparent);
    opacity: 0;
    transition: opacity 0.3s;
}

.skill-card:hover {
    transform: translateY(-6px);
    border-color: var(--accent);
    box-shadow: var(--glow);
}

.skill-card:hover::after {
    opacity: 1;
}

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

.skill-name {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 6px;
}

.skill-level {
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    color: var(--muted);
    margin-bottom: 14px;
}

.skill-bar {
    height: 3px;
    background: rgba(255, 255, 255, 0.07);
    border-radius: 10px;
    overflow: hidden;
}

.skill-fill {
    height: 100%;
    border-radius: 10px;
    background: linear-gradient(90deg, var(--accent), var(--accent2));
    width: 0;
    transition: width 1.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ══════════════════════════════════════
   PROJECTS
══════════════════════════════════════ */
#projects {
    padding: 100px 60px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    max-width: 1100px;
    margin: 0 auto;
}

.project-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 32px;
    position: relative;
    overflow: hidden;
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
    cursor: none;
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), var(--accent2), var(--accent3));
    opacity: 0;
    transition: opacity 0.3s;
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: rgba(56, 189, 248, 0.35);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.project-card:hover::before {
    opacity: 1;
}

.project-number {
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    color: var(--muted);
    margin-bottom: 20px;
    letter-spacing: 0.1em;
}

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

.project-desc {
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.65;
    margin-bottom: 24px;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 24px;
}

.tag {
    font-family: 'Space Mono', monospace;
    font-size: 0.65rem;
    padding: 4px 10px;
    border-radius: 100px;
    border: 1px solid var(--border);
    color: var(--muted);
}

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

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-family: 'Space Mono', monospace;
    font-size: 0.75rem;
    color: var(--accent);
    text-decoration: none;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 8px 16px;
    transition: all 0.2s;
}

.project-link:hover {
    background: rgba(56, 189, 248, 0.08);
    border-color: var(--accent);
}

.project-link svg {
    width: 14px;
    height: 14px;
}

.project-link-ghost {
    color: var(--muted);
}

.project-link-ghost:hover {
    color: var(--text);
    border-color: var(--muted);
    background: rgba(255, 255, 255, 0.04);
}

/* ══════════════════════════════════════
   CERTIFICATES
══════════════════════════════════════ */
#certificates {
    padding: 100px 60px;
}

.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 14px;
    max-width: 1100px;
    margin: 0 auto;
}

.cert-card {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 20px 22px;
    text-decoration: none;
    transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
    cursor: none;
}

.cert-card:hover {
    transform: translateY(-4px);
    border-color: var(--accent);
    box-shadow: var(--glow);
}

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

.cert-info {
    flex: 1;
}

.cert-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 4px;
}

.cert-issuer {
    font-family: 'Space Mono', monospace;
    font-size: 0.68rem;
    color: var(--muted);
}

.cert-arrow {
    width: 16px;
    height: 16px;
    color: var(--accent);
    flex-shrink: 0;
    opacity: 0;
    transition: opacity 0.2s;
}

.cert-card:hover .cert-arrow {
    opacity: 1;
}

/* ══════════════════════════════════════
   CONTACT
══════════════════════════════════════ */
#contact {
    padding: 100px 60px;
}

.contact-box {
    max-width: 760px;
    margin: 0 auto;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 56px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.contact-box::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 0%, rgba(56, 189, 248, 0.06), transparent 70%);
    pointer-events: none;
}

.contact-box h3 {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 800;
    margin-bottom: 14px;
}

.contact-box p {
    color: var(--muted);
    line-height: 1.7;
    margin-bottom: 36px;
}

.contact-links {
    display: flex;
    justify-content: center;
    gap: 12px;
    flex-wrap: wrap;
}

.contact-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: 'Space Mono', monospace;
    font-size: 0.78rem;
    color: var(--text);
    text-decoration: none;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.03);
    transition: all 0.2s;
}

.contact-link:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: rgba(56, 189, 248, 0.06);
    transform: translateY(-2px);
}

.contact-link svg {
    width: 16px;
    height: 16px;
}

/* ══════════════════════════════════════
   FOOTER
══════════════════════════════════════ */
footer {
    text-align: center;
    padding: 30px;
    border-top: 1px solid var(--border);
    font-family: 'Space Mono', monospace;
    font-size: 0.7rem;
    color: var(--muted);
    position: relative;
    z-index: 1;
}

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

/* ══════════════════════════════════════
   SCROLL REVEAL
══════════════════════════════════════ */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: none;
}

/* ══════════════════════════════════════
   RESPONSIVE — MOBILE
══════════════════════════════════════ */
@media (max-width: 900px) {
    .about-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    nav {
        padding: 16px 24px;
    }

    .nav-links {
        display: none;
        flex-direction: column;
        position: fixed;
        top: 72px;
        left: 0;
        right: 0;
        background: rgba(3, 5, 15, 0.97);
        backdrop-filter: blur(20px);
        padding: 20px;
        gap: 6px;
        border-bottom: 1px solid var(--border);
    }

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

    .nav-links a {
        font-size: 0.85rem;
        padding: 12px 16px;
    }

    .nav-hamburger {
        display: flex;
    }

    #home {
        grid-template-columns: 1fr;
        padding: 110px 24px 60px;
        text-align: center;
    }

    .hero-right {
        order: -1;
    }

    .avatar-wrap {
        width: 220px;
        height: 220px;
    }

    .avatar-wrap img {
        width: 220px;
        height: 220px;
    }

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

    .hero-btns {
        justify-content: center;
    }

    .hero-desc {
        margin-inline: auto;
    }

    #about,
    #skills,
    #projects,
    #certificates,
    #contact {
        padding: 80px 24px;
    }

    .contact-box {
        padding: 36px 24px;
    }
}