/* ========== RESET & BASE ========== */

@font-face {
    font-family: 'Lama Sans';
    font-style: normal;
    font-weight: 400;
    src: url('https://fonts.cdnfonts.com/s/89696/LamaSans-Regular.woff') format('woff');
}

@font-face {
    font-family: 'Lama Sans';
    font-style: normal;
    font-weight: 500;
    src: url('https://fonts.cdnfonts.com/s/89696/LamaSans-Medium.woff') format('woff');
}

@font-face {
    font-family: 'Lama Sans';
    font-style: normal;
    font-weight: 600;
    src: url('https://fonts.cdnfonts.com/s/89696/LamaSans-SemiBold.woff') format('woff');
}

@font-face {
    font-family: 'Lama Sans';
    font-style: normal;
    font-weight: 700;
    src: url('https://fonts.cdnfonts.com/s/89696/LamaSans-Bold.woff') format('woff');
}

@font-face {
    font-family: 'Lama Sans';
    font-style: normal;
    font-weight: 800;
    src: url('https://fonts.cdnfonts.com/s/89696/LamaSans-ExtraBold.woff') format('woff');
}

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

html {
    font-size: 14px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Lama Sans', sans-serif;
    font-style: normal;
    background-color: rgba(26, 25, 25, 1);
    color: #333;
    direction: rtl;
    min-height: 100vh;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

ul,
ol {
    list-style: none;
}
/* Chrome, Edge, Safari */
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox */
input[type="number"] {
    -moz-appearance: textfield;
}
/* يخلي الـ CKEditor ياخد عرض الفورم كله */
.cke_editor,
.cke_reset,
.cke_chrome {
    width: 100% !important;
}

/* أهم واحد */
.cke_inner,
.cke_contents {
    width: 100% !important;
}
.cke_notification_warning,
.cke_notifications_area,
.cke_notification {
    display: none !important;
}
.disabled-link {
    pointer-events: none;
    opacity: 0.5;
    cursor: not-allowed;
}
img {
    max-width: 100%;
    display: block;
}
.swal2-popup {
    font-family: inherit !important;
}

.swal2-container {
    z-index: 999999 !important;
}
button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: inherit;
}

input,
textarea {
    font-family: inherit;
    border: none;
    outline: none;
}

/* ========== SCROLLBAR ========== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #1a1919;
}

::-webkit-scrollbar-thumb {
    background: rgba(141, 49, 118, 0.5);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(141, 49, 118, 0.8);
}

/* ========== LAYOUT ========== */
.app-wrapper {
    display: flex;
    min-height: 100vh;
}

/* ========== SIDEBAR ========== */
.sidebar {
    width: 90px;
    background: rgba(26, 25, 25, 1);
    /* border-left: 1px solid rgba(255, 255, 255, 0.08); */
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 14px 0;
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    z-index: 100;
    overflow-y: auto;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.sidebar::-webkit-scrollbar {
    display: none;
}

.sidebar-logo {
    /* width: 48px;
    height: 48px; */
    margin-bottom: 16px;
    flex-shrink: 0;
}

.sidebar-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    width: 100%;
    flex: 1;
}

.sidebar-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 6px 4px;
    cursor: pointer;
    border-radius: 10px;
    transition: all 0.3s ease;
    width: 76px;
    position: relative;
    text-align: center;
}

.sidebar-nav-item:hover {
    background: transparent;
}

.sidebar-nav-item.active {
    background: transparent;
}

.sidebar-nav-item .nav-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
    flex-shrink: 0;
    opacity: 0.5;
    transition: all 0.3s ease;
    padding: 10px;
    box-sizing: content-box;
    border-radius: 10px;
    background: transparent;
}

.sidebar-nav-item.active .nav-icon,
.sidebar-nav-item:hover .nav-icon {
    opacity: 1;
    background: rgba(255, 255, 255, 0.05);
    filter: brightness(0) saturate(100%) invert(25%) sepia(60%) saturate(1600%) hue-rotate(291deg) brightness(95%) contrast(90%);
}

.sidebar-nav-item svg {
    width: 20px;
    height: 20px;
    fill: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
    flex-shrink: 0;
    padding: 10px;
    box-sizing: content-box;
    border-radius: 10px;
    background: transparent;
}

.sidebar-nav-item.active svg,
.sidebar-nav-item:hover svg {
    fill: rgba(141, 49, 118, 1);
    background: rgba(255, 255, 255, 0.05);
}

.sidebar-nav-item span {
    font-size: 0.62rem;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 500;
    transition: color 0.3s ease;
    line-height: 1.2;
}

.sidebar-nav-item.active span,
.sidebar-nav-item:hover span {
    color: rgba(255, 255, 255, 0.9);
}

/* ========== SIDEBAR FLYOUT MENUS ========== */
.sidebar-flyout-wrapper {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.sidebar-flyout {
    position: fixed;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    min-width: 260px;
    z-index: 200;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
    padding: 6px 0;
    pointer-events: none;
}
.text-center {
    text-align: center;
}

.sidebar-flyout.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.sidebar-flyout-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    text-decoration: none;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s ease;
}

.sidebar-flyout-item:last-child {
    border-bottom: none;
}

.sidebar-flyout-item:hover {
    background: #f8f7fc;
}

.flyout-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.flyout-title {
    font-size: 0.9rem;
    font-weight: 700;
    color: #1a1919;
}

.flyout-desc {
    font-size: 0.72rem;
    color: #999;
    font-weight: 400;
}

.flyout-arrow {
    font-size: 1.2rem;
    color: #999;
    transition: transform 0.2s ease;
}

.sidebar-flyout-item:hover .flyout-arrow {
    transform: translateX(-4px);
    color: rgba(141, 49, 118, 1);
}

/* ========== MAIN CONTENT ========== */
.main-content {
    flex: 1;
    margin-right: 90px;
    margin-top: 12px;
    margin-left: 12px;
    background: #ffffff;
    border-radius: 24px 24px 0 0;
    min-height: calc(100vh - 12px);
    overflow: hidden;
}

/* ========== HEADER ========== */
.header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 16px 24px;
    margin-bottom: 20px;
    padding-top: 32px;
}

.create-back-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #D48E00;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.create-back-link svg {
    width: 20px;
    height: 20px;
    stroke: #D48E00;
    /* transform: rotate(180deg); */
}

.header-right {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.header-greeting {
    display: flex;
    align-items: center;
    gap: 8px;
}

.header-greeting h1 {
    font-size: 20px;
    font-weight: 600;
    color: #1a1919;
    line-height: 100%;
    letter-spacing: 0px;
}

.header-count {
    font-size: 16px;
    color: #A2A2A2;
    font-weight: normal;
    margin-right: 8px;
}

.header-greeting .wave-emoji {
    font-size: 1.4rem;
}

.header-subtitle {
    font-size: 13px;
    color: #999;
    margin-top: 2px;
    font-weight: 400;
    line-height: 100%;
    letter-spacing: 0;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-user {
    display: flex;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 4px 4px 4px 14px;
    border-radius: 50px;
    background: #ECECEC;
    transition: background 0.3s ease;
    position: relative;
}

.header-user:hover {
    background: #e2e2e2;
}

.header-user-name {
    font-size: 0.82rem;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
}

.header-user-avatar-wrapper {
    position: relative;
    display: flex;
    flex-shrink: 0;
}

.header-user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
}

.status-badge {
    display: inline-block;
    border-radius: 8px;
    font-size: 11px;
    font-weight: 700;
    padding: 6px 12px;
    background: #F7FBF7;
    /* subtle default */
    color: #2e7d32;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.03) inset;
    text-align: center;
    vertical-align: middle;
}

.header-user.is-online .status-badge {
    display: block;
}

.header-user-chevron {
    font-size: 0.55rem;
    color: #666;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: auto;
    height: 40px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    transition: all 0.3s ease;
    flex-direction: row-reverse;
}

.header-btn-primary {
    background: #8D3176;
    color: #fff;
    border-radius: 12px;
    height: 40px;
    padding: 0 16px;
}

.header-btn-primary:hover {
    background: #7a2a66;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(141, 49, 118, 0.2);
}

.header-btn-primary svg {
    width: 18px;
    height: 18px;
    fill: none;
}

.header-icon-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #ECECEC;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    position: relative;
}

.header-icon-btn:hover {
    background: #e2e2e2;
}

.header-icon-btn svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: #333;
    stroke-width: 1.5;
}

/* ========== DROPDOWN MENUS ========== */
.dropdown-wrapper {
    position: relative;
}

.dropdown-menu {
    position: absolute;
    /* top: calc(100% + 8px); */
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    z-index: 200;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.25s ease;
    min-width: 200px;
}

.dropdown-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* --- Action Dropdown --- */
.dropdown-action {
    right: 0;
    min-width: 230px;
    padding: 4px 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 20px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #4a4a4a;
    text-decoration: none;
    transition: background 0.2s ease;
    border-bottom: none;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: #f8f7fc;
}

.dropdown-arrow {
    font-size: 1.1rem;
    color: #999;
    transition: transform 0.2s ease;
}

.dropdown-item:hover .dropdown-arrow {
    transform: translateX(-4px);
    color: rgba(141, 49, 118, 1);
}

/* --- Profile Dropdown --- */
.dropdown-profile {
    left: 0;
    min-width: 220px;
    padding: 0;
    overflow: hidden;
}

.dropdown-profile-header {
    padding: 16px 18px 12px;
    text-align: center;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-profile-name {
    font-size: 1.25rem;
    font-weight: 700;
    color: #8D3176;
    margin-bottom: 2px;
}

.dropdown-profile-role {
    font-size: 0.9rem;
    color: #999;
    font-weight: 400;
}

.dropdown-profile-body {
    padding: 12px 0;
}

.dropdown-profile-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 24px;
    font-size: 1rem;
    font-weight: 600;
    color: #1a1919;
    text-decoration: none;
    transition: background 0.2s ease;
}

.dropdown-profile-item:hover {
    background: #f8f7fc;
}

.dropdown-chevron {
    font-size: 1.5rem;
    color: #1a1919;
}

.dropdown-visibility {
    padding: 12px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-visibility-label {
    font-size: 1rem;
    font-weight: 600;
    color: #1a1919;
}

/* Toggle Switch Styles */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked+.slider {
    background-color: #00BA88;
}

input:focus+.slider {
    box-shadow: 0 0 1px #00BA88;
}

input:checked+.slider:before {
    transform: translateX(20px);
}

.dropdown-logout {
    color: #B20015;
    justify-content: flex-start;
    gap: 12px;
    margin-top: 8px;
}

.dropdown-logout svg {
    width: 18px;
    height: 18px;
    stroke: #B20015;
    fill: none;
}

/* ========== STAT CARDS ========== */
.stats-section {
    padding: 0 24px 16px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.stat-card {
    background: rgba(26, 25, 25, 1);
    border-radius: 40px;
    padding: 28px 24px;
    color: #fff;
    position: relative;
    overflow: hidden;
    width: 100%;
    min-height: 220px;
    display: flex;
    flex-direction: column;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.stat-card:hover {
    cursor: pointer;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/card-background.jpg') center/cover no-repeat;
    opacity: 0.2;
    border-radius: 40px;
    pointer-events: none;
    z-index: 0;
}

.stat-card::after {
    display: none;
}

.stat-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 6px;
    position: relative;
    z-index: 1;
}

.stat-card-title {
    font-size: 15px;
    font-weight: 700;
    color: rgba(255, 255, 255, 1);
    line-height: 100%;
    letter-spacing: 0.31px;
}

.stat-card-number-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    position: relative;
    z-index: 1;
    background: rgba(255, 255, 255, 0.2);
    width: 64px;
    height: 64px;
    border-radius: 50%;
}

.stat-card-number {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1;
}

.stat-card-number-wrapper .increase {
    display: flex;
    align-items: center;
    gap: 3px;
    color: #fff;
    font-weight: 600;
    font-size: 0.65rem;
}

.stat-card-number-wrapper .increase svg {
    width: 12px;
    height: 12px;
    fill: #fff;
}

.stat-card-meta {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 4px;
    font-size: 11.2px;
    font-weight: 500;
    line-height: 15.51px;
    letter-spacing: -0.07px;
    color: rgba(255, 255, 255, 1);
    opacity: 0.65;
}

.stat-card-meta .increase {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #fff;
    font-weight: 700;
    opacity: 1;
    font-size: 0.75rem;
}

.stat-card-meta .increase svg {
    width: 14px;
    height: 14px;
    fill: #fff;
}

.stat-card-details {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin: 10px;
    /* padding-top: 12px; */
    /* border-top: 1px solid rgba(255, 255, 255, 0.08); */
    position: relative;
    z-index: 1;
}

.stat-detail {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    flex-direction: row-reverse;
}

.stat-detail-label {
    font-size: 13px;
    font-weight: 700;
    line-height: 18px;
    letter-spacing: -0.1px;
    color: rgba(255, 255, 255, 1);
}

.stat-detail-value {
    font-size: 15px;
    font-weight: 600;
    line-height: 20px;
    letter-spacing: -0.3px;
    color: rgba(255, 255, 255, 1);
}

/* ========== CONTENT SECTIONS ========== */
.content-section {
    padding: 0 24px 24px;
}

.content-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

/* ========== TOP WIDGETS ========== */
.content-grid-top {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 14px;
    margin-top: 24px;
}

/* ========== MIDDLE WIDGETS ========== */
.content-grid-middle {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 14px;
    margin-top: 24px;
    margin-bottom: 24px;
}
 /* Timeline adjustments for the "Comprehensive" view */
 .activity-comprehensive-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.activity-comprehensive-header h2 {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1a1919;
}
/* Pagination */
.clients-pagination {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
    padding-top: 10px;
    padding-right: 20px;
}

.page-num,
.page-nav {
    background: transparent;
    border: none;
    color: #A2A2A2;
    font-size: 14px;
    font-weight: 600;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
}

.page-num.active {
    background: rgba(141, 49, 118, 1);
    color: #fff;
}

.page-num:hover:not(.active),
.page-nav:hover {
    color: rgba(141, 49, 118, 1);
}
.time-picker {
    direction: ltr;
    text-align: left;
}
.flatpickr-time {
    direction: ltr;
}

/* price & currency */
.price {
    display: flex !important;
    align-items: center !important;
    gap: 4px !important;
    font-weight: 800 !important;
    color: #8E3373 !important;
    font-size: 20px !important;
}
.currency-icon {
    width: 16px!important;
    height: 16px!important;
}
/* ========== BOTTOM WIDGETS ========== */
.content-grid-bottom {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 24px;
    height: 500px;
}

.card-recent-activities-wrapper {
    position: relative;
    height: 100%;
}

.card-recent-activities {
    position: absolute !important;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    display: flex;
    flex-direction: column;
    padding-bottom: 0 !important;
}

.card-recent-activities .activity-list {
    overflow-y: auto;
    flex: 1;
    min-height: 0;
    padding-right: 8px;
    /* Room for scrollbar */
    padding-bottom: 18px;
    /* Restore bottom padding lost from card */
}

/* Custom Scrollbar for activity-list */
.card-recent-activities .activity-list::-webkit-scrollbar {
    width: 6px;
}

.card-recent-activities .activity-list::-webkit-scrollbar-track {
    background: transparent;
}

.card-recent-activities .activity-list::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}

.card-recent-activities .activity-list::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}
/* show blade views css */
.client-box-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
}

.client-box-title {
    font-size: 20px;
    font-weight: 800;
    line-height: 1.15;
    color: #111827;
}

/* Client ID Badge */
.client-id-badge {
    font-size: 10px;
    font-weight: 600;
    color: #fff;
    background: rgba(146, 152, 164, 1);
    padding: 7px 8px;
    border-radius: 10px;
}

/* Status Badge */
.client-status-badge {
    display: inline-block;
    padding: 6px 24px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.client-status-active {
    background: rgba(198, 246, 236, 1);
    color: rgba(0, 151, 118, 1);
    font-size: 11px;
    font-weight: 700;
    padding: 6px 10px;
    border-radius: 8px;
}

/* Info Grid (2 columns for personal data) */
.client-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px 34px;
    align-items: start;
}

.client-info-grid-split {
    gap: 0 34px;
}

.client-info-column {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* Info Items */
.client-info-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: right;
}

.client-info-item-stages {
    gap: 12px;
}

.client-stage-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.client-info-label {
    font-size: 13px;
    font-weight: 700;
    color: #8b95a7;
    line-height: 1.3;
}

.client-info-value {
    font-size: 17px;
    font-weight: 500;
    color: #101828;
    word-break: break-word;
    line-height: 1.3;
}

.client-info-item-highlight {
    align-items: flex-start;
}

.client-source-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 7px 12px;
    border-radius: 12px;
    background: #fff6e8;
    color: #db9200;
    font-size: 14px;
    font-weight: 700;
    line-height: 1.2;
}

.client-info-item-assignee {
    justify-content: flex-end;
}

.client-assignee-inline {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.client-assignee-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #73839a;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.client-assignee-icon img {
    width: 12px;
    height: 12px;
    object-fit: contain;
}

.client-box {
    background: rgba(248, 250, 251, 1);
    border-radius: 28px;
    padding: 20px 24px 24px;
    display: flex;
    flex-direction: column;
}


.card-header-flex {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 24px;
}

.view-all-outline-btn {
    padding: 8px 16px;
    border: 1px solid #8D3176;
    background: transparent;
    color: #8D3176;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.view-all-outline-btn:hover {
    background: rgba(141, 49, 118, 0.05);
}

