/* JMTL Driver Booking */

.jmtl-driver-booking {
    max-width: 700px;
    margin: 0 auto 40px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

.jmtl-driver-title {
    text-align: center;
    font-size: 1.6em;
    margin-bottom: 25px;
    color: #1a1a2e;
}

/* Form fields */
.jmtl-driver-form-fields {
    margin-bottom: 20px;
}

.jmtl-driver-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.jmtl-driver-row .jmtl-driver-field {
    flex: 1;
}

.jmtl-driver-field {
    margin-bottom: 15px;
    position: relative;
}

.jmtl-driver-field label {
    display: block;
    font-weight: 600;
    margin-bottom: 5px;
    font-size: 0.95em;
    color: #333;
}

.jmtl-driver-field input[type="text"],
.jmtl-driver-field input[type="date"],
.jmtl-driver-field input[type="time"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 1em;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.jmtl-driver-field input:focus {
    border-color: #2563eb;
    outline: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Autocomplete suggestions */
.jmtl-driver-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 6px 6px;
    list-style: none;
    margin: 0;
    padding: 0;
    z-index: 1000;
    max-height: 200px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    display: none;
}

.jmtl-driver-suggestions li {
    padding: 10px 12px;
    cursor: pointer;
    font-size: 0.9em;
    border-bottom: 1px solid #f0f0f0;
    color: #333;
}

.jmtl-driver-suggestions li:last-child {
    border-bottom: none;
}

.jmtl-driver-suggestions li:hover {
    background: #f0f7ff;
}

/* Map */
.jmtl-driver-map {
    width: 100%;
    height: 400px;
    border-radius: 8px;
    border: 1px solid #ddd;
    margin-bottom: 20px;
}


/* Result panel */
.jmtl-driver-result {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

.jmtl-driver-result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #e2e8f0;
}

.jmtl-driver-result-row:last-child {
    border-bottom: none;
}

.jmtl-driver-label {
    font-weight: 600;
    color: #475569;
}

.jmtl-driver-value {
    font-size: 1.1em;
    color: #1a1a2e;
}

.jmtl-driver-result-price .jmtl-driver-value {
    font-size: 1.4em;
    font-weight: 700;
    color: #2563eb;
}

/* TVA note */
.jmtl-driver-tva-note {
    text-align: center;
    font-size: 0.85em;
    color: #64748b;
    margin: 8px 0 0;
}

/* Book button */
.jmtl-driver-actions {
    text-align: center;
    margin-bottom: 15px;
}

.jmtl-driver-btn {
    background: #2563eb;
    color: #fff;
    border: none;
    padding: 14px 40px;
    font-size: 1.1em;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.jmtl-driver-btn:hover:not(:disabled) {
    background: #1d4ed8;
    transform: translateY(-1px);
}

.jmtl-driver-btn:disabled {
    background: #94a3b8;
    cursor: not-allowed;
}

/* Messages */
.jmtl-driver-message {
    padding: 12px 16px;
    border-radius: 6px;
    font-size: 0.95em;
    text-align: center;
}

.jmtl-msg-info {
    background: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

.jmtl-msg-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.jmtl-msg-success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

/* Legal notice */
.jmtl-driver-legal {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-left: 4px solid #1e3a5f;
    border-radius: 6px;
    padding: 16px 20px;
    margin: 20px 0;
    font-size: 0.85em;
    line-height: 1.5;
    color: #334155;
}

.jmtl-driver-legal p {
    margin: 4px 0;
}

.jmtl-driver-legal-title {
    font-weight: 700;
    font-size: 1.05em;
    color: #1e3a5f;
    text-transform: uppercase;
    margin-bottom: 8px !important;
}

.jmtl-driver-legal-company {
    margin-top: 8px !important;
    font-weight: 600;
}

.jmtl-driver-legal-wc {
    max-width: 700px;
}

/* Availability badge */
.jmtl-availability-badge {
    padding: 10px 14px;
    border-radius: 6px;
    margin: -5px 0 15px;
    font-size: 0.9em;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.jmtl-availability-open {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.jmtl-availability-closed {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

.jmtl-availability-icon {
    font-size: 1.2em;
    line-height: 1;
}

/* Responsive */
@media (max-width: 600px) {
    .jmtl-driver-row {
        flex-direction: column;
        gap: 0;
    }

    .jmtl-driver-map {
        height: 300px;
    }

    .jmtl-driver-btn {
        width: 100%;
    }
}
