/* PlantWater - Nature-inspired Styles */

:root {
    --primary-green: #2d6a4f;
    --light-green: #52b788;
    --pale-green: #d8f3dc;
    --dark-green: #1b4332;
    --accent-green: #95d5b2;
    --soil-brown: #8b5a2b;
    --leaf-yellow: #d4a574;
    --danger-red: #e63946;
    --warning-orange: #f4a261;
    --success-green: #2a9d8f;
    --bg-cream: #fefae0;
    --bg-white: #ffffff;
    --text-dark: #264653;
    --text-muted: #6b7280;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius: 12px;
    --radius-lg: 20px;
}

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

body {
    font-family: 'Nunito', -apple-system, BlinkMacSystemFont, sans-serif;
    background: linear-gradient(135deg, #f1f8e9 0%, #e8f5e9 50%, #f1f8e9 100%);
    background-attachment: fixed;
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
}

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

/* Header */
header {
    text-align: center;
    padding: 30px 0;
    margin-bottom: 20px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 8px;
}

.logo-icon {
    font-size: 2.5rem;
    animation: gentle-sway 3s ease-in-out infinite;
}

@keyframes gentle-sway {
    0%, 100% { transform: rotate(-5deg); }
    50% { transform: rotate(5deg); }
}

h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-green);
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.tagline {
    color: var(--text-muted);
    font-size: 1.1rem;
}

/* Sections */
section {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow);
}

h2 {
    color: var(--dark-green);
    margin-bottom: 20px;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Form */
.plant-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

label {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.9rem;
}

input, select {
    padding: 12px 16px;
    border: 2px solid var(--pale-green);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.2s;
    background: var(--bg-cream);
}

input:focus, select:focus {
    outline: none;
    border-color: var(--light-green);
    box-shadow: 0 0 0 3px rgba(82, 183, 136, 0.2);
}

/* Buttons */
.btn {
    padding: 12px 24px;
    border: none;
    border-radius: var(--radius);
    font-size: 1rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-green), var(--light-green));
    color: white;
    box-shadow: 0 4px 12px rgba(45, 106, 79, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(45, 106, 79, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-water {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 10px 20px;
    font-size: 0.9rem;
}

.btn-water:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.4);
}

.btn-delete {
    background: transparent;
    color: var(--danger-red);
    padding: 8px;
    font-size: 1.2rem;
    opacity: 0.6;
}

.btn-delete:hover {
    opacity: 1;
    background: rgba(230, 57, 70, 0.1);
}

/* Stats Section */
.stats-section {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    padding: 20px;
    background: linear-gradient(135deg, var(--dark-green), var(--primary-green));
}

.stat-card {
    text-align: center;
    padding: 16px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: var(--radius);
    backdrop-filter: blur(10px);
    color: white;
}

.stat-card.urgent {
    background: rgba(230, 57, 70, 0.3);
    animation: pulse 2s ease-in-out infinite;
}

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

.stat-icon {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 4px;
}

.stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    display: block;
}

.stat-label {
    font-size: 0.8rem;
    opacity: 0.9;
}

/* Section Header & Filters */
.section-header {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-bottom: 20px;
}

.filter-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 8px 16px;
    border: 2px solid var(--pale-green);
    background: white;
    border-radius: 20px;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    transition: all 0.2s;
}

.filter-btn:hover {
    border-color: var(--light-green);
    color: var(--primary-green);
}

.filter-btn.active {
    background: var(--primary-green);
    border-color: var(--primary-green);
    color: white;
}

/* Plant List */
.plant-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.plant-card {
    background: linear-gradient(135deg, #ffffff, var(--bg-cream));
    border-radius: var(--radius);
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: var(--shadow);
    border-left: 4px solid var(--light-green);
    transition: all 0.2s;
}

.plant-card:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow-lg);
}

.plant-card.urgent {
    border-left-color: var(--danger-red);
    background: linear-gradient(135deg, #fff5f5, #ffe0e0);
}

.plant-card.warning {
    border-left-color: var(--warning-orange);
    background: linear-gradient(135deg, #fff8f0, #ffe8d6);
}

.plant-card.good {
    border-left-color: var(--success-green);
}

.plant-icon {
    font-size: 2.5rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--pale-green);
    border-radius: 50%;
}

.plant-info {
    flex: 1;
}

.plant-name {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--dark-green);
    margin-bottom: 4px;
}

.plant-meta {
    display: flex;
    gap: 12px;
    font-size: 0.85rem;
    color: var(--text-muted);
    flex-wrap: wrap;
}

.plant-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.status-badge {
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.status-badge.urgent {
    background: var(--danger-red);
    color: white;
}

.status-badge.warning {
    background: var(--warning-orange);
    color: white;
}

.status-badge.good {
    background: var(--success-green);
    color: white;
}

.plant-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Progress Bar */
.water-progress {
    width: 100%;
    height: 6px;
    background: #e5e7eb;
    border-radius: 3px;
    margin-top: 8px;
    overflow: hidden;
}

.water-progress-bar {
    height: 100%;
    border-radius: 3px;
    transition: width 0.3s ease;
}

.water-progress-bar.urgent {
    background: var(--danger-red);
}

.water-progress-bar.warning {
    background: var(--warning-orange);
}

.water-progress-bar.good {
    background: var(--success-green);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-muted);
}

.empty-state.hidden {
    display: none;
}

.empty-icon {
    font-size: 4rem;
    display: block;
    margin-bottom: 16px;
    opacity: 0.5;
}

/* Notifications */
.notification-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.notification {
    background: white;
    padding: 16px 20px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 12px;
    animation: slide-in 0.3s ease;
    max-width: 350px;
}

.notification.success {
    border-left: 4px solid var(--success-green);
}

.notification.error {
    border-left: 4px solid var(--danger-red);
}

.notification.info {
    border-left: 4px solid var(--light-green);
}

@keyframes slide-in {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.notification.fade-out {
    animation: slide-out 0.3s ease forwards;
}

@keyframes slide-out {
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Footer */
footer {
    text-align: center;
    padding: 20px;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 600px) {
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .stats-section {
        grid-template-columns: 1fr;
    }
    
    .plant-card {
        flex-wrap: wrap;
    }
    
    .plant-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    h1 {
        font-size: 1.8rem;
    }
}

/* Water droplet animation */
.water-animation {
    animation: droplet 0.6s ease;
}

@keyframes droplet {
    0% { transform: scale(1); }
    50% { transform: scale(1.3); }
    100% { transform: scale(1); }
}
