/* 
 * styles.css
 * Shared stylesheet for The Baker public repository
 */

:root {
    --color-primary: #D4A373;
    --color-primary-dark: #B8956A;
    --color-background: #FEFAE0;
    --color-surface: #FFFFFF;
    --color-text: #2C2C2C;
    --color-text-muted: #6B6B6B;
    --color-accent: #E9EDC9;
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
    --radius-lg: 24px;
    --radius-md: 12px;
}

@media (prefers-color-scheme: dark) {
    :root {
        --color-primary: #D4A373;
        --color-primary-dark: #E6C2A0; /* Lighter for readability in dark mode */
        --color-background: #121212;
        --color-surface: #1E1E1E;
        --color-text: #E0E0E0;
        --color-text-muted: #9E9E9E;
        --color-accent: #2C2C2C;
        --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
    }
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: var(--color-background);
    color: var(--color-text);
    line-height: 1.6;
    padding-bottom: 60px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 40px 20px;
}

header {
    text-align: center;
    margin-bottom: 60px;
}

.logo-image {
    width: 120px;
    height: 120px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    margin-bottom: 24px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.logo-image:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

h1 {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--color-primary-dark);
    margin-bottom: 12px;
    transition: color 0.3s ease;
}

.tagline {
    font-size: 1.25rem;
    color: var(--color-text-muted);
    font-weight: 500;
    max-width: 600px;
    margin: 0 auto 24px;
    transition: color 0.3s ease;
}

.download-badges {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 24px;
}

.badge img {
    height: 48px;
    transition: transform 0.2s ease;
}

.badge:hover img {
    transform: scale(1.05);
}

.section {
    background: var(--color-surface);
    border-radius: var(--radius-md);
    padding: 40px;
    margin-bottom: 40px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    transition: background-color 0.3s ease, box-shadow 0.3s ease;
}

@media (prefers-color-scheme: dark) {
    .section {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    }
}

h2 {
    font-size: 1.75rem;
    margin-bottom: 24px;
    color: var(--color-text);
    text-align: center;
    transition: color 0.3s ease;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
    opacity: 0; /* Starting state for the animation */
}

/* Staggering delays - optional class additions */
.delay-100 { animation-delay: 100ms; }
.delay-200 { animation-delay: 200ms; }
.delay-300 { animation-delay: 300ms; }
.delay-400 { animation-delay: 400ms; }

/* Screenshots */
.screenshots {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin: 32px 0;
}

.screenshot {
    width: 100%;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    animation: fadeInUp 0.5s ease-out forwards;
}

.screenshot:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* Features */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.feature-card {
    padding: 20px;
    border-radius: var(--radius-md);
    background: rgba(0, 0, 0, 0.02);
    transition: transform 0.3s ease, background-color 0.3s ease;
    animation: fadeInUp 0.5s ease-out forwards;
}

@media (prefers-color-scheme: dark) {
    .feature-card {
        background: rgba(255, 255, 255, 0.03);
    }
}

.feature-card:hover {
    transform: translateY(-4px);
    background: rgba(0, 0, 0, 0.04);
}

@media (prefers-color-scheme: dark) {
    .feature-card:hover {
        background: rgba(255, 255, 255, 0.05);
    }
}

.feature-card h3 {
    color: var(--color-primary-dark);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    transition: color 0.3s ease;
}

.feature-card p {
    color: var(--color-text-muted);
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

/* Nav Footer */
.footer {
    text-align: center;
    padding: 40px 0;
    border-top: 1px solid var(--color-accent);
    transition: border-color 0.3s ease;
}

.footer-nav {
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    gap: 24px;
    flex-wrap: wrap;
}

.footer-nav a {
    color: var(--color-primary-dark);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.footer-nav a:hover {
    color: var(--color-text);
    opacity: 0.8;
}

.copyright {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

@media (max-width: 600px) {
    h1 {
        font-size: 2rem;
    }

    .section {
        padding: 24px;
    }

    .screenshots {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Shared typography rules for Markdown-generated pages */
.policy-content h1 {
    font-size: 2em;
    border-bottom: 2px solid var(--color-accent);
    padding-bottom: 0.3em;
    margin-bottom: 16px;
    color: var(--color-text);
}

.policy-content h2 {
    font-size: 1.5em;
    margin-top: 24px;
    margin-bottom: 16px;
    text-align: left;
    border-bottom: 1px solid var(--color-accent);
    padding-bottom: 0.3em;
}

.policy-content h3 {
    font-size: 1.25em;
    margin-top: 24px;
    margin-bottom: 16px;
    font-weight: 600;
}

.policy-content p {
    margin-top: 0;
    margin-bottom: 16px;
    color: var(--color-text-muted);
}

.policy-content ul {
    padding-left: 2em;
    margin-bottom: 16px;
    color: var(--color-text-muted);
}

.policy-content li {
    margin-bottom: 0.5em;
}

.policy-content a {
    color: var(--color-primary-dark);
    text-decoration: none;
    font-weight: 500;
}

.policy-content a:hover {
    text-decoration: underline;
}

.policy-content .effective-date {
    color: var(--color-text-muted);
    font-style: italic;
    margin-bottom: 30px;
    display: block;
}
