/* ==========================================================================
   CSS Custom Properties (Design Tokens)
   ========================================================================== */
:root {
    /* Colors - Dark Luxury Tech */
    --clr-bg: #0a0a0f;
    --clr-bg-alt: #121218;
    --clr-accent: #c9a84c;
    --clr-accent-rgb: 201, 168, 76;
    --clr-text-main: #f5f0e8;
    --clr-text-muted: rgba(245, 240, 232, 0.7);
    --clr-glow: #3b82f6;
    --clr-glass-bg: rgba(255, 255, 255, 0.03);
    --clr-glass-hover: rgba(255, 255, 255, 0.06);
    --clr-glass-border: rgba(255, 255, 255, 0.08);

    /* Typography */
    --font-heading: 'Playfair Display', serif;
    --font-body: 'DM Sans', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;

    /* Spacing & Layout */
    --container-max: 1200px;
    --padding-section: clamp(4rem, 8vw, 8rem);
    --padding-container: clamp(1.5rem, 5vw, 3rem);

    /* Transitions */
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
    --transition-fast: 0.3s var(--ease-out-expo);
    --transition-slow: 0.8s var(--ease-in-out);
}

/* ==========================================================================
   Reset & Global Styles
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--clr-bg);
    overflow-x: hidden;
    width: 100%;
}

body {
    font-family: var(--font-body);
    background-color: var(--clr-bg);
    color: var(--clr-text-main);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
    /* Hide default cursor to use custom one */
    cursor: none;
}

a,
button {
    cursor: none;
    text-decoration: none;
    color: inherit;
    border: none;
    background: none;
    font-family: inherit;
}

img,
svg {
    display: block;
    max-width: 100%;
}

ul {
    list-style: none;
}

/* ==========================================================================
   Typography utilities
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 500;
    line-height: 1.1;
    color: var(--clr-text-main);
}

.text-accent {
    color: var(--clr-accent);
}

.text-muted {
    color: var(--clr-text-muted);
}

.text-mono {
    font-family: var(--font-mono);
}

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

.section-heading {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    margin-bottom: 2rem;
}

.section-subheading {
    font-family: var(--font-mono);
    color: var(--clr-accent);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-size: clamp(0.75rem, 1.5vw, 0.9rem);
    margin-bottom: 1rem;
    display: block;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 1rem 2rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 4px;
    transition: var(--transition-fast);
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.btn-primary {
    background-color: var(--clr-accent);
    color: var(--clr-bg);
    font-weight: 600;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #fff;
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.btn-primary:hover::before {
    opacity: 0.2;
}

.btn-primary:hover {
    box-shadow: 0 0 20px rgba(var(--clr-accent-rgb), 0.4);
    transform: translateY(-2px);
}

.btn-outline {
    border: 1px solid var(--clr-accent);
    color: var(--clr-accent);
}

.btn-outline:hover {
    background-color: rgba(var(--clr-accent-rgb), 0.1);
    transform: translateY(-2px);
}

/* ==========================================================================
   Background Effects & Layout
   ========================================================================== */
.noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9998;
    opacity: 0.04;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--padding-container);
}

.section {
    padding: var(--padding-section) 0;
    position: relative;
}

.clip-transition {
    clip-path: polygon(0 0, 100% 5%, 100% 100%, 0 95%);
    background-color: var(--clr-bg-alt);
    margin-top: -5vw;
    padding-top: calc(var(--padding-section) + 5vw);
    padding-bottom: calc(var(--padding-section) + 5vw);
    z-index: 10;
}

.clip-transition-alt {
    background-color: var(--clr-bg);
    margin-top: -5vw;
    padding-top: calc(var(--padding-section) + 5vw);
    z-index: 11;
}

.glass-panel {
    background: var(--clr-glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--clr-glass-border);
    border-radius: 12px;
}

/* ==========================================================================
   Custom Cursor
   ========================================================================== */
.cursor-dot,
.cursor-ring {
    position: fixed;
    top: 0;
    left: 0;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    z-index: 9999;
    pointer-events: none;
}

.cursor-dot {
    width: 6px;
    height: 6px;
    background-color: var(--clr-accent);
}

.cursor-ring {
    width: 36px;
    height: 36px;
    border: 1px solid var(--clr-accent);
    transition: width 0.2s, height 0.2s, background-color 0.2s;
}

