/* === PREMIUM SPACE PORTFOLIO === */

/* --- Fonts & Variables --- */
:root {
    --primary: #00f3ff;
    --secondary: #bc13fe;
    --accent: #ff006e;
    --bg: #0a0e27;
    --surface: rgba(255, 255, 255, 0.03);
    --text: #e8eaed;
    --text-dim: #9ca3af;

    --font-display: 'Clash Display', sans-serif;
    --font-body: 'Inter', sans-serif;

    --ease: cubic-bezier(0.4, 0, 0.2, 1);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* --- Reset & Base --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
}

/* --- 3D Canvas Background --- */
#bg-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

/* --- Custom Cursor --- */
.cursor-dot,
.cursor-ring {
    position: fixed;
    pointer-events: none;
    z-index: 10000;
    mix-blend-mode: difference;
}

.cursor-dot {
    width: 8px;
    height: 8px;
    background: var(--primary);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.3s var(--ease), height 0.3s var(--ease);
}

.cursor-ring {
    width: 40px;
    height: 40px;
    border: 2px solid var(--primary);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.3s var(--ease), height 0.3s var(--ease), opacity 0.3s;
    opacity: 0.5;
}

body:hover .cursor-ring {
    opacity: 1;
}

/* --- Header --- */
header {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    padding: 2rem 4rem;
    background: rgba(10, 14, 39, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1400px;
    margin: 0 auto;
}

.nav-logo {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
    letter-spacing: 2px;
    position: relative;
}

.nav-logo::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width 0.4s var(--ease-out);
}

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

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

.nav-links a {
    color: var(--text);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    position: relative;
    transition: color 0.3s;
}

.nav-links a::before {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s var(--ease-out);
}

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

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

.menu-icon {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text);
}

/* --- Hero Section --- */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6rem 4rem 0 4rem;
    position: relative;
}

.hero-content {
    text-align: center;
    max-width: 900px;
    background: rgba(255, 255, 255, 0.02);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 32px;
    padding: 4rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.tag {
    display: inline-block;
    padding: 0.5rem 1.5rem;
    background: rgba(0, 243, 255, 0.1);
    border: 1px solid rgba(0, 243, 255, 0.3);
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: var(--primary);
    margin-bottom: 2rem;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(3rem, 8vw, 6rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #fff 0%, var(--primary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 80px rgba(0, 243, 255, 0.3);
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-dim);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-group {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 1rem 2.5rem;
    border-radius: 50px;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s var(--ease);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.5px;
}

.btn.primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #000;
    border: none;
}

.btn.primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--secondary), var(--accent));
    transition: left 0.5s var(--ease-out);
    z-index: -1;
}

.btn.primary:hover::before {
    left: 0;
}

.btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0, 243, 255, 0.4);
}

.btn.secondary {
    background: transparent;
    color: var(--text);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.btn.secondary:hover {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 20px rgba(0, 243, 255, 0.3);
}

/* --- Content Sections --- */
.content-section {
    padding: 8rem 4rem;
    max-width: 1400px;
    margin: 0 auto;
}

.section-header {
    margin-bottom: 4rem;
}

.section-subtitle {
    display: block;
    font-size: 0.9rem;
    color: var(--primary);
    font-weight: 600;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(2.5rem, 5vw, 4rem);
    font-weight: 700;
    color: var(--text);
    letter-spacing: -1px;
}

/* --- Bento Grid --- */
.bento-grid {
    display: grid;
    gap: 2rem;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

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

.bento-card {
    background: var(--surface);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 24px;
    padding: 2.5rem;
    position: relative;
    overflow: hidden;
    transition: all 0.4s var(--ease);
}

.bento-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    opacity: 0;
    transition: opacity 0.4s;
}

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

.bento-card:hover {
    border-color: rgba(0, 243, 255, 0.3);
    transform: translateY(-8px);
    box-shadow: 0 20px 60px rgba(0, 243, 255, 0.15);
}

.bento-card h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text);
}

.bento-card h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.bento-card p {
    color: var(--text-dim);
    line-height: 1.8;
}

.highlight {
    color: var(--primary) !important;
    font-weight: 600;
}

.date {
    font-size: 0.9rem;
    color: var(--text-dim);
}

.icons {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
    font-size: 2rem;
    color: var(--primary);
}

/* --- Project Cards --- */
.project-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
}

.project-card {
    min-height: 400px;
    max-height: 500px;
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-content h3 {
    font-size: 1.4rem;
    margin-bottom: 0.75rem;
    line-height: 1.3;
}

.card-content p {
    margin-bottom: 1rem;
    line-height: 1.6;
    font-size: 0.95rem;
}

.card-content p:not(.tech-stack) {
    flex: 1;
}

.tech-stack {
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 0.75rem !important;
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
    text-decoration: none;
    font-size: 0.9rem;
    margin-top: auto;
    transition: all 0.3s;
}

.project-link:hover {
    transform: translateX(5px);
    color: var(--secondary);
}

/* --- Skills --- */
.skills-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
}

