:root {
    --bg-dark: #000000;
    --bg-card: rgba(24, 24, 27, 0.5);
    --border-color: rgba(255, 255, 255, 0.08);
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    --accent-color: #10b981;
    --accent-glow: rgba(16, 185, 129, 0.2);
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --navbar-bg: rgba(10, 10, 10, 0.7);
    --footer-bg: #09090b;
}

/* ===================== LIGHT MODE ===================== */
body.light-mode {
    --bg-dark: #f4f4f5;
    --bg-card: rgba(255, 255, 255, 0.75);
    --border-color: rgba(0, 0, 0, 0.1);
    --text-primary: #18181b;
    --text-secondary: #52525b;
    --accent-color: #059669;
    --accent-glow: rgba(5, 150, 105, 0.15);
    --navbar-bg: rgba(244, 244, 245, 0.8);
    --footer-bg: #e4e4e7;
}

body.light-mode .grid-background {
    background-image:
        linear-gradient(to right, rgba(5, 150, 105, 0.12) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(5, 150, 105, 0.12) 1px, transparent 1px);
}

body.light-mode .glow-blob {
    background: radial-gradient(circle, rgba(5, 150, 105, 0.06) 0%, transparent 60%);
}

body.light-mode .navbar {
    background: var(--navbar-bg);
    border-color: rgba(0,0,0,0.08);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.08);
}

body.light-mode .nav-links a,
body.light-mode .logo {
    color: var(--text-primary);
}

body.light-mode footer {
    background: var(--footer-bg);
    border-color: rgba(0,0,0,0.08);
}

body.light-mode .status-badge {
    background: rgba(5, 150, 105, 0.1);
    border-color: rgba(5, 150, 105, 0.2);
}

body.light-mode .btn-secondary {
    background: rgba(0,0,0,0.05);
    border-color: rgba(0,0,0,0.15);
    color: var(--text-primary);
}

body.light-mode .card {
    background: var(--bg-card);
    border-color: var(--border-color);
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
}

body.light-mode .loading-screen {
    background: #f4f4f5;
}

/* ---- Light Mode: Projects Section ---- */
body.light-mode .carousel-container {
    background: transparent;
}

body.light-mode .project-card {
    background-color: rgba(24, 24, 27, 0.85) !important;
    border-color: rgba(255,255,255,0.1) !important;
}

body.light-mode .project-link:hover .project-card {
    border-color: var(--accent-color) !important;
}

body.light-mode .project-content h3,
body.light-mode .project-content p {
    color: #ffffff !important;
}

body.light-mode .carousel-btn {
    background: rgba(255,255,255,0.9);
    border-color: rgba(0,0,0,0.15);
    color: #18181b;
}

body.light-mode .carousel-btn:hover {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

/* ---- Light Mode: Navbar fixes ---- */
body.light-mode .nav-btn {
    background: rgba(0,0,0,0.08);
    color: #18181b;
    border-color: rgba(0,0,0,0.15);
}

body.light-mode .nav-btn:hover {
    background: var(--accent-color);
    color: white;
    border-color: var(--accent-color);
}

body.light-mode .nav-links a {
    color: #3f3f46;
}

body.light-mode .nav-links a:hover {
    color: var(--accent-color);
}

/* ---- Light Mode: Footer fixes ---- */
body.light-mode .footer-brand p,
body.light-mode .footer-links a,
body.light-mode .footer-links h4,
body.light-mode .copyright p {
    color: #52525b;
}

body.light-mode .footer-social-tray a {
    color: #52525b;
    border-color: rgba(0,0,0,0.12);
}

body.light-mode .footer-social-tray a:hover {
    color: var(--accent-color);
    border-color: var(--accent-color);
}

/* ---- Light Mode: Back to Top ---- */
body.light-mode .back-to-top {
    background: rgba(255,255,255,0.9);
    color: #18181b;
    border-color: rgba(0,0,0,0.15);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

/* Smooth transition for all theme changes */
body, body * {
    transition: background-color 0.4s ease, border-color 0.4s ease, color 0.4s ease, box-shadow 0.4s ease;
}

/* ===================== GLOBAL REVEAL ANIMATIONS ===================== */
.reveal-item {
    opacity: 0;
    transition: 
        opacity 1.2s cubic-bezier(0.22, 1, 0.36, 1),
        transform 1.2s cubic-bezier(0.22, 1, 0.36, 1),
        filter 1.2s cubic-bezier(0.22, 1, 0.36, 1);
    filter: blur(15px);
    will-change: transform, opacity, filter;
}

.reveal-left { transform: translateX(-50px); }
.reveal-right { transform: translateX(50px); }
.reveal-up { transform: translateY(40px); }

.reveal-item.active {
    opacity: 1;
    transform: translate(0, 0);
    filter: blur(0);
}


/* ===================== TOAST NOTIFICATION ===================== */

/* ===================== TOAST NOTIFICATION ===================== */
.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(16, 185, 129, 0.15);
    border: 1px solid var(--accent-color);
    color: var(--accent-color);
    padding: 0.75rem 1.5rem;
    border-radius: 99px;
    font-size: 0.9rem;
    font-weight: 600;
    z-index: 99998;
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.4s ease;
    opacity: 0;
    pointer-events: none;
}

.toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

/* ===================== HAMBURGER MENU ===================== */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    width: 2.25rem;
    height: 2.25rem;
    padding: 6px;
    border-radius: 0.5rem;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    cursor: none;
    backdrop-filter: blur(8px);
    justify-content: center;
    align-items: center;
}

