/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8fafc;
    color: #333;
    line-height: 1.6;
}

/* Container - REMOVED (Using Ultimate Dashboard) */

/* Header Styling - REMOVED (Using Ultimate Dashboard Header) */
    color: #ffffff;
}

.user-name {
    font-weight: 500;
    color: #ffffff;
    font-size: 0.9rem;
}

.user-profile i.fa-chevron-down {
    font-size: 0.8rem;
    color: #e2e8f0;
    transition: transform 0.3s ease;
}

.user-profile.active i.fa-chevron-down {
    transform: rotate(180deg);
}

/* User Dropdown */
.user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 0.5rem;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border: 1px solid #e2e8f0;
    min-width: 280px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1001;
}

.user-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* User Info Section */
.user-info {
    padding: 1.5rem;
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    border-radius: 12px 12px 0 0;
}

.user-avatar {
    display: flex;
    justify-content: center;
    margin-bottom: 1rem;
}

.user-avatar i {
    font-size: 3rem;
    color: #3b82f6;
}

.user-details {
    text-align: center;
}

.user-fullname {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.25rem;
}

.user-role {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 0.25rem;
    font-weight: 500;
}

.user-email {
    font-size: 0.8rem;
    color: #94a3b8;
}

/* Dropdown Divider */
.dropdown-divider {
    height: 1px;
    background: #e2e8f0;
    margin: 0.5rem 0;
}

/* Dropdown Menu */
.dropdown-menu {
    padding: 0.75rem 0;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.5rem;
    color: #475569;
    text-decoration: none;
    transition: all 0.2s ease;
    font-size: 0.9rem;
}

.dropdown-item:hover {
    background: #f8fafc;
    color: #1e293b;
}

.dropdown-item i {
    width: 16px;
    text-align: center;
    color: #64748b;
}

.dropdown-item:hover i {
    color: #3b82f6;
}

/* Logout Button */
.logout-btn {
    color: #dc2626 !important;
    font-weight: 500;
}

.logout-btn:hover {
    background: #fef2f2 !important;
    color: #dc2626 !important;
}

.logout-btn i {
    color: #dc2626 !important;
}

.logout-btn:hover i {
    color: #dc2626 !important;
}

/* Main Content Layout - REMOVED (Using Ultimate Dashboard) */

/* Sidebar Styles - Moved to sidebar.css */

/* Content Area - REMOVED (Using Ultimate Dashboard) */

/* Filter Section */
.filter-section {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.filter-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
}

.btn-clear-filters {
    background: #ef4444;
    color: white;
    border: none;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background-color 0.2s;
}

.btn-clear-filters:hover {
    background: #dc2626;
}

.filter-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
}

.filter-group select {
    padding: 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    background: white;
    color: #374151;
}

.filter-group select:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.filter-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

.btn-apply-filters, .btn-export-filtered {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.2s;
}

.btn-apply-filters {
    background: #3b82f6;
    color: white;
}

.btn-apply-filters:hover {
    background: #2563eb;
}

.btn-export-filtered {
    background: #10b981;
    color: white;
}

.btn-export-filtered:hover {
    background: #059669;
}

/* Summary Cards */
.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.summary-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.card-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
}

.card-icon.warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.card-content h3 {
    font-size: 0.875rem;
    font-weight: 500;
    color: #6b7280;
    margin-bottom: 0.5rem;
}

.card-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
}

/* Problem Stats */
.problem-stats h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

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

.problem-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 0.5rem;
    border: 1px solid #e2e8f0;
}

.problem-label {
    font-size: 0.875rem;
    color: #374151;
    font-weight: 500;
}

.problem-value {
    font-size: 0.875rem;
    color: #3b82f6;
    font-weight: 600;
}

/* Province Summary */
.province-summary h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.province-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.province-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 0.5rem;
    border: 1px solid #e2e8f0;
}

.province-name {
    font-size: 0.875rem;
    color: #374151;
    font-weight: 500;
}

.province-stats {
    font-size: 0.875rem;
    color: #3b82f6;
    font-weight: 600;
}

/* Status Summary */
.status-summary h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

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

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 0.5rem;
    border: 1px solid #e2e8f0;
}

.status-label {
    font-size: 0.875rem;
    color: #374151;
    font-weight: 500;
}

.status-value {
    font-size: 0.875rem;
    color: #3b82f6;
    font-weight: 600;
}

/* Chart Sections */
.chart-section {
    margin-bottom: 2rem;
}

