
@font-face {
    font-family: 'Samarkan';
    src: url('https://fonts.cdnfonts.com/s/15456/SAMARN__.woff') format('woff');
}
.samarkan-title {
    font-family: 'Samarkan', sans-serif !important;
    letter-spacing: 1px;
}

/* ==========================================================================
   Apex Agency Hub - Premium Glassmorphism Stylesheet
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. VARIABLES & CORE SETTINGS
   -------------------------------------------------------------------------- */
:root {
    color-scheme: light dark;
    --bg-color: hsl(222, 47%, 7%);
    --bg-gradient: radial-gradient(circle at 50% 0%, hsl(224, 60%, 15%) 0%, hsl(222, 47%, 7%) 80%);

    /* Glassmorphism token system */
    --glass-bg: hsla(223, 47%, 11%, 0.45);
    --glass-bg-hover: hsla(223, 47%, 15%, 0.6);
    --glass-border: hsla(217, 32%, 18%, 0.6);
    --glass-border-focus: hsla(250, 95%, 65%, 0.5);

    --surface-bg: hsla(223, 47%, 12%, 0.5);

    /* Color Palette */
    --primary-color: hsl(250, 95%, 65%);
    --primary-glow: hsla(250, 95%, 65%, 0.15);
    --primary-light: hsl(250, 95%, 75%);

    --secondary-color: hsl(190, 95%, 50%);
    --secondary-glow: hsla(190, 95%, 50%, 0.15);

    --accent-color: hsl(322, 85%, 60%);

    --success-color: hsl(142, 70%, 45%);
    --success-glow: hsla(142, 70%, 45%, 0.15);

    --warning-color: hsl(38, 92%, 50%);
    --warning-glow: hsla(38, 92%, 50%, 0.15);

    --error-color: hsl(346, 84%, 55%);
    --error-glow: hsla(346, 84%, 55%, 0.15);

    --text-primary: hsl(210, 40%, 98%);
    --text-secondary: hsl(215, 20%, 75%);
    --text-muted: hsl(215, 16%, 52%);

    /* Effects */
    --blur-intensity: 16px;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --shadow-soft: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --shadow-inner: inset 0 1px 1px 0 hsla(0, 0%, 100%, 0.05);
    --shadow-glow-purple: 0 0 20px 2px hsla(250, 95%, 65%, 0.25);

    /* Transitions */
    --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-smooth: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

body.light-theme {
    color-scheme: light;
    --bg-color: hsl(210, 36%, 96%);
    --bg-gradient: radial-gradient(circle at 50% 0%, hsl(0, 0%, 100%) 0%, hsl(210, 36%, 96%) 80%);

    --glass-bg: hsla(0, 0%, 100%, 0.7);
    --glass-bg-hover: hsla(0, 0%, 100%, 0.9);
    --glass-border: hsla(217, 32%, 18%, 0.1);
    --glass-border-focus: hsla(250, 95%, 65%, 0.5);

    --surface-bg: hsla(0, 0%, 100%, 0.6);

    --text-primary: hsl(222, 47%, 11%);
    --text-secondary: hsl(215, 20%, 35%);
    --text-muted: hsl(215, 16%, 50%);

    --shadow-soft: 0 8px 32px 0 rgba(31, 38, 135, 0.07);
    --shadow-inner: inset 0 1px 1px 0 hsla(0, 0%, 0%, 0.02);
}

/* Base resets */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

body, html {
    background: var(--bg-color);
    background-image: var(--bg-gradient);
    color: var(--text-primary);
    min-height: 100vh;
    overflow-x: hidden;
    overflow-wrap: break-word;
    word-break: break-word;
    line-height: 1.5;
    color-scheme: dark;
}

/* Helpers */
.hidden {
    display: none !important;
}

.text-muted {
    color: var(--text-muted) !important;
}

.text-success {
    color: var(--success-color) !important;
}

.text-warning {
    color: var(--warning-color) !important;
}

.text-danger {
    color: var(--error-color) !important;
}

.text-primary {
    color: var(--primary-color) !important;
}

.text-secondary {
    color: var(--secondary-color) !important;
}

.text-center {
    text-align: center !important;
}

.text-right {
    text-align: right !important;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-4 {
    margin-top: 1rem;
}

.mt-6 {
    margin-top: 1.5rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.mb-6 {
    margin-bottom: 1.5rem;
}

.py-4 {
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.py-6 {
    padding-top: 1.5rem;
    padding-bottom: 1.5rem;
}

.flex {
    display: flex;
}

.flex-col {
    flex-direction: column;
}

.flex-wrap {
    flex-wrap: wrap;
}

.items-center {
    align-items: center;
}

.items-start {
    align-items: flex-start;
}

.items-end {
    align-items: flex-end;
}

.justify-between {
    justify-content: space-between;
}

.justify-center {
    justify-content: center;
}

.justify-start {
    justify-content: flex-start;
}

.justify-end {
    justify-content: flex-end;
}

.gap-1 {
    gap: 0.25rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 0.75rem;
}

.gap-4 {
    gap: 1rem;
}

.gap-6 {
    gap: 1.5rem;
}

.flex-1 {
    flex: 1;
}

.flex-2 {
    flex: 2;
}

.mr-2 {
    margin-right: 0.5rem;
}

.mr-4 {
    margin-right: 1rem;
}

.mr-6 {
    margin-right: 1.5rem;
}

.size-8 {
    width: 2rem;
    height: 2rem;
}

.size-10 {
    width: 2.5rem;
    height: 2.5rem;
}

.opacity-50 {
    opacity: 0.5;
}

.width-full {
    width: 100%;
}

.height-full {
    height: 100%;
}

/* Custom Glow Classes */
.bg-indigo-glow {
    background: var(--primary-glow);
}

.bg-cyan-glow {
    background: var(--secondary-glow);
}

.bg-emerald-glow {
    background: var(--success-glow);
}

.text-indigo {
    color: var(--primary-color);
}

.text-cyan {
    color: var(--secondary-color);
}

.text-emerald {
    color: var(--success-color);
}

/* --------------------------------------------------------------------------
   2. REUSABLE GLASS COMPONENTS
   -------------------------------------------------------------------------- */
.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border-radius: var(--radius-md);
    box-shadow: 0 4px 24px -1px rgba(0, 0, 0, 0.2), inset 0 1px 1px hsla(0, 0%, 100%, 0.1);
    transition: all var(--transition-smooth);
}

.glass-card:hover {
    background: var(--glass-bg-hover);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    border: 1px solid transparent;
    transition: all var(--transition-fast);
    color: var(--text-primary);
}

.btn-primary {
    background: var(--primary-color);
    box-shadow: var(--shadow-glow-purple);
}

.btn-primary:hover {
    background: var(--primary-light);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--secondary-color);
    color: hsl(222, 47%, 7%);
}

.btn-secondary:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--glass-border);
}

.btn-outline:hover {
    background: var(--glass-bg-hover);
    border-color: var(--text-muted);
}

.btn-success {
    background: var(--success-color);
    box-shadow: 0 0 15px hsla(142, 70%, 45%, 0.25);
}

.btn-success:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.btn-danger {
    background: var(--error-color);
}

.btn-warning {
    background: var(--warning-color);
    color: #000;
}

.btn-warning:hover {
    background: #e6a800; /* slightly darker yellow */
    transform: translateY(-1px);
}

.btn-info {
    background: #0ea5e9; /* Cyan / Blue */
    color: #fff;
}

.btn-info:hover {
    background: #0284c7;
    transform: translateY(-1px);
}

.btn-logout {
    background: hsla(346, 84%, 55%, 0.1);
    border: 1px solid hsla(346, 84%, 55%, 0.25);
    color: var(--error-color);
}

.btn-logout:hover {
    background: var(--error-color);
    color: var(--text-primary);
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
}

.btn-block {
    width: 100%;
}

.btn-icon {
    width: 38px;
    height: 38px;
    padding: 0;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
}

.btn-icon:hover {
    background: var(--glass-bg-hover);
    color: var(--primary-color);
}

.btn-text {
    background: transparent;
    border: none;
    color: var(--primary-color);
    font-weight: 600;
    cursor: pointer;
}

.btn-text:hover {
    color: var(--primary-light);
    text-decoration: underline;
}

/* Badges */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 3px 8px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-primary {
    background: var(--primary-glow);
    color: var(--primary-color);
}

.badge-secondary {
    background: var(--secondary-glow);
    color: var(--secondary-color);
}

.badge-accent {
    background: hsla(322, 85%, 60%, 0.15);
    color: var(--accent-color);
}

.badge-success {
    background: var(--success-glow);
    color: var(--success-color);
}

.badge-warning {
    background: var(--warning-glow);
    color: var(--warning-color);
}

.unread-bubble {
    background: var(--success-color);
    color: #ffffff;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
    width: 20px;
    height: 20px;
    min-width: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.badge-error {
    background: var(--error-glow);
    color: var(--error-color);
}

/* Forms */
.standard-form .input-group,
.login-form .input-group {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
}

.standard-form label,
.login-form label {
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--primary-light);
    letter-spacing: 0.5px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 14px;
    width: 18px;
    height: 18px;
    color: var(--text-muted);
}

