.msw-widget-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 20px;
    padding: 24px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, .06);
}

.msw-widget-head h3 {
    margin: 0 0 8px;
    font-size: 24px;
}

.msw-widget-head p {
    margin: 0 0 18px;
    color: #475569;
}

.msw-field-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
}

.msw-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.msw-field-full {
    grid-column: 1 / -1;
}

.msw-field input,
.msw-field select,
.msw-field textarea {
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid #cbd5e1;
    min-height: 48px;
}

.msw-field textarea {
    min-height: 120px;
}

.msw-booking-form {
    display: grid;
    gap: 18px;
}

.msw-booking-shell {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
}

.msw-booking-has-sidebar .msw-booking-shell {
    grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
    align-items: start;
}

.msw-booking-sidebar {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid #e2e8f0;
    background: #f8fafc;
    position: sticky;
    top: 20px;
}

.msw-booking-sidebar-head {
    display: grid;
    gap: 6px;
}

.msw-booking-sidebar-head strong {
    color: #0f172a;
}

.msw-booking-sidebar-head span {
    color: #64748b;
    font-size: 14px;
    line-height: 1.5;
}

.msw-booking-main {
    display: grid;
    gap: 18px;
}

.msw-booking-calendar-panel,
.msw-booking-slot-panel {
    display: grid;
    gap: 14px;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid #e2e8f0;
    background: #fff;
}

.msw-booking-calendar-head {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
}

.msw-booking-calendar-head > div {
    display: grid;
    gap: 4px;
}

.msw-booking-calendar-head strong {
    color: #0f172a;
}

.msw-booking-calendar-head span {
    color: #64748b;
    font-size: 14px;
}

.msw-booking-calendar,
.msw-booking-slots {
    display: grid;
    gap: 12px;
}

.msw-calendar-template-grid_classic .msw-booking-calendar,
.msw-calendar-template-grid_classic .msw-booking-slots {
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
}

.msw-calendar-template-grid_soft .msw-booking-calendar,
.msw-calendar-template-grid_soft .msw-booking-slots {
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
}

.msw-calendar-template-list .msw-booking-calendar,
.msw-calendar-template-list .msw-booking-slots {
    grid-template-columns: minmax(0, 1fr);
}

.msw-calendar-day,
.msw-slot-option {
    display: grid;
    gap: 6px;
    width: 100%;
    padding: 14px;
    border-radius: 16px;
    border: 1px solid #dbe3ee;
    background: #fff;
    color: #0f172a;
    cursor: pointer;
    text-align: left;
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease, background-color .15s ease;
}

.msw-calendar-day:hover,
.msw-slot-option:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(15, 23, 42, .08);
    border-color: #94a3b8;
}

.msw-calendar-day.is-active,
.msw-slot-option.is-active {
    background: #111827;
    border-color: #111827;
    color: #fff;
}

.msw-calendar-day-weekday,
.msw-calendar-day-month {
    font-size: 13px;
    text-transform: capitalize;
    color: inherit;
    opacity: .84;
}

.msw-calendar-day-number {
    font-size: 24px;
    line-height: 1;
}

.msw-calendar-template-grid_soft .msw-calendar-day,
.msw-calendar-template-grid_soft .msw-slot-option {
    border-radius: 22px;
    background: linear-gradient(180deg, #fff 0%, #f8fafc 100%);
}

.msw-calendar-template-list .msw-calendar-day,
.msw-calendar-template-list .msw-slot-option {
    grid-template-columns: auto auto 1fr;
    align-items: center;
}

.msw-calendar-template-list .msw-slot-option {
    grid-template-columns: minmax(0, 1fr);
}

.msw-booking-native-date-field input[type=date] {
    max-width: 280px;
}

.msw-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #111827;
    color: #fff;
    border: 1px solid #111827;
    padding: 14px 22px;
    border-radius: 14px;
    cursor: pointer;
    margin-top: 16px;
    text-decoration: none;
}

.msw-btn-small {
    padding: 10px 16px;
    margin-top: 0;
}

