/* --- MODERN RESET & VARIABLES --- */
:root {
    /* VIBRANT PALETTE */
    --primary-color: #1e3a8a;
    /* Deep Navy Blue */
    --secondary-color: #3b82f6;
    /* Bright Blue - Action */
    --success-color: #10b981;
    /* Emerald Green - Success */
    --warning-color: #f59e0b;
    /* Amber - Warning/Highlight */
    --accent-color: #ef4444;
    /* Red - Danger */

    /* Backgrounds */
    --light-bg: #f3f4f6;
    /* Light Gray */
    --white: #ffffff;

    /* Text */
    --text-dark: #111827;
    --text-muted: #6b7280;

    /* UI Elements */
    --border-radius: 12px;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);

    --font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
    font-family: var(--font-family);
    margin: 0;
    padding: 0;
    background-color: var(--light-bg);
    color: var(--text-dark);
    line-height: 1.6;
}

/* --- LAYOUT & CONTAINER --- */
.container {
    width: 90%;
    max-width: 1100px;
    margin: 2rem auto;
    padding: 2.5rem;
    background-color: var(--white);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md);
    position: relative;
}

/* --- TYPOGRAPHY --- */
h1,
h2,
h3,
h4,
h5,
h6 {
    color: var(--primary-color);
    margin-top: 0;
    font-weight: 700;
}

h1 {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 1rem;
}

h2 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 10px;
}

p {
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* --- HEADER --- */
header {
    background-color: var(--primary-color);
    /* Deep Navy Background */
    color: var(--white);
    padding: 1.5rem 0;
    text-align: center;
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
    border-bottom: 4px solid var(--warning-color);
    /* Amber Strip */
    position: relative;
    z-index: 100;
}

/* New Classes for Logos */
.header-logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
}

.header-logo {
    height: 75px;
    width: auto;
    /* This shadow works on the shape of the transparent image */
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
    transition: transform 0.3s ease;
}

.header-logo:hover {
    transform: scale(1.05);
}

