/* ==========================================================================
   Base & Reset
   ========================================================================== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    /* Color Palette */
    --color-bg: #f8fafc;
    --color-surface: #ffffff;
    --color-text-primary: #0f172a;
    --color-text-secondary: #475569;
    --color-text-muted: #64748b;
    --color-border: #cbd5e1;
    --color-border-hover: #94a3b8;
    
    /* Primary Brand Colors */
    --color-primary: #2563eb;
    --color-primary-hover: #1d4ed8;
    --color-primary-active: #1e40af;
    --color-primary-contrast: #ffffff;
    --color-primary-focus: rgba(37, 99, 235, 0.25);

    /* Feedback Colors */
    --color-danger: #dc2626;
    --color-danger-bg: #fef2f2;
    --color-danger-border: #fecaca;
    --color-success: #16a34a;
    --color-success-bg: #f0fdf4;
    --color-success-border: #bbf7d0;

    /* Typography & Layout */
    --font-family: system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --font-size-sm: 0.875rem;
    --font-size-base: 1rem;
    --font-size-lg: 1.125rem;
    --font-size-xl: 1.5rem;
    --font-weight-regular: 400;
    --font-weight-medium: 500;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;

    /* Radius & Shadows */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);

    /* Transitions */
    --transition-speed: 150ms;
}

body {
    font-family: var(--font-family);
    background-color: var(--color-bg);
    color: var(--color-text-primary);
    line-height: 1.5;
    min-height: 100vh;
}

/* ==========================================================================
   Layout & Container
   ========================================================================== */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
}

.login-card {
    width: 100%;
    max-width: 28rem;
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: 2.5rem 2rem;
}

/* ==========================================================================
   Header
   ========================================================================== */
.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-title {
    font-size: var(--font-size-xl);
    font-weight: var(--font-weight-bold);
    color: var(--color-text-primary);
    margin-bottom: 0.5rem;
}

.login-subtitle {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
}

/* ==========================================================================
   Alerts (Session Messages)
   ========================================================================== */
.alert {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    font-size: var(--font-size-sm);
    margin-bottom: 1.5rem;
}

.alert-success {
    background-color: var(--color-success-bg);
    border: 1px solid var(--color-success-border);
    color: var(--color-success);
}

.alert-error {
    background-color: var(--color-danger-bg);
    border: 1px solid var(--color-danger-border);
    color: var(--color-danger);
}

/* ==========================================================================
   Form Elements
   ========================================================================== */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.form-label {
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    color: var(--color-text-primary);
}

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

.forgot-password-link {
    font-size: var(--font-size-sm);
    color: var(--color-primary);
    text-decoration: none;
    font-weight: var(--font-weight-medium);
    border-radius: var(--radius-sm);
}

.forgot-password-link:hover {
    text-decoration: underline;
    color: var(--color-primary-hover);
}

.forgot-password-link:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Text & Password Inputs */
.form-input {
    width: 100%;
    padding: 0.625rem 0.875rem;
    font-size: var(--font-size-base);
    color: var(--color-text-primary);
    background-color: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    transition: border-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease;
}

.form-input:hover {
    border-color: var(--color-border-hover);
}

.form-input:focus-visible {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px var(--color-primary-focus);
}

.form-input.is-invalid {
    border-color: var(--color-danger);
}

.form-input.is-invalid:focus-visible {
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.2);
}

/* Password Input Wrapper & Toggle Button */
.password-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrapper .form-input {
    padding-right: 4.25rem;
}

.password-toggle-btn {
    position: absolute;
    right: 0.5rem;
    padding: 0.375rem 0.625rem;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--color-text-secondary);
    font-size: var(--font-size-sm);
    font-weight: var(--font-weight-medium);
    cursor: pointer;
    transition: color var(--transition-speed) ease, background-color var(--transition-speed) ease;
}

.password-toggle-btn:hover {
    color: var(--color-text-primary);
    background-color: var(--color-bg);
}

.password-toggle-btn:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Error Messages */
.error-message {
    font-size: var(--font-size-sm);
    color: var(--color-danger);
    min-height: 1.25rem;
}

.error-message:empty {
    display: none;
}

/* Checkbox (Remember Me) */
.form-check {
    flex-direction: row;
    align-items: center;
    gap: 0.5rem;
}

.form-check-input {
    width: 1rem;
    height: 1rem;
    accent-color: var(--color-primary);
    cursor: pointer;
    border-radius: var(--radius-sm);
}

.form-check-input:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.form-check-label {
    font-size: var(--font-size-sm);
    color: var(--color-text-secondary);
    cursor: pointer;
    user-select: none;
}

/* ==========================================================================
   Submit Button & States
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 0.75rem 1.25rem;
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-semibold);
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: background-color var(--transition-speed) ease, box-shadow var(--transition-speed) ease, opacity var(--transition-speed) ease;
}

.btn-primary {
    background-color: var(--color-primary);
    color: var(--color-primary-contrast);
}

.btn-primary:hover:not(:disabled) {
    background-color: var(--color-primary-hover);
}

.btn-primary:active:not(:disabled) {
    background-color: var(--color-primary-active);
}

.btn-primary:focus-visible {
    outline: 2px solid var(--color-primary-hover);
    outline-offset: 2px;
}

.btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
}

/* Loading State */
.btn-loader {
    display: none;
    width: 1rem;
    height: 1rem;
    border: 2px solid currentColor;
    border-right-color: transparent;
    border-radius: 50%;
    animation: btn-spin 0.6s linear infinite;
}