.cursor-ring.hover {
    width: 60px;
    height: 60px;
    background-color: rgba(var(--clr-accent-rgb), 0.1);
    border-color: transparent;
}

@media (max-width: 768px) {

    .cursor-dot,
    .cursor-ring {
        display: none;
    }

    body,
    a,
    button {
        cursor: auto;
    }
}

/* ==========================================================================
   Page Loader Animation
   ========================================================================== */
.loader {
    position: fixed;
    inset: 0;
    background-color: var(--clr-bg);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.8s var(--ease-out-expo), visibility 0.8s;
}

.loader.hidden {
    opacity: 0;
    visibility: hidden;
}

.loader-path {
    stroke-dasharray: 200;
    stroke-dashoffset: 200;
    animation: drawLogo 2s ease-in-out forwards;
}

@keyframes drawLogo {
    to {
        stroke-dashoffset: 0;
    }
}

/* ==========================================================================
   Scroll Reveal System
   ========================================================================== */
.reveal-item {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo), border-color 0.8s ease;
}

.reveal-item.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-item.delay-1 {
    transition-delay: 0.1s;
}

.reveal-item.delay-2 {
    transition-delay: 0.2s;
}

.reveal-item.delay-3 {
    transition-delay: 0.3s;
}

.reveal-item.revealed.border-flash {
    border-left: 2px solid var(--clr-accent);
    animation: flashLeftBorder 1.5s var(--ease-out-expo) forwards;
}

@keyframes flashLeftBorder {
    0% {
        border-left-color: rgba(var(--clr-accent-rgb), 0);
    }

    50% {
        border-left-color: rgba(var(--clr-accent-rgb), 1);
    }

    100% {
        border-left-color: rgba(var(--clr-accent-rgb), 0);
    }
}

/* ==========================================================================
   Navbar
   ========================================================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition-fast);
    padding: 1.5rem 0;
    background: transparent;
}

.header.scrolled {
    padding: 1rem 0;
    background: var(--clr-glass-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--clr-accent);
}

.header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--clr-accent);
    opacity: 0;
    transform: translateX(-20px);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo);
}

body.loaded .logo {
    opacity: 1;
    transform: translateX(0);
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--clr-text-main);
    transition: color 0.3s ease;
    opacity: 0;
    transform: translateX(20px);
}

.nav-link:hover {
    color: var(--clr-accent);
}

.contact-btn {
    border: 1px solid var(--clr-accent);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    color: var(--clr-accent);
}

.contact-btn:hover {
    background-color: rgba(var(--clr-accent-rgb), 0.1);
}

body.loaded .nav-link {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.8s var(--ease-out-expo), transform 0.8s var(--ease-out-expo), color 0.3s ease;
}

body.loaded .nav-link:nth-child(1) {
    transition-delay: 0.1s;
}

body.loaded .nav-link:nth-child(2) {
    transition-delay: 0.2s;
}

body.loaded .nav-link:nth-child(3) {
    transition-delay: 0.3s;
}

body.loaded .nav-link:nth-child(4) {
    transition-delay: 0.4s;
}

body.loaded .nav-link:nth-child(5) {
    transition-delay: 0.5s;
}

body.loaded .nav-link:nth-child(6) {
    transition-delay: 0.6s;
}

/* Mobile Menu */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    z-index: 1002;
    opacity: 0;
}

body.loaded .mobile-menu-btn {
    opacity: 1;
    transition: opacity 0.8s ease 0.5s;
}

.mobile-menu-btn .bar {
    width: 100%;
    height: 2px;
    background-color: var(--clr-accent);
    transition: var(--transition-fast);
    transform-origin: left center;
}

.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(10, 10, 15, 0.98);
    backdrop-filter: blur(10px);
    z-index: 1001;
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition-fast);
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-nav-links {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    text-align: center;
}

.mobile-nav-link {
    font-family: var(--font-heading);
    font-size: 2rem;
    opacity: 0;
    transform: translateY(20px);
    transition: var(--transition-fast);
}