.hamburger span {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

.mobile-menu {
    display: none;
    flex-direction: column;
    gap: 0;
    background: rgba(10,10,10,0.95);
    backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-color);
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
}

.mobile-menu.open {
    max-height: 400px;
    padding: 1rem 0;
}

.mobile-link {
    padding: 0.85rem 2rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 1px solid var(--border-color);
    transition: color 0.2s, background 0.2s;
}

.mobile-link:hover {
    color: var(--accent-color);
    background: rgba(16,185,129,0.05);
}

body.light-mode .mobile-menu {
    background: rgba(244,244,245,0.97);
}

/* ===================== PROJECT HOVER OVERLAY ===================== */
.project-card {
    position: relative;
    overflow: hidden;
}

.project-overlay {
    position: absolute;
    inset: 0;
    background: rgba(16, 185, 129, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.35s ease;
    backdrop-filter: blur(2px);
    z-index: 2;
}

.project-overlay span {
    background: var(--accent-color);
    color: white;
    font-weight: 700;
    padding: 0.6rem 1.4rem;
    border-radius: 99px;
    font-size: 0.95rem;
    transform: translateY(10px);
    transition: transform 0.35s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

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

.project-card:hover .project-overlay span {
    transform: translateY(0);
}


/* ===================== CONTACT SECTION ===================== */
.contact-section {
    padding: 5rem 0;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 3rem;
    align-items: start;
    margin-top: 3rem;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    border-radius: 1rem;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    backdrop-filter: blur(8px);
    transition: border-color 0.3s, box-shadow 0.3s;
}

.contact-item:hover {
    border-color: var(--accent-color);
    box-shadow: 0 4px 20px var(--accent-glow);
}

.contact-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.75rem;
    background: rgba(16,185,129,0.1);
    color: var(--accent-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}

.contact-item h4 {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 0.15rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.contact-item a {
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

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

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 0.85rem 1.1rem;
    border-radius: 0.75rem;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-primary);
    font-family: var(--font-sans);
    font-size: 0.95rem;
    backdrop-filter: blur(8px);
    outline: none;
    transition: border-color 0.3s, box-shadow 0.3s;
    resize: vertical;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--text-secondary);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(16,185,129,0.1);
}

@media (max-width: 768px) {
    .hamburger { display: flex; }
    .nav-links { display: none; }
    .mobile-menu { display: flex; }
    .contact-grid { grid-template-columns: 1fr; }
}

/* ===================== THEME TOGGLE BUTTON ===================== */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.theme-toggle {
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--bg-card);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: none;
    font-size: 0.9rem;
    backdrop-filter: blur(8px);
    transition: all 0.3s ease, transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) !important;
}

.theme-toggle:hover {
    border-color: var(--accent-color);
    color: var(--accent-color);
    box-shadow: 0 0 12px var(--accent-glow);
}

