:root {
    --primary-color: #6C63FF;
    --secondary-color: #4CAF50;
    --background: #0a0a0a;
    --surface: rgba(255, 255, 255, 0.05);
    --text: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    /* Make all text unselectable */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Make all images undraggable */
img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-drag: none;
    pointer-events: auto;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--background);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
    /* Prevent text selection and dragging */
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Hide visible scrollbars while preserving scroll behavior across browsers */
html, body {
    /* Firefox */
    scrollbar-width: none;
    /* IE 10+ / Edge */
    -ms-overflow-style: none;
}

/* WebKit browsers (Chrome, Safari, Edge Chromium) */
html::-webkit-scrollbar, body::-webkit-scrollbar {
    width: 0px;
    height: 0px;
    background: transparent;
}

/* Canvas Container */
#canvas-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
}

#canvas-container canvas {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100vh !important;
    object-fit: cover;
}

@media (max-width: 768px) {
    #canvas-container {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        overflow: hidden;
        -webkit-transform: translate3d(0, 0, 0);
        transform: translate3d(0, 0, 0);
    }
    
    #canvas-container canvas {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        min-width: 100vw !important;
        min-height: 100vh !important;
        max-width: 100vw !important;
        max-height: 100vh !important;
        transform: none !important;
        -webkit-transform: translate3d(0, 0, 0) !important;
        transform: translate3d(0, 0, 0) !important;
        object-fit: cover !important;
        will-change: auto !important;
    }
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    width: 100%;
    padding: 1rem 2rem;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

/* Force same header height on all pages */
.team-page header,
.projects-page header,
.contact-page header {
    padding: 1rem 2rem !important;
}

.team-page .logo-symbol img,
.projects-page .logo-symbol img,
.contact-page .logo-symbol img {
    height: 40px !important;
}

.team-page .logo-container,
.projects-page .logo-container,
.contact-page .logo-container {
    gap: 0.8rem !important;
}

.team-page nav,
.projects-page nav,
.contact-page nav {
    justify-content: space-between !important;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 100%;
    margin: 0 auto;
    width: 100%;
}

/* Mobile Menu Toggle Button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: var(--text);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

/* Normalize anchor-based logo containers */
a.logo-container {
    text-decoration: none;
    line-height: 1;
    padding: 0;
    margin: 0;
}

.logo-symbol img {
    height: 40px;
    width: auto;
}

.logo-text {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.logo {
    font-family: 'Poppins', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

nav ul {
    display: flex !important;
    list-style: none;
    gap: 2rem;
    margin: 0;
    padding: 0;
    align-items: center;
    margin-left: auto;
}

nav ul li {
    display: inline-block;
}

nav a {
    color: var(--text);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    white-space: nowrap;
}

nav a:hover {
    color: var(--primary-color);
    background: rgba(108, 99, 255, 0.1);
}

nav a.active {
    color: var(--primary-color);
    background: rgba(108, 99, 255, 0.15);
}

/* Sections */
section {
    padding: 6rem 2rem;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
}

.hero {
    text-align: center;
}

/* Typing Animation */
.typing-text {
    display: block;
    font-size: 0.65rem;
    color: var(--text-secondary);
    min-height: 1.5em;
    margin-bottom: 2rem;
    white-space: nowrap;
}

.cursor {
    display: inline-block;
    margin-left: 2px;
    animation: blink 1s infinite;
    font-weight: 300;
}

@keyframes blink {
    0%, 50% {
        opacity: 1;
    }
    51%, 100% {
        opacity: 0;
    }
}

/* Floating 3D Models */
#floating-models-container {
    position: relative;
    width: 100%;
    height: 350px;
    margin-top: 3rem;
}

#floating-models-container canvas {
    display: block;
}

.hero h1 {
    font-family: 'Poppins', sans-serif;
    font-size: 4rem;
    margin-bottom: 1rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    color: transparent;
}

