* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: #f5f5f5;
}

/* Container dengan efek 3D */
.container {
    display: flex;
    min-height: 100vh;
    background: linear-gradient(135deg, #8B4513 0%, #D2691E 100%);
    padding: 20px;
    perspective: 1000px;
}

/* Sidebar dengan efek 3D */
.sidebar {
    width: 280px;
    background: #FFF5E6;
    border-radius: 20px;
    padding: 25px;
    box-shadow: 
        20px 20px 30px rgba(0, 0, 0, 0.3),
        -5px -5px 15px rgba(255, 255, 255, 0.5),
        inset 0 -3px 8px rgba(139, 69, 19, 0.2);
    transform: rotateY(5deg) rotateX(2deg);
    transition: transform 0.3s ease;
    border: 1px solid rgba(139, 69, 19, 0.1);
}

.sidebar:hover {
    transform: rotateY(2deg) rotateX(1deg);
}

/* Profile Section dengan efek 3D */
.profile-section {
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 2px solid #8B4513;
    margin-bottom: 20px;
}

.profile-image {
    width: 120px;
    height: 120px;
    margin: 0 auto 15px;
    border-radius: 50%;
    background: #D2691E;
    position: relative;
    overflow: hidden;
    box-shadow: 
        8px 8px 15px rgba(139, 69, 19, 0.3),
        -5px -5px 10px rgba(255, 255, 255, 0.8),
        inset 0 -3px 8px rgba(0, 0, 0, 0.2);
    border: 3px solid #FFF5E6;
}

.profile-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(139, 69, 19, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
    cursor: pointer;
}

.profile-image:hover .profile-overlay {
    opacity: 1;
}

.profile-overlay i {
    color: white;
    font-size: 30px;
}

.profile-section h3 {
    color: #8B4513;
    font-size: 18px;
    margin-bottom: 5px;
}

.profile-section p {
    color: #D2691E;
    font-size: 14px;
    margin-bottom: 10px;
}

/* Menu dengan efek 3D */
.menu {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.menu-item {
    padding: 12px 15px;
    color: #8B4513;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 10px;
    background: #FFF5E6;
    box-shadow: 
        5px 5px 10px rgba(139, 69, 19, 0.2),
        -5px -5px 10px rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(139, 69, 19, 0.1);
}

.menu-item i {
    width: 20px;
}

.menu-item:hover {
    background: #8B4513;
    color: #FFF5E6;
    transform: translateY(-3px);
    box-shadow: 
        8px 8px 15px rgba(139, 69, 19, 0.3),
        -5px -5px 10px rgba(255, 255, 255, 0.8);
}

.menu-item.active {
    background: #8B4513;
    color: #FFF5E6;
    box-shadow: inset 3px 3px 8px rgba(0, 0, 0, 0.3);
}

/* Main Content dengan efek 3D */
.main-content {
    flex: 1;
    margin-left: 30px;
    background: #FFF5E6;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 
        20px 20px 30px rgba(0, 0, 0, 0.3),
        -5px -5px 15px rgba(255, 255, 255, 0.5),
        inset 0 -3px 8px rgba(139, 69, 19, 0.1);
    transform: rotateY(-2deg) rotateX(1deg);
    transition: transform 0.3s ease;
    border: 1px solid rgba(139, 69, 19, 0.1);
}

.main-content:hover {
    transform: rotateY(-1deg) rotateX(0.5deg);
}

/* Section styling */
.section {
    display: none;
}

.section.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header section */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.section-header h2 {
    color: #8B4513;
    font-size: 24px;
}

/* Button styling dengan efek 3D */
.btn-primary {
    background: #8B4513;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 
        5px 5px 10px rgba(139, 69, 19, 0.3),
        -3px -3px 8px rgba(255, 255, 255, 0.5);
    transition: all 0.3s;
}

.btn-primary:hover {
    background: #D2691E;
    transform: translateY(-3px);
    box-shadow: 
        8px 8px 15px rgba(139, 69, 19, 0.4),
        -5px -5px 10px rgba(255, 255, 255, 0.6);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: inset 3px 3px 8px rgba(0, 0, 0, 0.3);
}

.btn-edit {
    background: #D2691E;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    margin-right: 5px;
    box-shadow: 3px 3px 6px rgba(0, 0, 0, 0.2);
}

.btn-delete {
    background: #dc3545;
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    box-shadow: 3px 3px 6px rgba(0, 0, 0, 0.2);
}

/* Stats Cards dengan efek 3D */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 
        10px 10px 20px rgba(139, 69, 19, 0.2),
        -5px -5px 15px rgba(255, 255, 255, 0.8);
    text-align: center;
    transform: translateY(0);
    transition: all 0.3s;
}

.stat-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 
        15px 15px 25px rgba(139, 69, 19, 0.3),
        -8px -8px 20px rgba(255, 255, 255, 0.9);
}

.stat-card i {
    font-size: 40px;
    color: #8B4513;
    margin-bottom: 15px;
}