.header-right-group {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.title-icon-group {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-direction: row-reverse;
}

.title-group-text {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: right;
}

.card-title-main {
    font-size: 18px;
    font-weight: 800;
    color: #fcfcfc;
    margin: 0 0 4px 0;
}

.card-subtitle-main {
    font-size: 13px;
    color: #fcfcfc;
    font-weight: 500;
    margin: 0;
}

.icon-circle {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.bg-yellow-light {
    background: #FFF8E6;
}

.bg-purple-light {
    background: #F4EEF7;
}

.bg-gray-light {
    background: #f1f2f4;
}

.subtitle-text-pink {
    color: #8D3176;
    font-size: 13px;
    font-weight: 600;
}

/* Archived Clients Grid */
.archived-clients-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.archived-client-item {
    background: #fff;
    border: 1px solid #efefef;
    border-radius: 12px;
    padding: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.archived-client-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.client-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-direction: row-reverse;
}

.arrow-left-icon {
    color: #1a1919;
}

.remaining-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.remaining-label {
    font-size: 12px;
    color: #999;
    font-weight: 500;
}

.remaining-value {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 700;
}

.pink-text {
    color: #8D3176;
}

.client-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: right;
    gap: 4px;
}

.client-id {
    font-size: 11px;
    color: #666;
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 600;
}

.dot.yellow {
    width: 6px;
    height: 6px;
    background: #F2C94C;
    border-radius: 50%;
    display: inline-block;
}

.client-name {
    font-size: 15px;
    font-weight: 800;
    color: #1a1919;
    margin: 0;
}

.client-nationality {
    font-size: 13px;
    color: #999;
    margin: 0;
    font-weight: 500;
}

/* Productivity Section */
.card-productivity {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.card-header-flex-right {
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    gap: 12px;
}

.card-header-flex-center,
.card-header-flex-center .title-group-text {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    color: white;
}

.card-header-flex-center .title-group-text .card-title-main {

    color: white;
}

.productivity-chart-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    /* flex: 1; */
    margin: 24px 0;
}

.circular-progress-donut {
    position: relative;
    width: 140px;
    height: 140px;
    margin-bottom: 12px;
}

.circular-progress-svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.progress-track {
    fill: none;
    stroke: rgba(255, 255, 255, 0.15);
    stroke-width: 10;
}

.progress-fill {
    fill: none;
    stroke: #00BA88;
    stroke-width: 10;
    stroke-linecap: round;
    stroke-dasharray: 251.33;
    transition: stroke-dashoffset 0.5s ease;
}

.inner-circle {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.progress-value {
    font-size: 28px;
    font-weight: 800;
    color: #ffffff;
}

.chart-label {
    font-size: 14px;
    color: white;
    font-weight: 600;
    margin: 0;
}

.productivity-footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding-top: 16px;
    border-top: 1px solid #efefef;
}

.footer-time {
    font-size: 15px;
    font-weight: 700;
    color: white;
}

/* ========== CLIENT COUNTS CARD ========== */
.client-counts-chart {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-top: 24px;
    height: 180px;
    padding: 0 10px;
}

.chart-bar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.bar-value-top {
    font-size: 13px;
    font-weight: 700;
    color: #1a1919;
}

.bar-track {
    width: 14px;
    height: 100px;
    background: #f3f3f3;
    border-radius: 8px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.bar-fill {
    width: 100%;
    background: #8D3176;
    border-radius: 8px;
    transition: height 0.5s ease;
}

.bar-label-bottom {
    font-size: 11px;
    font-weight: 600;
    color: #1a1919;
    text-align: center;
    margin-top: 4px;
}

/* ========== CLIENT GROWTH CARD ========== */
.dropdown-select-simple {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    color: #666;
    padding: 4px 0;
}

.dropdown-text {
    font-size: 13px;
    font-weight: 600;
}

.dropdown-icon {
    color: #666;
}

.growth-chart-container {
    display: flex;
    flex-direction: column;
    margin-top: 24px;
}

.growth-chart-svg-wrapper {
    position: relative;
    width: 100%;
    height: 130px;
}

.growth-line-chart {
    width: 100%;
    height: 100%;
    overflow: visible;
}

.chart-tooltip {
    position: absolute;
    color: #1a1919;
    font-weight: 800;
    font-size: 14px;
    padding: 6px 10px;
    border-radius: 6px;
    transform: translate(-50%, -100%);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

.chart-tooltip.tooltip-mint {
    background: #6EDDD0;
    left: 73.7%;
    top: 55%;
}

.growth-chart-x-axis {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    padding: 0 8px;
}

.growth-chart-x-axis span {
    font-size: 11px;
    color: #bdc1d1;
    font-weight: 600;
}

/* ========== DEPARTURES CARD ========== */
.departures-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 24px;
}

.departures-total-label {
    font-size: 14px;
    font-weight: 800;
    color: #1a1919;
    align-self: flex-start;
}

.departures-progress {
    display: flex;
    align-items: center;
    gap: 12px;
}

.departures-progress-text {
    font-size: 14px;
    font-weight: 700;
    color: #8D3176;
    white-space: nowrap;
}

.departures-progress-bar {
    flex: 1;
    height: 10px;
    background: #f1f2f4;
    border-radius: 6px;
    overflow: hidden;
}

.departures-progress-fill {
    height: 100%;
    background: #e68a00;
    border-radius: 6px;
}

.departures-inner-card {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.departures-inner-card img {
    width: 28px;
    height: 28px;
}

.departures-inner-title {
    font-size: 15px;
    font-weight: 800;
    color: #1a1919;
}

.departures-meta-row {
    display: flex;
    justify-content: space-between;
    gap: 8px;
}

.departures-meta-pill {
    flex: 1;
    background: #fff;
    padding: 8px;
    border-radius: 8px;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: #666;
}

.btn-purple-full {
    width: 100%;
    padding: 12px;
    background: #8D3176;
    color: #fff;
    border-radius: 8px;
    border: none;
    font-size: 14px;
    font-weight: 700;
    transition: opacity 0.2s ease;
}

.btn-gray-full {
    width: 100%;
    padding: 12px;
    background: #e6e8ec;
    color: #1a1919;
    border-radius: 8px;
    border: none;
    font-size: 14px;
    font-weight: 700;
    transition: background 0.2s ease;
}

.btn-purple-full:hover {
    opacity: 0.9;
}

.btn-gray-full:hover {
    background: #d5d8df;
}

/* ========== RECENT ACTIVITIES CARD ========== */
.activities-header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.btn-outline-purple-icon {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: 1px solid #8D3176;
    background: transparent;
    color: #8D3176;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
}



.footer-divider {
    width: 1px;
    height: 20px;
    background: #ccc;
}

.footer-text {
    font-size: 14px;
    font-weight: 600;
    color: #fcfcfc;
}

/* ========== TASK LIST CARD ========== */
.card {
    /* background: rgba(243, 243, 243, 0.66); */
    border-radius: 14px;
    padding: 18px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

/* ========== TASK LIST CARD ========== */
.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.card-title {
    font-size: 22px;
    font-weight: 800;
    color: #1a1919;
}

.add-task-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    color: rgba(141, 49, 118, 1);
    font-size: 14px;
    font-weight: 700;
    transition: all 0.3s ease;
    flex-direction: row-reverse;
}

.add-task-btn:hover {
    opacity: 0.8;
}

.add-task-btn .plus-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #392d54;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: 400;
}

/* Task List Items */
.task-list {
    display: flex;
    flex-direction: column;
    max-height: 400px;
    overflow-y: auto;
    padding-left: 8px;
    /* For scrollbar breathing room */
}

/* Custom scrollbar for task list */
.task-list::-webkit-scrollbar {
    width: 6px;
}

.task-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.task-list::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.task-list::-webkit-scrollbar-thumb:hover {
    background: #bbb;
}

.task-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid #efefef;
    transition: background 0.2s ease;
}

.task-item:last-child {
    border-bottom: none;
}

.task-checkbox {
    width: 26px;
    height: 26px;
    border: 2px solid #8e94a3;
    border-radius: 50%;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.3s ease;
}

.task-checkbox:hover {
    border-color: rgba(141, 49, 118, 0.5);
}

.task-checkbox.checked {
    background: #fff;
    border-color: #8e94a3;
    position: relative;
}

.task-checkbox.checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    background: #392d54;
    border-radius: 50%;
}

.task-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.task-name {
    font-size: 15px;
    font-weight: 700;
    color: #1a1919;
}

.task-description {
    font-size: 13px;
    color: #999;
    font-weight: 500;
}

.task-date {
    font-size: 13px;
    color: #999;
    font-weight: 400;
    margin-top: 2px;
}

.task-delete {
    color: #999;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.3s ease;
    background: none;
    padding: 4px;
    flex-shrink: 0;
}

.task-delete:hover {
    color: #e74c3c;
}

/* ========== RECENT TASKS CARD ========== */
/* ========== RECENT TASKS NEW DESIGN ========== */
#card-recent-tasks-container {
    background: none;
    border-radius: 20px;
    padding: 0;
    box-shadow: none;
}

.recent-tasks-new-header {
    background: rgba(243, 243, 243, 0.66);
    border-radius: 18px;
    padding: 14px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
}

.recent-tasks-new-title {
    font-size: 18px;
    font-weight: 800;
    color: #1a1919;
    margin: 0;
}

.view-all-new-btn {
    padding: 6px 16px;
    border-radius: 8px;
    border: 1.5px solid rgba(141, 49, 118, 1);
    background: transparent;
    color: rgba(141, 49, 118, 1);
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.view-all-new-btn:hover {
    background: rgba(141, 49, 118, 0.05);
}

.recent-task-new-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    background: rgba(243, 243, 243, 0.66);
    padding: 16px;
    border-radius: 20px;
}

.recent-task-new-item {
    background: #fff;
    border-radius: 14px;
    padding: 12px 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    position: relative;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.recent-task-status-pill {
    position: absolute;
    top: -4px;
    left: 18px;
    /* Image shows arrow on left, status might be right? Wait. */
    /* Let's re-check the image. Arrow is left. Date is right. Status is TOP RIGHT. */
    right: 18px;
    width: 50px;
    height: 8px;
    border-radius: 4px;
}

.recent-task-status-pill.teal {
    background: #16a085;
}

.recent-task-status-pill.orange {
    background: #f39c12;
}

.recent-task-status-pill.pink {
    background: #f06292;
}

.recent-task-row-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
}

.recent-task-date-new {
    font-size: 13px;
    font-weight: 600;
    color: #1a1919;
}

.recent-task-arrow-new {
    color: #000;
    display: flex;
    align-items: center;
}

.recent-task-arrow-new svg {
    width: 20px;
    height: 20px;
}

.recent-task-row-mid {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    /* Align task name to right in RTL */
    gap: 8px;
}

.recent-task-name-new {
    font-size: 16px;
    font-weight: 700;
    color: #1a1919;
    margin: 0;
}

.recent-task-check-new {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 1.5px solid #1a1919;
    display: flex;
    align-items: center;
    justify-content: center;
}

.recent-task-check-new svg {
    width: 14px;
    height: 14px;
    fill: none;
    stroke: #1a1919;
    stroke-width: 2.5;
}

.recent-task-row-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 4px;
}

.recent-task-avatar-new {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.recent-task-project-pill-new {
    display: flex;
    align-items: center;
    gap: 6px;
    background: #f2f4f7;
    padding: 5px 10px;
    border-radius: 6px;
    color: #667085;
}

.recent-task-project-pill-new svg {
    width: 16px;
    height: 16px;
}

.recent-task-project-pill-new span {
    font-size: 12px;
    font-weight: 600;
}

/* ========== ANIMATIONS ========== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.stat-card {
    animation: fadeInUp 0.6s ease forwards;
}

.stat-card:nth-child(1) {
    animation-delay: 0.1s;
}

.stat-card:nth-child(2) {
    animation-delay: 0.2s;
}

.stat-card:nth-child(3) {
    animation-delay: 0.3s;
}

.stat-card:nth-child(4) {
    animation-delay: 0.4s;
}

.card {
    animation: fadeInUp 0.6s ease forwards;
    animation-delay: 0.5s;
}

.sidebar-nav-item {
    animation: slideInRight 0.4s ease forwards;
}

.sidebar-nav-item:nth-child(1) {
    animation-delay: 0.05s;
}

.sidebar-nav-item:nth-child(2) {
    animation-delay: 0.1s;
}

.sidebar-nav-item:nth-child(3) {
    animation-delay: 0.15s;
}

.sidebar-nav-item:nth-child(4) {
    animation-delay: 0.2s;
}

.sidebar-nav-item:nth-child(5) {
    animation-delay: 0.25s;
}

.sidebar-nav-item:nth-child(6) {
    animation-delay: 0.3s;
}

.sidebar-nav-item:nth-child(7) {
    animation-delay: 0.35s;
}

.sidebar-nav-item:nth-child(8) {
    animation-delay: 0.4s;
}

.sidebar-nav-item:nth-child(9) {
    animation-delay: 0.45s;
}

.sidebar-nav-item:nth-child(10) {
    animation-delay: 0.5s;
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .content-grid {
        grid-template-columns: 1fr;
    }

    .content-grid-top {
        grid-template-columns: 1fr;
    }

    .content-grid-middle {
        grid-template-columns: 1fr;
    }

    .content-grid-bottom {
        grid-template-columns: 1fr;
        height: auto;
    }
}

@media (max-width: 768px) {
    .sidebar {
        width: 80px;
    }

    .sidebar-nav-item span {
        display: none;
    }

    .main-content {
        margin-right: 80px;
        border-radius: 20px 0 0 20px;
    }

    .header {
        padding: 16px 20px;
        flex-direction: column;
        gap: 16px;
    }

    .header-right {
        align-items: center;
        text-align: center;
    }

    .stats-section {
        padding: 0 16px 16px;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .content-section {
        padding: 0 16px 16px;
    }

    .stat-card-details {
        gap: 16px;
    }

    .dashboard-highlight-section {
        margin-bottom: 16px;
        padding: 0 24px;
    }

    .content-grid-top {
        grid-template-columns: 1fr;
    }

    .content-grid-middle {
        grid-template-columns: 1fr;
    }

    .content-grid-bottom {
        grid-template-columns: 1fr;
        height: auto;
    }

    .card-recent-activities-wrapper {
        height: auto;
    }

    .card-recent-activities {
        position: relative !important;
    }
}

@media (max-width: 480px) {
    .header-greeting h1 {
        font-size: 1.3rem;
    }

    .header-left {
        flex-wrap: wrap;
        justify-content: center;
    }

    .stats-section {
        padding: 0 12px 12px;
    }

    .content-section {
        padding: 0 12px 12px;
    }

    .dashboard-highlight-section {
        padding: 0 12px;
    }

    .stat-card {
        border-radius: 24px;
        padding: 20px 16px;
    }
}

/* ========== CLIENTS PAGE ========== */
.clients-section {
    padding: 0 24px 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

/* Filters */
.clients-filters {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    flex-wrap: wrap;
    flex-direction: row;
}

.clients-filters .btn-outline-primary {
    border: 1px solid rgba(65, 47, 106, 1);
    color: rgba(65, 47, 106, 1);
    background: transparent;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s;
}

.clients-filters .btn-outline-primary:hover {
    background: rgba(141, 49, 118, 0.05);
}

.filters-group {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-direction: row;
}

.filter-select {
    position: relative;
    border: 1px solid #E5E5E5;
    border-radius: 12px;
    background: #fff;
    min-width: 120px;
    width: fit-content !important;
    height: 48px;
}

.filter-select.custom-select {
    border: none;
    padding: 0;
}

.filter-select .custom-select-trigger {
    padding: 8px 12px;
    height: 100%;
    display: flex;
    align-items: center;
}

.filter-select .custom-options {
    top: calc(100% + 4px);
}

.filter-select::after {
    content: '';
}

.filter-date,
.filter-search {
    position: relative;
    border: 1px solid #E5E5E5;
    border-radius: 17px;
    background: #fff;
    display: flex;
    align-items: center;
    padding: 7px 12px;
    flex-direction: row;
    height: 48px;
}

.filter-date input,
.filter-search input {
    background: transparent;
    color: #333;
    font-size: 13px;
    font-weight: 500;
    width: 100%;
    height: 100%;
}

.filter-date {
    width: 180px;
}

.filter-search {
    width: 280px;
}

.filter-date input::placeholder,
.filter-search input::placeholder {
    color: #A2A2A2;
}

.filter-date svg,
.filter-search svg {
    width: 18px;
    height: 18px;
    color: #000000;
    margin-left: 8px;
}

/* Flatpickr Custom Match */
.flatpickr-calendar {
    font-family: 'Lama Sans', sans-serif !important;
    border-radius: 16px !important;
    border: 1px solid #E5E5E5 !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08) !important;
    direction: rtl;
}

.flatpickr-day.selected,
.flatpickr-day.startRange,
.flatpickr-day.endRange,
.flatpickr-day.selected.inRange,
.flatpickr-day.startRange.inRange,
.flatpickr-day.endRange.inRange,
.flatpickr-day.selected:focus,
.flatpickr-day.startRange:focus,
.flatpickr-day.endRange:focus,
.flatpickr-day.selected:hover,
.flatpickr-day.startRange:hover,
.flatpickr-day.endRange:hover,
.flatpickr-day.selected.prevMonthDay,
.flatpickr-day.startRange.prevMonthDay,
.flatpickr-day.endRange.prevMonthDay,
.flatpickr-day.selected.nextMonthDay,
.flatpickr-day.startRange.nextMonthDay,
.flatpickr-day.endRange.nextMonthDay {
    background: rgba(141, 49, 118, 1) !important;
    border-color: rgba(141, 49, 118, 1) !important;
}

/* Tabs & Actions */
.clients-tabs-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #F0F0F0;
    padding-bottom: 0px;
    margin-top: 10px;
}

.actions-group {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
    flex-direction: row-reverse;
}

.btn-action-outline {
    border: 1px solid #ccc;
    background: transparent;
    color: #1a1919;
    padding: 11px 16px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s;
}

.btn-action-outline:hover {
    background: #f9f9f9;
}

.btn-action-outline svg,
.btn-action-outline img {
    width: 16px;
    height: 16px;
    color: rgba(141, 49, 118, 1);
}

.btn-action-outline.btn-export,
.btn-action-outline.btn-import {
    border-color: rgba(65, 47, 106, 1);
    color: rgba(65, 47, 106, 1);
}

.btn-action-outline.btn-download {
    border-color: rgba(208, 213, 221, 1);
    color: rgba(52, 64, 84, 1);
}

.tabs-group {
    display: flex;
    gap: 24px;
}

.tab-btn {
    background: transparent;
    border: none;
    color: #666;
    font-size: 15px;
    font-weight: 600;
    padding: 0 0 12px 0;
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.tab-btn.active {
    color: rgba(141, 49, 118, 1);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 3px;
    background: #8D3176;
    border-radius: 3px 3px 0 0;
}

.tab-badge {
    background: #F2F4F7;
    color: #667085;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.tab-btn.active .tab-badge {
    background: #8D3176;
    color: #fff;
}

/* Table */
.clients-table {
    /* background: #F9F9F9; */
    border-radius: 12px;
    padding: 10px 0;
}

.clients-table table {
    width: 100%;
    border-spacing: 0;
    text-align: right;
}

.clients-table th {
    color: #1a1919;
    font-weight: 700;
    font-size: 13px;
    padding: 10px 16px;
}

.clients-table td {
    padding: 10px 16px;
    vertical-align: middle;
    color: #333;
    font-size: 13px;
    font-weight: 600;
}

.clients-table tr {
    background: transparent;
    transition: background 0.3s;
    border-bottom: 2px solid #fff;
}

.clients-table tbody tr:hover {
    background: #f0f0f0;
}

.clients-table input[type="checkbox"] {
    width: 18px;
    height: 18px;
    border: 1px solid #ccc;
    border-radius: 4px;
    cursor: pointer;
}

.td-id {
    color: #8D3176;
    font-weight: 700;
    font-size: 12px;
    margin-bottom: 1px;
}

.td-name {
    color: #1a1919;
    font-weight: 600;
    font-size: 13px;
}

.status-badge {
    /*display: inline-block;*/
    /* border-radius: 8px; */
    font-size: 13px;
    font-weight: 700;
}

.status-active  , .status-open{
    background: #EBF7EE;
    color: #34A853;
}

.status-pending {
    background: #FFF7E6;
    color: #F8B500;
}

.status-archived ,
.status-closed
{
    background: #EBEEF2;
    color: #8E94A3;
}

.status-lost  , .status-cancelled{
    background: #FFEBEE;
    color: #E53935;
}

.status-inactive {
    color: #E0823D;
    background-color: #FDF2E9;
}

.client-count-link {
    color: #BA3382;
    text-decoration: underline;
}

.btn-action-icon-bg {
    background-color: #E2E8F0;
    border-radius: 6px;
    padding: 4px;
    display: inline-flex;
}

.icon-sm {
    width: 18px;
    height: 18px;
}

.btn-options {
    background: #E5E5E5;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-options:hover {
    background: #d4d4d4;
}

.btn-options svg {
    width: 20px;
    height: 20px;
}

/* Row Actions Dropdown - Image 2 style */
.row-options-dropdown {
    position: absolute;
    left: 80px;
    top: 50%;
    transform: translateY(-50%) translateX(-10px);
    background: #fff;
    border-radius: 24px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    width: max-content;
    padding: 16px;
    display: none;
    flex-direction: column;
    gap: 4px;
    border: 1px solid #F0F0F0;
}

.row-options-dropdown.open {
    display: flex;
}

.row-option-item {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 12px 16px;
    /* border-radius: 12px; */
    transition: background 0.2s;
    color: #1a1919;
    font-weight: 600;
    font-size: 20px;
    text-align: right;
}

.row-option-item:hover {
    background: #F9FAFB;
}

.row-option-item svg {
    width: 24px;
    height: 24px;
    stroke: #1a1919;
}

.row-option-item.text-danger {
    color: #B42318;
}

.row-option-item.text-danger svg {
    stroke: #B42318;
}

.dropdown-divider {
    height: 1px;
    background: #F0F0F0;
    margin: 8px 0;
}

/* Create Quotation Page Styles */
.create-quotation-section {
    padding: 0 24px 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.create-quotation-card {
    background: #fff;
    border: 1px solid #F0F0F0;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
}

.create-form-label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #1a1919;
    margin-bottom: 6px;
}

.create-form-label span {
    color: #E53935;
}

.create-form-input {
    width: 100%;
    height: 48px;
    background: #F8FAFB;
    border: 1px solid #F0F0F0;
    border-radius: 10px;
    padding: 0 14px;
    font-size: 13px;
    color: #333;
    transition: all 0.3s;
}

.create-form-input:focus {
    border-color: #8D3176;
    background: #fff;
}

.create-input-wrapper {
    position: relative;
    width: 100%;
}

.search-product-wrapper {
    margin-top: 24px;
}

.search-product-input {
    width: 100%;
    height: 48px;
    background: #F8FAFB;
    border: 1px solid #F0F0F0;
    border-radius: 12px;
    padding: 0 50px 0 16px;
    font-size: 14px;
}

.search-product-icon {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    background: #8D3176;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-product-icon svg {
    width: 14px;
    height: 14px;
    stroke: #fff;
}

/* Added Products List */
.added-products-container {
    margin-top: 30px;
    display: flex;
    gap: 24px;
}

.added-products-main {
    flex: 1;
    background: #fff;
    border: 1px solid #F0F0F0;
    border-radius: 24px;
    padding: 24px;
}

.added-products-header {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 24px;
}

.products-table-header {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1.5fr auto;
    gap: 16px;
    padding: 0 16px 12px;
    color: #8E94A3;
    font-weight: 600;
    font-size: 14px;
    text-align: center;
}

.product-row {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 12px;
}

.product-row-content {
    flex: 1;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1.5fr;
    gap: 16px;
    align-items: center;
    padding: 12px 24px;
    background: #F9FAFB;
    border-radius: 40px;
    text-align: center;
}

.product-info-cell {
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.product-name-val {
    font-size: 15px;
    font-weight: 700;
    color: #1a1919;
}

.product-code-val {
    font-size: 13px;
    color: #8D3176;
    font-weight: 600;
}

.qty-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #DAE1F0;
    border-radius: 14px;
    padding: 3px;
    width: fit-content;
    margin: 0 auto;
}

.qty-btn {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #1a1919;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.qty-val {
    font-weight: 700;
    font-size: 15px;
}

.delete-product-btn {
    color: #B42318;
    background: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Financial Summary Sidebar */
.financial-summary-card {
    width: 100%;
    background: #F9FAFB;
    border-radius: 24px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.financial-summary-card .create-form-input,
.financial-summary-card .custom-select-trigger {
    background: #fff !important;
}

.summary-title {
    font-size: 20px;
    font-weight: 700;
    text-align: center;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.summary-label {
    font-size: 14px;
    font-weight: 600;
    color: #1a1919;
}

.summary-val {
    font-size: 16px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}

.summary-val.total-large {
    font-size: 24px;
    color: #8D3176;
}

.validity-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #8E94A3;
    font-size: 13px;
    margin-top: 12px;
    justify-content: flex-start;
}

/* Responsiveness for Create Quotation Page */
@media (max-width: 1100px) {
    .added-products-container {
        flex-direction: column;
    }

    .financial-summary-card {
        width: 100%;
    }

    .added-products-main {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .products-table-header,
    .product-row {
        min-width: 850px;
    }
}

@media (max-width: 768px) {
    .create-header-row {
        flex-direction: column;
        gap: 16px;
    }

    .create-header-row .form-group {
        width: 100% !important;
    }

    .form-actions-footer {
        flex-direction: column-reverse;
        gap: 12px;
    }

    .btn-save-main,
    .btn-save-convert,
    .btn-cancel-main {
        width: 100%;
        padding: 14px 20px;
        margin-inline-start: 0 !important;
    }
}
/*copy*/

.copy-btn {
    border: none;
    background: transparent;
    padding: 4px;
    border-radius: 6px;
    cursor: pointer;
    transition: 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.copy-btn img {
    width: 16px;
    height: 16px;
    opacity: 0.6;
    transition: 0.2s;
}

.copy-btn:hover {
    background: #f3f4f6;
}

.copy-btn:hover img {
    opacity: 1;
}

.copy-btn.copied {
    background: #e6f9ed;
}

.copy-btn.copied img {
    opacity: 1;
    transform: scale(1.1);
}
#copy-toast {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -40%) scale(0.95);

    background: #111827;
    color: #fff;
    padding: 12px 18px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 500;

    opacity: 0;
    transition: all 0.25s ease;
    pointer-events: none;
    z-index: 9999;
}

#copy-toast.show {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}
/* Bottom Actions */
.form-actions-footer {
    display: flex;
    justify-content: flex-start;
    gap: 16px;
    margin-top: 40px;
}

.btn-save-main {
    background: #8D3176;
    color: #fff;
    border-radius: 12px;
    padding: 10px 40px;
    font-size: 15px;
    font-weight: 700;
}

.btn-save-convert {
    background: #fff;
    border: 1.5px solid #F8B500;
    color: #F8B500;
    border-radius: 12px;
    padding: 10px 24px;
    font-size: 15px;
    font-weight: 700;
}

.btn-cancel-main {
    background: #fff;
    border: 1.5px solid #1a1919;
    color: #1a1919;
    border-radius: 12px;
    padding: 10px 40px;
    font-size: 15px;
    font-weight: 700;
    margin-inline-start: auto;
}

/* Pagination */
.clients-pagination {
    display: flex;
    gap: 8px;
    align-items: center;
}

/* ========== ROW OPTIONS DROPDOWN ========== */
.td-actions {
    position: relative;
    text-align: center;
}

.row-options-dropdown {
    position: absolute;
    left: 100%;
    top: 80%;
    transform: translateY(10px) translateX(10px);
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    min-width: 180px;
    padding: 8px 0;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    border: 1px solid #f0f0f0;
}

/* Arrow for the dropdown box */
/* .row-options-dropdown::before {
    content: '';
    position: absolute;
    left: -6px;
    top: 12px;
    transform: translateY(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background: #fff;
    border-top: 1px solid #f0f0f0;
    border-right: 1px solid #f0f0f0;
} */

.row-options-dropdown.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(-37px) translateX(0);
}

.row-options-dropdown.open.open-up {
    top: auto;
    bottom: 50%;
    transform: translateY(-10px) translateX(0);
}

.row-option-item {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 12px 20px;
    color: #1a1919;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s ease;
    background: transparent;
    border: none;
    width: 100%;
    text-align: right;
    cursor: pointer;
    flex-direction: row-reverse;
}

.row-option-item:hover {
    background: #f8f8f8;
}

.row-option-item svg {
    width: 20px;
    height: 20px;
}

.row-option-item.text-whatsapp {
    color: #009776;
}
.text-danger{
    color: #E2001A !important;
}
.row-option-item.text-danger {
    color: #E2001A;
    border-top: 1px solid #f0f0f0;
    margin-top: 4px;
    padding-top: 16px;
}

/* ========== MODAL POPUP ========== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: #fff;
    border-radius: 22px;
    width: 100%;
    max-width: 460px;
    padding: 28px;
    position: relative;
    transform: translateY(20px);
    transition: all 0.3s ease;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.modal-overlay.open .modal-content {
    transform: translateY(0);
}

.modal-header {
    margin-bottom: 20px;
    text-align: center;
}

.modal-title {
    font-size: 20px;
    font-weight: 800;
    color: #1a1919;
}

.modal-body {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-size: 14px;
    font-weight: 700;
    color: #1a1919;
}

/* Custom Select styling for Modal */
.custom-select {
    position: relative;
    user-select: none;
    width: 100%;
}

.custom-select-trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    min-height: 48px;
    background: #fff;
    border: 1px solid #E5E5E5;
    border-radius: 17px;
    cursor: pointer;
    font-size: 14px;
    color: #392929;
    transition: all 0.2s;
}

.custom-select-trigger .arrow {
    width: 12px;
    height: 12px;
    border-bottom: 2px solid #666;
    border-left: 2px solid #666;
    transform: rotate(-45deg) translateY(-2px);
    transition: transform 0.3s;
}

.custom-select.open .custom-select-trigger .arrow {
    transform: rotate(135deg) translateY(-2px);
}

.custom-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid #E5E5E5;
    border-radius: 16px;
    margin-top: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    z-index: 1000;
    transition: all 0.3s ease;
    padding: 8px 0;
    max-height: 250px;
    overflow-y: auto;
}

.custom-options::-webkit-scrollbar {
    width: 6px;
}

.custom-options::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 8px;
    margin: 8px 0;
}

.custom-options::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 8px;
}

