/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Mobile layout for Contact section */
@media (max-width: 640px) {
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 0.9rem;
    }

    .contact-card {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        padding: 0.9rem 1rem;
        border-radius: 16px;
    }

    .contact-icon {
        font-size: 1.8rem;
        margin: 0 0.75rem 0 0;
    }

    .contact-title {
        margin: 0;
        font-size: 1rem;
    }

    .contact-sub {
        display: none;
    }

    .contact-link {
        color: #a78bfa;
        font-weight: 700;
        text-decoration: none;
        margin-left: 0.75rem;
    }

    /* Hide QR card on mobile */
    .qr-card {
        display: none;
    }
}

/* Projects Grid */
.projects .projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 1.25rem;
}

@media (max-width: 768px) {
    .projects .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    }
}

.project-card {
    overflow: hidden;
    border-radius: 18px;
    background: var(--gradient-glass);
    border: 1px solid rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(28px) saturate(160%);
    transform-style: preserve-3d;
}

.project-card .project-image {
    position: relative;
    aspect-ratio: 16/9;
    overflow: hidden;
}

.project-card .project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transform: scale(1.02);
    transition: transform .4s ease, filter .4s ease;
}

.project-card:hover .project-image img {
    transform: scale(1.07);
    filter: saturate(1.05);
}

.project-open {
    position: absolute;
    inset: auto 12px 12px auto;
    z-index: 2;
    padding: .5rem .85rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, .18);
    background: rgba(10, 10, 16, .55);
    color: var(--text-primary);
    font-weight: 600;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: transform .2s ease, background .2s ease, border-color .2s ease;
}

.project-open:hover {
    transform: translateY(-2px);
    background: rgba(10, 10, 16, .7);
    border-color: rgba(0, 122, 255, .35);
}

.project-content {
    padding: 0.75rem 0.85rem 0.85rem;
}

.project-title {
    font-size: 1.1rem;
    margin-bottom: .35rem;
}

.project-desc {
    color: var(--text-secondary);
    font-size: .95rem;
    margin-bottom: .6rem;
}

.project-tech {
    display: none;
}

.tech-tag {
    font-size: .78rem;
    padding: .25rem .55rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
}

/* Project Viewer (Modal) */
.project-viewer {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.project-viewer.active {
    display: flex;
}

.project-viewer .viewer-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .6);
    backdrop-filter: blur(4px);
}

.viewer-dialog {
    position: relative;
    width: min(1000px, 92vw);
    max-height: 90vh;
    border-radius: 18px;
    overflow: hidden;
    padding: 0;
}

.viewer-close {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 2;
    background: rgba(20, 20, 28, .7);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, .18);
    border-radius: 10px;
    padding: .35rem .55rem;
    cursor: pointer;
}

.viewer-media {
    position: relative;
    background: #0b0b12;
    display: grid;
    place-items: center;
}

.viewer-image {
    max-width: 100%;
    max-height: 62vh;
    display: block;
    object-fit: contain;
}

.nav-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(20, 20, 28, .6);
    border: 1px solid rgba(255, 255, 255, .18);
    color: var(--text-primary);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    cursor: pointer;
    display: grid;
    place-items: center;
}

.nav-btn.prev {
    left: 10px;
}

.nav-btn.next {
    right: 10px;
}

.nav-btn:hover {
    background: rgba(20, 20, 28, .8);
}

.viewer-meta {
    padding: .9rem 1rem;
}

.viewer-title {
    font-size: 1.05rem;
    margin-bottom: .25rem;
}

.viewer-desc {
    color: var(--text-secondary);
    font-size: .95rem;
    margin-bottom: .5rem;
}

.viewer-tech {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}

.viewer-tech .tech-tag {
    background: rgba(255, 255, 255, .06);
}

.viewer-thumbs {
    display: grid;
    grid-auto-flow: column;
    gap: .5rem;
    overflow-x: auto;
    padding: .65rem 1rem 1rem;
}

.viewer-thumbs img {
    height: 60px;
    width: 100px;
    object-fit: cover;
    border-radius: 8px;
    opacity: .7;
    border: 1px solid rgba(255, 255, 255, .12);
    cursor: pointer;
}

.viewer-thumbs img.active {
    opacity: 1;
    outline: 2px solid rgba(0, 122, 255, .6);
}

@media (max-width: 640px) {
    .viewer-image {
        max-height: 50vh;
    }

    .nav-btn {
        width: 34px;
        height: 34px;
    }
}

/* Experience & Education */
.experience .timeline-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.timeline-col {
    position: relative;
    padding: 1.2rem 1.2rem 1.4rem;
    border-radius: 20px;
}

.timeline-header {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: .8rem;
}

.timeline-emoji {
    font-size: 1.1rem;
}

.timeline-title {
    font-size: 1.15rem;
}

.timeline {
    position: relative;
    margin-left: 1.25rem;
    padding-left: 1.25rem;
}

.timeline::before {
    content: '';
    position: absolute;
    left: 0.35rem;
    top: 0.2rem;
    bottom: 0.2rem;
    width: 2px;
    background: linear-gradient(180deg, rgba(0, 122, 255, .8), rgba(88, 86, 214, .6));
    box-shadow: 0 0 12px rgba(0, 122, 255, .35);
}

.timeline-item {
    position: relative;
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 16px;
    padding: .9rem 1rem;
    margin: 1rem 0 1.1rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12);
}

.timeline-item::before {
    content: '';
    position: absolute;
    left: -1.55rem;
    top: 1.1rem;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #0ea5e9;
    box-shadow: 0 0 0 4px rgba(14, 165, 233, .25), 0 0 18px rgba(14, 165, 233, .45);
}

.timeline-item .time {
    color: var(--text-secondary);
    font-size: .9rem;
    margin-bottom: .25rem;
}

.timeline-item .role {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: .2rem;
}

.timeline-item .place {
    color: var(--text-secondary);
    font-size: .92rem;
    margin-bottom: .5rem;
}

.timeline-item .chips {
    display: flex;
    flex-wrap: wrap;
    gap: .4rem;
}

.timeline-item .chips .chip {
    padding: .25rem .55rem;
    border-radius: 999px;
    font-size: .78rem;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
}

@media (max-width: 900px) {
    .experience .timeline-grid {
        grid-template-columns: 1fr;
    }
}

/* Certificates */
.certificates .container {
    max-width: 100%;
    padding-left: 1rem;
    padding-right: 1rem;
}

@media (min-width: 1100px) {
    .certificates .container {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
}

.projects .container {
    max-width: 100%;
    padding-left: 1rem;
    padding-right: 1rem;
}

@media (min-width: 1100px) {
    .projects .container {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }
}

.certificates .certs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.25rem;
}

/* 4 certificates per row on large screens */
@media (min-width: 1100px) {
    .certificates .certs-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.cert-card .cert-image img {
    display: block;
    width: 100%;
    height: auto;
}

.cert-track {
    color: #a78bfa;
    font-weight: 800;
    font-size: .78rem;
    letter-spacing: .04em;
    text-transform: uppercase;
    margin-bottom: .35rem;
}

.cert-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: .5rem;
}

