* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ============================================
   LOGIN PAGE
   ============================================ */

.login-body {
    font-family: Arial, Helvetica, sans-serif;
    background: #1a3a5c;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-card {
    background: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    width: 100%;
    max-width: 380px;
}

.login-header {
    text-align: center;
    font-size: 22px;
    font-weight: bold;
    color: #1a3a5c;
    margin-bottom: 30px;
    letter-spacing: 0.5px;
}

.login-field {
    margin-bottom: 18px;
}

.login-field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #444;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.login-field input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
    font-family: inherit;
}

.login-field input:focus {
    outline: none;
    border-color: #1a3a5c;
}

.login-btn {
    width: 100%;
    padding: 12px;
    background: #1a3a5c;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    letter-spacing: 0.5px;
    margin-top: 5px;
}

.login-btn:hover {
    background: #15304d;
}

.login-error {
    text-align: center;
    color: #c53030;
    font-size: 13px;
    margin-top: 12px;
    min-height: 18px;
}

/* ============================================
   DASHBOARD
   ============================================ */

.dashboard-body {
    font-family: Arial, Helvetica, sans-serif;
    background: #f0f2f5;
    min-height: 100vh;
    color: #222;
}

.dashboard-header {
    background: #1a3a5c;
    color: #fff;
    padding: 0 30px;
    height: 60px;
    display: flex;
    align-items: center;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
}

.header-content h1 {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.header-back {
    color: #b0c4de;
    text-decoration: none;
    font-size: 13px;
    white-space: nowrap;
}

.header-back:hover {
    color: #fff;
}

.logout-btn {
    background: transparent;
    border: 1px solid rgba(255,255,255,0.3);
    color: #fff;
    padding: 6px 16px;
    border-radius: 4px;
    font-size: 12px;
    cursor: pointer;
}

.logout-btn:hover {
    background: rgba(255,255,255,0.1);
}

.dashboard-main {
    max-width: 1000px;
    margin: 0 auto;
    padding: 40px 30px;
}

.dashboard-main h2 {
    font-size: 24px;
    color: #1a3a5c;
    margin-bottom: 6px;
}

.dashboard-subtitle {
    color: #666;
    font-size: 14px;
    margin-bottom: 30px;
}

.report-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.report-card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 30px 24px;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s;
    cursor: pointer;
}

.report-card:hover {
    border-color: #1a3a5c;
    box-shadow: 0 2px 12px rgba(26,58,92,0.12);
    transform: translateY(-2px);
}

.report-card.disabled {
    opacity: 0.4;
    cursor: default;
    pointer-events: none;
}

.report-icon {
    font-size: 32px;
    margin-bottom: 12px;
}

.report-name {
    font-size: 16px;
    font-weight: 600;
    color: #1a3a5c;
    margin-bottom: 6px;
}

.report-desc {
    font-size: 12px;
    color: #666;
    line-height: 1.4;
}

/* ============================================
   REPORT FORM
   ============================================ */

.report-main {
    padding: 20px;
}

.page {
    max-width: 780px;
    margin: 0 auto;
    background: #fff;
    padding: 40px 50px 30px;
    box-shadow: 0 1px 6px rgba(0,0,0,0.15);
    position: relative;
}

