/* Gree.do Main Stylesheet - Emerald/Teal Theme with Brown Accents */

:root {
    /* Primary Colors - Emerald/Teal Green */
    --primary-green: #10b981;
    --primary-green-dark: #059669;
    --primary-green-light: #34d399;
    --primary-green-ultra-light: #d1fae5;
    
    /* Secondary Colors - Teal */
    --secondary-teal: #14b8a6;
    --secondary-teal-dark: #0f766e;
    --secondary-teal-light: #5eead4;
    
    /* Accent Colors - Brown from Banner */
    --accent-brown: #8b5a2b;
    --accent-brown-dark: #744c28;
    --accent-brown-light: #a67c52;
    
    /* Neutral Colors */
    --background: #0f172a;
    --background-card: #1e293b;
    --background-hover: #334155;
    --text-primary: #f8fafc;
    --text-secondary: #cbd5e1;
    --text-muted: #94a3b8;
    
    /* Status Colors */
    --success: var(--primary-green);
    --warning: #f59e0b;
    --error: #ef4444;
    
    /* Border and Shadow */
    --border-color: #475569;
    --shadow-primary: 0 4px 6px -1px rgba(16, 185, 129, 0.1);
    --shadow-hover: 0 10px 15px -3px rgba(16, 185, 129, 0.2);
}

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

body {
    font-family: 'Inter', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, var(--background) 0%, #1e293b 100%);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

/* Header Styles */
.header {
    position: relative;
    background: linear-gradient(135deg, var(--accent-brown-dark) 0%, var(--accent-brown) 100%);
    border-bottom: 3px solid var(--primary-green);
    overflow: hidden;
}

.header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('/static/img/gree-do-banner.png') center/cover;
    opacity: 0.8;
    z-index: 1;
}

.header-content {
    position: relative;
    z-index: 2;
    padding: 2rem 1rem;
    text-align: center;
    background: rgba(15, 23, 42, 0.7);
}

.banner-image {
    width: 90vw;
    max-width: 1125px;
    min-width: 300px;
    height: auto;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
}

