/* ==========================================================================
   Thomas Poisvert — Portfolio Hub Stylesheet
   Design System: Dark, Glassmorphism, Neon Glow & High-End Interactions
   ========================================================================== */

/* 1. VARIABLES & DESIGN TOKENS */
:root {
    /* Colors */
    --color-bg: #07090e;
    --color-surface: rgba(255, 255, 255, 0.03);
    --color-surface-hover: rgba(255, 255, 255, 0.06);
    --color-border: rgba(255, 255, 255, 0.08);
    --color-border-glow: rgba(59, 130, 246, 0.25);
    
    --color-text-primary: #f3f4f6;
    --color-text-secondary: #9ca3af;
    --color-text-muted: #6b7280;
    
    /* Neon Accents */
    --color-primary: #3b82f6;          /* Neon Blue */
    --color-primary-rgb: 59, 130, 246;
    --color-secondary: #10b981;        /* Emerald Green */
    --color-secondary-rgb: 16, 185, 129;
    --color-accent-pink: #ec4899;       /* Pink Accent for tags */
    --color-accent-orange: #f59e0b;     /* Gold Accent */
    
    /* Typography */
    --font-headings: 'Outfit', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    
    /* Animations */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-normal: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    
    /* Layout */
    --container-width: 1200px;
    --header-height: 80px;
}

/* 2. RESET & BASE STYLES */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    background-color: var(--color-bg);
}

body {
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: var(--color-bg);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    border: 2px solid var(--color-bg);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--color-primary);
}

/* Core Container */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

/* 3. VISUAL DECORATIONS (AMBIENT GLOW) */
.glow-bg {
    position: fixed;
    width: 600px;
    height: 600px;
    border-radius: 50%;
    pointer-events: none;
    z-index: -2;
    filter: blur(130px);
    opacity: 0.45;
    mix-blend-mode: screen;
    transition: transform var(--transition-slow);
}

#glow-bg-1 {
    background: radial-gradient(circle, rgba(var(--color-primary-rgb), 0.25) 0%, rgba(var(--color-primary-rgb), 0.05) 75%, transparent 100%);
    top: -200px;
    right: -100px;
}

#glow-bg-2 {
    background: radial-gradient(circle, rgba(var(--color-secondary-rgb), 0.2) 0%, rgba(var(--color-secondary-rgb), 0.02) 75%, transparent 100%);
    bottom: -150px;
    left: -150px;
}

/* Tech Grid Background Overlay */
.grid-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(to right, rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 60px 60px;
    z-index: -1;
    pointer-events: none;
}

/* 4. HEADER & NAVIGATION */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(7, 9, 14, 0.7);
    border-bottom: 1px solid var(--color-border);
    backdrop-filter: blur(12px) saturate(120%);
    z-index: 100;
    transition: transform var(--transition-normal), background var(--transition-normal);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 2rem;
}

.logo-link {
    font-family: var(--font-headings);
    font-size: 1.4rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: var(--color-text-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

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

.main-nav ul {
    display: flex;
    gap: 2.5rem;
    list-style: none;
}

.nav-link {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    text-decoration: none;
    transition: color var(--transition-fast);
    position: relative;
    padding: 0.5rem 0;
}

.nav-link:hover, .nav-link.active {
    color: var(--color-text-primary);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-primary);
    box-shadow: 0 0 8px var(--color-primary);
    transition: width var(--transition-normal);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

/* 5. BUTTON STYLES */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-family: var(--font-headings);
    font-size: 0.95rem;
    font-weight: 600;
    padding: 0.8rem 1.6rem;
    border-radius: 8px;
    text-decoration: none;
    cursor: pointer;
    transition: all var(--transition-normal);
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--color-primary) 0%, #2563eb 100%);
    color: #ffffff;
    border: none;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.5);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--color-text-primary);
    border: 1px solid var(--color-border);
    backdrop-filter: blur(8px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--color-text-primary);
    border: 1px solid var(--color-border);
}

.btn-outline:hover {
    border-color: var(--color-primary);
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
    color: #ffffff;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    border-radius: 6px;
}

.icon-download {
    transition: transform var(--transition-fast);
}

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

/* 6. HERO SECTION */
.hero-section {
    padding-top: calc(var(--header-height) + 5rem);
    padding-bottom: 6rem;
    position: relative;
}

.hero-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    max-width: 900px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    background: rgba(59, 130, 246, 0.08);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 20px;
    padding: 0.4rem 1rem;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    color: var(--color-primary);
    margin-bottom: 2rem;
    font-family: var(--font-headings);
    animation: fadeInDown var(--transition-slow) both;
}