.btn.is-loading .btn-loader {
    display: inline-block;
}

@keyframes btn-spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   Accessibility & Preferences
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Responsive adjustments for smaller screens */
@media (max-width: 480px) {
    .login-wrapper {
        padding: 1rem;
    }

    .login-card {
        padding: 1.75rem 1.25rem;
    }

    .login-title {
        font-size: 1.25rem;
    }
}


/* ==========================================================================
   Dashboard Shell & Floating Pill Sidebar (Exact Light Dribbble Design)
   ========================================================================== */

.app-layout {
    display: flex;
    min-height: 100vh;
    background-color: #f1f2f4;
}

.app-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* ==========================================================================
   Sidebar Component (Exact White Floating Pill)
   ========================================================================== */
.sidebar {
    width: 254px;
    height: calc(100vh - 28px);
    position: sticky;
    top: 14px;
    background-color: #ffffff;
    border-radius: 38px;
    margin: 14px 0 14px 14px;
    display: flex;
    flex-direction: column;
    padding: 24px 16px 16px 16px;
    flex-shrink: 0;
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.04);
    border: 1px solid rgba(0, 0, 0, 0.04);
    transition: width 0.38s cubic-bezier(0.16, 1, 0.3, 1), padding 0.38s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 100;
    overflow: visible;
}

/* Collapsed Sidebar State */
.sidebar.collapsed {
    width: 76px;
    padding: 24px 12px 16px 12px;
    overflow: visible !important;
}

.sidebar.collapsed .sidebar-menu-wrapper,
.sidebar.collapsed .menu-section,
.sidebar.collapsed .nav-tree {
    overflow: visible !important;
}

/* Floating Edge Toggle Button */
.sidebar-edge-toggle {
    position: absolute;
    right: -10px;
    top: 34px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background-color: #ffffff;
    border: 1.5px solid #e5e7eb;
    color: #9da3af;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
    transition: background-color 0.15s ease, color 0.15s ease, transform 0.38s cubic-bezier(0.16, 1, 0.3, 1);
}

.sidebar-edge-toggle:hover {
    background-color: #f9fafb;
    color: #111215;
    border-color: #d1d5db;
}

.sidebar-edge-toggle:focus-visible {
    outline: 2px solid #111215;
    outline-offset: 2px;
}

.sidebar.collapsed .sidebar-edge-toggle .toggle-icon {
    transform: rotate(180deg);
}

/* Header & Star Logo */
.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 22px;
}