.skill-pill {
    padding: 1rem 2rem;
    background: var(--surface);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text);
    transition: all 0.3s var(--ease);
    cursor: default;
}

.skill-pill:hover {
    background: rgba(0, 243, 255, 0.1);
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 243, 255, 0.2);
}

/* --- Contact --- */
.contact-container {
    text-align: center;
    background: var(--surface);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 32px;
    padding: 4rem;
    max-width: 900px;
    margin: 0 auto;
}

.contact-container h2 {
    font-family: var(--font-display);
    font-size: 3rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.contact-container p {
    color: var(--text-dim);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.25rem 2rem;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    color: var(--text);
    text-decoration: none;
    transition: all 0.3s var(--ease);
    font-size: 0.95rem;
}

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

.contact-item:hover {
    border-color: var(--primary);
    background: rgba(0, 243, 255, 0.05);
    transform: translateY(-4px);
    box-shadow: 0 10px 30px rgba(0, 243, 255, 0.2);
}

.email-link {
    display: inline-block;
    font-size: 1.5rem;
    color: var(--primary);
    text-decoration: none;
    margin-bottom: 2rem;
    transition: all 0.3s;
}

.email-link:hover {
    transform: scale(1.05);
    text-shadow: 0 0 20px var(--primary);
}

.socials {
    display: flex;
    gap: 2rem;
    justify-content: center;
}

.socials a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 50px;
    transition: all 0.3s;
}

.socials a:hover {
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 20px rgba(0, 243, 255, 0.3);
}

/* --- Education Grid --- */
.education-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.institution {
    color: var(--primary);
    font-weight: 500;
    margin-top: 0.5rem;
}

.details {
    color: var(--text-dim);
    font-size: 0.95rem;
    margin-top: 0.5rem;
}

/* --- Experience Card --- */
.experience-card {
    max-width: 900px;
    margin: 0 auto;
}

.experience-card .company {
    font-size: 1.1rem;
    margin-top: 0.5rem;
}

.experience-card .date {
    color: var(--text-dim);
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

/* --- Skills Container --- */
.skills-container {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.skill-category h3 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: var(--primary);
}

.skills-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

/* --- Certifications Grid --- */
.cert-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.cert-card {
    text-align: center;
    padding: 2.5rem 2rem;
}

.cert-icon {
    font-size: 3rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: block;
}

.cert-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.75rem;
}

.cert-card p {
    color: var(--text-dim);
    font-size: 0.95rem;
    margin-bottom: 0.5rem;
}

.cert-details {
    font-size: 0.85rem !important;
    color: var(--text-dim) !important;
    margin-top: 0.5rem;
}

/* --- Project Card Updates --- */
.tech-stack {
    color: var(--primary);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.project-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--primary);
    text-decoration: none;
    font-size: 0.95rem;
    margin-top: 1rem;
    transition: all 0.3s;
}

.project-link:hover {
    transform: translateX(5px);
    color: var(--secondary);
}

/* --- Responsive --- */
@media (max-width: 1024px) {
    .about-grid {
        grid-template-columns: 1fr;
    }

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

    .cert-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

@media (max-width: 768px) {
    header {
        padding: 1.5rem 2rem;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(10, 14, 39, 0.95);
        backdrop-filter: blur(20px);
        flex-direction: column;
        gap: 0;
        padding: 2rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }

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

    .nav-links li {
        padding: 1rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    }

    .menu-icon {
        display: block;
    }

    .hero {
        padding: 8rem 2rem 0 2rem;
        min-height: 100vh;
    }

    .hero-content {
        padding: 2.5rem 1.5rem;
    }

    .content-section {
        padding: 4rem 2rem;
    }

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

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

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

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

    .contact-info {
        grid-template-columns: 1fr;
        gap: 1rem;
        max-width: 100%;
        padding: 0 0.5rem;
    }

    .contact-item {
        padding: 1.1rem 1.25rem;
        font-size: 0.92rem;
        word-break: break-word;
        flex-direction: row;
        justify-content: flex-start;
        text-align: left;
        gap: 1rem;
    }

    .contact-item i {
        font-size: 1.4rem;
        flex-shrink: 0;
        min-width: 1.4rem;
    }

    .contact-container {
        padding: 4rem 1.25rem;
    }

    .contact-container h2 {
        font-size: 2rem;
        margin-bottom: 0.5rem;
    }

    .contact-container p {
        font-size: 0.95rem;
        margin-bottom: 2rem;
        padding: 0 0.5rem;
        line-height: 1.5;
    }

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

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

/* --- Animations --- */
@keyframes float {

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

    50% {
        transform: translateY(-20px);
    }
}

@keyframes glow {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}