/* CSS Custom Properties */
:root {
    /* Colors using HSL format */
    --primary-text: 210 11% 15%; /* Dark gray for text */
    --secondary-text: 210 8% 45%; /* Medium gray for secondary text */
    --muted-text: 210 6% 60%; /* Light gray for muted text */
    --background: 210 11% 98%; /* Light off-white background */
    --card-background: 0 0% 100%; /* Pure white for cards */
    --border-color: 210 16% 93%; /* Light gray border */
    --accent-blue: 210 100% 56%; /* Blue accent color */
    --accent-orange: 25 95% 53%; /* Orange accent color */
    --green-primary: 158 64% 52%; /* Green for primary button */
    --green-hover: 158 64% 47%; /* Darker green for hover */
    
    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-size-base: 16px;
    --font-size-lg: 18px;
    --font-size-xl: 24px;
    --font-size-2xl: 32px;
    --font-size-3xl: 48px;
    --line-height-tight: 1.25;
    --line-height-normal: 1.5;
    --line-height-relaxed: 1.625;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;
    --spacing-3xl: 6rem;
    
    /* Layout */
    --container-max-width: 1200px;
    --border-radius: 8px;
    --border-radius-lg: 12px;
}

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

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: var(--line-height-normal);
    color: hsl(var(--primary-text));
    background-color: hsl(var(--background));
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Navigation Styles */
.navbar {
    background-color: hsl(var(--card-background));
    border-bottom: 1px solid hsl(var(--border-color));
    position: sticky;
    top: 0;
    z-index: 100;
    padding: var(--spacing-sm) 0;
}

.nav-container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo .logo-text {
    font-size: var(--font-size-xl);
    font-weight: 700;
    color: hsl(var(--primary-text));
    text-decoration: none;
    transition: color 0.2s ease;
}

.nav-logo .logo-text:hover {
    color: hsl(var(--accent-orange));
}

.nav-menu {
    display: flex;
    gap: var(--spacing-lg);
}

.nav-link {
    color: hsl(var(--secondary-text));
    text-decoration: none;
    font-weight: 500;
    padding: var(--spacing-xs) var(--spacing-sm);
    border-radius: var(--border-radius);
    transition: all 0.2s ease;
}

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

/* Hero Section */
.hero-section {
    padding: var(--spacing-lg) 0;
    background-color: hsl(var(--background));
}

.hero-container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-headshot {
    margin-bottom: var(--spacing-xl);
}

.headshot-image {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    border: 3px solid hsl(var(--accent-orange));
    object-fit: cover;
    display: block;
    margin: 0 auto;
}

.hero-bio {
    max-width: 600px;
    margin: 0 auto;
}

.bio-text {
    font-size: var(--font-size-lg);
    color: hsl(var(--secondary-text));
    line-height: var(--line-height-relaxed);
    text-align: center;
}

/* Button Styles */
.btn {
    display: inline-flex;
    align-items: center;
    padding: var(--spacing-sm) var(--spacing-md);
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 500;
    font-size: var(--font-size-base);
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background-color: hsl(var(--green-primary));
    color: white;
}

.btn-primary:hover {
    background-color: hsl(var(--green-hover));
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: hsl(var(--accent-orange));
    color: white;
}

.btn-secondary:hover {
    background-color: hsl(25 95% 48%);
    transform: translateY(-1px);
}

/* Featured Applications Section */
.featured-section {
    padding: var(--spacing-xl) 0;
    background-color: hsl(var(--card-background));
}

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

.section-title {
    font-size: var(--font-size-2xl);
    font-weight: 400;
    color: hsl(var(--secondary-text));
    margin-bottom: var(--spacing-sm);
}

.section-underline {
    width: 60px;
    height: 3px;
    background-color: hsl(var(--accent-orange));
    margin-bottom: var(--spacing-lg);
}

.section-description {
    font-size: var(--font-size-base);
    color: hsl(var(--secondary-text));
    margin-bottom: var(--spacing-xl);
    line-height: var(--line-height-relaxed);
}

.note-text {
    color: hsl(var(--accent-orange));
    font-style: italic;
}

/* Projects Grid */
.projects-grid {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
    margin-top: var(--spacing-xl);
}

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

