:root {
    /* Premium Design System */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --primary-color: #635bff;
    --secondary-color: #00d4ff;
    --accent-color: #7c3aed;
    --text-color: #0b1020;
    --light-text: #667085;
    --background: #fbfcff;
    --section-bg: #f5f7fb;
    --card-bg: rgba(255, 255, 255, 0.84);
    --card-bg-solid: #ffffff;
    --shadow: 0 20px 60px rgba(15, 23, 42, 0.08);
    --shadow-soft: 0 8px 30px rgba(15, 23, 42, 0.06);
    --glow: 0 24px 80px rgba(99, 91, 255, 0.22);
    --circuit-color: rgba(99, 91, 255, 0.055);
    --border-color: rgba(15, 23, 42, 0.09);
    --radius-sm: 12px;
    --radius-md: 18px;
    --radius-lg: 28px;
    --radius-pill: 999px;
    --tag-bg: rgba(99, 91, 255, 0.08);
    --tag-text: #4138c2;
    --tag-hover-bg: rgba(99, 91, 255, 0.14);
}

/* Dark Theme Colors */
.dark-mode {
    --primary-color: #8b85ff;
    --secondary-color: #38bdf8;
    --accent-color: #a78bfa;
    --text-color: #f8fafc;
    --light-text: #a8b3cf;
    --background: #060913;
    --section-bg: #0c1222;
    --card-bg: rgba(15, 23, 42, 0.78);
    --card-bg-solid: #101827;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.38);
    --shadow-soft: 0 12px 36px rgba(0, 0, 0, 0.28);
    --glow: 0 26px 90px rgba(139, 133, 255, 0.28);
    --circuit-color: rgba(139, 133, 255, 0.12);
    --border-color: rgba(148, 163, 184, 0.16);
    --tag-bg: rgba(139, 133, 255, 0.14);
    --tag-text: #d7d4ff;
    --tag-hover-bg: rgba(139, 133, 255, 0.22);
}

/* Theme Switch */
.theme-switch {
    position: fixed;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 1001;
}

.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--section-bg);
    transition: .4s;
    border-radius: 34px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: var(--primary-color);
    transition: .4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--section-bg);
}

input:checked + .slider:before {
    transform: translateX(26px);
}

/* Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    transition: background-color 0.3s, color 0.3s;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans);
    line-height: 1.6;
    color: var(--text-color);
    background: var(--background);
    animation: fadeIn 1s ease-out;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.nav-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.logo {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.logo-dot {
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s;
}

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

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, var(--background) 0%, var(--section-bg) 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        linear-gradient(45deg, var(--circuit-color) 25%, transparent 25%) -50px 0,
        linear-gradient(-45deg, var(--circuit-color) 25%, transparent 25%) -50px 0,
        linear-gradient(45deg, transparent 75%, var(--circuit-color) 75%),
        linear-gradient(-45deg, transparent 75%, var(--circuit-color) 75%);
    background-size: 100px 100px;
    opacity: 0.15;
    animation: circuitMove 20s linear infinite;
}

.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 50% 50%, var(--circuit-color) 2px, transparent 2px) 0 0,
        radial-gradient(circle at 50% 50%, var(--circuit-color) 2px, transparent 2px) 25px 25px;
    background-size: 50px 50px;
    opacity: 0.1;
    animation: circuitPulse 4s ease-in-out infinite;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    animation: scaleIn 1s ease-out;
}

.hero-text h1 {
    font-size: 4rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: slideIn 1s ease-out;
}

.hero h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.hero p {
    font-size: 1.25rem;
    color: var(--light-text);
    margin-bottom: 2rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn:hover::before {
    width: 200%;
    height: 200%;
}

.primary {
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
}

.secondary {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

/* Sections */
section {
    padding: 5rem 0;
}

section:nth-child(even) {
    background: var(--section-bg);
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 3rem;
    text-align: center;
    color: var(--text-color);
    position: relative;
    display: inline-block;
    animation: fadeIn 1s ease-out;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 50%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), transparent);
    animation: slideIn 1s ease-out;
}

/* About Section */
.skills {
    margin-top: 3rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    padding: 2rem 0;
}

.group {
    position: relative;
    border-radius: 50%;
    padding: 1rem;
    background: var(--card-bg);
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    animation: float 6s ease-in-out infinite;
}

.group:hover {
    transform: translateY(-5px);
    box-shadow: var(--glow);
}

.skill-image {
    width: 100%;
    height: auto;
    border-radius: 50%;
    transition: all 0.3s ease;
    filter: grayscale(0%);
}

.group:hover .skill-image {
    filter: grayscale(100%);
}

.skill-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(99, 102, 241, 0.6);
    backdrop-filter: blur(4px);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: scale(0.8);
}

.group:hover .skill-overlay {
    opacity: 1;
    transform: scale(1);
}

.skill-percentage {
    color: white;
    font-size: 1.5rem;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    animation: fadeIn 0.3s ease-out;
}

/* Experience Section */
.experience-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.experience-card {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.experience-card:hover {
    transform: translateY(-5px);
}

.company-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.company-logo {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    object-fit: contain;
}

.remote-badge {
    background: var(--accent-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    margin-left: 1rem;
}

.tech-stack {
    margin-top: 1.5rem;
}

.tech-icons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 0.5rem;
}

.tech-icons img {
    width: 32px;
    height: 32px;
    transition: transform 0.2s ease;
}

.tech-icons img:hover {
    transform: scale(1.2);
}

.skills-gained {
    margin-top: 1.5rem;
}

.skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.skill-tag {
    background: var(--tag-bg);
    color: var(--tag-text);
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    transition: background-color 0.2s ease;
}

.skill-tag:hover {
    background: var(--tag-hover-bg);
}

/* Animation classes */
[data-aos] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-aos].aos-animate {
    opacity: 1;
    transform: translateY(0);
}

/* Projects Section */
.project-carousel {
    position: relative;
    overflow: hidden;
    padding: 2rem 0;
}

.project-track {
    display: flex;
    transition: transform 0.5s ease-out;
}

.project-card {
    min-width: 300px;
    margin-right: 2rem;
}

.carousel-nav {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
}

.carousel-nav button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: transform 0.3s;
}

.carousel-nav button:hover {
    transform: scale(1.1);
}

/* Education Section */
.education-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
}

.education-card h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.education-card h4 {
    color: var(--light-text);
    margin-bottom: 0.5rem;
}

.certifications {
    margin-top: 3rem;
}

.certifications ul {
    list-style: none;
    margin-top: 1rem;
}

.certifications li {
    margin-bottom: 0.5rem;
    color: var(--light-text);
}

/* Contact Section */
.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 500px;
    margin: 0 auto;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--primary-color);
}

.contact-item a {
    text-decoration: none;
    color: var(--text-color);
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: var(--primary-color);
}

/* Footer */
footer {
    background: var(--text-color);
    color: white;
    padding: 2rem 0;
    text-align: center;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 1000;
}

.hamburger span {
    width: 30px;
    height: 3px;
    background-color: var(--primary-color);
    transition: all 0.3s ease;
}

/* Animations */
@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

@keyframes blink-caret {
    from, to { border-color: transparent }
    50% { border-color: var(--primary-color) }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from { transform: translateX(-100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes scaleIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

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

@keyframes glowPulse {
    0% { box-shadow: 0 0 5px var(--primary-color); }
    50% { box-shadow: 0 0 20px var(--primary-color); }
    100% { box-shadow: 0 0 5px var(--primary-color); }
}

@keyframes circuitMove {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 200px 200px;
    }
}

@keyframes circuitPulse {
    0%, 100% {
        opacity: 0.1;
        transform: scale(1);
    }
    50% {
        opacity: 0.2;
        transform: scale(1.05);
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 70%;
        background: var(--background);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: right 0.3s ease;
        box-shadow: var(--shadow);
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links {
        display: none;
    }

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

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

    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }

    .skill-percentage {
        font-size: 1.2rem;
    }

    .project-card {
        min-width: 100%;
    }

    .section-title {
        font-size: 2rem;
    }

    .cta-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
        text-align: center;
    }

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

@media (max-width: 480px) {
    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
}

/* Certificates Section */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.cert-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 1rem;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    gap: 1.5rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: fadeIn 0.5s ease-out;
}

.cert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.2);
}

