/* ==========================================================================
   Modern visual refresh — purely presentational overrides.
   Loaded AFTER style.css. No markup / JS / behaviour is changed.
   To roll back: remove the <link> to modern.css from the layouts.
   ========================================================================== */

:root {
    --pt-primary: #1f7f95;
    --pt-primary-dark: #176478;
    --pt-primary-soft: #e8f4f7;
    --pt-accent: #00b8ad;
    --pt-ink: #1f2937;
    --pt-muted: #6b7280;
    --pt-line: #e8edf2;
    --pt-bg: #f4f7fa;
    --pt-surface: #ffffff;
    --pt-radius: 14px;
    --pt-radius-sm: 10px;
    --pt-shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.04), 0 1px 3px rgba(16, 24, 40, 0.06);
    --pt-shadow: 0 4px 6px -2px rgba(16, 24, 40, 0.04), 0 12px 24px -6px rgba(31, 127, 149, 0.10);
    --pt-shadow-lg: 0 20px 40px -12px rgba(16, 24, 40, 0.18);
    --pt-ring: 0 0 0 4px rgba(31, 127, 149, 0.15);
}

/* ---------- Base ---------- */
html { scroll-behavior: smooth; }

body {
    font-family: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
    color: var(--pt-ink);
    background: var(--pt-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 { color: var(--pt-ink); font-weight: 650; letter-spacing: -0.01em; }
a { color: var(--pt-primary); transition: color .15s ease; }
a:hover, a:focus { color: var(--pt-primary-dark); }

::selection { background: rgba(31, 127, 149, 0.2); }

/* Thin modern scrollbars */
* { scrollbar-width: thin; scrollbar-color: #c5d0d8 transparent; }
::-webkit-scrollbar { width: 8px; height: 8px; }
::-webkit-scrollbar-thumb { background: #c5d0d8; border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: #a9b8c2; }

/* Keyboard focus visibility */
a:focus-visible, button:focus-visible, .btn:focus-visible {
    outline: 2px solid var(--pt-primary);
    outline-offset: 2px;
}

/* ---------- Header ---------- */
.header {
    background: rgba(255, 255, 255, 0.85);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--pt-line);
    box-shadow: 0 1px 0 rgba(16, 24, 40, 0.02), 0 8px 24px -12px rgba(16, 24, 40, 0.10);
}

.header .user-menu .user-names h5 { font-weight: 600; color: var(--pt-ink); }
.header .user-menu .user-names span { color: var(--pt-muted); font-size: 12px; }

.header .user-img img,
.user-img img {
    border: 2px solid #fff;
    box-shadow: 0 0 0 2px var(--pt-primary-soft);
}

.dropdown-menu {
    border: 1px solid var(--pt-line);
    border-radius: var(--pt-radius-sm);
    box-shadow: var(--pt-shadow-lg);
    padding: 6px;
    animation: pt-pop .14s ease-out;
}
.dropdown-menu .dropdown-item,
.dropdown-menu > li > a {
    border-radius: 8px;
    padding: 9px 12px;
    font-size: 14px;
    color: var(--pt-ink);
}
.dropdown-menu .dropdown-item:hover,
.dropdown-menu .dropdown-item:focus {
    background: var(--pt-primary-soft);
    color: var(--pt-primary-dark);
}

@keyframes pt-pop {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ---------- Sidebar ---------- */
.sidebar {
    background: var(--pt-surface);
    border-top-right-radius: 24px;
    border-right: 1px solid var(--pt-line);
    box-shadow: 8px 0 32px -16px rgba(31, 127, 149, 0.18);
}

.sidebar-menu .menu-title {
    text-transform: uppercase;
    letter-spacing: .08em;
    font-size: 11px;
    font-weight: 700;
    color: #9aa7b2;
    padding: 18px 24px 8px;
}

.sidebar-menu > ul > li { padding: 2px 12px; }

.sidebar-menu > ul > li > a {
    border-radius: 12px;
    padding: 11px 14px;
    color: #4b5563;
    font-weight: 500;
    transition: background .18s ease, color .18s ease, transform .18s ease;
}

.sidebar-menu > ul > li > a:hover {
    background: var(--pt-primary-soft);
    color: var(--pt-primary-dark);
}

.sidebar-menu > ul > li > a.active,
.sidebar-menu > ul > li.active > a,
.sidebar-menu > ul > li > a.subdrop {
    background: linear-gradient(135deg, var(--pt-primary) 0%, #2796ae 100%);
    color: #fff;
    box-shadow: 0 8px 16px -8px rgba(31, 127, 149, 0.6);
}
.sidebar-menu > ul > li > a.active img,
.sidebar-menu > ul > li.active > a img,
.sidebar-menu > ul > li > a.subdrop img {
    filter: brightness(0) invert(1);
}

.sidebar-menu ul ul a {
    border-radius: 8px;
    color: #6b7280;
    padding: 8px 14px 8px 52px;
    transition: color .15s ease, background .15s ease;
}
.sidebar-menu ul ul a:hover { color: var(--pt-primary-dark); background: rgba(31, 127, 149, 0.06); }
.sidebar-menu ul ul a.active { color: var(--pt-primary); font-weight: 600; }

.sidebar-menu .logout-btn a {
    border-radius: 12px;
    transition: background .18s ease, color .18s ease;
}
.sidebar-menu .logout-btn a:hover { background: #fdecec; color: #c0392b; }

/* ---------- Page layout ---------- */
.page-wrapper { background: transparent; }
.page-wrapper > .content { padding: 32px; }

.page-header { margin-bottom: 24px; }
.page-title, .page-header .page-title {
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--pt-ink);
}
.breadcrumb { background: transparent; font-size: 13px; }
.breadcrumb-item a { color: var(--pt-muted); }
.breadcrumb-item.active { color: var(--pt-primary); font-weight: 600; }

/* ---------- Cards ---------- */
.card, .card-box, .dash-widget, .profile-bio {
    background: var(--pt-surface);
    border: 1px solid var(--pt-line);
    border-radius: var(--pt-radius);
    box-shadow: var(--pt-shadow-sm);
}
.card { transition: box-shadow .2s ease, transform .2s ease; }
.card:hover { box-shadow: var(--pt-shadow); }

.card-header {
    background: transparent;
    border-bottom: 1px solid var(--pt-line);
    padding: 18px 24px;
}
.card-body { padding: 24px; }
.card-title { font-weight: 650; color: var(--pt-ink); }
.card-footer { background: transparent; border-top: 1px solid var(--pt-line); }

.dash-widget { transition: transform .2s ease, box-shadow .2s ease; overflow: hidden; }
.dash-widget:hover { transform: translateY(-3px); box-shadow: var(--pt-shadow); }
.dash-widget::after {
    content: "";
    position: absolute; left: 0; top: 0; bottom: 0; width: 4px;
    background: linear-gradient(180deg, var(--pt-primary), var(--pt-accent));
    opacity: .9;
}
.dash-boxs {
    background: var(--pt-primary-soft);
    border: 0;
    border-radius: 14px;
}

/* ---------- Buttons ---------- */
.btn {
    border-radius: var(--pt-radius-sm);
    font-weight: 600;
    letter-spacing: .005em;
    transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease, border-color .15s ease, color .15s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary {
    background: linear-gradient(135deg, var(--pt-primary) 0%, #2796ae 100%);
    border: 0;
    color: #fff;
    box-shadow: 0 6px 14px -6px rgba(31, 127, 149, 0.55);
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active,
.btn-primary:not(:disabled):not(.disabled):active {
    background: linear-gradient(135deg, var(--pt-primary-dark) 0%, var(--pt-primary) 100%);
    color: #fff;
    box-shadow: 0 10px 20px -8px rgba(31, 127, 149, 0.65);
    transform: translateY(-1px);
}
.btn-primary:disabled, .btn-primary.disabled { opacity: .55; box-shadow: none; transform: none; }

.btn-outline-primary { color: var(--pt-primary); border-color: var(--pt-primary); }
.btn-outline-primary:hover { background: var(--pt-primary); border-color: var(--pt-primary); color: #fff; }

.btn-secondary { background: #eef2f6; border-color: transparent; color: #374151; }
.btn-secondary:hover { background: #e1e8ee; color: #111827; border-color: transparent; }

.btn-success { box-shadow: 0 6px 14px -6px rgba(40, 167, 69, .5); }
.btn-danger  { box-shadow: 0 6px 14px -6px rgba(220, 53, 69, .5); }

/* ---------- Forms ---------- */
.form-control, .form-select, .select2-container--default .select2-selection--single,
.select2-container--default .select2-selection--multiple {
    border: 1px solid #d7dee5;
    border-radius: var(--pt-radius-sm);
    background-color: #fff;
    color: var(--pt-ink);
    transition: border-color .15s ease, box-shadow .15s ease;
}
.form-control:hover, .form-select:hover { border-color: #b8c4ce; }
.form-control:focus, .form-select:focus,
.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: var(--pt-primary);
    box-shadow: var(--pt-ring);
    outline: 0;
}
.form-control::placeholder { color: #9aa7b2; }
.form-control:disabled, .form-control[readonly] { background: #f3f6f9; }
label, .form-label { font-weight: 600; font-size: 13px; color: #374151; }

.form-check-input:checked { background-color: var(--pt-primary); border-color: var(--pt-primary); }
.form-check-input:focus { box-shadow: var(--pt-ring); border-color: var(--pt-primary); }

/* ---------- Tables ---------- */
.table { color: var(--pt-ink); }
.table > thead > tr > th,
.table.custom-table > thead > tr > th,
.custom-table thead tr th {
    background: #f8fafc;
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    border-bottom: 1px solid var(--pt-line);
    white-space: nowrap;
}
.table > tbody > tr > td { border-color: var(--pt-line); vertical-align: middle; }
.table > tbody > tr { transition: background .12s ease; }
.table-hover > tbody > tr:hover,
.custom-table tbody tr:hover { background: #f6fafb; }
.table-responsive { border-radius: var(--pt-radius); }

.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
    border: 1px solid #d7dee5;
    border-radius: var(--pt-radius-sm);
    padding: 6px 12px;
}
.dataTables_wrapper .dataTables_filter input:focus {
    border-color: var(--pt-primary);
    box-shadow: var(--pt-ring);
    outline: 0;
}
.page-item .page-link, .paginate_button {
    border-radius: 8px !important;
    border: 0;
    color: var(--pt-muted);
    margin: 0 2px;
}
.page-item.active .page-link,
.paginate_button.current, .paginate_button.current:hover {
    background: var(--pt-primary) !important;
    color: #fff !important;
    border: 0 !important;
}

/* ---------- Badges / alerts ---------- */
.badge { border-radius: 999px; font-weight: 600; letter-spacing: .01em; }
.badge.rounded-pill { padding: .45em .85em; }

.alert {
    border: 0;
    border-left: 4px solid currentColor;
    border-radius: var(--pt-radius-sm);
    box-shadow: var(--pt-shadow-sm);
}
.alert-success { background: #e9f8ef; color: #1e7a45; }
.alert-danger  { background: #fdecec; color: #b42318; }
.alert-warning { background: #fff6e0; color: #9a6700; }
.alert-info    { background: #e8f4f7; color: var(--pt-primary-dark); }

/* ---------- Modals ---------- */
.modal-content {
    border: 0;
    border-radius: 18px;
    box-shadow: var(--pt-shadow-lg);
    overflow: hidden;
}
.modal-header { border-bottom: 1px solid var(--pt-line); padding: 18px 24px; }
.modal-title { font-weight: 700; }
.modal-body { padding: 24px; }
.modal-footer { border-top: 1px solid var(--pt-line); padding: 16px 24px; }
.modal-backdrop.show { opacity: .45; }

/* ---------- Tabs / nav ---------- */
.nav-tabs { border-bottom: 1px solid var(--pt-line); }
.nav-tabs .nav-link { border: 0; color: var(--pt-muted); font-weight: 600; border-bottom: 2px solid transparent; }
.nav-tabs .nav-link:hover { color: var(--pt-primary); }
.nav-tabs .nav-link.active { color: var(--pt-primary); border-bottom-color: var(--pt-primary); background: transparent; }
.nav-pills .nav-link { border-radius: 999px; font-weight: 600; }
.nav-pills .nav-link.active { background: var(--pt-primary); }

/* ---------- Loader ---------- */
.loader-wrapper { background: #fff; }
#loader { border-top-color: var(--pt-primary) !important; }

/* ---------- Auth pages (login / forgot / reset / verify) ---------- */
.login-body {
    background:
        radial-gradient(1000px 500px at 100% 0%, rgba(0, 184, 173, 0.10), transparent 60%),
        radial-gradient(900px 500px at 0% 100%, rgba(31, 127, 149, 0.12), transparent 60%),
        var(--pt-bg);
}
.login-wrap {
    background: #fff;
    border-radius: 0 48px 48px 0;
    box-shadow: 20px 0 60px -30px rgba(31, 127, 149, 0.25);
}
.login-wrapper .loginbox {
    border: 1px solid var(--pt-line);
    border-radius: 24px;
    box-shadow: var(--pt-shadow-lg);
}
.login-wrapper .login-logo p { color: var(--pt-primary); font-weight: 500; }
.login-wrapper .loginbox .login-right h2 { font-weight: 700; letter-spacing: -0.02em; }
.login-right .btn-primary { border-radius: 12px; padding: 12px 18px; }

/* ---------- Calendar (FullCalendar) ---------- */
.fc .fc-toolbar-title, .fc-toolbar h2 { font-weight: 700; }
.fc .fc-button-primary, .fc-button {
    background: var(--pt-primary);
    border-color: var(--pt-primary);
    border-radius: 8px;
}
.fc .fc-button-primary:hover { background: var(--pt-primary-dark); border-color: var(--pt-primary-dark); }
.fc .fc-event, .fc-event { border-radius: 6px; }

/* ---------- Responsive polish ---------- */
@media (max-width: 991.98px) {
    .page-wrapper > .content { padding: 20px 16px; }
    .sidebar { border-top-right-radius: 0; }
    .login-wrap { border-radius: 0; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}


/* ==========================================================================
   v2 — sidebar active state, DataTables 2 (dt-*), tables, profile pages
   ========================================================================== */

/* ---------- Sidebar: active / open item → white text + white icon ---------- */
.sidebar-menu > ul > li > a.active,
.sidebar-menu > ul > li > a.subdrop,
.sidebar-menu > ul > li.active > a,
.sidebar-menu > ul > li > a.active:hover,
.sidebar-menu > ul > li > a.subdrop:hover {
    background: linear-gradient(135deg, var(--pt-primary) 0%, #2796ae 100%) !important;
    color: #fff !important;
}
.sidebar-menu > ul > li > a.active span,
.sidebar-menu > ul > li > a.subdrop span,
.sidebar-menu > ul > li.active > a span,
.sidebar-menu > ul > li > a.active i,
.sidebar-menu > ul > li > a.subdrop i,
.sidebar-menu > ul > li.active > a i {
    color: #fff !important;
}
.sidebar-menu > ul > li > a.active .menu-side,
.sidebar-menu > ul > li > a.subdrop .menu-side,
.sidebar-menu > ul > li.active > a .menu-side,
.sidebar-menu > ul > li > a.active i,
.sidebar-menu > ul > li > a.subdrop i,
.sidebar-menu > ul > li.active > a i {
    background: rgba(255, 255, 255, 0.2) !important;
}
.sidebar-menu > ul > li > a.active img,
.sidebar-menu > ul > li > a.subdrop img,
.sidebar-menu > ul > li.active > a img,
.sidebar-menu > ul > li > a.active:hover img,
.sidebar-menu > ul > li > a.subdrop:hover img {
    filter: brightness(0) invert(1) !important;
}
.sidebar-menu > ul > li > a.active .menu-arrow:before,
.sidebar-menu > ul > li > a.subdrop .menu-arrow:before { color: #fff !important; }

/* Hover on inactive items: white icon tile so the icon stays readable */
.sidebar-menu > ul > li > a:not(.active):not(.subdrop):hover .menu-side,
.sidebar-menu > ul > li > a:not(.active):not(.subdrop):hover i { background: #fff; }
.sidebar-menu > ul > li > a:not(.active):not(.subdrop):hover img {
    filter: invert(35%) sepia(60%) saturate(700%) hue-rotate(150deg) brightness(90%) !important;
}

/* Sub menu: keep room for the style.css "active" arrow marker (left:50px) */
.sidebar-menu ul ul a { padding: 8px 14px 8px 70px; }
.sidebar-menu ul .submenu ul .active:before { left: 52px; }
.sidebar-menu ul ul a.active { background: rgba(31, 127, 149, 0.08); border-radius: 8px; }

/* ---------- DataTables 2.x (dt-*) ---------- */
div.dt-container { font-size: 14px; }
div.dt-container .dt-layout-row { margin: 0; align-items: center; gap: 12px; }
div.dt-container .dt-layout-row:last-child { padding: 16px 24px !important; border-top: 1px solid var(--pt-line); }
div.dt-container .dt-info { color: var(--pt-muted); font-size: 13px !important; padding: 0 !important; }
div.dt-container .dt-search input,
div.dt-container .dt-length select {
    border: 1px solid #d7dee5; border-radius: var(--pt-radius-sm); padding: 7px 12px; background: #fff;
}
div.dt-container .dt-search input:focus,
div.dt-container .dt-length select:focus { border-color: var(--pt-primary); box-shadow: var(--pt-ring); outline: 0; }

div.dt-container .dt-paging { display: flex; justify-content: flex-end; }
div.dt-container .dt-paging nav { display: inline-flex; gap: 4px; align-items: center; }
div.dt-container .dt-paging .dt-paging-button,
div.dt-container .dt-paging button.dt-paging-button {
    min-width: 36px; height: 36px; padding: 0 12px !important; margin: 0 !important;
    display: inline-flex; align-items: center; justify-content: center;
    background: #fff !important; color: #4b5563 !important;
    border: 1px solid var(--pt-line) !important; border-radius: 10px !important;
    font-size: 14px; font-weight: 600; box-shadow: none;
    transition: all .15s ease;
}
div.dt-container .dt-paging .dt-paging-button:hover:not(.disabled):not(.current) {
    background: var(--pt-primary-soft) !important; color: var(--pt-primary-dark) !important;
    border-color: #cfe6ec !important;
}
div.dt-container .dt-paging .dt-paging-button.current,
div.dt-container .dt-paging .dt-paging-button.current:hover {
    background: linear-gradient(135deg, var(--pt-primary), #2796ae) !important;
    color: #fff !important; border-color: transparent !important;
    box-shadow: 0 6px 12px -6px rgba(31, 127, 149, .6);
}
div.dt-container .dt-paging .dt-paging-button.disabled,
div.dt-container .dt-paging .dt-paging-button.disabled:hover {
    opacity: .45; cursor: default; background: #fff !important; color: #9aa7b2 !important;
}
div.dt-container .dt-paging .ellipsis { color: var(--pt-muted); padding: 0 4px; }

/* ---------- Tables (clean rows) ---------- */
.table-responsive { background: var(--pt-surface); }
.custom-table { border-collapse: separate; border-spacing: 0; width: 100%; }
.custom-table tbody tr { box-shadow: none; border: 0; background: #fff; }
.custom-table tbody tr td { border-bottom: 1px solid var(--pt-line) !important; padding: 14px 18px !important; color: var(--pt-ink); }
.custom-table tbody tr:last-child td { border-bottom: 0 !important; }
.custom-table thead tr th {
    padding: 13px 18px !important; background: #f8fafc; color: #64748b !important;
    font-size: 12px !important; font-weight: 700 !important; text-transform: uppercase; letter-spacing: .05em;
    border-bottom: 1px solid var(--pt-line) !important;
}
.custom-table tbody tr:hover td { background: #f6fafb; }

.page-table-header { padding: 18px 24px 6px; }
.doctor-table-blk h3 { font-weight: 700; letter-spacing: -0.01em; }
.top-nav-search.table-search-blk .form-control { border-radius: 999px; background: #f5f8fa; border-color: transparent; }
.top-nav-search.table-search-blk .form-control:focus { background: #fff; }

.custom-badge {
    border-radius: 999px; padding: 5px 14px; font-weight: 600; font-size: 12px; min-width: 0; line-height: 1.5;
}
.status-green, a.status-green { background: #e6f7ee; color: #1b8a52; }
.status-red, a.status-red { background: #fde8e8; color: #c62828; }
.status-orange, a.status-orange { background: #fff3dc; color: #b86e00; }
.status-blue, a.status-blue { background: #e4f1fd; color: #1769c2; }
.status-pink, a.status-pink { background: #fde7f3; color: #b4116f; }
.status-grey, a.status-grey { background: #eef1f4; color: #667085; }

/* ---------- Profile pages (psychologist / patient view) ---------- */
.profile-view {
    background: linear-gradient(135deg, #ffffff 0%, #f0f8fa 100%);
    border: 1px solid var(--pt-line); border-radius: 20px; padding: 28px;
    box-shadow: var(--pt-shadow-sm); position: relative; overflow: hidden;
}
.card-box.profile-header { padding: 0; border: 0; box-shadow: none; background: transparent; }

.profile-view .profile-img .avatar,
.profile-view .profile-img img.avatar {
    border-radius: 50%; border: 4px solid #fff; box-shadow: 0 0 0 3px var(--pt-primary-soft), var(--pt-shadow);
}
.profile-info-left { border-right: 1px dashed #cfdbe3; padding-right: 24px; }
.profile-info-left h3.user-name { font-size: 24px; font-weight: 700; letter-spacing: -0.02em; }
.profile-info-left small.text-muted {
    display: inline-block; margin-top: 6px; padding: 3px 12px; border-radius: 999px;
    background: var(--pt-primary-soft); color: var(--pt-primary-dark) !important; font-weight: 600; font-size: 12px;
}
.profile-info-left .staff-msg { margin-top: 20px; }
.profile-info-left .staff-msg .btn { font-size: 13px; padding: 8px 14px; width: 100%; }

.personal-info { gap: 2px; }
.personal-info li {
    display: flex; align-items: baseline; gap: 12px; margin: 0; padding: 10px 14px; border-radius: 10px;
    transition: background .15s ease;
}
.personal-info li:hover { background: rgba(31, 127, 149, .06); }
.personal-info li .title { float: none; width: 42%; flex: 0 0 42%; margin: 0; color: var(--pt-muted); font-weight: 600; font-size: 13px; }
.personal-info li .text { flex: 1; overflow: visible; color: var(--pt-ink); font-weight: 600; }
.personal-info .text > a { color: var(--pt-primary); }

/* Tabs on profile pages (beat the page-level inline <style> blocks) */
.profile-tabs .nav-tabs {
    background: var(--pt-surface); border: 1px solid var(--pt-line) !important; border-radius: 14px 14px 0 0;
    padding: 6px 10px 0; box-shadow: var(--pt-shadow-sm); gap: 4px; flex-wrap: wrap;
}
.profile-tabs .nav-tabs .nav-link,
.nav-tabs .nav-link {
    border: 0 !important; border-bottom: 3px solid transparent !important; border-radius: 10px 10px 0 0;
    padding: 12px 16px; color: var(--pt-muted); font-weight: 600; background: transparent;
}
.profile-tabs .nav-tabs .nav-link:hover,
.nav-tabs .nav-link:hover { background: var(--pt-primary-soft); color: var(--pt-primary-dark); }
.profile-tabs .nav-tabs .nav-link.active,
.nav-tabs .nav-link.active { color: var(--pt-primary) !important; border-bottom-color: var(--pt-primary) !important; background: transparent; }
.tab-content {
    background: var(--pt-surface); border: 1px solid var(--pt-line) !important; border-top: 0 !important;
    border-radius: 0 0 14px 14px; box-shadow: var(--pt-shadow-sm);
}
.tab-content .card-box { box-shadow: none; background: #fbfdfe; padding: 22px; }
.card-box > .card-title, .card-box h3.card-title {
    font-size: 16px; font-weight: 700; padding-bottom: 12px; margin-bottom: 18px; border-bottom: 1px solid var(--pt-line);
}

/* Timeline lists */
.experience-list:before { background: linear-gradient(180deg, var(--pt-primary), rgba(31,127,149,.1)); width: 2px; }
.experience-list > li .experience-user { background: transparent; }
.before-circle { background: var(--pt-primary); box-shadow: 0 0 0 4px var(--pt-primary-soft); }
.experience-list > li .experience-content { background: transparent; }
.experience-list > li .experience-content .timeline-content { color: #4b5563; font-size: 14px; line-height: 1.6; }
.experience-list > li .experience-content .timeline-content a.name { color: var(--pt-ink); font-weight: 700; }
.experience-list > li .time { color: var(--pt-muted); }
.skills > span { border-color: #cfe6ec; background: var(--pt-primary-soft); color: var(--pt-primary-dark); font-weight: 600; }

/* ---------- Settings / profile edit ---------- */
.settings-form .input-block { margin-bottom: 18px; }
.star-red { color: #e5484d; }
.progress { height: 8px; border-radius: 999px; background: #e8edf2; }
.progress-bar { background: linear-gradient(90deg, var(--pt-primary), var(--pt-accent)); border-radius: 999px; }

@media (max-width: 991.98px) {
    .profile-info-left { border-right: 0; border-bottom: 1px dashed #cfdbe3; padding: 0 0 18px; margin-bottom: 18px; }
    .personal-info li { flex-direction: column; gap: 2px; }
    .personal-info li .title { width: 100%; flex-basis: auto; }
    div.dt-container .dt-paging { justify-content: center; }
}


/* ==========================================================================
   v3 — Λίστα Πακέτων (pricing cards)
   ========================================================================== */
.package-item { min-height: 0; margin-bottom: 8px; }
.package-item .card {
    position: relative; overflow: hidden; border-radius: 22px; margin-bottom: 24px;
    background: linear-gradient(180deg, #ffffff 0%, #f6fbfc 100%) !important;
    border: 1px solid var(--pt-line); box-shadow: var(--pt-shadow-sm);
    transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.package-item .card::before {
    content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px;
    background: linear-gradient(90deg, var(--pt-primary), var(--pt-accent));
}
.package-item .card:hover { transform: translateY(-6px); box-shadow: var(--pt-shadow-lg); border-color: #cfe6ec; }

.package-item .card-body,
.package-item .card-body.card-buttons {
    padding: 38px 28px 32px !important; position: relative; z-index: 1;
}
.package-item .card-body .card-title {
    justify-self: center; margin: 0 0 14px; padding: 6px 16px; border-radius: 999px;
    background: var(--pt-primary-soft); color: var(--pt-primary-dark); font-size: 14px; font-weight: 700;
    letter-spacing: .01em; text-transform: none; /* Greek ordinals (1ο, 2ο) look like 10, 20 in capitals */
}
.package-item .card-body .card-price,
.package-item .card-body .card-price > span {
    font-size: 46px; font-weight: 800; letter-spacing: -0.03em; line-height: 1.1;
    background: linear-gradient(135deg, var(--pt-primary-dark), var(--pt-accent));
    -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent;
}
.package-item .card-body .card-price { margin: 4px 0 18px; }
.package-item .card-body .card-price > span.original-price {
    font-size: 24px; font-weight: 600; text-decoration: line-through; display: block;
    background: none; -webkit-text-fill-color: #9aa7b2; color: #9aa7b2;
}
.package-item .card-body .card-text {
    color: var(--pt-muted); font-size: 14px; line-height: 1.9; margin: 0 0 20px; padding: 16px 0;
    border-top: 1px dashed #d4e1e8; border-bottom: 1px dashed #d4e1e8;
}
.package-item .card-body form.payment-form .btn,
.package-item .card-body > a.btn { width: 100%; padding: 13px 18px; border-radius: 14px; font-size: 15px; display: block; }

/* Usage details box */
.packages-cart .details {
    border: 1px solid var(--pt-line); border-radius: 20px; padding: 26px 30px; box-shadow: var(--pt-shadow-sm);
    background: linear-gradient(135deg, #ffffff 0%, #f0f8fa 100%);
}
.packages-cart .details .title { font-size: 18px; font-weight: 700; letter-spacing: -0.01em; padding-bottom: 14px; }
.packages-cart .details .list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 28px; }
.packages-cart .details .list > div {
    padding: 4px 0 4px 46px; min-height: 36px; display: flex; align-items: center; font-size: 14px; color: #374151;
}
.packages-cart .details .list > div > i {
    top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border-radius: 10px;
    background: var(--pt-primary-soft); display: flex; align-items: center; justify-content: center; font-size: 15px;
}
@media (max-width: 767.98px) {
    .packages-cart .details .list { grid-template-columns: 1fr; }
    .package-item .card-body, .package-item .card-body.card-buttons { padding: 30px 20px 24px !important; }
}


/* ==========================================================================
   v4 — Βιογραφικό / Ρυθμίσεις (profile edit) & settings menu tabs
   ========================================================================== */

/* Top settings menu → segmented pills (also used by change-password / invoices) */
.settings-menu-links .nav-tabs.menu-tabs {
    display: inline-flex; flex-wrap: wrap; gap: 4px; padding: 5px; margin: 0 0 24px;
    background: var(--pt-surface); border: 1px solid var(--pt-line) !important; border-radius: 14px;
    box-shadow: var(--pt-shadow-sm);
}
.nav-tabs.menu-tabs .nav-item { padding: 0; margin: 0; }
.nav-tabs.menu-tabs .nav-link {
    border: 0 !important; border-radius: 10px; padding: 9px 18px; font-size: 14px; font-weight: 600;
    background: transparent; color: var(--pt-muted); box-shadow: none;
}
.nav-tabs.menu-tabs .nav-link:hover { background: var(--pt-primary-soft); color: var(--pt-primary-dark); }
.nav-tabs.menu-tabs .nav-item.active .nav-link,
.nav-tabs.menu-tabs .nav-item.active .nav-link:hover {
    background: linear-gradient(135deg, var(--pt-primary), #2796ae); color: #fff;
    box-shadow: 0 6px 12px -6px rgba(31, 127, 149, .6);
}

/* Card header (style.css gives card titles a dark background) */
.card .card-header .card-title { background: transparent; color: var(--pt-ink); font-size: 18px; font-weight: 700; margin: 0; }

/* Completion banner */
.card-body .alert.alert-info {
    display: block; background: linear-gradient(135deg, #eaf6f9, #f4fbfc); border: 1px solid #cfe6ec; border-left: 4px solid var(--pt-primary);
    color: var(--pt-ink); border-radius: 14px; padding: 16px 20px;
}
.card-body .alert.alert-info .badge { background: var(--pt-primary) !important; color: #fff; padding: 5px 12px; }
.card-body .alert.alert-info .text-muted { color: #52606d !important; }

/* Form tabs inside the card → soft pill bar; content flows without double borders */
#profileTabs.nav-tabs {
    background: #f1f5f8; border: 0 !important; border-radius: 14px; padding: 6px; gap: 4px; box-shadow: none; flex-wrap: wrap;
}
#profileTabs .nav-link {
    border: 0 !important; border-radius: 10px !important; padding: 10px 16px; font-size: 14px; font-weight: 600;
    color: var(--pt-muted); background: transparent;
}
#profileTabs .nav-link:hover { background: rgba(255, 255, 255, .7); color: var(--pt-primary-dark); }
#profileTabs .nav-link.active {
    background: #fff; color: var(--pt-primary) !important; box-shadow: var(--pt-shadow-sm);
}
#profileTabs .nav-link i { color: inherit; opacity: .85; }
#profileTabsContent.tab-content { border: 0 !important; box-shadow: none; background: transparent; padding: 8px 4px 0 !important; }

.card:has(#profileTabs):hover { box-shadow: var(--pt-shadow-sm); }

/* Section headings inside tabs */
#profileTabsContent .tab-pane h6 {
    display: flex; align-items: center; color: var(--pt-primary-dark); font-size: 15px; font-weight: 700;
    padding: 10px 14px; margin: 8px 0 18px; border: 0; border-left: 4px solid var(--pt-primary);
    background: linear-gradient(90deg, var(--pt-primary-soft), transparent); border-radius: 0 10px 10px 0;
}
#profileTabsContent .tab-pane h6 i { color: var(--pt-primary); }
#profileTabsContent .row.mb-3 { padding: 6px 0; }
#profileTabsContent hr { border-color: var(--pt-line); opacity: 1; }

/* Checkbox lists (skills / specializations) */
#profileTabsContent .scrolling {
    background: #fbfdfe; border: 1px solid var(--pt-line); border-radius: 14px; padding: 10px 12px;
}
#profileTabsContent .form-check { padding: 6px 10px 6px 2.1em; border-radius: 8px; transition: background .12s ease; }
#profileTabsContent .form-check:hover { background: var(--pt-primary-soft); }
#profileTabsContent .form-check-label { font-weight: 500; font-size: 14px; color: #374151; cursor: pointer; }
#profileTabsContent .form-check-input { cursor: pointer; }

/* Inputs: file / textarea / TinyMCE / phone */
#profileTabsContent textarea.form-control { min-height: 110px; }
#profileTabsContent input[type="file"].form-control { padding: 9px 12px; background: #f8fafc; }
.tox.tox-tinymce { border: 1px solid #d7dee5 !important; border-radius: 12px !important; box-shadow: none !important; }
.iti__country-container .iti__selected-country, .iti__selected-country { border-radius: 10px 0 0 10px; }

/* Save button */
.settings-btns { display: flex; justify-content: flex-end; padding-top: 18px; border-top: 1px solid var(--pt-line); }
.settings-btns .btn { padding: 12px 28px; border-radius: 12px; font-size: 15px; }
.settings-btns button:nth-child(1):hover { background: linear-gradient(135deg, var(--pt-primary-dark), var(--pt-primary)); }

/* Validation modal header */
#validationErrorModal .modal-header { background: #fdecec; color: #b42318; border-bottom: 0; }

@media (max-width: 767.98px) {
    .settings-menu-links .nav-tabs.menu-tabs { display: flex; }
    #profileTabs .nav-link i { display: none; }
    .settings-btns .btn { width: 100%; }
}


/* ==========================================================================
   v5 — Προτεινόμενος Ψυχολόγος (psychologists/matched)
   ========================================================================== */

/* FIX: the outer column carried the "card" class (white bg + padding) which removed the
   Bootstrap gutter, so the two columns were glued together. Make the outer column a plain
   column again and let the inner element be the card. */
.row > .therapist-selected-details {
    background: transparent; border-radius: 0; box-shadow: none;
    padding: 0 calc(var(--bs-gutter-x, 1.5rem) * .5);
}
.row > .therapist-selected-details > .therapist-selected-details {
    background: var(--pt-surface); border: 1px solid var(--pt-line); border-radius: 20px;
    box-shadow: var(--pt-shadow-sm); padding: 28px 30px;
}

/* Header card */
.profile-view.height-auto { padding: 24px 28px; margin-bottom: 20px; height: auto; }
.profile-view.height-auto .profile-img .avatar { border-radius: 50%; object-fit: cover; }
.profile-view.height-auto .profile-info-left { border-right: 0; padding-right: 0; }
.profile-view.height-auto h3.user-name { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.profile-view.height-auto h3.user-name svg { width: 24px; height: 24px; flex: 0 0 auto; }

.badge-soft-dark { background: #eef2f6; color: #374151; }
.badge-soft-success { background: #e6f7ee; color: #1b8a52; }
.badge-soft-dark, .badge-soft-success { padding: 6px 12px; font-size: 12px; font-weight: 600; }

/* Booking buttons: primary = solid, secondary = outline */
.profile-view .btn-outline-primary.active {
    background: linear-gradient(135deg, var(--pt-primary), #2796ae); color: #fff; border: 0;
    box-shadow: 0 6px 14px -6px rgba(31, 127, 149, .55);
}
.profile-view .btn-outline-primary.active:hover { background: linear-gradient(135deg, var(--pt-primary-dark), var(--pt-primary)); color: #fff; }
.profile-view .btn-outline-primary:not(.active) { background: #fff; border: 1.5px solid var(--pt-primary); color: var(--pt-primary); box-shadow: none; }
.profile-view .btn-outline-primary:not(.active):hover { background: var(--pt-primary-soft); color: var(--pt-primary-dark); }
.btn-outline-danger { background: #fff; border-width: 1.5px; box-shadow: none; }
.btn-outline-danger:hover { background: #fde8e8; color: #c62828; border-color: #e5484d; }

/* Bio / experience / seminars cards */
.profile-bio { padding: 24px 28px; margin: 0 0 20px; border-radius: 20px; }
.profile-bio .scrolling { max-height: 220px; padding-right: 10px; color: #374151; font-size: 15px; line-height: 1.75; }
.profile-bio .scrolling p { margin-bottom: 12px; }

/* Section labels (both columns) */
.profile-bio .entry h6,
.therapist-selected-details .entry h6 {
    display: flex; align-items: center; gap: 10px; margin: 0 0 12px;
    color: var(--pt-primary-dark); font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase;
}
.profile-bio .entry h6::before,
.therapist-selected-details .entry h6::before {
    content: ""; width: 4px; height: 16px; border-radius: 4px; background: linear-gradient(180deg, var(--pt-primary), var(--pt-accent));
}

/* Right column content */
.therapist-selected-details .entry > p.mb-0 {
    font-size: 16px; font-weight: 600; color: var(--pt-ink); text-transform: none;
}
.therapist-selected-details hr { border-color: var(--pt-line); opacity: 1; margin: 20px 0; }

.therapist-selected-details .university p {
    margin: 0 0 8px; padding: 10px 14px; background: #f8fafc; border: 1px solid var(--pt-line); border-radius: 12px;
    font-size: 14px; color: #374151; line-height: 1.5;
}
.therapist-selected-details .university p b { color: var(--pt-ink); }

/* Specializations as chips */
.therapist-selected-details .entry ul { gap: 8px; margin-bottom: 8px; }
.therapist-selected-details .entry ul li {
    width: auto; border: 1px solid #cfe6ec; background: var(--pt-primary-soft); color: var(--pt-primary-dark);
    border-radius: 999px; padding: 7px 16px; font-size: 13px; font-weight: 600;
    transition: transform .15s ease, box-shadow .15s ease;
}
.therapist-selected-details .entry ul li:hover { transform: translateY(-1px); box-shadow: 0 6px 12px -8px rgba(31, 127, 149, .6); }

.therapist-selected-details .scrolling {
    max-height: 200px; padding: 12px 16px; background: #f8fafc; border: 1px solid var(--pt-line); border-radius: 12px;
    font-size: 14px; line-height: 1.7; color: #374151;
}

@media (max-width: 767.98px) {
    .row > .therapist-selected-details > .therapist-selected-details { padding: 20px 18px; }
    .profile-bio { padding: 20px 18px; }
}


/* ==========================================================================
   v6 — Responsive (tablet / mobile) fixes
   ========================================================================== */

img, video, canvas, svg { max-width: 100%; }
.table-responsive { -webkit-overflow-scrolling: touch; }

/* Inline buttons/forms inside table cells were glued together */
td .btn + .btn, td form + .btn, td form + form, td .btn + form, td a.btn + a.btn { margin-left: 6px; }
.modal-footer { flex-wrap: wrap; gap: 8px; }
.modal-footer > * { margin: 0; }

/* ---------- Desktop collapsed sidebar (mini-sidebar) keeps icons inside 60px ---------- */
@media (min-width: 992px) {
    .mini-sidebar .sidebar-menu > ul > li { padding: 2px 0; }
    .mini-sidebar .sidebar-menu > ul > li > a { border-radius: 0; }
    .mini-sidebar.expand-menu .sidebar-menu > ul > li { padding: 2px 12px; }
    .mini-sidebar.expand-menu .sidebar-menu > ul > li > a { border-radius: 12px; }
}

/* ---------- Tablet & mobile: off-canvas sidebar + header ---------- */
@media (max-width: 991.98px) {
    /* Header: [menu] [logo] ........ [user]  (the logo block used to cover the whole header) */
    .header .header-left { left: 56px; width: auto; padding: 0 8px; z-index: 1; }
    .header .header-left .logo img { max-width: 150px; }
    a.mobile_btn { display: flex; align-items: center; justify-content: center; z-index: 12; padding: 0; width: 56px; }
    a.mobile_btn img { width: 24px; }
    .mobile-user-menu > a, .mobile-user-menu > a:hover { color: var(--pt-ink); }
    .header .user-menu { margin: 0; padding-right: 12px; align-items: center; }
    .header .user-menu .user-names { text-align: right; }

    /* Sidebar becomes a drawer that overlays the page instead of pushing it */
    .sidebar {
        top: 70px; bottom: 0; height: auto; width: 280px; margin-left: -300px; z-index: 1045;
        border-radius: 0 24px 24px 0; overflow-y: auto; box-shadow: none; padding-bottom: 24px;
    }
    .slide-nav .sidebar { margin-left: 0; box-shadow: 24px 0 60px -20px rgba(15, 23, 42, .35); }
    .slide-nav .page-wrapper { left: 0; }
    .sidebar-overlay {
        top: 70px; z-index: 1040; background: rgba(15, 23, 42, .45);
        -webkit-backdrop-filter: blur(2px); backdrop-filter: blur(2px);
    }
    .sidebar .logout-btn { margin: 24px 12px; }

    .page-header .text-end { text-align: left !important; margin-top: 10px; }
}

/* ---------- Login / auth pages ---------- */
@media (max-width: 991.98px) {
    .login-body { display: block; min-height: 100vh; }
    .login-wrap { display: none; }                      /* decorative fixed panel covered small screens */
    .login-wrap-bg { position: static; height: auto; width: 100%; padding: 28px 16px; }
    .login-wrapper { height: auto; min-height: calc(100vh - 56px); }
    .login-wrapper .loginbox .login-right { padding: 28px 22px; }
    .login-wrapper .login-logo { padding-bottom: 20px; }
}

/* ---------- Tablet ---------- */
@media (min-width: 768px) and (max-width: 991.98px) {
    .page-wrapper > .content { padding: 24px; }
    .card-body { padding: 20px; }
    .profile-view { padding: 22px; }
}

/* ---------- Mobile ---------- */
@media (max-width: 767.98px) {
    .page-wrapper > .content { padding: 16px 14px; }
    .card-body, .tab-content, .profile-bio { padding: 18px !important; }
    .card-header { padding: 14px 18px; }
    h1, .h1 { font-size: 1.6rem; }
    h2, .h2 { font-size: 1.4rem; }
    h3, .h3 { font-size: 1.2rem; }
    .btn { padding-top: 10px; padding-bottom: 10px; }

    /* Stacked full-width buttons were touching each other */
    .row > [class*="col-"]:has(> .btn.w-100):not(:last-child),
    .row > [class*="col-"]:has(> a.btn.w-100):not(:last-child),
    .row > [class*="col-"]:has(> form > .btn):not(:last-child) { margin-bottom: 10px; }
    .profile-view .mt-v1, .profile-view .mt-v2 { margin-top: 10px; }
    .staff-msg .row > [class*="col-"] { margin-bottom: 10px; }
    .profile-info-left .btn { width: 100%; }
    .profile-view.height-auto { padding: 20px 16px; }
    .profile-view .profile-basic { margin-top: 12px; }

    /* Tables -> cards (style.css provides the display:block layout) */
    table.comman-table.custom-table > tbody > tr {
        width: auto; margin: 0 0 14px; padding: 6px 0; border: 1px solid var(--pt-line);
        border-radius: 14px; box-shadow: var(--pt-shadow-sm);
    }
    table.comman-table.custom-table > tbody > tr > td {
        padding: 9px 16px !important; gap: 12px; flex-wrap: wrap; border-bottom: 1px dashed var(--pt-line) !important;
        background: transparent !important; text-align: right;
    }
    table.comman-table.custom-table > tbody > tr > td:last-child { border-bottom: 0 !important; margin-top: 0; }
    table.comman-table td::before { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--pt-muted); }
    table.comman-table td .btn { margin: 2px; }
    .table-responsive { background: transparent; padding: 2px; }
    .page-table-header { padding: 14px 16px 4px; }
    .doctor-table-blk { display: flex; flex-direction: column; align-items: stretch; gap: 10px; }
    .doctor-search-blk { width: 100%; }
    .top-nav-search.table-search-blk { width: 100%; }

    /* DataTables footer */
    div.dt-container .dt-layout-row { flex-direction: column; align-items: center; gap: 10px; padding: 12px 8px !important; }
    div.dt-container .dt-paging, div.dt-container .dt-paging nav { justify-content: center; flex-wrap: wrap; }
    div.dt-container .dt-paging .dt-paging-button { min-width: 34px; height: 34px; padding: 0 8px !important; }
    div.dt-container .dt-info { text-align: center; }

    /* Tab bars scroll sideways instead of wrapping into several rows */
    .profile-tabs .nav-tabs, #profileTabs.nav-tabs, .settings-menu-links .nav-tabs.menu-tabs {
        flex-wrap: nowrap; overflow-x: auto; white-space: nowrap; -webkit-overflow-scrolling: touch; scrollbar-width: none;
    }
    .profile-tabs .nav-tabs::-webkit-scrollbar, #profileTabs.nav-tabs::-webkit-scrollbar { display: none; }
    .profile-tabs .nav-tabs .nav-link, #profileTabs .nav-link, .nav-tabs.menu-tabs .nav-item { flex: 0 0 auto; width: 100%; text-align: left;}
    .settings-menu-links .nav-tabs.menu-tabs { display: flex; max-width: 100%; }
    .nav-tabs.menu-tabs .nav-link { width: auto; }

    /* Package cards */
    .package-item .card { margin-bottom: 16px; }
    .package-item .card-body .card-price, .package-item .card-body .card-price > span { font-size: 38px; }

    /* Modals */
    .modal-dialog { margin: 12px; }
    .modal-body, .modal-header, .modal-footer { padding-left: 18px; padding-right: 18px; }
    .modal-footer .btn { flex: 1 1 auto; }

    /* Calendar toolbar */
    .fc .fc-toolbar { flex-direction: column; gap: 10px; align-items: stretch; text-align: center; }
    .fc .fc-toolbar-title { font-size: 18px; }
    .fc .fc-toolbar-chunk { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px; }
    .fc-toolbar .fc-left, .fc-toolbar .fc-right { width: 100%; }

    /* Forms */
    .form-control, .form-select { font-size: 16px; }              /* prevents iOS zoom on focus */
    .settings-btns { justify-content: stretch; }
    .dropdown-menu { max-width: calc(100vw - 24px); }
}

@media (max-width: 479.98px) {
    .header .header-left .logo img { max-width: 130px; }
    .page-title { font-size: 18px; }
    .breadcrumb { flex-wrap: wrap; }
    .login-wrapper .loginbox .login-right { padding: 24px 16px; }
    .package-item .card-body, .package-item .card-body.card-buttons { padding: 26px 16px 20px !important; }
}