.theme-toggle.spin i {
    animation: spinIcon 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes spinIcon {
    0%   { transform: rotate(0deg) scale(0.5); opacity: 0; }
    100% { transform: rotate(360deg) scale(1); opacity: 1; }
}

/* ===================== MAGNETIC BUTTON BASE ===================== */
.btn {
    will-change: transform;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275), 
                background 0.3s ease, 
                box-shadow 0.3s ease,
                border-color 0.3s ease !important;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: var(--font-sans);
    background-color: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    cursor: none; /* Hide default cursor */
}

/* ===================== LOADING SCREEN ===================== */
.loading-screen {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.8s ease, visibility 0.8s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

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

.loader-name {
    font-size: 3rem;
    font-weight: 900;
    letter-spacing: -2px;
    margin-bottom: 0.5rem;
    animation: blurFadeIn 0.8s ease forwards;
}

.loader-tagline {
    color: var(--text-secondary);
    font-size: 0.95rem;
    margin-bottom: 2rem;
    animation: blurFadeIn 0.8s ease 0.2s forwards;
    opacity: 0;
}

.loader-bar {
    width: 200px;
    height: 3px;
    background: rgba(255,255,255,0.1);
    border-radius: 99px;
    margin: 0 auto;
    overflow: hidden;
}

.loader-fill {
    height: 100%;
    width: 0%;
    background: var(--accent-color);
    border-radius: 99px;
    animation: loadFill 1.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    box-shadow: 0 0 10px var(--accent-color);
}

@keyframes loadFill {
    0% { width: 0%; }
    100% { width: 100%; }
}

/* ===================== CUSTOM CURSOR ===================== */
.cursor-dot {
    position: fixed;
    width: 8px;
    height: 8px;
    background: var(--accent-color);
    border-radius: 50%;
    pointer-events: none;
    z-index: 10000;
    transform: translate(-50%, -50%);
    transition: transform 0.1s ease, width 0.2s ease, height 0.2s ease;
    box-shadow: 0 0 10px var(--accent-color), 0 0 20px rgba(16,185,129,0.4);
}

.cursor-ring {
    position: fixed;
    width: 36px;
    height: 36px;
    border: 1.5px solid rgba(16, 185, 129, 0.5);
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    transform: translate(-50%, -50%);
    transition: transform 0.12s ease, width 0.3s ease, height 0.3s ease, border-color 0.3s ease;
}

body:has(a:hover) .cursor-dot,
body:has(button:hover) .cursor-dot {
    width: 12px;
    height: 12px;
}

body:has(a:hover) .cursor-ring,
body:has(button:hover) .cursor-ring {
    width: 50px;
    height: 50px;
    border-color: var(--accent-color);
}

/* ===================== TYPEWRITER CURSOR ===================== */
.cursor-blink {
    display: inline-block;
    color: var(--accent-color);
    font-weight: 300;
    animation: blink 1s step-end infinite;
    margin-left: 2px;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

/* ===================== STATS SECTION ===================== */
.stats-section {
    padding: 3rem 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}

.stat-item {
    padding: 1.5rem;
    position: relative;
}

.stat-item:not(:last-child)::after {
    content: '';
    position: absolute;
    right: 0;
    top: 20%;
    height: 60%;
    width: 1px;
    background: var(--border-color);
}

.stat-number-wrap {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 2px;
    margin-bottom: 0.5rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 900;
    color: var(--accent-color);
    line-height: 1;
    font-variant-numeric: tabular-nums;
}

.stat-suffix {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent-color);
}

.stat-label {
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

@media (max-width: 600px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .stat-item:nth-child(2)::after {
        display: none;
    }
}

/* Background Grid Pattern */
.grid-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image:
        linear-gradient(to right, rgba(16, 185, 129, 0.15) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(16, 185, 129, 0.15) 1px, transparent 1px);
    background-size: 50px 50px;
    mask-image: radial-gradient(800px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), black, transparent);
    -webkit-mask-image: radial-gradient(800px circle at var(--mouse-x, 50%) var(--mouse-y, 50%), black, transparent);
    pointer-events: none;
}

.glow-blob {
    position: fixed;
    top: 0;
    left: 0;
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.08) 0%, transparent 60%);
    border-radius: 50%;
    transform: translate(calc(var(--mouse-x, 50vw) - 50%), calc(var(--mouse-y, 50vh) - 50%));
    z-index: -2;
    pointer-events: none;
    transition: transform 0.15s ease-out; /* Smooth trailing effect */
}

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

/* Typography */
h1,
h2,
h3 {
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.1;
}

