/* Base Styles */

@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');



:root {
    --primary-color: #2e7d32;
    --secondary-color: #81c784;
    --accent-color: #4caf50;
    --light-green: #e8f5e9;
    --dark-green: #1b5e20;
    --brown: #795548;
    --light-brown: #bcaaa4;
    --text-dark: #2d3436;
    --text-light: #f5f5f5;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: var(--light-green);
    color: var(--text-dark);
    position: relative;
    overflow-x: hidden;
    font-family: "Poppins", sans-serif;
  font-weight: 400;
  font-style: normal;
}

/* Leaf Overlay */
.leaf-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('/api/placeholder/400/400');
    background-size: 400px;
    opacity: 0.05;
    pointer-events: none;
    z-index: -1;
}

/* Header */
header {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.logo i {
    font-size: 1.8rem;
    color: var(--secondary-color);
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 600;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 1.5rem;
    
}

nav a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    text-decoration: none;
}

nav a:hover, nav a.active {
    background-color: var(--secondary-color);
}

/* Main Content */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

section {
    margin-bottom: 4rem;
}

h2 {
    color: var(--dark-green);
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--secondary-color);
}

#featured-plants h2 {
    text-align: center;
    margin: 2 auto;
}

/* Hero Section */
.hero {
    display: flex;
    align-items: center;
    gap: 2rem;
    min-height: 500px;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: -50%;
    width: 200%;
    height: 100%;
    background-color: var(--light-green);
    z-index: -1;
    border-radius: 0 0 50% 50%;
    box-shadow: inset 0 -10px 20px rgba(0, 0, 0, 0.1);
}

.hero-content {
    flex: 1;
}

.hero-content h2 {
    font-size: 4rem;
    color: var(--dark-green);
    border: none;
    margin-bottom: 1rem;
    /* z-index: 5; */
}

.hero-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.hero-image {
    position: absolute;
    top: -50px;
    left: 380px;
    width: 100%;
    height: 100%;
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: -1;
}

.hero-image img {
    max-width: 100%;
    border-radius: 10px;
    box-shadow: var(--shadow);
}

.cta-button-anchor{
    text-decoration: none;
    color: white;
    ;
}

.cta-button{
    background-color: var(--accent-color);
    color: white;
    /* border: none; */
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 0px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}


.cta-button:hover {
    background-color: var(--dark-green);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

/* Featured Plants Section */
.featured {
    position: relative;
    padding: 2rem 0;
}

.plant-carousel {
    display: flex;
    overflow-x: hidden;
    gap: 2rem;
    padding: 1rem 0;
}

.plant-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    margin: 15px;
    width: 280px;  /* reduced from 350px */
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.plant-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.15);
}

.plant-image {
    height: 200px;
    overflow: hidden;
}

.plant-image img {
    width: 100%;
    height: 180px;  /* reduced from 250px */
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 10px;
    transition: transform 0.5s ease;
}

.plant-card:hover .plant-image img {
    transform: scale(1.05);
}

.plant-card h3 {
    font-size: 20px;  /* reduced from 24px */
    margin: 10px 0;
    color: #2c3e50;
    padding: 0.5rem 0.5rem 0.25rem;
}

.plant-card p {
    font-size: 14px;  /* reduced from 16px */
    color: #666;
    margin-bottom: 15px;
    line-height: 1.4;
    padding: 0 0.5rem 0.5rem;
}

.carousel-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-top: 1.5rem;
}

