/* main styles */

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

body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    line-height: 1.6;
}

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

.header {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header h1 {
    color: #333;
    font-size: 2.5em;
}

.header img {
    max-width: 200px;
    height: auto;
    margin-bottom: 15px;
}

.driver-login-form {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.driver-login-form h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #333;
}

form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.admin-login-link {
    text-align: center;
    margin-top: 20px;
    color: #007bff;
    text-decoration: none;
}

input {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

/* Make selects used as inputs match input sizing and be mobile-friendly */
.location-input {
    width: 100%;
}

select.location-input {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    background-color: #fff;
}

button {
    padding: 12px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #0056b3;
}

button:disabled {
    background-color: #a0aec0;
    cursor: not-allowed;
    opacity: 0.75;
}

/* Employee Interface Styles */
.employee-dashboard {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    text-align: center;
}

.dashboard-card h3 {
    color: #333;
    margin-bottom: 10px;
}

.dashboard-card p {
    color: #666;
    margin-bottom: 15px;
}

.dashboard-btn {
    background-color: #28a745;
    padding: 10px 20px;
    font-size: 14px;
}

.dashboard-btn:hover {
    background-color: #218838;
}

.logout-section {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.logout-btn {
    display: inline-block;
    padding: 12px 24px;
    background-color: #dc3545;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s;
}

.logout-btn:hover {
    background-color: #c82333;
}

/* end main styles */

/* Admin Portal Styles */

.admin-dashboard {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.admin-dashboard h2 {
    text-align: center;
    margin-bottom: 15px;
    color: #333;
    font-size: 2em;
}

.admin-dashboard p {
    text-align: center;
    margin-bottom: 30px;
    color: #666;
    font-size: 16px;
}

.admin-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.card {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    text-align: center;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.card h3 {
    color: #333;
    margin-bottom: 10px;
    font-size: 18px;
}

.card p {
    color: #666;
    margin-bottom: 15px;
    font-size: 14px;
}

.card button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
    width: 100%;
    margin-top: 10px;
}

.card button:hover {
    background-color: #0056b3;
}

.card a {
    text-decoration: none;
    display: block;
}

.card a button {
    width: 100%;
}

.logout-section {
    text-align: center;
    margin-top: 20px;
}

.logout-section .btn-logout {
    display: inline-block;
    padding: 12px 24px;
    background-color: #dc3545;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.logout-section .btn-logout:hover {
    background-color: #c82333;
}

/* End Admin Portal Styles */

/* manage drivers styles */

.driver-table-wrapper {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.driver-table {
    width: 100%;
    border-collapse: collapse;
    margin: 0 auto;
}

.driver-table th,
.driver-table td {
    padding: 15px;
    text-align: center;
    border-bottom: 1px solid #eee;
}

.driver-table th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: #333;
    font-size: 16px;
}

.driver-table td {
    color: #666;
    font-size: 14px;
}

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

.edit-btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.edit-btn:hover {
    background-color: #0056b3;
}

.back-button-section {
    text-align: center;
    margin-top: 20px;
}

.back-button-section .btn-logout {
    display: inline-block;
    padding: 12px 24px;
    background-color: #6c757d;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background-color 0.3s;
    border: none;
    cursor: pointer;
    font-size: 16px;
}

.back-button-section .btn-logout:hover {
    background-color: #5a6268;
}

/* end manage drivers styles */

/* Spacing for action buttons in Manage Drivers */
.driver-table .save-btn,
.driver-table .save-new-btn {
    margin-right: 10px;
}

.driver-table .cancel-btn,
.driver-table .cancel-new-btn {
    margin-left: 10px;
}

/* Edit buttons row styling */
.edit-buttons-row .save-btn,
.edit-buttons-row .cancel-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
    margin: 0 5px;
}

.edit-buttons-row .save-btn:hover {
    background-color: #218838;
}

.edit-buttons-row .cancel-btn {
    background-color: #6c757d;
}

.edit-buttons-row .cancel-btn:hover {
    background-color: #5a6268;
}

/* Add buttons row styling */
.add-buttons-row .save-new-btn,
.add-buttons-row .cancel-new-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
    margin: 0 5px;
}

.add-buttons-row .save-new-btn:hover {
    background-color: #218838;
}

.add-buttons-row .cancel-new-btn {
    background-color: #6c757d;
}

.add-buttons-row .cancel-new-btn:hover {
    background-color: #5a6268;
}

/* Dumpster Inventory Styles */

.dumpster-dashboard {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.map-section {
    margin-bottom: 30px;
    text-align: center;
}

.map-section h3 {
    color: #333;
    margin-bottom: 15px;
    font-size: 18px;
}

.map-image {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 10px;
    border: 1px solid #e9ecef;
}

.note {
    color: #666;
    font-size: 14px;
    font-style: italic;
}

.assign-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.assign-btn:hover {
    background-color: #218838;
}

/* End Dumpster Inventory Styles */

/* Logs Page Styles */

.logs-dashboard {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.logs-header {
    text-align: center;
    margin-bottom: 20px;
}

.logs-header p {
    font-weight: bold;
    margin-bottom: 0;
    color: #333;
    font-size: 16px;
}

.highlight {
    color: #007bff;
    font-weight: bold;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin: 30px 0;
    padding: 20px 0;
    border-top: 1px solid #e9ecef;
}

.pagination-btn {
    background-color: #6c757d;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.pagination-btn:hover {
    background-color: #5a6268;
}

.page-number {
    color: #666;
    font-size: 14px;
    font-weight: bold;
}

.export-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.export-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.export-btn:hover {
    background-color: #218838;
}

/* End Logs Page Styles */

/* Messages Page Styles */

.messages-dashboard {
    background-color: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.message-box {
    width: 100%;
    min-height: 60px;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    font-family: Arial, sans-serif;
    resize: vertical;
}

.global-message-section {
    text-align: center;
    margin: 30px 0;
    padding: 20px 0;
    border-top: 1px solid #e9ecef;
}

.global-message-section h3 {
    color: #333;
    margin-bottom: 15px;
    font-size: 18px;
}

.global-message-box {
    width: 100%;
    min-height: 120px;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    font-family: Arial, sans-serif;
    resize: vertical;
    max-width: 600px;
    margin: 0 auto;
    display: block;
}

.message-controls {
    text-align: center;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.send-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s;
}

.send-btn:hover {
    background-color: #218838;
}

.message-all-btn {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    transition: background-color 0.3s;
}

.message-all-btn:hover {
    background-color: #218838;
}

/* End Messages Page Styles */

/* Form Layout Utilities - Modern Styling */
.form-row {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-top: 20px;
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 8px;
    font-weight: 600;
    color: #444;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ced4da;
    border-radius: 6px;
    font-size: 16px;
    background-color: #fff;
    transition: border-color 0.2s, box-shadow 0.2s;
    height: 48px;
    /* Ensure uniform height */
}

.form-group input:focus,
.form-group select:focus {
    border-color: #74B12F;
    outline: none;
    box-shadow: 0 0 0 3px rgba(116, 177, 47, 0.2);
}

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 35px;
    padding-top: 25px;
    border-top: 1px solid #eee;
}

/* Enhancing existing buttons */
.dropoff-btn,
.pickup-btn {
    background-color: #007bff;
    color: white;
    padding: 12px 28px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 6px rgba(0, 123, 255, 0.2);
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.dropoff-btn:hover,
.pickup-btn:hover {
    background-color: #0056b3;
    transform: translateY(-1px);
    box-shadow: 0 6px 8px rgba(0, 123, 255, 0.3);
}

.dropoff-btn:disabled,
.pickup-btn:disabled {
    background-color: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-logout {
    background-color: #6c757d;
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-logout:hover {
    background-color: #5a6268;
}

/* Use Location Button Modernized */
#use-location-btn {
    margin-top: 8px;
    background-color: #e9ecef !important;
    color: #495057 !important;
    border: 1px solid #ced4da !important;
    font-weight: 500;
    transition: all 0.2s;
    width: 100%;
    margin-bottom: 20px;
    /* Space before next group */
}

#use-location-btn:hover {
    background-color: #dde2e6 !important;
    border-color: #adb5bd !important;
    color: #212529 !important;
}

.dropoff-wrapper {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
}

/* Notification Badge Styles */
.notification-badge {
    position: absolute;
    top: -8px;
    right: -12px;
    background: #ff4444;
    color: white;
    border-radius: 50%;
    padding: 2px 7px;
    font-size: 12px;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 68, 68, 0.7);
    }

    50% {
        transform: scale(1.1);
        box-shadow: 0 0 0 10px rgba(255, 68, 68, 0);
    }

    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 68, 68, 0);
    }
}

.bell-icon {
    transition: transform 0.2s ease;
}

.bell-icon:hover {
    transform: scale(1.2);
}
/* ===== SaaS: trial banner, onboarding & organization pages ===== */
.saas-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 10px 16px;
    font-size: 15px;
    text-align: center;
}