.brand-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.brand-sparkle-icon {
    color: #111215;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Search Box */
.sidebar-search {
    margin-bottom: 22px;
}

.search-box {
    background-color: #ffffff;
    border-radius: 18px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid #e7eaee;
    transition: width 0.38s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.15s ease, border-color 0.15s ease;
}

.search-box:hover {
    background-color: #f9fafb;
    border-color: #d1d5db;
}

.search-icon {
    color: #9ca3af;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.search-input {
    background: transparent;
    border: none;
    outline: none;
    color: #374151;
    font-size: 13px;
    width: 100%;
    font-family: inherit;
    cursor: default;
}

.search-input::placeholder {
    color: #9ca3af;
}

.search-shortcuts {
    display: flex;
    gap: 3px;
    align-items: center;
    margin-left: auto;
}

.shortcut-key {
    font-family: inherit;
    font-size: 10px;
    font-weight: 600;
    color: #9ca3af;
    background: #ffffff;
    border-radius: 5px;
    padding: 2px 5px;
    line-height: 1;
    border: 1px solid #e5e7eb;
}

/* Collapsed Search Icon (Matches Image!) */
.sidebar.collapsed .search-box {
    width: 44px;
    height: 44px;
    border-radius: 16px;
    padding: 0;
    justify-content: center;
    margin: 0 auto;
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
}

.sidebar.collapsed .search-box:hover {
    background-color: #f9fafb;
    border-color: #d1d5db;
}

.sidebar.collapsed .search-icon {
    color: #6b7280;
}

.sidebar.collapsed .search-input,
.sidebar.collapsed .search-shortcuts {
    display: none;
}

/* Scrollable Menu Area */
.sidebar-menu-wrapper {
    display: flex;
    flex-direction: column;
    gap: 22px;
    flex: 1;
    overflow-y: auto;
    overflow-x: visible;
    scrollbar-width: none;
}

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

.menu-section {
    display: flex;
    flex-direction: column;
}

.section-heading {
    color: #a0a5b1;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.08em;
    display: block;
    margin-bottom: 8px;
    padding-left: 8px;
    text-transform: uppercase;
}

.sidebar.collapsed .section-heading {
    text-align: center;
    padding-left: 0;
    font-size: 9.5px;
    margin-bottom: 12px;
}

/* Nav Tree Rows */
.nav-tree {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-tree-item {
    position: relative;
}

.nav-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    border-radius: 14px;
    color: #4b5563;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-row:hover {
    color: #111215;
    background-color: #f7f8fa;
}

/* Active Parent / Dashboard Pill */
.nav-tree-item.active-parent > .nav-row {
    background-color: #f7f8fa;
    color: #111215;
    font-weight: 600;
}

.row-icon {
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: currentColor;
}

.row-text {
    white-space: nowrap;
}

.row-chevron {
    margin-left: auto;
    color: #9ca3af;
    display: flex;
    align-items: center;
}

/* Collapsed Nav Row - Matches 4-square in Image */
.sidebar.collapsed .nav-row {
    width: 44px;
    height: 44px;
    padding: 0;
    justify-content: center;
    border-radius: 16px;
    margin: 0 auto;
}

.sidebar.collapsed .nav-tree-item.active-parent > .nav-row {
    background-color: #f5f6f8;
    color: #111215;
}

.sidebar.collapsed .row-text,
.sidebar.collapsed .row-chevron {
    display: none;
}

.submenu-toggle-btn {
    width: 100%;
    border: none;
    background: transparent;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
}

/* Submenu Tree Branch */
.tree-branch-container {
    margin-left: 20px;
    padding-left: 14px;
    border-left: 1.5px solid #e5e7eb;
    margin-top: 4px;
    margin-bottom: 6px;
    position: relative;
    max-height: 250px;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.2s ease, margin 0.2s ease;
}

.nav-tree-item.collapsed-submenu .tree-branch-container {
    max-height: 0;
    opacity: 0;
    margin-top: 0;
    margin-bottom: 0;
    pointer-events: none;
}

.row-chevron svg {
    transition: transform 0.25s ease;
}

.nav-tree-item.collapsed-submenu .row-chevron svg {
    transform: rotate(180deg);
}

.tree-sub-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.tree-sub-item {
    position: relative;
}

.tree-sub-item::before {
    content: '';
    position: absolute;
    left: -14px;
    top: 50%;
    width: 10px;
    height: 1.5px;
    background-color: #e5e7eb;
}

.tree-sub-link {
    display: block;
    padding: 6px 12px;
    border-radius: 10px;
    color: #6b7280;
    font-size: 12.5px;
    text-decoration: none;
    font-weight: 400;
    transition: all 0.15s ease;
}

.tree-sub-link:hover {
    color: #111215;
}

.tree-sub-link.active {
    background-color: #f7f8fa;
    color: #111215;
    font-weight: 600;
}

/* Hide submenu tree when sidebar is collapsed */
.sidebar.collapsed .tree-branch-container {
    display: none;
}

/* Messages Section */
.section-heading-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-left: 8px;
    padding-right: 4px;
    margin-bottom: 8px;
}

.section-heading-row .section-heading {
    margin-bottom: 0;
    padding-left: 0;
}

.section-add-btn {
    background: transparent;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
    transition: color 0.15s ease;
}

.section-add-btn:hover {
    color: #111215;
}

.contacts-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.contact-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 4px 8px;
    border-radius: 10px;
    text-decoration: none;
    transition: background-color 0.15s ease;
}

.contact-link:hover {
    background-color: #f7f8fa;
}

.contact-avatar-wrapper {
    position: relative;
    width: 26px;
    height: 26px;
    flex-shrink: 0;
}

.contact-avatar {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: cover;
    display: block;
}

.contact-status-dot {
    position: absolute;
    bottom: -1px;
    right: -1px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    border: 1.5px solid #ffffff;
}

.contact-status-dot.online {
    background-color: #10b981;
}

.contact-status-dot.busy {
    background-color: #ef4444;
}

.contact-name {
    color: #4b5563;
    font-size: 13px;
    font-weight: 500;
    white-space: nowrap;
}

.sidebar.collapsed .contacts-list {
    gap: 12px;
    align-items: center;
}

.sidebar.collapsed .contact-link {
    padding: 0;
    justify-content: center;
}

.sidebar.collapsed .contact-name,
.sidebar.collapsed .section-add-btn {
    display: none;
}

/* Sidebar Bottom & User Profile */
.sidebar-bottom {
    margin-top: auto;
    padding-top: 14px;
}

.profile-card {
    background-color: #ffffff;
    border-radius: 20px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #e7eaee;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease;
}

.profile-card:hover {
    background-color: #f9fafb;
    border-color: #d1d5db;
}