header h1 {
    color: var(--white);
    margin: 0;
    font-size: 1.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

header p {
    color: rgba(255, 255, 255, 0.8);
    margin: 5px 0 0;
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 1px;
}

header a {
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

header a:hover {
    color: var(--white);
    text-decoration: underline;
}

/* --- HERO SECTION --- */
.hero-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, #2563eb 100%);
    color: var(--white);
    padding: 5rem 1rem 8rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    border-radius: 0 0 50px 50px;
    margin-bottom: 0;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 2.8rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    line-height: 1.2;
    color: var(--white);
    text-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.hero-subtitle {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 2.5rem;
    font-weight: 300;
    line-height: 1.8;
}

/* --- BUTTONS --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
}

.btn-primary:hover {
    background-color: #1e40af;
}

.btn-hero {
    background-color: var(--warning-color);
    color: #fff;
    font-weight: 700;
    padding: 16px 45px;
    font-size: 1.15rem;
    box-shadow: 0 10px 25px rgba(245, 158, 11, 0.4);
}

.btn-hero:hover {
    background-color: #fbbf24;
    color: #fff;
}

.btn-success {
    background-color: var(--success-color);
    color: var(--white);
}

.btn-success:hover {
    background-color: #059669;
}

.btn-danger {
    background-color: var(--accent-color);
    color: var(--white);
}

.btn-danger:hover {
    background-color: #dc2626;
}

.btn-secondary {
    background-color: #e5e7eb;
    color: var(--text-dark);
}

.btn-secondary:hover {
    background-color: #d1d5db;
}

.btn-excel {
    background-color: #217346;
    color: white;
    border-radius: 6px;
    font-size: 0.9rem;
}

/* --- FORMS --- */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    background-color: #f9fafb;
    font-size: 1rem;
    font-family: inherit;
    transition: all 0.2s;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
    background-color: var(--white);
}

.form-group small {
    display: block;
    margin-top: 5px;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* --- TABLES --- */
.content-table {
    width: 100%;
    border-collapse: collapse;
    margin: 25px 0;
    font-size: 0.95rem;
    border-radius: 8px 8px 0 0;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    border: 1px solid #eee;
}

.content-table thead tr {
    background-color: var(--primary-color);
    color: var(--white);
    text-align: left;
}

.content-table th,
.content-table td {
    padding: 15px;
}

.content-table tbody tr {
    border-bottom: 1px solid #f3f4f6;
}

.content-table tbody tr:nth-of-type(even) {
    background-color: #f9fafb;
}

.content-table tbody tr:hover {
    background-color: #eff6ff;
}

/* --- STATUS BADGES --- */
.status {
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    display: inline-block;
}

.status-pemeriksaan-usulan {
    background-color: #eff6ff;
    color: #1d4ed8;
}

.status-perubahan {
    background-color: #fffbeb;
    color: #b45309;
}

.status-pemeriksaan-rumah {
    background-color: #ecfeff;
    color: #0e7490;
}

.status-pengerjaan {
    background-color: #fff7ed;
    color: #c2410c;
}

.status-tuntas {
    background-color: #ecfdf5;
    color: #047857;
}

.status-ditolak {
    background-color: #f8d7da;
    color: #c0392b;
}

/* --- CARDS & STATS --- */
.stats-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 2rem;
}

.stat-card {
    background: var(--white);
    padding: 20px 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-left: 5px solid transparent;
    transition: transform 0.3s, box-shadow 0.3s;
    overflow: hidden;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.stat-content {
    text-align: left;
    z-index: 1;
}

.stat-card h3 {
    font-size: 2.5rem;
    margin: 0;
    line-height: 1;
    font-weight: 800;
    color: var(--text-dark);
}

.stat-card p {
    margin: 5px 0 0;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
}

.stat-icon {
    font-size: 2.5rem;
    opacity: 0.15;
    transform: rotate(-10deg);
    transition: transform 0.3s, opacity 0.3s;
}

.stat-card:hover .stat-icon {
    transform: rotate(0deg) scale(1.1);
    opacity: 0.3;
}

.stat-card.purple {
    border-left-color: #9b59b6;
}

.stat-card.purple h3 {
    color: #9b59b6;
}

.stat-card.purple .stat-icon {
    color: #9b59b6;
}

.stat-card.orange {
    border-left-color: #e67e22;
}

.stat-card.orange h3 {
    color: #e67e22;
}

.stat-card.orange .stat-icon {
    color: #e67e22;
}

.stat-card.blue {
    border-left-color: #3498db;
}

.stat-card.blue h3 {
    color: #3498db;
}

.stat-card.blue .stat-icon {
    color: #3498db;
}

.stat-card.green {
    border-left-color: #2ecc71;
}

.stat-card.green h3 {
    color: #2ecc71;
}

.stat-card.green .stat-icon {
    color: #2ecc71;
}

/* --- NOTIFICATIONS --- */
.notification {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 5px solid;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.notification-success {
    background-color: #ecfdf5;
    color: #065f46;
    border-color: #10b981;
}

.notification-info {
    background-color: #eff6ff;
    color: #1e40af;
    border-color: #3b82f6;
}

.notification-error {
    background-color: #fef2f2;
    color: #991b1b;
    border-color: #ef4444;
}

/* --- UTILITIES --- */
.damage-summary {
    padding: 20px;
    border-radius: var(--border-radius);
    color: white;
    font-weight: bold;
    margin-bottom: 20px;
    box-shadow: var(--shadow-md);
}

.damage-light {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.damage-medium {
    background: linear-gradient(135deg, #f97316, #c2410c);
}

.damage-heavy {
    background: linear-gradient(135deg, #ef4444, #b91c1c);
}

@media (max-width: 768px) {
    .container {
        width: 95%;
        padding: 1.5rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .content-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    .stats-container {
        grid-template-columns: 1fr;
    }
}