﻿.appointment-form {
    background-color: #8b5a2b;
    padding: 40px;
    border-radius: 15px;
    margin: 30px auto;
    max-width: 900px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
}

    .appointment-form h2 {
        color: #ffffff;
        font-family: 'Segoe UI', Arial, sans-serif;
        font-size: 28px;
        font-weight: 600;
        margin-bottom: 30px;
        text-align: center;
        text-transform: uppercase;
    }

    .appointment-form .row.g-3 {
        margin-bottom: 20px;
    }

    .appointment-form .col-md-6 {
        display: flex;
        flex-direction: column;
        min-width: 0; /* Prevent flex shrinking */
        position: relative; /* Allow dropdown to expand */
        overflow: visible; /* Ensure dropdown options aren't clipped */
    }

    .appointment-form label {
        color: #ffffff;
        font-family: 'Segoe UI', Arial, sans-serif;
        font-size: 16px;
        font-weight: 500;
        margin-bottom: 8px;
    }

    .appointment-form .required {
        color: #ff4d4d;
    }

    .appointment-form .form-control {
        width: 100%;
        padding: 12px;
        border: none;
        border-radius: 8px;
        font-family: 'Segoe UI', Arial, sans-serif;
        font-size: 15px;
        background-color: #ffffff;
        box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
        transition: box-shadow 0.3s ease;
        appearance: none; /* Remove default browser styling */
        -webkit-appearance: none;
        -moz-appearance: none;
        position: relative;
        z-index: 2; /* Ensure dropdown can overlap other elements */
        min-height: 44px; /* Ensure enough height for the dropdown */
    }

    /* Specific styling for select elements */
    .appointment-form select.form-control {
        background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg>');
        background-repeat: no-repeat;
        background-position: right 12px center;
        background-size: 16px;
        padding-right: 36px; /* Space for the arrow */
        cursor: pointer;
    }

        /* Ensure dropdown options are visible */
        .appointment-form select.form-control option {
            background-color: #ffffff;
            color: #333333;
            font-family: 'Segoe UI', Arial, sans-serif;
            font-size: 15px;
            padding: 8px; /* Ensure options are readable */
        }

    .appointment-form .form-control:focus {
        outline: none;
        box-shadow: 0 0 8px rgba(0, 123, 255, 0.5);
    }

.dark-mode .appointment-form .form-control {
    background-color: #444444;
    color: #ffffff;
    border: 1px solid #555555;
}

.dark-mode .appointment-form select.form-control {
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg>');
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 36px;
}

    .dark-mode .appointment-form select.form-control option {
        background-color: #444444;
        color: #ffffff;
    }

.appointment-form .form-text {
    color: #ffd700;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 13px;
    font-style: italic;
}

.appointment-form .appointment-type-label {
    color: #ffffff;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 15px;
    font-weight: 500;
    padding: 12px 25px;
    border: 2px solid #ffffff;
    border-radius: 8px;
    display: inline-block;
}

.appointment-form .form-row {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 20px;
    gap: 20px;
}

.appointment-form .form-group {
    flex: 1;
    min-width: 300px;
}

    .appointment-form .form-group:last-child {
        margin-right: 0;
    }

.appointment-form .appointment-time .time-slots {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    margin-top: 10px;
}

    .appointment-form .appointment-time .time-slots label {
        color: #333333;
        background-color: #f8f9fa;
        padding: 10px;
        border: 2px solid #d1d3e2;
        border-radius: 8px;
        cursor: pointer;
        text-align: center;
        font-family: 'Segoe UI', Arial, sans-serif;
        font-size: 14px;
        font-weight: 500;
        transition: all 0.3s ease;
    }

    .appointment-form .appointment-time .time-slots input[type="radio"] {
        display: none;
    }

        .appointment-form .appointment-time .time-slots input[type="radio"]:checked + label {
            background-color: #28a745;
            color: #ffffff;
            border-color: #28a745;
            box-shadow: 0 4px 8px rgba(40, 167, 69, 0.3);
        }

    .appointment-form .appointment-time .time-slots label:hover {
        background-color: #e2e6ea;
        border-color: #adb5bd;
    }

.appointment-form .custom-submit-btn {
    background-color: #28a745;
    border: none;
    padding: 15px 30px;
    font-family: 'Segoe UI', Arial, sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #ffffff;
    text-transform: uppercase;
    width: 100%;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(40, 167, 69, 0.3);
    transition: all 0.3s ease;
}

    .appointment-form .custom-submit-btn:hover {
        background-color: #218838;
        box-shadow: 0 6px 12px rgba(33, 136, 56, 0.4);
    }

.dark-mode .appointment-form {
    background-color: #333333;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.4);
}

    .dark-mode .appointment-form h2 {
        color: #ffffff;
    }

    .dark-mode .appointment-form label {
        color: #ffffff;
    }

    .dark-mode .appointment-form .form-text {
        color: #ffd700;
    }

    .dark-mode .appointment-form .appointment-type-label {
        color: #ffffff;
        border-color: #666666;
    }

    .dark-mode .appointment-form .appointment-time .time-slots label {
        color: #ffffff;
        background-color: #555555;
        border-color: #666666;
    }

    .dark-mode .appointment-form .appointment-time .time-slots input[type="radio"]:checked + label {
        background-color: #38c172;
        border-color: #38c172;
        box-shadow: 0 4px 8px rgba(56, 193, 114, 0.3);
    }

    .dark-mode .appointment-form .appointment-time .time-slots label:hover {
        background-color: #666666;
        border-color: #777777;
    }

    .dark-mode .appointment-form .custom-submit-btn {
        background-color: #38c172;
        box-shadow: 0 4px 8px rgba(56, 193, 114, 0.3);
    }

        .dark-mode .appointment-form .custom-submit-btn:hover {
            background-color: #2a9957;
            box-shadow: 0 6px 12px rgba(42, 153, 87, 0.4);
        }