.standard-form input,
.standard-form select,
.standard-form textarea,
.login-form input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(139, 92, 246, 0.4);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.95rem;
    box-shadow: inset 0 2px 6px rgba(0,0,0,0.3);
    transition: all var(--transition-fast);
}

.standard-form select option {
    background: #1e293b;
    color: #fff;
    padding: 10px;
}

.standard-form input::placeholder,
.standard-form textarea::placeholder,
.login-form input::placeholder,
.inline-add-form input::placeholder {
    color: var(--text-muted);
    opacity: 0.9;
}

.input-wrapper input {
    padding-left: 44px;
}

.standard-form input:focus,
.standard-form select:focus,
.standard-form textarea:focus,
.login-form input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.3), inset 0 2px 4px rgba(0,0,0,0.3);
    background: rgba(30, 41, 59, 0.8);
}

.input-row {
    display: flex;
    justify-content: space-between;
}

/* --------------------------------------------------------------------------
   3. SCREEN CONTROLS & ROUTING
   -------------------------------------------------------------------------- */
.screen {
    opacity: 0;
    pointer-events: none;
    position: absolute;
    inset: 0;
    transition: opacity var(--transition-smooth);
    display: flex;
    overflow: hidden;
}

.screen.active {
    opacity: 1;
    pointer-events: auto;
    position: relative;
}

/* --------------------------------------------------------------------------
   4. LOGIN CARD PANEL
   -------------------------------------------------------------------------- */
#login-screen {
    justify-content: center;
    align-items: center;
    background-image: radial-gradient(circle at 10% 20%, hsla(250, 95%, 65%, 0.1) 0%, transparent 40%),
        radial-gradient(circle at 90% 80%, hsla(190, 95%, 50%, 0.08) 0%, transparent 40%);
}

.login-wrapper {
    width: 100%;
    max-width: 440px;
    padding: 20px;
}

.login-card {
    padding: 40px;
    border-radius: var(--radius-lg);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.logo-box {
    width: 60px;
    height: 60px;
    background: var(--primary-color);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px auto;
    box-shadow: var(--shadow-glow-purple);
}

.logo-icon {
    width: 32px;
    height: 32px;
    color: var(--text-primary);
}

.login-header h1 {
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 6px;
}

.login-header p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.login-options {
    margin: -10px 0 20px 0;
    text-align: center;
}

.tip-text {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.tip-text b {
    color: var(--text-secondary);
}

/* --------------------------------------------------------------------------
   5. WORKPLACE SYSTEM LAYOUT
   -------------------------------------------------------------------------- */
.app-container {
    height: 100vh;
    width: 100vw;
    position: relative;
}

#dashboard-screen {
    display: flex;
    flex-direction: row;
}

/* Glass Sidebar */
.sidebar {
    width: 280px;
    height: 100vh;
    border-radius: 0;
    border-top: none;
    border-left: none;
    border-bottom: none;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    transition: width var(--transition-smooth), opacity var(--transition-smooth), padding var(--transition-smooth);
    overflow: hidden;
}

.sidebar.collapsed {
    width: 0;
    padding-left: 0;
    padding-right: 0;
    opacity: 0;
    pointer-events: none;
    border-right: none;
}

.sidebar-header {
    padding: 24px;
    border-bottom: 1px solid var(--glass-border);
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.brand-logo {
    width: 38px;
    height: 38px;
    background: var(--primary-glow);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
}

.brand-logo i {
    width: 20px;
    height: 20px;
}

.brand-text h3 {
    font-size: 1.1rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.role-badge {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    color: var(--secondary-color);
}

/* User profile details in sidebar */
.user-profile-widget {
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--glass-border);
}

.avatar {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--primary-color) 0%, hsla(250, 95%, 45%, 1) 100%);
    color: var(--text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.05rem;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

.user-meta h4 {
    font-size: 0.9rem;
    font-weight: 600;
}

.user-meta p {
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* Navigation items in sidebar */
.sidebar-nav {
    flex: 1;
    padding: 24px 16px;
    overflow-y: auto;
}

.nav-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.nav-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.92rem;
    transition: all var(--transition-fast);
}

.nav-item div,
.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-item i {
    width: 20px;
    height: 20px;
    color: var(--text-muted);
    transition: color var(--transition-fast);
}

.nav-item:hover {
    background: var(--glass-bg-hover);
    color: var(--text-primary);
}

.nav-item:hover i {
    color: var(--text-primary);
}

.nav-item.active {
    background: var(--primary-glow);
    color: var(--primary-color);
    border: 1px solid hsla(250, 95%, 65%, 0.15);
}

.nav-item.active i {
    color: var(--primary-color);
}

.sidebar-footer {
    padding: 16px;
    border-top: 1px solid var(--glass-border);
}

/* --------------------------------------------------------------------------
   6. MAIN PANEL ELEMENTS
   -------------------------------------------------------------------------- */
.main-content {
    flex: 1;
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 24px 30px;
}

.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    margin-bottom: 24px;
    flex-shrink: 0;
    position: relative;
    z-index: 100;
}

.page-title h2 {
    font-size: 1.3rem;
    font-weight: 700;
}

.page-title p {
    font-size: 0.85rem;
}

.top-bar-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Date Display Widget */
.date-widget {
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Live clocking controller widget */
.clock-widget {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    padding: 5px 6px 5px 14px;
    border-radius: var(--radius-sm);
}

.status-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-online {
    background-color: var(--success-color);
    box-shadow: 0 0 8px var(--success-color);
    animation: pulse 2s infinite;
}

.status-offline {
    background-color: var(--text-muted);
}

.status-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.clock-timer {
    font-family: monospace;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--secondary-color);
    background: hsla(190, 95%, 50%, 0.1);
    padding: 4px 8px;
    border-radius: 4px;
}

/* Tabs Switchers */
.tab-panel {
    display: none;
    animation: fadeIn var(--transition-fast);
}

.tab-panel.active {
    display: block;
}

/* --------------------------------------------------------------------------
   7. CORE STAT CARDS GRID
   -------------------------------------------------------------------------- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 24px;
}

.stat-card {
    display: flex;
    align-items: center;
    padding: 24px;
    gap: 20px;
    background: linear-gradient(135deg, hsla(223, 47%, 13%, 0.4) 0%, hsla(223, 47%, 10%, 0.6) 100%);
    transition: transform 0.3s ease, box-shadow 0.3s ease, background 0.3s ease;
    cursor: default;
}

.stat-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px -5px rgba(0,0,0,0.4), inset 0 1px 1px hsla(0,0%,100%,0.15);
    background: linear-gradient(135deg, hsla(223, 47%, 16%, 0.5) 0%, hsla(223, 47%, 12%, 0.7) 100%);
}

.stat-icon {
    width: 54px;
    height: 54px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon i {
    width: 26px;
    height: 26px;
}

.stat-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
}

.stat-content h2 {
    font-size: 1.6rem;
    font-weight: 750;
    line-height: 1;
}

.stat-sub {
    font-size: 0.75rem;
}

/* Progress indicator bars */
.progress-bar-container {
    width: 130px;
    height: 6px;
    background: var(--surface-bg);
    border-radius: 10px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color), var(--primary-color));
    background-size: 200% 100%;
    border-radius: 10px;
    transition: width var(--transition-smooth);
    animation: gradientMove 3s linear infinite;
    box-shadow: 0 0 10px var(--primary-glow);
}

@keyframes gradientMove {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* --------------------------------------------------------------------------
   8. CARD LAYOUT AND STRUCTURES
   -------------------------------------------------------------------------- */
.dashboard-row {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
}

.border-bottom {
    border-bottom: 1px solid var(--glass-border);
}

.header-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-title i {
    width: 22px;
    height: 22px;
}

.header-title h3 {
    font-size: 1.05rem;
    font-weight: 700;
}

.card-body {
    padding: 24px;
}

/* --------------------------------------------------------------------------
   9. TARGET LISTS & CHECKLIST SYSTEM
   -------------------------------------------------------------------------- */
.target-quick-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.target-quick-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
}

.target-checkbox {
    width: 20px;
    height: 20px;
    border: 2px solid var(--glass-border);
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
}

.target-checkbox.checked {
    border-color: var(--success-color);
    background: var(--success-color);
}

.target-checkbox i {
    width: 14px;
    height: 14px;
    color: var(--bg-color);
    display: none;
}

.target-checkbox.checked i {
    display: block;
}

.target-text {
    font-size: 0.92rem;
    transition: all var(--transition-fast);
}

.target-text.completed {
    color: var(--text-muted);
    text-decoration: line-through;
}

/* Target checklists panel view */
.inline-add-form {
    display: flex;
    gap: 10px;
}

.inline-add-form input {
    flex: 1;
    padding: 10px 14px;
    background: hsla(222, 47%, 20%, 0.4);
    border: 1px solid hsla(0,0%,100%,0.1);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
}

.inline-add-form input:focus {
    outline: none;
    border-color: var(--primary-color);
}

.target-checklist-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}

.target-full-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
}

.btn-delete-target {
    color: var(--text-muted);
    cursor: pointer;
    background: transparent;
    border: none;
    padding: 4px;
    display: flex;
    border-radius: 4px;
}

.btn-delete-target:hover {
    color: var(--error-color);
    background: hsla(346, 84%, 55%, 0.1);
}

/* --------------------------------------------------------------------------
   10. HOLIDAY & DOUGHNUT GRAPH SYSTEM
   -------------------------------------------------------------------------- */