.custom-options::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

.custom-select.open .custom-options {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
    transform: translateY(0);
}

.custom-option {
    display: block;
    padding: 10px 14px;
    font-size: 14px;
    color: #1a1919;
    cursor: pointer;
    transition: background 0.2s;
    font-weight: 500;
}

.custom-option:hover {
    background: #f8f8f8;
}

.custom-option.selected {
    background: #f0f0f0;
    font-weight: 700;
}

.form-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #E5E5E5;
    border-radius: 12px;
    background: #FDFDFD;
    resize: none;
    height: 100px;
    font-size: 14px;
    color: #333;
    font-family: inherit;
}

.form-textarea::placeholder {
    color: #999;
}

.modal-footer {
    margin-top: 24px;
    display: flex;
    gap: 12px;
}

.btn-modal {
    flex: 1;
    padding: 10px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.btn-modal-primary {
    background: rgba(141, 49, 118, 1);
    color: #fff;
    border: none;
}

.btn-modal-primary:hover {
    background: rgba(160, 60, 136, 1);
}

.btn-modal-secondary {
    background: #fff;
    color: #1a1919;
    border: 1px solid #1a1919;
}

.btn-modal-secondary:hover {
    background: #f9f9f9;
}

/* ========== CREATE CLIENT PAGE ========== */

.create-back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(212, 142, 0, 1);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    margin-bottom: 8px;
    transition: opacity 0.3s;
    flex-direction: row-reverse;
    justify-content: flex-end;
    align-self: flex-start;
}

.create-back-link:hover {
    opacity: 0.7;
}

.create-back-link svg {
    color: rgba(212, 142, 0, 1);
}

.create-client-section {
    padding: 0 24px 24px;
}

.create-client-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    /* box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04); */
    border: 1px solid #F0F0F0;
}

.create-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.create-form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.create-form-label {
    font-size: 14px;
    font-weight: 700;
    color: #1a1919;
    text-align: right;
}

.create-form-label-centered {
    text-align: center;
    font-size: 14px;
}

.create-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.create-form-input {
    width: 100%;
    height: 48px;
    padding: 10px 14px;
    border: 1px solid rgba(226, 232, 240, 1);
    border-radius: 10px;
    font-size: 13px;
    color: rgba(100, 116, 139, 1);
    background: rgba(248, 250, 251, 1);
    transition: border-color 0.3s;
    font-family: inherit;
}

textarea.create-form-input {
    height: auto;
    min-height: 120px;
    padding-top: 12px;
    padding-bottom: 12px;
}

.create-input-suffix {
    margin-right: 10px;
    font-size: 13px;
    font-weight: 600;
    color: rgba(100, 116, 139, 1);
    white-space: nowrap;
}

.create-input-with-suffix .create-form-input {
    flex: 1;
}

.create-form-input::placeholder {
    color: rgba(100, 116, 139, 1);
}

.create-form-input:focus {
    border-color: rgba(141, 49, 118, 0.5);
}

.create-input-icon {
    position: absolute;
    left: 14px;
    width: 20px;
    height: 20px;
    color: #999;
    pointer-events: none;
}

/* Date input - hide native browser icon */
.create-date-input::-webkit-calendar-picker-indicator {
    opacity: 0;
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.create-date-input::-webkit-datetime-edit-text,
.create-date-input::-webkit-datetime-edit-month-field,
.create-date-input::-webkit-datetime-edit-day-field,
.create-date-input::-webkit-datetime-edit-year-field {
    color: rgba(100, 116, 139, 1);
}

.create-date-input::-webkit-datetime-edit {
    direction: rtl;
}

.create-date-input:valid::-webkit-datetime-edit-text,
.create-date-input:valid::-webkit-datetime-edit-month-field,
.create-date-input:valid::-webkit-datetime-edit-day-field,
.create-date-input:valid::-webkit-datetime-edit-year-field {
    color: rgba(100, 116, 139, 1);
}

/* Phone input with country code */
.create-phone-input {
    text-align: right;
    padding-right: 100px;
}

.create-phone-code {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 0 14px;
    border-left: 1px solid #E5E5E5;
    color: #333;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    position: absolute;
    right: 1px;
    top: 1px;
    bottom: 1px;
    border-radius: 0 12px 12px 0;
    background: #fff;
    cursor: pointer;
}

.create-phone-code svg {
    color: #666;
}

/* WhatsApp options row */
.create-whatsapp-row {
    margin-bottom: 28px;
    margin-top: -16px;
}

.create-whatsapp-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.create-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    user-select: none;
}

.create-checkbox-label input[type="checkbox"] {
    display: none;
}

.create-checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #ccc;
    border-radius: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.create-checkbox-label input[type="checkbox"]:checked+.create-checkmark {
    background: rgba(20, 174, 92, 1);
    border-color: rgba(20, 174, 92, 1);
}

.create-checkbox-label input[type="checkbox"]:checked+.create-checkmark::after {
    content: '';
    width: 6px;
    height: 10px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    margin-top: -2px;
}

.create-add-whatsapp {
    display: flex;
    align-items: center;
    gap: 6px;
    color: rgba(141, 49, 118, 1);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity 0.3s;
}

.create-add-whatsapp:hover {
    opacity: 0.7;
}

.create-add-whatsapp svg {
    color: rgba(141, 49, 118, 1);
}

/* Dynamic WhatsApp number rows */
.create-whatsapp-number-row {
    margin-bottom: 16px;
    margin-top: -8px;
}

.create-remove-whatsapp {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #E2001A;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    margin-top: 6px;
    transition: opacity 0.3s;
}

.create-remove-whatsapp:hover {
    opacity: 0.7;
}

.create-remove-whatsapp svg {
    color: #E2001A;
}

/* Select wrapper */
.create-select-wrapper {
    position: relative;
}

.create-form-select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid #E5E5E5;
    border-radius: 10px;
    font-size: 13px;
    color: #999;
    background: #fff;
    font-family: inherit;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    transition: border-color 0.3s;
}

.create-form-select:focus {
    border-color: rgba(141, 49, 118, 0.5);
    outline: none;
}

.create-form-select option {
    color: #333;
}

.create-select-arrow {
    position: absolute;
    left: 14px;
    width: 18px;
    height: 18px;
    color: #666;
    pointer-events: none;
}

/* Override custom-select-trigger styles for create page */
.create-custom-select .custom-select-trigger {
    background: rgba(248, 250, 251, 1);
    border-color: rgba(226, 232, 240, 1);
    color: rgba(100, 116, 139, 1);
}

/* Saudi radio group */
.create-saudi-row {
    margin-top: 8px;
}

.create-saudi-row .create-form-group {
    align-items: flex-start;
}

.create-full-width {
    grid-column: 1 / -1;
}

.create-radio-group {
    display: flex;
    align-items: center;
    gap: 24px;
    justify-content: center;
}

.create-radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    cursor: pointer;
    user-select: none;
}

.create-radio-label input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: rgba(141, 49, 118, 1);
    cursor: pointer;
}

.create-radio-custom {
    display: none;
}

/* Additional info link */
.create-additional-row {
    margin-top: 8px;
    margin-bottom: 0;
}

.create-additional-row .create-form-group {
    align-items: flex-start;
}

.create-additional-info {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: rgba(0, 151, 118, 1);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: opacity 0.3s;
}

.create-additional-info:hover {
    opacity: 0.7;
}

.create-additional-info svg {
    color: rgba(0, 151, 118, 1);
}

.create-additional-info.active svg line:first-child {
    display: none;
}

/* Extra information section */
.create-extra-info {
    margin-top: 24px;
    padding-top: 24px;
    border-top: 1px solid #F0F0F0;
}

.create-extra-info .create-form-row {
    margin-bottom: 24px;
}

/* Form action buttons */
.create-form-actions {
    display: flex;
    gap: 16px;
    margin-top: 32px;
    justify-content: flex-end;
}

/* ========== VISIT REPORT – PRODUCTS SECTION ========== */
.visit-product-search-wrapper {
    position: relative;
    width: 100%;
}

.visit-product-search-wrapper .create-form-input {
    background: #F8FAFB;
    border-radius: 999px;
    padding-right: 46px;
    padding-left: 24px;
}

.visit-product-search-wrapper .create-input-icon {
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #8D3176;
    position: absolute;
}

.visit-product-search-wrapper .create-input-icon svg {
    width: 20px;
    height: 20px;
    stroke: #8D3176;
}

.product-search-results {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    left: 0;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    border: 1px solid #E2E8F0;
    padding: 8px 0;
    max-height: 260px;
    overflow-y: auto;
    z-index: 20;
}

.product-search-result-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    cursor: pointer;
    font-size: 13px;
}

.product-search-result-item:hover {
    background: #F8FAFC;
}

.client-search-result-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    cursor: pointer;
    font-size: 13px;
}

.client-search-result-item:hover {
    background: #F8FAFC;
}
.client-search-details{
    margin: 10px;
    font-size: 15px;
    border: 1px solid #8D3176;
    padding: 11px;
    display: flex;
    flex-flow: column-reverse;
    gap: 8px;
    color: #8D3176;
}
.client-search-name{
    display: flex;
    flex-flow: column;
    color: #8D3176;
    /* font-size: 11px; */
    font-weight: 600;
}
.product-search-result-main {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.product-search-result-name {
    font-weight: 600;
    color: #1F2933;
}

.product-search-result-code {
    font-weight: 600;
    color: #8D3176;
    font-size: 12px;
}

.product-search-result-price {
    font-weight: 600;
    color: #475569;
    white-space: nowrap;
}

.visit-report-products-card {
    margin-top: 12px;
    background: #F8FAFB;
    border-radius: 24px;
    padding: 20px 24px;
}

.visit-products-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
}

.visit-products-header-title {
    font-size: 16px;
    font-weight: 700;
    color: #1A1919;
}

.visit-products-table-wrapper {
    padding: 10px 16px 6px;
}

.visit-products-table {
    width: 100%;
    border-spacing: 0 12px;
    border-collapse: separate;
    text-align: center;
}

.visit-products-table thead th {
    padding: 8px 10px;
    font-size: 13px;
    font-weight: 600;
    color: #8E94A3;
}

.visit-products-table tbody td {
    padding: 12px 10px;
    font-size: 13px;
    font-weight: 600;
    color: #1A1919;
    background: #FFFFFF;
}

.visit-product-row td:first-child {
    border-top-right-radius: 16px;
    border-bottom-right-radius: 16px;
    text-align: right;
    padding-right: 20px;
}

.visit-product-row td:last-child {
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
}

.visit-product-row {
    background: #FFFFFF;
    box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
    transition: transform 0.2s, box-shadow 0.2s;
}

.visit-product-row:hover {
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.08);
}

.visit-product-info-name {
    font-size: 14px;
    font-weight: 700;
    color: #1A1919;
}

.visit-product-info-code {
    font-size: 12px;
    font-weight: 600;
    color: #8D3176;
}

.visit-qty-control {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #DAE1F0;
    border-radius: 999px;
    padding: 4px;
}