.saas-banner-info {
    background: #eaf6d9;
    color: #365a12;
    border-bottom: 1px solid #c8e3a3;
}

.saas-banner-warn {
    background: #fff1e6;
    color: #8a3b00;
    border-bottom: 1px solid #ffc89a;
}

.saas-banner a {
    color: inherit;
    font-weight: bold;
    text-decoration: underline;
}

.saas-panel {
    background: #fff;
    padding: 24px 30px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.saas-panel h2 {
    color: #333;
    margin-bottom: 8px;
}

.saas-panel h3 {
    color: #333;
    margin: 16px 0 10px;
}

.saas-panel p.muted,
.saas-muted {
    color: #666;
    font-size: 14px;
}

.saas-status {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: bold;
    text-transform: capitalize;
}

.saas-status-active,
.saas-status-trialing {
    background: #eaf6d9;
    color: #365a12;
}

.saas-status-past_due {
    background: #fff1e6;
    color: #8a3b00;
}

.saas-status-expired,
.saas-status-canceled {
    background: #fde2e2;
    color: #8a1c1c;
}

.saas-inline-form {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.saas-inline-form input,
.saas-inline-form select {
    flex: 1 1 180px;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 15px;
}

.saas-inline-form button {
    flex: 0 0 auto;
}

.saas-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
}

.saas-table th,
.saas-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #eee;
    text-align: left;
    vertical-align: middle;
}