.mobile-menu-overlay.active .mobile-nav-link {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero-section {
    height: 100vh;
    min-height: 600px;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.hero-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.hero-container {
    position: relative;
    z-index: 1;
    width: 100%;
}

.hero-title {
    font-size: clamp(3rem, 8vw, 6rem);
    margin: 1rem 0 1.5rem;
    line-height: 1;
}

.hero-title .word {
    display: inline-block;
    opacity: 0;
    transform: translateY(30px);
}

.hero-title.animate .word {
    animation: textUp 0.8s var(--ease-out-expo) forwards;
}

@keyframes textUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
    max-width: 600px;
    margin-bottom: 3rem;
    opacity: 0;
    transform: translateY(20px);
}

body.loaded .hero-subtitle {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s var(--ease-out-expo) 1s, transform 0.8s var(--ease-out-expo) 1s;
}

.hero-ctas {
    display: flex;
    gap: 1.5rem;
    opacity: 0;
    transform: translateY(20px);
}

body.loaded .hero-ctas {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s var(--ease-out-expo) 1.2s, transform 0.8s var(--ease-out-expo) 1.2s;
}

.scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    color: var(--clr-accent);
    opacity: 0;
    animation: bounce 2s infinite var(--ease-in-out);
}

body.loaded .scroll-indicator {
    opacity: 1;
    transition: opacity 1s ease 1.5s;
}

@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translate(-50%, 0);
    }

    40% {
        transform: translate(-50%, -10px);
    }

    60% {
        transform: translate(-50%, -5px);
    }
}

.hero-watermark {
    position: absolute;
    bottom: 2rem;
    right: 2rem;
    font-size: 0.7rem;
    color: rgba(201, 168, 76, 0.3);
    pointer-events: none;
    line-height: 1;
}

.hero-image-wrapper {
    position: absolute;
    right: 5%;
    top: 50%;
    transform: translateY(-50%);
    width: 35vw;
    max-width: 500px;
    height: 80vh;
    display: flex;
    justify-content: center;
    align-items: flex-end;
    pointer-events: none;
    z-index: 0;
    opacity: 0;
}

body.loaded .hero-image-wrapper {
    opacity: 1;
    transition: opacity 1.5s var(--ease-out-expo) 0.5s;
}

.hero-image {
    object-fit: contain;
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 0 30px rgba(201, 168, 76, 0.15)) grayscale(20%) contrast(1.1);
    /* Fade the bottom edge of the image to blend into the background */
    -webkit-mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 80%, rgba(0, 0, 0, 0) 100%);
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 1) 80%, rgba(0, 0, 0, 0) 100%);
}

.hero-image-glow {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 50%;
    background: radial-gradient(circle, rgba(201, 168, 76, 0.2) 0%, transparent 70%);
    z-index: -1;
}

.hero-image-ring {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: clamp(280px, 35vw, 550px);
    height: clamp(280px, 35vw, 550px);
    border-radius: 50%;
    border: 2px solid rgba(201, 168, 76, 0.15);
    border-top: 2px solid var(--clr-accent);
    border-bottom: 2px solid var(--clr-accent);
    box-shadow: 0 0 30px rgba(201, 168, 76, 0.05);
    z-index: -1;
    animation: rotateRing 15s linear infinite;
    pointer-events: none;
}