.hero p {
    font-size: 1.5rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

/* Services Section */
.services {
    padding: 4rem 2rem;
}
.services-inner {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}
.services h2 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    /* lighter, softer gradient for the section heading */
    background: linear-gradient(45deg, #8f9bff, #7fe9ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    /* Initial hidden state */
    opacity: 0;
    transform: translateY(-100%);
}

.services h2.in-view {
    animation: dragInFromTop 0.8s ease-out forwards;
}

.services-sub {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    /* Initial hidden state */
    opacity: 0;
    transform: translateY(-100%);
}

.services-sub.in-view {
    animation: dragInFromTop 0.8s ease-out forwards;
    animation-delay: 0.15s; /* Slight delay after heading */
}
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.75rem;
    margin-top: 1.5rem;
}

/* Drag-in animation keyframes */
@keyframes dragInFromTop {
    0% {
        transform: translateY(-100%);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

/* Mobile fade-in animation */
@keyframes fadeInUp {
    0% {
        transform: translateY(20px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.service-card {
    background: linear-gradient(180deg, rgba(255,255,255,0.02), rgba(255,255,255,0.01));
    border-radius: 16px;
    padding: 1.75rem;
    text-align: left;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    box-shadow: 0 6px 20px rgba(0,0,0,0.35);
    position: relative;
    overflow: hidden;
    /* initial hidden state for scroll animation */
    opacity: 0;
    transform: translateY(-100%);
}

/* Subtle frosted-glass overlay on hover: keeps text sharp while blurring what sits behind the card */
.service-card::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 280ms ease, transform 280ms ease;
    /* small translucent tint so the blur effect is visible */
    background: rgba(255,255,255,0.02);
    /* backdrop-filter blurs the backdrop behind the element (frosted glass) */
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    z-index: 0;
}

.service-card > * {
    /* keep card content above the overlay */
    position: relative;
    z-index: 1;
}

.service-card:hover::before {
    opacity: 1;
}

.service-card:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow: 0 12px 30px rgba(0,0,0,0.45);
}
.service-icon {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(45deg, rgba(108,99,255,0.18), rgba(76,175,80,0.12));
    color: var(--primary-color);
    font-size: 1.4rem;
}
.service-card h3 {
    margin: 0;
    font-size: 1.15rem;
}
.service-card p {
    margin: 0;
    color: var(--text-secondary);
    flex: 1 1 auto;
}

/* visible state when scrolled into view */
.service-card.in-view {
    animation: dragInFromTop 0.8s ease-out forwards;
}

@media (max-width: 680px) {
    .services {
        padding: 2.5rem 1.5rem;
        margin-top: -3rem;
    }
    .services h2 {
        font-size: 1.8rem;
        margin-bottom: 0.4rem;
        opacity: 1 !important;
        transform: none !important;
    }
    .services h2.in-view {
        animation: none !important;
    }
    .services-sub {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
        opacity: 1 !important;
        transform: none !important;
    }
    .services-sub.in-view {
        animation: none !important;
    }
    .services-grid {
        gap: 0.6rem;
        margin-top: 1rem;
    }
    .service-card { 
        min-height: auto;
        padding: 1.2rem;
        gap: 0.6rem;
        transform: translateY(20px);
    }
    .service-card.in-view {
        animation: fadeInUp 0.5s ease-out forwards;
    }
    .service-icon { 
        width: 40px; 
        height: 40px; 
        font-size: 1rem;
        border-radius: 8px;
    }
    .service-card h3 {
        font-size: 1rem;
    }
    .service-card p {
        font-size: 0.85rem;
        line-height: 1.4;
    }
}

/* Reviews Section */
.reviews {
    padding: 5rem 2rem;
    background: rgba(32, 32, 32, 0.068);
    position: relative;
}

.reviews-container {
    max-width: 1400px;
    margin: 0 auto;
}

.reviews h2 {
    text-align: center;
    font-size: 2.8rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, #007bff, #00d4ff);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.reviews-sub {
    text-align: center;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
    margin-bottom: 3rem;
}

.reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;
    margin-top: 3rem;
}

.review-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 2.5rem;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.review-card:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-10px);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 15px 40px rgba(255, 255, 255, 0.1);
}

.review-card.in-view {
    opacity: 1;
    transform: translateY(0);
}