.cert-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
}

.cert-icon i {
    font-size: 1.5rem;
    color: white;
}

.cert-content h3 {
    color: var(--text-color);
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.cert-content p {
    color: var(--light-text);
    font-size: 0.9rem;
}

.theme-transition {
    transition: background-color 0.3s ease,
                color 0.3s ease,
                border-color 0.3s ease,
                box-shadow 0.3s ease;
}

.theme-transition * {
    transition: background-color 0.3s ease,
                color 0.3s ease,
                border-color 0.3s ease,
                box-shadow 0.3s ease;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-image {
    position: relative;
    border-radius: 1rem;
    overflow: hidden;
    aspect-ratio: 1;
    box-shadow: var(--shadow);
    background: var(--card-bg);
}

.image-slider {
    position: relative;
    width: 100%;
    height: 100%;
    background: var(--card-bg);
}

.about-text {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.about-text p {
    color: var(--light-text);
    font-size: 1.1rem;
    line-height: 1.8;
}

.quick-contact {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.quick-contact a {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.quick-contact a:hover {
    color: var(--primary-color);
}

@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .about-image {
        max-width: 400px;
        margin: 0 auto;
    }
}

/* Premium Design System Overrides */
body {
    font-family: var(--font-sans);
    letter-spacing: -0.01em;
    background:
        radial-gradient(circle at top left, rgba(99, 91, 255, 0.08), transparent 34rem),
        radial-gradient(circle at 85% 8%, rgba(0, 212, 255, 0.08), transparent 30rem),
        var(--background);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

.container,
.nav-content {
    max-width: 1120px;
    padding-inline: clamp(1.25rem, 4vw, 2rem);
}

.navbar {
    background: rgba(251, 252, 255, 0.76);
    border-bottom: 1px solid var(--border-color);
    box-shadow: 0 1px 0 rgba(15, 23, 42, 0.04);
    padding: 0.85rem 0;
}

.dark-mode .navbar {
    background: rgba(6, 9, 19, 0.78);
}

.logo {
    font-size: 1.55rem;
    font-weight: 800;
    letter-spacing: -0.06em;
}

.nav-links {
    gap: clamp(1rem, 2.4vw, 1.75rem);
}

.nav-links a {
    color: var(--light-text);
    font-size: 0.94rem;
    font-weight: 600;
    letter-spacing: -0.02em;
}

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

.theme-switch {
    top: 18px;
    right: 18px;
    color: var(--light-text);
}

.slider {
    background: var(--card-bg-solid);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
}

section {
    padding: clamp(4.5rem, 8vw, 7rem) 0;
}

section:nth-child(even) {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0)),
        var(--section-bg);
}

.dark-mode section:nth-child(even) {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0)),
        var(--section-bg);
}

.hero {
    min-height: 100svh;
    height: auto;
    padding-top: 6rem;
    background:
        radial-gradient(circle at 15% 18%, rgba(99, 91, 255, 0.14), transparent 24rem),
        radial-gradient(circle at 82% 28%, rgba(0, 212, 255, 0.14), transparent 26rem),
        linear-gradient(180deg, var(--background), var(--section-bg));
}

.hero-content {
    gap: clamp(2.5rem, 7vw, 5rem);
}

.hero-text h1 {
    font-size: clamp(3rem, 8vw, 5.7rem);
    line-height: 0.98;
    letter-spacing: -0.08em;
    margin-bottom: 1.2rem;
    background: linear-gradient(120deg, var(--text-color), var(--primary-color) 48%, var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
}

.hero h2 {
    font-size: clamp(1.35rem, 3vw, 2.05rem);
    line-height: 1.2;
    letter-spacing: -0.045em;
    color: var(--text-color);
    margin-bottom: 0.85rem;
}

.hero p,
.about-text p {
    max-width: 620px;
    color: var(--light-text);
    font-size: clamp(1rem, 1.6vw, 1.18rem);
    line-height: 1.8;
}

.section-title {
    display: block;
    width: fit-content;
    margin: 0 auto clamp(2.5rem, 5vw, 4rem);
    font-size: clamp(2.1rem, 5vw, 3.7rem);
    line-height: 1.02;
    letter-spacing: -0.065em;
    font-weight: 800;
}

.section-title::after {
    left: 50%;
    width: 56%;
    height: 4px;
    border-radius: var(--radius-pill);
    transform: translateX(-50%);
    background: linear-gradient(90deg, transparent, var(--primary-color), var(--secondary-color), transparent);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0.82rem 1.2rem;
    border-radius: var(--radius-pill);
    font-weight: 700;
    letter-spacing: -0.025em;
    box-shadow: var(--shadow-soft);
}

.primary {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color) 50%, var(--secondary-color));
    box-shadow: 0 16px 38px rgba(99, 91, 255, 0.28);
}

.secondary {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    backdrop-filter: blur(18px);
}

.primary:hover,
.secondary:hover,
.carousel-nav button:hover,
.contact-item:hover,
.cert-card:hover,
.education-card:hover,
.experience-card:hover,
.project-card:hover,
.group:hover {
    transform: translateY(-4px);
}

.group,
.experience-card,
.education-card,
.cert-card,
.project-card,
.about-image,
.contact-item {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
    backdrop-filter: blur(22px);
}

.experience-card,
.education-card,
.cert-card,
.project-card,
.contact-item {
    border-radius: var(--radius-lg);
}

.experience-card,
.education-card,
.cert-card {
    padding: clamp(1.25rem, 3vw, 2rem);
}

