/* Root variables for color palette */

:root {
    --primary-green: #388e3c;
    --secondary-green: #66bb6a;
    --earth-brown: #8d6e63;
    --light-earth: #d7ccc8;
    --background: #f5f5f5;
    --white: #fff;
    --text-dark: #263238;
    --accent-yellow: #ffd54f;
}

body {
    margin: 0;
    font-family: 'Segoe UI', Arial, sans-serif;
    background: var(--background);
    color: var(--text-dark);
}

.navbar {
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 70px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-left {
    display: flex;
    align-items: center;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
}

.logo-icon {
    font-size: 1.8rem;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-green);
    letter-spacing: 0.5px;
}

.navbar-center {
    flex: 1;
    display: flex;
    justify-content: center;
}

.nav-links {
    display: flex;
    gap: 2.5rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.nav-link {
    color: var(--text-dark);
    text-decoration: none;
    font-weight: 500;
    font-size: 1rem;
    padding: 0.5rem 0;
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-green);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: var(--primary-green);
}

.nav-link:hover::after {
    width: 100%;
}

.navbar-right {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.nav-btn {
    padding: 0.6rem 1.2rem;
    border-radius: 6px;
    font-weight: 500;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.login-btn {
    background: transparent;
    border: 1px solid var(--primary-green);
    color: var(--primary-green);
}

.login-btn:hover {
    background: var(--primary-green);
    color: var(--white);
}

.signup-btn {
    background: var(--primary-green);
    border: 1px solid var(--primary-green);
    color: var(--white);
}

.signup-btn:hover {
    background: var(--secondary-green);
    border-color: var(--secondary-green);
}


/* Responsive Navbar */

@media (max-width: 900px) {
    .navbar-container {
        padding: 0 1rem;
    }
    .nav-links {
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .navbar-container {
        height: auto;
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
    }
    .navbar-center {
        width: 100%;
    }
    .nav-links {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
    .navbar-right {
        width: 100%;
        justify-content: center;
    }
    .nav-link::after {
        display: none;
    }
}

.footer {
    background: var(--earth-brown);
    color: var(--white);
    text-align: center;
    padding: 1rem 0;
    margin-top: auto;
    position: relative;
    width: 100%;
}

.social-links {
    margin-bottom: 0.5rem;
    text-align: center;
}

.social-links a img {
    width: 24px;
    height: 24px;
    margin: 0 0.5rem;
    vertical-align: middle;
}

main#app {
    max-width: 1100px;
    margin: 2rem auto;
    padding: 0 1rem;
    min-height: calc(100vh - 70px - 60px);
    display: flex;
    flex-direction: column;
}

.product-details,
.search-bar {
    flex: 1;
    margin-bottom: 2rem;
}


/* Cards */

.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.card {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s, box-shadow 0.3s;
    border-top: 4px solid var(--card-color);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

.card .icon {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.card .card-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.card .card-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--card-color);
    margin-bottom: 0.25rem;
}

.card .card-subtitle {
    font-size: 0.9rem;
    color: var(--text-dark);
    opacity: 0.7;
}


/* Timeline */

.timeline {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin: 2rem 0;
    overflow-x: auto;
}

.timeline-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.timeline-step .step-icon {
    background: var(--secondary-green);
    color: var(--white);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.timeline-step .step-label {
    font-size: 0.95rem;
    text-align: center;
}

.timeline-step:not(:last-child)::after {
    content: '';
    position: absolute;
    top: 20px;
    left: 100%;
    width: 60px;
    height: 4px;
    background: var(--secondary-green);
    z-index: 0;
}


/* Search bar */

.search-bar {
    margin: 2rem auto;
    max-width: 400px;
    gap: 0.5rem;
}

.search-bar input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--secondary-green);
    border-radius: 8px 0 0 8px;
    outline: none;
    font-size: 1rem;
}

.search-bar button {
    padding: 0.75rem 1.25rem;
    border: none;
    background: var(--primary-green);
    color: var(--white);
    border-radius: 0 8px 8px 0;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s;
}

.search-bar button:hover {
    background: var(--secondary-green);
}


/* Enhanced Hero Section */

.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    padding: 4rem 2rem;
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--secondary-green) 100%);
    color: var(--white);
    position: relative;
    overflow: hidden;
    border-radius: 14px;
}

.hero-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 1.5rem;
    z-index: 2;
    text-align: center;
}

.hero .headline {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin: 0;
}

.hero .subheadline {
    font-size: 1.25rem;
    opacity: 0.9;
    margin: 0;
}

.hero-cta {
    display: flex;
    gap: 1rem;
    margin-top: 1rem;
    justify-content: center;
    width: 100%;
}

.hero-image {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.hero-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 20px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg, rgba(0, 0, 0, 0.3) 0%, rgba(0, 0, 0, 0.1) 100%);
    border-radius: 20px;
}


/* How It Works Section */