.visit-qty-input {
    width: 40px;
    text-align: center;
    border: none;
    background: transparent;
    font-weight: 700;
    color: #1A1919;
}

.visit-qty-btn {
    width: 26px;
    height: 26px;
    border-radius: 9px;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    color: #1A1919;
}

.visit-product-remove-btn {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: #FEE2E2;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #B91C1C;
}

.visit-unit-price,
.visit-row-total {
    font-weight: 700;
}

.visit-multiselect {
    position: relative;
    width: 220px;
    margin: 0 auto;
}

.visit-multiselect-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 14px;
    background: #FFFFFF;
    border-radius: 10px;
    border: 1px solid #E5E5E5;
    font-size: 13px;
    color: #666;
    cursor: pointer;
    position: relative;
    height: 48px;
    max-height: 48px;
    overflow: hidden;
    transition: border-color 0.3s;
    width: 100%;
}
.load-more-wrapper {
    text-align: center;
    margin-top: 20px;
}

.load-more-btn {
    background: linear-gradient(135deg, #8D3176, #8D3176);
    color: #fff;
    border: none;
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 500;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 20px rgba(79, 70, 229, 0.25);
}

.load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(79, 70, 229, 0.35);
}

.load-more-btn:active {
    transform: scale(0.97);
}

.load-more-btn.loading {
    opacity: 0.7;
    cursor: not-allowed;
}
.load-more-btn.loading::after {
    content: " ...";
    animation: dots 1s infinite;
}

@keyframes dots {
    0% { content: "."; }
    50% { content: ".."; }
    100% { content: "..."; }
}

.visit-multiselect-trigger:hover,
.visit-multiselect.open .visit-multiselect-trigger {
    border-color: rgba(141, 49, 118, 0.5);
}

.visit-multiselect-trigger span {
    font-weight: 600;
    color: #1A1919;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: block;
    flex: 1;
    text-align: right;
    padding-left: 10px;
    min-width: 0;
    /* Allow the span to shrink for ellipsis to work */
}

.visit-multiselect-trigger .arrow {
    width: 12px;
    height: 12px;
    border-bottom: 2px solid #666;
    border-left: 2px solid #666;
    transform: rotate(-45deg) translateY(-2px);
    transition: transform 0.3s;
    flex-shrink: 0;
    margin-right: 8px;
}

.visit-multiselect.open .visit-multiselect-trigger .arrow {
    transform: rotate(135deg) translateY(-2px);
}

.visit-multiselect-options {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    background: #FFFFFF;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    border: 1px solid #E2E8F0;
    padding: 8px 0;
    z-index: 15;

}

.visit-multiselect:not(.open) .visit-multiselect-options {
    display: none;
}

.visit-multiselect.open .visit-multiselect-options {
    display: block;
    max-height: 260px;
    overflow-y: auto;
}
.visit-multiselect-option {
    display: flex;
    align-items: center;
    flex-direction: row-reverse;
    gap: 10px;
    padding: 8px 14px;
    font-size: 13px;
    color: #1A1919;
}

.visit-multiselect-option span {
    flex: 1;
}

.visit-multiselect-option input[type="checkbox"] ,
.checkSingle{
    width: 18px;
    height: 18px;
    border-radius: 4px;
    border: 2px solid #E2E8F0;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background: #FFFFFF;
    cursor: pointer;
    position: relative;
}

.visit-multiselect-option input[type="checkbox"]:checked ,
.checkSingle:checked {
    background: #8D3176;
    border-color: #8D3176;
}

.visit-multiselect-option input[type="checkbox"]:checked::after ,
.checkSingle:checked::after {
    content: '';
    position: absolute;
    inset: 0;
    margin: auto;
    width: 4px;
    height: 8px;
    border: solid #FFFFFF;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.visit-products-summary {
    margin-top: 24px;
    padding-top: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: stretch;
}

.visit-summary-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 14px;
    font-weight: 600;
    width: 100%;
}

.visit-summary-row-label {
    color: #1A1919;
    font-size: 14px;
}

.visit-summary-row-value {
    min-width: 80px;
    text-align: left;
    direction: ltr;
    font-weight: 700;
    color: #1A1919;
}

#discount-amount,
#discount-amount {
    color: #B20015;
}

.visit-summary-row-total {
    border-top: 1px solid rgba(0, 0, 0, 0.07);
    padding-top: 16px;
    width: 100%;
}

.visit-summary-row-total .visit-summary-row-label {
    color: #1A1919;
    font-size: 16px;
    font-weight: 700;
}

.visit-summary-row-total .visit-summary-row-value {
    font-size: 18px;
    color: #8D3176;
}

/* .create-form-actions {
    display: flex;
    gap: 16px;
    margin-top: 32px;
    justify-content: flex-start;
} */

.create-btn-save {
    padding: 14px 80px;
    background: rgba(141, 49, 118, 1);
    color: #fff;
    border: none;
    border-radius: 14px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.3s;
    font-family: inherit;
}

.create-btn-save:hover {
    background: rgba(160, 60, 136, 1);
}

.create-btn-cancel {
    padding: 14px 56px;
    background: #fff;
    color: rgba(141, 49, 118, 1);
    border: 1px solid rgba(141, 49, 118, 1);
    border-radius: 14px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}


.create-btn-cancel:hover {
    background: #f9f9f9;
}
/*scripts*/
.preview-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.preview-item {
    position: relative;
    width: 120px;
}

.preview-img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #eee;
}

.preview-name {
    font-size: 12px;
    margin-top: 4px;
    text-align: center;
    word-break: break-word;
}

.remove-btn {
    position: absolute;
    top: 5px;
    right: 5px;
    background: red;
    color: #fff;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}
.image-preview {
    width: 120px;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #eee;
    display: none;
}
.spinner-border {
    border: 2px solid transparent;
    border-top: 2px solid #6366f1;
    border-right: 2px solid #22c55e;
    border-radius: 50%;
    animation: spin 0.7s linear infinite;
}

.spinner-border-sm {
    width: 20px;
    height: 20px;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}
/* ========== VISIT REPORT – EMPTY STATE ========== */
.visit-empty-state-row td {
    padding: 40px 20px !important;
    background: transparent !important;
}

.visit-empty-state-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    color: #94A3B8;
}

.visit-empty-state-icon {
    width: 48px;
    height: 48px;
    opacity: 0.5;
}

.visit-empty-state-text {
    font-size: 14px;
    font-weight: 600;
}

/* ========== RESPONSIVE – CREATE CLIENT PAGE ========== */
@media (max-width: 768px) {
    .create-client-section {
        padding: 0 12px 12px;
    }

    .create-client-card {
        padding: 24px 16px;
    }

    .create-form-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .create-whatsapp-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .create-form-actions {
        flex-direction: column-reverse;
    }

    .create-btn-save,
    .create-btn-cancel {
        width: 100%;
        text-align: center;
    }
}

/* ========== RESPONSIVE – CLIENTS PAGE ========== */

/* Tablet landscape & small desktops */
@media (max-width: 1200px) {
    .clients-section {
        padding: 0 20px 20px;
    }

    .clients-filters {
        flex-direction: column;
        align-items: stretch;
        gap: 14px;
    }

    .filters-group {
        flex-wrap: wrap;
        gap: 10px;
    }

    .filter-select {
        flex: 1;
        min-width: 140px;
    }

    .filter-date {
        flex: 1;
        min-width: 160px;
        width: auto;
    }

    .filter-search {
        flex: 1;
        min-width: 200px;
        width: auto;
    }

    .clients-tabs-actions {
        flex-wrap: wrap;
        gap: 16px;
    }

    .actions-group {
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 8px;
    }

    .clients-table {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .clients-table table {
        min-width: 800px;
    }
}

/* Tablet portrait */
@media (max-width: 992px) {
    .clients-tabs-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }

    .tabs-group {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        gap: 6px;
        padding-bottom: 10px;
        scrollbar-width: none;
    }

    .tabs-group::-webkit-scrollbar {
        display: none;
    }

    .tab-btn {
        font-size: 13px;
        padding: 8px 14px 10px;
        white-space: nowrap;
        flex-shrink: 0;
        border-radius: 8px;
        background: #f5f5f5;
    }

    .tab-btn.active {
        background: rgba(141, 49, 118, 0.08);
    }

    .tab-btn.active::after {
        display: none;
    }

    .actions-group {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 8px;
        flex-direction: unset;
    }

    .btn-action-outline {
        justify-content: center;
        padding: 10px 12px;
        font-size: 12px;
    }

    .filters-group {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .filter-select,
    .filter-date,
    .filter-search {
        width: 100%;
        min-width: unset;
    }

    .clients-filters .btn-outline-primary {
        width: 100%;
        text-align: center;
        display: flex;
        justify-content: center;
    }

    .clients-table th,
    .clients-table td {
        padding: 12px 14px;
        font-size: 13px;
    }

    .clients-pagination {
        flex-wrap: wrap;
        gap: 6px;
    }

    .modal-content {
        width: 90%;
        padding: 30px 24px;
    }
}

/* Mobile landscape & small tablets */
@media (max-width: 768px) {
    .clients-section {
        padding: 0 12px 12px;
    }

    .clients-filters {
        gap: 10px;
    }

    .filters-group {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .filter-select,
    .filter-date,
    .filter-search {
        width: 100%;
    }

    .filter-date input,
    .filter-search input {
        width: 100%;
    }

    .actions-group {
        grid-template-columns: repeat(2, 1fr);
    }

    .btn-action-outline {
        font-size: 12px;
        padding: 10px 10px;
        gap: 6px;
    }

    .btn-action-outline svg,
    .btn-action-outline img {
        width: 14px;
        height: 14px;
    }

    .tabs-group {
        gap: 4px;
    }

    .tab-btn {
        font-size: 12px;
        padding: 7px 12px 8px;
    }

    .tab-badge {
        font-size: 10px;
        padding: 1px 6px;
    }

    .clients-table table {
        min-width: 650px;
    }

    .clients-table th,
    .clients-table td {
        padding: 10px 10px;
        font-size: 12px;
    }

    .clients-pagination {
        justify-content: center;
    }

    .page-num,
    .page-nav {
        width: 32px;
        height: 32px;
        font-size: 13px;
    }

    .modal-content {
        width: 95%;
        max-height: 90vh;
        overflow-y: auto;
        padding: 24px 16px;
    }

    .modal-title {
        font-size: 20px;
    }

    .modal-footer {
        flex-direction: column;
    }
}

/* Mobile portrait */
@media (max-width: 480px) {
    .clients-section {
        padding: 0 8px 8px;
    }

    .actions-group {
        grid-template-columns: 1fr;
    }

    .btn-action-outline {
        width: 100%;
    }

    .tab-btn {
        font-size: 11px;
        padding: 6px 10px 7px;
        gap: 4px;
    }

    .tab-badge {
        font-size: 9px;
    }

    .clients-table table {
        min-width: 550px;
    }

    .clients-table th,
    .clients-table td {
        padding: 8px 8px;
        font-size: 11px;
    }

    .status-badge {
        font-size: 10px;
        padding: 3px 8px;
    }

    .btn-options svg {
        width: 16px;
        height: 16px;
    }

    .row-options-dropdown {
        min-width: 150px;
    }

    .row-option-item {
        padding: 10px 14px;
        font-size: 13px;
    }

    .modal-content {
        border-radius: 16px;
    }

    .btn-modal {
        font-size: 15px;
        padding: 14px;
    }
}

/* ========== CLIENT DETAILS VIEW ========== */
.client-details-section {
    padding: 0 24px 24px;
}

.client-details-grid {
    display: grid;
    grid-template-columns: 1fr 1.4fr;
    gap: 20px;
}

/* ========== HEADER ACTIONS: EDIT, CONVERT, DOWNLOAD ========== */
.view-quotation-actions-top {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}

.view-q-btn-edit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #1a1919;
    color: #1a1919;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.view-q-btn-edit:hover {
    background: #f8f9fa;
}

.view-q-btn-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 10px;
    background: #fff;
    border: 1px solid #4B318D;
    color: #4B318D;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.view-q-btn-action svg {
    color: #4B318D;
}

.view-q-btn-action:hover {
    background: rgba(75, 49, 141, 0.05);
}

/* Box shared styles */
.client-box {
    background: rgba(248, 250, 251, 1);
    border-radius: 18px;
    padding: 22px 24px;
    display: flex;
    flex-direction: column;
}

.client-box-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.client-box-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1919;
}

/* Client ID Badge */
.client-id-badge {
    font-size: 11.02px;
    font-weight: 600;
    color: #fff;
    background: rgba(146, 152, 164, 1);
    padding: 9.18px;
    border-radius: 13.96px;
}

/* Status Badge */
.client-status-badge {
    display: inline-block;
    padding: 6px 24px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
}

.client-status-active {
    background: rgba(198, 246, 236, 1);
    color: rgba(0, 151, 118, 1);
    font-size: 15.55px;
    font-weight: 700;
    padding: 5.18px 10.37px;
    border-radius: 6.48px;
}

/* Info Grid (2 columns for personal data) */
.client-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px 32px;
}

/* Info Items */
.client-info-item {
    display: flex;
    flex-direction: column;
    gap: 6px;
    text-align: right;
}

.client-info-label {
    font-size: 12px;
    font-weight: 600;
    color: #aaa;
}

/* Types */
.type-stage .icon-box {
    background-color: var(--bg-stage);
    color: var(--color-stage);
}

.timeline-stage-change {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    font-weight: 700;
}

.timeline-stage-pill {
    padding: 6px 14px;
    border-radius: 6px;
    background-color: var(--border);
    color: var(--text-dark);
}

.timeline-stage-pill.new {
    background-color: var(--color-stage);
    color: white;
}

.stage-change-visual {
    gap: 16px;
}

.stage-change-visual .timeline-stage-pill {
    padding: 0;
    border-radius: 0;
    background: transparent;
    color: #0f172a;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.25;
    white-space: nowrap;
}

.stage-change-visual .timeline-stage-pill.new {
    color: #0f172a;
}

.stage-change-visual .timeline-stage-connector {
    display: inline-flex;
    align-items: center;
    direction: ltr;
}

.stage-change-visual .stage-dot {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 5px solid;
    background-color: #fff;
    display: inline-block;
    flex-shrink: 0;
}

.stage-change-visual .stage-dot.old {
    border-color: #b91011;
}

.stage-change-visual .stage-dot.new {
    border-color: #0e9f7b;
}

.stage-change-visual .stage-line {
    width: 80px;
    height: 2px;
    background-color: #b3b3b3;
    margin: 0 8px;
    position: relative;
}

.stage-change-visual .stage-line-mid-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background-color: #b3b3b3;
    position: absolute;
    top: 50%;
    left: 96%;
    transform: translate(-50%, -50%);
}

.stage-change-visual .stage-line-arrow {
    position: absolute;
    top: 50%;
    left: 1px;
    width: 9px;
    height: 9px;
    border-left: 2px solid #b3b3b3;
    border-bottom: 2px solid #b3b3b3;
    transform: translateY(-50%) rotate(45deg);
}
/* Centered Info Item for Quotation Details */
.quotation-info-centered {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: flex-start;
    justify-content: center;
    flex: 1;
}

.client-info-item-center {
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-align: right;
}

.client-info-item-center .client-info-label {
    font-size: 14px;
    font-weight: 600;
    color: #8E94A3;
}

.client-info-item-center .client-info-value {
    font-size: 24px;
    font-weight: 500;
    color: #1a1919;
}

/* ========== VIEW QUOTATION PRODUCTS ========== */
.view-products-container {
    margin-top: 24px;
}

.view-products-header-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1919;
    margin-bottom: 16px;
    text-align: right;
}

.view-products-table {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.view-products-th {
    display: grid;
    grid-template-columns: 1.5fr 1fr 2.5fr 1fr 1fr 1fr 1fr 1fr;
    gap: 12px;
    padding: 0 24px 8px;
    color: #8E94A3;
    font-size: 14px;
    font-weight: 600;
    text-align: center;
}

.view-products-th>div:first-child {
    text-align: right;
}

.view-product-row {
    display: grid;
    grid-template-columns: 1.5fr 1fr 2.5fr 1fr 1fr 1fr 1fr 1fr;
    gap: 12px;
    align-items: center;
    background: rgba(248, 250, 251, 1);
    border-radius: 12px;
    padding: 10px 16px;
    text-align: center;
}

.view-product-row>.view-product-info {
    text-align: right;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.view-product-name {
    font-size: 15px;
    font-weight: 600;
    color: #1a1919;
}

.view-product-code {
    font-size: 13px;
    font-weight: 600;
    color: #8D3176;
}

.view-product-img-wrapper {
    display: flex;
    justify-content: center;
}

.view-product-image {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    object-fit: cover;
}

.view-product-desc {
    font-size: 14px;
    font-weight: 600;
    line-height: 1.6;
    color: #1a1919;
}

.view-product-val {
    font-size: 15px;
    font-weight: 600;
    color: #1a1919;
}

@media (max-width: 1200px) {
    .view-products-container {
        overflow-x: auto;
    }

    .view-products-table {
        min-width: 900px;
    }
}

/* Contact List */
.client-contact-list {
    display: flex;
    flex-direction: column;
    gap: 28px;
    flex: 1;
}

.client-contact-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
}

/* Box Actions */
.client-box-actions {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: auto;
    padding-top: 32px;
    justify-content: flex-start;
    flex-direction: row-reverse;
}

.client-whatsapp-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 40px;
    background: rgba(0, 151, 118, 1);
    color: #fff;
    border-radius: 6.48px;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.2s ease;
}

.client-data-actions {
    margin-top: 24px;
    padding-top: 0;
    /* justify-content: flex-end; */
}

.client-data-whatsapp {
    border-radius: 8px;
}

.client-whatsapp-btn:hover {
    background: rgba(0, 130, 100, 1);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 151, 118, 0.3);
}

.client-download-report {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    font-size: 15px;
    font-weight: 600;
    color: #666;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 1.5px solid #e0e0e0;
    border-radius: 6.48px;
    background: #fff;
}

.client-download-report:hover {
    border-color: rgba(141, 49, 118, 0.5);
    color: rgba(141, 49, 118, 1);
}

.client-download-report .action-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

/* --- Responsive rules for View Quotation Details --- */
@media (max-width: 992px) {
    .client-details-grid {
        grid-template-columns: 1fr;
    }

    .client-info-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .client-contact-row {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .client-details-section {
        padding: 0 16px 24px;
    }

    .client-box {
        padding: 24px 20px;
    }

    .client-box-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .view-quotation-actions-top {
        flex-direction: column;
        align-items: stretch;
    }

    .view-q-btn-edit,
    .view-q-btn-action {
        width: 100%;
    }

    .client-data-actions {
        justify-content: center;
        width: 100%;
    }

    .client-whatsapp-btn {
        width: 100%;
        justify-content: center;
    }

    .client-box-actions {
        justify-content: center;
        width: 100%;
        gap: 12px;
        flex-direction: column-reverse;
    }

    .client-download-report {
        width: 100%;
        justify-content: center;
    }
}

/* ========== ACTIVITY TIMELINE & MODAL ========== */
.feed-wrapper,
.action-modal-overlay,
.card-recent-activities {
    --bg-app: #f4f7fb;
    --surface: #ffffff;
    --text-dark: #1e293b;
    --text-gray: #64748b;
    --border: #e2e8f0;

    /* Activity Theme Colors */
    --color-call: #10b981;
    --bg-call: #d1fae5;

    --color-invoice: #3b82f6;
    --bg-invoice: #dbeafe;

    --color-note: #f59e0b;
    --bg-note: #fef3c7;

    --color-stage: #8B3275;
    /* Brand Purple */
    --bg-stage: #fdf4fa;

    --color-visit: #8b5cf6;
    --bg-visit: #ede9fe;

    --color-meeting: #f43f5e;
    /* Rose */
    --bg-meeting: #ffe4e6;
}

/* --- Expanded Width --- */
.feed-wrapper {
    width: 100%;
    margin-top: 24px;
    background-color: var(--surface);
    border-radius: 20px;
    padding: 30px 40px;
    /* box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05); */
}

/* --- Header & Buttons --- */
.feed-header {
    font-size: 1.3rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid var(--border);
    padding-bottom: 15px;
}

.header-actions {
    display: flex;
    gap: 12px;
}

.feed-wrapper .btn,
.action-modal-overlay .btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    font-family: inherit;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.feed-wrapper .btn-primary,
.action-modal-overlay .btn-primary {
    background-color: var(--color-stage);
    color: #ffffff;
}

.feed-wrapper .btn-primary:hover,
.action-modal-overlay .btn-primary:hover {
    background-color: #70265d;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(139, 50, 117, 0.2);
}

.feed-wrapper .btn-outline {
    color: var(--color-invoice);
    background-color: var(--bg-invoice);
}

.feed-wrapper .btn-outline-stage {
    color: var(--color-stage);
    background-color: #fff;
    border: 1.5px solid var(--color-stage);
    font-weight: 500;
    font-size: 16px;
    padding: 8px 24px;
}

.feed-wrapper .btn-outline-stage:hover {
    background-color: rgba(139, 50, 117, 0.04);
}

/* --- Feed Container --- */
.activity-list {
    position: relative;
}

.activity-list::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    right: 23px;
    width: 2px;
    background-color: var(--border);
    z-index: 0;
}

