/* CSS Variables for Theming */
:root {
    /* Base font size: 16px at 320px → 20px at 1400px */
    font-size: clamp(1rem, 0.92rem + 0.39vw, 1.25rem);
    
    /* Color Palette - Dark Mocha */
    --color-primary: #8b5a3c;
    --color-primary-dark: #5d3a22;
    --color-secondary: #a67c52;
    --color-accent: #d4a574;
    --color-bg: #1a1410;
    --color-text: #1f2937;
    --color-text-light: #6b7280;
    --color-border: #e5e7eb;
    
    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;
    
    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    
    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
        'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
        sans-serif;
    line-height: 1.6;
    color: #e8d5c4;
    background-color: var(--color-bg);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Typography */
h1 {
    /* Massive scale: 48px → 128px */
    font-size: clamp(3rem, 2.07rem + 4.63vw, 8rem);
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: var(--spacing-md);
}

h2 {
    font-size: clamp(1.5rem, 1.29rem + 1.04vw, 2.5rem);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: var(--spacing-sm);
}

p {
    margin-bottom: var(--spacing-sm);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
    width: 100%;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #2d1f16 0%, #4a3426 100%);
    color: #f5e6d3;
    padding: var(--spacing-xl) var(--spacing-sm);
    text-align: center;
    animation: fadeIn 1s ease-in;
    border-bottom: 2px solid #8b5a3c;
}

.tagline {
    font-size: clamp(1.125rem, 1.05rem + 0.37vw, 1.5rem);
    opacity: 0.9;
    color: #d4a574;
}

/* Portfolio Grid */
.portfolio-grid {
    flex: 1;
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--spacing-md);
    padding: var(--spacing-lg) var(--spacing-sm);
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Portfolio Card */
.portfolio-card {
    background: #2a1f18;
    border: 1px solid #4a3426;
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.4);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.portfolio-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.5), 0 0 0 2px #8b5a3c;
}

.card-content h2 {
    color: #d4a574;
}

.card-content p {
    color: #b89968;
    margin-bottom: var(--spacing-md);
}

/* CTA Button */
.cta-button {
    display: inline-block;
    background-color: #8b5a3c;
    color: #f5e6d3;
    padding: var(--spacing-xs) var(--spacing-md);
    border-radius: var(--radius-md);
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.2s ease;
    border: 1px solid #a67c52;
}

.cta-button:hover,
.cta-button:focus {
    background-color: #a67c52;
    transform: scale(1.05);
    outline: 2px solid #d4a574;
    outline-offset: 2px;
}

/* Footer */
.site-footer {
    background-color: var(--color-text);
    color: white;
    padding: var(--spacing-md) var(--spacing-sm);
    text-align: center;
    margin-top: auto;
}

.site-footer nav ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: var(--spacing-md);
    margin-top: var(--spacing-sm);
}

.site-footer a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.site-footer a:hover,
.site-footer a:focus {
    color: var(--color-accent);
    text-decoration: underline;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }

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

/* Tablet: 768px - 1024px */
@media (min-width: 768px) {
    .container {
        padding: 0 var(--spacing-md);
    }
    
    .portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop: 1024px+ */
@media (min-width: 1024px) {
    .portfolio-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Mobile Improvements */
@media (max-width: 767px) {
    .hero {
        padding: 3rem 1.5rem;
        min-height: 60vh;
    }

    .hero h1 {
        font-size: clamp(2rem, 8vw, 3rem);
        line-height: 1.2;
    }

    .tagline {
        font-size: 1.1rem;
        line-height: 1.6;
    }

    .portfolio-grid {
        gap: 1.5rem;
        padding: 1.5rem;
    }

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

    .card-content h2 {
        font-size: 1.75rem;
    }

    .card-content p {
        font-size: 1rem;
        line-height: 1.6;
    }

    /* Better touch targets for mobile */
    .cta-button {
        padding: 1rem 2rem;
        font-size: 1rem;
        min-height: 48px;
        width: 100%;
        text-align: center;
        display: block;
    }

    footer {
        padding: 2rem 1.5rem;
    }

    .social-links {
        gap: 1.5rem;
    }

    .social-links a {
        font-size: 2rem;
        padding: 0.75rem;
    }
}