.holiday-donut-chart-container {
    width: 140px;
    height: 140px;
    margin: 10px auto;
    position: relative;
}

.donut-chart {
    width: 100%;
    height: 100%;
}

.donut-ring {
    stroke: var(--surface-bg);
}

.donut-segment {
    transform: rotate(-90deg);
    transform-origin: 50% 50%;
    transition: stroke-dasharray 0.8s ease;
}

.donut-text-group {
    fill: var(--text-primary);
}

.donut-number {
    font-size: 1.45rem;
    font-weight: 800;
}

.donut-label {
    font-size: 0.65rem;
    text-transform: uppercase;
    font-weight: 700;
    fill: var(--text-muted);
    letter-spacing: 1px;
}

.legend {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.legend-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.legend-dot.bg-cyan {
    background-color: var(--secondary-color);
}

.legend-dot.bg-indigo {
    background-color: var(--primary-color);
}

.legend-label {
    font-size: 0.82rem;
    color: var(--text-secondary);
}

/* calculated days in holiday request */
.calculated-days-preview {
    background: var(--primary-glow);
    border: 1px dashed var(--primary-color);
    padding: 10px;
    border-radius: var(--radius-sm);
    text-align: center;
    margin-top: 10px;
}

/* --------------------------------------------------------------------------
   11. DATA TABLES
   -------------------------------------------------------------------------- */
.table-responsive {
    overflow-x: auto;
    width: 100%;
}

.table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.table th {
    padding: 12px 16px;
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--text-muted);
    border-bottom: 1px solid var(--glass-border);
}

.table td {
    padding: 12px 16px;
    font-size: 0.88rem;
    color: var(--text-secondary);
    border-bottom: 1px solid hsla(217, 32%, 18%, 0.3);
}

.table tr:last-child td {
    border-bottom: none;
}

.table tr:hover td {
    background: var(--surface-bg);
}

.table-avatar-cell {
    display: flex;
    align-items: center;
    gap: 12px;
}

.table-avatar-cell .mini-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* --------------------------------------------------------------------------
   12. ADMIN CORE UTILITIES (NOTIFICATIONS & EVENT FEED)
   -------------------------------------------------------------------------- */
/* Notifications dropdown header indicator */
.notification-widget {
    position: relative;
}

.notification-indicator {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background-color: var(--error-color);
    box-shadow: 0 0 6px var(--error-color);
}

#emp-queue-count {
    font-size: 1rem;
    padding: 6px 14px;
    font-weight: 700;
    background: var(--warning-color);
    color: #000;
    box-shadow: 0 0 12px rgba(255, 209, 102, 0.4);
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.notification-dropdown {
    position: absolute;
    top: 50px;
    right: 0;
    width: 380px;
    max-height: 480px;
    display: flex;
    flex-direction: column;
    z-index: 9999;
    border-radius: var(--radius-md);
    animation: slideDown var(--transition-fast);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-soft);
}

.dropdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    border-bottom: 1px solid var(--glass-border);
}

.dropdown-header h3 {
    font-size: 0.95rem;
    font-weight: 700;
}

.notification-list {
    overflow-y: auto;
    max-height: 380px;
}

.notification-item {
    display: flex;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid var(--glass-border);
    transition: background var(--transition-fast);
}

.notification-item:hover {
    background: var(--surface-bg);
}

.notification-item-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.notification-item-content {
    flex: 1;
}

.notification-item-content p {
    font-size: 0.84rem;
    color: var(--text-secondary);
}

.notification-item-content span {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 4px;
    display: block;
}

/* Event Logs Sidebar in Admin Main dashboard */
.admin-event-log-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-height: 380px;
    overflow-y: auto;
}

.event-log-item {
    display: flex;
    gap: 12px;
    padding: 12px;
    border-radius: var(--radius-sm);
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
}

.event-log-text {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.event-log-time {
    font-size: 0.7rem;
    color: var(--text-muted);
    display: block;
    margin-top: 2px;
}

/* Targets Summary Dashboard Cards Grid */
.target-progress-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
}

.target-summary-card {
    padding: 16px;
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    background: var(--surface-bg);
}

.target-summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.target-summary-title h4 {
    font-size: 0.9rem;
    font-weight: 600;
}

.target-summary-title p {
    font-size: 0.75rem;
}

.target-summary-bar-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.target-summary-percent {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.target-summary-metrics {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    font-size: 0.78rem;
}

/* Detailed Target monitoring board (Admin) */
.admin-targets-board-wrapper {
    display: grid;
    gap: 20px;
}

.admin-member-targets-card {
    padding: 20px;
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
}

.member-card-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 12px;
}

.member-targets-list-section h5 {
    font-size: 0.78rem;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
    margin-bottom: 8px;
}

.member-targets-list-section {
    margin-bottom: 16px;
}

.member-targets-list {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.member-target-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    font-size: 0.82rem;
    padding: 6px 10px;
    background: var(--surface-bg);
    border-radius: 4px;
}

.member-target-row span.done {
    text-decoration: line-through;
    color: var(--text-muted);
}

/* --------------------------------------------------------------------------
   13. MODALS CONTAINER
   -------------------------------------------------------------------------- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(4, 9, 20, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 500;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-fast);
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-container {
    width: 100%;
    max-width: 480px;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid var(--glass-border);
}

.modal-header h3 {
    font-size: 1.15rem;
    font-weight: 700;
}

.modal-body {
    padding: 24px;
}


.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

/* --------------------------------------------------------------------------
   14. ADVANCED CHAT STYLES
   -------------------------------------------------------------------------- */
.chat-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.chat-list-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 12px;
    margin-bottom: 4px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background var(--transition-fast);
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.chat-list-item i {
    width: 16px;
    height: 16px;
}

.chat-list-item:hover {
    background: var(--glass-bg-hover);
    color: var(--text-primary);
}

.chat-list-item.active {
    background: var(--primary-glow);
    color: var(--primary-color);
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   14. TOAST ALERTS & ANIMATIONS
   -------------------------------------------------------------------------- */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 1000;
}

.toast {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.88rem;
    font-weight: 600;
    box-shadow: var(--shadow-soft);
    animation: slideIn var(--transition-fast) forwards;
    min-width: 250px;
}

.toast-success {
    background: var(--success-color);
}

.toast-error {
    background: var(--error-color);
}

.toast-warning {
    background: var(--warning-color);
}

/* keyframes details */
@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 hsla(142, 70%, 45%, 0.7);
    }

    70% {
        transform: scale(1);
        box-shadow: 0 0 0 8px hsla(142, 70%, 45%, 0);
    }

    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 hsla(142, 70%, 45%, 0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* --------------------------------------------------------------------------
   15. RESPONSIVE MEDIA WRAPPERS
   -------------------------------------------------------------------------- */
@media (min-width: 769px) and (max-width: 1024px) {
    .dashboard-row {
        flex-direction: column;
    }

    .sidebar {
        width: 80px;
    }

    .brand-text,
    .user-profile-widget .user-meta,
    .nav-item span {
        display: none !important;
    }

    .user-profile-widget {
        justify-content: center;
        padding: 16px 0;
    }

    .nav-item {
        justify-content: center;
        padding: 14px;
    }

    .nav-item i {
        margin: 0;
    }

    .sidebar-footer button span {
        display: none !important;
    }

    .sidebar-footer {
        padding: 16px 8px;
    }
}


/* ==========================================================================
   UPPTICK TEAM V2 - EXTRA INTERACTIVE STYLES
   ========================================================================== */

/* 1. Stopwatch glowing and widget styles */
.active-stopwatch-card {
    background: linear-gradient(135deg, hsla(250, 95%, 65%, 0.15) 0%, hsla(190, 95%, 50%, 0.08) 100%);
    border: 1px solid var(--primary-glow);
    box-shadow: var(--shadow-glow-purple), var(--shadow-soft);
    border-radius: var(--radius-md);
    animation: fadeIn var(--transition-fast);
}

.active-stopwatch-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    flex-wrap: wrap;
    gap: 16px;
}

.active-stopwatch-details {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.active-stopwatch-details h3 {
    font-size: 1.2rem;
    font-weight: 750;
    letter-spacing: -0.3px;
}

.active-stopwatch-clock-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.stopwatch-digits {
    font-family: 'Courier New', Courier, monospace;
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--secondary-color);
    text-shadow: 0 0 12px hsla(190, 95%, 50%, 0.35);
    background: var(--surface-bg);
    padding: 6px 16px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
    letter-spacing: 1px;
}

/* 2. Priority badges customized colors */
.priority-badge {
    text-transform: uppercase;
    font-size: 0.68rem;
    font-weight: 750;
    letter-spacing: 0.5px;
}

.priority-urgent {
    background: hsla(346, 84%, 55%, 0.15) !important;
    color: var(--error-color) !important;
    border: 1px solid hsla(346, 84%, 55%, 0.3) !important;
}

.priority-high {
    background: hsla(38, 92%, 50%, 0.15) !important;
    color: var(--warning-color) !important;
    border: 1px solid hsla(38, 92%, 50%, 0.3) !important;
}

.priority-medium {
    background: hsla(250, 95%, 65%, 0.15) !important;
    color: var(--primary-color) !important;
    border: 1px solid hsla(250, 95%, 65%, 0.3) !important;
}