.pulse-dot {
    width: 6px;
    height: 6px;
    background-color: var(--color-primary);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--color-primary);
    animation: pulse 2s infinite;
}

.hero-title {
    font-family: var(--font-headings);
    font-size: 4rem;
    font-weight: 800;
    line-height: 1.15;
    letter-spacing: -1px;
    color: #ffffff;
    margin-bottom: 1.5rem;
    animation: fadeInUp var(--transition-slow) 0.1s both;
}

.gradient-text {
    background: linear-gradient(to right, #ffffff 20%, #93c5fd 60%, var(--color-primary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-secondary);
    max-width: 680px;
    margin-bottom: 3rem;
    font-weight: 300;
    line-height: 1.7;
    animation: fadeInUp var(--transition-slow) 0.2s both;
}

.hero-actions {
    display: flex;
    gap: 1.5rem;
    animation: fadeInUp var(--transition-slow) 0.3s both;
}

/* 7. PROJECTS SECTION & CARDS GRID */
.projects-section {
    padding: 6rem 0;
    position: relative;
}

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

.section-category {
    font-family: var(--font-headings);
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--color-primary);
    display: block;
    margin-bottom: 0.5rem;
}

.section-title {
    font-family: var(--font-headings);
    font-size: 2.5rem;
    font-weight: 800;
    color: #ffffff;
    margin-bottom: 1rem;
}

.section-desc {
    font-size: 1.05rem;
    color: var(--color-text-secondary);
    max-width: 550px;
    margin: 0 auto;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

/* Glassmorphism Project Card */
.project-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 16px;
    padding: 2.2rem;
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(16px) saturate(120%);
    transition: transform var(--transition-normal), border-color var(--transition-normal), box-shadow var(--transition-normal);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    min-height: 320px;
}

.project-card:hover {
    border-color: var(--color-border-glow);
    box-shadow: 0 10px 30px rgba(59, 130, 246, 0.08);
}

/* Mouse cursor hover glow effect */
.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(800px circle at var(--mouse-x, 0px) var(--mouse-y, 0px), rgba(255, 255, 255, 0.04), transparent 40%);
    z-index: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

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

.card-glow {
    position: absolute;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(59, 130, 246, 0.06) 0%, transparent 70%);
    top: -150px;
    left: -150px;
    pointer-events: none;
    z-index: 0;
    transition: transform var(--transition-normal);
}

.project-card:hover .card-glow {
    transform: translate(20px, 20px) scale(1.2);
}

.card-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    height: 100%;
}

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

.project-tag {
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 0.3rem 0.8rem;
    border-radius: 12px;
}

.tag-web {
    background: rgba(16, 185, 129, 0.08);
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: var(--color-secondary);
}

.tag-saas {
    background: rgba(245, 158, 11, 0.08);
    border: 1px solid rgba(245, 158, 11, 0.2);
    color: var(--color-accent-orange);
}

.tag-eng {
    background: rgba(59, 130, 246, 0.08);
    border: 1px solid rgba(59, 130, 246, 0.2);
    color: var(--color-primary);
}

.tag-software {
    background: rgba(236, 72, 153, 0.08);
    border: 1px solid rgba(236, 72, 153, 0.2);
    color: var(--color-accent-pink);
}

.tag-brand {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--color-text-primary);
}

.tag-admin {
    background: rgba(139, 92, 246, 0.08);
    border: 1px solid rgba(139, 92, 246, 0.2);
    color: #a78bfa;
}

.tag-cad {
    background: rgba(0, 240, 255, 0.08);
    border: 1px solid rgba(0, 240, 255, 0.2);
    color: #00f0ff;
}

.tag-archived {
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.project-date {
    font-size: 0.75rem;
    color: var(--color-text-muted);
}

.project-name {
    font-family: var(--font-headings);
    font-size: 1.5rem;
    font-weight: 700;
    color: #ffffff;
}

.project-image {
    width: 100%;
    height: 150px;
    border-radius: 8px;
    overflow: hidden;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    border: 1px solid var(--color-border);
    background: rgba(0, 0, 0, 0.2);
}

.project-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-normal);
}

.project-card:hover .project-image img {
    transform: scale(1.05);
}

.project-description {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    line-height: 1.5;
    flex-grow: 1;
}

.project-tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: auto;
}

.project-tech-stack span {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
}

.project-links {
    margin-top: 1.5rem;
}

.project-link-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.primary-link {
    color: var(--color-primary);
}

.primary-link:hover {
    color: #ffffff;
}

.primary-link svg {
    transition: transform var(--transition-fast);
}

.primary-link:hover svg {
    transform: translate(2px, -2px);
}

.project-status-info {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    font-style: italic;
}