.review-stars {
    display: flex;
    gap: 0.3rem;
    align-items: center;
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: #ffd700;
}

.review-stars .rating-number {
    margin-left: 0.5rem;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
}

.review-stars .far.fa-star {
    color: rgba(255, 215, 0, 0.3);
}

.review-text {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 2rem;
    font-style: italic;
}

.review-author {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.author-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #007bff, #00d4ff);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    overflow: hidden;
}

.author-info {
    display: flex;
    flex-direction: column;
}

.author-info h4 {
    font-size: 1.1rem;
    margin: 0 0 0.3rem 0;
    color: white;
}

.author-info span {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.6);
}

.author-info .review-date {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 0.2rem;
}

/* View More button - hidden by default on desktop */
.view-more-btn {
    display: none !important;
}

@media (max-width: 1024px) {
    .reviews-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }
}

@media (max-width: 768px) {
    .reviews {
        padding: 2.5rem 1.5rem;
    }

    .reviews h2 {
        font-size: 1.8rem;
        margin-bottom: 0.5rem;
    }
    
    .reviews-sub {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }

    .reviews-grid {
        grid-template-columns: 1fr;
        gap: 0.8rem;
    }

    .review-card {
        padding: 1rem;
        border-radius: 10px;
        /* Animation initial state */
        opacity: 0;
        transform: translateY(20px);
        transition: none;
    }
    
    .review-card:hover {
        transform: translateY(20px);
        background: rgba(255, 255, 255, 0.08);
    }
    
    .review-card.in-view {
        animation: fadeInUp 0.5s ease-out forwards;
    }

    /* Hidden review cards on mobile */
    .review-card.hidden-review {
        display: none;
    }
    
    .review-stars {
        font-size: 0.85rem;
        margin-bottom: 0.8rem;
        gap: 0.15rem;
    }
    
    .review-text {
        font-size: 0.8rem;
        line-height: 1.4;
        margin-bottom: 0.8rem;
    }
    
    .review-author {
        font-size: 0.85rem;
    }
    
    .author-avatar {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }
    
    .author-info h4 {
        font-size: 0.9rem;
    }
    
    .author-info span {
        font-size: 0.75rem;
    }

    /* Hidden reviews on mobile */
    .hidden-review {
        display: none;
    }

    /* View More button for mobile */
    .view-more-btn {
        display: block !important;
        margin: 1.5rem auto 0;
        padding: 0.6rem 1.5rem;
        background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
        color: white;
        border: none;
        border-radius: 25px;
        font-size: 0.85rem;
        font-weight: 600;
        cursor: pointer;
        transition: transform 0.3s ease;
    }

    .view-more-btn:hover {
        transform: translateY(-2px);
    }
}

/* Skills Section */
.skills {
    padding: 5rem 2rem;
    position: relative;
}

.skills-container {
    max-width: 1400px;
    margin: 0 auto;
}

.skills h2 {
    text-align: center;
    font-size: 2.8rem;
    margin-bottom: 0.5rem;
    background: linear-gradient(45deg, #007bff, #00d4ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.skills-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 3rem;
}

.skills-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 3rem;
    padding: 1rem;
}

.skill-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 2rem 1.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.1);
    cursor: pointer;
    /* Start hidden for scroll animation */
    opacity: 0;
    transform: translateY(20px) scale(0.95);
}

.skill-card:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-8px) scale(1.05);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 10px 30px rgba(255, 255, 255, 0.1);
}

.skill-card img {
    width: 64px;
    height: 64px;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
    transition: transform 0.3s ease;
}

.skill-card:hover img {
    transform: scale(1.1) rotate(5deg);
}

.skill-card span {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text);
    text-align: center;
}

/* Skill card visible state */
.skill-card.in-view {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition: transform 420ms cubic-bezier(.2,.9,.2,1), opacity 360ms ease;
}