.form-title {
    text-align: center;
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.form-subtitle {
    text-align: center;
    font-size: 9.5px;
    color: #333;
    line-height: 1.5;
    margin-bottom: 16px;
}

/* Sections */
.section {
    border-top: 1px solid #999;
    padding: 8px 0;
}

.section:last-of-type {
    border-bottom: 1px solid #999;
}

.section.conditional-required {
    border-left: 3px solid #c53030;
    padding-left: 8px;
}

/* Rows & Fields */
.row {
    display: flex;
    gap: 20px;
    align-items: flex-end;
}

.field {
    margin-bottom: 2px;
}

.flex-1 { flex: 1; }
.flex-2 { flex: 2; }

.field-label {
    font-size: 10.5px;
    color: #222;
}

.field-label strong {
    font-size: 11px;
}

/* Underline inputs */
.underline-input {
    border: none;
    border-bottom: 1px solid #666;
    outline: none;
    font-size: 11px;
    font-family: Arial, Helvetica, sans-serif;
    padding: 2px 4px;
    background: #f5f7fa;
    color: #111;
    width: 100%;
    margin-top: 1px;
}

.underline-input:focus {
    border-bottom-color: #222;
    background: #f0f2ff;
}

.underline-input.full {
    width: 100%;
    display: block;
    margin-top: 2px;
}

.underline-input.inline-input {
    width: auto;
    display: inline-block;
    vertical-align: middle;
    margin-left: 4px;
}

.underline-input[readonly] {
    background: #eef0f3;
    color: #555;
    cursor: default;
}

.underline-input:disabled {
    background: #eee;
    border-bottom-color: #ccc;
    color: #999;
}

.underline-input.invalid {
    border-bottom: 2px solid #c53030;
    background: #fff5f5;
}

.underline-input.disabled-visual {
    background: #eee;
    border-bottom-color: #ccc;
    color: #999;
}

/* Textarea */
.textarea-field {
    width: 100%;
    border: 1px solid #999;
    border-radius: 0;
    font-size: 11px;
    font-family: Arial, Helvetica, sans-serif;
    padding: 6px 8px;
    resize: vertical;
    outline: none;
    margin-top: 6px;
    color: #111;
    background: #f5f7fa;
}

.textarea-field:focus {
    border-color: #444;
    background: #f0f2ff;
}

.textarea-field.invalid {
    border-color: #c53030;
    background: #fff5f5;
}

/* Radio & Checkbox */
.radio-group, .checkbox-group {
    display: inline;
    margin-left: 8px;
}

.radio, .checkbox {
    font-size: 10.5px;
    cursor: pointer;
    margin-right: 12px;
    white-space: nowrap;
}

.radio input[type="radio"],
.checkbox input[type="checkbox"] {
    width: 12px;
    height: 12px;
    margin-right: 3px;
    vertical-align: middle;
    accent-color: #333;
    cursor: pointer;
}

/* Field errors */
.field-error {
    display: block;
    font-size: 9.5px;
    color: #c53030;
    min-height: 14px;
    margin-top: 2px;
}

/* CPR status */
.cpr-status {
    font-size: 10px;
    margin-top: 4px;
    min-height: 14px;
}

.cpr-status.found {
    color: #276749;
}

.cpr-status.not-found {
    color: #c53030;
}

.cpr-status.searching {
    color: #666;
    font-style: italic;
}

/* Signature area */
.signature-area {
    display: flex;
    gap: 40px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #999;
    align-items: flex-end;
}

.stamp-box {
    flex: 1;
    border: 1px solid #666;
    height: 90px;
    position: relative;
}

.stamp-label {
    position: absolute;
    bottom: -18px;
    left: 0;
    font-size: 9px;
    color: #555;
}

.signature-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.signature-line {
    border-bottom: 1px solid #666;
    height: 60px;
}

.signature-label {
    font-size: 9px;
    color: #555;
    text-align: right;
    margin-top: 2px;
}

/* Submit button */
.form-actions {
    margin-top: 30px;
    text-align: center;
}

.submit-btn {
    background: #999;
    color: #fff;
    border: none;
    padding: 12px 36px;
    font-size: 13px;
    font-weight: 600;
    cursor: not-allowed;
    letter-spacing: 0.5px;
    border-radius: 4px;
    transition: background 0.2s;
}

.submit-btn.active {
    background: #1a3a5c;
    cursor: pointer;
}

.submit-btn.active:hover {
    background: #15304d;
}

/* Message */
.message {
    text-align: center;
    margin-top: 10px;
    font-size: 11px;
    min-height: 18px;
}

.message.success {
    color: #276749;
    font-weight: 500;
}

.message.error {
    color: #c53030;
    font-weight: 500;
}

/* Print styles */
@media print {
    .dashboard-header, .form-actions, .message, .field-error, .cpr-status { display: none; }
    body { background: white; }
    .page { box-shadow: none; padding: 20px 30px; max-width: 100%; }
    .underline-input:focus, .textarea-field:focus { background: transparent; }
}

/* Responsive */
@media (max-width: 600px) {
    .report-main { padding: 10px; }
    .page { padding: 20px 16px; }
    .row { flex-direction: column; gap: 6px; }
    .dashboard-main { padding: 20px 16px; }
    .header-content { padding: 0 10px; }
}