.chart-section h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.chart-container {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.chart-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background: #f8fafc;
    border-radius: 0.5rem;
    border: 1px solid #e2e8f0;
}

.chart-label {
    min-width: 120px;
    font-size: 0.875rem;
    color: #374151;
    font-weight: 500;
}

.chart-bar {
    flex: 1;
    height: 0.75rem;
    background: #e2e8f0;
    border-radius: 0.375rem;
    overflow: hidden;
}

.chart-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6 0%, #1d4ed8 100%);
    border-radius: 0.375rem;
    transition: width 0.3s ease;
}

.chart-value {
    min-width: 60px;
    font-size: 0.875rem;
    color: #3b82f6;
    font-weight: 600;
    text-align: right;
}

/* Cards */
.card {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    margin-bottom: 1.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.problem-card {
    border-left: 4px solid #3b82f6;
}

.followup-card {
    border-left: 4px solid #10b981;
}

.recommendation-card {
    border-left: 4px solid #f59e0b;
}

.status-card {
    border-left: 4px solid #8b5cf6;
}

.analysis-card {
    border-left: 4px solid #ef4444;
}

/* Problem Detail, Tindak Lanjut, Rekomendasi */
.problem-detail, .tindak-lanjut-detail, .rekomendasi-detail {
    margin-bottom: 1.5rem;
}

.problem-detail h4, .tindak-lanjut-detail h4, .rekomendasi-detail h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.problem-detail strong, .tindak-lanjut-detail strong, .rekomendasi-detail strong {
    color: #3b82f6;
    font-weight: 600;
}

.problem-detail p, .tindak-lanjut-content p, .rekomendasi-content p {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 1rem;
    font-size: 0.875rem;
    line-height: 1.6;
    color: #374151;
    margin-top: 0.5rem;
}

.problem-types h5 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin: 1.5rem 0 1rem 0;
}

/* Sample Problems, Tindak Lanjut, Rekomendasi */
.sample-problems, .sample-tindak-lanjut, .sample-rekomendasi {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.sample-problems h4, .sample-tindak-lanjut h4, .sample-rekomendasi h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.sample-problem, .sample-tindak, .sample-rekom {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.875rem;
    line-height: 1.5;
    color: #374151;
}

.sample-problem strong, .sample-tindak strong, .sample-rekom strong {
    color: #3b82f6;
    font-weight: 600;
}

/* Status Summary */
.status-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.status-section h4 {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

.status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #e2e8f0;
}

.status-item:last-child {
    border-bottom: none;
}

.status-value {
    padding: 0.25rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.875rem;
    font-weight: 500;
    background: #f3f4f6;
    color: #6b7280;
}

.status-value.active {
    background: #dbeafe;
    color: #1e40af;
}

/* No Results */
.no-results {
    text-align: center;
    padding: 2rem;
    color: #6b7280;
    font-style: italic;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 1024px) {
    .sidebar {
        width: 240px;
    }
    
    .filter-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
    
    .summary-cards {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
}

@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }
    
    .header {
        padding: 1rem;
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .header-left, .header-right {
        flex-direction: column;
        gap: 1rem;
    }
    
    .header-left {
        flex: none;
    }
    
    .project-info {
        max-width: none;
    }
    
    .project-location, .project-province {
        max-width: none;
        white-space: normal;
        text-overflow: clip;
    }
    
    .user-dropdown {
        right: -50px;
        min-width: 250px;
    }
    
    .logo {
        font-size: 1.2rem;
    }
    
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
        max-height: 300px;
    }
    
    .content {
        padding: 1rem;
    }
    
    .filter-grid {
        grid-template-columns: 1fr;
    }
    
    .filter-actions {
        flex-direction: column;
    }
    
    .summary-cards {
        grid-template-columns: 1fr;
    }
    
    .status-summary {
        grid-template-columns: 1fr;
    }
    
    .problem-grid {
        grid-template-columns: 1fr;
    }
    
    .status-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 0.75rem;
    }
    
    .header-right {
        justify-content: center;
    }
    
    .project-location {
        font-size: 0.9rem;
    }
    
    .project-province {
        font-size: 0.8rem;
    }
    
    .patent-year {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
    
    .card {
        padding: 1rem;
    }
    
    .summary-card {
        padding: 1rem;
    }
    
    .chart-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .chart-label {
        min-width: auto;
    }
    
    .chart-value {
        min-width: auto;
        text-align: left;
    }
}