.cert-year {
    color: var(--text-secondary);
    font-size: .9rem;
}

.cert-badge {
    font-size: .78rem;
    padding: .25rem .6rem;
    border-radius: 999px;
    background: rgba(16, 185, 129, .12);
    color: #22c55e;
    border: 1px solid rgba(16, 185, 129, .35);
}

/* Why Me */
.why .why-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: .9rem;
}

.why-card {
    text-align: center;
    padding: 1rem;
    border-radius: inherit;
    transition: transform .2s ease, border-color .2s ease;
}

.why-card:hover {
    transform: translateY(-3px);
    border-color: rgba(0, 122, 255, .28);
}

.why-icon {
    font-size: 1.4rem;
    margin-bottom: .45rem;
}

.why-title {
    font-size: .98rem;
    margin-bottom: .2rem;
}

.why-text {
    color: var(--text-secondary);
    font-size: .95rem;
}

@media (min-width: 1100px) {
    .why .why-grid {
        grid-template-columns: repeat(5, 1fr);
    }
}

/* New Skills Tiles */
/* Testimonials */
.testimonials .testi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.2rem;
}

.testi-card {
    padding: 1.2rem 1.3rem;
}

.testi-quote {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-primary);
    margin: 0 0 .6rem;
}

.testi-author {
    color: #a78bfa;
    font-weight: 700;
    text-decoration: none;
}

.testi-author:hover {
    text-decoration: underline;
}

.testi-featured {
    background: rgba(255, 255, 255, .06);
    border-color: rgba(255, 255, 255, .18);
}

/* Testimonials Carousel */
.carousel {
    position: relative;
}

.carousel-viewport {
    overflow: hidden;
    width: 100%;
}

.carousel-track {
    display: flex;
    transition: transform .45s ease;
    will-change: transform;
}

.carousel-track>.testi-card {
    flex: 0 0 100%;
    box-sizing: border-box;
}

.carousel-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .18);
    color: var(--text-primary);
    width: 36px;
    height: 36px;
    border-radius: 999px;
    display: grid;
    place-items: center;
    cursor: pointer;
    z-index: 2;
}

.carousel-arrow:hover {
    background: rgba(255, 255, 255, .14);
}

.carousel-arrow.prev {
    left: -6px;
}

.carousel-arrow.next {
    right: -6px;
}

.carousel-dots {
    display: flex;
    justify-content: center;
    gap: .4rem;
    margin-top: .8rem;
}

.carousel-dots button {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, .22);
    border: none;
    cursor: pointer;
    padding: 0;
}

.carousel-dots button.active {
    background: #a78bfa;
}

@media (min-width: 700px) {
    .carousel-arrow.prev {
        left: -12px;
    }

    .carousel-arrow.next {
        right: -12px;
    }
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
    align-items: stretch;
}

.contact-card {
    text-align: center;
    padding: 1.2rem;
}

.contact-icon {
    font-size: 2rem;
    margin-bottom: .5rem;
}

.contact-title {
    font-size: 1rem;
    margin: .25rem 0;
}

.contact-sub {
    color: var(--text-secondary);
    margin-bottom: .5rem;
}

.contact-link {
    color: #a78bfa;
    font-weight: 700;
    text-decoration: none;
}

.contact-link:hover {
    text-decoration: underline;
}

.qr-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 1.2rem;
}

.qr-image {
    width: 180px;
    max-width: 60%;
    height: auto;
    display: block;
}

.qr-caption {
    color: var(--text-secondary);
    margin-top: .6rem;
    text-align: center;
}

@media (min-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr 1fr 1.35fr;
        grid-auto-rows: 1fr;
        gap: 1.2rem;
    }

    .contact-grid .contact-card {
        min-height: 160px;
    }

    .contact-grid .contact-card:nth-of-type(1) {
        grid-column: 1;
        grid-row: 1;
    }

    .contact-grid .contact-card:nth-of-type(2) {
        grid-column: 2;
        grid-row: 1;
    }

    .contact-grid .contact-card:nth-of-type(3) {
        grid-column: 1;
        grid-row: 2;
    }

    .contact-grid .contact-card:nth-of-type(4) {
        grid-column: 2;
        grid-row: 2;
    }

    .contact-grid .qr-card {
        grid-column: 3;
        grid-row: 1 / span 2;
        padding: 1.6rem;
    }

    .qr-image {
        width: 220px;
        max-width: 70%;
    }
}

/* Reinforce mobile Contact layout at the end to win cascade */
@media (max-width: 640px) {
    .contact .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .contact .contact-grid {
        grid-template-columns: 1fr !important;
        gap: 0.9rem;
    }

    .contact .contact-card {
        display: grid;
        grid-template-columns: auto 1fr auto;
        grid-template-areas: 'icon title action';
        column-gap: 0.75rem;
        align-items: center;
        padding: 0.9rem 1rem;
        border-radius: 16px;
    }

    .contact .contact-icon {
        grid-area: icon;
        font-size: 1.8rem;
        margin: 0 0.25rem 0 0;
    }

    .contact .contact-title {
        grid-area: title;
        margin: 0;
        font-size: 1rem;
    }

    .contact .contact-sub {
        display: none !important;
    }

    .contact .contact-link {
        grid-area: action;
        justify-self: end;
        color: #a78bfa;
        font-weight: 700;
        text-decoration: none;
        margin: 0;
    }

    .contact .qr-card {
        display: none !important;
    }
}

.skills-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 0.8rem;
}

.skill-tile {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 0.6rem;
    padding: 0.6rem 0.75rem;
    border-radius: 12px;
    background: var(--gradient-glass);
    backdrop-filter: blur(22px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
    min-height: 44px;
}

.skill-tile:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 22px rgba(0, 0, 0, 0.28);
    border-color: rgba(0, 122, 255, 0.3);
}

.skill-logo {
    font-size: 2rem;
}