@keyframes rotateRing {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

@media (max-width: 1024px) {
    .hero-image-wrapper {
        opacity: 0.15 !important;
        /* Make it a watermark-style background on smaller screens */
        right: 0;
        width: 80vw;
    }

    .hero-content {
        position: relative;
        z-index: 2;
    }
}

/* ==========================================================================
   About Section
   ========================================================================== */
.about-inner {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text {
    padding: 2rem;
    margin-bottom: 3rem;
    border-left: 2px solid transparent;
    /* Prepared for border flash */
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: var(--clr-text-muted);
}

.about-text p:last-child {
    margin-bottom: 0;
}

.about-stats {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    border-top: 1px solid var(--clr-glass-border);
    padding-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--clr-text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.decorative-frame {
    position: relative;
    width: 100%;
    aspect-ratio: 4/5;
    border: 1px solid var(--clr-glass-border);
    border-radius: 4px;
    padding: 1.5rem;
}

.decorative-frame::before,
.decorative-frame::after {
    content: '';
    position: absolute;
    width: 40%;
    height: 40%;
}

.decorative-frame::before {
    top: -10px;
    left: -10px;
    border-top: 2px solid var(--clr-accent);
    border-left: 2px solid var(--clr-accent);
}

.decorative-frame::after {
    bottom: -10px;
    right: -10px;
    border-bottom: 2px solid var(--clr-accent);
    border-right: 2px solid var(--clr-accent);
}

.frame-inner {
    background: var(--clr-bg);
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    border: 1px solid rgba(201, 168, 76, 0.2);
}

.frame-content {
    color: var(--clr-text-muted);
    font-size: 0.9rem;
    line-height: 1.8;
}

.frame-content span {
    color: var(--clr-accent);
}

/* ==========================================================================
   Skills Section
   ========================================================================== */
.skills-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.skill-card {
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: all 0.4s var(--ease-out-expo);
    position: relative;
    overflow: hidden;
}

.skill-card::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: radial-gradient(circle, rgba(201, 168, 76, 0.15) 0%, transparent 70%);
    transform: translate(-50%, -50%);
    border-radius: 50%;
    transition: width 0.4s ease, height 0.4s ease;
    z-index: -1;
}

.skill-card:hover {
    transform: translateY(-5px);
    border-color: rgba(201, 168, 76, 0.5);
    box-shadow: 0 10px 30px rgba(10, 10, 15, 0.5);
}

.skill-card:hover::after {
    width: 200%;
    height: 200%;
}

.skill-icon {
    font-size: 2rem;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    font-family: var(--font-heading);
}

.skill-name {
    font-size: 1.1rem;
    margin-bottom: 0.2rem;
    font-family: var(--font-body);
}

.skill-category {
    font-size: 0.75rem;
    color: var(--clr-accent);
    opacity: 0.8;
}

/* ==========================================================================
   Experience & Education Timeline
   ========================================================================== */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 0;
}

.timeline-line {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 2px;
    background: var(--clr-glass-border);
    transform: translateX(-50%);
    z-index: 0;
}

/* Animated part of line */
.timeline-line::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 0;
    /* JS will animate this to 100% on scroll */
    background: var(--clr-accent);
    transition: height 1.5s var(--ease-in-out);
}

.timeline.draw-line .timeline-line::after {
    height: 100%;
}

.timeline-item {
    position: relative;
    z-index: 1;
    margin-bottom: 4rem;
    width: 50%;
    padding-right: 3rem;
}

.timeline-item:nth-child(even) {
    margin-left: 50%;
    padding-left: 3rem;
    padding-right: 0;
}

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

.timeline-dot {
    position: absolute;
    top: 0;
    right: -24px;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--clr-bg);
    border: 2px solid var(--clr-accent);
    z-index: 2;
    transition: var(--transition-fast);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.timeline-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.4s ease;
}

.timeline-item.revealed .timeline-logo {
    filter: grayscale(0%);
}

.timeline-item:nth-child(even) .timeline-dot {
    left: -24px;
}

.timeline-item.revealed .timeline-dot {
    background: var(--clr-bg);
    box-shadow: 0 0 20px rgba(var(--clr-accent-rgb), 0.3);
    border-color: var(--clr-accent);
    animation: nodePulse 1s var(--ease-out-expo) forwards;
}

@keyframes nodePulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.5);
    }

    100% {
        transform: scale(1);
    }
}

.timeline-date {
    font-family: var(--font-mono);
    font-size: 0.9rem;
    color: var(--clr-text-muted);
    margin-bottom: 0.5rem;
}

.timeline-content {
    padding: 1.5rem;
    border-radius: 8px;
}

.timeline-title {
    font-size: 1.25rem;
    margin-bottom: 0.2rem;
}

.timeline-company {
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.timeline-details li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--clr-text-muted);
    font-size: 0.95rem;
}

.timeline-details li::before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--clr-accent);
}

.timeline-short .timeline-item {
    margin-bottom: 2rem;
}

/* ==========================================================================
   Projects Section
   ========================================================================== */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(450px, 1fr));
    gap: 3rem;
}

.project-card {
    position: relative;
    background: var(--clr-bg-alt);
    border: 1px solid var(--clr-glass-border);
    border-radius: 12px;
    overflow: hidden;
    min-height: 350px;
    transform-style: preserve-3d;
    will-change: transform;
}

.project-content {
    padding: 3rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    transform: translateZ(30px);
    /* 3D effect base */
}

.project-header {
    margin-bottom: 1.5rem;
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--clr-glass-border);
    border-radius: 20px;
    font-size: 0.75rem;
    margin-bottom: 1rem;
}

