/* Global Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes shimmer {
    0% { background-position: -1000px 0; }
    100% { background-position: 1000px 0; }
}

/* Loading Animation */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    animation: shimmer 2s infinite;
}

/* Animated Classes */
.fade-in {
    animation: fadeIn 0.5s ease-out;
}

.slide-in-left {
    animation: slideInLeft 0.5s ease-out;
}

.slide-in-right {
    animation: slideInRight 0.5s ease-out;
}

.slide-in-up {
    animation: slideInUp 0.5s ease-out;
}

/* Card Hover Effects */
.hover-card {
    transition: all 0.3s ease;
}

.hover-card:hover {
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

/* Button Animations */
.btn-animate {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-animate::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255,255,255,0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-animate:hover::after {
    width: 300%;
    height: 300%;
}

/* Notification Badge Animation */
.badge {
    position: relative;
}

.badge[data-count]:after {
    content: attr(data-count);
    position: absolute;
    top: -8px;
    right: -8px;
    min-width: 20px;
    height: 20px;
    line-height: 20px;
    padding: 0 6px;
    background: var(--accent);
    border-radius: 10px;
    color: white;
    text-align: center;
    font-size: 12px;
    animation: pulse 2s infinite;
}

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(90deg, var(--sidebar-bg) 25%, var(--sidebar-hover) 50%, var(--sidebar-bg) 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
}

/* Progress Bar */
.progress-bar {
    height: 4px;
    background: var(--sidebar-bg);
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar::after {
    content: '';
    display: block;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    animation: shimmer 2s infinite;
}

/* Tooltip */
.tooltip {
    position: relative;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    padding: 5px 10px;
    background: var(--card-bg);
    color: var(--text-light);
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.tooltip:hover::before {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(-5px);
}

/* Modal Animation */
.modal {
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    transform: scale(0.7);
    transition: all 0.3s ease;
}

.modal.active .modal-content {
    transform: scale(1);
}

/* Sidebar Menu Item Hover */
.menu-item {
    position: relative;
    overflow: hidden;
}

.menu-item::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background: var(--primary);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
}

.menu-item:hover::before {
    transform: translateX(0);
}

/* Card Loading State */
.card-loading {
    position: relative;
    overflow: hidden;
}

.card-loading::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
    animation: shimmer 2s infinite;
}

/* Image Hover Effect */
.image-hover {
    transition: all 0.3s ease;
}

.image-hover:hover {
    transform: scale(1.05);
    filter: brightness(1.1);
}

/* Notification Animation */
@keyframes notification {
    0% { transform: translateX(100%); opacity: 0; }
    10% { transform: translateX(0); opacity: 1; }
    90% { transform: translateX(0); opacity: 1; }
    100% { transform: translateX(100%); opacity: 0; }
}

.notification {
    animation: notification 3s ease-in-out forwards;
}

/* Smooth Scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--sidebar-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* General Styles */
:root {
    --primary: #1a73e8;
    --primary-dark: #1557b0;
    --secondary: #00c6ff;
    --sidebar-bg: #1e1e2d;
    --sidebar-hover: #2b2b3d;
    --content-bg: #151521;
    --card-bg: #1e1e2d;
    --text-light: #ffffff;
    --text-dark: #e0e0e0;
    --border-color: #2b2b3d;
    --danger: #f44336;
    --success: #4caf50;
    --warning: #ff9800;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--content-bg);
    color: var(--text-light);
    min-height: 100vh;
}

/* Main Content */
.main-content {
    margin-left: 250px;
    padding: 20px;
    min-height: 100vh;
    background: var(--content-bg);
}

.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding: 20px;
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.page-header h1 {
    color: var(--text-light);
    font-size: 24px;
    margin: 0;
}

/* Cards */
.content-card {
    background: var(--card-bg);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
}

/* Product Grid */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.product-card {
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border-color: var(--primary);
}

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid var(--border-color);
}

.product-details {
    padding: 15px;
}

.product-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 10px;
}

.product-name {
    color: var(--text-light);
    font-size: 1.1em;
    margin: 0;
}

.product-info {
    margin: 10px 0;
}

.product-price {
    color: var(--secondary);
    font-size: 1.2em;
    font-weight: bold;
}

/* Buttons */
.btn-animate {
    background: linear-gradient(45deg, var(--primary), var(--primary-dark));
    color: var(--text-light);
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.btn-animate:hover {
    box-shadow: 0 5px 15px rgba(26, 115, 232, 0.4);
}

.btn-secondary {
    background: linear-gradient(45deg, var(--secondary), var(--primary));
}

.btn-icon {
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    padding: 5px;
    transition: all 0.3s ease;
    opacity: 0.8;
}

.btn-icon:hover {
    opacity: 1;
    color: var(--secondary);
}

/* Filters */
.filters {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.search-bar {
    flex: 1;
    padding: 10px 15px;
    background: var(--sidebar-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-light);
}

.search-bar::placeholder {
    color: var(--text-dark);
    opacity: 0.7;
}

.filter-select {
    padding: 10px 15px;
    background: var(--sidebar-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-light);
    cursor: pointer;
}

.filter-select option {
    background: var(--sidebar-bg);
    color: var(--text-light);
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.8);
    z-index: 1000;
}

.modal-content {
    background: var(--card-bg);
    width: 90%;
    max-width: 600px;
    margin: 50px auto;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    color: var(--text-light);
}

/* Forms */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: var(--text-light);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 8px;
    background: var(--sidebar-bg);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    color: var(--text-light);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--primary);
    outline: none;
}

