/* ================= GLOBAL ================= */

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

body {
    font-family: 'Segoe UI', sans-serif;
    background: #f4f6f9;
    color: #333;
}

a {
    text-decoration: none;
}

/* ================= LAYOUT ================= */

.dashboard {
    display: flex;
    min-height: 100vh;
}

/* ================= SIDEBAR ================= */

.sidebar {
    width: 230px;
    background: #111827;
    color: white;
    padding: 25px 20px;
}

.logo {
    margin-bottom: 30px;
    font-size: 20px;
}

.menu {
    list-style: none;
}

.menu li {
    margin-bottom: 18px;
}

.menu li a {
    color: white;
    font-size: 15px;
    display: block;
    padding: 6px 8px;
    border-radius: 6px;
    transition: 0.2s ease;
}

.menu li a:hover {
    background: rgba(255,255,255,0.1);
}

/* ================= MAIN CONTENT ================= */

.main-content {
    flex: 1;
    padding: 30px;
}

/* ================= TOP BAR ================= */

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.top-left {
    display: flex;
    align-items: center;
}

.menu-btn {
    display: none;
    font-size: 22px;
    background: none;
    border: none;
    cursor: pointer;
    margin-right: 10px;
}

.top-bar button {
    background: #dc3545;
    color: white;
    border: none;
    padding: 7px 14px;
    border-radius: 5px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s ease;
}

.top-bar button:hover {
    background: #bb2d3b;
}

/* ================= CARDS ================= */

.card {
    background: white;
    padding: 25px;
    border-radius: 10px;
    margin-bottom: 25px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.06);
}

/* ================= DASHBOARD STATS ================= */

.stats-card {
    height: 110px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.stats-card h2 {
    font-size: 16px;
    color: #0d6efd;
    margin-bottom: 10px;
}

.stats-card p {
    font-size: 26px;
    font-weight: bold;
}

@media (min-width: 900px) {
    .dashboard-overview {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

/* ================= DOCTOR LIST ================= */

.doctor-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f8f9fa;
    padding: 12px 15px;
    border-radius: 8px;
    margin-bottom: 10px;
    transition: 0.2s ease;
}

.doctor-item:hover {
    background: #eef2f7;
}

.doctor-info {
    display: flex;
    flex-direction: column;
}

.specialization {
    font-size: 13px;
    color: #666;
}

.delete-doctor-btn,
.delete-booking-btn {
    background: #dc3545;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
    transition: 0.2s ease;
}

.delete-doctor-btn:hover,
.delete-booking-btn:hover {
    background: #bb2d3b;
}

/* ================= ADD DOCTOR FORM ================= */

.form-group {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 5px;
}

.form-group input {
    padding: 9px 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    transition: 0.2s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #0d6efd;
    box-shadow: 0 0 0 2px rgba(13,110,253,0.2);
}

.primary-btn {
    margin-top: 10px;
    padding: 10px 15px;
    background: #0d6efd;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s ease;
}

.primary-btn:hover {
    background: #0b5ed7;
}

/* ================= BOOKINGS TABLE ================= */

.booking-table {
    width: 100%;
    border-collapse: collapse;
}

.booking-table th,
.booking-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e9ecef;
    font-size: 14px;
}

.booking-table th {
    background: #f1f3f5;
    font-weight: 600;
}

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

/* ================= OVERLAY ================= */

.overlay {
    display: none;
}

/* ================= MOBILE ================= */

@media (max-width: 900px) {

    .dashboard {
        flex-direction: column;
    }

    .menu-btn {
        display: inline-block;
    }

    .sidebar {
        position: fixed;
        top: 0;
        left: -250px;
        height: 100%;
        width: 220px;
        background: #111827;
        padding: 20px;
        transition: 0.3s ease;
        z-index: 1000;
    }

    .sidebar.active {
        left: 0;
    }

    .overlay {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0,0,0,0.4);
        z-index: 900;
    }

    .overlay.active {
        display: block;
    }

    .main-content {
        padding: 15px;
    }

    .booking-table th,
    .booking-table td {
        font-size: 12px;
        padding: 8px;
    }
}

.login-container {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #f4f6f9;
}

.login-card {
    background: white;
    padding: 30px;
    border-radius: 8px;
    width: 300px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

.login-card input {
    width: 100%;
    padding: 8px;
    margin: 10px 0;
}

.login-buttons {
    display: flex;
    justify-content: space-between;
}

.error-text {
    color: red;
    font-size: 14px;
}

.back-link {
    display: block;
    margin-top: 15px;
    font-size: 14px;
}

/* ================= RESPONSIVE ================= */