.saas-table th {
    background: #f7f7f7;
    color: #444;
}

.saas-table select {
    padding: 6px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

.saas-table .btn-small {
    padding: 6px 10px;
    font-size: 13px;
}

.btn-secondary {
    background: #6c757d;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-danger {
    background: #c0392b;
}

.btn-danger:hover {
    background: #a93226;
}

.saas-message {
    margin-top: 12px;
    padding: 10px;
    border-radius: 4px;
    font-size: 14px;
    display: none;
}

.saas-message.ok {
    display: block;
    background: #eaf6d9;
    color: #365a12;
}

.saas-message.err {
    display: block;
    background: #fde2e2;
    color: #8a1c1c;
}

.brand-dialog {
    box-sizing: border-box;
    width: min(420px, calc(100vw - 32px));
    padding: 28px;
    border: 0;
    border-radius: 12px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, .22);
    color: #333;
    font: 16px/1.5 Arial, sans-serif;
}

.brand-dialog::backdrop { background: rgba(0, 0, 0, .42); }
.brand-dialog h2 { margin: 0 0 12px; font-size: 23px; }
.brand-dialog p { margin: 0; }
.brand-dialog form { display: flex; justify-content: flex-end; margin-top: 24px; }
.brand-dialog button {
    min-width: 80px;
    padding: 10px 18px;
    border: 0;
    border-radius: 6px;
    background: #0d6efd;
    color: #fff;
    font: inherit;
    cursor: pointer;
}
.brand-dialog button:focus-visible { outline: 3px solid #74b12f; outline-offset: 3px; }

.saas-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 12px;
}

.saas-invite-link {
    word-break: break-all;
    font-family: monospace;
    font-size: 12px;
    background: #f7f7f7;
    padding: 8px;
    border-radius: 4px;
}