.project-card {
    min-width: min(360px, 82vw);
    margin-right: 1.5rem;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.project-content {
    padding: 1.6rem;
}

.project-content h3,
.cert-content h3,
.education-card h3,
.experience-card h3 {
    color: var(--text-color);
    font-weight: 750;
    letter-spacing: -0.04em;
    line-height: 1.15;
}

.project-content p,
.cert-content p,
.education-card h4,
.education-card p,
.experience-card p,
.certifications li {
    color: var(--light-text);
}

.tech-stack span,
.skill-tag {
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(99, 91, 255, 0.12);
    background: var(--tag-bg);
    color: var(--tag-text);
    padding: 0.38rem 0.72rem;
    border-radius: var(--radius-pill);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.skills-grid {
    gap: clamp(1rem, 3vw, 2rem);
}

.group {
    border-radius: var(--radius-lg);
    padding: clamp(0.9rem, 2vw, 1.25rem);
}

.skill-image,
.skill-overlay {
    border-radius: calc(var(--radius-lg) - 8px);
}

.skill-overlay {
    background: linear-gradient(135deg, rgba(99, 91, 255, 0.72), rgba(0, 212, 255, 0.54));
}

.about-content {
    gap: clamp(2rem, 6vw, 5rem);
}

.about-image,
.image-slider {
    border-radius: var(--radius-lg);
}

.quick-contact a,
.contact-item {
    border-radius: var(--radius-md);
}

.quick-contact a {
    width: fit-content;
    color: var(--light-text);
    font-weight: 600;
}

.contact-info {
    max-width: 560px;
}

.contact-item {
    padding: 1rem 1.1rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.contact-item i,
.cert-icon {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.contact-item i {
    width: 42px;
    height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    color: white;
    font-size: 1.05rem;
    flex: 0 0 auto;
}

.cert-icon {
    box-shadow: 0 14px 32px rgba(99, 91, 255, 0.22);
}

.carousel-nav button,
.slider-btn {
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    color: var(--text-color);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(18px);
}

footer {
    background: #070b16;
    color: rgba(255, 255, 255, 0.72);
    border-top: 1px solid var(--border-color);
}

@media (max-width: 1180px) {
    .container,
    .nav-content {
        max-width: 960px;
    }
}

@media (max-width: 900px) {
    .hero-content {
        flex-direction: column;
        align-items: flex-start;
    }

    .hero-text {
        max-width: 680px;
    }

    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .nav-links.active {
        display: flex;
    }

    .nav-links {
        width: min(82%, 360px);
        background: var(--card-bg-solid);
        border-left: 1px solid var(--border-color);
    }

    .hero {
        padding-top: 7rem;
    }

    .hero-content {
        align-items: center;
    }

    .hero-text h1 {
        font-size: clamp(2.75rem, 13vw, 4.25rem);
    }

    .cta-buttons {
        width: min(100%, 360px);
        margin-inline: auto;
    }
}

@media (max-width: 560px) {
    .container,
    .nav-content {
        padding-inline: 1rem;
    }

    section {
        padding: 4rem 0;
    }

    .theme-switch {
        transform: scale(0.88);
        transform-origin: top right;
    }

    .skills-grid {
        gap: 0.85rem;
    }

    .cert-card,
    .contact-item {
        align-items: flex-start;
    }
}

/* Step 3: Premium Navigation */
.navbar {
    position: fixed;
    top: 18px;
    left: 50%;
    width: min(calc(100% - 2rem), 1120px);
    transform: translateX(-50%);
    padding: 0;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.68);
    box-shadow: 0 18px 55px rgba(15, 23, 42, 0.12);
    backdrop-filter: blur(24px) saturate(1.35);
    -webkit-backdrop-filter: blur(24px) saturate(1.35);
}

.navbar.is-scrolled {
    background: rgba(255, 255, 255, 0.82);
    box-shadow: 0 20px 70px rgba(15, 23, 42, 0.16);
}

.dark-mode .navbar {
    background: rgba(8, 13, 27, 0.68);
}

.dark-mode .navbar.is-scrolled {
    background: rgba(8, 13, 27, 0.84);
}

.nav-content {
    min-height: 64px;
    max-width: none;
    padding: 0.48rem 0.58rem 0.48rem 1rem;
}

.logo {
    display: inline-flex;
    align-items: center;
    min-width: 42px;
    min-height: 42px;
    color: var(--text-color);
    text-decoration: none;
    border-radius: var(--radius-pill);
    transition: color 0.25s ease, transform 0.25s ease, background-color 0.25s ease;
}

.logo:hover,
.logo:focus-visible {
    color: var(--primary-color);
    background: var(--tag-bg);
    transform: translateY(-1px);
}

.nav-links {
    align-items: center;
    gap: 0.25rem;
    padding: 0.28rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.52);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.dark-mode .nav-links {
    background: rgba(15, 23, 42, 0.54);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.nav-links a {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 0.9rem;
    border-radius: var(--radius-pill);
    color: var(--light-text);
    isolation: isolate;
    outline: none;
}

.nav-links a::after {
    inset: auto 0.72rem 6px;
    width: auto;
    height: 2px;
    border-radius: var(--radius-pill);
    opacity: 0;
    transform: scaleX(0);
    transform-origin: center;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.nav-links a:hover,
.nav-links a:focus-visible,
.nav-links a.active {
    color: var(--text-color);
    background: rgba(99, 91, 255, 0.08);
}

.nav-links a:hover::after,
.nav-links a:focus-visible::after,
.nav-links a.active::after {
    width: auto;
    opacity: 1;
    transform: scaleX(1);
}

.nav-links a:focus-visible,
.hamburger:focus-visible,
.logo:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--primary-color), white 25%);
    outline-offset: 3px;
}

.hamburger {
    width: 46px;
    height: 46px;
    margin: 0;
    padding: 0;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
}

.hamburger span {
    width: 18px;
    height: 2px;
    border-radius: var(--radius-pill);
    background: var(--text-color);
    transform-origin: center;
}

.hamburger.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.scroll-progress {
    position: absolute;
    right: 0.75rem;
    bottom: 0;
    left: 0.75rem;
    height: 2px;
    overflow: hidden;
    border-radius: var(--radius-pill);
    background: transparent;
}

.scroll-progress-bar {
    display: block;
    width: 100%;
    height: 100%;
    transform: scaleX(0);
    transform-origin: left;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color), var(--secondary-color));
    transition: transform 0.12s linear;
}

@media (max-width: 900px) {
    .navbar {
        width: min(calc(100% - 8rem), 720px);
    }

    .nav-content {
        padding-right: 0.48rem;
    }
}

@media (max-width: 768px) {
    .navbar {
        left: 0.75rem;
        width: calc(100% - 7.5rem);
        transform: none;
    }

    .hamburger {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .nav-links {
        position: fixed;
        top: calc(100% + 0.75rem);
        right: 0;
        left: 0;
        display: flex;
        width: auto;
        height: auto;
        padding: 0.65rem;
        border-radius: var(--radius-lg);
        background: var(--card-bg-solid);
        border: 1px solid var(--border-color);
        box-shadow: var(--shadow);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        transform: translateY(-0.5rem) scale(0.98);
        transition: opacity 0.25s ease, visibility 0.25s ease, transform 0.25s ease;
        backdrop-filter: blur(24px);
        -webkit-backdrop-filter: blur(24px);
    }

    .nav-links.active {
        right: 0;
        display: flex;
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        transform: translateY(0) scale(1);
    }

    .nav-links a {
        justify-content: center;
        width: 100%;
        min-height: 46px;
        padding: 0 1rem;
    }
}

@media (max-width: 480px) {
    .navbar {
        top: 12px;
        left: 0.5rem;
        width: calc(100% - 6.75rem);
        transform: none;
    }

    .nav-content {
        min-height: 58px;
        padding-left: 0.8rem;
    }

    .logo {
        font-size: 1.35rem;
    }
}

/* Step 4: Premium Hero Section */
.hero {
    --mouse-x: 50%;
    --mouse-y: 45%;
    min-height: 100svh;
    isolation: isolate;
    padding: clamp(8rem, 12vw, 10rem) 0 clamp(5rem, 8vw, 7rem);
    background:
        radial-gradient(circle at var(--mouse-x) var(--mouse-y), rgba(99, 91, 255, 0.18), transparent 22rem),
        linear-gradient(180deg, var(--background) 0%, var(--section-bg) 100%);
}

.hero::before,
.hero::after {
    z-index: -3;
}

.hero-aurora,
.hero-grid {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.hero-aurora {
    z-index: -2;
    background:
        radial-gradient(circle at 18% 24%, rgba(99, 91, 255, 0.32), transparent 24rem),
        radial-gradient(circle at 78% 22%, rgba(0, 212, 255, 0.26), transparent 28rem),
        radial-gradient(circle at 52% 84%, rgba(124, 58, 237, 0.18), transparent 26rem);
    filter: blur(14px);
    opacity: 0.9;
    animation: auroraDrift 14s ease-in-out infinite alternate;
}

.hero-grid {
    z-index: -1;
    background-image:
        linear-gradient(rgba(99, 91, 255, 0.08) 1px, transparent 1px),
        linear-gradient(90deg, rgba(99, 91, 255, 0.08) 1px, transparent 1px);
    background-size: 72px 72px;
    mask-image: radial-gradient(circle at center, black 0%, transparent 72%);
    opacity: 0.32;
}

.hero-content {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
    gap: clamp(3rem, 7vw, 6rem);
    min-height: min(720px, calc(100svh - 12rem));
}

.hero-text {
    max-width: 660px;
}

.hero-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    width: fit-content;
    margin-bottom: 1.25rem;
    padding: 0.48rem 0.82rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
    color: var(--light-text);
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: -0.025em;
    backdrop-filter: blur(18px);
}

.status-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #22c55e;
    box-shadow: 0 0 0 6px rgba(34, 197, 94, 0.12);
}

.hero-text h1 {
    max-width: 720px;
    margin-bottom: 1.15rem;
    font-size: clamp(2.65rem, 5.8vw, 4.95rem);
    line-height: 1.02;
    letter-spacing: -0.065em;
    background:
        linear-gradient(115deg, var(--text-color) 8%, var(--primary-color) 48%, var(--secondary-color) 92%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero h2 {
    min-height: 2.25rem;
    margin-bottom: 0.85rem;
    color: var(--text-color);
    font-size: clamp(1.08rem, 1.8vw, 1.42rem);
    font-weight: 750;
    letter-spacing: -0.035em;
}

#animated-intro {
    display: inline-block;
    color: var(--primary-color);
    transition: opacity 0.22s ease, transform 0.22s ease;
}

#animated-intro.is-changing {
    opacity: 0;
    transform: translateY(0.35rem);
}