.project-card {
    border-radius: var(--border-radius-lg);
    padding: 0;
    transition: all 0.3s ease;
    cursor: pointer;
    overflow: hidden;
    display: flex;
    gap: var(--spacing-lg);
    align-items: center;
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1);
}

.project-thumbnail {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    order: 2;
}

.thumbnail-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius);
}

.thumbnail-text {
    font-size: 3rem;
    opacity: 0.8;
}

.project-content {
    flex: 1;
    padding: var(--spacing-lg);
    order: 1;
}

.project-header {
    margin-bottom: var(--spacing-md);
}

.project-title {
    font-size: var(--font-size-lg);
    font-weight: 600;
    color: hsl(var(--primary-text));
    margin-bottom: var(--spacing-xs);
    line-height: var(--line-height-tight);
}

.project-description {
    color: hsl(var(--secondary-text));
    line-height: var(--line-height-relaxed);
    font-size: var(--font-size-base);
}

/* Color variations for project cards */
.project-card-blue {
    background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
    border: 1px solid #93c5fd;
}

.project-card-blue:hover {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
    box-shadow: 0 12px 24px rgba(59, 130, 246, 0.2);
}

.project-card-green {
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 1px solid #6ee7b7;
}

.project-card-green:hover {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
    box-shadow: 0 12px 24px rgba(16, 185, 129, 0.2);
}

.project-card-purple {
    background: linear-gradient(135deg, #faf5ff 0%, #e9d5ff 100%);
    border: 1px solid #c4b5fd;
}

.project-card-purple:hover {
    background: linear-gradient(135deg, #e9d5ff 0%, #ddd6fe 100%);
    box-shadow: 0 12px 24px rgba(139, 92, 246, 0.2);
}

.project-card-orange {
    background: linear-gradient(135deg, #fff7ed 0%, #fed7aa 100%);
    border: 1px solid #fdba74;
}

.project-card-orange:hover {
    background: linear-gradient(135deg, #fed7aa 0%, #fbbf24 100%);
    box-shadow: 0 12px 24px rgba(249, 115, 22, 0.2);
}

.project-card-teal {
    background: linear-gradient(135deg, #f0fdfa 0%, #ccfbf1 100%);
    border: 1px solid #5eead4;
}

.project-card-teal:hover {
    background: linear-gradient(135deg, #ccfbf1 0%, #99f6e4 100%);
    box-shadow: 0 12px 24px rgba(20, 184, 166, 0.2);
}

/* Footer */
.footer {
    background-color: hsl(var(--background));
    border-top: 1px solid hsl(var(--border-color));
    padding: var(--spacing-lg) 0;
    margin-top: var(--spacing-3xl);
}

.footer-container {
    max-width: var(--container-max-width);
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    text-align: center;
}

.footer p {
    color: hsl(var(--muted-text));
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 var(--spacing-sm);
    }
    
    .nav-menu {
        gap: var(--spacing-md);
    }
    
    .hero-container,
    .featured-container {
        padding: 0 var(--spacing-sm);
    }
    
    .headshot-image {
        width: 150px;
        height: 150px;
    }
    
    .bio-text {
        font-size: var(--font-size-base);
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .projects-grid {
        gap: var(--spacing-md);
    }
    
    .project-card {
        flex-direction: column;
        text-align: center;
    }
    
    .project-thumbnail {
        width: 100px;
        height: 100px;
        order: 1;
    }
    
    .project-content {
        order: 2;
    }
    
    .thumbnail-text {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .nav-menu {
        gap: var(--spacing-sm);
    }
    
    .nav-link {
        padding: var(--spacing-xs);
        font-size: 14px;
    }
    
    .headshot-image {
        width: 120px;
        height: 120px;
    }
    
    .section-title {
        font-size: var(--font-size-xl);
    }
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus styles for accessibility */
.nav-link:focus,
.btn:focus,
.project-card:focus {
    outline: 2px solid hsl(var(--accent-blue));
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .navbar,
    .hero-buttons,
    .footer {
        display: none;
    }
    
    .hero-section {
        padding: var(--spacing-lg) 0;
    }
    
    .project-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid hsl(var(--border-color));
    }
}