.msw-response {
    margin-top: 14px;
    font-weight: 600;
}

.msw-response.is-error {
    color: #b91c1c;
}

.msw-response.is-success {
    color: #166534;
}

.msw-dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 18px;
}

.msw-dashboard-panel {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.msw-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    margin: 0 0 18px;
}

.msw-summary-card {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 16px;
    background: #f8fafc;
}

.msw-summary-card span {
    display: block;
    color: #64748b;
    font-size: 13px;
}

.msw-summary-card strong {
    display: block;
    font-size: 20px;
    color: #0f172a;
}

.msw-dashboard-card {
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 14px;
    background: #fff;
}

.msw-dashboard-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.msw-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 10px;
    border-radius: 999px;
    font-size: 12px;
    font-weight: 700;
}

.msw-status-pending {
    background: #fef3c7;
    color: #92400e;
}

.msw-status-accepted {
    background: #dcfce7;
    color: #166534;
}

.msw-status-rejected {
    background: #fee2e2;
    color: #b91c1c;
}

.msw-dashboard-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
    margin: 12px 0;
}

.msw-dashboard-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.msw-dashboard-actions button,
.msw-availability-item button {
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid #111827;
    background: #111827;
    color: #fff;
    cursor: pointer;
}

.msw-dashboard-actions button.msw-reject,
.msw-dashboard-actions button.msw-toggle-messages {
    background: #fff;
    color: #111827;
}

.msw-booking-note {
    margin: 14px 0;
    padding: 14px;
    border-radius: 14px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
}

.msw-booking-note strong {
    display: block;
    margin-bottom: 8px;
}

.msw-booking-note p {
    margin: 0;
    color: #334155;
}

.msw-booking-messages {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e2e8f0;
}

.msw-booking-messages[hidden] {
    display: none !important;
}

.msw-message-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 16px;
}

.msw-message-item {
    padding: 14px;
    border-radius: 14px;
    border: 1px solid #e2e8f0;
    background: #fff;
}

.msw-message-customer {
    background: #eff6ff;
    border-color: #bfdbfe;
}

.msw-message-doctor,
.msw-message-manager {
    background: #f8fafc;
}

.msw-message-system {
    background: #fefce8;
    border-color: #fde68a;
}

.msw-message-meta {
    display: grid;
    gap: 4px;
    margin-bottom: 10px;
}

.msw-message-meta strong {
    color: #0f172a;
}

.msw-message-meta span,
.msw-message-meta time {
    color: #64748b;
    font-size: 13px;
}

.msw-message-body {
    color: #334155;
    line-height: 1.5;
}

.msw-booking-message-form .msw-btn {
    margin-top: 0;
}

.msw-customer-booking-summary {
    margin-bottom: 18px;
}

.msw-customer-portal .msw-booking-messages {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
}

.msw-customer-portal .msw-message-list {
    margin-top: 8px;
}

.msw-empty-state {
    padding: 20px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    color: #64748b;
}

.msw-availability-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.msw-availability-item {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 12px;
    align-items: center;
    padding: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
}

.msw-login-widget form {
    display: grid;
    gap: 14px;
}

.msw-login-widget label {
    display: block;
    margin-bottom: 6px;
}

.msw-login-widget input[type=text],
.msw-login-widget input[type=password] {
    width: 100%;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid #cbd5e1;
}

.msw-login-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.msw-login-remember {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    color: #334155;
}

.msw-login-widget input[type=checkbox] {
    width: 16px;
    height: 16px;
}

.msw-login-link {
    color: #0f172a;
    text-decoration: none;
    font-weight: 600;
}

.msw-login-link:hover {
    text-decoration: underline;
}

.msw-login-captcha {
    padding: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 16px;
    background: #f8fafc;
}

@media (max-width: 767px) {
    .msw-booking-has-sidebar .msw-booking-shell {
        grid-template-columns: minmax(0, 1fr);
    }

    .msw-booking-sidebar {
        position: static;
    }

    .msw-booking-calendar-head {
        align-items: flex-start;
    }

    .msw-calendar-template-list .msw-calendar-day {
        grid-template-columns: 1fr;
    }

    .msw-login-row {
        align-items: flex-start;
        flex-direction: column;
    }
}