@media (max-width: 768px) {
    .skills {
        padding: 3rem 1.5rem;
    }

    .skills-container {
        max-width: 100%;
        margin: 0 auto;
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    
    .skills h2 {
        font-size: 1.8rem;
        margin-bottom: 0.5rem;
    }
    
    .skills-subtitle {
        font-size: 0.9rem;
        margin-bottom: 1.5rem;
    }
    
    .skills-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 0.8rem;
        padding: 1rem;
        background: rgba(255, 255, 255, 0.03);
        border-radius: 12px;
        border: 1px solid rgba(255, 255, 255, 0.08);
        justify-items: center;
        width: 100%;
        max-width: 100%;
        margin: 0 auto;
    }
    
    .skill-card {
        padding: 1rem 0.5rem;
        gap: 0.5rem;
        border-radius: 10px;
        width: 100%;
        max-width: 100%;
    }
    
    .skill-card img {
        width: 36px;
        height: 36px;
    }
    
    .skill-card span {
        font-size: 0.75rem;
        font-weight: 500;
    }
}

@media (max-width: 480px) {
    .skills-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 0.6rem;
        padding: 0.8rem;
        justify-items: center;
    }
    
    .skill-card {
        padding: 0.8rem 0.4rem;
        width: 100%;
        max-width: 100%;
    }
    
    .skill-card img {
        width: 32px;
        height: 32px;
    }
    
    .skill-card span {
        font-size: 0.7rem;
    }

    .typing-text {
        text-align: center;
        font-size: 0.65rem;
    }

    .cta-button {
        padding: 0.5rem 1.2rem;
        font-size: 0.8rem;
    }

    /* Floating 3D models - smaller and closer to button on mobile */
    #floating-models-container {
        height: 200px;
        margin-top: 1rem;
    }
}

/* Buttons */
.cta-button {
    display: inline-block;
    padding: 1rem 2rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: transform 0.3s;
}

.cta-button:hover {
    transform: translateY(-2px);
}

/* Team & Projects Grid */
/* Team & Projects Grid */
.team-row-first {
    display: flex;
    justify-content: center;
    gap: 1rem; /* reduced gap between the two prominent cards */
    margin-bottom: 2rem; /* pull the section up by reducing bottom space */
}

.team-row-first > .team-card {
    width: 400px;
    flex: 0 0 400px;
}

.team-row-remaining {
    display: grid;
    grid-template-columns: repeat(3, 400px);
    gap: 1rem; /* tighter spacing for remaining rows */
    justify-content: center;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.25rem;
    margin-top: 1.5rem; /* move team grid slightly up */
}

/* Projects grid: center rows, max 3 cards per row. Extra items wrap to next centered row. */
.projects-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center; /* center items in each row when there are fewer than 3 */
    /* cap width so at most 3 cards fit per row on wide screens (3 * 320px + gaps) */
    max-width: calc(3 * 320px + 2 * 2rem);
    margin-top: 3rem;
    margin-left: auto;
    margin-right: auto;
}

.project-card {
    /* fixed base width so at most 3 cards fit inside the .projects-grid max-width */
    flex: 0 0 320px; /* do not shrink below 320px on wide screens */
    min-width: 280px;
    max-width: 320px;
}

.team-card, .project-card {
    display: block;
    background: var(--surface);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(10px);
    /* keep hover transform */
    transition: transform 420ms cubic-bezier(.2,.9,.2,1), opacity 360ms ease;
}

/* Start team/project cards hidden for scroll animation */
.team-card {
    opacity: 0;
    transform: translateY(18px) scale(0.995);
}

.project-card {
    /* Projects page cards visible by default, animation will enhance but not block visibility */
    opacity: 1;
    transform: translateY(0);
}