.skill-name {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.92rem;
    line-height: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* SVG badge sizing */
.skill-logo .logo-svg {
    width: 26px;
    height: 26px;
    display: block;
}

/* Tooltips for skills */
.skill-tile[data-tip] {
    position: relative;
}

/* Disable tooltips entirely */
.skill-tile[data-tip]::after,
.skill-tile[data-tip]::before {
    content: none !important;
}

.skill-tile:hover::after,
.skill-tile:focus-within::after,
.skill-tile:hover::before,
.skill-tile:focus-within::before {
    content: none !important;
}

@media (max-width: 520px) {
    .skills-tiles {
        grid-template-columns: repeat(2, 1fr);
    }

    .skill-logo .logo-svg {
        width: 24px;
        height: 24px;
    }

    .skill-name {
        font-size: 0.88rem;
    }
}

/* compact header spacing for skills */
.skills .section-header {
    margin-bottom: 1rem;
}

:root {
    --primary-color: #007AFF;
    --secondary-color: #5856D6;
    --accent-color: #FF9500;
    --background-dark: #000000;
    --background-secondary: #0A0A0A;
    --background-tertiary: #1A1A1A;
    --text-primary: #FFFFFF;
    --text-secondary: #EBEBF5;
    --text-tertiary: #EBEBF599;

    /* Enhanced Glass Variables */
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-bg-hover: rgba(255, 255, 255, 0.08);
    --glass-border: rgba(255, 255, 255, 0.1);
    --glass-border-hover: rgba(255, 255, 255, 0.2);
    --glass-highlight: rgba(255, 255, 255, 0.15);
    --glass-shadow: rgba(0, 0, 0, 0.25);
    --glass-inner-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1);
    --glass-outer-glow: 0 0 20px rgba(255, 255, 255, 0.05);

    --gradient-primary: linear-gradient(135deg, #007AFF, #5856D6);
    --gradient-secondary: linear-gradient(135deg, #FF9500, #FF6B35);
    --gradient-glass: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    --gradient-glass-border: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: radial-gradient(ellipse at center, #0A0A0A 0%, #000000 100%);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 20%, rgba(0, 122, 255, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(88, 86, 214, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(255, 149, 0, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: -1;
    animation: backgroundPulse 8s ease-in-out infinite;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 60% 30%, rgba(255, 59, 48, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 30% 70%, rgba(52, 199, 89, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 70% 70%, rgba(255, 204, 0, 0.06) 0%, transparent 40%);
    pointer-events: none;
    z-index: -1;
    animation: backgroundPulse 12s ease-in-out infinite reverse;
}

@keyframes backgroundPulse {

    0%,
    100% {
        opacity: 1;
        transform: scale(1) rotate(0deg);
    }

    50% {
        opacity: 0.7;
        transform: scale(1.1) rotate(2deg);
    }
}

/* Apple Liquid Glass Morphism Effect */
.glass-card {
    background: var(--gradient-glass);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: none;
    border-image: none;
    border-radius: 24px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 8px 32px var(--glass-shadow),
        var(--glass-inner-shadow),
        var(--glass-outer-glow);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--glass-highlight), transparent);
    opacity: 0.8;
    border-radius: inherit;
}

.glass-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.1), transparent 70%);
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.4s ease;
    border-radius: inherit;
}

/* Ensure media and overlays inside glass cards respect rounding */
.glass-card img,
.glass-card video,
.glass-card canvas,
.glass-card .overlay,
.glass-card .media,
.glass-card .cover,
.glass-card .thumb {
    border-radius: inherit;
}

.glass-card:hover {
    transform: translateY(-8px) scale(1.02);
    background: var(--glass-bg-hover);
    border-color: transparent;
    box-shadow:
        0 20px 60px var(--glass-shadow),
        0 0 0 1px rgba(255, 255, 255, 0.05),
        var(--glass-inner-shadow),
        0 0 40px rgba(255, 255, 255, 0.1);
}

