* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #00d4ff;
    --secondary-color: #0099ff;
    --success-color: #43e97b;
    --danger-color: #f5576c;
    --warning-color: #ffa726;
    --info-color: #4facfe;
    --dark-color: #1a1a2e;
    --light-color: #ffffff;
    --glass-bg: rgba(30, 41, 59, 0.4);
    --glass-border: rgba(71, 85, 105, 0.3);
    --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.4);
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: url('../images/pages_background.jpg') no-repeat center center fixed;
    background-size: cover;
    background-position: center center;
    color: var(--text-primary);
    line-height: 1.6;
    position: relative;
    min-height: 100vh;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.5) 0%, rgba(0, 0, 0, 0.6) 100%);
    z-index: -1;
}

body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('../images/pages_background.jpg') no-repeat center center fixed;
    background-size: cover;
    filter: brightness(1.2) contrast(1.1);
    z-index: -2;
}

.glass-effect {
    background: var(--glass-bg);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow);
}

.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 20px;
}

.login-container {
    width: 100%;
    max-width: 450px;
}

.login-box {
    border-radius: 20px;
    padding: 40px;
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header i {
    font-size: 48px;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.login-header h1 {
    font-size: 28px;
    margin-bottom: 10px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 14px;
}

.alert {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.alert-error {
    background: rgba(245, 87, 108, 0.2);
    border: 1px solid rgba(245, 87, 108, 0.3);
    color: #ff6b7a;
}

.alert-success {
    background: rgba(67, 233, 123, 0.2);
    border: 1px solid rgba(67, 233, 123, 0.3);
    color: #43e97b;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    background: rgba(255, 255, 255, 0.15);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 212, 255, 0.4);
}

.btn-success {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
    color: white;
}

.btn-danger {
    background: linear-gradient(135deg, #f5576c 0%, #f093fb 100%);
    color: white;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 12px;
}

.login-footer {
    margin-top: 30px;
    text-align: center;
}

.demo-credentials {
    background: rgba(255, 255, 255, 0.05);
    padding: 15px;
    border-radius: 8px;
    font-size: 12px;
    line-height: 1.8;
}

.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.header {
    position: fixed;
    top: 0;
    left: 280px;
    right: 0;
    height: 60px;
    padding: 0 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 1000;
    border-radius: 0;
    border: none;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    transition: left 0.3s ease;
}

.sidebar.collapsed ~ .app-container .header {
    left: 80px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
    flex: 1;
}

.sidebar-toggle {
    display: none;
}

.header-breadcrumb {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.page-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
    color: var(--text-primary);
}

.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--text-secondary);
}

.breadcrumb a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb a:hover {
    color: var(--primary-color);
}

.breadcrumb i {
    font-size: 10px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-time {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    margin-right: 15px;
    padding-right: 15px;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
}

.time-display {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
}

.date-display {
    font-size: 11px;
    color: var(--text-secondary);
}

.header-icon-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 18px;
    cursor: pointer;
    padding: 10px;
    border-radius: 6px;
    transition: all 0.3s ease;
    position: relative;
}

.header-icon-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--primary-color);
}

.clock-in-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(220, 38, 38, 0.15);
    border: 1px solid rgba(220, 38, 38, 0.3);
    border-radius: 6px;
    color: #ef4444;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 10px;
}

.clock-in-btn:hover {
    background: rgba(220, 38, 38, 0.25);
    border-color: rgba(220, 38, 38, 0.5);
}

.clock-in-btn i {
    font-size: 14px;
}

.header-notifications {
    position: relative;
}

.notification-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 20px;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    position: relative;
    transition: all 0.3s ease;
}

.notification-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.notification-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--danger-color);
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: 600;
}

