/* ========================================
   AdamAtlanta - Main Stylesheet
   Typography: Fluid with 1.250 Modular Scale
   ======================================== */

/* CSS Custom Properties */
:root {
    /* Color Palette - Earth Tones */
    --color-primary: #4a6741;        /* Forest Green */
    --color-primary-dark: #3d5536;   /* Darker Green */
    --color-primary-light: #5a7a50;  /* Lighter Green */
    --color-secondary: #b8894d;      /* Warm Gold */
    --color-secondary-dark: #9a7340; /* Darker Gold */
    --color-background: #f5f2eb;     /* Warm Cream */
    --color-background-alt: #ebe7dd; /* Slightly Darker Cream */
    --color-text: #2d3629;           /* Dark Green-Gray */
    --color-text-muted: #5c6358;     /* Muted Text */
    --color-text-light: #f5f2eb;     /* Light Text */
    --color-border: #d4cfc3;         /* Subtle Border */

    /* Modular Scale: 1.250 (Major Third) */
    /* Base: 1rem (16px) */
    --scale-ratio: 1.250;
    --font-size-sm: 0.8rem;                /* 12.8px */
    --font-size-base: 1rem;                /* 16px */
    --font-size-md: 1.25rem;               /* 20px */
    --font-size-lg: 1.563rem;              /* 25px */
    --font-size-xl: 1.953rem;              /* 31.25px */
    --font-size-2xl: 2.441rem;             /* 39px */
    --font-size-3xl: 3.052rem;             /* 48.8px */
    --font-size-4xl: 3.815rem;             /* 61px */

    /* Fluid Typography using clamp() */
    --fluid-sm: clamp(0.7rem, 0.65rem + 0.25vw, 0.8rem);
    --fluid-base: clamp(0.938rem, 0.875rem + 0.3vw, 1.125rem);
    --fluid-md: clamp(1.1rem, 1rem + 0.5vw, 1.25rem);
    --fluid-lg: clamp(1.25rem, 1rem + 1vw, 1.563rem);
    --fluid-xl: clamp(1.5rem, 1.2rem + 1.5vw, 1.953rem);
    --fluid-2xl: clamp(1.75rem, 1.3rem + 2vw, 2.441rem);
    --fluid-3xl: clamp(2rem, 1.5rem + 2.5vw, 3.052rem);
    --fluid-4xl: clamp(2.5rem, 1.75rem + 3.5vw, 3.815rem);

    /* Font Families */
    --font-display: 'Cormorant Garamond', Georgia, serif;
    --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

    /* Spacing Scale */
    --space-xs: clamp(0.5rem, 0.4rem + 0.5vw, 0.75rem);
    --space-sm: clamp(0.75rem, 0.6rem + 0.75vw, 1rem);
    --space-md: clamp(1rem, 0.8rem + 1vw, 1.5rem);
    --space-lg: clamp(1.5rem, 1rem + 2vw, 2.5rem);
    --space-xl: clamp(2rem, 1.5rem + 2.5vw, 4rem);
    --space-2xl: clamp(3rem, 2rem + 4vw, 6rem);

    /* Layout */
    --max-width: 72rem;
    --content-width: 60rem;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 250ms ease;
    --transition-slow: 400ms ease;

    /* Borders & Shadows */
    --border-radius: 0.5rem;
    --shadow-sm: 0 1px 3px rgba(45, 54, 41, 0.08);
    --shadow-md: 0 4px 12px rgba(45, 54, 41, 0.1);
    --shadow-lg: 0 8px 24px rgba(45, 54, 41, 0.12);
}

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

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-size: var(--fluid-base);
    font-weight: 400;
    line-height: 1.7;
    color: var(--color-text);
    background-color: var(--color-background);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-display);
    font-weight: 500;
    line-height: 1.2;
    color: var(--color-primary);
    letter-spacing: -0.02em;
}

h1 {
    font-size: var(--fluid-4xl);
    font-weight: 600;
}

h2 {
    font-size: var(--fluid-3xl);
}

h3 {
    font-size: var(--fluid-2xl);
}

h4 {
    font-size: var(--fluid-xl);
}

h5 {
    font-size: var(--fluid-lg);
}

h6 {
    font-size: var(--fluid-md);
}

p {
    font-size: var(--fluid-base);
    max-width: 65ch;
}

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

a:hover,
a:focus {
    color: var(--color-secondary-dark);
    text-decoration: underline;
}

/* Layout */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: var(--space-md);
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* Hero Section */
.hero {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-2xl) var(--space-md);
    min-height: 50vh;
}

.logo-container {
    margin-bottom: var(--space-lg);
}

.logo {
    width: clamp(180px, 30vw, 320px);
    height: auto;
    filter: drop-shadow(0 4px 12px rgba(74, 103, 65, 0.15));
    transition: transform var(--transition-base);
}

.logo:hover {
    transform: scale(1.02);
}

.tagline {
    font-family: var(--font-display);
    font-size: var(--fluid-lg);
    font-weight: 400;
    font-style: italic;
    color: var(--color-text-muted);
    max-width: 40ch;
}

/* Section Styles */
section {
    padding: var(--space-xl) 0;
}

.section-title {
    text-align: center;
    margin-bottom: var(--space-lg);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--color-secondary), var(--color-primary));
    margin: var(--space-sm) auto 0;
    border-radius: 2px;
}

/* About Section */
.about {
    text-align: center;
    max-width: var(--content-width);
    margin: 0 auto;
}

.about p {
    margin: 0 auto;
    color: var(--color-text-muted);
}

/* Projects Section */
.projects {
    max-width: var(--content-width);
    margin: 0 auto;
    width: 100%;
}

.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
    gap: var(--space-md);
    margin-top: var(--space-md);
}

.project-card {
    background: var(--color-background-alt);
    border-radius: var(--border-radius);
    padding: var(--space-lg);
    text-align: center;
    border: 1px solid var(--color-border);
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.project-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.project-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    background: var(--color-background);
    border-radius: 50%;
    margin-bottom: var(--space-sm);
    color: var(--color-primary);
}

.project-card h3 {
    font-size: var(--fluid-lg);
    margin-bottom: var(--space-xs);
    color: var(--color-primary);
}

.project-card p {
    font-size: var(--fluid-sm);
    color: var(--color-text-muted);
    margin: 0 auto;
}

/* Footer */
.footer {
    margin-top: auto;
    padding: var(--space-lg) var(--space-md);
    text-align: center;
    border-top: 1px solid var(--color-border);
}

.footer-content {
    max-width: var(--content-width);
    margin: 0 auto;
}

.copyright {
    font-size: var(--fluid-sm);
    color: var(--color-text-muted);
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Focus Styles */
:focus-visible {
    outline: 2px solid var(--color-secondary);
    outline-offset: 2px;
}

/* Selection Styles */
::selection {
    background: var(--color-primary);
    color: var(--color-text-light);
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }

    .logo {
        max-width: 200px;
    }
}