.profile-avatar-wrap {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.profile-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.profile-info {
    display: flex;
    flex-direction: column;
    gap: 1px;
    flex: 1;
    overflow: hidden;
}

.profile-initial,
.navbar-initial {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #315b8a;
    background: linear-gradient(135deg, #e9f3ff, #d8eaff);
    border: 1px solid #cfe5ff;
    border-radius: 50%;
    font-weight: 700;
}

.profile-initial {
    width: 2rem;
    height: 2rem;
    font-size: 0.8rem;
}

.profile-name {
    color: #111215;
    font-size: 12.5px;
    font-weight: 600;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
}

.profile-role {
    color: #9ca3af;
    font-size: 9.5px;
    font-weight: 500;
    letter-spacing: 0.02em;
}

.profile-chevron {
    color: #9ca3af;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.profile-logout-button {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 10px;
    cursor: pointer;
    transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.profile-logout-button:hover {
    color: #dc2626;
    background-color: #fef2f2;
    border-color: #fecaca;
}

.profile-logout-button:focus-visible {
    outline: 2px solid #111215;
    outline-offset: 2px;
}

.sidebar.collapsed .profile-card {
    background-color: transparent;
    border: none;
    padding: 0;
    justify-content: center;
}

.sidebar.collapsed .profile-info,
.sidebar.collapsed .profile-chevron,
.sidebar.collapsed .profile-card form {
    display: none;
}

.sidebar.collapsed .profile-initial {
    width: 38px;
    height: 38px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

/* ==========================================================================
   Top Navbar (Matching Clean Light Dribbble Style)
   ========================================================================== */
.app-navbar {
    height: 3.75rem;
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.04);
    border-radius: 24px;
    margin: 14px 14px 0 14px;
    padding: 0 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 14px;
    z-index: 50;
    transition: all 0.2s ease;
}

.navbar-left {
    display: flex;
    align-items: center;
    gap: 0.875rem;
}

.navbar-breadcrumbs {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.crumb-root {
    color: #9da3af;
    font-size: 0.8125rem;
    font-weight: 500;
}

.crumb-separator {
    color: #d1d5db;
    font-size: 0.8125rem;
}

.app-navbar .page-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: #111215;
    margin: 0;
}

.live-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.125rem 0.5rem;
    background: rgba(16, 185, 129, 0.09);
    border: 1px solid rgba(16, 185, 129, 0.22);
    border-radius: 999px;
}

.status-pulse-dot {
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 50%;
    background-color: #10b981;
    box-shadow: 0 0 6px #10b981;
}

.live-text {
    color: #059669;
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.mobile-menu-btn {
    display: none;
    background: transparent;
    border: none;
    color: #717684;
    cursor: pointer;
    padding: 0.375rem;
    border-radius: 8px;
    transition: color 0.15s ease;
}

.mobile-menu-btn:hover {
    color: #111215;
}

/* Navbar Right Actions */
.navbar-right {
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.navbar-date-chip {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background-color: #f7f8fa;
    border: 1px solid #e9ecf0;
    padding: 0.375rem 0.75rem;
    border-radius: 12px;
    color: #6b7280;
    font-size: 0.75rem;
    font-weight: 500;
}

.navbar-icon-btn {
    position: relative;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 12px;
    background-color: #f7f8fa;
    border: 1px solid #e9ecf0;
    color: #717684;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.navbar-icon-btn:hover {
    background-color: #ffffff;
    color: #111215;
    border-color: #d1d5db;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.notification-indicator {
    position: absolute;
    top: 0.45rem;
    right: 0.45rem;
    width: 0.375rem;
    height: 0.375rem;
    border-radius: 50%;
    background-color: #ef4444;
    box-shadow: 0 0 6px #ef4444;
}

.navbar-create-btn {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    background-color: #111215;
    color: #ffffff;
    border: none;
    padding: 0.45rem 0.875rem;
    border-radius: 12px;
    font-size: 0.78125rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.15s ease, transform 0.15s ease;
}

.navbar-create-btn:hover {
    background-color: #27282d;
    transform: translateY(-1px);
}

.navbar-user-chip {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background-color: #f7f8fa;
    border: 1px solid #e9ecf0;
    padding: 0.25rem 0.625rem 0.25rem 0.25rem;
    border-radius: 20px;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.navbar-initial {
    width: 1.75rem;
    height: 1.75rem;
    font-size: 0.7rem;
}

.navbar-user-chip:hover {
    background-color: #f1f3f7;
}

.navbar-avatar-wrap {
    position: relative;
    width: 1.75rem;
    height: 1.75rem;
    border-radius: 50%;
    overflow: hidden;
}

.navbar-avatar {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.navbar-user-name {
    color: #111215;
    font-size: 0.78125rem;
    font-weight: 600;
}

.navbar-user-chip .chevron-icon {
    color: #717684;
}

/* Main Content & Footer Area */
.main-content {
    flex: 1;
    padding: 14px;
}

.app-footer {
    margin: 0 14px 14px 14px;
    padding: 1rem 1.5rem;
    font-size: 0.75rem;
    color: #9da3af;
    border-radius: 20px;
    border: 1px solid rgba(0, 0, 0, 0.04);
    background-color: #ffffff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
    text-align: center;
}

/* Sidebar Backdrop on Mobile */
.sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.35);
    backdrop-filter: blur(4px);
    z-index: 90;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .navbar-date-chip,
    .crumb-root,
    .crumb-separator {
        display: none;
    }

    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        bottom: 0;
        margin: 10px;
        height: calc(100vh - 20px);
        transform: translateX(-120%);
        box-shadow: var(--shadow-lg);
    }

    .sidebar.mobile-open {
        transform: translateX(0);
        width: 254px;
    }

    .sidebar-backdrop.active {
        display: block;
    }

    .app-navbar {
        margin: 10px 10px 0 10px;
        padding: 0 0.875rem;
    }

    .main-content {
        padding: 10px;
    }
}

/* ==========================================================================
   Dashboard Home & Widgets (Clean Light Theme)
   ========================================================================== */
.dashboard-content {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.dashboard-banner {
    background: #ffffff;
    color: #111215;
    padding: 1.75rem 2rem;
    border-radius: 24px;
    border: 1px solid rgba(0, 0, 0, 0.04);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
}

.banner-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
    color: #111215;
}

.banner-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.25rem;
}

.stat-card {
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.04);
    border-radius: 20px;
    padding: 1.25rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 35px rgba(0, 0, 0, 0.06);
}

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stat-title {
    font-size: 0.8125rem;
    font-weight: 500;
    color: #6b7280;
}

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

.stat-icon-blue {
    background-color: #eff6ff;
    color: #2563eb;
}

.stat-icon-green {
    background-color: #f0fdf4;
    color: #16a34a;
}

.stat-icon-purple {
    background-color: #faf5ff;
    color: #9333ea;
}

.stat-icon-orange {
    background-color: #fff7ed;
    color: #ea580c;
}

.stat-value {
    font-size: 1.625rem;
    font-weight: 700;
    color: #111215;
}

.stat-footer {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
}

.stat-badge {
    padding: 0.125rem 0.375rem;
    border-radius: 6px;
    font-weight: 600;
}

.stat-badge.positive {
    background-color: #dcfce7;
    color: #15803d;
}

.stat-badge.negative {
    background-color: #fee2e2;
    color: #b91c1c;
}

.stat-badge.neutral {
    background-color: #f3f4f6;
    color: #4b5563;
}

.stat-period {
    color: #9da3af;
}

/* ==========================================================================
   User Management
   ========================================================================== */
.dashboard-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.dashboard-content .btn {
    width: auto;
    min-height: 2.5rem;
    padding: 0.625rem 1rem;
    border-radius: 12px;
    font-size: 0.8125rem;
    text-decoration: none;
}

.dashboard-content .btn-primary {
    background-color: #111215;
}

.dashboard-content .btn-primary:hover:not(:disabled) {
    background-color: #27282d;
    transform: translateY(-1px);
}

.btn-secondary {
    background-color: #f7f8fa;
    color: #4b5563;
    border: 1px solid #e7eaee;
}

.btn-secondary:hover {
    background-color: #ffffff;
    color: #111215;
    border-color: #d1d5db;
}

.table-panel,
.form-card {
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.04);
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
    overflow: hidden;
}