.priority-low {
    background: hsla(215, 16%, 52%, 0.15) !important;
    color: var(--text-secondary) !important;
    border: 1px solid hsla(215, 16%, 52%, 0.3) !important;
}

/* 3. Task Terminal work queue */
.tasks-queue-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.task-queue-item {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    padding: 16px 20px;
    transition: all var(--transition-fast);
}

.task-queue-item:hover {
    background: var(--glass-bg-hover);
    border-color: var(--glass-border-focus);
}

.task-queue-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
}

.task-queue-info {
    flex: 1;
}

.task-queue-info h4 {
    font-size: 1.02rem;
    font-weight: 650;
    color: var(--text-primary);
}

.task-queue-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    margin-top: 6px;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.task-meta-divider {
    color: var(--glass-border);
}

.task-queue-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid hsla(217, 32%, 18%, 0.4);
    padding-top: 14px;
    margin-top: 14px;
    flex-wrap: wrap;
    gap: 12px;
}

.task-time-tracker {
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--surface-bg);
    padding: 6px 12px;
    border-radius: 4px;
    border: 1px solid var(--glass-border);
}

.task-timer-digits {
    font-family: monospace;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.task-action-btns {
    display: flex;
    gap: 8px;
}

/* Waiting for dependency style */
.task-blocked {
    border-left: 4px solid var(--warning-color) !important;
    background: hsla(38, 92%, 50%, 0.03) !important;
}

.task-blocked-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--warning-color);
    font-weight: 600;
}

/* 4. Collaborative live chat styles */
.chat-container {
    height: calc(100vh - 120px);
    display: flex;
    flex-direction: column;
}

.chat-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    height: 100%;
    overflow: hidden;
    padding: 20px;
}

.chat-feed-wrapper {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: var(--surface-bg);
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
}

.chat-message {
    max-width: 65%;
    padding: 12px 18px;
    border-radius: var(--radius-md);
    font-size: 0.9rem;
    position: relative;
    box-shadow: var(--shadow-inner);
    animation: fadeIn 0.25s ease;
}

.chat-message-left {
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    align-self: flex-start;
    border-bottom-left-radius: 2px;
}

.chat-message-right {
    background: var(--primary-glow);
    border: 1px solid hsla(250, 95%, 65%, 0.25);
    align-self: flex-end;
    border-bottom-right-radius: 2px;
}

.chat-message-sender {
    font-weight: 750;
    font-size: 0.76rem;
    margin-bottom: 6px;
    color: var(--secondary-color);
    letter-spacing: 0.3px;
}

.chat-message-text {
    line-height: 1.45;
    word-break: break-word;
}

.chat-message-time {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-top: 6px;
    text-align: right;
}

.chat-input-area {
    display: flex;
    gap: 12px;
    align-items: center;
}

.chat-input-area input {
    flex: 1;
    padding: 12px 18px;
    background: var(--surface-bg);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all var(--transition-fast);
}

.chat-input-area input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--primary-glow);
}

/* 5. Client Manager Checkboxes List */
.checkbox-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 0;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.checkbox-item input {
    width: auto !important;
    cursor: pointer;
}

.checkbox-item:hover {
    color: var(--text-primary);
}

.summary-preview-area {
    animation: fadeIn var(--transition-fast);
}

.completed-tasks-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 250px;
    overflow-y: auto;
}

.completed-task-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 14px;
    background: hsla(142, 70%, 45%, 0.05);
    border: 1px solid hsla(142, 70%, 45%, 0.15);
    border-radius: 4px;
    font-size: 0.84rem;
}

.completed-task-title {
    color: var(--text-muted);
    text-decoration: line-through;
}

/* Pulse animation utility */
.animate-pulse {
    animation: stopwatch-pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes stopwatch-pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: .5;
    }
}

/* ==========================================================================
   CHAT LAYOUT & MOBILE OPTIMIZATION
   ========================================================================== */
.chat-container {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    height: 75vh;
    background: transparent;
    border: none;
    padding: 0;
    position: relative;
    overflow: hidden;
}

.chat-sidebar {
    width: 300px;
    flex-shrink: 0;
    padding: 1rem 0;
    overflow-y: auto;
    background: transparent;
    border-right: 1px solid var(--glass-border);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.chat-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: var(--surface-bg);
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
    box-shadow: var(--shadow-sm);
    transition: transform 0.3s ease;
}

@media (max-width: 768px) {
    .chat-container {
        height: calc(100vh - 140px); /* Adjust based on mobile header/footer */
    }

    .chat-sidebar {
        width: 100%;
        border-right: none;
    }

    .chat-main {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        border-radius: var(--radius-lg);
        transform: translateX(100%);
        z-index: 10;
    }

    .chat-container.chat-active-mobile .chat-sidebar {
        transform: translateX(-100%);
    }

    .chat-container.chat-active-mobile .chat-main {
        transform: translateX(0);
    }

    .btn-chat-back {
        display: flex !important; /* Override inline none */
    }
}

/* ==========================================================================
   MOBILE RESPONSIVENESS & PWA STYLES
   ========================================================================== */
.mobile-header {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    background: var(--surface-bg);
    border-bottom: 1px solid var(--glass-border);
    z-index: 100;
}

.mobile-brand {
    display: flex;
    align-items: center;
    gap: 10px;
}

.mobile-brand h3 {
    font-size: 1.2rem;
    font-weight: 700;
    margin: 0;
}

.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-bottom: 1rem;
    border-radius: var(--radius-sm);
    box-shadow: inset 0 0 5px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    /* 1. Base Layout & Header */
    .mobile-header {
        display: flex;
    }
    #dashboard-screen {
        flex-direction: column;
    }
    .main-content {
        height: calc(100vh - 65px);
        padding: 12px;
        overflow-x: hidden;
    }

    /* 2. Sidebar Restyling for Mobile */
    .sidebar {
        position: fixed;
        left: -100%;
        top: 0;
        height: 100vh;
        width: 85vw;
        max-width: 320px;
        z-index: 9999;
        background: rgba(11, 12, 16, 0.98);
        backdrop-filter: blur(20px);
        transition: left 0.3s ease;
        border-right: 1px solid var(--glass-border);
    }
    .sidebar.active {
        left: 0;
    }

    /* 3. Grid & Layout overrides */
    .dashboard-row, 
    .stats-grid, 
    .target-progress-summary-grid {
        display: flex;
        flex-direction: column;
        grid-template-columns: 1fr;
        gap: 15px;
    }

    /* 4. Top Bar adjustments */
    .top-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
        margin-bottom: 20px;
    }
    
    .top-bar .btn, .header-actions .btn {
        width: 100%;
        justify-content: center;
    }

    /* 5. Tables & Horizontal Scrolling */
    .table-responsive {
        border: 1px solid var(--glass-border);
        border-radius: var(--radius-md);
        margin-bottom: 1.5rem;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    .table th, .table td {
        white-space: nowrap; /* Prevent squishing text */
        padding: 12px 15px;
    }

    /* 6. Modals Optimization */
    .modal-content {
        width: 95% !important;
        max-width: 100% !important;
        max-height: 85vh;
        overflow-y: auto;
        padding: 20px;
        margin: 10px auto;
    }
    
    /* 7. Forms, Buttons and Touch Targets */
    input, select, textarea, .btn {
        min-height: 44px; /* Touch friendly */
    }

    /* 8. Stopwatch Timer Scaling */
    #stopwatch-display, 
    #active-task-timer,
    .timer-display {
        font-size: clamp(3rem, 15vw, 5rem) !important;
        margin-bottom: 1rem;
    }

    /* 9. Cards and Container margins */
    .glass-card {
        padding: 15px;
    }
    .card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    .card-header .btn {
        width: 100%;
        margin-top: 5px;
    }

    /* 10. Specific Dashboard Adjustments */
    #admin-priority-alerts-banner .flex {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 15px;
    }
    #admin-priority-alerts-banner .flex-col {
        align-items: center;
    }
    #admin-priority-alerts-banner .btn {
        width: 100%;
        margin-top: 10px;
    }

    /* 11. Notification Dropdown Mobile Fix */
    .notification-dropdown {
        position: fixed;
        top: 70px;
        right: 15px;
        left: 15px;
        width: auto;
        max-width: none;
    }
}

/* ==========================================================================
   ENHANCED ACTIVE STOPWATCH & UI POLISH
   ========================================================================== */
.active-stopwatch-card {
    position: relative;
    overflow: hidden;
    background: linear-gradient(145deg, hsla(223, 47%, 15%, 0.8), hsla(223, 47%, 11%, 0.9)) !important;
    border: 1px solid hsla(322, 85%, 60%, 0.3) !important;
    box-shadow: 0 8px 32px hsla(322, 85%, 60%, 0.15), inset 0 1px 1px hsla(0,0%,100%,0.1) !important;
}

.active-stopwatch-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    box-shadow: inset 0 0 20px hsla(322, 85%, 60%, 0.1);
    pointer-events: none;
    border-radius: inherit;
}

.active-stopwatch-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
}

.active-stopwatch-details h3 {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 8px 0 4px 0;
    background: -webkit-linear-gradient(45deg, #fff, #a5b4fc);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.active-stopwatch-clock-controls {
    display: flex;
    align-items: center;
    gap: 16px;
}

.stopwatch-digits {
    font-family: 'SF Mono', 'Fira Code', 'Roboto Mono', monospace;
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--primary-light);
    text-shadow: 0 0 10px var(--primary-glow);
    background: hsla(223, 47%, 9%, 0.6);
    padding: 8px 20px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
}