/* --- Individual Activity Item --- */
.activity-item {
    display: flex;
    gap: 24px;
    margin-bottom: 24px;
    position: relative;
    z-index: 1;
}

.activity-item:last-child {
    margin-bottom: 0;
}

.icon-box {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-shrink: 0;
    border: 4px solid var(--surface);
}

.icon-box svg {
    width: 22px;
    height: 22px;
    stroke-width: 2;
}

/* --- Wide Card Content Box --- */
.activity-content-box {
    flex-grow: 1;
    background-color: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px 24px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 30px;
    transition: all 0.2s;
}

.activity-content-box:hover {
    border-color: #cbd5e1;
    background-color: #f8fafc;
}

.activity-content-box::before {
    content: '';
    position: absolute;
    top: 18px;
    right: -6px;
    width: 10px;
    height: 10px;
    background-color: inherit;
    border-top: 1px solid var(--border);
    border-right: 1px solid var(--border);
    transform: rotate(45deg);
}

/* Right Side: Main Details */
.content-details {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.lead-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-gray);
    background-color: #f1f5f9;
    padding: 4px 10px;
    border-radius: 6px;
    width: max-content;
    margin-bottom: 4px;
    border: 1px solid var(--border);
}

.lead-badge svg {
    width: 14px;
    height: 14px;
    color: var(--color-stage);
}

.activity-title {
    font-weight: 800;
    font-size: 1.1rem;
    color: var(--text-dark);
    margin-bottom: 4px;
}

/* Images Gallery */
.img-gallery {
    display: flex;
    gap: 12px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.img-gallery img {
    width: 80px;
    height: 80px;
    border-radius: 8px;
    object-fit: cover;
    border: 1px solid var(--border);
    cursor: pointer;
    transition: transform 0.2s;
}

.img-gallery img:hover {
    transform: scale(1.05);
    border-color: var(--color-stage);
}

/* NEW: ATTENDANCE ACTION BUTTONS */
.quick-actions {
    display: flex;
    gap: 12px;
    margin-top: 12px;
}

.btn-attend {
    background-color: #00c48c;
    /* Exact Green from image */
    color: white;
    border: none;
    padding: 8px 32px;
    border-radius: 8px;
    font-weight: 700;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
}


.btn-attend-span {
    background-color: #8B3275;
    color: white;
    border: none;
    padding: 8px 32px;
    border-radius: 8px;
    font-weight: 700;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
}

.btn-absent {
    background-color: #c91028;
    /* Exact Red from image */
    color: white;
    border: none;
    padding: 8px 32px;
    border-radius: 8px;
    font-weight: 700;
    font-family: inherit;
    font-size: 0.95rem;
    cursor: pointer;
    transition: opacity 0.2s, transform 0.1s;
}

.btn-attend:hover,
.btn-absent:hover {
    opacity: 0.9;
    transform: scale(0.98);
}

/* Left Side: Metadata (User & Time) */
.content-metadata {
    flex-shrink: 0;
    width: 220px;
    border-right: 1px dashed var(--border);
    padding-right: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.activity-time {
    font-size: 0.85rem;
    color: var(--text-gray);
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: var(--text-dark);
    font-weight: 700;
}

.timeline-user-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background-color: var(--border);
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-dark);
    font-size: 0.8rem;
}

/* Types */
.type-stage .icon-box {
    background-color: var(--bg-stage);
    color: var(--color-stage);
}

.timeline-stage-change {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    font-weight: 700;
}

.timeline-stage-pill {
    padding: 6px 14px;
    border-radius: 6px;
    background-color: var(--border);
    color: var(--text-dark);
}
.dashboard .activity-list{
    overflow-y: auto;
    flex: 1;
    max-height: 600px;
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
        padding-right: 8px;
    padding-bottom : 80px;
}
.type-visit .icon-box {
    background-color: var(--bg-visit);
    color: var(--color-visit);
}

.type-meeting .icon-box {
    background-color: var(--bg-meeting);
    color: var(--color-meeting);
}

.type-note .icon-box {
    background-color: var(--bg-note);
    color: var(--color-note);
}

.type-invoice .icon-box {
    background-color: var(--bg-invoice);
    color: var(--color-invoice);
}

.type-call .icon-box {
    background-color: var(--bg-call);
    color: var(--color-call);
}

/* Specific Timeline Item Styles */
.timeline-note-content {
    background-color: #FDF9E9;
    padding: 16px 20px;
    border-radius: 8px;
    font-size: 0.95rem;
    color: var(--text-dark);
    line-height: 1.6;
    margin-top: 4px;
}

.btn-invoice-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border: 1px solid var(--color-stage);
    color: var(--color-stage);
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 700;
    text-decoration: none;
    margin-top: 8px;
    width: max-content;
    transition: all 0.2s;
    background: transparent;
}

.btn-invoice-link:hover {
    background-color: var(--bg-stage);
}

.timeline-call-info {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: var(--text-dark);
    font-weight: 600;
    margin-top: 4px;
}

.call-status-pill {
    background-color: var(--bg-call);
    color: var(--color-call);
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 700;
}

/* =========================================
 DASHBOARD STYLES (FIXED CROSS-PLATFORM)
========================================= */

.dashboard-highlight-section {
    margin-bottom: 16px;
    padding: 0 24px;
}

.dashboard-highlight-productivity-wrapper {
    width: 380px;
    max-width: 100%;
    z-index: 1;
    flex-shrink: 0;
    display: flex;
    justify-content: center;
}

.productivity-charts-flex {
    display: flex;
    align-items: center;
    gap: 15px;
    margin: 12px 0;
    flex-direction: row;
    flex-wrap: nowrap;
    justify-content: center;
}

.productivity-chart-container {
    /* flex: 1; */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.dashboard-highlight-banner {
    background: linear-gradient(90deg, rgba(18, 13, 45, 0.9) 0%, rgba(36, 16, 77, 0.85) 100%),url('/crm-smartup-frontend/assets/images/chess.jpg') center center / cover no-repeat;
    border-radius: 16px;
    min-height: 155px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    padding: 10px 14px;
    overflow: hidden;
    position: relative;
}

.dashboard-highlight-banner::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 72% 40%, rgba(255, 255, 255, 0.16), transparent 45%);
    pointer-events: none;
}

.dashboard-highlight-content {
    color: #fff;
    text-align: right;
    z-index: 1;
    max-width: 40%;
    margin-right: 40px;
    margin-left: auto;
}

.dashboard-highlight-content h2 {
    margin: 0 0 8px 0;
    font-size: 26px;
    line-height: 1.2;
    font-weight: 800;
}

.dashboard-highlight-content p {
    margin: 0;
    font-size: 15px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
    font-weight: 500;
}

.dashboard-highlight-dots {
    margin-top: 12px;
    display: flex;
    justify-content: flex-start;
    gap: 6px;
}

.dashboard-highlight-dot {
    width: 6px;
    height: 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dashboard-highlight-dot.active {
    width: 14px;
    background: #fff;
}

/* Carousel Styles */
.dashboard-highlight-carousel {
    position: relative;
    min-height: 110px;
}

.dashboard-highlight-slide {
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    opacity: 0;
    visibility: hidden;
    transition: all 0.6s ease;
    transform: translateY(10px);
}

.dashboard-highlight-slide.active {
    position: relative;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dashboard-highlight-productivity-wrapper .card-productivity {
    margin: 0;
    min-height: 130px;
    padding: 10px 12px;
    background: transparent;
    width: fit-content;
}

.card-productivity .circular-progress-donut {
    width: 105px !important;
    height: 105px !important;
    margin-bottom: 6px !important;
}

.card-productivity .progress-value {
    font-size: 20px !important;
}

.card-productivity .chart-label {
    font-size: 11px !important;
}

.card-productivity .card-title-main {
    font-size: 14px !important;
}

.card-productivity .card-subtitle-main {
    font-size: 10px !important;
}

/* ===== Responsive ===== */
@media (max-width: 1200px) {
    .dashboard-highlight-content h2 {
        font-size: 28px;
    }

    .dashboard-highlight-content p {
        font-size: 18px;
    }
}

@media (max-width: 992px) {
    .dashboard-highlight-banner {
        flex-direction: column;
        align-items: stretch;
    }

    .dashboard-highlight-content {
        max-width: 100%;
        margin: 0;
    }

    .dashboard-highlight-productivity-wrapper {
        width: 100%;
        max-width: 380px;
        align-self: center;
        margin-top: 15px;
    }

    .productivity-charts-flex {
        justify-content: center;
    }
}
/* =========================================
   SAR IMAGE WITH INPUT STYLES
========================================= */
.input-currency {
    position: relative;
    width: 100%;
}

.input-currency input {
    width: 100%;
    padding-left: 10px; /* مساحة للصورة */
    border: 1px solid #ccc;
    border-radius: 8px;
    outline: none;

}

.input-currency .currency {
    position: absolute;
    top: 50%;
    left: 10px; /* عشان عربي */
    transform: translateY(-50%);
    pointer-events: none;
}

.input-currency .currency img {
    width: 18px;
    height: 18px;
    opacity: 0.7;
}
/* =========================================
   MODAL (POPUP) STYLES
========================================= */
.action-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.action-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.action-modal-box {
    background-color: var(--surface);
    width: 100%;
    max-width: 600px;
    border-radius: 24px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s ease;
    max-height: 80vh;
    overflow-y: auto;
}

.action-modal-overlay.active .action-modal-box {
    transform: translateY(0) scale(1);
}

.action-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.action-modal-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-dark);
}

.action-close-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- Action Form Controls --- */
.action-form-group {
    margin-bottom: 24px;
}

.action-form-label {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.search-input-wrapper {
    position: relative;
    width: 100%;
}

.search-icon-circle {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    background-color: #A03D82;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.search-icon-circle svg {
    width: 14px;
    height: 14px;
    stroke-width: 2.5;
}

.action-form-control {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid rgba(226, 232, 240, 1);
    border-radius: 12px;
    font-family: inherit;
    font-size: 0.95rem;
    color: var(--text-dark);
    background-color: rgba(249, 250, 251, 1);
    transition: all 0.2s;
    appearance: none;
    resize: vertical;
}

.action-form-group .custom-select-trigger {
    border: 1px solid rgba(226, 232, 240, 1) !important;
    background-color: rgba(249, 250, 251, 1) !important;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.search-input-wrapper .action-form-control {
    padding-right: 50px;
}

.action-form-control::placeholder {
    color: #94a3b8;
}

.action-form-control:focus {
    outline: none;
    border-color: var(--color-stage);
}

.action-modal-footer {
    margin-top: 30px;
    gap: 16px;
    display: flex;
}

.action-modal-footer .btn-outline-action {
    flex: 1;
    padding: 14px;
    border-radius: 12px;
    font-size: 1rem;
    color: #1a1a1a;
    border: 1px solid #1a1a1a;
    background: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-modal-footer .btn-outline-action:hover {
    background: #f8f9fa;
}

.action-modal-footer .btn-primary-action {
    flex: 1;
    padding: 14px;
    border-radius: 12px;
    font-size: 1rem;
    background: #8D3176;
    color: #fff;
    border: none;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.action-modal-footer .btn-primary-action:hover {
    background: #70265d;
}

.action-upload-group {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 32px;
    flex-direction: column;
}

.upload-text-content {
    flex: 1;
}

.upload-hint {
    font-size: 0.85rem;
    color: #94a3b8;
    line-height: 1.6;
    margin: 0;
}

.upload-btn-container {
    flex-shrink: 0;
    padding-top: 24px;
}

.action-btn-upload {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border: 1.5px solid var(--color-stage);
    border-radius: 12px;
    color: var(--color-stage);
    font-weight: 700;
    font-size: 0.95rem;
    cursor: pointer;
    background: #fff;
    transition: all 0.2s;
}

.action-btn-upload:hover {
    background: var(--bg-stage);
}

.action-modal-footer {
    display: flex;
    gap: 16px;
    margin-top: 32px;
}

.action-btn-save {
    flex: 1;
    background-color: var(--color-stage);
    color: #fff;
    border: none;
    padding: 14px;
    border-radius: 16px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: opacity 0.2s;
}

.action-btn-save:hover {
    opacity: 0.9;
}

.action-btn-cancel {
    width: 120px;
    background-color: #fff;
    color: #1a1a1a;
    border: 1px solid #1a1a1a;
    padding: 14px;
    border-radius: 16px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}

.action-btn-cancel:hover {
    background-color: #f1f5f9;
}

@media (max-width: 850px) {
    .activity-content-box {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .content-metadata {
        width: 100%;
        border-right: none;
        border-top: 1px dashed var(--border);
        padding-right: 0;
        padding-top: 16px;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }

    .action-upload-group {
        flex-direction: column;
        align-items: stretch;
    }

    .upload-btn-container {
        padding-top: 10px;
        align-self: flex-start;
    }
}

@media (max-width: 768px) {
    .feed-wrapper {
        padding: 24px 16px;
    }

    .feed-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .feed-header .header-actions {
        width: 100%;
        flex-direction: column;
    }

    .feed-header .header-actions .btn {
        width: 100%;
        justify-content: center;
    }

    .activity-item {
        gap: 12px;
    }

    .icon-box {
        width: 40px;
        height: 40px;
    }

    .icon-box svg {
        width: 18px;
        height: 18px;
    }

    .activity-list::before {
        right: 19px;
    }
}

@media (max-width: 480px) {
    .content-metadata {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .activity-content-box {
        padding: 16px;
    }

    .quick-actions {
        flex-direction: column;
        width: 100%;
    }

    .quick-actions .btn-attend,
    .quick-actions .btn-absent {
        width: 100%;
    }
}

/* =========================================
   GENERIC SMART UP MODAL (FOR ALERTS/SUCCESS)
========================================= */
.smart-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(4px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.smart-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.smart-modal-box {
    background: #FFFFFF;
    width: 90%;
    max-width: 400px;
    border-radius: 20px;
    padding: 30px;
    text-align: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.smart-modal-overlay.active .smart-modal-box {
    transform: translateY(0);
}

.smart-modal-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.smart-modal-icon.success {
    background: #E8F7F0;
    color: #10B981;
}

.smart-modal-icon.warning {
    background: #FFF9E6;
    color: #FBB000;
}

.smart-modal-title {
    font-size: 18px;
    font-weight: 700;
    color: #1A1919;
    margin-bottom: 8px;
}

.smart-modal-text {
    font-size: 14px;
    color: #64748B;
    line-height: 1.6;
    margin-bottom: 24px;
}

/* Bulk delete preview list inside smart modal */
.bulk-delete-preview-list {
    list-style: none;
    padding: 0;
    margin: 0 0 20px;
    max-height: 180px;
    overflow-y: auto;
    text-align: right;
}

.bulk-delete-preview-list li {
    background: #FEF2F2;
    /* very light red */
    color: #7F1D1D;
    padding: 8px 10px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 6px;
}

.smart-modal-footer {
    display: flex;
    gap: 12px;
}

.smart-modal-btn {
    flex: 1;
    padding: 12px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.smart-modal-btn-primary {
    background: #8D3176;
    color: #FFFFFF;
}

.smart-modal-btn-danger {
    background: #B20015;
    color: #FFFFFF;
}

.smart-modal-btn-outline {
    background: #F8FAFB;
    color: #64748B;
    border: 1px solid #E2E8F0;
}

.smart-modal-btn:hover {
    opacity: 0.9;
}

/* Product Create Form Custom Styles */
.required-asterisk {
    color: #DC2626;
    margin-left: 4px;
}

.price-input-wrapper {
    position: relative;
}

.price-input-wrapper .create-form-input {
    padding-left: 45px;
}

.price-suffix {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 13px;
    color: #666;
    font-weight: 500;
}

.upload-form-row {
    margin-top: 10px;
}

.upload-form-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
}

.upload-form-label {
    margin-bottom: 0;
}

.upload-form-hint {
    font-size: 12px;
    color: #A2A2A2;
}

.btn-upload-product {
    background-color: #4A3E72;
    color: #FFFFFF;
    border-radius: 12px;
    padding: 10px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 5px;
}

.create-form-actions-product {
    margin-top: 30px;
    display: flex;
    justify-content: flex-start;
    flex-direction: row-reverse;
}


.btn-cancel-product {
    width: 140px;
    height: 48px;
    border-color: #1A1919;
    color: #1A1919;
    margin-left: 12px;
}

/* =========================================
   PRODUCT VIEW DETAILS STYLES
========================================= */

/* --- Details Card --- */
.product-details-section {
    padding: 0 24px 24px;
}

.product-details-card {
    background-color: transparent;
    border: none;
    border-radius: 0;
    padding: 24px;
    box-shadow: none;
}

/* Top Area: Image + Core Info */
.product-overview {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #E5E7EB;
    align-items: center;
}

.product-image-large {
    width: 150px;
    height: 150px;
    border-radius: 12px;
    border: 1px solid #E5E7EB;
    object-fit: cover;
    background-color: #F3F4F6;
    padding: 5px;
}

.product-core-info {
    flex-grow: 1;
}

.product-core-title {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 12px;
    color: #1F2937;
}

.product-tags-row {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.product-badge {
    background-color: #F3F4F6;
    color: #1F2937;
    padding: 6px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 700;
    border: 1px solid #E5E7EB;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.product-price-tag {
    color: #8B3275;
    background-color: #FDF4FA;
    border-color: #FDF4FA;
}

/* Data Grid */
.product-data-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 40px;
}

.product-data-group {
    display: flex;
    flex-direction: column;
}

.product-data-label {
    font-size: 0.9rem;
    color: #6B7280;
    font-weight: 700;
    margin-bottom: 8px;
}

.product-data-value {
    font-size: 1rem;
    color: #1F2937;
    font-weight: 600;
    background-color: #F9FAFB;
    padding: 14px 16px;
    border-radius: 8px;
    border: 1px solid #F3F4F6;
    line-height: 1.6;
    min-height: 52px;
}

/* Description takes full width */
.product-full-width {
    grid-column: span 2;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .product-overview {
        flex-direction: column;
        text-align: center;
    }

    .product-tags-row {
        justify-content: center;
        flex-wrap: wrap;
    }

    .product-data-grid {
        grid-template-columns: 1fr;
        /* Stacks to 1 column on mobile */
    }

    .product-full-width {
        grid-column: span 1;
    }
}

/* Delete Selected Button */
.delete-selected-container {
    display: none;
    /* Hidden by default, shown when rows are selected */
    justify-content: flex-start;
    margin-top: 24px;
}

.btn-delete-selected {
    background-color: #B91C1C;
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-direction: row-reverse;
}

.btn-delete-selected:hover {
    background-color: #991B1B;
}

/* ========== TEAMS MODULE ========== */
.header-greeting-counter {
    font-size: 16px;
    color: #A2A2A2;
    font-weight: normal;
    margin-right: 8px;
}

.user-count-link {
    color: #BA4E8B;
    text-decoration: underline;
}

.delete-selected-wrapper {
    display: flex;
    justify-content: flex-end;
    margin-top: 20px;
}

.btn-delete-selected-red {
    background-color: #B00020;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-weight: 600;
}

.create-btn-team-save {
    background-color: #8E3372;
    color: white;
    border: none;
    border-radius: 12px;
    padding: 10px 40px;
    font-weight: 600;
}

.create-btn-team-cancel {
    background-color: transparent;
    color: #1A1919;
    border: 1px solid #1A1919;
    border-radius: 12px;
    padding: 10px 40px;
    font-weight: 600;
}

/* ========== INVOICE STATUS BADGES ========== */
.status-paid {
    background-color: #D1FAE5;
    color: #059669;
    padding: 4px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.8rem;
}

.status-partial-paid {
    background-color: #FEF3C7;
    color: #D97706;
    padding: 4px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 0.8rem;
}

/* ========== INVOICE VIEW PAGE ========== */
.invoice-view-header {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.invoice-view-header h1 {
    font-size: 24px;
    font-weight: 700;
    color: #1a1919;
    direction: ltr;
    text-align: right;
}

.invoice-view-header .invoice-date {
    font-size: 13px;
    color: #999;
    font-weight: 400;
}

.invoice-download-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    color: #666;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 1.5px solid #e0e0e0;
    border-radius: 10px;
    background: #fff;
    margin-bottom: 20px;
}

.invoice-download-btn:hover {
    background: #f8f9fa;
    border-color: #ccc;
}

.invoice-download-btn img {
    width: 18px;
    height: 18px;
}

/* Invoice Info Grid - flex layout for invoice details */
.invoice-info-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.invoice-info-row {
    display: flex;
    gap: 32px;
}

.invoice-info-row .client-info-item {
    flex: 1;
}

/* Invoice QR Code */
.invoice-qr-code {
    width: 120px;
    height: 120px;
    background: #f0f0f0;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.invoice-qr-code img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Invoice Status in View */
.invoice-status-badge-large {
    display: inline-block;
    padding: 8px 24px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    white-space: nowrap;
}

.invoice-status-paid {
    background: rgba(198, 246, 236, 1);
    color: rgba(0, 151, 118, 1);
}

.invoice-status-partial {
    background: #FEF3C7;
    color: #D97706;
}

/* ========== INVOICE PRODUCTS TABLE ========== */
.invoice-products-section {
    padding: 0 24px 24px;
}

.invoice-products-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1919;
    margin-bottom: 16px;
    text-align: right;
}

.invoice-products-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 10px;
}

.invoice-products-table thead th {
    font-size: 13px;
    font-weight: 600;
    color: #8E94A3;
    padding: 12px 16px;
    text-align: center;
    border-bottom: 1px solid #f0f0f0;
}

.invoice-products-table thead th:first-child {
    text-align: right;
}

.invoice-products-table tbody tr {
    background: rgba(248, 250, 251, 1);
    border-radius: 20px;
}

.invoice-products-table tbody tr td:first-child {
    border-radius: 0 20px 20px 0;
}

.invoice-products-table tbody tr td:last-child {
    border-radius: 20px 0 0 20px;
}

.invoice-products-table tbody td {
    font-size: 15px;
    font-weight: 600;
    color: #1a1919;
    padding: 14px 16px;
    text-align: center;
}

.invoice-products-table tbody td:first-child {
    text-align: right;
}

.invoice-totals {
    display: flex;
    flex-direction: column;
    margin-top: 16px;
    margin-right: auto;
    max-width: 450px;
}

.invoice-total-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 0;
}

.invoice-total-row:first-child {
    border-bottom: 1px solid #f0f0f0;
}

.invoice-total-row .label {
    font-size: 16px;
    font-weight: 700;
    color: #1a1919;
}

.invoice-total-row .value {
    font-size: 16px;
    font-weight: 700;
    color: #1a1919;
    display: flex;
    align-items: center;
    gap: 4px;
}

.invoice-total-row .value.total-purple {
    color: #8D3176;
}

.invoice-total-row .value .currency {
    font-size: 14px;
    font-weight: 600;
    color: #8D3176;
}

/* ========== PAYMENT LOG SECTION ========== */
.payment-log-section {
    padding: 0 24px 24px;
}

.payment-log-header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin-bottom: 16px;
}

.payment-log-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a1919;
}

.payment-log-count {
    font-size: 13px;
    font-weight: 500;
    color: #999;
}

/* Payment log content - side by side layout */
.payment-log-content {
    display: flex;
    gap: 20px;
    align-items: stretch;
}

/* Dark remaining amount card */
.payment-remaining-box {
    background: #1E1835;
    border-radius: 16px;
    padding: 24px 20px;
    display: flex;
    flex-direction: column;
    min-width: 240px;
    max-width: 260px;
    color: #fff;
    gap: 16px;
}

.payment-remaining-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
    text-align: center;
    flex: 1;
}

.payment-remaining-info .remaining-date {
    font-size: 13px;
    font-weight: 500;
    color: #D4A843;
    display: flex;
    align-items: center;
    gap: 6px;
}

.payment-remaining-info .remaining-date svg {
    stroke: #D4A843;
}

.payment-remaining-info .remaining-label {
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.85);
    margin-top: 16px;
}

.payment-remaining-info .remaining-amount {
    font-size: 32px;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.5px;
}

.payment-remaining-info .remaining-currency {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.6);
}

.btn-add-payment {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: #8D3176;
    color: #fff;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: inherit;
    margin-top: auto;
    justify-content: center;
    width: 100%;
}

.btn-add-payment:hover {
    background: #7a2a66;
}

.btn-add-payment img {
    width: 18px;
    height: 18px;
    filter: brightness(0) invert(1);
}

/* Payment table section */
.payment-table-wrapper {
    flex: 1;
}

.payment-log-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0 8px;
}