.table-panel-header,
.form-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #eef0f3;
}

.table-panel-header h2,
.form-card-header h2 {
    color: #111215;
    font-size: 0.9375rem;
    font-weight: 700;
}

.table-panel-header p,
.form-card-header p {
    margin-top: 0.2rem;
    color: #8b909c;
    font-size: 0.75rem;
}

.record-count {
    flex-shrink: 0;
    padding: 0.35rem 0.65rem;
    color: #555b67;
    background-color: #f7f8fa;
    border: 1px solid #e9ecf0;
    border-radius: 10px;
    font-size: 0.6875rem;
    font-weight: 600;
}

.table-responsive {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 760px;
}

.data-table th {
    padding: 0.75rem 1.25rem;
    color: #9da3af;
    background-color: #fafbfc;
    border-bottom: 1px solid #eef0f3;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-align: left;
    text-transform: uppercase;
}

.data-table td {
    padding: 0.9rem 1.25rem;
    color: #34373d;
    border-bottom: 1px solid #f0f1f3;
    font-size: 0.8125rem;
    vertical-align: middle;
}

.data-table tbody tr {
    transition: background-color 0.15s ease;
}

.data-table tbody tr:hover {
    background-color: #fafbfc;
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.user-cell {
    display: flex;
    align-items: center;
    gap: 0.7rem;
}

.user-avatar {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #34373d;
    background-color: #f0f1f3;
    border: 1px solid #e2e4e8;
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 700;
}

.text-muted {
    color: #7c828e !important;
}

.project-description {
    max-width: 18rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.priority-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.55rem;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: capitalize;
}

.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.55rem;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 700;
    text-transform: capitalize;
}

.status-active,
.status-open {
    color: #166534;
    background-color: #dcfce7;
    border-color: #bbf7d0;
}

.status-pending,
.status-in_progress {
    color: #a16207;
    background-color: #fef9c3;
    border-color: #fde68a;
}

.status-completed,
.status-resolved {
    color: #315b8a;
    background-color: #eef6ff;
    border-color: #cfe5ff;
}

.status-closed {
    color: #6b7280;
    background-color: #f3f4f6;
    border-color: #e5e7eb;
}

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

.priority-urgent {
    color: #b91c1c;
    background-color: #fee2e2;
    border-color: #fecaca;
}

.priority-high {
    color: #c2410c;
    background-color: #ffedd5;
    border-color: #fed7aa;
}

.priority-medium {
    color: #a16207;
    background-color: #fef9c3;
    border-color: #fde68a;
}

.priority-normal,
.priority-low {
    color: #166534;
    background-color: #dcfce7;
    border-color: #bbf7d0;
}

.file-link {
    color: #111215;
    font-weight: 600;
    text-decoration: none;
}

.file-link:hover {
    text-decoration: underline;
}

.file-help {
    color: #8b909c;
    font-size: 0.6875rem;
}

.project-users-select {
    min-height: 8rem !important;
}

.project-users-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    max-width: 18rem;
}

.project-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
    gap: 0.75rem;
    padding: 1.25rem;
}