.animate-pulse {
    animation: pulseGlow 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

@keyframes pulseGlow {
    0%, 100% { opacity: 1; box-shadow: 0 0 8px hsla(322, 85%, 60%, 0.4); }
    50% { opacity: .6; box-shadow: 0 0 2px hsla(322, 85%, 60%, 0.1); }
}

.btn {
    position: relative;
    overflow: hidden;
}

.btn:active {
    transform: scale(0.97) !important;
}

/* ==========================================================================
   TASK QUEUE ITEMS (Improves contrast in My Work Queue)
   ========================================================================== */
.tasks-queue-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.task-queue-item {
    background: hsla(223, 47%, 16%, 0.6);
    border: 1px solid hsla(0, 0%, 100%, 0.1);
    border-radius: var(--radius-md);
    padding: 20px;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast);
}

.task-queue-item:hover {
    background: hsla(223, 47%, 20%, 0.8);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px -4px rgba(0,0,0,0.3);
    border-color: hsla(0, 0%, 100%, 0.2);
}

.task-queue-item h4 {
    color: var(--text-primary);
    font-size: 1.1rem;
    font-weight: 700;
}

/* ==========================================================================
   LIGHT THEME OVERRIDES FOR HARDCODED DARK BACKGROUNDS
   ========================================================================== */
body.light-theme .stat-card {
    background: var(--surface-bg);
}
body.light-theme .stat-card:hover {
    background: var(--glass-bg-hover);
}

body.light-theme .glass-panel {
    background: var(--surface-bg) !important;
}

body.light-theme .active-stopwatch-card {
    background: var(--surface-bg) !important;
    border-color: var(--glass-border) !important;
    box-shadow: var(--shadow-soft) !important;
}
body.light-theme .active-stopwatch-card::before {
    box-shadow: none;
}
body.light-theme .active-stopwatch-details h3 {
    background: none;
    -webkit-text-fill-color: var(--text-primary);
    color: var(--text-primary);
}
body.light-theme .stopwatch-digits {
    background: var(--glass-bg);
    color: var(--primary-color);
    text-shadow: none;
}

body.light-theme .task-queue-item {
    background: var(--surface-bg);
    border-color: var(--glass-border);
}
body.light-theme .task-queue-item:hover {
    background: var(--glass-bg-hover);
    border-color: var(--primary-light);
}

body.light-theme .target-summary-card {
    background: var(--surface-bg);
}

body.light-theme .dashboard-row .glass-card {
    background: var(--surface-bg);
}

body.light-theme .standard-form input,
body.light-theme .standard-form select,
body.light-theme .standard-form textarea,
body.light-theme .login-form input {
    background: rgba(255, 255, 255, 0.6);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

body.light-theme .standard-form select option {
    background: #ffffff;
    color: var(--text-primary);
}

body.light-theme .standard-form input:focus,
body.light-theme .standard-form select:focus,
body.light-theme .standard-form textarea:focus,
body.light-theme .login-form input:focus {
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.2), inset 0 2px 4px rgba(0,0,0,0.05);
}
.toast-info { background: var(--info-color, hsl(200, 100%, 40%)); }


/* CLIENT VIEW SCOPED STYLES */
/* ============================================================
   UPPTICK CLIENT PORTAL — v4.0 — Minimal & Sophisticated
   Inspired by: Linear, Vercel, Notion dark
   No Tailwind. Pure CSS. Self-contained.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,300;0,14..32,400;0,14..32,500;0,14..32,600;0,14..32,700&display=swap');

/* ── TOKENS ── */
:root {
  --bg:          #09090f;
  --bg-card:     #111118;
  --bg-card-2:   #0e0e16;
  --sidebar-bg:  #0c0c13;
  --topbar-bg:   rgba(9,9,15,0.92);

  --primary:     #6366f1;
  --primary-10:  rgba(99,102,241,0.10);
  --primary-20:  rgba(99,102,241,0.20);
  --primary-dim: rgba(99,102,241,0.06);

  --success:     #22c55e;
  --success-10:  rgba(34,197,94,0.10);
  --warning:     #f59e0b;
  --warning-10:  rgba(245,158,11,0.10);
  --danger:      #ef4444;
  --danger-10:   rgba(239,68,68,0.10);

  /* Service palette */
  --s-creative:    #a855f7;
  --s-ppc:         #f59e0b;
  --s-seo:         #10b981;
  --s-social:      #38bdf8;
  --s-marketplace: #f97316;
  --s-development: #3b82f6;
  --s-general:     #64748b;

  --text:        #f0f0f8;
  --text-2:      #a0a0b8;
  --text-muted:  #5a5a72;

  --border:      rgba(255,255,255,0.06);
  --border-2:    rgba(255,255,255,0.10);

  --sidebar-w:   220px;
  --topbar-h:    56px;
  --radius:      8px;
  --radius-lg:   12px;

  --ease: cubic-bezier(0.25,0.46,0.45,0.94);
  --t:    all 0.2s var(--ease);

  --font: 'Inter', system-ui, -apple-system, sans-serif;
}
.client-view /* ── RESET ── */
*, .client-view *::before, .client-view *::after { box-sizing: border-box; margin: 0; padding: 0; }
.client-view html, .client-view body { height: 100%; width: 100%; }
.client-view body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 13.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
.client-view a { color: inherit; text-decoration: none; }
.client-view button, .client-view input, .client-view select, .client-view textarea {
  font-family: inherit;
  font-size: inherit;
}
.client-view /* ── SCROLLBAR ── */
::-webkit-scrollbar { width: 4px; }
.client-view ::-webkit-scrollbar-track { background: transparent; }
.client-view ::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); border-radius: 99px; }
.client-view ::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.15); }
.client-view /* ── UTILITY ── */
.hidden { display: none !important; }
.client-view /* ============================================================
   SCREEN SYSTEM
   ============================================================ */
.screen { display: none; width: 100%; height: 100vh; }
.client-view .screen.active { display: flex; }
.client-view /* ============================================================
   LOGIN SCREEN
   ============================================================ */
#login-screen {
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 600px 500px at 20% 10%, rgba(99,102,241,0.07) 0%, transparent 70%),
    radial-gradient(ellipse 400px 400px at 80% 90%, rgba(168,85,247,0.05) 0%, transparent 70%);
  align-items: center;
  justify-content: center;
}
.client-view .login-card {
  width: 100%;
  max-width: 380px;
  padding: 36px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
}
.client-view .login-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
}
.client-view .login-brand .brand-icon {
  width: 36px;
  height: 36px;
  background: var(--primary-10);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}
.client-view .login-brand h1 {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
}
.client-view .login-brand p {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 1px;
}
.client-view .login-heading {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}
.client-view .login-subheading {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}
.client-view /* ── FORM ── */
.form-group { margin-bottom: 14px; }
.client-view .form-group label {
  display: block;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-2);
  margin-bottom: 6px;
}
.client-view .form-group input, .client-view .form-group select, .client-view .form-group textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 9px 12px;
  color: var(--text);
  outline: none;
  transition: var(--t);
}
.client-view .form-group input::placeholder { color: var(--text-muted); }
.client-view .form-group input:focus, .client-view .form-group select:focus, .client-view .form-group textarea:focus {
  border-color: rgba(99,102,241,0.5);
  background: rgba(99,102,241,0.04);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.08);
}
.client-view .form-group textarea { resize: vertical; min-height: 80px; }
.client-view .form-group select {
  background-color: var(--bg-card-2);
  cursor: pointer;
}
.client-view /* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  font-size: 0.82rem;
  font-weight: 500;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--t);
  white-space: nowrap;
}
.client-view .btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.client-view .btn-primary:hover { background: #5254d8; border-color: #5254d8; }
.client-view .btn-outline {
  background: transparent;
  border-color: var(--border-2);
  color: var(--text-2);
}
.client-view .btn-outline:hover { border-color: rgba(255,255,255,0.2); color: var(--text); background: rgba(255,255,255,0.04); }
.client-view .btn-success { background: var(--success); color: #fff; }
.client-view .btn-success:hover { background: #16a34a; }
.client-view .btn-danger { background: var(--danger-10); color: var(--danger); border-color: rgba(239,68,68,0.25); }
.client-view .btn-sm { padding: 5px 10px; font-size: 0.76rem; border-radius: 6px; }
.client-view .btn-block { width: 100%; }
.client-view .btn svg, .client-view .btn [data-lucide] { width: 15px; height: 15px; }
.client-view /* ── LOADING SCREEN ── */
#loading-screen {
  background: var(--bg);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
}
.client-view .loader-icon {
  width: 48px;
  height: 48px;
  background: var(--primary-10);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  animation: pulse 2s ease infinite;
}
@keyframes pulse {
.client-view 0%, .client-view 100% { opacity: 1; transform: scale(1); }
.client-view 50% { opacity: 0.6; transform: scale(0.96); }
}
.client-view .loader-text h2 {
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 4px;
}
.client-view .loader-text p {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
}
.client-view .progress-bar-wrap {
  width: 200px;
  height: 2px;
  background: rgba(255,255,255,0.06);
  border-radius: 99px;
  overflow: hidden;
}
.client-view .progress-bar-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 99px;
  transition: width 0.3s var(--ease);
}
.client-view /* ============================================================
   WORKSPACE
   ============================================================ */