/* Navbar */
.navbar {
    position: fixed;
    top: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 800px;
    z-index: 100;
    background: rgba(24, 24, 27, 0.4);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border-color);
    border-radius: 9999px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.navbar.scrolled {
    background: rgba(24, 24, 27, 0.8);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.1);
    top: 1rem;
    border-color: rgba(255, 255, 255, 0.15);
}

.nav-container {
    width: 100%;
    padding: 0.75rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.25rem;
    font-weight: 800;
    text-decoration: none;
    color: var(--text-primary);
}

.logo-img-nav {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.nav-avatar {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--border-color);
    transition: all 0.2s ease;
}

.logo-img-nav:hover .nav-avatar {
    border-color: var(--accent-color);
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.3);
}

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

.nav-links a {
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    transition: color 0.2s;
}

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

.nav-btn {
    text-decoration: none;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s;
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

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

.hero::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 60%);
    z-index: -1;
    pointer-events: none;
}

.hero-content {
    max-width: 800px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.5rem;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.pulse {
    width: 8px;
    height: 8px;
    background-color: var(--accent-color);
    border-radius: 50%;
    position: relative;
}

.pulse::after {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    width: 16px;
    height: 16px;
    background-color: var(--accent-color);
    border-radius: 50%;
    animation: ping 2s cubic-bezier(0, 0, 0.2, 1) infinite;
    opacity: 0.5;
}

@keyframes ping {

    75%,
    100% {
        transform: scale(2);
        opacity: 0;
    }
}

@keyframes blurFadeIn {
    0% {
        opacity: 0;
        filter: blur(15px);
        transform: translateY(20px);
    }
    100% {
        opacity: 1;
        filter: blur(0);
        transform: translateY(0);
    }
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    animation: blurFadeIn 1.5s cubic-bezier(0.2, 0.8, 0.2, 1) 0.3s forwards;
    opacity: 0;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-secondary);
    max-width: 600px;
    opacity: 0;
    animation: blurFadeIn 1.5s cubic-bezier(0.2, 0.8, 0.2, 1) 0.8s forwards;
}

.hero-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    opacity: 0;
    animation: blurFadeIn 1.5s cubic-bezier(0.2, 0.8, 0.2, 1) 1.2s forwards;
}

.btn {
    text-decoration: none;
    padding: 0.75rem 1.5rem;
    border-radius: 9999px;
    font-weight: 500;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: white;
    color: black;
}

.btn-primary:hover {
    background: #e4e4e7;
    /* zinc-200 */
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--bg-card);
    color: white;
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Animated Resume Button */
.btn-animated {
    position: relative;
    background: linear-gradient(90deg, #10b981, #0ea5e9, #10b981);
    background-size: 200% auto;
    color: white;
    border: none;
    z-index: 1;
    overflow: hidden;
    animation: gradientShift 3s linear infinite;
}

.btn-animated:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 10px 25px rgba(16, 185, 129, 0.5);
    color: white;
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    100% {
        background-position: 200% 50%;
    }
}

.resume-view:hover {
    background: #3b82f6;
    border-color: #3b82f6;
}

.resume-download:hover {
    background: #10b981;
    border-color: #10b981;
}

/* General Sections */
.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 6rem 2rem;
}

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 1rem;
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.grid {
    display: grid;
    gap: 1.5rem;
}

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

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

.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 1rem;
    padding: 2rem;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), border-color 0.3s, box-shadow 0.3s;
    transform-style: preserve-3d;
}

.card:hover {
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.feature-card:hover {
    border-color: var(--accent-color);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4), 0 0 20px rgba(16, 185, 129, 0.15);
}

.feature-icon {
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-bottom: 1rem;
    background: rgba(16, 185, 129, 0.1);
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.75rem;
    transition: all 0.4s ease;
    transform: translateZ(20px);
    /* 3D pop effect */
}


.feature-card:hover .feature-icon {
    transform: translateZ(30px) scale(1.1) rotate(5deg);
    background: var(--accent-color);
    color: #fff;
    box-shadow: 0 0 15px var(--accent-color);
}

.feature-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    transform: translateZ(10px);
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    transform: translateZ(5px);
}