.project-card-link {
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
    padding: 1rem;
    color: inherit;
    text-decoration: none;
    background: #fafbfc;
    border: 1px solid #eef0f3;
    border-radius: 0.8rem;
    transition: border-color 0.15s ease, transform 0.15s ease;
}

.project-card-link:hover {
    border-color: #cfd3d9;
    transform: translateY(-2px);
}

.project-card-link strong {
    color: #111215;
}

.project-card-link span:not(.status-badge) {
    color: #8b909c;
    font-size: 0.75rem;
}

.customer-hero {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 2rem;
    color: #ffffff;
    background: linear-gradient(135deg, #15171b, #303642);
    border-radius: 24px;
    box-shadow: 0 16px 35px rgba(17, 18, 21, 0.14);
}

.customer-eyebrow {
    color: #b8c9df;
    font-size: 0.65rem;
    font-weight: 800;
    letter-spacing: 0.12em;
}

.customer-hero h1 {
    margin-top: 0.45rem;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
}

.customer-hero p {
    margin-top: 0.5rem;
    color: #cbd2de;
    font-size: 0.85rem;
}

.customer-hero .btn-primary {
    color: #111215;
    background: #ffffff;
}

.customer-stat-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.75rem;
    margin: 1rem 0;
}

.customer-stat-card {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 1.15rem;
    background: #ffffff;
    border: 1px solid #eef0f3;
    border-radius: 16px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.025);
}

.customer-stat-card strong {
    color: #111215;
    font-size: 1.65rem;
}

.customer-stat-card > span:last-child {
    color: #9aa1ad;
    font-size: 0.7rem;
}

.customer-dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    gap: 1rem;
}

.customer-ticket-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.9rem 1.25rem;
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid #f0f1f3;
}

.customer-ticket-row:hover {
    background: #fafbfc;
}

.customer-ticket-id {
    color: #8b909c;
    font-size: 0.75rem;
    font-weight: 700;
}

.customer-ticket-content {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 0;
}

.customer-ticket-content strong {
    color: #34373d;
    font-size: 0.8rem;
}

