/* ===== CSS Variables & Reset ===== */
:root {
    --bg-primary: #0a0a0f;
    --bg-secondary: #12121a;
    --bg-card: rgba(20, 20, 30, 0.8);
    --text-primary: #f0f0f5;
    --text-secondary: #a0a0b0;
    --text-muted: #606070;
    --accent-gradient: linear-gradient(135deg, #6366f1, #8b5cf6, #ec4899);
    --border-color: rgba(255, 255, 255, 0.08);
    --shadow-glow: 0 0 60px rgba(99, 102, 241, 0.15);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --transition-fast: 0.2s ease;
    --transition-normal: 0.3s ease;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

/* ===== Animated Background ===== */
.bg-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(99, 102, 241, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(139, 92, 246, 0.1) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 50%, rgba(236, 72, 153, 0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: -2;
}

.bg-grid {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: -1;
}

/* ===== Container ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

/* ===== Hero Section ===== */
.hero {
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 4rem 0;
}

.hero-content {
    max-width: 700px;
}

.avatar-ring {
    width: 120px;
    height: 120px;
    margin: 0 auto 2rem;
    padding: 4px;
    border-radius: 50%;
    background: var(--accent-gradient);
    animation: pulse-ring 3s ease-in-out infinite;
}

@keyframes pulse-ring {

    0%,
    100% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.02);
        opacity: 0.9;
    }
}

.avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: 2px;
}

.hero-title {
    margin-bottom: 1.5rem;
}

.greeting {
    display: block;
    font-size: 1.2rem;
    font-weight: 400;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.name {
    display: block;
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 700;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 1.5rem;
    line-height: 1.8;
}

.hero-role {
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.hero-cert {
    font-size: 0.95rem;
    color: #10b981;
    font-weight: 500;
    margin-bottom: 0.75rem;
}

.hero-location {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.icon-sm {
    width: 16px;
    height: 16px;
}

.skills-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
    max-width: 550px;
    margin: 0 auto 2rem;
}

.skill-badge {
    padding: 0.4rem 0.85rem;
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 20px;
    font-size: 0.8rem;
    color: #a5b4fc;
    font-weight: 500;
}

.hero-links {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: var(--radius-md);
    font-weight: 500;
    font-size: 0.95rem;
    text-decoration: none;
    transition: all var(--transition-normal);
    cursor: pointer;
    border: none;
}

.btn .icon {
    width: 18px;
    height: 18px;
}

.btn-primary {
    background: var(--accent-gradient);
    color: white;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4);
}

.btn-secondary {
    background: var(--bg-card);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* ===== Projects Section ===== */
.projects-section {
    padding: 4rem 0;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 2.5rem;
    color: var(--text-primary);
}

.title-icon {
    font-size: 1.5rem;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

/* ===== Project Cards ===== */
.project-card {
    position: relative;
    background: var(--bg-card);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all var(--transition-normal);
    backdrop-filter: blur(10px);
}

.project-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: var(--shadow-glow);
}

.card-glow {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    opacity: 0;
    transition: opacity var(--transition-normal);
}

.project-card:hover .card-glow {
    opacity: 1;
}

.card-content {
    padding: 1.75rem;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.project-icon {
    font-size: 2rem;
    line-height: 1;
}

.project-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

.project-description {
    color: var(--text-secondary);
    font-size: 0.925rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.project-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.link-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 500;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.link-btn .icon {
    width: 14px;
    height: 14px;
}

.link-github {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.link-github:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

.link-live {
    background: rgba(99, 102, 241, 0.15);
    color: #a5b4fc;
    border: 1px solid rgba(99, 102, 241, 0.3);
}

.link-live:hover {
    background: rgba(99, 102, 241, 0.25);
    color: white;
}

/* ===== Footer ===== */
.footer {
    text-align: center;
    padding: 3rem 0;
    color: var(--text-muted);
    font-size: 0.9rem;
    border-top: 1px solid var(--border-color);
    margin-top: 2rem;
}

/* ===== Responsive Design ===== */
@media (max-width: 768px) {
    .container {
        padding: 1rem;
    }

    .hero {
        min-height: 50vh;
        padding: 3rem 0;
    }

    .avatar-ring {
        width: 100px;
        height: 100px;
    }

    .avatar {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-links {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 250px;
        justify-content: center;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .project-card {
        transform: none !important;
    }
}

/* ===== Scrollbar Styling ===== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ===== Selection Styling ===== */
::selection {
    background: rgba(99, 102, 241, 0.3);
    color: white;
}