.hero-subtitle {
    max-width: 580px;
    margin-bottom: 1.75rem;
    color: var(--light-text);
    font-size: clamp(0.98rem, 1.35vw, 1.08rem);
    line-height: 1.75;
}

.cta-buttons {
    flex-wrap: wrap;
    align-items: center;
    gap: 0.85rem;
}

.resume-btn {
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.62);
    color: var(--text-color);
    backdrop-filter: blur(18px);
}

.dark-mode .resume-btn {
    background: rgba(15, 23, 42, 0.62);
}

.hero-socials {
    display: flex;
    gap: 0.7rem;
    margin-top: 1.4rem;
}

.hero-socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--card-bg);
    color: var(--text-color);
    box-shadow: var(--shadow-soft);
    text-decoration: none;
    transition: transform 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    backdrop-filter: blur(18px);
}

.hero-socials a:hover,
.hero-socials a:focus-visible {
    color: var(--primary-color);
    border-color: rgba(99, 91, 255, 0.28);
    box-shadow: var(--glow);
    transform: translateY(-3px);
}

.hero-visual {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 440px;
    transform: perspective(900px) rotateX(var(--hero-tilt-y, 0deg)) rotateY(var(--hero-tilt-x, 0deg));
    transition: transform 0.18s ease-out;
}

.hero-orb {
    position: relative;
    display: grid;
    place-items: center;
    width: min(440px, 74vw);
    aspect-ratio: 1;
    border: 1px solid var(--border-color);
    border-radius: 42%;
    background:
        radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.86), transparent 10rem),
        linear-gradient(135deg, rgba(99, 91, 255, 0.18), rgba(0, 212, 255, 0.1));
    box-shadow: var(--glow), inset 0 1px 0 rgba(255, 255, 255, 0.55);
    overflow: hidden;
    animation: orbFloat 7s ease-in-out infinite;
}

.dark-mode .hero-orb {
    background:
        radial-gradient(circle at 35% 28%, rgba(255, 255, 255, 0.1), transparent 10rem),
        linear-gradient(135deg, rgba(99, 91, 255, 0.22), rgba(0, 212, 255, 0.1));
}

.hero-animation {
    width: min(310px, 56vw);
    height: min(310px, 56vw);
    z-index: 2;
    filter: drop-shadow(0 24px 42px rgba(99, 91, 255, 0.18));
}

.orb-ring {
    position: absolute;
    border: 1px solid rgba(99, 91, 255, 0.28);
    border-radius: 50%;
    pointer-events: none;
}

.ring-one {
    inset: 11%;
    animation: orbitSpin 16s linear infinite;
}

.ring-two {
    inset: 20%;
    transform: rotate(58deg);
    animation: orbitSpin 22s linear infinite reverse;
}

.ring-three {
    inset: 30%;
    border-color: rgba(0, 212, 255, 0.26);
    animation: orbitPulse 4.8s ease-in-out infinite;
}

.hero-stat-card {
    position: absolute;
    width: min(230px, 54vw);
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--card-bg);
    box-shadow: var(--shadow);
    backdrop-filter: blur(20px);
}

.hero-stat-card span {
    display: block;
    margin-bottom: 0.28rem;
    color: var(--light-text);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.hero-stat-card strong {
    color: var(--text-color);
    font-size: 0.96rem;
    letter-spacing: -0.035em;
}

.stat-primary {
    top: 13%;
    right: 0;
}

.stat-secondary {
    bottom: 13%;
    left: 0;
}

.scroll-indicator {
    position: absolute;
    right: clamp(1.25rem, 4vw, 2.5rem);
    bottom: 1.5rem;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--light-text);
    font-size: 0.84rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-decoration: none;
    transition: color 0.25s ease, transform 0.25s ease;
}

.scroll-indicator i {
    animation: scrollBounce 1.8s ease-in-out infinite;
}

.scroll-indicator:hover,
.scroll-indicator:focus-visible {
    color: var(--primary-color);
    transform: translateY(-2px);
}

[data-motion="hero-copy"],
[data-motion="hero-visual"],
.hero-socials,
.scroll-indicator {
    opacity: 0;
    translate: 0 26px;
    animation: heroReveal 0.9s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

[data-motion="hero-visual"] {
    animation-delay: 0.14s;
}

.hero-socials {
    animation-delay: 0.28s;
}

.scroll-indicator {
    animation-delay: 0.5s;
}

@keyframes heroReveal {
    to {
        opacity: 1;
        translate: 0 0;
    }
}

@keyframes auroraDrift {
    0% {
        transform: translate3d(-2%, -1%, 0) scale(1);
    }
    100% {
        transform: translate3d(2%, 2%, 0) scale(1.06);
    }
}

@keyframes orbFloat {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-18px) rotate(2deg);
    }
}

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

@keyframes orbitPulse {
    0%, 100% {
        opacity: 0.46;
        transform: scale(0.95);
    }
    50% {
        opacity: 1;
        transform: scale(1.06);
    }
}

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

@media (max-width: 980px) {
    .hero-content {
        grid-template-columns: 1fr;
        text-align: left;
    }

    .hero-visual {
        min-height: 380px;
        order: -1;
    }

    .stat-primary {
        right: 8%;
    }

    .stat-secondary {
        left: 8%;
    }
}

@media (max-width: 768px) {
    .hero {
        padding-top: 8.2rem;
    }

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

    .hero-eyebrow,
    .hero-subtitle,
    .cta-buttons,
    .hero-socials {
        margin-inline: auto;
    }

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

    .hero-visual {
        min-height: 330px;
    }

    .hero-stat-card {
        display: none;
    }
}

@media (max-width: 520px) {
    .hero-text h1 {
        font-size: clamp(2.35rem, 12vw, 3.35rem);
        line-height: 1.05;
        letter-spacing: -0.055em;
    }

    .hero h2 {
        min-height: 3.5rem;
    }

    .cta-buttons {
        width: 100%;
    }

    .cta-buttons .btn {
        width: 100%;
    }

    .scroll-indicator {
        right: 50%;
        translate: 50% 0;
    }
}

/* Step 4 Revision: javal.dev-inspired text hero */
.hero {
    min-height: 100svh;
    padding: clamp(8.5rem, 13vw, 11rem) 0 clamp(4.75rem, 8vw, 6.5rem);
    background:
        radial-gradient(circle at var(--mouse-x) var(--mouse-y), rgba(99, 91, 255, 0.2), transparent 19rem),
        radial-gradient(circle at 50% 16%, rgba(0, 212, 255, 0.13), transparent 28rem),
        linear-gradient(180deg, var(--background) 0%, var(--section-bg) 100%);
}

.hero-content-centered {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: clamp(2rem, 4vw, 3rem);
    min-height: min(680px, calc(100svh - 13rem));
    text-align: center;
}

.hero-content-centered .hero-text {
    max-width: 920px;
    margin: 0 auto;
}

.hero-topline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.hero-kicker,
.hero-eyebrow {
    min-height: 38px;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    padding: 0.48rem 0.9rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.52);
    color: var(--text-color);
    box-shadow: var(--shadow-soft);
    font-size: 0.88rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    text-decoration: none;
    backdrop-filter: blur(18px);
    transition: transform 0.25s ease, border-color 0.25s ease, color 0.25s ease;
}

.dark-mode .hero-kicker {
    background: rgba(15, 23, 42, 0.54);
}

.hero-kicker:hover,
.hero-kicker:focus-visible {
    color: var(--primary-color);
    border-color: rgba(99, 91, 255, 0.3);
    transform: translateY(-2px);
}

.hero-content-centered .hero-eyebrow {
    margin-bottom: 0;
    font-size: 0.88rem;
}