/* visible state when team cards scroll into view */
.team-card.in-view {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* visible state when project cards scroll into view */
.project-card.in-view {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Center avatar image inside team cards */
.team-card > img {
    display: block;
    margin: 0 auto 1rem;
    width: 140px;
    height: 140px;
    object-fit: cover;
    border-radius: 50%;
}

.team-card:hover, .project-card:hover {
    transform: translateY(-5px);
}

/* Project Card Styling */
.project-card h3 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.project-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

/* Slightly round project images for a softer look */
.project-card img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 5px;
    object-fit: cover;
}

.project-card .tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.project-card .tag {
    padding: 0.25rem 0.75rem;
    background: rgba(108, 99, 255, 0.1);
    border-radius: 15px;
    font-size: 0.9rem;
    color: var(--primary-color);
    border: 1px solid rgba(108, 99, 255, 0.3);
}

.project-link {
    display: inline-block;
    padding: 0.6rem 1.5rem;
    background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
    color: white;
    text-decoration: none;
    border-radius: 25px;
    margin-top: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.project-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(108, 99, 255, 0.4);
}

/* Contact Section */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.contact-card {
    background: var(--surface);
    border-radius: 20px;
    padding: 2rem;
    text-align: center;
    text-decoration: none;
    color: var(--text);
    transition: transform 0.3s;
}

.contact-card:hover {
    transform: translateY(-5px);
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #007bff, #0056b3);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 123, 255, 0.4);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
}

.scroll-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(0, 123, 255, 0.6);
}

.scroll-to-top:active {
    transform: translateY(-2px);
}

/* Footer */
footer {
    text-align: center;
    padding: 2rem 1.5rem 1rem;
    background: var(--surface);
    backdrop-filter: blur(10px);
    margin-top: 6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    text-align: left;
    margin-bottom: 1.5rem;
}

