/**
 * Denver Driver Booker - Frontend Styles
 */

/* Container */
.ddb-booking-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

/* Book Now Button */
.ddb-book-now-btn {
    background: #2A3A41;
    color: white;
    padding: 15px 40px;
    border: none;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: block;
    margin: 0 auto 20px;
}

.ddb-book-now-btn:hover {
    background: #1e2a30;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* Booking Wrapper */
.ddb-booking-wrapper {
    animation: slideDown 0.3s ease-out;
}

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

/* Form Styles */
.ddb-form-group {
    margin-bottom: 20px;
}

.ddb-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.ddb-form-group .required {
    color: #dc3232;
}

.ddb-form-group input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
    overflow: hidden;
}

/* Date input width for desktop only */
@media (min-width: 769px) {
    input[type="date" i] {
        width: 90% !important;
    }
}

.ddb-form-group input:focus {
    outline: none;
    border-color: #2A3A41;
    box-shadow: 0 0 0 2px rgba(42, 58, 65, 0.1);
}

.ddb-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Submit Button */
.ddb-submit-btn {
    background: #2A3A41;
    color: white;
    padding: 12px 30px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.ddb-submit-btn:hover {
    background: #1e2a30;
}

.ddb-submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Loading State */
.ddb-loading {
    text-align: center;
    padding: 40px;
}

.ddb-spinner {
    display: inline-block;
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #2A3A41;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Results Section */
.ddb-results {
    margin-top: 40px;
}

/* Driver Cards */
.ddb-drivers-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.ddb-driver-card {
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.ddb-driver-card:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

/* Driver Thumbnail */
.ddb-driver-thumbnail {
    width: 100px;
    height: 100px;
    margin-bottom: 15px;
}

.ddb-driver-thumbnail img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
}

/* Driver Name */
.ddb-driver-name {
    margin: 0 0 10px 0;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

/* Car Details */
.ddb-car-details {
    color: #666;
    margin-bottom: 10px;
    font-size: 14px;
}

/* Price */
.ddb-price {
    font-size: 24px;
    font-weight: bold;
    color: #2A3A41;
    margin-bottom: 15px;
}

/* Contact Buttons */
.ddb-contact-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 15px;
    width: 100%;
}

.ddb-contact-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #f0f0f0;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s;
    padding: 8px;
}

.ddb-contact-btn:hover {
    background: #e0e0e0;
    transform: scale(1.1);
}

.ddb-contact-btn img {
    width: 24px;
    height: 24px;
}

/* Pay Now Button */
.ddb-pay-now-btn {
    width: 100%;
    padding: 12px 20px;
    background: #2A3A41;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
    margin-bottom: 10px;
}

.ddb-pay-now-btn:hover {
    background: #1e2a30;
}

/* What is included Section */
.ddb-included-section {
    width: 100%;
}

.ddb-included-toggle {
    width: 100%;
    padding: 10px;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.3s;
}

.ddb-included-toggle:hover {
    background: #f0f0f0;
}

.ddb-included-toggle .dashicons {
    transition: transform 0.3s;
}

.ddb-included-toggle.active .dashicons {
    transform: rotate(180deg);
}

.ddb-included-content {
    display: none;
    padding: 15px;
    background: #f9f9f9;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    font-size: 14px;
    text-align: left;
    color: #666;
}

/* Styles for included list in frontend */
.ddb-included-content .ddb-included-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.ddb-included-content .ddb-included-list li {
    padding: 10px;
    margin-bottom: 8px;
    background: #fff;
    border-left: 3px solid #2A3A41;
}

.ddb-included-content .ddb-included-list li strong {
    display: block;
    margin-bottom: 3px;
    color: #2A3A41;
}

.ddb-included-content .ddb-included-list li p {
    margin: 0;
    font-size: 13px;
}

.ddb-included-content .ddb-refund-policy-link {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #ddd;
    text-align: center;
}

.ddb-included-content .ddb-refund-policy-link h4 {
    margin: 0 0 5px 0;
    font-size: 14px;
    color: #2A3A41;
}

.ddb-included-content .ddb-refund-policy-link p {
    margin: 0;
    font-size: 13px;
}

/* Error Messages */
.ddb-error {
    background: #fcf0f1;
    border-left: 4px solid #dc3232;
    padding: 15px;
    margin-top: 20px;
    border-radius: 4px;
}

/* Payment Modal */
.ddb-modal {
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.ddb-modal-content {
    background-color: #fefefe;
    margin: 5% auto;
    padding: 30px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

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

.ddb-modal-close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    line-height: 20px;
}

.ddb-modal-close:hover,
.ddb-modal-close:focus {
    color: #000;
}

.ddb-payment-summary {
    background: #f9f9f9;
    padding: 20px;
    border-radius: 4px;
    margin: 20px 0;
}

.ddb-payment-summary h3 {
    margin-top: 0;
    color: #2A3A41;
}

.ddb-summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #e0e0e0;
}

.ddb-summary-row:last-child {
    border-bottom: none;
}

.ddb-total-row {
    margin-top: 10px;
    padding-top: 15px;
    border-top: 2px solid #2A3A41;
    font-weight: bold;
    font-size: 18px;
    color: #2A3A41;
}

#ddb-payment-form .ddb-form-group {
    margin-bottom: 15px;
}

#ddb-payment-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
}

#ddb-payment-form input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.ddb-proceed-btn {
    width: 100%;
    padding: 15px;
    background: #2A3A41;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s;
}

.ddb-proceed-btn:hover {
    background: #1e2a30;
}

.ddb-proceed-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Responsive Design */
@media (max-width: 768px) {
    .ddb-booking-container {
        padding: 0;
    }
    
    .ddb-booking-form {
        padding: 15px;
        border-radius: 0;
    }
    
    .ddb-form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .ddb-form-group {
        margin-bottom: 15px;
    }
    
    .ddb-drivers-list {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .ddb-driver-card {
        padding: 15px;
    }
    
    .ddb-driver-thumbnail {
        width: 80px;
        height: 80px;
    }
    
    .ddb-book-now-btn {
        width: 100%;
        font-size: 16px;
        padding: 12px 30px;
    }
}