/* 8. ABOUT / PROFILE SECTION */
.about-section {
    padding: 6rem 0;
    border-top: 1px solid var(--color-border);
    position: relative;
}

.about-container {
    max-width: var(--container-width);
}

.about-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 4rem;
    align-items: center;
}

.about-subtitle {
    font-family: var(--font-headings);
    font-size: 1.6rem;
    font-weight: 600;
    color: var(--color-primary);
    margin-bottom: 1.5rem;
}

.about-paragraph {
    font-size: 1.05rem;
    color: var(--color-text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.skills-mini-list {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
    margin-top: 2.5rem;
}

.skill-category h4 {
    font-family: var(--font-headings);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #ffffff;
    margin-bottom: 0.4rem;
}

.skill-category p {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
}

/* Visual avatar placeholder/cards */
.about-card-visual {
    position: relative;
    height: 400px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 1.5rem;
}

.avatar-glow {
    position: absolute;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(var(--color-primary-rgb), 0.15) 0%, transparent 70%);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    filter: blur(20px);
    z-index: 0;
    pointer-events: none;
}

.about-badge-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    backdrop-filter: blur(12px);
    z-index: 1;
    transition: transform var(--transition-normal);
}

.about-badge-card:hover {
    transform: translateX(10px);
    border-color: var(--color-border-glow);
}

.secondary-badge {
    align-self: flex-end;
    width: 90%;
    background: rgba(255, 255, 255, 0.04);
}

.badge-icon {
    font-size: 2rem;
}

.badge-texts {
    display: flex;
    flex-direction: column;
}

.badge-number {
    font-family: var(--font-headings);
    font-size: 1.3rem;
    font-weight: 700;
    color: #ffffff;
}

.badge-label {
    font-size: 0.8rem;
    color: var(--color-text-secondary);
}

/* 9. CONTACT SECTION */
.contact-section {
    padding: 6rem 0;
    border-top: 1px solid var(--color-border);
}

.contact-box {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: 20px;
    padding: 4rem;
    backdrop-filter: blur(16px);
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.contact-subtitle {
    font-size: 1.1rem;
    color: var(--color-text-secondary);
    margin-bottom: 3rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

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

.contact-method-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 2rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: var(--color-text-primary);
    transition: all var(--transition-normal);
}

.contact-method-card:hover:not(.no-click) {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--color-primary);
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(59, 130, 246, 0.05);
}

.contact-method-card.no-click {
    cursor: default;
}

.contact-icon {
    width: 50px;
    height: 50px;
    background: rgba(59, 130, 246, 0.08);
    color: var(--color-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.contact-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--color-text-muted);
}

.contact-value {
    font-size: 0.95rem;
    font-weight: 600;
}

/* 10. FOOTER */
.main-footer {
    background: #040508;
    border-top: 1px solid var(--color-border);
    padding: 3rem 0;
    font-size: 0.9rem;
    color: var(--color-text-muted);
}

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

.footer-links {
    display: flex;
    gap: 1.5rem;
    align-items: center;
}

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

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

.footer-dot {
    color: rgba(255, 255, 255, 0.1);
}

.footer-signature {
    font-size: 0.8rem;
    font-style: italic;
    color: var(--color-text-muted);
}

/* 11. ANIMATIONS */
@keyframes pulse {
    0% {
        transform: scale(0.9);
        box-shadow: 0 0 0 0 rgba(var(--color-primary-rgb), 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 8px rgba(var(--color-primary-rgb), 0);
    }
    100% {
        transform: scale(0.9);
        box-shadow: 0 0 0 0 rgba(var(--color-primary-rgb), 0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(25px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-25px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 12. RESPONSIVE MEDIA QUERIES */
@media (max-width: 1024px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .about-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    .about-card-visual {
        height: auto;
        flex-direction: row;
        flex-wrap: wrap;
    }
    .about-badge-card {
        flex: 1;
        min-width: 250px;
    }
    .secondary-badge {
        align-self: flex-start;
        width: auto;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }
    
    .hero-title {
        font-size: 2.8rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .main-nav {
        display: none; /* Mobile menu can be simplified for this single hub page */
    }
    
    .contact-methods {
        flex-direction: column;
        gap: 1.2rem;
    }
    
    .contact-box {
        padding: 2.5rem 1.5rem;
    }
    
    .hero-actions {
        flex-direction: column;
        width: 100%;
        gap: 1rem;
    }
    
    .hero-actions .btn {
        width: 100%;
    }
    
    .header-cta-wrapper {
        margin-left: auto;
    }
}

/* 13. SCROLL REVEAL ANIMATIONS */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), 
                transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}