.how-it-works {
    padding: 5rem 2rem;
    background: var(--white);
}

.how-it-works h2 {
    text-align: center;
    font-size: 2.5rem;
    color: var(--primary-green);
    margin-bottom: 3rem;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.step-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    text-align: center;
    transition: transform 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.step-card.reveal {
    opacity: 1;
    transform: translateY(0);
}

.step-card:hover {
    transform: translateY(-5px);
}

.step-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.step-card h3 {
    color: var(--primary-green);
    margin-bottom: 1rem;
}

.step-card p {
    color: var(--text-dark);
    opacity: 0.8;
    line-height: 1.6;
}


/* Features Section */

.features {
    padding: 5rem 2rem;
    background: #f8f9fa;
}

.features h2 {
    text-align: center;
    font-size: 2.5rem;
    color: var(--primary-green);
    margin-bottom: 3rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.feature-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.feature-card.reveal {
    opacity: 1;
    transform: translateY(0);
}

.feature-card:hover {
    transform: translateY(-5px);
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.feature-card h3 {
    color: var(--primary-green);
    margin-bottom: 1rem;
}

.feature-card p {
    color: var(--text-dark);
    opacity: 0.8;
    line-height: 1.6;
}


/* Testimonials Section */

.testimonials {
    padding: 5rem 2rem;
    background: var(--white);
}

.testimonials h2 {
    text-align: center;
    font-size: 2.5rem;
    color: var(--primary-green);
    margin-bottom: 3rem;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.testimonial-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    opacity: 0;
    transform: translateY(20px);
}

.testimonial-card.reveal {
    opacity: 1;
    transform: translateY(0);
}

.quote {
    font-size: 1.1rem;
    line-height: 1.6;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
    font-style: italic;
}

.author {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.company {
    font-weight: 600;
    color: var(--primary-green);
}

.role {
    font-size: 0.9rem;
    color: var(--text-dark);
    opacity: 0.7;
}


/* CTA Section */

.cta-section {
    padding: 5rem 2rem;
    background: linear-gradient(135deg, var(--primary-green) 0%, var(--secondary-green) 100%);
    color: var(--white);
    text-align: center;
    border-radius: 14px;
}

.cta-section h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-section p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 2rem;
}


/* Enhanced Button Styles */

.cta-btn {
    padding: 1rem 2rem;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.cta-btn.primary {
    background: var(--accent-yellow);
    color: var(--primary-green);
}

.cta-btn.primary:hover {
    background: var(--white);
    transform: translateY(-2px);
}

.cta-btn.secondary {
    background: transparent;
    color: var(--white);
    border: 2px solid var(--white);
}

.cta-btn.secondary:hover {
    background: var(--white);
    color: var(--primary-green);
    transform: translateY(-2px);
}


/* Responsive Design */

@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding: 3rem 1rem;
    }
    .hero-content {
        order: 2;
    }
    .hero-image {
        order: 1;
        max-width: 500px;
        margin: 0 auto;
    }
    .hero .headline {
        font-size: 2.5rem;
    }
    .hero-cta {
        justify-content: center;
    }
    .how-it-works h2,
    .features h2,
    .testimonials h2 {
        font-size: 2rem;
    }
}

@media (max-width: 600px) {
    .hero .headline {
        font-size: 2rem;
    }
    .hero .subheadline {
        font-size: 1.1rem;
    }
    .hero-cta {
        flex-direction: column;
    }
    .steps-grid,
    .features-grid,
    .testimonials-grid {
        grid-template-columns: 1fr;
    }
}


/* Product Details */

.product-details {
    background: var(--white);
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(56, 142, 60, 0.08);
    padding: 2rem;
    max-width: 500px;
    margin: 2rem auto;
}

.product-details .details-row {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.product-details .details-icon {
    font-size: 1.5rem;
    margin-right: 1rem;
    color: var(--primary-green);
}

.product-details .details-label {
    font-weight: 500;
    min-width: 120px;
}

.product-details .details-value {
    font-size: 1.05rem;
}


/* Responsive Design */

@media (max-width: 800px) {
    .summary-cards {
        flex-direction: column;
        gap: 1rem;
    }
    .timeline {
        flex-direction: column;
        gap: 1rem;
    }
}

@media (max-width: 600px) {
    .navbar,
    .footer {
        flex-direction: column;
        align-items: flex-start;
        padding: 1rem;
    }
    .nav-links {
        flex-direction: column;
        gap: 1rem;
        width: 100%;
    }
    main#app {
        padding: 0 0.5rem;
    }
    .hero .headline {
        font-size: 1.5rem;
    }
}


/* Dashboard Styles */

.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.dashboard-header h1 {
    color: var(--primary-green);
    margin: 0;
    font-size: 2rem;
}

.dashboard-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.search-container {
    display: flex;
    gap: 0.5rem;
}

.search-input {
    padding: 0.6rem 1rem;
    border: 1px solid var(--light-earth);
    border-radius: 6px;
    font-size: 0.95rem;
    min-width: 250px;
}

.search-btn {
    padding: 0.6rem 1.2rem;
    background: var(--primary-green);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.3s;
}

.search-btn:hover {
    background: var(--secondary-green);
}

.filter-select {
    padding: 0.6rem 1rem;
    border: 1px solid var(--light-earth);
    border-radius: 6px;
    font-size: 0.95rem;
    background: white;
    cursor: pointer;
}

.dashboard-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 2rem;
}

.stat-item {
    background: var(--white);
    padding: 1rem 2rem;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(56, 142, 60, 0.08);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: bold;
    color: var(--primary-green);
}

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

.dashboard-section {
    margin: 2rem 0;
}

.dashboard-section h2 {
    color: var(--primary-green);
    margin-bottom: 1rem;
}

.batch-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.batch-item {
    background: var(--white);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(56, 142, 60, 0.08);
}

.batch-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.batch-id {
    font-weight: bold;
    font-size: 1.1rem;
    color: var(--primary-green);
}

.batch-status {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.9rem;
}

.batch-status.completed {
    background: var(--secondary-green);
    color: var(--white);
}

.batch-status.in-progress {
    background: var(--accent-yellow);
    color: var(--text-dark);
}

.batch-details {
    display: flex;
    gap: 1.5rem;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.batch-details span {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.search-section {
    margin: 2rem 0;
}

.search-section h2 {
    color: var(--primary-green);
    margin-bottom: 1rem;
}

.card-subtitle {
    font-size: 0.9rem;
    color: var(--text-dark);
    opacity: 0.8;
}


/* Recent Batches Table */

.recent-batches {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.recent-batches h2 {
    color: var(--primary-green);
    margin-bottom: 1.5rem;
}

.table-container {
    overflow-x: auto;
}

.batches-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.batches-table th,
.batches-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--light-earth);
}

.batches-table th {
    font-weight: 600;
    color: var(--text-dark);
    background: #f8f9fa;
}

.batches-table tr:hover {
    background: #f8f9fa;
}

.status-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.status-badge.harvested {
    background: #E8F5E9;
    color: #2E7D32;
}

.status-badge.transported {
    background: #E3F2FD;
    color: #1565C0;
}

.status-badge.warehoused {
    background: #FFF3E0;
    color: #E65100;
}

.status-badge.delivered {
    background: #EDE7F6;
    color: #5E35B1;
}

.view-btn {
    padding: 0.4rem 0.8rem;
    background: var(--primary-green);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.3s;
}

.view-btn:hover {
    background: var(--secondary-green);
}


/* Responsive adjustments for dashboard */

@media (max-width: 900px) {
    .dashboard-header {
        flex-direction: column;
        gap: 1rem;
        align-items: flex-start;
    }
    .dashboard-actions {
        width: 100%;
        flex-direction: column;
    }
    .search-container {
        width: 100%;
    }
    .search-input {
        flex: 1;
    }
    .filter-select {
        width: 100%;
    }
}

@media (max-width: 600px) {
    .dashboard-container {
        padding: 1rem;
    }
    .summary-cards {
        grid-template-columns: 1fr;
    }
    .batches-table {
        font-size: 0.9rem;
    }
    .batches-table th,
    .batches-table td {
        padding: 0.75rem;
    }
}


/* Back Button Styles */

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--white);
    border: 1px solid var(--light-earth);
    border-radius: 8px;
    color: var(--text-dark);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin: 2rem auto;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    text-decoration: none;
}

.back-btn:hover {
    background: var(--primary-green);
    color: var(--white);
    border-color: var(--primary-green);
    transform: translateY(-2px);
}

.back-icon {
    font-size: 1.2rem;
    line-height: 1;
}


/* Modal Styles */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal-content {
    background: var(--white);
    border-radius: 12px;
    padding: 2rem;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    animation: modalSlideIn 0.3s ease;
}

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

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.modal-header h2 {
    color: var(--primary-green);
    margin: 0;
    font-size: 1.8rem;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--text-dark);
    cursor: pointer;
    padding: 0.5rem;
    line-height: 1;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.close-btn:hover {
    opacity: 1;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    color: var(--text-dark);
    font-weight: 500;
    font-size: 0.95rem;
}

.form-group input {
    padding: 0.75rem 1rem;
    border: 1px solid var(--light-earth);
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-green);
}

.auth-btn {
    background: var(--primary-green);
    color: var(--white);
    border: none;
    padding: 0.75rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 0.5rem;
}

.auth-btn:hover {
    background: var(--secondary-green);
    transform: translateY(-2px);
}

.auth-switch {
    text-align: center;
    margin-top: 1rem;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.auth-switch a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 500;
}

.auth-switch a:hover {
    text-decoration: underline;
}