.notification-dropdown {
    position: absolute;
    top: calc(100% + 15px);
    right: 0;
    width: 350px;
    border-radius: 12px;
    display: none;
    max-height: 500px;
    overflow: hidden;
    background: rgba(30, 41, 59, 0.95);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.notification-dropdown.active {
    display: block;
    animation: fadeInDown 0.3s ease;
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.notification-header {
    padding: 15px 20px;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notification-header h3 {
    font-size: 16px;
}

.notification-header a {
    color: var(--primary-color);
    font-size: 12px;
    text-decoration: none;
}

.notification-list {
    max-height: 350px;
    overflow-y: auto;
}

.notification-item {
    padding: 15px 20px;
    border-bottom: 1px solid var(--glass-border);
    cursor: pointer;
    transition: all 0.3s ease;
}

.notification-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.notification-item.unread {
    background: rgba(102, 126, 234, 0.1);
}

.notification-item h4 {
    font-size: 14px;
    margin-bottom: 5px;
}

.notification-item p {
    font-size: 12px;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.notification-item span {
    font-size: 11px;
    color: var(--text-secondary);
}

.notification-footer {
    padding: 12px 20px;
    text-align: center;
    border-top: 1px solid var(--glass-border);
}

.notification-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
}

.notification-loading {
    padding: 30px;
    text-align: center;
    color: var(--text-secondary);
}

.header-user {
    position: relative;
}

.user-btn {
    background: none;
    border: none;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    padding: 6px 12px;
    border-radius: 6px;
    transition: all 0.3s ease;
    height: 48px;
}

.header-user .user-btn {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.user-role {
    font-size: 12px;
    font-weight: 600;
    color: var(--text-primary);
    letter-spacing: 0.5px;
}

.user-avatar {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.2);
    display: block;
    flex-shrink: 0;
}

.header-user .user-avatar {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
}

.user-btn span {
    color: var(--text-primary);
    font-weight: 500;
}

.user-btn i {
    color: var(--text-secondary);
    font-size: 12px;
}

.user-dropdown {
    position: absolute;
    top: calc(100% + 15px);
    right: 0;
    width: 250px;
    border-radius: 12px;
    display: none;
    background: rgba(20, 25, 45, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 1000;
}

.user-dropdown.active {
    display: block;
    animation: fadeInDown 0.3s ease;
}

.user-info {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-info img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

.user-info h4 {
    font-size: 14px;
    margin-bottom: 3px;
}

.user-info p {
    font-size: 12px;
    color: var(--text-secondary);
}

.user-dropdown a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: var(--text-primary);
    text-decoration: none;
    transition: all 0.3s ease;
}

.user-dropdown a:hover {
    background: rgba(255, 255, 255, 0.05);
}

.user-dropdown a i {
    width: 20px;
    color: var(--text-secondary);
}

.dropdown-divider {
    height: 1px;
    background: var(--glass-border);
    margin: 5px 0;
}

.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 280px;
    height: 100vh;
    overflow-y: auto;
    padding: 0;
    border-radius: 0;
    border: none;
    border-right: 1px solid var(--glass-border);
    transition: all 0.3s ease;
    z-index: 999;
    background: var(--glass-bg);
    backdrop-filter: blur(16px) saturate(180%);
    -webkit-backdrop-filter: blur(16px) saturate(180%);
    box-shadow: var(--shadow);
}

.sidebar-brand {
    padding: 20px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(0, 0, 0, 0.2);
}

.sidebar-brand h2 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 10px 0;
    white-space: nowrap;
    line-height: 1.2;
}

.sidebar-user-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: var(--success-color);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.sidebar-user-badge i {
    font-size: 8px;
}

.sidebar.collapsed {
    width: 80px;
}

.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    padding: 10px 0;
}

.nav-section {
    margin-bottom: 15px;
}

.nav-section h3 {
    padding: 12px 25px 8px 25px;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 5px;
    font-weight: 600;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 25px;
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    font-size: 14px;
}

.nav-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.nav-item.active {
    background: rgba(59, 130, 246, 0.15);
    color: var(--text-primary);
    border-left: 3px solid #3b82f6;
}

.nav-item i {
    width: 18px;
    font-size: 16px;
}

/* Dropdown Menu Styles */
.nav-item-dropdown {
    position: relative;
}

.dropdown-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    cursor: pointer;
}

.dropdown-icon {
    margin-left: auto;
    font-size: 12px;
    transition: transform 0.3s ease;
}

.dropdown-toggle.active .dropdown-icon {
    transform: rotate(180deg);
}

.dropdown-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    background: rgba(0, 0, 0, 0.2);
    margin-left: 0;
}

.dropdown-menu.show {
    max-height: 500px;
}

.submenu-item {
    padding-left: 50px !important;
    font-size: 13px;
}

.submenu-item i.fa-angle-right {
    font-size: 12px;
    width: 12px;
}

.submenu-item:hover {
    background: rgba(255, 255, 255, 0.08);
}

