/*
 * Digital Garden - Main Stylesheet
 * Aligned with Material Design principles & Modern Web Standards
 */

:root {
    --primary-color: #2D5A27;
    --primary-variant: #1B3022;
    --secondary-color: #388E3C; /* Darkened for better contrast against white text */
    --background-color: #ffffff;
    --surface-color: #F1F8E9;
    --on-surface-color: #333333;
    --text-color: #333333;
    --white: #ffffff;
    --shadow: 0 8px 20px rgba(0,0,0,0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Accessibility: Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1 !important;
        transform: none !important;
        transition: none !important;
    }
    * {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* --- Custom Themed Scrollbar --- */
::-webkit-scrollbar {
    width: 10px;
}
::-webkit-scrollbar-track {
    background: var(--surface-color);
}
::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 5px;
    border: 2px solid var(--surface-color);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* --- Improved Focus States for Accessibility --- */
:focus-visible {
    outline: 3px solid var(--secondary-color);
    outline-offset: 4px;
}

/* --- Reveal on Scroll --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* --- Slider Dots --- */
.slider-dots {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-top: 25px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ccc;
    cursor: pointer;
    border: none;
    padding: 0;
    transition: var(--transition);
}

.dot:hover {
    background: #999;
}

.dot.active {
    background: var(--primary-color);
    transform: scale(1.2);
}

/* --- Final CTA --- */
.cta-bottom-section {
    padding: 100px 0;
    text-align: center;
    background: linear-gradient(135deg, var(--surface-color), #ffffff);
}

.cta-bottom-section h2 {
    font-size: 2.2rem;
    color: var(--primary-variant);
    margin-bottom: 15px;
}

.cta-bottom-section p {
    font-size: 1.1rem;
    margin-bottom: 35px;
    opacity: 0.8;
}

/* --- Dark Mode Support --- */
@media (prefers-color-scheme: dark) {
    :root {
        --background-color: #121212;
        --surface-color: #1e1e1e;
        --on-surface-color: #e0e0e0;
        --text-color: #e0e0e0;
    }

    body { background-color: var(--background-color); }

    .feature-card {
        background: #1e1e1e;
        border-color: rgba(255,255,255,0.05);
    }

    .feature-card h3 { color: var(--secondary-color); }

    .screenshots-section { background-color: #181818; }

    .screenshot-item img { border-color: #333; }

    .cta-bottom-section {
        background: linear-gradient(135deg, #1a1a1a, #121212);
    }

    .cta-bottom-section h2 { color: var(--white); }

    .social-proof.dark .badge {
        background: rgba(255, 255, 255, 0.1);
        color: var(--white);
        border: 2px solid rgba(255, 255, 255, 0.2);
    }
}

/* --- Accessibility: Skip to content --- */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px;
    z-index: 1000;
}
.skip-link:focus { top: 0; }

/* --- Language Selector --- */
.lang-selector {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
}

.lang-selector select {
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255,255,255,0.3);
    background: rgba(0,0,0,0.2);
    color: var(--white);
    cursor: pointer;
    font-weight: 600;
    backdrop-filter: blur(4px);
    outline: none;
}

.lang-selector select option { color: #333; }

/* --- Header --- */
header {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    padding: 80px 20px;
    text-align: center;
    position: relative;
}

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

.logo {
    width: 110px;
    height: 110px;
    background: var(--white);
    border-radius: 24px;
    padding: 10px;
    box-shadow: var(--shadow);
    margin-bottom: 24px;
    transition: var(--transition);
}

.logo:hover {
    transform: scale(1.05) rotate(2deg);
}

h1 {
    font-size: clamp(2.5rem, 6vw, 3.5rem);
    margin: 10px 0;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 20px; /* Reduced from 30px to fit social proof */
    max-width: 750px;
    margin: 0 auto 20px auto;
    font-weight: 400;
}

/* --- Social Proof Badges --- */
.social-proof {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.social-proof .badge {
    background: rgba(255, 255, 255, 0.2);
    color: var(--white);
    padding: 10px 20px;
    border-radius: 50px;
    font-size: 0.95rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 10px;
    backdrop-filter: blur(8px);
    border: 2px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.social-proof .badge i {
    color: #FFD700; /* Gold for stars and check-circles */
}

.social-proof.dark .badge {
    background: rgba(45, 90, 39, 0.08);
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.play-store-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #000;
    color: var(--white);
    padding: 16px 32px;
    border-radius: 14px;
    text-decoration: none;
    font-weight: 700;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.play-store-badge:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* --- Features Grid --- */
.features-section { padding: 80px 0; }

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    justify-items: center;
}

.feature-card {
    width: 100%;
    max-width: 380px;
    text-align: center;
    padding: 45px 30px;
    background: var(--surface-color);
    border-radius: 32px;
    transition: var(--transition);
    border: 1px solid rgba(0,0,0,0.03);
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.08);
}

.feature-card i {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 24px;
}

.feature-card h3 {
    margin-bottom: 14px;
    color: var(--primary-variant);
    font-size: 1.5rem;
}

/* --- Carousel Section --- */
.screenshots-section {
    background-color: #fcfdfa;
    padding: 100px 0;
    text-align: center;
}

.slider-wrapper {
    position: relative;
    margin: 50px auto 0 auto;
    width: 100%;
    max-width: 1050px;
    display: flex;
    align-items: center;
}

.screenshot-container {
    display: flex;
    overflow-x: auto;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 35px;
    padding: 20px 10px 50px 10px;
    width: 100%;
    scrollbar-width: none; /* Firefox */
}

.screenshot-container::-webkit-scrollbar { display: none; }

.screenshot-item {
    flex-shrink: 0;
    width: 290px;
    scroll-snap-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.screenshot-item img {
    height: 540px;
    width: auto;
    border-radius: 24px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.12);
    border: 6px solid var(--white);
    margin-bottom: 20px;
    user-select: none;
}

.screenshot-caption {
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    max-width: 260px;
    line-height: 1.3;
}

/* Navigation Buttons */
.nav-btn {
    position: absolute;
    top: 45%;
    transform: translateY(-50%);
    background: var(--primary-color);
    color: var(--white);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    z-index: 20;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 15px rgba(0,0,0,0.25);
    transition: var(--transition);
}

.nav-btn:hover {
    background: var(--secondary-color);
    transform: translateY(-50%) scale(1.1);
}

.nav-btn:active { transform: translateY(-50%) scale(0.95); }

.nav-btn.left { left: 10px; }
.nav-btn.right { right: 10px; }

@media (min-width: 1200px) {
    .nav-btn.left { left: -70px; }
    .nav-btn.right { right: -70px; }
}

@media (max-width: 768px) {
    header { padding: 60px 20px; }
    .screenshot-container img { height: 440px; }
    .screenshot-item { width: 240px; }
    .nav-btn {
        width: 44px;
        height: 44px;
        background: rgba(45, 90, 39, 0.85);
    }
}

/* --- Privacy Policy Specifics --- */
.privacy-body {
    max-width: 850px;
    margin: 0 auto;
    padding: 60px 24px;
}

.privacy-header {
    margin-bottom: 40px;
    border-bottom: 3px solid var(--surface-color);
    padding-bottom: 20px;
    text-align: left;
}

.privacy-header h1 {
    color: var(--primary-color);
    text-align: left;
}

.privacy-body h2 {
    color: var(--primary-variant);
    margin-top: 40px;
    font-size: 1.5rem;
    font-weight: 700;
}

.privacy-body .contact-box {
    background: var(--surface-color);
    border-left: 5px solid var(--primary-color);
    padding: 24px;
    margin: 25px 0;
    border-radius: 0 12px 12px 0;
}

.privacy-body .back-link {
    display: inline-block;
    margin-bottom: 30px;
    color: var(--primary-color);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    text-decoration: none;
    font-weight: 600;
}

/* --- Footer --- */
footer {
    background: var(--primary-variant);
    color: var(--white);
    padding: 80px 20px;
    text-align: center;
}

footer a {
    color: #A5D6A7;
    text-decoration: none;
    margin: 0 15px;
    font-weight: 600;
    transition: var(--transition);
}

footer a:hover { color: var(--white); }

.copyright {
    margin-top: 25px;
    font-size: 0.9rem;
    opacity: 0.7;
}
