/*
Theme Name: SmolPlants
Theme URI: https://smolplants.com
Author: SmolPlants Team
Description: A fresh, green ecommerce WordPress theme for small plants by mail. WooCommerce compatible.
Version: 1.0.0
Requires at least: 5.0
Tested up to: 6.5
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: smolplants
Tags: ecommerce, woocommerce, plants, green, nature, responsive
*/

/* === CSS Variables === */
:root {
    --green-dark: #2d5016;
    --green-mid: #4a7c29;
    --green-light: #7cb342;
    --green-pale: #e8f5e9;
    --green-accent: #a5d6a7;
    --brown: #8d6e63;
    --cream: #fefdf8;
    --white: #ffffff;
    --text-dark: #2c3e2d;
    --text-mid: #5a6b5c;
    --text-light: #8a9a8c;
    --shadow: 0 4px 20px rgba(45, 80, 22, 0.1);
    --shadow-hover: 0 8px 30px rgba(45, 80, 22, 0.15);
    --radius: 12px;
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--text-dark);
    background: var(--cream);
    line-height: 1.6;
    overflow-x: hidden;
}

a {
    color: var(--green-mid);
    text-decoration: none;
    transition: var(--transition);
}

a:hover {
    color: var(--green-dark);
}

img {
    max-width: 100%;
    height: auto;
}

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

/* === Header === */
.site-header {
    background: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.site-logo a {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--green-dark);
    display: flex;
    align-items: center;
    gap: 8px;
}

.site-logo .logo-icon {
    font-size: 2rem;
}

.main-nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

.main-nav a {
    color: var(--text-dark);
    font-weight: 500;
    padding: 8px 0;
    position: relative;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--green-light);
    transition: var(--transition);
}

.main-nav a:hover::after,
.main-nav a.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.cart-icon {
    position: relative;
    font-size: 1.5rem;
    color: var(--green-dark);
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background: var(--green-light);
    color: white;
    font-size: 0.7rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--green-dark);
}

/* === Hero Section === */
.hero {
    background: linear-gradient(135deg, var(--green-dark) 0%, var(--green-mid) 50%, var(--green-light) 100%);
    padding: 100px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '🌿';
    position: absolute;
    font-size: 15rem;
    opacity: 0.1;
    top: -30px;
    left: -30px;
}

.hero::after {
    content: '🌱';
    position: absolute;
    font-size: 12rem;
    opacity: 0.1;
    bottom: -20px;
    right: -20px;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero h1 {
    font-size: 3.5rem;
    color: var(--white);
    margin-bottom: 20px;
    font-weight: 800;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
}

.hero p {
    font-size: 1.3rem;
    color: var(--green-pale);
    margin-bottom: 35px;
}

.hero-btn {
    display: inline-block;
    background: var(--white);
    color: var(--green-dark);
    padding: 16px 40px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: var(--transition);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.hero-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.3);
    color: var(--green-mid);
}

.hero-badges {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.hero-badge {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--white);
    font-weight: 500;
}

.hero-badge span {
    font-size: 1.5rem;
}

/* === Section Styles === */
.section {
    padding: 80px 0;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--green-dark);
    margin-bottom: 15px;
}

.section-header p {
    color: var(--text-mid);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* === Featured Products Grid === */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
}

.product-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.product-image {
    height: 220px;
    background: var(--green-pale);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 5rem;
    position: relative;
}

.product-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: var(--green-light);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.product-info {
    padding: 20px;
}

.product-info h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
    color: var(--text-dark);
}

.product-price {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--green-mid);
    margin-bottom: 15px;
}

.add-to-cart-btn {
    width: 100%;
    padding: 12px;
    background: var(--green-mid);
    color: white;
    border: none;
    border-radius: 8px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.add-to-cart-btn:hover {
    background: var(--green-dark);
}

/* === Care Tips Section === */
.care-section {
    background: var(--green-pale);
}

.care-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.care-card {
    background: var(--white);
    padding: 35px;
    border-radius: var(--radius);
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.care-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.care-icon {
    font-size: 3.5rem;
    margin-bottom: 20px;
}

.care-card h3 {
    font-size: 1.3rem;
    color: var(--green-dark);
    margin-bottom: 12px;
}

.care-card p {
    color: var(--text-mid);
    font-size: 0.95rem;
}

/* === Newsletter Section === */
.newsletter {
    background: linear-gradient(135deg, var(--green-mid), var(--green-dark));
    padding: 70px 20px;
    text-align: center;
}

.newsletter h2 {
    color: var(--white);
    font-size: 2.2rem;
    margin-bottom: 15px;
}

.newsletter p {
    color: var(--green-pale);
    margin-bottom: 30px;
    font-size: 1.1rem;
}

.newsletter-form {
    display: flex;
    max-width: 500px;
    margin: 0 auto;
    gap: 10px;
}

.newsletter-form input {
    flex: 1;
    padding: 15px 20px;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    outline: none;
}

.newsletter-form button {
    padding: 15px 30px;
    background: var(--white);
    color: var(--green-dark);
    border: none;
    border-radius: 50px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.newsletter-form button:hover {
    background: var(--green-pale);
}

/* === Page Content === */
.page-content {
    padding: 60px 0;
}

.page-content h1 {
    font-size: 2.5rem;
    color: var(--green-dark);
    margin-bottom: 30px;
    text-align: center;
}

.page-content .entry-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 1.1rem;
    line-height: 1.8;
}

/* === WooCommerce Styles === */
.woocommerce .products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 30px;
}

.woocommerce ul.products li.product {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    margin: 0 !important;
    width: 100% !important;
    float: none !important;
}

.woocommerce ul.products li.product:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.woocommerce ul.products li.product a img {
    border-radius: 0;
}

.woocommerce ul.products li.product .price {
    color: var(--green-mid) !important;
    font-weight: 700;
    font-size: 1.3rem;
}

.woocommerce a.button,
.woocommerce button.button,
.woocommerce input.button {
    background: var(--green-mid) !important;
    color: white !important;
    border: none !important;
    border-radius: 8px !important;
    padding: 12px 20px !important;
    font-weight: 600 !important;
    transition: var(--transition) !important;
}

.woocommerce a.button:hover,
.woocommerce button.button:hover,
.woocommerce input.button:hover {
    background: var(--green-dark) !important;
}

.woocommerce .woocommerce-message {
    background: var(--green-pale) !important;
    border-color: var(--green-light) !important;
    color: var(--green-dark) !important;
}

/* === Footer === */
.site-footer {
    background: var(--green-dark);
    color: var(--white);
    padding: 60px 20px 30px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-col h3 {
    font-size: 1.2rem;
    margin-bottom: 20px;
    color: var(--green-accent);
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col ul li a {
    color: var(--green-pale);
}

.footer-col ul li a:hover {
    color: var(--white);
}

.footer-bottom {
    text-align: center;
    padding-top: 40px;
    margin-top: 40px;
    border-top: 1px solid rgba(255,255,255,0.1);
    color: var(--text-light);
}

/* === Responsive === */
@media (max-width: 768px) {
    .main-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        box-shadow: var(--shadow);
        padding: 20px;
    }

    .main-nav.active {
        display: block;
    }

    .main-nav ul {
        flex-direction: column;
        gap: 15px;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .hero h1 {
        font-size: 2.2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .newsletter-form {
        flex-direction: column;
    }

    .hero-badges {
        flex-direction: column;
        align-items: center;
        gap: 15px;
    }
}

/* === Utility === */
.text-center { text-align: center; }
.mt-20 { margin-top: 20px; }
.mb-20 { margin-bottom: 20px; }