.submenu-item.active {
    background: rgba(59, 130, 246, 0.2);
    border-left: 3px solid #3b82f6;
}

.main-content {
    margin-top: 60px;
    margin-left: 280px;
    margin-bottom: 20px;
    padding: 30px;
    min-height: calc(100vh - 60px - 20px);
    transition: all 0.3s ease;
}

.sidebar.collapsed ~ * .main-content {
    margin-left: 80px;
}

.page-header {
    margin-bottom: 30px;
}

.page-header h1 {
    font-size: 32px;
    margin-bottom: 8px;
}

.page-header p {
    color: var(--text-secondary);
    font-size: 14px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    padding: 25px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: white;
}

.stat-content h3 {
    font-size: 32px;
    margin-bottom: 5px;
}

.stat-content p {
    color: var(--text-secondary);
    font-size: 14px;
    margin-bottom: 8px;
}

.stat-change {
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.stat-change.positive {
    color: var(--success-color);
}

.stat-change.negative {
    color: var(--danger-color);
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    border-radius: 15px;
    overflow: hidden;
}

.card-header {
    padding: 20px;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card-header h2 {
    font-size: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.card-content {
    padding: 20px;
}

.project-list,
.ticket-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.project-item,
.ticket-item {
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
}

.project-item:hover,
.ticket-item:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateX(5px);
}

.project-info h4,
.ticket-info h4 {
    font-size: 14px;
    margin-bottom: 5px;
}

.project-info p,
.ticket-info p {
    font-size: 12px;
    color: var(--text-secondary);
}

.project-meta,
.ticket-meta {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: flex-end;
}

.badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-planning {
    background: rgba(255, 167, 38, 0.2);
    color: #ffa726;
}

.badge-in-progress {
    background: rgba(79, 172, 254, 0.2);
    color: #4facfe;
}

.badge-on-hold {
    background: rgba(255, 167, 38, 0.2);
    color: #ffa726;
}

.badge-completed {
    background: rgba(67, 233, 123, 0.2);
    color: #43e97b;
}

.badge-cancelled {
    background: rgba(245, 87, 108, 0.2);
    color: #f5576c;
}

.badge-open {
    background: rgba(79, 172, 254, 0.2);
    color: #4facfe;
}

.badge-pending {
    background: rgba(255, 167, 38, 0.2);
    color: #ffa726;
}

.badge-resolved {
    background: rgba(67, 233, 123, 0.2);
    color: #43e97b;
}

.badge-closed {
    background: rgba(158, 158, 158, 0.2);
    color: #9e9e9e;
}

.badge-priority-low {
    background: rgba(67, 233, 123, 0.2);
    color: #43e97b;
}

.badge-priority-medium {
    background: rgba(79, 172, 254, 0.2);
    color: #4facfe;
}

.badge-priority-high {
    background: rgba(255, 167, 38, 0.2);
    color: #ffa726;
}

.badge-priority-critical {
    background: rgba(245, 87, 108, 0.2);
    color: #f5576c;
}

.activity-timeline {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.activity-item {
    display: flex;
    gap: 15px;
}

.activity-avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--primary-color);
}

.activity-content p {
    font-size: 14px;
    margin-bottom: 5px;
}

.activity-time {
    font-size: 12px;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 5px;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: var(--text-secondary);
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 15px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 14px;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table thead {
    background: rgba(255, 255, 255, 0.05);
}

.data-table th,
.data-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.data-table th {
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-secondary);
}

.data-table tbody tr {
    transition: all 0.3s ease;
}

.data-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.05);
}

.action-buttons {
    display: flex;
    gap: 8px;
}

.btn-icon {
    width: 32px;
    height: 32px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    width: 90%;
    max-width: 600px;
    border-radius: 15px;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h2 {
    font-size: 20px;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-primary);
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
}

.modal-body {
    padding: 20px;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

@media (max-width: 1024px) {
    .sidebar {
        width: 80px;
    }
    
    .sidebar .nav-section h3,
    .sidebar .nav-item span {
        display: none;
    }
    
    .main-content {
        margin-left: 80px;
    }
    
    .header-search input {
        width: 200px;
    }
    
    .header-search input:focus {
        width: 250px;
    }
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .dashboard-grid {
        grid-template-columns: 1fr;
    }
    
    .header-search {
        display: none;
    }
    
    .user-btn span {
        display: none;
    }
}