/* Dropdown Navigation */
.navigation {
    position: absolute;
    bottom: 1rem;
    right: 1rem;
    z-index: 1000;
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-btn {
    display: flex;
    align-items: center;
    padding: 0.75rem 1.25rem;
    background: rgba(16, 185, 129, 0.9);
    color: var(--text-primary);
    border: none;
    border-radius: 8px;
    font-weight: 500;
    font-size: 0.875rem;
    cursor: pointer;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    gap: 0.5rem;
}

/* Smaller dropdown button on mobile */
@media (max-width: 768px) {
    .dropdown-btn {
        padding: 0.4rem 0.8rem;
        font-size: 0.75rem;
        gap: 0.3rem;
    }
    
    .dropdown-btn i {
        font-size: 0.7rem;
    }
}

.dropdown-btn:hover {
    background: rgba(5, 150, 105, 0.95);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.dropdown-arrow {
    transition: transform 0.3s ease;
    font-size: 0.75rem;
}

.dropdown.active .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-content {
    position: absolute;
    bottom: 100%;
    right: 0;
    margin-bottom: 0.5rem;
    min-width: 180px;
    background: rgba(30, 41, 59, 0.95);
    border-radius: 8px;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.dropdown.active .dropdown-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-content .nav-link {
    display: flex;
    align-items: center;
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.dropdown-content .nav-link:last-child {
    border-bottom: none;
}

.dropdown-content .nav-link:hover {
    background: rgba(16, 185, 129, 0.2);
    color: var(--primary-green);
    padding-left: 1.25rem;
}

.dropdown-content .nav-link i {
    margin-right: 0.75rem;
    font-size: 1rem;
    width: 16px;
    text-align: center;
}

/* Main Content */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.main-content {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    align-items: start;
}

.main-content-centered {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.content-area {
    background: var(--background-card);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: var(--shadow-primary);
    border: 1px solid var(--border-color);
}

/* Logo Section */
.logo-section {
    text-align: center;
    margin-bottom: 3rem;
}

.logo-container {
    position: relative;
    display: inline-block;
    margin: 2rem 0;
}

.logo-image {
    width: min(60vw, 600px);
    max-width: 90vw;
    min-width: 200px;
    height: auto;
    transition: transform 0.3s ease;
    filter: drop-shadow(0 4px 12px rgba(16, 185, 129, 0.3));
}

/* Logo Animation Classes */
.logo-bounce {
    animation: gentleBounce 3s ease-in-out infinite;
}

.logo-glow {
    animation: gentleGlow 4s ease-in-out infinite alternate;
}

.logo-float {
    animation: gentleFloat 6s ease-in-out infinite;
}

.logo-pulse {
    animation: gentlePulse 2s ease-in-out infinite;
}

.logo-combined {
    animation:
        gentleBounce 3s ease-in-out infinite,
        gentleGlow 4s ease-in-out infinite alternate,
        gentleFloat 6s ease-in-out infinite,
        gentlePulse 2s ease-in-out infinite;
}

/* Space gun cursor */
.space-gun-cursor {
    cursor: none !important;
}

.space-gun {
    position: fixed;
    width: 24px;
    height: 24px;
    pointer-events: none;
    z-index: 10000;
    transition: transform 0.1s ease;
    transform-origin: center;
}

.space-gun::before {
    content: "🔫";
    font-size: 20px;
    display: block;
    transform: rotate(-45deg);
    filter: sepia(1) hue-rotate(120deg) saturate(2) brightness(1.2);
}

.space-gun.shooting::after {
    content: "💥";
    position: absolute;
    font-size: 16px;
    left: -8px;
    top: -8px;
    animation: shootEffect 0.3s ease-out;
}

@keyframes shootEffect {
    0% {
        opacity: 0;
        transform: scale(0) rotate(0deg);
    }
    50% {
        opacity: 1;
        transform: scale(1.2) rotate(180deg);
    }
    100% {
        opacity: 0;
        transform: scale(1.8) rotate(360deg);
    }
}

/* Floating sparkles */
.floating-sparkle {
    position: fixed;
    width: 4px;
    height: 4px;
    background: var(--primary-green);
    border-radius: 50%;
    pointer-events: none;
    z-index: 50;
    opacity: 0;
    animation: floatSparkle 8s linear infinite;
}

.floating-sparkle:nth-child(odd) {
    background: var(--secondary-teal);
    animation-duration: 10s;
}

.floating-sparkle:nth-child(3n) {
    background: var(--accent-brown);
    animation-duration: 12s;
}

@keyframes floatSparkle {
    0% {
        opacity: 0;
        transform: translateY(100vh) rotate(0deg) scale(0);
    }
    10% {
        opacity: 1;
        transform: translateY(90vh) rotate(36deg) scale(1);
    }
    90% {
        opacity: 1;
        transform: translateY(-10vh) rotate(324deg) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-20vh) rotate(360deg) scale(0);
    }
}

@keyframes gentleBounce {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes gentleGlow {
    0% { filter: drop-shadow(0 4px 12px rgba(16, 185, 129, 0.3)); }
    100% { filter: drop-shadow(0 8px 24px rgba(16, 185, 129, 0.6)); }
}

@keyframes gentleFloat {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    33% { transform: translateY(-8px) rotate(1deg); }
    66% { transform: translateY(-12px) rotate(-1deg); }
}

@keyframes gentlePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Data Display */
.timestamp-data {
    background: rgba(16, 185, 129, 0.1);
    border: 2px solid var(--primary-green);
    border-radius: 8px;
    padding: 1.5rem;
    margin: 2rem 0;
}

.timestamp-section {
    margin-bottom: 1.5rem;
}

.timestamp-section h3 {
    color: var(--primary-green);
    margin-bottom: 0.5rem;
    font-size: 1.125rem;
    font-weight: 600;
}

.timestamp-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.timestamp-item:last-child {
    border-bottom: none;
}

.timestamp-label {
    color: var(--text-secondary);
    font-weight: 500;
}

.timestamp-value {
    color: var(--text-primary);
    font-family: 'Courier New', monospace;
    font-weight: bold;
}

/* Sidebar */
.sidebar {
    background: var(--background-card);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow-primary);
    border: 1px solid var(--border-color);
    height: fit-content;
}

.sidebar h3 {
    color: var(--primary-green);
    margin-bottom: 1rem;
    font-size: 1.125rem;
}

.fact-section {
    background: rgba(20, 184, 166, 0.1);
    border-left: 4px solid var(--secondary-teal);
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 0 8px 8px 0;
}

.quote-section {
    background: rgba(139, 90, 43, 0.1);
    border-left: 4px solid var(--accent-brown);
    padding: 1rem;
    margin: 1rem 0;
    border-radius: 0 8px 8px 0;
}

/* Navigation button styling */
.btn {
    padding: 0.75rem 1.5rem;
    background: var(--primary-green);
    color: var(--text-primary);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn:hover {
    background: var(--primary-green-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

/* Loading Animation */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: var(--primary-green);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Status Indicators */
.status-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
}

.status-healthy {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
    border: 1px solid var(--success);
}

.status-warning {
    background: rgba(245, 158, 11, 0.2);
    color: var(--warning);
    border: 1px solid var(--warning);
}

.status-error {
    background: rgba(239, 68, 68, 0.2);
    color: var(--error);
    border: 1px solid var(--error);
}

/* Responsive Design */
@media (max-width: 768px) {
    .main-content {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .main-content-centered {
        padding: 1rem;
    }
    
    .navigation {
        position: absolute;
        bottom: 0.5rem;
        right: 0.5rem;
    }
    
    .dropdown-content {
        position: absolute;
        bottom: 100%;
        right: 0;
        margin-bottom: 0.5rem;
        opacity: 0;
        visibility: hidden;
        transform: translateY(10px);
    }
    
    .dropdown.active .dropdown-content {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
    
    .header-content {
        padding: 0.5rem;
    }
    
    .header {
        min-height: auto;
    }
    
    /* Disable background banner on mobile */
    .header::before {
        display: none;
    }
    
    .banner-image {
        width: 95vw;
        min-width: 280px;
    }
    
    .logo-image {
        width: min(70vw, 500px);
        min-width: 180px;
    }
    
}

@media (max-width: 480px) {
    .dropdown-btn {
        padding: 0.3rem 0.6rem;
        font-size: 0.7rem;
        width: auto;
        min-width: 80px;
        justify-content: center;
    }
    
    .dropdown-content .nav-link {
        justify-content: center;
        text-align: center;
    }
    
    .header-content {
        padding: 0.25rem;
    }
    
    .header {
        min-height: auto;
        padding: 0;
    }
    
    /* Ensure background banner stays disabled on small mobile */
    .header::before {
        display: none;
    }
    
    .navigation {
        bottom: 0.25rem;
        right: 0.25rem;
    }
    
    .banner-image {
        width: 98vw;
        min-width: 250px;
    }
    
    .logo-image {
        width: min(80vw, 400px);
        min-width: 150px;
    }
    
    .logo-section {
        margin-bottom: 1rem;
    }
    
    
    .container {
        padding: 1rem 0.5rem;
    }
    
    .footer {
        padding: 1rem;
        text-align: center;
    }
    
    .footer p {
        font-size: 0.875rem;
        line-height: 1.5;
    }
}

/* Footer */
.footer {
    text-align: center;
    padding: 2rem 1rem;
    color: var(--text-muted);
    border-top: 1px solid var(--border-color);
    margin-top: 4rem;
}

.footer a {
    color: var(--primary-green);
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* Animation utilities */
.fade-in {
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.slide-in {
    animation: slideIn 0.6s ease-out;
}

@keyframes slideIn {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}