.hero-content-centered .hero-text h1 {
    max-width: 880px;
    margin: 0 auto 1.1rem;
    font-size: clamp(3rem, 7vw, 6.15rem);
    line-height: 0.95;
    letter-spacing: -0.085em;
}

.hero-intro {
    max-width: 780px;
    margin: 0 auto 0.9rem;
    color: var(--text-color);
    font-size: clamp(1.18rem, 2.2vw, 1.7rem);
    font-weight: 700;
    line-height: 1.35;
    letter-spacing: -0.045em;
}

.hero-content-centered .hero-subtitle {
    max-width: 730px;
    margin: 0 auto 2rem;
    font-size: clamp(1rem, 1.45vw, 1.14rem);
    line-height: 1.8;
}

.hero-content-centered .cta-buttons,
.hero-content-centered .hero-socials {
    justify-content: center;
}

.hero-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(120px, 1fr));
    width: min(720px, 100%);
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    background: var(--card-bg);
    box-shadow: var(--shadow);
    backdrop-filter: blur(22px);
}

.hero-metrics div {
    padding: 1.15rem 1rem;
}

.hero-metrics div + div {
    border-left: 1px solid var(--border-color);
}

.hero-metrics strong,
.hero-metrics span {
    display: block;
}

.hero-metrics strong {
    color: var(--text-color);
    font-size: clamp(1.15rem, 2.2vw, 1.55rem);
    line-height: 1;
    letter-spacing: -0.055em;
}

.hero-metrics span {
    margin-top: 0.4rem;
    color: var(--light-text);
    font-size: 0.82rem;
    font-weight: 700;
}

[data-motion="hero-metrics"] {
    opacity: 0;
    translate: 0 26px;
    animation: heroReveal 0.9s cubic-bezier(0.16, 1, 0.3, 1) 0.36s forwards;
}

@media (max-width: 768px) {
    .hero-content-centered .hero-text h1 {
        font-size: clamp(2.7rem, 11vw, 4.4rem);
        line-height: 1;
    }

    .hero-intro {
        font-size: clamp(1.08rem, 4vw, 1.35rem);
    }

    .hero-metrics {
        grid-template-columns: 1fr;
        max-width: 360px;
    }

    .hero-metrics div + div {
        border-top: 1px solid var(--border-color);
        border-left: 0;
    }
}

@media (max-width: 520px) {
    .hero-content-centered .hero-text h1 {
        font-size: clamp(2.45rem, 12vw, 3.35rem);
        letter-spacing: -0.065em;
    }

    .hero-topline {
        gap: 0.55rem;
    }

    .hero-kicker,
    .hero-content-centered .hero-eyebrow {
        width: 100%;
        justify-content: center;
    }
}

/* Step 5: Story-driven About Section */
.about {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 15% 8%, rgba(99, 91, 255, 0.08), transparent 28rem),
        radial-gradient(circle at 85% 45%, rgba(0, 212, 255, 0.06), transparent 26rem),
        var(--background);
}

.about-header {
    max-width: 860px;
    margin: 0 auto clamp(2.5rem, 5vw, 4rem);
    text-align: center;
}

.section-kicker {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 34px;
    margin-bottom: 1rem;
    padding: 0.42rem 0.78rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--card-bg);
    color: var(--primary-color);
    box-shadow: var(--shadow-soft);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    backdrop-filter: blur(18px);
}

.about-header .section-title {
    margin-bottom: 1rem;
}

.about-header p {
    max-width: 760px;
    margin: 0 auto;
    color: var(--light-text);
    font-size: clamp(1.02rem, 1.5vw, 1.16rem);
    line-height: 1.85;
}

.about-story-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1rem, 2.5vw, 1.5rem);
    margin-bottom: clamp(1.5rem, 3vw, 2rem);
}

.about-story-card,
.about-timeline,
.about-stats {
    border: 1px solid var(--border-color);
    background: var(--card-bg);
    box-shadow: var(--shadow);
    backdrop-filter: blur(22px);
}

.about-story-card {
    min-height: 290px;
    padding: clamp(1.35rem, 3vw, 2rem);
    border-radius: var(--radius-lg);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.about-story-card:hover {
    transform: translateY(-5px);
    border-color: rgba(99, 91, 255, 0.24);
    box-shadow: var(--glow);
}

.story-label {
    display: inline-block;
    margin-bottom: 1.1rem;
    color: var(--primary-color);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.about-story-card h3 {
    max-width: 520px;
    margin-bottom: 1rem;
    color: var(--text-color);
    font-size: clamp(1.55rem, 3vw, 2.35rem);
    line-height: 1.05;
    letter-spacing: -0.06em;
}

.about-story-card p,
.timeline-item p {
    color: var(--light-text);
    font-size: 1rem;
    line-height: 1.8;
}

.about-details {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.65fr);
    gap: clamp(1rem, 2.5vw, 1.5rem);
    align-items: stretch;
}

.about-timeline {
    position: relative;
    padding: clamp(1.2rem, 3vw, 2rem);
    border-radius: var(--radius-lg);
}

.timeline-item {
    position: relative;
    padding-left: 2rem;
    padding-bottom: 1.6rem;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-item::before {
    content: '';
    position: absolute;
    top: 0.45rem;
    left: 0;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    box-shadow: 0 0 0 6px rgba(99, 91, 255, 0.12);
}

.timeline-item::after {
    content: '';
    position: absolute;
    top: 1.35rem;
    bottom: 0.2rem;
    left: 4px;
    width: 1px;
    background: var(--border-color);
}

.timeline-item:last-child::after {
    display: none;
}

.timeline-item span {
    display: inline-block;
    margin-bottom: 0.35rem;
    color: var(--primary-color);
    font-size: 0.82rem;
    font-weight: 800;
}

.timeline-item h3 {
    margin-bottom: 0.42rem;
    color: var(--text-color);
    font-size: clamp(1.08rem, 2vw, 1.35rem);
    line-height: 1.2;
    letter-spacing: -0.045em;
}

.about-stats {
    display: grid;
    grid-template-columns: 1fr;
    overflow: hidden;
    border-radius: var(--radius-lg);
}

.about-stats div {
    padding: 1.35rem;
}

.about-stats div + div {
    border-top: 1px solid var(--border-color);
}

.about-stats strong,
.about-stats span {
    display: block;
}

.about-stats strong {
    color: var(--text-color);
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    line-height: 1;
    letter-spacing: -0.07em;
}

.about-stats span {
    margin-top: 0.45rem;
    color: var(--light-text);
    font-size: 0.9rem;
    font-weight: 700;
}

.about-reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
}

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

@media (max-width: 900px) {
    .about-story-grid,
    .about-details {
        grid-template-columns: 1fr;
    }

    .about-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .about-stats div + div {
        border-top: 0;
        border-left: 1px solid var(--border-color);
    }

    .about-stats div:nth-child(3) {
        border-left: 0;
    }

    .about-stats div:nth-child(n + 3) {
        border-top: 1px solid var(--border-color);
    }
}

@media (max-width: 560px) {
    .about-header {
        text-align: left;
    }

    .about-header .section-title {
        margin-inline: 0;
        text-align: left;
    }

    .about-header .section-title::after {
        left: 0;
        transform: none;
    }

    .about-stats {
        grid-template-columns: 1fr;
    }

    .about-stats div + div,
    .about-stats div:nth-child(n + 3) {
        border-top: 1px solid var(--border-color);
        border-left: 0;
    }
}

/* Step 6: Interactive Skill Cards */
.skills {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 80% 10%, rgba(99, 91, 255, 0.08), transparent 24rem),
        var(--section-bg);
}

.skills-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1rem, 2vw, 1.35rem);
    padding: clamp(1rem, 3vw, 2rem) 0 0;
}

.skill-card {
    position: relative;
    min-height: 285px;
    padding: 1.35rem;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.42)),
        var(--card-bg);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(22px);
    transform: translateY(0);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
}

.dark-mode .skill-card {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.015)),
        var(--card-bg);
}

