/* ========== Common Styles - shared across all pages ========== */
/* Dynamic Island styles are in dynamic-island.css */

/* Message styles */
.message {
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 15px;
    font-size: 14px;
}

.message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Custom modal overlay (not Bootstrap modal) - uses ID selectors to avoid Bootstrap conflict */
#imageModal,
#messageModal,
#autoFillModal,
#multipleVehiclesModal,
#vehicleModal,
#renameModal,
#renameRouteModal,
#renameBrandModal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: transparent;
    backdrop-filter: blur(8px) brightness(0.95);
    -webkit-backdrop-filter: blur(8px) brightness(0.95);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

#imageModal.show,
#messageModal.show,
#autoFillModal.show,
#multipleVehiclesModal.show,
#vehicleModal.show,
#renameModal.show,
#renameRouteModal.show,
#renameBrandModal.show {
    display: flex;
    opacity: 1;
    visibility: visible;
}

#imageModal .modal-content,
#messageModal .modal-content,
#autoFillModal .modal-content,
#multipleVehiclesModal .modal-content,
#vehicleModal .modal-content,
#renameModal .modal-content,
#renameRouteModal .modal-content,
#renameBrandModal .modal-content {
    background-color: var(--card-bg, #fff);
    margin: auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 800px;
    position: relative;
    box-shadow: var(--shadow-lg, 0 10px 40px rgba(0,0,0,0.2));
    transform: scale(0.9);
    transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}

#imageModal.show .modal-content,
#messageModal.show .modal-content,
#autoFillModal.show .modal-content,
#multipleVehiclesModal.show .modal-content,
#vehicleModal.show .modal-content,
#renameModal.show .modal-content,
#renameRouteModal.show .modal-content,
#renameBrandModal.show .modal-content {
    transform: scale(1);
}

.modal-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

/* Button styles - custom buttons only (Bootstrap .btn is loaded separately) */

.btn-approve {
    background: #4CAF50;
    color: white;
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
}

.btn-approve:hover { background: #45a049; }

.btn-reject {
    background: #f44336;
    color: white;
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
}

.btn-reject:hover { background: #da190b; }

.btn-delete {
    background: #ff5722;
    color: white;
    padding: 6px 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
}

.btn-delete:hover { background: #e64a19; }

/* Status badge (avoid Bootstrap .badge conflict) */
.custom-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.status-badge.pending { background: #fff3cd; color: #856404; }
.status-badge.approved { background: #d4edda; color: #155724; }
.status-badge.rejected { background: #f8d7da; color: #721c24; }

/* Close button - scoped to modal context to avoid Bootstrap conflict */
#imageModal .close,
#messageModal .close,
#autoFillModal .close,
#multipleVehiclesModal .close,
#vehicleModal .close,
#renameModal .close,
#renameRouteModal .close,
#renameBrandModal .close {
    position: absolute;
    right: 20px;
    top: 15px;
    color: var(--text-secondary, #666);
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10;
    transition: color 0.3s ease;
    background: none;
    border: none;
    padding: 0;
    line-height: 1;
}

#imageModal .close:hover,
#messageModal .close:hover,
#autoFillModal .close:hover,
#multipleVehiclesModal .close:hover,
#vehicleModal .close:hover,
#renameModal .close:hover,
#renameRouteModal .close:hover,
#renameBrandModal .close:hover {
    color: var(--text-color, #333);
}

/* Note: .container, .header, .footer are defined in style.css - do not duplicate here */

/* Form styles */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--text-color, #333);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border-color, #e0e0e0);
    border-radius: 6px;
    font-size: 14px;
    background: var(--card-bg, #fff);
    color: var(--text-color, #333);
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color, #4a90d9);
}

/* Note: .card is defined in style.css - do not duplicate here */

/* Note: .active styles are handled per-page */

/* Suggestions dropdown */
.suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--card-bg, #fff);
    border: 1px solid var(--border-color, #e0e0e0);
    border-radius: 0 0 6px 6px;
    box-shadow: var(--shadow-sm, 0 2px 4px rgba(0,0,0,0.1));
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
    display: none;
}

.suggestion-item {
    padding: 10px 12px;
    cursor: pointer;
    font-size: 14px;
    color: var(--text-color, #333);
    transition: background 0.2s ease;
}

.suggestion-item:hover {
    background: var(--bg-color, #f5f5f5);
}