.footer-section h3 {
    color: #007bff;
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.footer-section h4 {
    color: #007bff;
    font-size: 1rem;
    margin-bottom: 0.8rem;
}

.footer-section p {
    color: rgba(255, 255, 255, 0.8);
    margin: 0.4rem 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.footer-section i {
    color: #007bff;
    width: 18px;
    font-size: 0.9rem;
}

.footer-social {
    display: flex;
    gap: 0.8rem;
    flex-wrap: wrap;
}

.footer-social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    background: rgba(0, 123, 255, 0.1);
    border-radius: 50%;
    color: #007bff;
    font-size: 1rem;
    transition: all 0.3s ease;
    text-decoration: none;
    line-height: 1;
}

.footer-social a i {
    display: flex;
    align-items: center;
    justify-content: center;
}

.footer-social a:hover {
    background: #007bff;
    color: white;
    transform: translateY(-3px);
}

.footer-bottom {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.6);
    margin: 0;
    font-size: 0.85rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    header {
        padding: 0.75rem 1rem;
    }

    nav {
        flex-wrap: nowrap;
        position: relative;
    }

    /* Show hamburger menu */
    .mobile-menu-toggle {
        display: flex;
        order: 2;
        margin-left: auto;
    }

    /* Keep logo on left for all pages on mobile */
    nav {
        justify-content: flex-start;
    }

    .logo-container {
        order: 1;
        margin-right: auto;
    }

    .logo-symbol img {
        height: 32px;
    }

    .logo-text {
        font-size: 1.2rem;
    }

    /* Hide logo text on mobile for team, projects, and contact pages */
    .team-page .logo-text,
    .projects-page .logo-text,
    .contact-page .logo-text {
        display: none;
    }

    /* Force same header height on mobile for all pages */
    .team-page header,
    .projects-page header,
    .contact-page header {
        padding: 0.75rem 1rem !important;
    }

    .team-page .logo-symbol img,
    .projects-page .logo-symbol img,
    .contact-page .logo-symbol img {
        height: 32px !important;
    }

    /* Hide menu by default on mobile */
    nav ul {
        display: none !important;
        position: absolute;
        top: 100%;
        left: 50%;
        transform: translateX(-50%);
        width: 90%;
        max-width: 350px;
        background: linear-gradient(145deg, rgba(15, 15, 45, 0.98), rgba(20, 30, 80, 0.95));
        backdrop-filter: blur(20px);
        flex-direction: column;
        gap: 0.5rem;
        padding: 1rem;
        border: 2px solid rgba(0, 123, 255, 0.3);
        border-radius: 20px;
        box-shadow: 0 20px 60px rgba(0, 123, 255, 0.4), 
                    inset 0 1px 0 rgba(255, 255, 255, 0.1);
        animation: slideDownBounce 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
        z-index: 1000;
    }

    @keyframes slideDownBounce {
        0% {
            opacity: 0;
            transform: translateX(-50%) translateY(-20px) scale(0.9);
        }
        70% {
            transform: translateX(-50%) translateY(5px) scale(1.02);
        }
        100% {
            opacity: 1;
            transform: translateX(-50%) translateY(0) scale(1);
        }
    }

    /* Show menu when active */
    nav ul.mobile-menu-active {
        display: flex !important;
    }

    nav ul li {
        width: 100%;
        text-align: center;
        border-radius: 12px;
        transition: all 0.3s ease;
        position: relative;
        overflow: hidden;
        background: rgba(255, 255, 255, 0.03);
        margin: 0;
    }

    nav ul li::before {
        content: '';
        position: absolute;
        left: 50%;
        top: 50%;
        width: 0;
        height: 0;
        background: radial-gradient(circle, rgba(0, 123, 255, 0.3), transparent);
        border-radius: 50%;
        transform: translate(-50%, -50%);
        transition: width 0.4s ease, height 0.4s ease;
    }

    nav ul li:hover::before {
        width: 200%;
        height: 200%;
    }

    nav ul li:hover {
        background: rgba(0, 123, 255, 0.2);
        transform: translateY(-2px);
        box-shadow: 0 4px 15px rgba(0, 123, 255, 0.3);
    }

    nav a {
        padding: 1rem 1.5rem;
        font-size: 1rem;
        display: block;
        width: 100%;
        font-weight: 500;
        letter-spacing: 0.5px;
        transition: all 0.3s ease;
        position: relative;
        z-index: 1;
    }

    nav a.active {
        color: #00d4ff;
        background: rgba(0, 123, 255, 0.1);
    }

    nav a:hover {
        color: #00d4ff;
        padding-left: 1.5rem;
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    /* Team page mobile responsive */
    .team-hero h1 {
        font-size: 2.5rem !important;
    }

    .team-hero p {
        font-size: 1.1rem !important;
    }

    .team-row-first {
        flex-direction: column;
        align-items: center;
        gap: 1.5rem;
    }

    .team-row-first > .team-card {
        width: 100%;
        max-width: 350px;
        flex: 0 0 auto;
        padding: 1.2rem;
    }

    .team-row-remaining {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }

    .team-row-remaining .team-card {
        width: 100%;
        max-width: 350px;
        margin: 0 auto;
        padding: 1.2rem;
    }

    .team-card > img {
        width: 80px;
        height: 80px;
    }

    .team-card h3 {
        font-size: 1.1rem;
    }

    .team-card .role {
        font-size: 0.85rem;
    }

    .team-card p {
        font-size: 0.85rem;
    }

    /* For smaller screens allow projects to reflow to 2 or 1 columns */
    .projects-grid {
        max-width: none;
        gap: 1rem;
    }

    .project-card {
        flex: 1 1 calc(50% - 1rem);
        max-width: none;
        padding: 1.2rem;
    }

    .project-card h3 {
        font-size: 1.1rem;
    }

    .project-card p {
        font-size: 0.85rem;
    }

    .project-card img {
        height: 150px;
    }

    .project-card .tags {
        gap: 0.4rem;
        margin-top: 0.8rem;
    }

    .project-card .tag {
        font-size: 0.7rem;
        padding: 0.3rem 0.6rem;
    }
}

@media (max-width: 480px) {
    .team-hero h1 {
        font-size: 2rem !important;
    }

    .team-hero p {
        font-size: 1rem !important;
    }

    .project-card {
        flex: 1 1 100%;
        padding: 1rem;
    }

    .project-card img {
        height: 130px;
    }

    /* Footer mobile */
    footer {
        padding: 2rem 1rem 1rem;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .footer-section p {
        justify-content: center;
    }

    .footer-social {
        justify-content: center;
    }

    /* Scroll to top button mobile */
    .scroll-to-top {
        width: 45px;
        height: 45px;
        bottom: 1.5rem;
        right: 1.5rem;
        font-size: 1rem;
    }
}