.project-title {
    font-size: 1.8rem;
    line-height: 1.2;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.project-tags span {
    font-size: 0.75rem;
    color: var(--clr-accent);
    background: rgba(var(--clr-accent-rgb), 0.1);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.project-desc {
    color: var(--clr-text-muted);
    line-height: 1.7;
    margin-top: auto;
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 15, 0.85);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.4s var(--ease-out-expo);
    transform: translateZ(50px);
}

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

/* ==========================================================================
   Contact Section
   ========================================================================== */
.contact-section {
    position: relative;
    overflow: hidden;
}

.contact-bg-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 60vw;
    height: 60vw;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.05) 0%, transparent 60%);
    transform: translate(-50%, -50%);
    z-index: 0;
    pointer-events: none;
}

.contact-content {
    position: relative;
    z-index: 1;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-subtext {
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: flex-start;
    text-align: left;
    margin-bottom: 3rem;
}

.contact-form-wrapper {
    padding: 2.5rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--clr-accent);
    font-size: 0.9rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    background: rgba(10, 10, 15, 0.5);
    border: 1px solid var(--clr-glass-border);
    border-radius: 4px;
    padding: 1rem;
    color: var(--clr-text-main);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: rgba(201, 168, 76, 0.5);
    background: rgba(10, 10, 15, 0.8);
    box-shadow: 0 0 15px rgba(201, 168, 76, 0.1);
}

.submit-btn {
    width: 100%;
    margin-top: 1rem;
}

.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    display: none;
}

.submit-btn.loading .btn-text {
    display: none;
}

.submit-btn.loading .spinner {
    display: block;
}

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

.form-status {
    margin-top: 1rem;
    font-size: 0.85rem;
    text-align: center;
    min-height: 20px;
}

.form-status.success {
    color: #4ade80;
}

.form-status.error {
    color: #f87171;
}

.contact-cards {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.contact-card {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    transition: var(--transition-fast);
}

.contact-card:hover {
    transform: translateY(-5px);
    border-color: rgba(var(--clr-accent-rgb), 0.5);
    box-shadow: 0 10px 30px rgba(var(--clr-accent-rgb), 0.1);
}

.contact-icon {
    font-size: 2rem;
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
}

.contact-label {
    font-size: 0.75rem;
    color: var(--clr-accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.contact-value {
    font-size: 0.9rem;
    color: var(--clr-text-main);
    word-break: break-all;
}

.mt-4 {
    margin-top: 2rem;
}

/* Toast */
.toast {
    position: fixed;
    bottom: -100px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 1.5rem;
    background: rgba(10, 10, 15, 0.95);
    z-index: 10000;
    transition: bottom 0.4s var(--ease-out-expo);
}

.toast.show {
    bottom: 2rem;
}

.toast-icon {
    color: var(--clr-accent);
    font-size: 1.2rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.footer {
    border-top: 1px solid rgba(var(--clr-accent-rgb), 0.3);
    padding: 2rem 0;
    background-color: var(--clr-bg);
}

.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-left {
    font-size: 0.9rem;
}

.footer-center .logo-text {
    font-size: 1.5rem;
}

.footer-right {
    display: flex;
    align-items: center;
}

.typing-cursor {
    animation: blink 1s step-end infinite;
}

@keyframes blink {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0;
    }
}

/* ==========================================================================
   Media Queries
   ========================================================================== */
@media (max-width: 1024px) {
    .about-inner {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .decorative-frame {
        max-width: 400px;
        margin: 0 auto;
    }

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

    .contact-cards {
        grid-template-columns: 1fr;
    }
}

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

    .mobile-menu-btn {
        display: flex;
    }

    .mobile-menu-btn.active .bar:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .mobile-menu-btn.active .bar:nth-child(2) {
        opacity: 0;
    }

    .mobile-menu-btn.active .bar:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -8px);
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hero-ctas {
        flex-direction: column;
    }

    .hero-watermark {
        display: none;
    }

    .about-stats {
        flex-direction: column;
        gap: 2rem;
    }

    .decorative-frame {
        padding: 1rem;
    }

    .frame-inner {
        padding: 1.25rem;
    }

    .frame-content {
        font-size: 0.75rem;
        white-space: pre-wrap;
        word-break: break-word;
    }

    /* Timeline Mobile */
    .timeline-line {
        left: 24px;
        transform: none;
    }

    .timeline-item,
    .timeline-item:nth-child(even) {
        width: 100%;
        margin-left: 0;
        padding-left: 4rem;
        padding-right: 0;
    }

    .timeline-dot {
        left: 0 !important;
        right: auto !important;
    }

    .footer-inner {
        flex-direction: column;
        text-align: center;
        gap: 1.5rem;
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}