.payment-log-table thead th {
    font-size: 13px;
    font-weight: 600;
    color: #8E94A3;
    padding: 12px 16px;
    text-align: center;
    border-bottom: 1px solid #f0f0f0;
}

.payment-log-table thead th:first-child {
    text-align: right;
}

.payment-log-table tbody tr {
    background: rgba(248, 250, 251, 1);
    border-radius: 20px;
}

.payment-log-table tbody tr td:first-child {
    border-radius: 0 20px 20px 0;
}

.payment-log-table tbody tr td:last-child {
    border-radius: 20px 0 0 20px;
}

.payment-log-table tbody td {
    font-size: 14px;
    font-weight: 500;
    color: #1a1919;
    padding: 14px 16px;
    text-align: center;
}

.payment-log-table tbody td:first-child {
    text-align: right;
}

.btn-delete-payment {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    background: none;
    color: #B20015;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-family: inherit;
}

.btn-delete-payment:hover {
    opacity: 0.7;
}

.btn-delete-payment svg,
.btn-delete-payment img {
    width: 14px;
    height: 14px;
    filter: brightness(0) saturate(100%) invert(10%) sepia(95%) saturate(5000%) hue-rotate(350deg) brightness(80%) contrast(110%);
}

/* Invoice view separator */
.invoice-section-divider {
    height: 1px;
    background: #f0f0f0;
    margin: 0 24px 24px;
}

/* Sidebar logo link */
.sidebar-logo a {
    display: block;
}

/* Header count text */
.header-count {
    font-size: 16px;
    color: #A2A2A2;
    font-weight: normal;
    margin-right: 8px;
}

/* Invoice download button wrapper */
.invoice-download-wrapper {
    padding: 0 24px;
    text-align: left;
}

/* QR code + status row */
.invoice-qr-status-row {
    /* margin-top: auto; */
    padding-top: 16px;
    display: flex;
    flex-direction: row-reverse;
    align-items: flex-end;
    justify-content: space-between;
}

.invoice-qr-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Bold info value */
.client-info-value-bold {
    font-weight: 700;
}

/* WhatsApp icon sizing */
.whatsapp-icon {
    width: 20px;
    height: 20px;
}

/* Currency unit styling */
.currency-unit {
    font-size: 12px;
    color: #999;
}

/* Payment delete buttons container */
.payment-delete-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    justify-content: flex-end;
}

/* Payment add wrapper */
.payment-add-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* ========== PROJECTS PAGES ========== */

/* Back link */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 600;
    color: #8D3176;
    text-decoration: none;
    margin-bottom: 4px;
    transition: opacity 0.2s;
}

.back-link:hover {
    opacity: 0.7;
}

.back-link svg {
    width: 16px;
    height: 16px;
}

/* Projects Tabs */
.projects-tabs {
    display: flex;
    align-items: center;
    gap: 24px;
    border-bottom: 2px solid #E5E5E5;
    justify-content: flex-end;
    width: fit-content;
    flex-direction: row-reverse;
}

.projects-tab {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 4px 12px;
    font-size: 14px;
    font-weight: 600;
    color: #999;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    background: none;
}

.projects-tab:hover {
    color: #555;
}

.projects-tab.active {
    color: #1a1919;
    border-bottom-color: #8D3176;
}

.projects-tab .tab-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 6px;
    border-radius: 6px;
    background: #F0F0F0;
    font-size: 12px;
    font-weight: 700;
    color: #666;
}

.projects-tab.active .tab-count {
    background: rgba(141, 49, 118, 0.1);
    color: #8D3176;
}

/* Avatar Group */
.avatar-group {
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: flex-end;
}

.avatar-group img {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 2px solid #fff;
    margin-right: -10px;
    object-fit: cover;
}

.avatar-group img:first-child {
    margin-right: 0;
}

.avatar-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #8D3176;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    border: 2px solid #fff;
    margin-right: -10px;
}

/* Project Name with edit icon */
.project-name-cell {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: #1a1919;
}

.project-name-cell .edit-icon {
    width: 16px;
    height: 16px;
    color: #999;
    cursor: pointer;
    transition: color 0.2s;
    flex-shrink: 0;
}

.project-name-cell .edit-icon:hover {
    color: #8D3176;
}

/* Add Action Button in table */
.btn-add-action-cell {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 20px;
    background: #E8E8E8;
    color: #555;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-add-action-cell:hover {
    background: #DADADA;
}

/* ========== KANBAN BOARD ========== */
.kanban-board {
    display: flex;
    overflow-x: auto;
    gap: 16px;
    align-items: start;
    padding-bottom: 30px; /* Extra padding for scrollbar */
}

.kanban-column {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-height: 200px;
    min-width: 380px;
    flex: 0 0 auto;
}

.kanban-column-header {
    background: #F8F9FA;
    border-radius: 16px;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.kanban-column-body {
    background: #F8F9FA;
    border-radius: 16px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.kanban-column-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a1919;
}

/* Task Card */
.task-card {
    background: #fff;
    border-radius: 12px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    transition: box-shadow 0.2s ease;
    position: relative;
}

.task-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.task-card-indicator {
    position: absolute;
    top: -2.5px;
    right: 16px;
    width: 32px;
    height: 5px;
    border-radius: 2px;
}

.task-card-indicator.green {
    background: #009776;
}

.task-card-indicator.orange {
    background: #E0823D;
}

.task-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-direction: row-reverse;
}

.task-card-date {
    font-size: 12px;
    color: #999;
    font-weight: 500;
}

.task-card-edit {
    width: 20px;
    height: 20px;
    cursor: pointer;
    transition: opacity 0.2s;
    opacity: 0.7;
}

.task-card-edit:hover {
    opacity: 1;
}

.task-card-body {
    display: flex;
    flex-direction: column;
    gap: 11px;

}

.task-card-name {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #1a1919;
    flex-direction: row-reverse;
    justify-content: flex-end;
}

.task-card-name .check-icon {
    width: 18px;
    height: 18px;
    color: #009776;
    flex-shrink: 0;
}

.task-card-project {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: #999;
    font-weight: 500;
    justify-content: flex-end;
    flex-direction: row-reverse;
}

.task-card-project .folder-icon {
    width: 14px;
    height: 14px;
    color: #8D3176;
    flex-shrink: 0;
}

.task-card-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

.task-card-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
}

.clients-kanban-board {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 24px;
    margin-top: 20px;
}
#globalScroll {
    position: fixed;
    bottom: 0;

    right: 90px;              /* عرض السايدبار */
    width: calc(100% - 90px); /* باقي الشاشة */

    overflow-x: auto;
    height: 14px;
    z-index: 9999;
    background: #fff;
    will-change: transform;
    transform: translateZ(0);
    -webkit-overflow-scrolling: touch;

}

#globalScroll div {
    height: 1px;
}
.clients-kanban-board::-webkit-scrollbar {
    display: none;
}

.clients-kanban-board .kanban-column {
    min-width: 380px;
    flex: 0 0 auto;
}

.client-kanban-card {
    background: #fff;
    border-radius: 12px;
    padding: 10px 10px 9px;
    display: flex;
    flex-direction: column;
    gap: 5px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
    position: relative;
    border: 1px solid #f0f0f0;
    align-items: stretch;
}

.client-kanban-card .card-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    width: 100%;
}

.client-kanban-card .card-name {
    font-size: 16px;
    font-weight: 800;
    color: #1a1919;
    margin-top: 2px;
    line-height: 1.2;
    text-align: right;
}

.client-kanban-card .card-id {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 62px;
    padding: 6px 9px;
    border-radius: 12px;
    background: #8f98a8;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
}

.card-importance-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 4px 8px;
    border-radius: 9px;
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.card-importance-badge.importance-low ,  .card-importance-badge.importance-unknown {
    background: #f8e1e4;
    color: #c21e36;
}

.card-importance-badge.importance-medium {
    background: #fff0d5;
    color: #c98500;
}

.card-importance-badge.importance-high{
    background: #e3f4ea;
    color: #1f8f55;
}

.client-kanban-card .card-date {
    font-size: 12px;
    color: #1a1919;
    font-weight: 500;
    text-align: right;
    line-height: 1.15;
}

.client-kanban-card .card-bottom-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 6px;
    flex-direction: row-reverse;
}
/* Calendar Event Detail Popup */
.cal-event-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.34);
    z-index: 1100;
    align-items: center;
    justify-content: center;
    padding: 14px;
}

.cal-event-overlay.active {
    display: flex;
}

.cal-event-popup {
    background: #ffffff;
    border-radius: 20px;
    width: 100%;
    max-width: min(760px, 94vw);
    max-height: calc(100vh - 56px);
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.18);
    direction: rtl;
}

.cal-event-popup-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 18px 20px 10px;
    gap: 12px;
}

.cal-event-popup-title-area {
    text-align: right;
}

.cal-event-popup-title {
    font-size: clamp(1.05rem, 1.4vw, 1.35rem);
    font-weight: 800;
    color: #101010;
    margin: 0 0 8px;
    line-height: 1.3;
}

.cal-event-popup-date {
    font-size: clamp(0.82rem, 1vw, 0.95rem);
    color: #171717;
    margin: 0;
    line-height: 1.35;
}

.cal-event-popup-actions {
    display: flex;
    gap: 10px;
    align-items: center;
    padding-top: 6px;
    flex-shrink: 0;
    flex-direction: row-reverse;
}

.cal-event-action-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: #171717;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: background 0.15s, color 0.15s;
}

.cal-event-action-btn:hover {
    background: #f3f4f6;
    color: #101010;
}

.cal-event-delete-btn {
    color: #DC2626;
}

.cal-event-delete-btn:hover {
    color: #B91C1C;
    background: #FEE2E2;
}

.cal-event-popup-body {
    padding: 0 20px 18px;
}

.cal-event-content-card {
    background: #F4F4F5;
    border-radius: 16px;
    padding: 16px 14px 14px;
}

.cal-event-detail-row {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    padding: 0;
    margin-bottom: 14px;
    font-size: clamp(0.86rem, 0.95vw, 1rem);
    color: #2a2a2a;
    line-height: 1.35;
}

.cal-event-detail-row svg {
    width: 18px;
    height: 18px;
    stroke: #a03d82;
    flex-shrink: 0;
}

.cal-event-desc-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 0;
    margin-top: 4px;
}

.cal-event-desc-text {
    flex: 1;
    font-size: clamp(0.86rem, 0.95vw, 1rem);
    color: #2a2a2a;
    line-height: 1.6;
    text-align: right;
}

.cal-event-desc-text p {
    margin: 0 0 8px;
}

.cal-event-desc-text p:last-child {
    margin-bottom: 0;
}

.cal-event-desc-icon {
    flex-shrink: 0;
    margin-top: 4px;
    width: 18px;
    height: 18px;
    stroke: #a03d82;
}

.cal-event-divider-full {
    border: none;
    border-top: 2px solid #191919;
    margin: 12px 0 10px;
}

.cal-event-meeting-info {
    padding: 0;
    font-size: clamp(0.78rem, 0.86vw, 0.9rem);
    color: #2a2a2a;
    text-align: right;
    direction: ltr;
    line-height: 1.45;
    word-break: break-word;
}

.cal-event-meeting-info p {
    margin: 0 0 4px;
}

/* Short divider (narrow, centered) at top of meeting block */
.cal-meeting-div-short {
    width: 44px;
    border: none;
    border-top: 1.5px solid #9ca3af;
    margin: 8px auto;
}

/* Mid divider (medium width) between sections */
.cal-meeting-div-mid {
    width: 160px;
    border: none;
    border-top: 1px solid #d1d5db;
    margin: 10px auto;
}

/* Full-width divider inside meeting info */
.cal-meeting-div-full {
    border: none;
    border-top: 1px solid #d1d5db;
    margin: 10px 0;
}

/* Right-aligned short divider at bottom */
.cal-meeting-div-right {
    margin-left: auto;
    margin-right: 0;
}

.cal-event-link {
    color: #3b82f6;
    text-decoration: underline;
    word-break: break-all;
}

.add-action-modal-box {
    max-width: min(640px, 94vw) !important;
    max-height: calc(100vh - 56px);
    overflow-y: auto;
}

.client-kanban-card .card-bottom-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-top: 12px;
    flex-direction: row-reverse;
}

.card-tags {
    display: flex;
    gap: 6px;
}
.card-top-row{
    display: flex;
    align-items: center;
    gap: 10px;
}

.left-icon{
    margin-right: auto;

    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #f5f5f5;

    display: flex;
    align-items: center;
    justify-content: center;

    color: gray;
}

.auth-input-icon{
    width: 20px;
    height: 20px;
}
.tag {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3px 8px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 600;
    flex-direction: row-reverse;

}

.tag-purple {
    background: #F1E5F1;
    color: #8D3176;
    border: 1px solid #8D3176;
}

.tag-orange {
    background: #FFF8E1;
    color: #E6A23C;
    border: 1px solid #E6A23C;
}

.tag-icon {
    width: 13px;
    height: 13px;
    display: flex;
    align-items: center;
    justify-content: center;


}

.tag-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

/* Icons are provided in the HTML via <img> elements for better semantics */

.client-kanban-card .card-flag-row {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    flex-direction: row-reverse;
    margin: 8px;
}

.client-kanban-card .card-flag {
    width: 20px;
    height: auto;
    object-fit: contain;
}

.client-kanban-card .card-nationality {
    font-size: 12px;
    color: #1a1919;
    font-weight: 700;
}