.skill-card::before {
    content: '';
    position: absolute;
    inset: -1px;
    opacity: 0;
    background: radial-gradient(circle at 20% 0%, rgba(99, 91, 255, 0.2), transparent 15rem);
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.skill-card:hover {
    transform: translateY(-6px);
    border-color: rgba(99, 91, 255, 0.26);
    box-shadow: var(--glow);
}

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

.skill-card-top {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.skill-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.8), transparent 2rem),
        linear-gradient(135deg, rgba(99, 91, 255, 0.18), rgba(0, 212, 255, 0.1));
    color: var(--primary-color);
    font-size: 1.25rem;
    box-shadow: var(--shadow-soft);
    transition: transform 0.3s ease, color 0.3s ease;
}

.skill-card:hover .skill-icon {
    color: var(--secondary-color);
    transform: rotate(-4deg) scale(1.06);
}

.skill-level {
    padding: 0.35rem 0.62rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--tag-bg);
    color: var(--tag-text);
    font-size: 0.75rem;
    font-weight: 800;
}

.skill-card h3,
.skill-card p,
.skill-card .skill-tags,
.skill-meter {
    position: relative;
    z-index: 1;
}

.skill-card h3 {
    margin-bottom: 0.75rem;
    color: var(--text-color);
    font-size: clamp(1.25rem, 2.3vw, 1.65rem);
    line-height: 1.05;
    letter-spacing: -0.055em;
}

.skill-card p {
    min-height: 78px;
    color: var(--light-text);
    font-size: 0.96rem;
    line-height: 1.65;
}

.skill-card .skill-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin: 1.1rem 0 1.15rem;
}

.skill-card .skill-tags span {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 0.28rem 0.55rem;
    border: 1px solid rgba(99, 91, 255, 0.12);
    border-radius: var(--radius-pill);
    background: var(--tag-bg);
    color: var(--tag-text);
    font-size: 0.76rem;
    font-weight: 800;
}

.skill-meter {
    height: 7px;
    overflow: hidden;
    border-radius: var(--radius-pill);
    background: rgba(99, 91, 255, 0.1);
}

.skill-meter span {
    display: block;
    width: var(--level);
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color), var(--secondary-color));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
}

.skill-card.is-visible .skill-meter span,
.skill-card:hover .skill-meter span {
    transform: scaleX(1);
}

@media (max-width: 1080px) {
    .skills-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .skills-grid {
        grid-template-columns: 1fr;
    }

    .skill-card {
        min-height: auto;
    }

    .skill-card p {
        min-height: auto;
    }
}

/* Step 7: Premium Project Case Studies */
.projects {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 18% 6%, rgba(99, 91, 255, 0.11), transparent 30rem),
        radial-gradient(circle at 82% 26%, rgba(0, 212, 255, 0.08), transparent 28rem),
        var(--background);
}

.projects-header {
    max-width: 860px;
    margin: 0 auto clamp(2rem, 4vw, 3rem);
    text-align: center;
}

.projects-header .section-title {
    margin-bottom: 1rem;
}

.projects-header p {
    max-width: 760px;
    margin: 0 auto;
    color: var(--light-text);
    font-size: clamp(1rem, 1.5vw, 1.14rem);
    line-height: 1.8;
}

.project-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: clamp(1.5rem, 3vw, 2.25rem);
    padding: 0.6rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(22px);
}

.project-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.project-filter {
    min-height: 38px;
    padding: 0 0.85rem;
    border: 1px solid transparent;
    border-radius: var(--radius-pill);
    background: transparent;
    color: var(--light-text);
    font: inherit;
    font-size: 0.88rem;
    font-weight: 800;
    cursor: pointer;
    transition: color 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.project-filter:hover,
.project-filter:focus-visible,
.project-filter.active {
    color: var(--text-color);
    border-color: var(--border-color);
    background: var(--tag-bg);
    transform: translateY(-1px);
}

.project-search {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    min-width: min(360px, 100%);
    min-height: 44px;
    padding: 0 0.9rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.52);
    color: var(--light-text);
}

.dark-mode .project-search {
    background: rgba(15, 23, 42, 0.54);
}

.project-search input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--text-color);
    font: inherit;
    font-size: 0.92rem;
}

.project-search input::placeholder {
    color: var(--light-text);
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1.2rem, 2.5vw, 1.65rem);
}

.project-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    margin-right: 0;
    overflow: hidden;
    border: 1px solid var(--border-color);
    border-radius: calc(var(--radius-lg) + 6px);
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
    transform-style: preserve-3d;
    transition: opacity 0.25s ease, transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
    backdrop-filter: blur(24px);
}

.project-card::after {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0;
    background: radial-gradient(420px circle at var(--spotlight-x, 50%) var(--spotlight-y, 0%), rgba(99, 91, 255, 0.22), transparent 42%);
    transition: opacity 0.25s ease;
    pointer-events: none;
}

.project-card:hover {
    border-color: rgba(99, 91, 255, 0.28);
    box-shadow: var(--glow);
}

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

.project-card.is-hidden {
    display: none;
}

.project-card.featured {
    grid-column: span 1;
}

.project-visual {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 220px;
    overflow: hidden;
    color: white;
    isolation: isolate;
}

.project-visual::before {
    content: '';
    position: absolute;
    inset: 16%;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 32px;
    transform: rotate(-5deg);
}

.project-visual::after {
    content: '';
    position: absolute;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.18);
    filter: blur(18px);
    transform: translate(26%, -18%);
}

.project-visual i {
    z-index: 1;
    font-size: clamp(2.2rem, 5vw, 3.4rem);
    filter: drop-shadow(0 22px 40px rgba(0, 0, 0, 0.25));
}

.project-visual span {
    position: absolute;
    right: 1rem;
    bottom: 1rem;
    z-index: 1;
    padding: 0.38rem 0.7rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.16);
    font-size: 0.78rem;
    font-weight: 800;
    backdrop-filter: blur(14px);
}