/* Badges */
.badge {
    background: var(--sidebar-hover);
    color: var(--text-light);
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    margin-right: 5px;
    border: 1px solid var(--border-color);
}

/* Stock Info */
.stock-info {
    margin-top: 10px;
    font-size: 0.9em;
    color: var(--text-dark);
}

.low-stock {
    color: var(--danger);
}

/* Tooltips */
.tooltip {
    position: relative;
}

.tooltip:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--sidebar-hover);
    color: var(--text-light);
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    border: 1px solid var(--border-color);
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.fade-in {
    animation: fadeIn 0.3s ease-in;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--sidebar-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* Dashboard Stats */
.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.stat-card {
    background: var(--card-bg);
    border-radius: 8px;
    padding: 20px;
    border: 1px solid var(--border-color);
    display: flex;
    align-items: center;
    gap: 20px;
}

.stat-icon {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-icon i {
    font-size: 24px;
    color: var(--text-light);
}

.stat-details h3 {
    color: var(--text-dark);
    font-size: 14px;
    margin-bottom: 5px;
}

.stat-value {
    color: var(--text-light);
    font-size: 24px;
    font-weight: bold;
}

/* Card Header */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.card-header h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-light);
    font-size: 18px;
    margin: 0;
}

.card-header h2 i {
    color: var(--secondary);
}

/* Dashboard Table */
.table-responsive {
    overflow-x: auto;
}

.dashboard-table {
    width: 100%;
    border-collapse: collapse;
}

.dashboard-table th,
.dashboard-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.dashboard-table th {
    color: var(--text-dark);
    font-weight: 500;
}

.dashboard-table td {
    color: var(--text-light);
}

/* Status Badge */
.status-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
}

.status-badge.pending {
    background: rgba(255, 152, 0, 0.1);
    color: #ff9800;
}

.status-badge.paid {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
}

.status-badge.process {
    background: rgba(33, 150, 243, 0.1);
    color: #2196f3;
}

.status-badge.shipped {
    background: rgba(156, 39, 176, 0.1);
    color: #9c27b0;
}

.status-badge.completed {
    background: rgba(76, 175, 80, 0.1);
    color: #4caf50;
}

.status-badge.cancelled {
    background: rgba(244, 67, 54, 0.1);
    color: #f44336;
}

/* Date Info */
.date-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-dark);
    font-size: 14px;
}

.date-info i {
    color: var(--secondary);
}

/* Dashboard Styles */
.dashboard-container {
    padding: 20px;
    display: grid;
    gap: 20px;
    animation: fadeIn 0.5s ease-out;
}

.welcome-section {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 30px;
    border: 1px solid var(--border-color);
    margin-bottom: 20px;
}

.welcome-section h1 {
    color: var(--text-light);
    font-size: 2em;
    margin-bottom: 10px;
}

.welcome-section p {
    color: var(--text-muted);
    font-size: 1.1em;
}

.product-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    padding: 20px 0;
}

.product-card {
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    overflow: hidden;
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    border-color: var(--primary);
}

.product-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.product-details {
    padding: 20px;
}

.product-name {
    font-size: 1.2em;
    font-weight: 600;
    color: var(--text-light);
    margin-bottom: 10px;
}

.product-price {
    color: var(--accent);
    font-size: 1.3em;
    font-weight: 600;
    margin: 10px 0;
}

.order-history {
    background: var(--card-bg);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    padding: 25px;
    margin-top: 30px;
}

.order-history h2 {
    color: var(--text-light);
    font-size: 1.5em;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.order-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid var(--border-color);
    transition: all 0.3s ease;
}

.order-item:last-child {
    border-bottom: none;
}

.order-item:hover {
    background: var(--sidebar-hover);
    border-radius: 8px;
}

.order-details {
    flex: 1;
}

.order-id {
    color: var(--accent);
    font-size: 0.9em;
    margin-bottom: 5px;
}

.order-status {
    background: var(--primary);
    color: var(--text-light);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 500;
}

.search-bar {
    width: 100%;
    padding: 12px 20px;
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    color: var(--text-light);
    font-size: 1em;
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.search-bar:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 2px rgba(26, 115, 232, 0.2);
}

.search-bar::placeholder {
    color: var(--text-muted);
}

.btn-view {
    background: var(--primary);
    color: var(--text-light);
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    font-weight: 500;
}

.btn-view:hover {
    background: var(--primary-dark);
} 