.glass-card:hover::after {
    opacity: 1;
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Modern Tech Navigation */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(80px) saturate(200%);
    -webkit-backdrop-filter: blur(80px) saturate(200%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.1),
        0 8px 32px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.navbar.scrolled {
    background: rgba(0, 0, 0, 0.8);
    border-bottom-color: rgba(255, 255, 255, 0.15);
    box-shadow:
        0 1px 0 rgba(255, 255, 255, 0.15),
        0 12px 40px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0.75rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

/* 3D Logo with Cube */
.nav-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.nav-logo:hover {
    transform: scale(1.05);
}

.logo-icon {
    perspective: 1000px;
    width: 40px;
    height: 40px;
}

.logo-cube {
    position: relative;
    width: 100%;
    height: 100%;
    transform-style: preserve-3d;
    animation: rotateCube 8s linear infinite;
    transition: animation-play-state 0.3s ease;
}

.nav-logo:hover .logo-cube {
    animation-play-state: paused;
    transform: rotateX(45deg) rotateY(45deg);
}

.cube-face {
    position: absolute;
    width: 40px;
    height: 40px;
    border: 1px solid rgba(0, 122, 255, 0.3);
    background: var(--gradient-primary);
    opacity: 0.8;
}

.cube-face.front {
    transform: rotateY(0deg) translateZ(20px);
}

.cube-face.back {
    transform: rotateY(180deg) translateZ(20px);
}

.cube-face.right {
    transform: rotateY(90deg) translateZ(20px);
}

.cube-face.left {
    transform: rotateY(-90deg) translateZ(20px);
}

.cube-face.top {
    transform: rotateX(90deg) translateZ(20px);
}

.cube-face.bottom {
    transform: rotateX(-90deg) translateZ(20px);
}

@keyframes rotateCube {
    0% {
        transform: rotateX(0deg) rotateY(0deg);
    }

    100% {
        transform: rotateX(360deg) rotateY(360deg);
    }
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1;
}

.logo-main {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.logo-sub {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    font-weight: 400;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

/* Navigation Center */
.nav-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

/* Navigation Menu */
.nav-menu {
    display: flex;
    list-style: none;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    padding: 0.5rem;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 4px 16px rgba(0, 0, 0, 0.2);
}

.nav-item {
    position: relative;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.25rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.9rem;
    border-radius: 25px;
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 1;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0;
    border-radius: 25px;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.nav-link:hover::before,
.nav-link.active::before {
    opacity: 1;
}

.nav-link:hover,
.nav-link.active {
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.3);
}

.nav-icon {
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.nav-link:hover .nav-icon {
    transform: scale(1.2) rotate(10deg);
}

.nav-text {
    font-weight: 500;
    letter-spacing: 0.02em;
}

.nav-indicator {
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--gradient-secondary);
    border-radius: 1px;
    transform: translateX(-50%);
    transition: width 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.nav-link.active .nav-indicator {
    width: 80%;
}

/* Navigation Actions */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.theme-toggle,
.lang-toggle {
    width: 40px;
    height: 40px;
    border: none;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
}

.theme-toggle::before,
.lang-toggle::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 50%;
}

.theme-toggle:hover::before,
.lang-toggle:hover::before {
    opacity: 0.2;
}

.theme-toggle:hover,
.lang-toggle:hover {
    transform: translateY(-2px) scale(1.05);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.2);
    color: var(--text-primary);
}

.theme-icon {
    position: relative;
    width: 18px;
    height: 18px;
}

.sun-icon,
.moon-icon {
    position: absolute;
    top: 0;
    left: 0;
    transition: all 0.3s ease;
}

.moon-icon {
    opacity: 0;
    transform: rotate(180deg);
}

.theme-toggle.dark .sun-icon {
    opacity: 0;
    transform: rotate(-180deg);
}

.theme-toggle.dark .moon-icon {
    opacity: 1;
    transform: rotate(0deg);
}

.lang-text {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.05em;
}

.nav-social {
    display: flex;
    gap: 0.5rem;
}

.social-link {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    position: relative;
    overflow: hidden;
}

.social-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 50%;
}

.social-link:hover::before {
    opacity: 1;
}

.social-link:hover {
    transform: translateY(-2px) scale(1.1);
    color: white;
    border-color: transparent;
    box-shadow: 0 8px 25px rgba(0, 122, 255, 0.3);
}

/* Modern Hamburger */
.hamburger {
    display: none;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    cursor: pointer;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.hamburger:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: scale(1.05);
}

.hamburger-box {
    width: 20px;
    height: 16px;
    position: relative;
}

.hamburger-inner {
    position: absolute;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 1px;
    top: 50%;
    transform: translateY(-50%);
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.hamburger-inner::before,
.hamburger-inner::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 1px;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.hamburger-inner::before {
    top: -6px;
}

.hamburger-inner::after {
    bottom: -6px;
}

.hamburger.active .hamburger-inner {
    background: transparent;
}

.hamburger.active .hamburger-inner::before {
    transform: rotate(45deg);
    top: 0;
}

.hamburger.active .hamburger-inner::after {
    transform: rotate(-45deg);
    bottom: 0;
}

/* End of file tweaks */
@media (min-width: 1100px) {
  /* Force wider, centered testimonials layout */
  .testimonials .container {
    max-width: 100% !important;
    width: 100% !important;
  }
  .testimonials .testi-grid {
    display: grid !important;
    grid-template-columns: repeat(2, 620px) !important;
    gap: 2rem !important;
    justify-content: center !important;
    align-content: start !important;
    max-width: calc(620px * 2 + 2rem) !important;
    margin-inline: auto !important;
  }
}

/* Projects: ensure desktop images are not shifted by generic .project-image flex styles */
@media (min-width: 1024px) {
  .project-card .project-image {
    display: block !important;
    height: auto !important;
    aspect-ratio: 16/9 !important;
    justify-content: initial !important;
    align-items: initial !important;
  }
  .project-card .project-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    margin: 0;
  }
}

/* Projects: visual design per reference */
/* Grid: 3 columns desktop, 2 tablet, 1 mobile */
@media (min-width: 1100px) {
  .projects .projects-grid {
    grid-template-columns: repeat(3, minmax(320px, 1fr));
    gap: 2rem;
    align-items: stretch;
  }
}
@media (min-width: 768px) and (max-width: 1099.98px) {
  .projects .projects-grid {
    grid-template-columns: repeat(2, minmax(320px, 1fr));
    gap: 1.75rem;
    align-items: stretch;
  }
}

/* Card tuning: radius and layout */
.project-card {
  border-radius: 22px;
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* Footer area (content) with subtle purple/dark gradient */
.project-content {
  margin-top: 0;
  background: linear-gradient(180deg, rgba(26, 18, 38, 0.65) 0%, rgba(26, 18, 38, 0.92) 100%);
  padding: 1rem 1rem 1.1rem;
}

.project-title {
  margin: 0 0 .6rem 0;
}

/* Hide description to match design (title + chips) */
.project-desc {
  display: none;
}

/* Tech chips */
.project-tech {
  display: flex !important;
  flex-wrap: wrap;
  gap: .5rem;
}

.tech-tag {
  display: inline-block;
  padding: .4rem .75rem;
  border-radius: 999px;
  font-size: .85rem;
  line-height: 1;
  color: var(--text-primary);
  background: rgba(88, 86, 214, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}


/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.mobile-menu.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100%;
    padding: 2rem;
    gap: 3rem;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    text-align: center;
}

.mobile-nav-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 1rem 2rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 1.2rem;
    font-weight: 500;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    transition: all 0.3s ease;
    min-width: 200px;
    transform: translateY(30px);
    opacity: 0;
    animation: mobileSlideIn 0.6s ease forwards;
}

.mobile-nav-link:nth-child(1) {
    animation-delay: 0.1s;
}

.mobile-nav-link:nth-child(2) {
    animation-delay: 0.2s;
}

.mobile-nav-link:nth-child(3) {
    animation-delay: 0.3s;
}

.mobile-nav-link:nth-child(4) {
    animation-delay: 0.4s;
}

.mobile-nav-link:nth-child(5) {
    animation-delay: 0.5s;
}

@keyframes mobileSlideIn {
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.mobile-nav-link:hover {
    background: var(--gradient-primary);
    color: white;
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 10px 30px rgba(0, 122, 255, 0.3);
}

.mobile-icon {
    font-size: 1.2rem;
}

.mobile-social {
    display: flex;
    gap: 2rem;
}

.mobile-social-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 25px;
    transition: all 0.3s ease;
}

.mobile-social-link:hover {
    background: var(--gradient-primary);
    color: white;
    border-color: transparent;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

/* Make hero full-width */
.hero>.container {
    max-width: none;
    width: 100%;
    padding-left: 0;
    padding-right: 0;
}

/* Subtle dim to calm global background orbs under hero */
.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background:
        radial-gradient(80% 60% at 10% 20%, rgba(147, 51, 234, .20), transparent 60%),
        radial-gradient(70% 50% at 85% 30%, rgba(59, 130, 246, .20), transparent 60%),
        linear-gradient(180deg, rgba(255, 255, 255, .04), rgba(255, 255, 255, 0));
    pointer-events: none;
    z-index: 0;
}

/* New Hero layout */
.hero-wrap {
    padding: clamp(28px, 5vw, 48px) clamp(16px, 4vw, 32px);
    border-radius: 0;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

/* decorative overlay inside hero card */
.hero-wrap::before {
    content: none;
}

.hero-inner {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1.5fr .9fr;
    align-items: start;
    gap: clamp(28px, 4.5vw, 56px);
    min-height: 80vh;
}

.hero-content.hero-card {
    padding: clamp(20px, 3.6vw, 36px);
    border-radius: 24px;
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.03));
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 18px 50px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(14px);
    width: 100%;
    max-width: none;
    position: relative;
    align-self: start;
    display: block;
    text-align: left;
}

.hero-content.hero-card.glass-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 24px;
    padding: 1.5px;
    background: linear-gradient(135deg, rgba(168, 85, 247, .7), rgba(96, 165, 250, .45));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.hero-content.hero-card.glass-card::after {
    content: "";
    position: absolute;
    inset: -1px;
    border-radius: 24px;
    background: radial-gradient(80% 40% at 10% 0%, rgba(255, 255, 255, .12), transparent 60%);
    pointer-events: none;
}

.hero-content.hero-card.glass-card {
    transform: translateY(8px);
    opacity: 0;
}

.hero-content.hero-card.glass-card.animate-on-scroll.animate {
    margin-top: 10%;
    transform: translateY(0);
    opacity: 1;
    transition: transform .5s ease, opacity .5s ease, box-shadow .3s ease;
}

.hero-content.hero-card .hero-title {
    margin-bottom: .2rem;
}

.hero-content.hero-card .hero-desc {
    margin: 0 0 .9rem;
}

.hero-content.hero-card .hero-badges {
    margin-bottom: 1rem;
    justify-content: flex-start;
}

.hero-content.hero-card .hero-actions {
    margin-top: .2rem;
    justify-content: flex-start;
}

.hero-content .hero-title {
    font-size: clamp(2.4rem, 5vw, 3.6rem);
    line-height: 1.12;
    margin: 0 0 .4rem;
    letter-spacing: -0.01em;
    font-weight: 800;
}

.hero-content .title-line {
    display: block;
}

.hero-content .title-line {
    opacity: 0;
    transform: translateY(8px);
}

.hero-content .title-line:nth-child(1) {
    animation: heroFadeUp .6s ease .05s forwards;
}

.hero-content .title-line .accent {
    background: linear-gradient(135deg, #f0abfc, #a78bfa, #60a5fa);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    font-weight: 800;
    animation: heroFadeUp .6s ease .18s forwards, heroHueShift 7s ease-in-out .18s infinite alternate;
}

.hero-subtitle {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: .75rem;
}

.hero-badges {
    display: flex;
    flex-wrap: wrap;
    gap: .55rem .6rem;
    margin-bottom: 1rem;
}

.hero-badges .badge {
    font-size: .92rem;
    padding: .46rem .8rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .07);
    border: 1px solid rgba(255, 255, 255, .16);
    box-shadow: 0 4px 14px rgba(0, 0, 0, .15);
}

.hero-badges .badge.icon {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
}

.hero-badges .badge.icon img {
    width: 18px;
    height: 18px;
    display: block;
}

.hero-cta {
    display: flex;
    gap: .7rem;
}

/* New content blocks */
.hero-overline {
    font-size: .9rem;
    letter-spacing: .12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .7);
    margin-bottom: .6rem;
}