#workspace-screen { flex-direction: row; }
.client-view /* ── SIDEBAR ── */
.sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  height: 100vh;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.client-view .sidebar-header {
  padding: 16px 16px 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}
.client-view .sidebar-logo-icon {
  width: 30px;
  height: 30px;
  background: var(--primary-10);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}
.client-view .sidebar-logo-icon svg { width: 15px; height: 15px; }
.client-view .sidebar-logo-text strong {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
}
.client-view .sidebar-logo-text span {
  font-size: 0.65rem;
  color: var(--text-muted);
}
.client-view /* Client info section */
.sidebar-client {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}
.client-view .client-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.client-view .client-info-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.client-view .client-info-badge {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 600;
  color: var(--success);
  background: var(--success-10);
  border: 1px solid rgba(34,197,94,0.2);
  padding: 1px 6px;
  border-radius: 99px;
  margin-top: 2px;
}
.client-view /* Nav */
.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 8px;
}
.client-view .nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 450;
  cursor: pointer;
  transition: var(--t);
  border: 1px solid transparent;
  text-decoration: none;
  position: relative;
  user-select: none;
}
.client-view .nav-item svg { width: 15px; height: 15px; flex-shrink: 0; }
.client-view .nav-item:hover {
  color: var(--text-2);
  background: rgba(255,255,255,0.04);
  border-color: transparent;
}
.client-view .nav-item.active {
  color: var(--text);
  background: var(--primary-dim);
  border-color: rgba(99,102,241,0.15);
  font-weight: 500;
}
.client-view .nav-item.active svg { color: var(--primary); }
.client-view .nav-badge {
  margin-left: auto;
  background: var(--primary);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 99px;
  min-width: 18px;
  text-align: center;
}
.client-view .sidebar-section-label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 10px 10px 4px;
}
.client-view .sidebar-footer {
  padding: 12px 8px;
  border-top: 1px solid var(--border);
}
.client-view .sidebar-footer .btn {
  width: 100%;
  color: var(--text-muted);
  font-size: 0.78rem;
  justify-content: flex-start;
  padding: 7px 10px;
  gap: 8px;
}
.client-view .sidebar-footer .btn:hover { color: var(--danger); background: var(--danger-10); border-color: rgba(239,68,68,0.2); }
.client-view /* ── TOPBAR ── */
.topbar {
  height: var(--topbar-h);
  background: var(--topbar-bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  flex-shrink: 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.client-view .topbar-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
.client-view .topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}
.client-view .clock-chip {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 99px;
}
.client-view .clock-chip svg { width: 12px; height: 12px; }
.client-view /* ── MAIN ── */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  background: var(--bg);
}
.client-view .panel-container {
  flex: 1;
  overflow-y: auto;
  padding: 28px 28px;
}
.client-view /* ── PANELS ── */
.panel { display: none; animation: fadeIn 0.2s ease; }
.client-view .panel.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }
.client-view /* ── PAGE HEADER ── */
.page-header { margin-bottom: 24px; }
.client-view .page-header h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .page-header p { font-size: 0.8rem; color: var(--text-muted); }
.client-view .page-header-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.client-view .page-header-row h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .page-header-row p { font-size: 0.8rem; color: var(--text-muted); }
.client-view /* ── STAT GRID ── */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}
.client-view .stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  transition: var(--t);
}
.client-view .stat-card:hover { border-color: var(--border-2); }
.client-view .stat-card-label {
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.client-view .stat-card-label svg { width: 12px; height: 12px; }
.client-view .stat-card-value {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1;
}
.client-view .stat-card-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 4px;
}
.client-view /* Retainer card (wide) */
.retainer-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 24px;
}
.client-view .retainer-ring-wrap { position: relative; width: 80px; height: 80px; flex-shrink: 0; }
.client-view .retainer-ring-wrap svg { width: 80px; height: 80px; transform: rotate(-90deg); }
.client-view .retainer-ring-pct {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--text);
}
.client-view .retainer-info h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 4px;
}
.client-view .retainer-info p { font-size: 0.78rem; color: var(--text-muted); }
.client-view .retainer-services {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.client-view /* ── TABLE ── */
.data-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.client-view .data-table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.client-view .data-table-header h3 {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 7px;
}
.client-view .data-table-header h3 svg { width: 14px; height: 14px; color: var(--primary); }
.client-view table {
  width: 100%;
  border-collapse: collapse;
}
.client-view th {
  padding: 10px 16px;
  text-align: left;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border);
}
.client-view td {
  padding: 12px 16px;
  font-size: 0.82rem;
  color: var(--text-2);
  border-bottom: 1px solid rgba(255,255,255,0.03);
  vertical-align: middle;
}
.client-view tr:last-child td { border-bottom: none; }
.client-view tr:hover td { background: rgba(255,255,255,0.015); }
.client-view /* ── SECTION CARD ── */
.section-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 16px;
}
.client-view .section-card-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.client-view .section-card-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 7px;
}
.client-view .section-card-title svg { width: 14px; height: 14px; color: var(--primary); }
.client-view .section-card-body { padding: 16px 18px; }
.client-view .section-card-body-flush { }
.client-view /* ── TIMELINE FEED ── */
.timeline-feed { display: flex; flex-direction: column; gap: 0; }
.client-view .timeline-entry {
  display: flex;
  gap: 14px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  transition: var(--t);
}
.client-view .timeline-entry:last-child { border-bottom: none; }
.client-view .timeline-entry:hover { background: rgba(255,255,255,0.015); }
.client-view .timeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 5px;
}
.client-view .timeline-content { flex: 1; min-width: 0; }
.client-view .timeline-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .timeline-meta {
  font-size: 0.73rem;
  color: var(--text-muted);
}
.client-view /* ── BADGES / CHIPS ── */
.chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.client-view .service-chip { }
.client-view .status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
}
.client-view .status-new { background: var(--warning-10); color: var(--warning); }
.client-view .status-ack { background: rgba(59,130,246,0.1); color: #3b82f6; }
.client-view .status-replied { background: var(--success-10); color: var(--success); }
.client-view .status-task { background: rgba(168,85,247,0.1); color: #a855f7; }
.client-view /* ── DELIVERABLE GRID ── */
.deliverable-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.client-view .deliverable-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--t);
}
.client-view .deliverable-card:hover { border-color: var(--border-2); }
.client-view .deliverable-thumb {
  height: 100px;
  background: rgba(255,255,255,0.03);
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}
.client-view .deliverable-thumb svg { width: 28px; height: 28px; opacity: 0.4; }
.client-view .deliverable-info { padding: 12px 14px; }
.client-view .deliverable-info h4 {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.client-view .deliverable-info p {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.client-view .deliverable-actions { display: flex; gap: 6px; }
.client-view /* ── REQUEST CARDS ── */
.request-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid transparent;
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  margin-bottom: 10px;
  transition: var(--t);
}
.client-view .request-card:hover { border-right-color: var(--border-2); }
.client-view .request-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.client-view .request-card-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 4px;
}
.client-view .request-card-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
.client-view .request-card-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.5;
}
.client-view .request-reply-box {
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--primary-dim);
  border: 1px solid rgba(99,102,241,0.15);
  border-radius: var(--radius);
}
.client-view .request-reply-from {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 4px;
}
.client-view .request-reply-text {
  font-size: 0.78rem;
  color: var(--text-2);
}
.client-view /* ── TEAM STATUS GRID ── */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.client-view .team-member-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 16px;
  text-align: center;
  transition: var(--t);
}
.client-view .team-member-card:hover { border-color: var(--border-2); }
.client-view .team-member-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin: 0 auto 12px;
  position: relative;
}
.client-view .team-status-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--bg-card);
}
.client-view .dot-online { background: var(--success); }
.client-view .dot-offline { background: var(--text-muted); }
.client-view .dot-leave { background: var(--warning); }
.client-view .team-member-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .team-member-role { font-size: 0.72rem; color: var(--text-muted); }
.client-view /* ── EMPTY STATE ── */
.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: var(--text-muted);
}
.client-view .empty-state svg {
  width: 40px;
  height: 40px;
  margin: 0 auto 12px;
  opacity: 0.3;
}
.client-view .empty-state h3 {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 4px;
}
.client-view .empty-state p { font-size: 0.78rem; }
.client-view /* ── DIVIDER ── */
.divider { border: none; border-top: 1px solid var(--border); margin: 20px 0; }
.client-view /* ── FILTER ROW ── */
.filter-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.client-view .filter-row select {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 6px 10px;
  color: var(--text-2);
  font-size: 0.78rem;
  outline: none;
  cursor: pointer;
  transition: var(--t);
}
.client-view .filter-row select:focus { border-color: rgba(99,102,241,0.5); }
.client-view /* ── MODAL ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease);
}
.client-view .modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.client-view .modal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 460px;
  transform: translateY(8px);
  transition: transform 0.2s var(--ease);
}
.client-view .modal-overlay.open .modal-box { transform: translateY(0); }
.client-view .modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.client-view .modal-header h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
}
.client-view .modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  transition: var(--t);
}
.client-view .modal-close:hover { color: var(--text); background: rgba(255,255,255,0.06); }
.client-view .modal-close svg { width: 16px; height: 16px; }
.client-view .modal-body { padding: 20px; }
.client-view .modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}
.client-view /* ── TOAST ── */
.toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.client-view .toast {
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-weight: 500;
  color: #fff;
  pointer-events: all;
  border: 1px solid rgba(255,255,255,0.1);
  transform: translateX(110%);
  opacity: 0;
  transition: all 0.3s var(--ease);
  max-width: 300px;
}
.client-view .toast.show { transform: translateX(0); opacity: 1; }
.client-view .toast-success { background: #16a34a; border-color: rgba(34,197,94,0.3); }
.client-view .toast-error { background: #dc2626; border-color: rgba(239,68,68,0.3); }
.client-view .toast-warning { background: #d97706; border-color: rgba(245,158,11,0.3); }
.client-view .toast-info { background: #2563eb; }
.client-view /* ── SCROLLABLE TABLE WRAP ── */
.table-scroll { overflow-x: auto; }


/* ========================================= */
/* CLIENT PORTAL SCOPED STYLES */
/* ========================================= */

/* ============================================================
   UPPTICK CLIENT PORTAL — v4.0 — Minimal & Sophisticated
   Inspired by: Linear, Vercel, Notion dark
   No Tailwind. Pure CSS. Self-contained.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,300;0,14..32,400;0,14..32,500;0,14..32,600;0,14..32,700&display=swap');

/* ── TOKENS ── */
:root {
  --bg:          #09090f;
  --bg-card:     #111118;
  --bg-card-2:   #0e0e16;
  --sidebar-bg:  #0c0c13;
  --topbar-bg:   rgba(9,9,15,0.92);

  --primary:     #6366f1;
  --primary-10:  rgba(99,102,241,0.10);
  --primary-20:  rgba(99,102,241,0.20);
  --primary-dim: rgba(99,102,241,0.06);

  --success:     #22c55e;
  --success-10:  rgba(34,197,94,0.10);
  --warning:     #f59e0b;
  --warning-10:  rgba(245,158,11,0.10);
  --danger:      #ef4444;
  --danger-10:   rgba(239,68,68,0.10);

  /* Service palette */
  --s-creative:    #a855f7;
  --s-ppc:         #f59e0b;
  --s-seo:         #10b981;
  --s-social:      #38bdf8;
  --s-marketplace: #f97316;
  --s-development: #3b82f6;
  --s-general:     #64748b;

  --text:        #f0f0f8;
  --text-2:      #a0a0b8;
  --text-muted:  #5a5a72;

  --border:      rgba(255,255,255,0.06);
  --border-2:    rgba(255,255,255,0.10);

  --sidebar-w:   220px;
  --topbar-h:    56px;
  --radius:      8px;
  --radius-lg:   12px;

  --ease: cubic-bezier(0.25,0.46,0.45,0.94);
  --t:    all 0.2s var(--ease);

  --font: 'Inter', system-ui, -apple-system, sans-serif;
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
.client-view html, .client-view body { height: 100%; width: 100%; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 13.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
.client-view a { color: inherit; text-decoration: none; }
.client-view button, .client-view input, .client-view select, .client-view textarea {
  font-family: inherit;
  font-size: inherit;
}

/* ── SCROLLBAR ── */
.client-view ::-webkit-scrollbar { width: 4px; }
.client-view ::-webkit-scrollbar-track { background: transparent; }
.client-view ::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); border-radius: 99px; }
.client-view ::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.15); }

/* ── UTILITY ── */
.client-view .hidden { display: none !important; }

/* ============================================================
   SCREEN SYSTEM
   ============================================================ */
.client-view .screen { display: none; width: 100%; height: 100vh; }
.client-view .screen.active { display: flex; }

/* ============================================================
   LOGIN SCREEN
   ============================================================ */
.client-view #login-screen {
  background: var(--bg);
  background-image:
    radial-gradient(ellipse 600px 500px at 20% 10%, rgba(99,102,241,0.07) 0%, transparent 70%),
    radial-gradient(ellipse 400px 400px at 80% 90%, rgba(168,85,247,0.05) 0%, transparent 70%);
  align-items: center;
  justify-content: center;
}

.client-view .login-card {
  width: 100%;
  max-width: 380px;
  padding: 36px 32px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
}

.client-view .login-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
}