.rag-visual { background: linear-gradient(135deg, #635bff, #7c3aed 48%, #00d4ff); }
.docs-visual { background: linear-gradient(135deg, #0f766e, #14b8a6 48%, #38bdf8); }
.rooh-visual { background: linear-gradient(135deg, #be185d, #7c3aed 52%, #fb7185); }
.cv-visual { background: linear-gradient(135deg, #1d4ed8, #06b6d4 52%, #22c55e); }
.web-visual { background: linear-gradient(135deg, #111827, #635bff 52%, #38bdf8); }
.health-visual { background: linear-gradient(135deg, #dc2626, #f97316 52%, #facc15); }
.devops-visual { background: linear-gradient(135deg, #334155, #2563eb 52%, #22c55e); }
.portfolio-visual { background: linear-gradient(135deg, #020617, #4f46e5 52%, #a78bfa); }
.mobile-visual { background: linear-gradient(135deg, #0369a1, #0ea5e9 52%, #67e8f9); }

.project-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: clamp(1.25rem, 2.5vw, 1.75rem);
}

.project-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-bottom: 0.9rem;
}

.project-meta span {
    padding: 0.32rem 0.6rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--tag-bg);
    color: var(--tag-text);
    font-size: 0.74rem;
    font-weight: 800;
}

.project-content h3 {
    margin-bottom: 0.72rem;
    color: var(--text-color);
    font-size: clamp(1.35rem, 2.6vw, 2rem);
    line-height: 1.06;
    letter-spacing: -0.06em;
}

.project-content > p {
    color: var(--light-text);
    font-size: 0.98rem;
    line-height: 1.75;
}

.project-content .tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin: 1.05rem 0 1.2rem;
}

.project-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem;
    margin-top: auto;
}

.project-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 0.85rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--card-bg-solid);
    color: var(--text-color);
    font-size: 0.86rem;
    font-weight: 800;
    text-decoration: none;
    transition: transform 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.project-actions a:hover,
.project-actions a:focus-visible {
    color: var(--primary-color);
    border-color: rgba(99, 91, 255, 0.3);
    transform: translateY(-2px);
}

.project-actions .disabled-link {
    opacity: 0.55;
    cursor: not-allowed;
    pointer-events: none;
}

.project-details {
    margin-top: 1rem;
    border-top: 1px solid var(--border-color);
}

.project-details summary {
    padding: 0.95rem 0 0;
    color: var(--text-color);
    font-weight: 800;
    cursor: pointer;
    list-style: none;
}

.project-details summary::-webkit-details-marker {
    display: none;
}

.project-details summary::after {
    content: '+';
    float: right;
    color: var(--primary-color);
}

.project-details[open] summary::after {
    content: '-';
}

.case-study-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
    padding-top: 1rem;
}

.case-study-grid div {
    padding: 0.85rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.36);
}

.dark-mode .case-study-grid div {
    background: rgba(15, 23, 42, 0.38);
}

.case-study-grid strong {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--primary-color);
    font-size: 0.76rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.case-study-grid p {
    color: var(--light-text);
    font-size: 0.88rem;
    line-height: 1.6;
}

.project-empty {
    margin-top: 1.5rem;
    color: var(--light-text);
    text-align: center;
    font-weight: 700;
}

@media (max-width: 980px) {
    .project-controls {
        align-items: stretch;
        flex-direction: column;
    }

    .project-search {
        min-width: 0;
    }

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

@media (max-width: 620px) {
    .projects-header {
        text-align: left;
    }

    .projects-header .section-title {
        margin-inline: 0;
        text-align: left;
    }

    .projects-header .section-title::after {
        left: 0;
        transform: none;
    }

    .project-filters {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .case-study-grid {
        grid-template-columns: 1fr;
    }
}

/* Steps 8-9: Experience Timeline and Certifications */
.experience,
.certificates {
    position: relative;
    overflow: hidden;
}

.experience {
    background:
        radial-gradient(circle at 12% 12%, rgba(99, 91, 255, 0.08), transparent 28rem),
        var(--background);
}

.experience-header,
.cert-header {
    max-width: 860px;
    margin: 0 auto clamp(2.25rem, 5vw, 4rem);
    text-align: center;
}

.experience-header .section-title,
.cert-header .section-title {
    margin-bottom: 1rem;
}

.experience-header p,
.cert-header p {
    max-width: 760px;
    margin: 0 auto;
    color: var(--light-text);
    font-size: clamp(1rem, 1.45vw, 1.14rem);
    line-height: 1.8;
}

.experience-timeline {
    position: relative;
    display: grid;
    gap: 1.35rem;
    max-width: 980px;
    margin: 0 auto;
}

.experience-timeline::before {
    content: '';
    position: absolute;
    top: 1.5rem;
    bottom: 1.5rem;
    left: 34px;
    width: 1px;
    background: linear-gradient(180deg, transparent, var(--border-color), transparent);
}

.experience-item {
    position: relative;
    display: grid;
    grid-template-columns: 68px minmax(0, 1fr);
    gap: 1.2rem;
    align-items: start;
}

.experience-logo {
    position: sticky;
    top: 110px;
    z-index: 1;
    display: grid;
    place-items: center;
    width: 68px;
    height: 68px;
    border: 1px solid var(--border-color);
    border-radius: 22px;
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.75), transparent 2.2rem),
        linear-gradient(135deg, rgba(99, 91, 255, 0.2), rgba(0, 212, 255, 0.12)),
        var(--card-bg-solid);
    color: var(--primary-color);
    box-shadow: var(--shadow);
    font-size: 0.92rem;
    font-weight: 900;
    letter-spacing: -0.05em;
}

.experience-card-modern {
    position: relative;
    padding: clamp(1.25rem, 3vw, 2rem);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(22px);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.experience-card-modern:hover {
    transform: translateY(-5px);
    border-color: rgba(99, 91, 255, 0.26);
    box-shadow: var(--glow);
}

.experience-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.experience-meta span,
.experience-tech span {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0.28rem 0.62rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--tag-bg);
    color: var(--tag-text);
    font-size: 0.78rem;
    font-weight: 800;
}

.experience-card-modern h3 {
    margin-bottom: 0.35rem;
    color: var(--text-color);
    font-size: clamp(1.35rem, 2.6vw, 2rem);
    line-height: 1.08;
    letter-spacing: -0.06em;
}

.experience-card-modern h4 {
    margin-bottom: 1rem;
    color: var(--primary-color);
    font-size: 1rem;
    font-weight: 800;
}

.experience-card-modern ul {
    display: grid;
    gap: 0.7rem;
    margin: 0 0 1.25rem;
    padding-left: 1.1rem;
    color: var(--light-text);
}

.experience-card-modern li {
    line-height: 1.7;
}

.experience-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}

.certificates {
    background:
        radial-gradient(circle at 80% 12%, rgba(0, 212, 255, 0.08), transparent 26rem),
        var(--section-bg);
}

.cert-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1rem, 2vw, 1.35rem);
    margin-top: 0;
}

.cert-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    overflow: hidden;
    min-height: 390px;
    padding: 0;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    background: var(--card-bg);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(22px);
    transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.cert-card::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0;
    background: radial-gradient(circle at 24% 0%, rgba(99, 91, 255, 0.18), transparent 18rem);
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.cert-card:hover {
    transform: translateY(-6px);
    border-color: rgba(99, 91, 255, 0.26);
    box-shadow: var(--glow);
}

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

.cert-preview {
    position: relative;
    display: grid;
    place-items: center;
    min-height: 160px;
    overflow: hidden;
    color: white;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color) 50%, var(--secondary-color));
}

.cert-preview::before {
    content: '';
    position: absolute;
    inset: 18px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 22px;
    transform: rotate(-3deg);
}

.cert-preview i {
    z-index: 1;
    font-size: 2.8rem;
    filter: drop-shadow(0 18px 32px rgba(0, 0, 0, 0.22));
}

.cert-preview span {
    position: absolute;
    right: 1rem;
    bottom: 1rem;
    z-index: 1;
    padding: 0.34rem 0.64rem;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.16);
    font-size: 0.76rem;
    font-weight: 900;
    backdrop-filter: blur(14px);
}

.cert-card .cert-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
    padding: 1.35rem;
}

.cert-card .cert-icon {
    width: 42px;
    height: 42px;
    margin-bottom: 1rem;
    border-radius: var(--radius-sm);
}

.cert-card h3 {
    margin-bottom: 0.65rem;
    color: var(--text-color);
    font-size: clamp(1.12rem, 2vw, 1.45rem);
    line-height: 1.12;
    letter-spacing: -0.05em;
}

.cert-card p {
    margin-bottom: 1.2rem;
    color: var(--light-text);
    line-height: 1.7;
}

.cert-card a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: fit-content;
    min-height: 40px;
    margin-top: auto;
    padding: 0 0.85rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-pill);
    background: var(--card-bg-solid);
    color: var(--text-color);
    font-size: 0.86rem;
    font-weight: 900;
    text-decoration: none;
    transition: transform 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.cert-card a:hover,
.cert-card a:focus-visible {
    color: var(--primary-color);
    border-color: rgba(99, 91, 255, 0.3);
    transform: translateY(-2px);
}

.experience-reveal,
.cert-reveal {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 0.75s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.75s cubic-bezier(0.16, 1, 0.3, 1);
}

.experience-reveal.is-visible,
.cert-reveal.is-visible {
    opacity: 1;
    transform: translateY(0);
}

@media (max-width: 1040px) {
    .cert-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .experience-header,
    .cert-header {
        text-align: left;
    }

    .experience-header .section-title,
    .cert-header .section-title {
        margin-inline: 0;
        text-align: left;
    }

    .experience-header .section-title::after,
    .cert-header .section-title::after {
        left: 0;
        transform: none;
    }

    .experience-timeline::before {
        left: 24px;
    }

    .experience-item {
        grid-template-columns: 50px minmax(0, 1fr);
        gap: 0.85rem;
    }

    .experience-logo {
        width: 50px;
        height: 50px;
        border-radius: 16px;
        font-size: 0.72rem;
    }
}

@media (max-width: 640px) {
    .cert-grid {
        grid-template-columns: 1fr;
    }
}

/* Steps 10-18: Contact, Footer, Global Motion, Background, A11y */
.site-bg {
    position: fixed;
    inset: 0;
    z-index: -10;
    overflow: hidden;
    pointer-events: none;
    background: var(--background);
}

.mesh {
    position: absolute;
    width: 42vw;
    min-width: 320px;
    aspect-ratio: 1;
    border-radius: 50%;
    filter: blur(58px);
    opacity: 0.24;
    transform: translate3d(0, var(--scroll-y, 0), 0);
    animation: meshFloat 18s ease-in-out infinite alternate;
}

.mesh-one {
    top: -12%;
    left: -10%;
    background: #635bff;
}

.mesh-two {
    top: 20%;
    right: -12%;
    background: #00d4ff;
    animation-delay: -5s;
}

.mesh-three {
    bottom: -18%;
    left: 28%;
    background: #7c3aed;
    animation-delay: -9s;
}

.noise {
    position: absolute;
    inset: 0;
    opacity: 0.035;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.8) 0 1px, transparent 1px),
        radial-gradient(circle at 70% 80%, rgba(0, 0, 0, 0.65) 0 1px, transparent 1px);
    background-size: 34px 34px, 47px 47px;
}

