.admin-wrapper {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 220px;
    min-height: 100vh;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 100;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.admin-sidebar .sidebar-logo {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    font-weight: 700;
    flex-shrink: 0;
}

.admin-sidebar .sidebar-menu {
    flex: 1;
    padding: 8px 0;
}

.admin-sidebar .sidebar-menu a {
    display: flex;
    align-items: center;
    height: 44px;
    padding: 0 20px;
    font-size: 14px;
    transition: all 0.2s ease;
}

.admin-sidebar .sidebar-menu a .menu-icon {
    width: 20px;
    margin-right: 10px;
    text-align: center;
    flex-shrink: 0;
}

.admin-sidebar .sidebar-user {
    padding: 12px 16px;
    border-top: 1px solid transparent;
    flex-shrink: 0;
}

.admin-sidebar .sidebar-user .user-info {
    font-size: 12px;
    margin-bottom: 8px;
}

.admin-sidebar .sidebar-user .logout-btn {
    display: inline-block;
    font-size: 12px;
    cursor: pointer;
}

.admin-main {
    margin-left: 220px;
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.admin-header {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 90;
    flex-shrink: 0;
}

.admin-header .page-title {
    font-size: 18px;
    font-weight: 600;
}

.admin-content {
    flex: 1;
    padding: 20px 24px;
    overflow-y: auto;
}

.view-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.view-header {
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    position: sticky;
    top: 0;
    z-index: 90;
    flex-shrink: 0;
}

.view-header .logo {
    font-size: 18px;
    font-weight: 700;
}

.view-header .nav-links {
    display: flex;
    align-items: center;
    gap: 20px;
}

.view-main {
    flex: 1;
    padding: 20px 24px;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.container {
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
    padding: 0 16px;
}

.card {
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 16px;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 16px;
    padding-bottom: 12px;
}

.card-title {
    font-size: 16px;
    font-weight: 600;
}

.toolbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}

.toolbar-right {
    margin-left: auto;
}

.search-box {
    display: inline-flex;
    align-items: center;
}

.search-box input {
    height: 34px;
    padding: 0 12px;
    border: 1px solid transparent;
    border-radius: 4px 0 0 4px;
    width: 200px;
}

.search-box button {
    height: 34px;
    padding: 0 12px;
    border: 1px solid transparent;
    border-left: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 34px;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    gap: 4px;
}

.btn-sm {
    height: 28px;
    padding: 0 10px;
    font-size: 12px;
}

.btn-lg {
    height: 40px;
    padding: 0 24px;
    font-size: 16px;
}

.btn-block {
    display: flex;
    width: 100%;
}

.btn[disabled] {
    opacity: 0.6;
    cursor: not-allowed;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
}

.form-group label .required {
    margin-left: 2px;
}

.form-control {
    width: 100%;
    height: 36px;
    padding: 0 12px;
    border: 1px solid transparent;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

textarea.form-control {
    height: auto;
    min-height: 80px;
    padding: 8px 12px;
    resize: vertical;
}

select.form-control {
    appearance: auto;
}

.form-row {
    display: flex;
    gap: 16px;
}

.form-row .form-group {
    flex: 1;
}

.data-table {
    width: 100%;
    border-radius: 8px;
    overflow: hidden;
}

.data-table thead th {
    padding: 12px 16px;
    font-weight: 600;
    font-size: 13px;
    text-align: left;
    white-space: nowrap;
}

.data-table tbody td {
    padding: 12px 16px;
    font-size: 14px;
    border-top: 1px solid transparent;
    vertical-align: middle;
}

.data-table .actions {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.pagination {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
    margin-top: 16px;
    padding-top: 16px;
}

.pagination .page-btn {
    min-width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid transparent;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    padding: 0 8px;
    transition: all 0.2s ease;
}

.pagination .page-info {
    font-size: 13px;
    margin: 0 8px;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s ease;
}

.modal {
    width: 90%;
    max-width: 600px;
    max-height: 80vh;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    animation: fadeIn 0.2s ease;
}

.modal-lg {
    max-width: 900px;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid transparent;
    flex-shrink: 0;
}

.modal-title {
    font-size: 16px;
    font-weight: 600;
}

.modal-close {
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 4px;
    font-size: 18px;
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    padding: 12px 20px;
    border-top: 1px solid transparent;
    flex-shrink: 0;
}

.badge {
    display: inline-flex;
    align-items: center;
    height: 22px;
    padding: 0 8px;
    border-radius: 11px;
    font-size: 12px;
    white-space: nowrap;
}

.status-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    margin-right: 6px;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
}

.empty-state .empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
}

.empty-state .empty-text {
    font-size: 14px;
}

.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 12px 20px;
    border-radius: 6px;
    font-size: 14px;
    animation: slideInRight 0.3s ease;
    max-width: 360px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

@keyframes slideInRight {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-box {
    width: 100%;
    max-width: 400px;
    border-radius: 8px;
    padding: 40px 32px;
}

.login-box .login-title {
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-box .login-subtitle {
    text-align: center;
    font-size: 14px;
    margin-bottom: 32px;
}

.login-box .form-group {
    margin-bottom: 20px;
}

.login-box .login-btn {
    width: 100%;
    height: 42px;
    font-size: 16px;
    margin-top: 8px;
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.stat-card {
    border-radius: 8px;
    padding: 20px;
}

.stat-card .stat-label {
    font-size: 13px;
    margin-bottom: 8px;
}

.stat-card .stat-value {
    font-size: 28px;
    font-weight: 700;
}

.tab-nav {
    display: flex;
    border-bottom: 2px solid transparent;
    margin-bottom: 16px;
}

.tab-nav .tab-item {
    padding: 10px 20px;
    font-size: 14px;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s ease;
}

@media (max-width: 768px) {
    .admin-sidebar {
        width: 60px;
    }
    .admin-sidebar .sidebar-logo span,
    .admin-sidebar .sidebar-menu a .menu-text,
    .admin-sidebar .sidebar-user {
        display: none;
    }
    .admin-sidebar .sidebar-menu a {
        justify-content: center;
        padding: 0;
    }
    .admin-sidebar .sidebar-menu a .menu-icon {
        margin-right: 0;
    }
    .admin-main {
        margin-left: 60px;
    }
    .admin-content {
        padding: 12px 16px;
    }
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    .grid-2, .grid-3, .grid-4 {
        grid-template-columns: 1fr;
    }
    .toolbar {
        flex-direction: column;
        align-items: stretch;
    }
    .toolbar-right {
        margin-left: 0;
    }
    .search-box input {
        width: 100%;
    }
    .data-table {
        display: block;
        overflow-x: auto;
    }
    .modal {
        width: 95%;
        max-height: 90vh;
    }
}
