
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: 'Segoe UI', sans-serif; background: linear-gradient(135deg, #1565c0 0%, #0d47a1 100%); min-height: 100vh; padding: 15px; }
.container { max-width: 1000px; margin: 5px auto; background: white; border-radius: 12px; box-shadow: 0 20px 60px rgba(0,0,0,0.3); overflow: hidden; }
.header { background: linear-gradient(135deg, #1565c0, #0d47a1); color: white; padding: 15px 20px; display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.header h2 { font-size: 18px; font-weight: 800; }
.header-right { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.btn-back { background: rgba(255,255,255,0.2); color: white; border: 2px solid white; padding: 7px 13px; border-radius: 6px; font-weight: 600; font-size: 13px; text-decoration: none; }
.badge-count { background: white; color: #1565c0; padding: 4px 10px; border-radius: 20px; font-size: 12px; font-weight: 800; }
.content { padding: 16px 20px; }

/* Filtros */
.filters { display: flex; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.f-btn { padding: 6px 16px; border-radius: 20px; border: 2px solid #ddd; background: white; font-size: 12px; font-weight: 700; cursor: pointer; color: #555; }
.f-btn.active { background: #1565c0; color: white; border-color: #1565c0; }

/* Cards */
.sub-card { border: 2px solid #e0e0e0; border-radius: 12px; padding: 16px; margin-bottom: 12px; transition: all 0.2s; }
.sub-card.status-NEW { border-left: 4px solid #1565c0; }
.sub-card.status-REVIEWED { border-left: 4px solid #f57f17; }
.sub-card.status-APPROVED { border-left: 4px solid #2e7d32; opacity: 0.7; }
.sub-card.status-REJECTED { border-left: 4px solid #c62828; opacity: 0.6; }

.sub-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; margin-bottom: 12px; }
.sub-nome { font-size: 16px; font-weight: 800; color: #222; }
.sub-data { font-size: 11px; color: #aaa; margin-top: 2px; }

.status-badge { display: inline-block; padding: 3px 10px; border-radius: 12px; font-size: 11px; font-weight: 700; }
.sb-NEW { background: #e3f2fd; color: #1565c0; }
.sb-REVIEWED { background: #fff8e1; color: #f57f17; }
.sb-APPROVED { background: #e8f5e9; color: #2e7d32; }
.sb-REJECTED { background: #fdecea; color: #c62828; }

.sub-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 12px; }
.sub-field { background: #f9f9f9; border-radius: 8px; padding: 8px 10px; }
.sub-field .lbl { font-size: 10px; font-weight: 700; color: #888; text-transform: uppercase; margin-bottom: 2px; }
.sub-field .val { font-size: 12px; font-weight: 700; color: #333; word-break: break-word; }

.sub-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.btn-aprovar { background: #e8f5e9; color: #2e7d32; border: 2px solid #a5d6a7; padding: 8px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-aprovar:hover { background: #2e7d32; color: white; }
.btn-rejeitar { background: #fdecea; color: #c62828; border: 2px solid #ef9a9a; padding: 8px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-rejeitar:hover { background: #c62828; color: white; }
.btn-ver { background: #e3f2fd; color: #1565c0; border: 2px solid #90caf9; padding: 8px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-ver:hover { background: #1565c0; color: white; }
.btn-psa { background: #f3e5f5; color: #6a1b9a; border: 2px solid #ce93d8; padding: 8px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-psa:hover { background: #6a1b9a; color: white; }
.btn-cfd { background: #e8eaf6; color: #283593; border: 2px solid #9fa8da; padding: 8px 14px; border-radius: 8px; font-size: 12px; font-weight: 700; cursor: pointer; }
.btn-cfd:hover { background: #283593; color: white; }

/* Modal aprovar */
.modal-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 1000; align-items: center; justify-content: center; padding: 15px; }
.modal-overlay.open { display: flex; }
.modal { background: white; border-radius: 14px; padding: 24px; width: 100%; max-width: 480px; position: relative; max-height: 90vh; overflow-y: auto; }
.modal h3 { font-size: 17px; font-weight: 800; margin-bottom: 4px; color: #1565c0; }
.modal .sub-txt { font-size: 13px; color: #888; margin-bottom: 16px; }
.modal-close { position: absolute; top: 16px; right: 16px; background: none; border: none; font-size: 20px; cursor: pointer; }
.form-group { margin-bottom: 12px; }
.form-group label { display: block; font-size: 11px; font-weight: 700; color: #666; text-transform: uppercase; margin-bottom: 4px; }
.form-group input, .form-group select { width: 100%; padding: 9px 12px; border: 2px solid #e0e0e0; border-radius: 8px; font-size: 13px; outline: none; font-family: inherit; }
.form-group input:focus, .form-group select:focus { border-color: #1565c0; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn-save { background: #1565c0; color: white; border: none; padding: 12px 24px; border-radius: 8px; font-weight: 700; font-size: 14px; cursor: pointer; width: 100%; margin-top: 8px; }
.btn-cancel { background: #f5f5f5; color: #555; border: none; padding: 10px 24px; border-radius: 8px; font-weight: 700; font-size: 13px; cursor: pointer; width: 100%; margin-top: 6px; }

.info-box { background: #e3f2fd; border-radius: 8px; padding: 10px 12px; font-size: 12px; color: #1565c0; margin-bottom: 14px; }

.empty { text-align: center; padding: 40px; color: #aaa; font-size: 14px; }
.loading { text-align: center; padding: 40px; color: #aaa; font-size: 14px; }

@media (max-width: 600px) {
    .sub-grid { grid-template-columns: 1fr 1fr; }
    .header { flex-direction: column; }
    .form-row { grid-template-columns: 1fr; }
}
    .version { font-size: 10px; opacity: 0.5; text-align: right; padding: 4px 20px 8px; }