.hero-desc {
    color: var(--text-secondary);
    font-size: clamp(1.02rem, 1.15vw, 1.15rem);
    line-height: 1.8;
    margin: 0 0 1.1rem;
    max-width: 60ch;
}

.hero-actions {
    display: flex;
    align-items: center;
    gap: .8rem 1rem;
    flex-wrap: wrap;
    margin-bottom: 1rem;
}

.hero-actions .hint {
    color: rgba(255, 255, 255, .7);
    font-size: .9rem;
}

.hero-stats {
    display: flex;
    gap: 1.2rem;
    flex-wrap: wrap;
    margin: .2rem 0 1rem;
}

.hero-stats .stat {
    display: grid;
    grid-auto-flow: column;
    align-items: baseline;
    gap: .35rem;
    padding: .4rem .65rem;
    border-radius: 12px;
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .08);
}

.hero-stats .stat strong {
    font-size: 1.1rem;
    color: #fff;
}

.hero-stats .stat span {
    color: var(--text-secondary);
    font-size: .95rem;
}

.hero-socials {
    display: flex;
    gap: .6rem;
    align-items: center;
}

.hero-socials a {
    display: inline-flex;
    width: 36px;
    height: 36px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
    transition: transform .2s ease, background .2s ease;
}

.hero-socials a:hover {
    transform: translateY(-2px);
    background: rgba(167, 139, 250, .18);
    border-color: rgba(167, 139, 250, .35);
}

.hero-socials img {
    width: 18px;
    height: 18px;
    display: block;
}

.hero-media {
    display: grid;
    place-items: center;
}

.hero-photo-wrap {
    position: relative;
}

.hero-photo {
    display: block;
    width: min(480px, 40vw);
    height: auto;
    object-fit: contain;
    border-radius: 16px;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, .45));
    transition: transform .25s ease;
}

.hero-photo-wrap:hover .hero-photo {
    transform: translateY(-4px);
}

.hero-glow {
    position: absolute;
    left: 50%;
    bottom: -18px;
    transform: translateX(-50%);
    width: 82%;
    height: 28px;
    background: radial-gradient(50% 100% at 50% 0%, rgba(168, 85, 247, .75), rgba(168, 85, 247, 0));
    filter: blur(16px);
    opacity: .95;
    border-radius: 999px;
}

@media (max-width: 900px) {
    .hero {
        padding-top: 3rem;
    }

    .hero-wrap {
        padding: 1.2rem 0;
        border-radius: 0;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 1rem;
        min-height: unset;
    }

    .hero-media {
        order: -1;
    }

    .hero-photo {
        width: min(320px, 70vw);
    }

    .hero-actions {
        gap: .7rem;
    }

    .hero-stats {
        gap: .7rem;
    }

    .hero-content.hero-card {
        padding: 1rem .9rem;
        border-radius: 16px;
        max-width: none;
    }
}

/* Animations */
@keyframes heroFadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes heroHueShift {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 100% 50%;
    }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {

    .hero-content .title-line,
    .hero-content .title-line .accent {
        animation: none !important;
        opacity: 1;
        transform: none;
    }
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

/* Animated Background Particles */
.animated-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -2;
    overflow: hidden;
}

.particle {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0.6;
    animation: particleFloat 15s linear infinite;
}

.particle-1 {
    width: 4px;
    height: 4px;
    background: rgba(0, 122, 255, 0.8);
    left: 10%;
    animation-delay: 0s;
    animation-duration: 20s;
}

.particle-2 {
    width: 6px;
    height: 6px;
    background: rgba(88, 86, 214, 0.6);
    left: 20%;
    animation-delay: 2s;
    animation-duration: 25s;
}

.particle-3 {
    width: 3px;
    height: 3px;
    background: rgba(255, 149, 0, 0.7);
    left: 30%;
    animation-delay: 4s;
    animation-duration: 18s;
}

.particle-4 {
    width: 5px;
    height: 5px;
    background: rgba(255, 59, 48, 0.5);
    left: 40%;
    animation-delay: 6s;
    animation-duration: 22s;
}

.particle-5 {
    width: 4px;
    height: 4px;
    background: rgba(52, 199, 89, 0.6);
    left: 50%;
    animation-delay: 8s;
    animation-duration: 19s;
}

.particle-6 {
    width: 7px;
    height: 7px;
    background: rgba(255, 204, 0, 0.4);
    left: 60%;
    animation-delay: 10s;
    animation-duration: 24s;
}

.particle-7 {
    width: 3px;
    height: 3px;
    background: rgba(0, 122, 255, 0.7);
    left: 70%;
    animation-delay: 12s;
    animation-duration: 21s;
}

.particle-8 {
    width: 5px;
    height: 5px;
    background: rgba(88, 86, 214, 0.5);
    left: 80%;
    animation-delay: 14s;
    animation-duration: 17s;
}

.particle-9 {
    width: 4px;
    height: 4px;
    background: rgba(255, 149, 0, 0.6);
    left: 90%;
    animation-delay: 16s;
    animation-duration: 23s;
}

.particle-10 {
    width: 6px;
    height: 6px;
    background: rgba(255, 59, 48, 0.4);
    left: 15%;
    animation-delay: 18s;
    animation-duration: 26s;
}

@keyframes particleFloat {
    0% {
        transform: translateY(100vh) translateX(0) rotate(0deg);
        opacity: 0;
    }

    10% {
        opacity: 0.6;
    }

    90% {
        opacity: 0.6;
    }

    100% {
        transform: translateY(-100px) translateX(100px) rotate(360deg);
        opacity: 0;
    }
}