/* Add Task Button */
.btn-add-task {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #8D3176;
    background: none;
    border: none;
    cursor: pointer;
    border-top: 1px solid #E5E5E5;
    margin-top: 4px;
    transition: background 0.2s ease;
    border-radius: 0 0 12px 12px;
}

.btn-add-task:hover {
    background: rgba(141, 49, 118, 0.05);
}

.btn-add-task svg {
    width: 16px;
    height: 16px;
}

/* Project Sub-tabs */
.project-sub-tabs {
    display: flex;
    align-items: center;
    gap: 28px;
    border-bottom: 2px solid #E5E5E5;
    justify-content: flex-end;
    width: fit-content;
    flex-direction: row-reverse;
}

.project-sub-tab {
    display: inline-flex;
    align-items: center;
    padding: 10px 4px 12px;
    font-size: 14px;
    font-weight: 600;
    color: #999;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.2s ease;
    background: none;
}

.project-sub-tab:hover {
    color: #555;
}

.project-sub-tab.active {
    color: #1a1919;
    border-bottom-color: #8D3176;
}

/* ========== PROJECTS RESPONSIVE ========== */
@media (max-width: 992px) {
    .kanban-board {
        grid-template-columns: 1fr;
    }

    .projects-tabs {
        gap: 16px;
    }

    .project-sub-tabs {
        gap: 16px;
        overflow-x: auto;
    }
}

@media (max-width: 768px) {
    .kanban-board {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .kanban-column {
        padding: 16px 12px;
    }

    .task-card {
        padding: 14px;
    }

    .projects-tabs,
    .project-sub-tabs {
        gap: 12px;
    }
}

/* ========== REFINED MODAL & AVATARS ========== */

/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.modal-overlay.open {
    display: flex;
}

/* Modal Content */
.modal-content {
    background: #fff;
    width: 500px;
    max-width: 95%;
    border-radius: 20px;
    padding: 32px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        transform: translateY(20px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.modal-header {
    margin-bottom: 32px;
    text-align: right;
}

.modal-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a1919;
}

/* Modal Body / Form */
.modal-body {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-label {
    font-size: 14px;
    font-weight: 700;
    color: #1a1919;
    text-align: right;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 14px 16px;
    background: #F8F9FA;
    border: 1px solid #E9ECEF;
    border-radius: 12px;
    font-size: 14px;
    color: #1a1919;
    transition: all 0.2s ease;
    text-align: right;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    background: #fff;
    border-color: #8D3176;
    box-shadow: 0 0 0 4px rgba(141, 49, 118, 0.05);
}

.form-textarea {
    resize: none;
}

/* Modal Custom Select Background Override */
.modal-body .custom-select-trigger {
    background: rgba(248, 250, 251, 1);
    border: 1px solid rgba(226, 232, 240, 1);
    border-radius: 12px;
    padding: 14px 16px;
    color: rgba(100, 116, 139, 1);
}

.modal-body .custom-select.open .custom-select-trigger {
    background: #fff;
    border-color: #8D3176;
    box-shadow: 0 0 0 4px rgba(141, 49, 118, 0.05);
}

/* Modal Footer */
.modal-footer {
    margin-top: 40px;
    display: flex;
    align-items: center;
    gap: 16px;
    justify-content: flex-start;
}

.btn-modal {
    padding: 14px 40px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-modal-primary {
    background: #9d2e7a;
    color: #fff;
    border: none;
}

.btn-modal-primary:hover {
    background: #842666;
    transform: translateY(-2px);
}

.btn-modal-secondary {
    background: #fff;
    color: #1a1919;
    border: 1.5px solid #1a1919;
    padding: 13px 39px;
}

.btn-modal-secondary:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
}

/* Initials Avatar */
.avatar-initials {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    border: 2px solid #fff;
    margin-right: -10px;
}

.avatar-orange {
    background: #FF9F00;
}

.avatar-blue {
    background: #007BFF;
}

.avatar-green {
    background: #28A745;
}

.avatar-purple {
    background: #8D3176;
}

@media (max-width: 768px) {
    .create-form-row {
        grid-template-columns: 1fr;
    }

    .modal-content {
        padding: 24px;
    }

    .modal-footer {
        flex-direction: column;
        width: 100%;
    }

    .btn-modal {
        width: 100%;
    }
}

/* ========== CALENDAR PAGE ========== */
.calendar-section {
    padding: 0 24px 24px;
}

.calendar-controls {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}

.controls-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

.calendar-search {
    position: relative;
    width: 280px;
}

.calendar-search input {
    width: 100%;
    padding: 12px 40px 12px 16px;
    border-radius: 16px;
    border: 1px solid #E2E8F0;
    font-size: 0.9rem;
    color: #1a1919;
}

.calendar-search img {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    opacity: 0.5;
}

.calendar-filters {
    display: flex;
    align-items: center;
    gap: 12px;
}

.filter-dropdown {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 12px;
    border: 1px solid #E2E8F0;
    background: #fff;
    cursor: pointer;
    font-size: 0.85rem;
    font-weight: 500;
    color: #4a5568;
    transition: all 0.2s ease;
}

.filter-dropdown:hover {
    border-color: var(--primary);
}

.filter-dropdown img {
    width: 14px;
    height: 14px;
    opacity: 0.6;
}

.controls-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.btn-today {
    padding: 10px 20px;
    border-radius: 12px;
    background: #F8FAFC;
    color: #1a1919;
    font-weight: 600;
    font-size: 0.9rem;
    border: 1px solid #E2E8F0;
}

.month-nav {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #F8FAFC;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #E2E8F0;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    background: #EDF2F7;
}

.nav-btn img {
    width: 16px;
    height: 16px;
}

.current-month {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1919;
    min-width: 120px;
    text-align: center;
}

/* Calendar Grid */
.calendar-view-container {
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    /* border: 1px solid #E2E8F0; */
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    /* border-top: 1px solid #E2E8F0;
    border-right: 1px solid #E2E8F0; */
}

.calendar-day-header {
    background: #F8FAFC;
    padding: 12px;
    text-align: center;
    font-weight: 700;
    font-size: 0.85rem;
    color: #64748b;
    border-bottom: 1px solid #F1F5F9;
}

.calendar-cell {
    min-height: 140px;
    min-width: 140px;
    padding: 12px;
    border-left: 1px solid #F1F5F9;
    border-bottom: 1px solid #F1F5F9;
    position: relative;
    transition: background 0.2s ease;
}

.calendar-cell:nth-child(7n) {
    border-left: none;
}

.calendar-cell:hover {
    background: #FDFDFD;
}

.day-number {
    font-size: 0.9rem;
    font-weight: 600;
    color: #4a5568;
    display: block;
    margin-bottom: 8px;
    text-align: left;
}

.calendar-cell.empty {
    background: #F9FAFB;
}

/* Event Badges */
.calendar-event-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border-radius: 8px;
    margin-bottom: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    cursor: pointer;
    transition: transform 0.2s ease;
    white-space: nowrap;
    overflow: hidden;
}

.calendar-event-badge:hover {
    transform: scale(1.02);
}

.event-assignee {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    flex-shrink: 0;
}

.assignee-s {
    background-color: #3b82f6;
}

/* Blueish */
.badge-assignee-m {
    background-color: #f97316;
}

.assignee-a {
    background-color: #4a3aff;
}
.assignee-n {
    background-color: #00BA88;
}
.badge-assignee-a {
    background-color: #df2828;
    text-decoration: line-through;
}
.badge-assignee-n {
    background-color: #00BA88;
}
/* Orangeish */

.event-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
}

.check-icon {
    width: 12px;
    height: 12px;
}

.badge-teal {
    background-color: #00BA88;
}

.badge-blue {
    background-color: #3b82f6;
}
.badge-orange {
    background-color: #fd9024;
}
.badge-gray {
    background-color: #F8FAFC;
    color: #4a5568;
    border: 1px solid #E2E8F0;
}

.event-time-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #4A3AFF;
    color: #fff;
    width: 22px;
    height: 22px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 700;
}

/* Custom Refactoring Classes */
.calendar-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    opacity: 0.5;
    width: 18px;
    height: 18px;
}

.badge-offset {
    margin-top: 25px !important;
}

.modal-md {
    max-width: 500px !important;
}

.flex-between {
    justify-content: space-between !important;
}

.trigger-large {
    border-radius: 12px !important;
    padding: 14px 16px !important;
}

.mb-24 {
    margin-bottom: 24px !important;
}

.d-block {
    display: block !important;
}

@media (max-width: 1200px) {
    .calendar-controls {
        flex-wrap: wrap;
        gap: 16px;
    }

    .controls-right {
        flex: 1;
        min-width: 100%;
        flex-wrap: wrap;
        display: flex;
        /* Back to flex */
        grid-template-columns: none;
    }

    .calendar-search {
        flex: 1;
        min-width: 200px;
    }

    .calendar-filters {
        flex: 2;
        display: flex;
        flex-wrap: wrap;
        min-width: 300px;
        gap: 12px;
    }

    .filter-select {
        flex: 1;
        min-width: 120px;
    }

    .controls-left {
        width: 100%;
        border-top: 1px solid #f1f5f9;
        padding-top: 16px;
        margin-top: 8px;
    }
}

@media (max-width: 768px) {
    .calendar-view-container {
        overflow-x: auto;
        padding-bottom: 10px;
        -webkit-overflow-scrolling: touch;
    }

    .calendar-grid {
        min-width: 700px;
        /* Keep the 7-column structure, allow scroll */
        display: grid;
        grid-template-columns: repeat(7, 1fr);
        gap: 0;
        border: 1px solid #E2E8F0;
    }

    .calendar-cell {
        min-height: 100px;
        border: 1px solid #f1f5f9;
        border-radius: 0;
        background: transparent;
    }

    .calendar-day-header {
        display: flex;
        padding: 12px;
        font-size: 0.8rem;
    }

    .calendar-controls {
        padding: 0 4px;
    }
}

@media (max-width: 480px) {
    .header-greeting h1 {
        font-size: 1.2rem;
    }

    .calendar-search-icon {
        right: 12px;
    }
}

/* ========== REPORTS SECTION ========== */
.reports-section {
    padding: 0 24px 40px;
}

.reports-header {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 24px;
}

.reports-header h2 {
    font-size: 22px;
    font-weight: 800;
    color: #1a1919;
}

.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
}

.report-card {
    background: #fff;
    border: 1px solid #f1f5f9;
    border-radius: 20px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.3s ease;
}

.report-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.report-icon-wrapper {
    margin-bottom: 20px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.report-icon-wrapper img {
    width: 120px;
    height: auto;
}

.report-info {
    text-align: center;
    margin-bottom: 20px;
    width: 100%;
}

.report-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1919;
    margin-bottom: 8px;
}

.report-meta {
    font-size: 0.85rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.report-actions {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 16px;
    border-top: 1px dashed #e2e8f0;
    flex-direction: row-reverse;
}

.btn-report-view {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #64748b;
    transition: all 0.2s ease;
    cursor: pointer;
}

.btn-report-view:hover {
    background: #f8fafc;
    color: #412f6a;
}

.btn-report-download {
    background: #1a192e;
    color: #fff;
    border-radius: 12px;
    padding: 10px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s ease;
    cursor: pointer;
    border: none;
}

.btn-report-download:hover {
    background: #2d2c4d;
}

.btn-report-download svg {
    width: 18px;
    height: 18px;
}

@media (max-width: 768px) {
    .reports-grid {
        grid-template-columns: 1fr;
    }
}

/* ========== CONVERT TO INVOICE PAGE ========== */
.convert-products-container {
    margin-top: 32px;
    background: #F8F9FA;
    border-radius: 24px;
    padding: 24px;
}

.convert-products-table-header {
    display: grid;
    grid-template-columns: 2fr 1.5fr 3fr 1fr 1.5fr 1.5fr 1.5fr;
    gap: 16px;
    padding: 12px 24px;
    color: #8E94A3;
    font-size: 14px;
}

.convert-product-row {
    background: #fff;
    border-radius: 16px;
    margin-bottom: 12px;
    display: grid;
    grid-template-columns: 2fr 1.5fr 3fr 1fr 1.5fr 1.5fr 1.5fr;
    gap: 16px;
    padding: 16px 24px;
    align-items: center;
}

.convert-product-name {
    display: block;
    font-weight: 600;
}

.convert-product-code {
    color: #6366F1;
    font-size: 12px;
}

.convert-product-img-wrapper {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    overflow: hidden;
    background: #F8F9FA;
    display: flex;
    align-items: center;
    justify-content: center;
}

.convert-product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.convert-product-desc {
    font-size: 13px;
    color: #4B5563;
}

.convert-product-val-bold {
    font-weight: 600;
}

.convert-product-val-total {
    font-weight: 700;
    color: #111827;
}

.convert-summary-container {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
}

.convert-summary-item {
    display: flex;
    gap: 40px;
    width: 300px;
    justify-content: space-between;
}

.convert-summary-label {
    color: #4B5563;
    font-weight: 600;
}

.convert-summary-val {
    font-weight: 700;
    font-family: 'Outfit';
}

.convert-summary-total-wrapper {
    display: flex;
    gap: 40px;
    width: 300px;
    justify-content: space-between;
    border-top: 2px solid #E5E7EB;
    padding-top: 12px;
    margin-top: 8px;
}

.convert-summary-total-label {
    color: #111827;
    font-weight: 700;
    font-size: 18px;
}

.convert-summary-total-val {
    font-weight: 800;
    font-family: 'Outfit';
    font-size: 20px;
    color: #9D2E7C;
}

.convert-actions-footer {
    margin-top: 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-direction: row-reverse;

}

@media (max-width: 768px) {
    .convert-actions-footer {
        flex-direction: column-reverse;
        gap: 12px;
    }
}

.convert-btn-cancel {
    border: 1.5px solid #111827;
    background: #fff;
    color: #111827;
    padding: 14px 48px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
}

.convert-btn-save {
    background: #9D2E7C;
    color: #fff;
    border: none;
    padding: 14px 100px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 10px 15px -3px rgba(157, 46, 124, 0.3);
}

.convert-input-currency {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #8E94A3;
}

.convert-textarea {
    height: auto !important;
    padding: 12px !important;
}

.convert-validity {
    margin-top: 24px;
}

/* ========== COSTS MODULE ========== */
.costs-creator-badge {
    background: #FDEDF7;
    color: #111827;
    padding: 6px 16px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 13px;
    font-weight: 600;
}

.costs-table-badge {
    background: #FDEDF7;
    color: #9D2E7C;
    padding: 4px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
}

.costs-view-main-icon {
    width: 64px;
    height: 64px;
    background: rgba(242, 230, 239, 1);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.costs-view-main-icon img {
    width: 32px;
    filter: brightness(0) saturate(100%) invert(17%) sepia(60%) saturate(1200%) hue-rotate(280deg) brightness(70%) contrast(120%);
}

.costs-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 40px;
}

.costs-info-card {
    background: #F9FAFB;
    padding: 24px;
    border-radius: 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.costs-info-label {
    color: #9CA3AF;
    font-size: 13px;
    margin-bottom: 8px;
}

.costs-info-value {
    color: #111827;
    font-size: 18px;
    font-weight: 700;
}

.costs-amount-value {
    color: #8D3176;
    font-size: 22px;
    font-weight: 800;
    font-family: 'Outfit';
}

.costs-attachment-grid {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.costs-attachment-card {
    border: 1px solid #F3F4F6;
    border-radius: 16px;
    padding: 24px 40px;
    text-align: center;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    transition: transform 0.2s;
}

.costs-attachment-card:hover {
    transform: translateY(-4px);
}

.costs-file-icon {
    width: 56px;
    margin-bottom: 16px;
}

.costs-file-name {
    font-weight: 700;
    color: #111827;
    font-size: 13px;
    margin-bottom: 4px;
}

.costs-file-meta {
    color: #9CA3AF;
    font-size: 11px;
}

.costs-batch-delete-btn {
    background: #B20015;
    color: #fff;
    border: none;
    padding: 12px 32px;
    border-radius: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

/* ========== COSTS VIEW PAGE ========== */

/* Back link override for costs (gold color) */
.costs-back-link {
    color: #FBB040;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
    margin-bottom: 8px;
}

/* Page heading */
.costs-page-heading {
    font-size: 24px;
    color: #111827;
    font-weight: 700;
}

/* Card wrapper padding */
.costs-view-card {
    padding: 40px;
}

/* Top row: icon+title on right, badge on left */
.costs-view-top-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 32px;
}

/* Title + icon group (inner flex, RTL order) */
.costs-view-title-group {
    display: flex;
    align-items: center;
    gap: 16px;
    /* flex-direction: row-reverse; */
}

/* Title text block */
.costs-view-title-block {
    text-align: right;
}

/* Field label (small gray) */
.costs-view-label {
    color: #9CA3AF;
    font-size: 13px;
    margin-bottom: 6px;
}

/* Section heading (e.g. ������� value) */
.costs-view-heading {
    font-size: 20px;
    color: #111827;
    font-weight: 700;
    margin: 0;
}

/* Description block */
.costs-view-desc-block {
    margin-bottom: 32px;
    border-bottom: 1px solid #F3F4F6;
    padding-bottom: 32px;
}

/* Description label */
.costs-view-desc-label {
    color: #9CA3AF;
    font-size: 13px;
    margin-bottom: 10px;
    text-align: right;
}

/* Description paragraph */
.costs-view-desc-text {
    color: #1F2937;
    line-height: 1.9;
    font-size: 15px;
    text-align: right;
    margin: 0;
}

/* Info bar container - two cards side by side */
.costs-view-info-bar {
    display: flex;
    gap: 16px;
    margin-bottom: 40px;
}

/* Individual info card */
.costs-view-info-card {
    flex: 1;
    background: #F9FAFB;
    border-radius: 16px;
    padding: 20px 28px;
}

/* Card header row */
.costs-view-info-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

/* Info bar field label */
.costs-view-info-label {
    color: #9CA3AF;
    font-size: 13px;
    margin-bottom: 8px;
}

.costs-view-info-card-header .costs-view-info-label {
    margin-bottom: 0;
}

/* ID tag inside client card */
.costs-view-id-tag {
    color: #9CA3AF;
    font-size: 13px;
    font-weight: 500;
}

/* Client name value */
.costs-view-client-value {
    color: #111827;
    font-size: 18px;
    font-weight: 700;
}

/* Amount value */
.costs-view-amount-value {
    color: #8D3176;
    font-size: 22px;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
}

/* Attachments section heading */
.costs-view-attachments-heading {
    font-size: 16px;
    color: #111827;
    font-weight: 700;
    margin-bottom: 24px;
    text-align: right;
}

/* Attachment grid aligned to right */
.costs-attachment-grid--right {
    justify-content: flex-start;
}

/* Icon inside attachment card - top spacing */
.costs-attachment-icon-wrap {
    margin-bottom: 16px;
}

/* Creator badge avatar */
.costs-creator-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
}

/* Creator badge icon */
.costs-creator-icon {
    width: 18px;
}

/* Costs view footer */
.costs-view-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-top: 24px;
    margin-top: 24px;
    border-top: 1px solid #F3F4F6;
    justify-content: flex-end;
    direction: rtl;
}

.costs-view-footer-label {
    font-size: 13px;
    color: #9CA3AF;
    font-weight: 500;
}

.costs-view-footer-value {
    font-size: 13px;
    color: #6B7280;
    font-weight: 500;
    direction: ltr;
}

/* Costs upload button */
.costs-upload-btn {
    background: #3D2D7A;
    color: #fff;
    padding: 18px 40px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
    border: none;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    font-family: inherit;
    transition: background 0.2s ease;
    flex-direction: row-reverse;
}

.costs-upload-btn:hover {
    background: #2E2060;
}

.costs-upload-btn img {
    width: 18px;
    height: 18px;
}

/* ========== PROFILE PAGE ========== */
.profile-card {
    background: #fff;
    border-radius: 20px;
    padding: 0;
    position: relative;
    width: 100%;
    margin: 0;
    border: none;
}

.profile-cover-box {
    background: #F8F9FA;
    border-radius: 24px;
    padding: 32px 40px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 40px;
}

.profile-avatar-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}