/* ---------- Doctor Sidebar Widget ---------- */

.msw-sidebar-doctors {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 8px 20px rgba(15,23,42,.05);
}

.msw-sidebar-title {
    font-size: 18px;
    font-weight: 700;
    margin: 0 0 16px;
    color: #1e1b4b;
}

.msw-sidebar-doctor-item {
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 2px;
    margin-bottom: 2px;
}

.msw-sidebar-doctor-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.msw-sidebar-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    background: none;
    border: none;
    padding: 10px 0;
    cursor: pointer;
    text-align: left;
    font-size: 14px;
    color: #334155;
    transition: color .2s ease;
}

.msw-sidebar-toggle:hover { color: #7c3aed; }

.msw-sidebar-doctor-name {
    font-weight: 600;
    flex: 1;
}

.msw-sidebar-doctor-role {
    font-size: 11px;
    background: #f3e8ff;
    color: #7c3aed;
    padding: 2px 8px;
    border-radius: 6px;
    white-space: nowrap;
}

.msw-sidebar-chevron {
    font-size: 16px;
    width: 16px;
    height: 16px;
    transition: transform .2s ease;
}

.msw-sidebar-doctor-detail {
    padding: 0 0 12px 4px;
}

.msw-sidebar-bio {
    font-size: 13px;
    color: #64748b;
    margin: 0 0 8px;
    line-height: 1.5;
}

.msw-sidebar-contact {
    font-size: 13px;
    color: #475569;
    margin: 0 0 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.msw-sidebar-contact .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
    color: #94a3b8;
}

.msw-sidebar-services {
    list-style: none;
    margin: 8px 0 0;
    padding: 0;
}

.msw-sidebar-services li {
    font-size: 13px;
    padding: 4px 0;
    border-bottom: 1px dashed #e2e8f0;
    color: #334155;
}

.msw-sidebar-services li:last-child { border-bottom: none; }

.msw-sidebar-services li small {
    color: #94a3b8;
    font-size: 11px;
}

/* ---------- Site Search Widget ---------- */

.msw-site-search-wrap {
    max-width: 1200px;
}

.msw-site-search-title {
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 16px;
    color: #1e1b4b;
}

.msw-site-search-filters {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.msw-site-search-input {
    flex: 1;
    min-width: 200px;
    padding: 10px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    font-size: 14px;
    outline: none;
    transition: border-color .2s;
}

.msw-site-search-input:focus {
    border-color: #7c3aed;
}

.msw-site-search-category {
    padding: 10px 14px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    font-size: 14px;
    background: #fff;
    min-width: 180px;
}

.msw-site-search-grid {
    display: grid;
    gap: 16px;
}

.msw-site-card {
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 14px;
    padding: 18px;
    box-shadow: 0 4px 12px rgba(15,23,42,.04);
    transition: box-shadow .2s, transform .2s;
}

.msw-site-card:hover {
    box-shadow: 0 8px 24px rgba(15,23,42,.08);
    transform: translateY(-2px);
}

.msw-site-card-name {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 6px;
    color: #1e1b4b;
}

.msw-site-card-category {
    display: inline-block;
    font-size: 11px;
    background: #f1f5f9;
    color: #475569;
    padding: 2px 8px;
    border-radius: 6px;
    margin-bottom: 8px;
}

.msw-site-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

.msw-site-tag {
    font-size: 11px;
    padding: 2px 8px;
    border-radius: 6px;
    white-space: nowrap;
}

.msw-site-card-link {
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity .2s;
}

.msw-site-card-link:hover {
    opacity: .8;
}

.msw-site-search-empty {
    grid-column: 1 / -1;
    text-align: center;
    color: #94a3b8;
    font-size: 14px;
    padding: 32px 0;
}

@media (max-width: 768px) {
    .msw-site-search-grid {
        grid-template-columns: 1fr !important;
    }
    .msw-site-search-filters {
        flex-direction: column;
    }
}