.customer-ticket-content span {
    overflow: hidden;
    color: #8b909c;
    font-size: 0.72rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

@media (max-width: 900px) {
    .customer-stat-grid,
    .customer-dashboard-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .customer-hero {
        align-items: flex-start;
        flex-direction: column;
        padding: 1.35rem;
    }

    .customer-stat-grid,
    .customer-dashboard-grid {
        grid-template-columns: 1fr;
    }
}

.customer-ticket-hero .banner-actions { display:flex; align-items:center; gap:.75rem; }
.customer-ticket-overview .table-panel-header { padding-bottom: .5rem; }
.ticket-description { max-width: 70rem; line-height: 1.6; }
.muted-value { color:#9aa1ad !important; font-weight:500 !important; }
.project-summary-meta { display:flex; align-items:center; gap:.75rem; margin-top:.75rem; }
.summary-count,.reply-count { color:#8b909c; font-size:.75rem; font-weight:600; }
.customer-replies-panel,.customer-project-tickets { overflow:hidden; }
.reply-timeline { padding: .25rem 1.5rem 1.25rem; }
.reply-timeline-item { display:flex; gap:.85rem; padding:1rem 0; border-bottom:1px solid #eef0f3; }
.reply-timeline-item:last-child { border-bottom:none; }
.reply-avatar { width:2.25rem; height:2.25rem; flex:0 0 2.25rem; display:grid; place-items:center; color:#374151; background:#eef2f7; border:1px solid #dfe5ec; border-radius:50%; font-weight:700; }
.reply-bubble { flex:1; min-width:0; padding:.8rem 1rem; background:#f8fafc; border:1px solid #edf0f4; border-radius:14px; }
.reply-meta { display:flex; justify-content:space-between; gap:1rem; align-items:center; }
.reply-meta strong { color:#34373d; font-size:.8125rem; }
.reply-meta time { color:#9aa1ad; font-size:.6875rem; white-space:nowrap; }
.reply-bubble p { margin-top:.45rem; color:#596170; font-size:.8125rem; line-height:1.55; white-space:pre-line; }
.customer-reply-form { max-width:none; }
.customer-ticket-list { padding:0 1.5rem; }
.customer-ticket-list-row { padding:1.15rem 0; }
.customer-ticket-list-row .icon-action { margin-left:.25rem; font-size:1rem; }
.customer-project-summary { min-height:8rem; }
@media (max-width: 600px) { .customer-ticket-hero .banner-actions,.reply-meta { align-items:flex-start; flex-direction:column; } .customer-ticket-hero .banner-actions .btn { width:auto; } .reply-timeline,.customer-ticket-list { padding-left:1rem; padding-right:1rem; } .customer-ticket-list-row { align-items:flex-start; flex-wrap:wrap; } .customer-ticket-list-row > .status-badge { margin-left:auto; } }

.customer-badge {
    gap: 0.35rem;
    color: #315b8a;
    background-color: #eef6ff;
    border-color: #cfe5ff;
}

.customer-badge-dot {
    width: 0.35rem;
    height: 0.35rem;
    background-color: #4d9be8;
    border-radius: 50%;
}

.assigned-empty {
    color: #a0a6b2;
    font-size: 0.75rem;
    font-style: italic;
}

.user-detail-link {
    color: inherit;
    text-decoration: none;
}

.user-detail-link:hover {
    text-decoration: underline;
}

.user-details-header {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 1.25rem;
    border-bottom: 1px solid #eef0f3;
}

.user-details-header h2 {
    color: #111215;
    font-size: 1rem;
}

.user-details-header p {
    margin-top: 0.2rem;
    color: #8b909c;
    font-size: 0.8rem;
}

.user-avatar-large {
    width: 3rem;
    height: 3rem;
    font-size: 1rem;
}

.project-summary-card,
.project-tabs-card {
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.04);
    border-radius: 24px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.03);
}

.project-summary-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
}

.project-summary-icon {
    width: 3rem;
    height: 3rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #111215;
    background-color: #f7f8fa;
    border: 1px solid #e7eaee;
    border-radius: 14px;
}

.project-summary-content {
    flex: 1;
    min-width: 0;
}

.summary-label {
    color: #9da3af;
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.project-summary-content h2 {
    margin-top: 0.15rem;
    color: #111215;
    font-size: 1.125rem;
    font-weight: 700;
}

.project-summary-content p {
    margin-top: 0.25rem;
    color: #717684;
    font-size: 0.8125rem;
}

.project-tabs-card {
    overflow: hidden;
}

.project-tabs {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    padding: 0 1.5rem;
    border-bottom: 1px solid #eef0f3;
}

.project-tab {
    position: relative;
    padding: 1rem 0 0.85rem;
    color: #8b909c;
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 0.8125rem;
    font-weight: 600;
}

.project-tab::after {
    position: absolute;
    right: 0;
    bottom: -1px;
    left: 0;
    height: 2px;
    background-color: #111215;
    content: '';
    opacity: 0;
    transform: scaleX(0.5);
    transition: opacity 0.15s ease, transform 0.15s ease;
}

.project-tab:hover,
.project-tab.is-active {
    color: #111215;
}

.project-tab.is-active::after {
    opacity: 1;
    transform: scaleX(1);
}

.project-tab:focus-visible {
    outline: 2px solid #111215;
    outline-offset: 3px;
}

.project-tab-panel {
    padding: 1.5rem;
}

.tab-panel-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1rem;
}

.tab-panel-heading h2 {
    color: #111215;
    font-size: 0.9375rem;
    font-weight: 700;
}

.tab-panel-heading p {
    margin-top: 0.2rem;
    color: #8b909c;
    font-size: 0.75rem;
}

.tab-heading-actions {
    display: flex;
    align-items: center;
    gap: 0.65rem;
}

.client-detail-row,
.ticket-detail-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 0;
    border-bottom: 1px solid #f0f1f3;
}

.client-detail-row:last-child,
.ticket-detail-row:last-child {
    border-bottom: none;
}

.client-detail-row div,
.ticket-detail-row div {
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    flex: 1;
}

.client-detail-row strong,
.ticket-detail-row strong {
    color: #34373d;
    font-size: 0.875rem;
}

.client-detail-row span:not(.user-avatar),
.ticket-detail-row span {
    color: #8b909c;
    font-size: 0.75rem;
}

.empty-tab-state {
    padding: 2rem 1rem;
    color: #8b909c;
    font-size: 0.8125rem;
    text-align: center;
}

.ticket-show-panel {
    margin-top: 1rem;
}

.details-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
    padding: 1.25rem;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    padding: 1rem;
    border: 1px solid #eef0f3;
    border-radius: 0.75rem;
    background: #fafbfc;
}

.detail-item-full {
    grid-column: 1 / -1;
}

.detail-item strong {
    color: #34373d;
    font-size: 0.875rem;
}

@media (max-width: 600px) {
    .details-grid {
        grid-template-columns: 1fr;
    }
}

.btn-compact {
    min-height: 2rem !important;
    padding: 0.45rem 0.75rem !important;
}

@media (max-width: 600px) {
    .project-summary-card {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .project-summary-card .btn {
        width: 100%;
    }

    .project-tabs {
        gap: 1rem;
        padding: 0 1rem;
    }

    .project-tab-panel {
        padding: 1rem;
    }

    .tab-panel-heading {
        align-items: flex-start;
        flex-direction: column;
    }

    .tab-heading-actions {
        width: 100%;
        justify-content: space-between;
    }
}

.role-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.55rem;
    color: #4b5563;
    background-color: #f3f4f6;
    border: 1px solid #e5e7eb;
    border-radius: 999px;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: capitalize;
}

.action-buttons {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.icon-action {
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #717684;
    background-color: #f7f8fa;
    border: 1px solid #e7eaee;
    border-radius: 10px;
    cursor: pointer;
    transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.icon-action:hover {
    color: #111215;
    background-color: #ffffff;
    border-color: #cfd3d9;
}

.icon-action-danger:hover {
    color: #dc2626;
    background-color: #fef2f2;
    border-color: #fecaca;
}

.icon-action-disabled {
    color: #c5c9d0;
    background-color: #fafbfc;
    border-color: #eef0f3;
    cursor: not-allowed;
}

.empty-table-state {
    padding: 3rem 1.5rem !important;
    color: #8b909c !important;
    text-align: center;
}

.empty-table-state a {
    color: #111215;
    font-weight: 600;
}

.pagination-wrapper {
    display: flex;
    justify-content: flex-end;
}

.form-card {
    width: 100%;
    max-width: 760px;
}

.form-card-icon {
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #111215;
    background-color: #f7f8fa;
    border: 1px solid #e7eaee;
    border-radius: 12px;
}

.form-card-header {
    justify-content: flex-start;
}

.form-card form {
    padding: 1.5rem;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.25rem;
}

.form-group-full {
    grid-column: 1 / -1;
}

.form-card .form-label {
    color: #34373d;
    font-size: 0.75rem;
    font-weight: 600;
}

.form-card .form-input {
    min-height: 2.75rem;
    padding: 0.65rem 0.8rem;
    color: #111215;
    background-color: #fafbfc;
    border-color: #e3e6ea;
    border-radius: 12px;
    font-size: 0.8125rem;
}

.form-card .form-input:focus-visible {
    background-color: #ffffff;
    border-color: #111215;
    box-shadow: 0 0 0 3px rgba(17, 18, 21, 0.08);
}

.form-error {
    color: #dc2626;
    font-size: 0.75rem;
}

.optional-label {
    color: #8b909c;
    font-size: 0.75rem;
    font-weight: 400;
}

.form-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.625rem;
    margin-top: 1.5rem;
    padding-top: 1.25rem;
    border-top: 1px solid #eef0f3;
}

@media (max-width: 768px) {
    .dashboard-banner {
        align-items: flex-start;
        flex-direction: column;
        padding: 1.35rem;
    }

    .dashboard-banner .btn {
        width: 100%;
    }

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

    .form-group-full {
        grid-column: auto;
    }
}

@media (max-width: 480px) {
    .table-panel-header,
    .form-card-header,
    .form-card form {
        padding: 1rem;
    }

    .table-panel-header {
        align-items: flex-start;
        flex-direction: column;
    }

    .form-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .form-actions .btn {
        width: 100%;
    }
}
.customer-reply-form .reply-upload { margin-top: 24px; }
.reply-upload-box.reply-upload-dark { position: relative; background: #111; border: 2px dashed #414141; border-radius: 18px; padding: 24px 20px; gap: 0; min-height: 240px; justify-content: center; }
.reply-upload-dark .reply-upload-icon { display: grid; place-items: center; width: 48px; height: 48px; flex-shrink: 0; border-radius: 50%; background: #262626; margin-bottom: 16px; }
.reply-upload-dark .reply-upload-icon svg { color: #a3a3a3; width: 24px; height: 24px; }
.reply-upload-box.reply-upload-dark strong { color: #f5f5f5; font-size: 20px; font-weight: 650; line-height: 1.3; }
.reply-upload-box.reply-upload-dark p { color: #a3a3a3; font-size: 13px; max-width: 700px; margin: 10px 0 18px; line-height: 1.5; }
.reply-upload-dark .reply-browse-button { display: inline-flex; align-items: center; justify-content: center; padding: 10px 20px; border: 1px solid #414141; border-radius: 10px; background: transparent; color: #fafafa; font-size: 14px; line-height: 1.4; font-weight: 600; cursor: pointer; margin: 0; }
@media (max-width: 600px) { .reply-upload-box.reply-upload-dark { padding: 20px 16px; min-height: 220px; } }
.reply-browse-button:hover { background: #262626; border-color: #737373; }
.reply-upload-dark .reply-file-input { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); }
.reply-upload-box.reply-upload-dark:focus-within, .reply-upload-box.reply-upload-dark.is-dragging { border-color: #a3a3a3; background: #191919; outline: 2px solid #737373; outline-offset: 3px; }
.reply-upload-dark:focus-within .reply-browse-button { outline: 2px solid #fafafa; outline-offset: 3px; }
.reply-upload-heading .form-label { display: flex; align-items: center; gap: 10px; }
.reply-upload-heading span { font-size: 11px; font-weight: 500; color: #64748b; background: #f1f5f9; padding: 3px 8px; border-radius: 20px; }
.reply-upload-box { margin-top: 10px; padding: 24px; border: 1px dashed #cbd5e1; border-radius: 16px; background: #f8fafc; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; transition: border-color .2s, background .2s; }
.reply-upload-box:focus-within { border-color: #475569; background: #f1f5f9; outline: 2px solid #cbd5e1; outline-offset: 3px; }
.reply-upload-box svg { color: #64748b; }
.reply-upload-box strong { font-size: 14px; color: #334155; }
.reply-upload-box p { margin: 0; font-size: 12px; line-height: 1.6; color: #64748b; }
.reply-upload-box input { max-width: 100%; font: inherit; font-size: 12px; color: #64748b; }
.reply-upload-box input::file-selector-button { border: 1px solid #dbe1e8; background: white; border-radius: 9px; padding: 9px 14px; margin-right: 10px; color: #334155; font-weight: 600; cursor: pointer; }
.reply-file-list { padding: 0; margin: 12px 0 0; list-style: none; display: grid; gap: 8px; }
.reply-file-list li { padding: 10px 14px; border: 1px solid #e2e8f0; border-radius: 10px; font-size: 12px; color: #475569; overflow-wrap: anywhere; }
.customer-reply-form textarea { font-family: inherit; line-height: 1.7; }