/* Animated Gradient Orbs */
.gradient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    pointer-events: none;
    animation: orbFloat 20s ease-in-out infinite;
}

.orb-1 {
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(0, 122, 255, 0.3), transparent);
    top: 10%;
    left: 5%;
    animation-delay: 0s;
}

.orb-2 {
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(88, 86, 214, 0.25), transparent);
    top: 60%;
    right: 10%;
    animation-delay: 7s;
}

.orb-3 {
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(255, 149, 0, 0.2), transparent);
    bottom: 20%;
    left: 30%;
    animation-delay: 14s;
}

@keyframes orbFloat {

    0%,
    100% {
        transform: translate(0, 0) scale(1);
        opacity: 0.3;
    }

    33% {
        transform: translate(50px, -30px) scale(1.1);
        opacity: 0.5;
    }

    66% {
        transform: translate(-30px, 50px) scale(0.9);
        opacity: 0.4;
    }
}

.shape {
    position: absolute;
    border-radius: 50%;
    background: var(--gradient-primary);
    opacity: 0.15;
    animation: float 8s ease-in-out infinite;
    filter: blur(1px);
}

.shape-1 {
    width: 300px;
    height: 300px;
    top: 20%;
    left: 10%;
    animation-delay: 0s;
    background: linear-gradient(45deg, rgba(0, 122, 255, 0.2), rgba(88, 86, 214, 0.2));
}

.shape-2 {
    width: 200px;
    height: 200px;
    top: 60%;
    right: 15%;
    animation-delay: 2s;
    background: linear-gradient(135deg, rgba(255, 149, 0, 0.2), rgba(255, 59, 48, 0.2));
}

.shape-3 {
    width: 150px;
    height: 150px;
    bottom: 20%;
    left: 60%;
    animation-delay: 4s;
    background: linear-gradient(225deg, rgba(52, 199, 89, 0.2), rgba(255, 204, 0, 0.2));
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px) rotate(0deg) scale(1);
        opacity: 0.15;
    }

    25% {
        transform: translateY(-30px) rotate(90deg) scale(1.1);
        opacity: 0.25;
    }

    50% {
        transform: translateY(-20px) rotate(180deg) scale(0.9);
        opacity: 0.2;
    }

    75% {
        transform: translateY(-40px) rotate(270deg) scale(1.05);
        opacity: 0.18;
    }
}