.stat-card h3 {
    color: #D2691E;
    font-size: 16px;
    margin-bottom: 10px;
}

.stat-card p {
    color: #8B4513;
    font-size: 28px;
    font-weight: 600;
}

/* Table styling dengan efek 3D */
.table-container {
    background: white;
    border-radius: 15px;
    padding: 20px;
    overflow-x: auto;
    box-shadow: 
        inset 0 2px 5px rgba(139, 69, 19, 0.1),
        10px 10px 20px rgba(139, 69, 19, 0.15);
}

table {
    width: 100%;
    border-collapse: collapse;
}

th {
    background: #8B4513;
    color: white;
    padding: 15px;
    text-align: left;
    font-weight: 500;
}

td {
    padding: 12px 15px;
    border-bottom: 1px solid #eee;
    color: #333;
}

tr:hover {
    background: #f9f9f9;
}

/* Status badge */
.status-badge {
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.status-lunas {
    background: #28a745;
    color: white;
}

.status-belum {
    background: #dc3545;
    color: white;
}

/* Filter section */
.filter-section {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.filter-section select,
.filter-section input {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
    box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.1);
}

.filter-section select {
    width: 200px;
}

.filter-section input {
    flex: 1;
}

/* Modal styling dengan efek 3D */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.modal-content {
    background: #FFF5E6;
    margin: 5% auto;
    width: 90%;
    max-width: 500px;
    border-radius: 20px;
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.4),
        inset 0 -3px 8px rgba(139, 69, 19, 0.2);
    transform: rotateX(2deg);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        transform: rotateX(10deg) translateY(-50px);
        opacity: 0;
    }
    to {
        transform: rotateX(2deg) translateY(0);
        opacity: 1;
    }
}

.pdf-modal {
    max-width: 800px;
}

.modal-header {
    padding: 20px;
    background: #8B4513;
    color: white;
    border-radius: 20px 20px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-size: 18px;
}

.close {
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s;
}

.close:hover {
    color: #D2691E;
}

.modal-body {
    padding: 25px;
}

/* Form styling */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #8B4513;
    font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s;
    box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.1);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #8B4513;
    box-shadow: 0 0 0 3px rgba(139, 69, 19, 0.2);
}

.form-group input[readonly] {
    background: #f5f5f5;
    cursor: not-allowed;
}

/* Chart container */
.chart-container {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 
        10px 10px 20px rgba(139, 69, 19, 0.2),
        -5px -5px 15px rgba(255, 255, 255, 0.8);
}

.chart-container h3 {
    color: #8B4513;
    margin-bottom: 20px;
}

.category-stats {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.category-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.category-item span {
    width: 80px;
    color: #8B4513;
    font-weight: 500;
}

.progress-bar {
    flex: 1;
    height: 25px;
    background: #f0f0f0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.1);
}

.progress {
    height: 100%;
    background: linear-gradient(90deg, #8B4513, #D2691E);
    color: white;
    font-size: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: width 0.3s ease;
    box-shadow: 0 3px 8px rgba(139, 69, 19, 0.3);
}

/* Rekap section */
.rekap-section {
    margin-bottom: 30px;
}

.rekap-section h3 {
    color: #8B4513;
    margin-bottom: 20px;
}

.rekap-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.rekap-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 
        8px 8px 15px rgba(139, 69, 19, 0.15),
        -5px -5px 10px rgba(255, 255, 255, 0.8);
}

.rekap-card h4 {
    color: #D2691E;
    font-size: 14px;
    margin-bottom: 10px;
}

.rekap-card p {
    color: #8B4513;
    font-size: 20px;
    font-weight: 600;
}

/* Invoice preview */
.invoice-preview {
    background: white;
    padding: 30px;
    border-radius: 12px;
    margin-top: 20px;
    box-shadow: inset 2px 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
}

.watermark {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-30deg);
    font-size: 60px;
    font-weight: bold;
    color: rgba(255, 0, 0, 0.2);
    white-space: nowrap;
    pointer-events: none;
    z-index: 1;
}

.invoice-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #8B4513;
}

.invoice-header h2 {
    color: #8B4513;
    font-size: 24px;
    margin-bottom: 5px;
}

.invoice-details {
    margin-bottom: 30px;
}

.invoice-details p {
    margin-bottom: 5px;
    color: #333;
}

.invoice-table {
    width: 100%;
    margin-bottom: 30px;
}

.invoice-table th {
    background: #8B4513;
    color: white;
    padding: 10px;
}

.invoice-table td {
    padding: 8px;
    border: 1px solid #ddd;
}

.invoice-total {
    text-align: right;
    font-size: 18px;
    font-weight: bold;
    color: #8B4513;
}

.pdf-actions {
    text-align: right;
    margin-bottom: 20px;
}

/* Responsive */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        margin-bottom: 20px;
        transform: none;
    }
    
    .main-content {
        margin-left: 0;
        transform: none;
    }
    
    .stats-container {
        grid-template-columns: 1fr;
    }
}