.client-view .login-brand .brand-icon {
  width: 36px;
  height: 36px;
  background: var(--primary-10);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}

.client-view .login-brand h1 {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--text);
}
.client-view .login-brand p {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 1px;
}

.client-view .login-heading {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}
.client-view .login-subheading {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

/* ── FORM ── */
.client-view .form-group { margin-bottom: 14px; }
.client-view .form-group label {
  display: block;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--text-2);
  margin-bottom: 6px;
}
.form-group input,
.form-group select,
.client-view .form-group textarea {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 9px 12px;
  color: var(--text);
  outline: none;
  transition: var(--t);
}
.client-view .form-group input::placeholder { color: var(--text-muted); }
.form-group input:focus,
.form-group select:focus,
.client-view .form-group textarea:focus {
  border-color: rgba(99,102,241,0.5);
  background: rgba(99,102,241,0.04);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.08);
}
.client-view .form-group textarea { resize: vertical; min-height: 80px; }
.client-view .form-group select {
  background-color: var(--bg-card-2);
  cursor: pointer;
}

/* ── BUTTONS ── */
.client-view .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  font-size: 0.82rem;
  font-weight: 500;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--t);
  white-space: nowrap;
}
.client-view .btn-primary {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.client-view .btn-primary:hover { background: #5254d8; border-color: #5254d8; }
.client-view .btn-outline {
  background: transparent;
  border-color: var(--border-2);
  color: var(--text-2);
}
.client-view .btn-outline:hover { border-color: rgba(255,255,255,0.2); color: var(--text); background: rgba(255,255,255,0.04); }
.client-view .btn-success { background: var(--success); color: #fff; }
.client-view .btn-success:hover { background: #16a34a; }
.client-view .btn-danger { background: var(--danger-10); color: var(--danger); border-color: rgba(239,68,68,0.25); }
.client-view .btn-sm { padding: 5px 10px; font-size: 0.76rem; border-radius: 6px; }
.client-view .btn-block { width: 100%; }
.client-view .btn svg, .client-view .btn [data-lucide] { width: 15px; height: 15px; }

/* ── LOADING SCREEN ── */
.client-view #loading-screen {
  background: var(--bg);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 16px;
}
.client-view .loader-icon {
  width: 48px;
  height: 48px;
  background: var(--primary-10);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  animation: pulse 2s ease infinite;
}
@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.96); }
}
.client-view .loader-text h2 {
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  margin-bottom: 4px;
}
.client-view .loader-text p {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-align: center;
}
.client-view .progress-bar-wrap {
  width: 200px;
  height: 2px;
  background: rgba(255,255,255,0.06);
  border-radius: 99px;
  overflow: hidden;
}
.client-view .progress-bar-fill {
  height: 100%;
  background: var(--primary);
  border-radius: 99px;
  transition: width 0.3s var(--ease);
}

/* ============================================================
   WORKSPACE
   ============================================================ */
.client-view #client-workspace { flex-direction: row; }

/* ── SIDEBAR ── */
.client-view .sidebar {
  width: var(--sidebar-w);
  min-width: var(--sidebar-w);
  height: 100vh;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.client-view .sidebar-header {
  padding: 16px 16px 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}
.client-view .sidebar-logo-icon {
  width: 30px;
  height: 30px;
  background: var(--primary-10);
  border: 1px solid rgba(99,102,241,0.2);
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
  flex-shrink: 0;
}
.client-view .sidebar-logo-icon svg { width: 15px; height: 15px; }
.client-view .sidebar-logo-text strong {
  display: block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text);
}
.client-view .sidebar-logo-text span {
  font-size: 0.65rem;
  color: var(--text-muted);
}

/* Client info section */
.client-view .sidebar-client {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 10px;
}
.client-view .client-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
  flex-shrink: 0;
}
.client-view .client-info-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.client-view .client-info-badge {
  display: inline-block;
  font-size: 0.62rem;
  font-weight: 600;
  color: var(--success);
  background: var(--success-10);
  border: 1px solid rgba(34,197,94,0.2);
  padding: 1px 6px;
  border-radius: 99px;
  margin-top: 2px;
}

/* Nav */
.client-view .sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 8px;
}
.client-view .nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 450;
  cursor: pointer;
  transition: var(--t);
  border: 1px solid transparent;
  text-decoration: none;
  position: relative;
  user-select: none;
}
.client-view .nav-item svg { width: 15px; height: 15px; flex-shrink: 0; }
.client-view .nav-item:hover {
  color: var(--text-2);
  background: rgba(255,255,255,0.04);
  border-color: transparent;
}
.client-view .nav-item.active {
  color: var(--text);
  background: var(--primary-dim);
  border-color: rgba(99,102,241,0.15);
  font-weight: 500;
}
.client-view .nav-item.active svg { color: var(--primary); }
.client-view .nav-badge {
  margin-left: auto;
  background: var(--primary);
  color: #fff;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 99px;
  min-width: 18px;
  text-align: center;
}

.client-view .sidebar-section-label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  padding: 10px 10px 4px;
}