/* Animated Lines */
.animated-lines {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.line {
    position: absolute;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: lineMove 15s linear infinite;
}

.line-1 {
    top: 20%;
    width: 200px;
    animation-delay: 0s;
}

.line-2 {
    top: 40%;
    width: 150px;
    animation-delay: 5s;
}

.line-3 {
    top: 60%;
    width: 180px;
    animation-delay: 10s;
}

.line-4 {
    top: 80%;
    width: 120px;
    animation-delay: 3s;
}

@keyframes lineMove {
    0% {
        left: -200px;
        opacity: 0;
    }

    50% {
        opacity: 1;
    }

    100% {
        left: 100%;
        opacity: 0;
    }
}

.hero-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Hero-specific override: stack text vertically on the left column */
.hero .hero-content {
    display: block !important;
    grid-template-columns: unset;
    gap: 0;
    text-align: left;
    max-width: none;
    margin: 0;
}

.hero .hero-content .hero-badges,
.hero .hero-content .hero-actions {
    justify-content: flex-start;
}

.hero-title {
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.title-line {
    display: block;
    opacity: 0;
    transform: translateY(50px);
    animation: slideUp 1s ease forwards;
}

.title-line:nth-child(2) {
    animation-delay: 0.2s;
}

.gradient-text {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes slideUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    opacity: 0;
    animation: fadeIn 1s ease forwards 0.6s;
}

@keyframes fadeIn {
    to {
        opacity: 1;
    }
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    opacity: 0;
    animation: fadeIn 1s ease forwards 0.8s;
}

.btn {
    padding: 1rem 2rem;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 10px 30px rgba(0, 122, 255, 0.3);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(0, 122, 255, 0.4);
}

.btn-secondary {
    background: var(--gradient-glass);
    color: var(--text-primary);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(30px) saturate(180%);
    -webkit-backdrop-filter: blur(30px) saturate(180%);
    position: relative;
    overflow: hidden;
    box-shadow:
        0 4px 16px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.btn-secondary:hover::before {
    left: 100%;
}

.btn-secondary:hover {
    background: var(--glass-bg-hover);
    border-color: var(--glass-border-hover);
    transform: translateY(-3px);
    box-shadow:
        0 8px 24px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 20px rgba(255, 255, 255, 0.05);
}

.hero-image {
    display: flex;
    justify-content: center;
    opacity: 0;
    animation: fadeIn 1s ease forwards 1s;
}

.profile-card {
    background: var(--gradient-glass);
    backdrop-filter: blur(50px) saturate(200%);
    -webkit-backdrop-filter: blur(50px) saturate(200%);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    transform: perspective(1000px) rotateY(-15deg);
    transition: all 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.profile-card::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: conic-gradient(from 0deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: rotate 8s linear infinite;
    opacity: 0.3;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.profile-card:hover {
    transform: perspective(1000px) rotateY(0deg);
}

.profile-avatar {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.avatar-placeholder {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: var(--background-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
}

.avatar-placeholder::before {
    content: '👨‍💻';
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    animation: fadeIn 1s ease forwards 1.5s;
}

.scroll-arrow {
    width: 30px;
    height: 30px;
    border-right: 2px solid var(--text-secondary);
    border-bottom: 2px solid var(--text-secondary);
    transform: rotate(45deg);
    animation: bounce 2s infinite;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: rotate(45deg) translateY(0);
    }

    40% {
        transform: rotate(45deg) translateY(-10px);
    }

    60% {
        transform: rotate(45deg) translateY(-5px);
    }
}

/* Section Styles */
section {
    padding: 6rem 0;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    margin-bottom: 1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto;
}

/* About Section */
.about {
    background: linear-gradient(135deg, var(--background-dark) 0%, var(--background-secondary) 100%);
}

.about-text h3 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.about-text p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    color: var(--text-tertiary);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* New About Grid & Cards */
.about-grid {
    display: grid;
    grid-template-columns: minmax(280px, 380px) 1fr;
    gap: 2rem;
}

.about-profile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 2.25rem;
}

.profile-name {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 1.25rem;
}

.profile-role {
    margin-top: 0.35rem;
    font-weight: 600;
}

.profile-location {
    margin-top: 0.5rem;
    color: var(--text-tertiary);
    font-size: 0.95rem;
}

.profile-metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    width: 100%;
    margin-top: 1.5rem;
}

.metric {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.metric:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.metric-value {
    display: block;
    font-size: 1.6rem;
    font-weight: 800;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.metric-label {
    display: block;
    margin-top: 0.25rem;
    color: var(--text-tertiary);
    font-size: 0.8rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.profile-actions {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.75rem;
    width: 100%;
    margin-top: 1.5rem;
}

.action-btn {
    height: 44px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.06);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.action-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 0;
    pointer-events: none;
}

.action-btn:hover {
    transform: translateY(-2px) scale(1.03);
    color: #fff;
    box-shadow: 0 12px 30px rgba(0, 122, 255, 0.25);
    border-color: transparent;
}

.action-btn:hover::before {
    opacity: 1;
}

/* Ensure icon stays above the gradient overlay */
.action-btn svg {
    position: relative;
    z-index: 1;
    display: block;
}

.about-right {
    display: grid;
    gap: 1.5rem;
}

.card-badge {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.25), rgba(255, 255, 255, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
    margin-bottom: 1rem;
}

.card-title {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
}

.card-text {
    color: var(--text-secondary);
}

.principles-list {
    display: grid;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

.principle-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.principle-icon {
    font-size: 1.1rem;
}

.principle-text {
    color: var(--text-secondary);
}

/* Responsive */
@media (max-width: 920px) {
    .about-grid {
        grid-template-columns: 1fr;
    }

    .profile-metrics {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 520px) {
    .profile-metrics {
        grid-template-columns: 1fr 1fr;
    }

    .profile-actions {
        grid-template-columns: 1fr 1fr;
    }
}

/* Full-width CTA under About */
.about-cta-full {
    width: 100vw;
    margin-left: calc(50% - 50vw);
    margin-right: calc(50% - 50vw);
    margin-top: 2rem;
    position: relative;
    isolation: isolate;
    /* keep glow under content */
}

.about-cta-full .cta-card {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2.25rem;
    border-radius: 24px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.03));
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* Full-bleed soft edge glow */
.about-cta-full::before,
.about-cta-full::after {
    content: '';
    position: absolute;
    inset: -10% 0 -10% 0;
    /* extend a bit beyond */
    background:
        radial-gradient(1200px 200px at 10% 50%, rgba(120, 0, 255, 0.18), transparent 70%),
        radial-gradient(1200px 200px at 90% 50%, rgba(0, 122, 255, 0.18), transparent 70%);
    filter: blur(20px);
    z-index: -1;
    pointer-events: none;
}

.about-cta-full::after {
    inset: -20% 0 -20% 0;
    opacity: 0.5;
}

.cta-status {
    color: #9BE180;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #30D158;
    box-shadow: 0 0 10px rgba(48, 209, 88, 0.6);
}

.cta-title {
    font-size: clamp(1.6rem, 3.5vw, 2.2rem);
    margin-bottom: 0.5rem;
}

.cta-subtitle {
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
}

.cta-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.chip {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 0.9rem;
    border-radius: 999px;
    background: radial-gradient(circle at 30% 30%, rgba(120, 0, 255, 0.35), rgba(80, 0, 120, 0.25));
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: var(--text-primary);
    font-weight: 500;
    transition: all 0.5s ease;
    opacity: 0;
    transform: translateY(6px);
}

.cta-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.cta-button {
    padding-inline: 1.5rem;
}

/* Scroll reveal enhancements for CTA */
.about-cta-full .cta-card.animate-on-scroll {
    opacity: 0;
    transform: translateY(16px) scale(0.985);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.about-cta-full .cta-card.animate-on-scroll.animate {
    opacity: 1;
    transform: none;
}

.about-cta-full .cta-card.animate-on-scroll.animate .chip {
    opacity: 1;
    transform: none;
}

.about-cta-full .cta-card.animate-on-scroll.animate .chip:nth-child(1) {
    transition-delay: 0.05s;
}

.about-cta-full .cta-card.animate-on-scroll.animate .chip:nth-child(2) {
    transition-delay: 0.12s;
}

.about-cta-full .cta-card.animate-on-scroll.animate .chip:nth-child(3) {
    transition-delay: 0.19s;
}

@media (max-width: 640px) {
    .about-cta-full .cta-card {
        padding: 1.5rem;
        border-radius: 20px;
    }
}

/* Skills Section */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.skill-category {
    background: var(--gradient-glass);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.skill-category::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    transition: left 0.6s ease;
}

.skill-category:hover::before {
    left: 100%;
}

.skill-category:hover {
    transform: translateY(-10px);
}

.skill-category h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

.skill-items {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.skill-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background: var(--gradient-glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    position: relative;
    overflow: hidden;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
    transition: all 0.3s ease;
}

.skill-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center, rgba(255, 255, 255, 0.1), transparent 70%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.skill-item:hover::before {
    opacity: 1;
}

.skill-item:hover {
    background: var(--glass-bg-hover);
    border-color: rgba(255, 255, 255, 0.1);
    transform: scale(1.05) translateY(-2px);
    box-shadow:
        0 8px 16px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 20px rgba(255, 255, 255, 0.08);
}

.skill-icon {
    font-size: 1.5rem;
}

/* Projects Section */
.projects {
    background: var(--background-secondary);
}

/* Certificates and Testimonials Sections - same dark background */
.certificates {
    background: var(--background-secondary);
}

.testimonials {
    background: var(--background-secondary);
}

/* Testimonials Grid (no carousel) */
.testimonials .container {
    padding-inline: 1rem;
    max-width: 100%;
    width: 100%;
}

.testi-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.25rem;
    justify-content: center;
    margin-inline: auto;
    justify-items: stretch;
}

.testi-card {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: 1.25rem 1.5rem;
}

.testi-quote {
    margin: 0;
    color: var(--text-primary);
    line-height: 1.6;
    font-size: 0.98rem;
}

.testi-author {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 600;
}

.testi-card.testi-featured {
    border: 1px solid var(--primary-color);
    box-shadow: 0 10px 30px rgba(0, 122, 255, 0.15);
}

@media (min-width: 1100px) {
    .testi-grid {
        grid-template-columns: repeat(2, 620px);
        gap: 2rem;
        justify-content: center;
        max-width: calc(620px * 2 + 2rem);
        margin-inline: auto;
    }
    .testimonials .container {
        padding-inline: 1.5rem;
        max-width: 1500px;
    }
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
}

.project-card {
    background: var(--gradient-glass);
    backdrop-filter: blur(40px) saturate(180%);
    -webkit-backdrop-filter: blur(40px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.25),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.4s ease;
}

.project-card:hover::before {
    opacity: 1;
}

.project-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.project-image {
    height: 200px;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.project-placeholder {
    font-size: 4rem;
    opacity: 0.8;
}

.project-content {
    padding: 2rem;
}

.project-content h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.project-content p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
}

.project-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.tech-tag {
    padding: 0.25rem 0.75rem;
    background: rgba(0, 122, 255, 0.2);
    color: var(--primary-color);
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.project-links {
    display: flex;
    gap: 1rem;
}

.project-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.project-link:hover {
    color: var(--text-primary);
}

/* Contact Section */
.contact-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
}

.contact-info h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.contact-info p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.contact-methods {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.contact-method {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--gradient-glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    text-decoration: none;
    color: var(--text-secondary);
    position: relative;
    overflow: hidden;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

.contact-method::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    transition: left 0.5s ease;
}

.contact-method:hover::before {
    left: 100%;
}

.contact-method:hover {
    background: var(--glass-bg-hover);
    border-color: var(--glass-border-hover);
    color: var(--text-primary);
    transform: translateX(10px) translateY(-2px);
    box-shadow:
        0 8px 24px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 20px rgba(255, 255, 255, 0.05);
}

.method-icon {
    font-size: 1.5rem;
}

.contact-form {
    position: sticky;
    top: 2rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: var(--gradient-glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    color: var(--text-primary);
    font-family: inherit;
    position: relative;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: var(--glass-bg-hover);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.15),
        0 0 0 3px rgba(0, 122, 255, 0.1),
        0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-tertiary);
}

/* Footer */
.footer {
    background: var(--background-dark);
    padding: 2rem 0;
    border-top: 1px solid var(--glass-border);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-tertiary);
}

.footer-links {
    display: flex;
    gap: 2rem;
}

.footer-links a {
    color: var(--text-tertiary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #fff;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        display: none;
    }

    .hamburger {
        display: flex;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .stats {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .skills-grid {
        grid-template-columns: 1fr;
    }

    .skill-items {
        grid-template-columns: 1fr;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* Floating Elements */
.floating-element {
    position: absolute;
    pointer-events: none;
    opacity: 0.1;
    animation: elementFloat 12s ease-in-out infinite;
}

.floating-element-1 {
    top: 15%;
    left: 85%;
    width: 20px;
    height: 20px;
    background: rgba(0, 122, 255, 0.3);
    border-radius: 50%;
    animation-delay: 0s;
}

.floating-element-2 {
    top: 45%;
    left: 5%;
    width: 15px;
    height: 15px;
    background: rgba(255, 149, 0, 0.3);
    border-radius: 50%;
    animation-delay: 4s;
}

.floating-element-3 {
    top: 75%;
    left: 90%;
    width: 25px;
    height: 25px;
    background: rgba(88, 86, 214, 0.3);
    border-radius: 50%;
    animation-delay: 8s;
}

@keyframes elementFloat {

    0%,
    100% {
        transform: translateY(0) translateX(0) rotate(0deg);
        opacity: 0.1;
    }

    25% {
        transform: translateY(-20px) translateX(10px) rotate(90deg);
        opacity: 0.3;
    }

    50% {
        transform: translateY(-10px) translateX(-15px) rotate(180deg);
        opacity: 0.2;
    }

    75% {
        transform: translateY(-30px) translateX(5px) rotate(270deg);
        opacity: 0.25;
    }
}

/* Scroll Animations */
@keyframes slideInFromLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInFromRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInFromBottom {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-on-scroll {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, transform;
}

.animate-on-scroll.animate {
    opacity: 1;
    transform: none;
}

/* Variants */
.animate-on-scroll[data-anim="fade-up"] {
    transform: translateY(18px);
}

.animate-on-scroll[data-anim="fade-left"] {
    transform: translateX(24px);
}

.animate-on-scroll[data-anim="fade-right"] {
    transform: translateX(-24px);
}

.animate-on-scroll[data-anim="zoom-in"] {
    transform: scale(0.96);
}

.animate-on-scroll.animate[data-anim] {
    transform: none;
}

/* Staggered children default transition */
[data-stagger]>.animate-on-scroll {
    transition-delay: 0s;
}

@media (prefers-reduced-motion: reduce) {

    .animate-on-scroll,
    .animate-on-scroll.animate {
        transition: none !important;
        transform: none !important;
        opacity: 1 !important;
    }
}

/* Mesh Gradient Animation */
.mesh-gradient {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -3;
    background:
        radial-gradient(ellipse 80% 80% at 50% -20%, rgba(0, 122, 255, 0.05), transparent),
        radial-gradient(ellipse 80% 80% at 80% 120%, rgba(88, 86, 214, 0.05), transparent),
        radial-gradient(ellipse 80% 80% at 20% 120%, rgba(255, 149, 0, 0.03), transparent);
    animation: meshMove 30s ease-in-out infinite;
}

@keyframes meshMove {

    0%,
    100% {
        transform: scale(1) rotate(0deg);
        opacity: 1;
    }

    33% {
        transform: scale(1.1) rotate(1deg);
        opacity: 0.8;
    }

    66% {
        transform: scale(0.95) rotate(-1deg);
        opacity: 0.9;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background-dark);
}

::-webkit-scrollbar-thumb {
    background: var(--glass-border);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Performance Optimizations */
.floating-shapes,
.animated-bg,
.gradient-orb,
.particle,
.mesh-gradient {
    will-change: transform, opacity;
    backface-visibility: hidden;
    perspective: 1000px;
}

/* Mobile-only darker background without affecting desktop */
@media (max-width: 768px) {
    /* Remove colorful animated layers to keep background dark */
    .mesh-gradient,
    .animated-bg,
    .gradient-orb,
    .particle,
    .floating-element { display: none !important; }

    /* Tone down global glow overlays */
    body::before,
    body::after { opacity: 0.15 !important; }

    /* Make navbar solid/darker for readability */
    .navbar { background: rgba(0, 0, 0, 0.88) !important; }

    /* Set a solid dark background on html/body */
    html, body { background: #0b0b12 !important; }

    /* Ensure hero has a real dark overlay */
    .hero { position: relative; }
    .hero::before { 
        content: "";
        position: absolute; 
        inset: 0; 
        background: rgba(0, 0, 0, 0.5) !important; 
        pointer-events: none;
    }

    /* Darken mobile menu surfaces */
    .mobile-menu, 
    .mobile-menu-content { background: rgba(10, 10, 14, 0.96) !important; }

    /* Darker glass variables on mobile only */
    :root {
        --gradient-glass: linear-gradient(135deg, rgba(18, 18, 24, 0.72), rgba(8, 8, 12, 0.72));
        --glass-bg: rgba(15, 15, 20, 0.72);
        --glass-bg-hover: rgba(18, 18, 24, 0.82);
        --glass-border: rgba(255, 255, 255, 0.08);
        --glass-border-hover: rgba(255, 255, 255, 0.14);
    }

    /* Apply darker glass to cards explicitly */
    .glass-card { 
        background: #14141a !important; 
        border: 1px solid rgba(255,255,255,0.06) !important; 
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: none !important;
    }

    /* Ensure hero text card also becomes darker */
    .hero-content.hero-card { 
        background: #14141a !important; 
        border: 1px solid rgba(255,255,255,0.06) !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: none !important;
    }

    /* Remove glass effect from other components that use blur/transparent glass */
    .project-card,
    .story-card,
    .principles-card,
    .cta-card,
    .skill-tile.glass-card,
    .testi-card,
    .about-profile.glass-card,
    .timeline-item { 
        background: #14141a !important; 
        border: 1px solid rgba(255,255,255,0.06) !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: none !important;
    }

    /* Buttons and controls that had glass blur */
    .project-open,
    .carousel-arrow,
    .nav-btn,
    .viewer-close { 
        background: #1a1a22 !important; 
        border: 1px solid rgba(255,255,255,0.08) !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        box-shadow: none !important;
    }
}
