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

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  font-size: 13px;
  line-height: 1.4;
  color: #333;
  background: #f0f0f0;
}

a {
  color: #0066cc;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 10px 15px;
}

header {
  background: #2c3e50;
  color: white;
  padding: 8px 15px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 3px solid #1a252f;
}

header h1 {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

header nav {
  display: flex;
  gap: 15px;
  align-items: center;
}

header nav a {
  color: #ecf0f1;
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 3px;
  transition: background 0.2s;
}

header nav a:hover {
  background: rgba(255,255,255,0.1);
  text-decoration: none;
}

header nav a.active {
  background: rgba(255,255,255,0.2);
}

.user-info {
  font-size: 11px;
  color: #bdc3c7;
  display: flex;
  align-items: center;
  gap: 10px;
}

.logout-btn {
  background: #c0392b;
  color: white !important;
  padding: 4px 12px !important;
  border-radius: 3px;
  font-size: 11px;
}

.logout-btn:hover {
  background: #a93226;
}

h2 {
  font-size: 15px;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid #ddd;
}

h3 {
  font-size: 13px;
  font-weight: 600;
  color: #34495e;
  margin-bottom: 8px;
}

.login-page {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
}

.login-box {
  background: white;
  padding: 30px;
  border-radius: 4px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
  width: 320px;
}

.login-box h1 {
  font-size: 18px;
  text-align: center;
  margin-bottom: 20px;
  color: #2c3e50;
}

.form-group {
  margin-bottom: 12px;
}

.form-group label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: #7f8c8d;
  text-transform: uppercase;
  margin-bottom: 4px;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #bdc3c7;
  border-radius: 3px;
  font-size: 13px;
  transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #3498db;
}

.form-group textarea {
  resize: vertical;
  min-height: 60px;
}

.btn {
  display: inline-block;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 600;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}

.btn-primary {
  background: #3498db;
  color: white;
}

.btn-primary:hover {
  background: #2980b9;
  text-decoration: none;
}

.btn-secondary {
  background: #95a5a6;
  color: white;
}

.btn-secondary:hover {
  background: #7f8c8d;
}

.btn-success {
  background: #27ae60;
  color: white;
}

.btn-success:hover {
  background: #229954;
}

.btn-sm {
  padding: 4px 10px;
  font-size: 11px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.metric-tile {
  background: white;
  border: 1px solid #ddd;
  border-radius: 3px;
  padding: 15px;
  text-align: center;
}

.metric-tile .value {
  font-size: 28px;
  font-weight: 700;
  color: #2c3e50;
}

.metric-tile .label {
  font-size: 11px;
  color: #7f8c8d;
  text-transform: uppercase;
  margin-top: 4px;
}

.metric-tile.warning .value {
  color: #e67e22;
}

.metric-tile.danger .value {
  color: #c0392b;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border: 1px solid #ddd;
  font-size: 12px;
}

table th,
table td {
  padding: 8px 10px;
  text-align: left;
  border-bottom: 1px solid #eee;
}

table th {
  background: #ecf0f1;
  font-weight: 600;
  color: #2c3e50;
  font-size: 11px;
  text-transform: uppercase;
  border-bottom: 2px solid #bdc3c7;
}

table tr:hover {
  background: #f9f9f9;
}

table tr:nth-child(even) {
  background: #fafafa;
}

table tr:nth-child(even):hover {
  background: #f5f5f5;
}

.status-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 3px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
}

.status-RECEIVED {
  background: #3498db;
  color: white;
}

.status-NEEDS_REVIEW {
  background: #e67e22;
  color: white;
}

.status-APPROVED {
  background: #27ae60;
  color: white;
}

.status-EXCEPTION {
  background: #c0392b;
  color: white;
}

.card {
  background: white;
  border: 1px solid #ddd;
  border-radius: 3px;
  margin-bottom: 15px;
}

.card-header {
  background: #ecf0f1;
  padding: 10px 15px;
  border-bottom: 1px solid #ddd;
  font-weight: 600;
  font-size: 13px;
  color: #2c3e50;
}

.card-body {
  padding: 15px;
}

.search-form {
  display: flex;
  gap: 10px;
  margin-bottom: 15px;
  flex-wrap: wrap;
  align-items: flex-end;
}

.search-form .form-group {
  margin-bottom: 0;
}

.filter-bar {
  background: white;
  border: 1px solid #ddd;
  border-radius: 3px;
  padding: 12px 15px;
  margin-bottom: 15px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: flex-end;
}

.filter-bar .form-group {
  margin-bottom: 0;
  flex: 1;
  min-width: 120px;
}

.filter-bar .form-group input,
.filter-bar .form-group select {
  padding: 6px 8px;
  font-size: 12px;
}

.banner {
  padding: 10px 15px;
  border-radius: 3px;
  margin-bottom: 15px;
  font-size: 12px;
}

.banner-success {
  background: #d4edda;
  border: 1px solid #c3e6cb;
  color: #155724;
}

.banner-warning {
  background: #fff3cd;
  border: 1px solid #ffeeba;
  color: #856404;
}

.banner-error {
  background: #f8d7da;
  border: 1px solid #f5c6cb;
  color: #721c24;
}

.banner-info {
  background: #d1ecf1;
  border: 1px solid #bee5eb;
  color: #0c5460;
}

.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 15px;
}

.detail-item {
  display: flex;
  flex-direction: column;
}

.detail-item .label {
  font-size: 10px;
  color: #7f8c8d;
  text-transform: uppercase;
  margin-bottom: 2px;
}

.detail-item .value {
  font-size: 13px;
  color: #2c3e50;
  font-weight: 500;
}

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

.form-section {
  margin-bottom: 20px;
  padding-bottom: 15px;
  border-bottom: 1px solid #eee;
}

.form-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.pdf-preview {
  border: 1px solid #ddd;
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 15px;
}

.pdf-preview iframe {
  width: 100%;
  height: 500px;
  border: none;
}

.activity-log {
  font-size: 12px;
}

.activity-log .activity-item {
  padding: 8px 0;
  border-bottom: 1px solid #eee;
  display: flex;
  gap: 10px;
}

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

.activity-log .timestamp {
  color: #7f8c8d;
  font-size: 11px;
  white-space: nowrap;
}

.activity-log .action {
  font-weight: 600;
}

.activity-log .actor {
  color: #3498db;
}

.activity-log .detail {
  color: #7f8c8d;
  font-size: 11px;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
}

.page-header h2 {
  margin-bottom: 0;
  border-bottom: none;
  padding-bottom: 0;
}

.inline-form {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

.inline-form .form-group {
  margin-bottom: 0;
}

.amount {
  font-family: "Consolas", "Monaco", monospace;
}

.text-muted {
  color: #7f8c8d;
}

.text-right {
  text-align: right;
}

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 15px; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 15px; }
