:root {
    --primary: #2c3e50;
    --secondary: #3498db;
    --success: #27ae60;
    --danger: #e74c3c;
    --bg: #f4f7f6;
}

body { 
    font-family: 'Segoe UI', Arial, sans-serif; 
    background-color: var(--bg); 
    margin: 0; padding: 20px; 
}

/* --- APP UI STYLING --- */
.app-container { max-width: 1100px; margin: auto; }
.main-header { text-align: center; margin-bottom: 30px; }
.main-header h1 { color: var(--primary); margin: 0; }

.entry-card {
    background: white;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    margin-bottom: 30px;
    border-top: 8px solid var(--secondary);
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.input-group { display: flex; flex-direction: column; gap: 8px; }
label { font-weight: bold; font-size: 0.85rem; color: #666; text-transform: uppercase; }
input, select, textarea {
    padding: 12px; border: 1px solid #ccc; border-radius: 8px; font-size: 1rem;
}

.hidden { display: none !important; }
.custom-input { border: 2px solid #e67e22 !important; background-color: #fffaf5; }
textarea { grid-column: span 2; height: 80px; }

.btn-container {
    margin-top: 20px; display: flex; gap: 12px; justify-content: flex-end; grid-column: span 2;
}
button {
    padding: 12px 24px; border: none; border-radius: 8px; cursor: pointer; font-weight: bold; transition: 0.2s;
}
.btn-save { background: var(--success); color: white; }
.btn-download { background: var(--secondary); color: white; }
.btn-clear { background: #ddd; color: #666; }
button:hover { opacity: 0.8; transform: translateY(-2px); }

.table-container {
    overflow-x: auto; background: white; border-radius: 15px; box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { padding: 15px; border-bottom: 1px solid #eee; }
th { background: var(--primary); color: white; font-size: 0.8rem; text-transform: uppercase; }

/* --- RSL REPORT STYLING (The Image Match) --- */
.rsl-report-page {
    width: 1120px; /* Optimized for Landscape A4 */
    padding: 40px;
    background: white;
    color: black;
    font-family: 'Times New Roman', Times, serif;
}
.rsl-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 3px solid black;
    padding-bottom: 10px;
    margin-bottom: 20px;
}
.rsl-logo { height: 60px; }
.rsl-title { 
    font-size: 28pt; 
    text-align: center; 
    margin: 0; 
    flex-grow: 1; 
    text-transform: uppercase; 
    font-weight: bold; 
}

.rsl-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}
.rsl-table th, .rsl-table td {
    border: 1px solid black;
    padding: 10px;
    font-size: 11pt;
    height: 30px;
}
.rsl-table th {
    background-color: #333;
    color: white;
    text-align: left;
}

.rsl-footer {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr 1fr;
    border: 1px solid black;
    background: #f9f9f9;
}
.footer-item {
    padding: 10px;
    border-right: 1px solid black;
    font-size: 11pt;
    font-weight: bold;
}
.footer-item:last-child { border-right: none; }

.rsl-gallery-title {
    text-align: center;
    font-size: 18pt;
    margin-top: 30px;
    text-transform: uppercase;
    text-decoration: underline;
}
#pdf-gallery {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 20px;
}
#pdf-gallery img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border: 1px solid black;
}