/* Projects Carousel */
.carousel-container {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.carousel-track {
    display: flex;
    gap: 1.5rem;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 1rem 0 2rem;
    -ms-overflow-style: none; /* IE/Edge */
    scrollbar-width: none; /* Firefox */
}

.carousel-track::-webkit-scrollbar {
    display: none;
}

.project-link {
    text-decoration: none;
    color: inherit;
    display: block;
    flex: 0 0 auto;
}

.project-link:hover .project-card {
    border-color: var(--accent-color);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.25);
    transform: translateY(-4px);
}

.carousel-track .project-card {
    min-width: 350px;
    max-width: 400px;
    flex: 0 0 auto;
    height: 320px;
    display: flex;
    align-items: flex-end;
    background-color: var(--bg-card); /* Fallback */
    background-blend-mode: overlay;
    border-radius: 1rem;
    padding: 2rem;
    transition: transform 0.5s cubic-bezier(0.25, 0.8, 0.25, 1), border-color 0.4s, box-shadow 0.4s;
}

.carousel-btn {
    position: absolute;
    z-index: 10;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: rgba(24, 24, 27, 0.8);
    border: 1px solid var(--border-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    backdrop-filter: blur(8px);
    transition: all 0.3s;
    top: 50%;
    transform: translateY(-50%);
}

.carousel-btn:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.prev-btn {
    left: -1.5rem;
}

.next-btn {
    right: -1.5rem;
}

.project-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.project-content p {
    color: #e4e4e7; /* lighter text for dark backgrounds */
    font-size: 0.95rem;
    line-height: 1.4;
}

/* Creator Section */
.creator-card {
    max-width: 800px;
    margin: 0 auto;
    padding: 3rem;
}

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

.avatar-placeholder {
    width: 5rem;
    height: 5rem;
    background: linear-gradient(135deg, var(--accent-color), #3b82f6);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 800;
    color: white;
}

.avatar-img {
    width: 5.5rem;
    height: 5.5rem;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--accent-color);
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.3);
}

.creator-name {
    font-size: 1.75rem;
}

.creator-role {
    color: var(--accent-color);
    font-weight: 500;
}

.creator-bio {
    color: var(--text-secondary);
    font-size: 1.05rem;
    margin-bottom: 2rem;
}

.creator-bio p {
    margin-bottom: 1rem;
}

.creator-links {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.social-btn {
    text-decoration: none;
    color: white;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    transition: all 0.2s;
}

.social-btn:hover {
    transform: translateY(-2px);
}

.social-btn.github:hover {
    background: #24292e;
    border-color: #24292e;
}

.social-btn.linkedin:hover {
    background: #0077b5;
    border-color: #0077b5;
}

.social-btn.instagram:hover {
    background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    border-color: transparent;
}

.social-btn.email:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
}

/* Footer */
footer {
    border-top: 1px solid var(--border-color);
    background: linear-gradient(to top, rgba(16, 185, 129, 0.05) 0%, rgba(0, 0, 0, 0) 100%), rgba(0, 0, 0, 0.6);
    margin-top: 6rem;
    position: relative;
}

.footer-container {
    padding-top: 5rem;
    padding-bottom: 4rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 3rem;
}

.footer-brand .logo {
    font-size: 2.5rem;
    display: block;
    margin-bottom: 0.5rem;
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 1.1rem;
    max-width: 300px;
}

.footer-social-tray {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.footer-social-tray a {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all 0.2s ease;
    text-decoration: none;
}

.footer-social-tray a:hover {
    background: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(16, 185, 129, 0.3);
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.footer-links h4 {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.2s;
}

.footer-links a:hover {
    color: var(--accent-color);
    transform: translateX(5px);
}

.copyright {
    text-align: center;
    padding: 1.5rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    background: var(--accent-color);
    color: black;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: 0 4px 20px rgba(16, 185, 129, 0.4);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-5px);
    background: #fff;
}

/* Responsive */
@media (max-width: 768px) {
    .navbar {
        width: 95%;
        top: 1rem;
    }

    .nav-links {
        display: none;
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .hero-actions {
        flex-direction: column;
        width: 100%;
        max-width: 300px;
    }

    .prev-btn { left: 0; }
    .next-btn { right: 0; }
    
    .carousel-track .project-card {
        min-width: 280px;
        height: 280px;
    }

    .creator-header {
        flex-direction: column;
        text-align: center;
    }

    .creator-links {
        justify-content: center;
    }

    .creator-card {
        padding: 2rem 1.5rem;
    }
}