.carousel-controls button {
    background-color: var(--secondary-color);
    color: white;
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.carousel-controls button:hover {
    background-color: var(--primary-color);
}

/* Garden Map Section */
.garden-map {
    padding: 2rem 0;
}

.garden-interactive {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.map-container {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.garden-map-img {
    width: 100%;
    display: block;
}

.region {
    position: absolute;
    background-color: rgba(46, 125, 50, 0.7);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.region:hover {
    background-color: var(--accent-color);
    transform: scale(1.05);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.region-info {
    background-color: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.region-info h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Plant Details */
.plant-details {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    z-index: 2000;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem;
}

.plant-details.hidden {
    display: none;
}

.plant-content {
    background-color: white;
    width: 100%;
    max-width: 900px;
    max-height: 80vh;
    overflow-y: auto;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.close-button {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    width: 40px;
    height: 40px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.close-button:hover {
    background-color: rgba(0, 0, 0, 0.8);
}

.plant-header {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    background-color: var(--light-green);
}

.plant-header img {
    width: 250px;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.plant-header-info {
    flex: 1;
}

.plant-header-info h2 {
    color: var(--dark-green);
    margin-bottom: 0.5rem;
    border: none;
}

.plant-header-info p {
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 1rem;
}

.plant-tags {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.tag {
    background-color: var(--secondary-color);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.9rem;
}

.plant-info-tabs {
    padding: 0 2rem 2rem;
}

.tabs {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.tab-button {
    background: none;
    border: none;
    padding: 1rem 1.5rem;
    cursor: pointer;
    font-size: 1rem;
    color: var(--text-dark);
    position: relative;
    transition: all 0.3s ease;
}

.tab-button::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--accent-color);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.tab-button.active {
    color: var(--primary-color);
    font-weight: 600;
}

.tab-button.active::after {
    transform: scaleX(1);
}

.tab-content {
    padding: 1rem 0;
}

.tab-pane {
    display: none;
}

.tab-pane.active {
    display: block;
}

/* Encyclopedia Section */
.encyclopedia {
    padding: 2rem 0;
}

.search-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 2rem;
    background-color: white;
    padding: 1.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.search {
    flex: 1;
    min-width: 300px;
    display: flex;
}

.search input {
    flex: 1;
    padding: 0.8rem 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 4px 0 0 4px;
    font-size: 1rem;
}

.search button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0 1.5rem;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

.filters {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.filters select {
    padding: 0.8rem 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 1rem;
    min-width: 150px;
}

.plant-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
}

/* About Section */
.about-content {
    background-color: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow);
}

.about-text p {
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

.mission {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e0e0e0;
}

.mission h3 {
    color: var(--dark-green);
    margin-bottom: 1rem;
}

.mission ul {
    padding-left: 1.5rem;
    line-height: 1.8;
}

/* Footer */
footer {
    background-color: var(--dark-green);
    color: var(--text-light);
    padding: 3rem 2rem 1rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.footer-logo i {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

.footer-links h4, .footer-newsletter h4 {
    margin-bottom: 1rem;
    color: var(--secondary-color);
}

.footer-links ul {
    list-style: none;
}

.footer-links a {
    color: var(--text-light);
    text-decoration: none;
    display: block;
    padding: 0.5rem 0;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--secondary-color);
}

.footer-newsletter p {
    margin-bottom: 1rem;
}

.newsletter-form {
    display: flex;
}

.newsletter-form input {
    flex: 1;
    padding: 0.8rem;
    border: none;
    border-radius: 4px 0 0 4px;
}

.newsletter-form button {
    background-color: var(--accent-color);
    color: white;
    border: none;
    padding: 0 1.5rem;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.newsletter-form button:hover {
    background-color: var(--secondary-color);
}

.footer-bottom {
    max-width: 1200px;
    margin: 2rem auto 0;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
}

/* Responsiveness */
@media (max-width: 1000px) {
    .hero {
        flex-direction: column;
        text-align: center;
    }

    .plant-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .plant-header img {
        width: 100%;
        max-width: 300px;
    }
}

@media (max-width: 768px) {
    header {
        flex-direction: column;
        padding: 1rem;
    }

    .logo {
        margin-bottom: 1rem;
    }

    nav ul {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.5rem;
    }

    .search-filter {
        flex-direction: column;
    }
}

@media (max-width: 500px) {
    .plant-carousel {
        padding-bottom: 2rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(20px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.plant-card, .region-info, .about-content, .search-filter {
    animation: slideIn 0.5s ease-out;
}

.plant-details {
    animation: fadeIn 0.3s ease-out;
}



/* popup */

.learn-more-btn {
    background: #4CAF50;
    color: white;
    border: none;
    padding: 10px 23px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    transition: background 0.3s ease;
    width: 100%;
}

.learn-more-btn:hover {
    background: #45a049;
}

.popup {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    z-index: 1000;
    animation: fadeIn 0.3s ease-out;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch; /* For iOS smooth scrolling */
    overscroll-behavior: contain;
}

/* Custom Scrollbar for Popup */
.popup-content {
    position: relative;
    background-color: white;
    margin: 2% auto;
    padding: 40px;
    width: 90%;
    max-width: 1000px;
    border-radius: 25px;
    max-height: 85vh;
    overflow-y: auto;
    animation: slideIn 0.4s ease-out;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    scroll-behavior: smooth;
    border: 1px solid rgba(76, 175, 80, 0.1);
    
    /* Modern Scrollbar Styling */
    &::-webkit-scrollbar {
        width: 8px;  /* reduced from 12px */
        background-color: transparent;
    }

    &::-webkit-scrollbar-thumb {
        background: linear-gradient(45deg, #4CAF50, #45a049);
        border-radius: 20px;
        /* removed border to make it cleaner */
    }

    &::-webkit-scrollbar-thumb:hover {
        background: linear-gradient(45deg, #45a049, #357a38);
    }

    &::-webkit-scrollbar-track {
        background-color: rgba(76, 175, 80, 0.05);
        border-radius: 20px;
        margin: 5px 0;
    }

    &::-webkit-scrollbar-button {
        display: none;  /* removes the arrows */
    }

    /* Firefox Scrollbar */
    scrollbar-width: thin;
    scrollbar-color: #4CAF50 rgba(76, 175, 80, 0.05);
}

.popup-header {
    margin-bottom: 30px;
}

.popup-header h2{
    margin-left: 2vw;
}

.popup-header img {
    width: 100%;
    height: 400px;  /* increased from 300px */
    object-fit: cover;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.popup-header .sketchfab-embed-wrapper {
    width: 100%;
    height: 400px;
    margin-bottom: 20px;
    border-radius: 15px;
    overflow: hidden;
}

.popup-header .sketchfab-embed-wrapper iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.popup-info {
    padding: 30px;
    background-color: #f9f9f9;
    border-radius: 15px;
}

#popup-scientific{
    color: var(--dark-green);
    font-size: 23px;
    font-weight: 400;
}

#popup-title{
    font-size: 28px;
}

#popup-benefits{
    color: var(--dark-green);
    font-size: 18px;
    font-weight: 400;
}

#popup-growing{
    color: var(--dark-green);
    font-size: 18px;
    font-weight: 400;
}

#popup-uses{
    color: var(--dark-green);
    font-size: 18px;
    font-weight: 400;
}

.popup-info h2 {
    color: var(--secondary-color);
    font-size: 24px;
    margin-bottom: 15px;
    border-bottom: 2px solid var(--secondary-color);
    padding-bottom: 10px;
    font-weight: 500;
}

.popup-info ul {
    list-style-type: none;
    padding: 0;
}

.popup-info ul li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.popup-info ul li:last-child {
    border-bottom: none;
}

.close-popup {
    position: absolute;
    right: 30px;
    top: 20px;
    font-size: 40px;
    cursor: pointer;
    color: #333;
    z-index: 1001;
    width: 50px;
    height: 50px;
    background: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.close-popup:hover {
    color: #000;
    background: #f5f5f5;
    transform: scale(1.1);
}

@keyframes slideIn {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}