.profile-avatar-wrapper {
    position: relative;
    width: 120px;
    height: 120px;
}

.profile-avatar-img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    border: 4px solid #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.profile-avatar-btns {
    display: flex;
    gap: 8px;
    background: #fff;
    padding: 4px;
    border-radius: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.btn-avatar-action {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    text-decoration: none;
}

.btn-avatar-change {
    background: #90278E;
    color: #fff;
}

.btn-avatar-delete {
    background: #fff;
    color: #EF4444;
    border: 1px solid #EF4444;
}

.btn-avatar-delete svg {
    width: 12px;
    height: 12px;
}

.btn-avatar-change svg {
    width: 12px;
    height: 12px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
}

.profile-id-badge {
    background: #F3F4F6;
    color: #111827;
    padding: 8px 16px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
}

.profile-status-wrapper {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.status-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
}

.status-pill {
    padding: 6px 16px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
}

.status-pill.is-active {
    background: #ECFDF3;
    color: #027A48;
}

.status-pill.is-inactive {
    background: #FEF3F2;
    color: #B42318;
}

.form-error-text {
    color: #B42318;
    font-size: 12px;
    margin-top: 6px;
}

.schedule-input-disabled {
    background-color: #F9FAFB !important;
    color: #9CA3AF !important;
}

.profile-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    margin-bottom: 24px;
}

.profile-row-full {
    grid-template-columns: 1fr;
}

.profile-section-title {
    font-size: 18px;
    font-weight: 700;
    color: #111827;
    margin: 40px 0 24px;
}

.profile-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.profile-input-wrapper input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #E5E7EB;
    border-radius: 12px;
    background: #F9FAFB;
    color: #111827;
    font-size: 14px;
    transition: all 0.2s;
}

.profile-input-wrapper select,
.profile-input-wrapper textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #E5E7EB;
    border-radius: 12px;
    background: #F9FAFB;
    color: #111827;
    font-size: 14px;
    transition: all 0.2s;
    appearance: none;
}

.profile-input-wrapper select:focus,
.profile-input-wrapper textarea:focus {
    border-color: #9D2E7C;
    outline: none;
    background: #fff;
}

.profile-input-wrapper select {
    background-image: url("data:image/svg+xml;charset=UTF-8,%3Csvg width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%239CA3AF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 16px center;
    background-size: 16px;
    padding-left: 40px;
    cursor: pointer;
}

.profile-input-wrapper select option {
    color: #111827;
}

.profile-input-wrapper input:focus {
    border-color: #9D2E7C;
    outline: none;
    background: #fff;
}

.profile-input-wrapper input::placeholder {
    color: #9CA3AF;
}

.profile-input-wrapper.has-icon-right input {
    padding-right: 48px;
}

.profile-input-wrapper.has-icon-left input {
    padding-left: 48px;
}

.profile-input-wrapper.has-both-icons input {
    padding-right: 48px;
    padding-left: 48px;
}

.profile-input-icon-right {
    position: absolute;
    right: 16px;
    color: #9CA3AF;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-input-icon-left {
    position: absolute;
    left: 16px;
    color: #9CA3AF;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-form-label {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 12px;
}

.profile-form-label .required {
    color: #EF4444;
    margin-right: 4px;
}

.profile-actions {
    display: flex;
    gap: 16px;
    margin-top: 40px;
    justify-content: flex-end;
}

.btn-profile-save {
    background: #90278E;
    color: #fff;
    border: none;
    padding: 14px 48px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    font-size: 16px;
    flex: 1;
    max-width: 250px;
}

.btn-profile-cancel {
    background: #fff;
    color: #111827;
    border: 1px solid #111827;
    padding: 14px 48px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    font-size: 16px;
    flex: 1;
    max-width: 150px;
}

@media (max-width: 768px) {
    .profile-cover-box {
        flex-direction: column-reverse;
        align-items: center;
        gap: 24px;
    }

    .profile-form-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .profile-actions {
        flex-direction: column-reverse;
    }

    .btn-profile-save, .btn-profile-cancel {
        max-width: 100%;
    }
}

/* ========== NOTIFICATIONS PAGE ========== */
.notifications-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    padding: 16px 24px;
    gap: 16px;
}

.notifications-search-group {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #FAFBFC;
    border-radius: 30px;
    height: 52px;
    padding: 4px 16px 4px 4px;
    width: 100%;
    max-width: 500px;
}

.notifications-search-input-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    padding-right: 4px;
}

.notifications-search-input-wrapper input {
    background: transparent;
    border: none;
    outline: none;
    width: 100%;
    font-family: inherit;
    font-size: 15px;
    color: #333;
}

.notifications-search-btn {
    background: #9A3B86;
    color: #fff;
    border: none;
    border-radius: 30px;
    height: 100%;
    padding: 0 32px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    flex-shrink: 0;
}

.notifications-date-nav {
    display: flex;
    align-items: center;
    gap: 12px;
    background: #FAFBFC;
    border-radius: 30px;
    height: 52px;
    padding: 0 16px;
}

.notifications-nav-btn {
    background: none;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 4px;
}

.notifications-date-current {
    display: flex;
    align-items: center;
    gap: 8px;
}

.notifications-date-current span {
    font-weight: 600;
    font-size: 14px;
    color: #333;
}

.notifications-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 16px 24px;
}

.notification-card {
    display: flex;
    align-items: flex-start;
    background: #FAFBFC;
    border-radius: 16px;
    padding: 24px;
}

.notification-icon-wrapper {
    margin-left: 20px;
    position: relative;
    flex-shrink: 0;
}

.notification-unread-dot {
    position: absolute;
    top: 0;
    right: -4px;
    width: 8px;
    height: 8px;
    background: #F26722;
    border-radius: 50%;
    box-shadow: 0 0 0 2px #FAFBFC;
}

.notification-icon-circle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.notification-icon-orange {
    background: #FFF4EB;
}

.notification-icon-yellow {
    background: #FFF9E6;
}

.notification-icon-blue {
    background: #F0F6FF;
}

.notification-content {
    flex: 1;
}

.notification-title {
    margin: 0 0 6px 0;
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

.notification-desc {
    margin: 0 0 12px 0;
    font-size: 14px;
    color: #777;
}

.notification-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #A0A0A0;
    font-size: 13px;
}

@media (max-width: 768px) {
    .notifications-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .notifications-search-group {
        max-width: 100%;
    }

    .notifications-date-nav {
        justify-content: space-between;
    }
}

/* ========== EXPENSES / FINANCIAL METRICS PERFORMANCE ========== */
:root {
    --primary: #8e3a7d;
    --lost: #e74c3c;
    --expected: #f1c40f;
    --won: #27ae60;
    --waiting: #e7783c;
    --bg: #1a1a1a;
    --card-bg: #ffffff;
    --text-muted: #888;
}

/* Financial Header Toolbar */
.financial-subtitle {
    font-size: 14px;
    margin-top: 6px;
    color: #888;
}

.financial-toolbar {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    padding: 0 24px;
    margin-bottom: 24px;
}

.date-picker-container {
    display: flex;
    align-items: center;
    gap: 14px;
    width: 100%;
    justify-content: space-between;
}

.update-time {
    font-size: 11px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 4px;
}

.update-time svg {
    opacity: 0.7;
}

.date-picker-btn {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--primary);
    background: transparent;
    color: var(--primary);
    padding: 10px 18px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    font-size: 14px;
}

/* 1️⃣ حالات الإيراد - تصميم أفقي بسيط */
.financial-content {
    padding: 0 24px 24px;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-bottom: 35px;
}

.status-box {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    text-align: center;
    background: white;
    padding: 24px;
    border-radius: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.02);
}

.status-box.lost { border-bottom: 4px solid var(--lost); }
.status-box.expected { border-bottom: 4px solid var(--expected); }
.status-box.won { border-bottom: 4px solid var(--won); }
.status-box.wait { border-bottom: 4px solid var(--waiting); }

.status-label-group {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    flex-direction: row-reverse;
}

.status-label-group span {
    font-size: 13px;
    color: #888;
    font-weight: 600;
    margin: 0;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.status-box.lost .status-dot { background-color: var(--lost); }
.status-box.expected .status-dot { background-color: var(--expected); }
.status-box.won .status-dot { background-color: var(--won); }

.status-value {
    font-size: 26px;
    font-weight: 800;
    display: block;
}

.status-box.lost .status-value { color: var(--lost); }
.status-box.expected .status-value { color: var(--expected); }
.status-box.won .status-value { color: var(--won); }

/* ========== CAPITAL BALANCE COMPONENT ========== */
.capital-balance-card {
    background: #fdfdfd;
    border-radius: 20px;
    padding: 35px 50px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.02);
    margin-bottom: 25px;
    border: 1px solid #f0f0f0;
}

.capital-balance-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

/* Info Section (Right side in RTL) */
.capital-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    max-width: 50%;
}

.c-balance-header {
    text-align: right;
    margin-bottom: 15px;
}

.c-title {
    display: block;
    color: #666;
    font-size: 15px;
    margin-bottom: 8px;
    font-weight: 500;
}

.c-value {
    display: block;
    font-size: 32px;
    color: #1a1a1a;
    font-weight: bold;
    letter-spacing: -0.5px;
}

.c-divider {
    border: none;
    border-top: 1px solid #eee;
    margin: 20px 0;
}

.c-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.c-detail-row {
    display: flex;
    justify-content: space-between; /* LTR separates left from right */
    align-items: center;
}

.c-detail-label {
    color: #888;
    font-size: 14px;
    font-weight: 500;
}

.c-detail-left {
    display: flex;
    align-items: center;
    gap: 8px; /* space between text and icon */
    flex-direction: row; /* Force icon to the left visually relative to the span in an RTL container */
    font-weight: 600;
    font-size: 15px;
    color: #1a1a1a;
}

.c-detail-left.loss {
    color: #e74c3c;
}

/* Chart Section (Left side in RTL) */
.capital-chart {
    flex-shrink: 0;
    width: 170px;
    height: 170px;
    position: relative;
    /* Optional shadow to mimic image subtle depth */
}

.circular-chart {
    display: block;
    margin: 0 auto;
    max-width: 100%;
    max-height: 100%;
}

.circle-bg {
    fill: none;
    stroke: #f3f3f3;
    stroke-width: 3.8;
}

.circle {
    fill: none;
    stroke: var(--primary, #8e3a7d);
    stroke-width: 3.8;
    stroke-linecap: round;
    /* To apply the percentage visually:
       For 70% it's stroke-dasharray="70, 100" (Because R=15.9155 makes Circ=100) */
}

.circular-chart .percentage {
    fill: var(--primary, #8e3a7d);
    font-size: 7px; /* Scaled down relative to viewBox */
    font-weight: bold;
    text-anchor: middle;
    /* Dominant baseline centers the text mathematically in the exact middle of Y=18 */
    dominant-baseline: central;
}

/* 2️⃣ تحليل الأرباح - الفيو الجديد للنتايج */
.profit-analysis {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    margin-bottom: 50px;
}

.main-card {
    background: rgba(248, 250, 251, 1);
    padding: 25px;
    border-radius: 25px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.02);
}

.main-card-title {
    margin-bottom: 24px;
    font-size: 18px;
    color: #1a1a1a;
    font-weight: 700;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #f5f5f5;
}

.result-item:last-child { border-bottom: none; }
.result-item.highlight-box {
    background: #ffffff;
    margin: 10px -10px;
    padding: 15px 10px;
    border-radius: 10px;
    border-bottom: none;
}

.label-group h4 {
    margin: 0 0 4px 0;
    font-size: 15px;
    color: #333;
    font-weight: 700;
}
.label-group small {
    color: #999;
    font-size: 11px;
}

.result-item.highlight-box h4 {
    color: var(--primary);
    font-size: 16px;
    font-weight: 800;
}

.value-text {
    font-size: 20px;
    font-weight: 800;
    color: #1a1a1a;
}
.value-text.loss { color: var(--lost); }
.value-text.highlight {
    color: var(--primary);
    font-size: 22px;
}

/* 3️⃣ توزيع الشركاء */
.partners-list { margin-top: 15px; }

.partner-row {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
    background: #fdfbff;
    padding: 12px;
    border-radius: 12px;
}

.partner-row .avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 18px;
}
.partner-row .avatar.primary { background: var(--primary); }
.partner-row .avatar.secondary { background: #555; }

.share-info { flex-grow: 1; }
.share-info span {
    display: block;
    color: #666;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 4px;
}
.share-info small {
    color: var(--primary);
    font-weight: bold;
    font-size: 14px;
}

.final-amount {
    font-weight: 800;
    font-size: 18px;
    color: #1a1a1a;
}

.warning-text {
    font-size: 12px;
    color: #999;
    margin-top: 24px;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.warning-icon {
    color: #f1c40f;
    font-size: 16px;
}

/* ========== RESPONSIVE: FINANCIAL METRICS PAGE ========== */
@media (max-width: 992px) {
    .profit-analysis {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .date-picker-container {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    .date-picker-container .update-time {
        justify-content: center;
    }
    .status-grid {
        grid-template-columns: 1fr;
    }
    .capital-balance-card {
        padding: 25px 20px;
    }
    .capital-balance-content {
        flex-direction: column;
        gap: 30px;
    }
    .capital-info {
        max-width: 100% !important;
        width: 100%;
    }
    .c-balance-header {
        text-align: center;
    }
    .c-value {
        justify-content: center;
    }
    .c-detail-row {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }
    .c-detail-left {
        width: 100%;
        justify-content: center;
    }
}

/* ========== USER WORK SCHEDULE COMPONENT ========== */
.schedule-card {
    --primary-purple: #823478;
    --light-bg: #f8f4f9;
    --active-green-bg: #f2faf7;
    --inactive-red-bg: #fff5f5;
    --border-color: #f1eff2;
    --text-main: #333;
    --text-muted: #888;
    --white: #ffffff;

    background: var(--white);
    border-radius: 24px;
}

.schedule-header-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.schedule-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
}

.schedule-icon-box {
    width: 24px;
    height: 24px;
    color: var(--primary-purple);
}

.schedule-header-section h2 {
    font-size: 1.2rem;
    color: var(--text-main);
    margin: 0;
}

.schedule-subtitle {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0;
}

/* الجدول */
.schedule-table {
    border: 1px solid var(--border-color);
    border-radius: 16px;
    overflow: hidden;
}

.schedule-table-head {
    display: grid;
    grid-template-columns: 2fr 2fr 2fr 1fr;
    padding: 15px 25px;
    background: #fafafa;
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.9rem;
}

.schedule-row-item {
    display: grid;
    grid-template-columns: 2fr 2fr 2fr 1fr;
    padding: 12px 25px;
    align-items: center;
    border-top: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.schedule-row-item.active { background-color: var(--active-green-bg); }
.schedule-row-item.disabled { background-color: var(--inactive-red-bg); opacity: 0.7; }

.schedule-day-name { font-weight: 600; color: var(--text-main); }

/* مدخلات الوقت */
.schedule-time-box {
    position: relative;
    width: 130px;
}

.schedule-time-input {
    width: 100%;
    padding: 10px 15px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    background: white;
    text-align: center;
    font-size: 0.9rem;
    outline: none;
    cursor: pointer;
    transition: border 0.3s;
    color: var(--text-main);
}

.schedule-time-input:focus { border-color: var(--primary-purple); }
.schedule-time-input:disabled { background-color: transparent; color: #aaa; cursor: not-allowed; }

/* مفتاح التبديل (Switch) */
.schedule-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.schedule-switch input { opacity: 0; width: 0; height: 0; }

.schedule-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #ddd;
    transition: .4s;
    border-radius: 34px;
}

.schedule-slider:before {
    position: absolute;
    content: "";
    height: 18px; width: 18px;
    left: 4px; bottom: 3px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

.schedule-switch input:checked + .schedule-slider { background-color: var(--primary-purple); }
.schedule-switch input:checked + .schedule-slider:before { transform: translateX(22px); }

/* الفوتر */
.schedule-footer-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 25px;
    background: #f7f4f8;
    margin-top: -1px;
    border-top: 1px solid var(--border-color);
}

.schedule-summary-label { color: var(--text-muted); font-size: 0.9rem; }

.schedule-badge {
    background: white;
    color: var(--primary-purple);
    padding: 6px 18px;
    border-radius: 20px;
    font-weight: bold;
    font-size: 0.85rem;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
}
/*notifications*/
.notification-wrapper{
    position: relative;
    display: inline-block;
}

.notification-bell{
    position: relative;
    font-size: 24px;
    cursor: pointer;
}

.notification-count{
    position: absolute;
    top: -8px;
    right: -10px;

    min-width: 20px;
    height: 20px;

    padding: 0 6px;

    border-radius: 50px;

    background: #8D3176;
    color: white;

    font-size: 12px;
    font-weight: bold;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow: 0 2px 8px rgba(141, 49, 118, 0.3);
}
.notifications-page{
    max-width: 850px;
    margin: 40px auto;
    padding: 20px;
    font-family: Arial, sans-serif;
}

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

.notifications-header h2{
    color: #8D3176;
    margin: 0;
}

.mark-all-btn{
    background: #8D3176;
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 10px;
    cursor: pointer;
    transition: 0.3s;
}

.mark-all-btn:hover{
    opacity: 0.9;
}

.notifications-list{
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.notification-card{
    background: white;
    border: 1px solid #eee;
    border-radius: 16px;
    padding: 18px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    transition: 0.3s;
}

.notification-card:hover{
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.06);
}

.notification-card.unread{
    border-left: 5px solid #8D3176;
    background: #fcf7fb;
}

.notification-top{
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.notification-top h4{
    margin: 0;
    font-size: 16px;
    color: #222;
}

.new-badge{
    background: #8D3176;
    color: white;
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 30px;
}

.notification-content p{
    margin: 0 0 10px;
    color: #666;
    line-height: 1.5;
}

.notification-time{
    font-size: 12px;
    color: #999;
}

.notification-action{
    margin-left: 20px;
}

.read-btn{
    border: none;
    background: transparent;
    color: #8D3176;
    cursor: pointer;
    font-weight: bold;
    transition: 0.3s;
}

.read-btn:hover{
    opacity: 0.7;
}

.read-text{
    color: #27ae60;
    font-size: 14px;
    font-weight: bold;
}

.empty-notifications{
    background: #fafafa;
    border-radius: 16px;
    padding: 40px;
    text-align: center;
    color: #999;
}

@media (max-width: 600px) {
    .schedule-table-head, .schedule-row-item { grid-template-columns: 1fr 1fr; gap: 10px; height: auto; }
    .schedule-header-section { flex-direction: column; align-items: flex-start; gap: 10px; }
}

/*notification modal*/
.modal {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.4);
    z-index: 1000;
}
.modal.hidden {
    display: none;
}
.modal-content {
    background: #fff;
    border-radius: 8px;
    padding: 2rem;
    /*width: 90%;*/
    /*max-width: 360px;*/
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    text-align: center;
}
.modal-content h2 {
    margin-bottom: 1rem;
    color: #5D2E8C;
}
.modal-content p {
    margin-bottom: 1.5rem;
    color: #333;
    line-height: 1.4;
}
.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}
.btn {
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
}
.btn-purple {
    background: #5D2E8C;
    color: #fff;
    border: none;
}
.btn-outline {
    background: transparent;
    color: #5D2E8C;
    border: 2px solid #5D2E8C;
}