.client-view .sidebar-footer {
  padding: 12px 8px;
  border-top: 1px solid var(--border);
}
.client-view .sidebar-footer .btn {
  width: 100%;
  color: var(--text-muted);
  font-size: 0.78rem;
  justify-content: flex-start;
  padding: 7px 10px;
  gap: 8px;
}
.client-view .sidebar-footer .btn:hover { color: var(--danger); background: var(--danger-10); border-color: rgba(239,68,68,0.2); }

/* ── TOPBAR ── */
.client-view .topbar {
  height: var(--topbar-h);
  background: var(--topbar-bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  flex-shrink: 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.client-view .topbar-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
.client-view .topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}
.client-view .clock-chip {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.75rem;
  color: var(--text-muted);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 99px;
}
.client-view .clock-chip svg { width: 12px; height: 12px; }

/* ── MAIN ── */
.client-view .main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  background: var(--bg);
}
.client-view .panel-container {
  flex: 1;
  overflow-y: auto;
  padding: 28px 28px;
}

/* ── PANELS ── */
.client-view .panel { display: none; animation: fadeIn 0.2s ease; }
.client-view .panel.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

/* ── PAGE HEADER ── */
.page-header { margin-bottom: 24px; }
.page-header h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .page-header p { font-size: 0.8rem; color: var(--text-muted); }

.client-view .page-header-row {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.client-view .page-header-row h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .page-header-row p { font-size: 0.8rem; color: var(--text-muted); }

/* ── STAT GRID ── */
.client-view .stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.client-view .stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px 20px;
  transition: var(--t);
}
.client-view .stat-card:hover { border-color: var(--border-2); }
.client-view .stat-card-label {
  font-size: 0.72rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 5px;
}
.client-view .stat-card-label svg { width: 12px; height: 12px; }
.client-view .stat-card-value {
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.02em;
  line-height: 1;
}
.client-view .stat-card-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Retainer card (wide) */
.client-view .retainer-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 24px;
}
.client-view .retainer-ring-wrap { position: relative; width: 80px; height: 80px; flex-shrink: 0; }
.client-view .retainer-ring-wrap svg { width: 80px; height: 80px; transform: rotate(-90deg); }
.client-view .retainer-ring-pct {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  font-weight: 800;
  color: var(--text);
}
.client-view .retainer-info h3 {
  font-size: 0.95rem;
  font-weight: 700;
  margin-bottom: 4px;
}
.client-view .retainer-info p { font-size: 0.78rem; color: var(--text-muted); }
.client-view .retainer-services {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}

/* ── TABLE ── */
.client-view .data-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.client-view .data-table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}
.client-view .data-table-header h3 {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 7px;
}
.client-view .data-table-header h3 svg { width: 14px; height: 14px; color: var(--primary); }
.client-view table {
  width: 100%;
  border-collapse: collapse;
}
.client-view th {
  padding: 10px 16px;
  text-align: left;
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  background: rgba(255,255,255,0.02);
  border-bottom: 1px solid var(--border);
}
.client-view td {
  padding: 12px 16px;
  font-size: 0.82rem;
  color: var(--text-2);
  border-bottom: 1px solid rgba(255,255,255,0.03);
  vertical-align: middle;
}
.client-view tr:last-child td { border-bottom: none; }
.client-view tr:hover td { background: rgba(255,255,255,0.015); }

/* ── SECTION CARD ── */
.client-view .section-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 16px;
}
.client-view .section-card-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.client-view .section-card-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 7px;
}
.client-view .section-card-title svg { width: 14px; height: 14px; color: var(--primary); }
.client-view .section-card-body { padding: 16px 18px; }
.client-view .section-card-body-flush { }

/* ── TIMELINE FEED ── */
.client-view .timeline-feed { display: flex; flex-direction: column; gap: 0; }
.client-view .timeline-entry {
  display: flex;
  gap: 14px;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.03);
  transition: var(--t);
}
.client-view .timeline-entry:last-child { border-bottom: none; }
.client-view .timeline-entry:hover { background: rgba(255,255,255,0.015); }
.client-view .timeline-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 5px;
}
.client-view .timeline-content { flex: 1; min-width: 0; }
.client-view .timeline-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .timeline-meta {
  font-size: 0.73rem;
  color: var(--text-muted);
}

/* ── BADGES / CHIPS ── */
.client-view .chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.client-view .service-chip { }

.client-view .status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 600;
}
.client-view .status-new { background: var(--warning-10); color: var(--warning); }
.client-view .status-ack { background: rgba(59,130,246,0.1); color: #3b82f6; }
.client-view .status-replied { background: var(--success-10); color: var(--success); }
.client-view .status-task { background: rgba(168,85,247,0.1); color: #a855f7; }

/* ── DELIVERABLE GRID ── */
.client-view .deliverable-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.client-view .deliverable-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: var(--t);
}
.client-view .deliverable-card:hover { border-color: var(--border-2); }
.client-view .deliverable-thumb {
  height: 100px;
  background: rgba(255,255,255,0.03);
  display: flex;
  align-items: center;
  justify-content: center;
  border-bottom: 1px solid var(--border);
  color: var(--text-muted);
}
.client-view .deliverable-thumb svg { width: 28px; height: 28px; opacity: 0.4; }
.client-view .deliverable-info { padding: 12px 14px; }
.client-view .deliverable-info h4 {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.client-view .deliverable-info p {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.client-view .deliverable-actions { display: flex; gap: 6px; }

/* ── REQUEST CARDS ── */
.client-view .request-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 3px solid transparent;
  border-radius: var(--radius-lg);
  padding: 16px 18px;
  margin-bottom: 10px;
  transition: var(--t);
}
.client-view .request-card:hover { border-right-color: var(--border-2); }
.client-view .request-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.client-view .request-card-meta {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 4px;
}
.client-view .request-card-title {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text);
}
.client-view .request-card-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.5;
}
.client-view .request-reply-box {
  margin-top: 10px;
  padding: 10px 12px;
  background: var(--primary-dim);
  border: 1px solid rgba(99,102,241,0.15);
  border-radius: var(--radius);
}
.client-view .request-reply-from {
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 4px;
}
.client-view .request-reply-text {
  font-size: 0.78rem;
  color: var(--text-2);
}

/* ── TEAM STATUS GRID ── */
.client-view .team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 12px;
}
.client-view .team-member-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 16px;
  text-align: center;
  transition: var(--t);
}
.client-view .team-member-card:hover { border-color: var(--border-2); }
.client-view .team-member-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #a855f7);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  margin: 0 auto 12px;
  position: relative;
}
.client-view .team-status-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid var(--bg-card);
}
.client-view .dot-online { background: var(--success); }
.client-view .dot-offline { background: var(--text-muted); }
.client-view .dot-leave { background: var(--warning); }
.client-view .team-member-name {
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 3px;
}
.client-view .team-member-role { font-size: 0.72rem; color: var(--text-muted); }

/* ── EMPTY STATE ── */
.client-view .empty-state {
  padding: 48px 24px;
  text-align: center;
  color: var(--text-muted);
}
.client-view .empty-state svg {
  width: 40px;
  height: 40px;
  margin: 0 auto 12px;
  opacity: 0.3;
}
.client-view .empty-state h3 {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 4px;
}
.client-view .empty-state p { font-size: 0.78rem; }

/* ── DIVIDER ── */
.client-view .divider { border: none; border-top: 1px solid var(--border); margin: 20px 0; }

/* ── FILTER ROW ── */
.client-view .filter-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.client-view .filter-row select {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  padding: 6px 10px;
  color: var(--text-2);
  font-size: 0.78rem;
  outline: none;
  cursor: pointer;
  transition: var(--t);
}
.client-view .filter-row select:focus { border-color: rgba(99,102,241,0.5); }

/* ── MODAL ── */
.client-view .modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s var(--ease);
}
.client-view .modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}
.client-view .modal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 460px;
  transform: translateY(8px);
  transition: transform 0.2s var(--ease);
}
.client-view .modal-overlay.open .modal-box { transform: translateY(0); }
.client-view .modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.client-view .modal-header h3 {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text);
}
.client-view .modal-close {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  transition: var(--t);
}
.client-view .modal-close:hover { color: var(--text); background: rgba(255,255,255,0.06); }
.client-view .modal-close svg { width: 16px; height: 16px; }
.client-view .modal-body { padding: 20px; }
.client-view .modal-footer {
  padding: 14px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

/* ── TOAST ── */
.client-view .toast-container {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}
.client-view .toast {
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 0.78rem;
  font-weight: 500;
  color: #fff;
  pointer-events: all;
  border: 1px solid rgba(255,255,255,0.1);
  transform: translateX(110%);
  opacity: 0;
  transition: all 0.3s var(--ease);
  max-width: 300px;
}
.client-view .toast.show { transform: translateX(0); opacity: 1; }
.client-view .toast-success { background: #16a34a; border-color: rgba(34,197,94,0.3); }
.client-view .toast-error { background: #dc2626; border-color: rgba(239,68,68,0.3); }
.client-view .toast-warning { background: #d97706; border-color: rgba(245,158,11,0.3); }
.client-view .toast-info { background: #2563eb; }

/* ── SCROLLABLE TABLE WRAP ── */
.client-view .table-scroll { overflow-x: auto; }