.cursor-glow {
    position: fixed;
    top: -160px;
    left: -160px;
    z-index: 9999;
    width: 320px;
    height: 320px;
    border-radius: 50%;
    opacity: 0.16;
    background: radial-gradient(circle, rgba(99, 91, 255, 0.58), transparent 68%);
    pointer-events: none;
    transition: transform 0.12s linear;
    mix-blend-mode: screen;
}

.motion-item {
    opacity: 0;
    transform: translateY(22px) scale(0.985);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.motion-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.contact {
    position: relative;
    overflow: hidden;
    background:
        radial-gradient(circle at 16% 12%, rgba(99, 91, 255, 0.1), transparent 26rem),
        radial-gradient(circle at 82% 30%, rgba(0, 212, 255, 0.08), transparent 28rem),
        var(--background);
}

.contact-header {
    max-width: 860px;
    margin: 0 auto clamp(2rem, 5vw, 3.25rem);
    text-align: center;
}

.contact-header .section-title {
    margin-bottom: 1rem;
}

.contact-header p {
    max-width: 720px;
    margin: 0 auto;
    color: var(--light-text);
    font-size: clamp(1rem, 1.45vw, 1.14rem);
    line-height: 1.8;
}

.contact-shell {
    display: grid;
    grid-template-columns: minmax(280px, 0.78fr) minmax(0, 1.22fr);
    gap: clamp(1rem, 3vw, 1.6rem);
    align-items: stretch;
    max-width: 1040px;
    margin: 0 auto;
}

.contact-panel,
.contact-form {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    background: var(--card-bg);
    box-shadow: var(--shadow);
    backdrop-filter: blur(24px);
}

.contact-panel {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 1.4rem;
    padding: clamp(1.25rem, 3vw, 1.75rem);
}

.availability-card {
    display: flex;
    gap: 0.9rem;
    align-items: flex-start;
    padding: 1rem;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.36);
}

.dark-mode .availability-card {
    background: rgba(15, 23, 42, 0.38);
}

.availability-card strong {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--text-color);
    letter-spacing: -0.035em;
}

.availability-card p {
    color: var(--light-text);
    line-height: 1.65;
}

.contact-methods {
    display: grid;
    gap: 0.75rem;
}

.contact-methods a,
.contact-socials a,
.footer-actions a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-color);
    background: var(--card-bg-solid);
    color: var(--text-color);
    text-decoration: none;
    transition: transform 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.contact-methods a {
    justify-content: flex-start;
    gap: 0.75rem;
    min-height: 46px;
    padding: 0 0.9rem;
    border-radius: var(--radius-md);
    font-weight: 700;
}

.contact-methods a:hover,
.contact-socials a:hover,
.footer-actions a:hover {
    color: var(--primary-color);
    border-color: rgba(99, 91, 255, 0.3);
    box-shadow: var(--shadow-soft);
    transform: translateY(-3px);
}

.contact-socials {
    display: flex;
    gap: 0.7rem;
}

.contact-socials a,
.footer-actions a {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-pill);
}

.contact-form {
    display: grid;
    gap: 1rem;
    padding: clamp(1.25rem, 3vw, 1.9rem);
}

.form-row {
    display: grid;
    gap: 0.45rem;
}

.form-row label {
    color: var(--text-color);
    font-size: 0.88rem;
    font-weight: 800;
}

.form-row input,
.form-row textarea {
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.58);
    color: var(--text-color);
    font: inherit;
    padding: 0.92rem 1rem;
    outline: none;
    resize: vertical;
    transition: border-color 0.25s ease, box-shadow 0.25s ease, background-color 0.25s ease;
}

.dark-mode .form-row input,
.dark-mode .form-row textarea {
    background: rgba(15, 23, 42, 0.5);
}

.form-row input:focus,
.form-row textarea:focus {
    border-color: rgba(99, 91, 255, 0.42);
    box-shadow: 0 0 0 4px rgba(99, 91, 255, 0.12);
}

.field-error {
    display: none;
    color: #dc2626;
    font-size: 0.82rem;
    font-weight: 700;
}

.form-row.has-error input,
.form-row.has-error textarea {
    border-color: #dc2626;
}

.form-row.has-error .field-error {
    display: block;
}

.submit-btn {
    width: fit-content;
    min-width: 156px;
    border: 0;
    cursor: pointer;
}

.submit-btn .btn-loader {
    display: none;
    width: 16px;
    height: 16px;
    margin-left: 0.6rem;
    border: 2px solid rgba(255, 255, 255, 0.45);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.submit-btn.is-loading .btn-loader {
    display: inline-block;
}

.submit-btn.is-success {
    background: linear-gradient(135deg, #16a34a, #22c55e);
}

.form-status {
    min-height: 1.4rem;
    color: var(--light-text);
    font-size: 0.9rem;
    font-weight: 700;
}

.site-footer {
    position: relative;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent),
        #070b16;
    color: rgba(255, 255, 255, 0.78);
    padding: clamp(2.5rem, 6vw, 4rem) 0 2rem;
    text-align: left;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.06);
    color: white;
    font-size: 1.6rem;
    font-weight: 900;
    text-decoration: none;
    animation: logoPulse 4s ease-in-out infinite;
}

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

.footer-content p {
    max-width: 560px;
    color: rgba(255, 255, 255, 0.76);
    font-size: clamp(1rem, 1.5vw, 1.16rem);
    font-weight: 700;
    letter-spacing: -0.035em;
}

.footer-actions {
    display: flex;
    gap: 0.65rem;
}

.footer-actions a {
    background: rgba(255, 255, 255, 0.06);
    color: white;
}

.footer-meta {
    margin-top: 1.25rem;
    color: rgba(255, 255, 255, 0.48);
    font-size: 0.9rem;
}

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

@keyframes meshFloat {
    to { transform: translate3d(4%, calc(var(--scroll-y, 0) + 3%), 0) scale(1.08); }
}

@keyframes logoPulse {
    0%, 100% { box-shadow: 0 0 0 rgba(99, 91, 255, 0); transform: translateY(0); }
    50% { box-shadow: 0 18px 50px rgba(99, 91, 255, 0.22); transform: translateY(-3px); }
}

:focus-visible {
    outline: 2px solid color-mix(in srgb, var(--primary-color), white 20%);
    outline-offset: 4px;
}

@media (max-width: 900px) {
    .contact-shell {
        grid-template-columns: 1fr;
    }

    .footer-content {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    body {
        overflow-x: hidden;
    }

    .contact-header,
    .projects-header,
    .cert-header,
    .experience-header {
        text-align: left;
    }

    .contact-header .section-title {
        margin-inline: 0;
        text-align: left;
    }

    .contact-header .section-title::after {
        left: 0;
        transform: none;
    }

    .submit-btn {
        width: 100%;
    }

    .cursor-glow {
        display: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
    }

    .cursor-glow,
    .mesh {
        display: none;
    }

    .motion-item,
    .about-reveal,
    .experience-reveal,
    .cert-reveal,
    .contact-reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}
