/* ManagerAgro - Custom Styles */

:root {
    --primary-color: #198754;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #17a2b8;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa;
}

/* Sidebar */
#sidebar-wrapper {
    min-height: calc(100vh - 56px);
    transition: margin 0.25s ease-out;
}

#sidebar-wrapper .list-group-item {
    border: none;
    border-radius: 0;
    padding: 12px 20px;
}

#sidebar-wrapper .list-group-item:hover {
    background-color: #e9ecef;
}

#sidebar-wrapper .list-group-item.active {
    background-color: var(--primary-color);
    color: white;
    border-left: 4px solid #0d6832;
}

#sidebar-wrapper .list-group-item i {
    margin-right: 10px;
    width: 20px;
}

/* Page content */
#page-content-wrapper {
    flex: 1;
    padding: 0;
}

.main-content {
    padding: 30px;
    min-height: calc(100vh - 56px - 100px);
}

/* Cards */
.card {
    border: none;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.card-header {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
}

/* Stats Cards */
.stat-card {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0d6832 100%);
    color: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
}

.stat-card h3 {
    font-size: 2.5rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.stat-card p {
    margin: 0;
    opacity: 0.9;
}

.stat-card i {
    font-size: 2rem;
    opacity: 0.8;
}

/* Buttons */
.btn-primary {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.btn-primary:hover {
    background-color: #0d6832;
    border-color: #0d6832;
}

/* Tables */
.table {
    background-color: white;
}

.table thead th {
    background-color: var(--primary-color);
    color: white;
    border: none;
}

/* Forms */
.form-label {
    font-weight: 500;
    color: #495057;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(25, 135, 84, 0.25);
}

/* Alerts */
.alert {
    border-radius: 8px;
}

/* Login/Register page */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.auth-card {
    max-width: 450px;
    width: 100%;
    padding: 40px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.auth-card .logo {
    font-size: 3rem;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 20px;
}

.auth-card h2 {
    text-align: center;
    margin-bottom: 30px;
    color: #333;
}

/* Badges */
.badge {
    padding: 6px 12px;
    font-weight: 500;
}

/* Status badges */
.status-active {
    background-color: var(--success-color);
}

.status-inactive {
    background-color: var(--secondary-color);
}

.status-pending {
    background-color: var(--warning-color);
}

.status-completed {
    background-color: var(--info-color);
}

/* Calendar styles */
.calendar {
    background: white;
    border-radius: 10px;
    padding: 20px;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

/* Map container */
.map-container {
    height: 400px;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 20px;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    #sidebar-wrapper {
        margin-left: -250px;
    }

    #sidebar-wrapper.show {
        margin-left: 0;
    }

    .main-content {
        padding: 15px;
    }

    .stat-card h3 {
        font-size: 2rem;
    }
}

/* Loading spinner */
.spinner-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Notifications dropdown */
.dropdown-menu {
    max-height: 400px;
    overflow-y: auto;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #0d6832;
}

/* Print styles */
@media print {
    #sidebar-wrapper,
    .navbar,
    footer,
    .no-print {
        display: none !important;
    }

    .main-content {
        padding: 0;
    }
}
