:root {
  --primary-color: #2b5aed;
  --primary-hover: #1f45c2;
  --bg-color: #f7f9fa;
  --sidebar-bg: #ffffff;
  --card-bg: #ffffff;
  --text-main: #1a1c21;
  --text-muted: #6b7280;
  --border-color: #e5e7eb;
  --accent-color: #f3f6ff;
  --success-color: #10b981;
  --warning-color: #f59e0b;
  --danger-color: #ef4444;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
  background-color: var(--bg-color);
  color: var(--text-main);
  -webkit-font-smoothing: antialiased;
}

/* Layout */
.app-container {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* Sidebar */
.sidebar {
  width: 260px;
  background-color: var(--sidebar-bg);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.sidebar.collapsed {
  width: 70px;
}
.sidebar.collapsed .nav-item {
  justify-content: center;
}
.sidebar.collapsed .nav-item svg {
  margin-right: 0;
}
.sidebar.collapsed .user-profile {
  justify-content: center;
}
.sidebar.collapsed .user-avatar {
  margin-right: 0;
}
.sidebar.collapsed .nav-item span {
  display: none;
}
.sidebar.collapsed .logout-btn {
  display: none !important;
}
.collapse-toggle-btn:hover {
  background-color: #f3f4f6 !important;
}

.logo-container {
  height: 70px;
  display: flex;
  align-items: center;
  padding: 0 20px;
  font-size: 24px;
  font-weight: 800;
  color: var(--primary-color);
  border-bottom: 1px solid var(--border-color);
  justify-content: space-between;
}

.nav-section {
  padding: 16px 12px;
}

.nav-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  font-weight: 700;
  margin-bottom: 8px;
  padding: 0 12px;
}

.nav-item {
  display: flex;
  align-items: center;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--text-main);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
  margin-bottom: 4px;
  transition: all 0.2s;
  cursor: pointer;
}

.nav-item svg {
  margin-right: 12px;
  color: var(--text-muted);
  width: 18px;
  height: 18px;
  transition: all 0.2s;
}

.nav-item:hover {
  background-color: var(--bg-color);
}

.nav-item.active {
  background-color: var(--primary-color);
  color: white;
}

.nav-item.active svg {
  color: white;
}

.user-profile {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  cursor: pointer;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--primary-color);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  margin-right: 12px;
}

.user-info {
  display: flex;
  flex-direction: column;
}

.user-name {
  font-size: 14px;
  font-weight: 600;
}

/* Main Content */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Header */
.header {
  height: 70px;
  background-color: var(--sidebar-bg);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  flex-shrink: 0;
}

.search-bar {
  display: flex;
  align-items: center;
  background-color: var(--bg-color);
  border-radius: 20px;
  padding: 8px 16px;
  width: 400px;
  border: 1px solid transparent;
  transition: all 0.2s;
}

.search-bar:focus-within {
  border-color: var(--primary-color);
  background-color: white;
  box-shadow: 0 0 0 3px rgba(43, 90, 237, 0.1);
}

.search-bar input {
  border: none;
  background: transparent;
  outline: none;
  width: 100%;
  margin-left: 8px;
  font-size: 14px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px 20px;
  border-radius: 20px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  gap: 8px;
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  box-shadow: 0 4px 12px rgba(43, 90, 237, 0.3);
}

.datetime-display {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
}

/* Page Content */
.page-container {
  padding: 24px;
  display: flex;
  gap: 20px;
  align-items: flex-start;
  min-height: calc(100vh - 64px);
  overflow-y: auto;
}

.main-column {
  flex: 1;
  min-width: 0;
}

.side-column {
  width: 300px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: sticky;
  top: 24px;
  max-height: calc(100vh - 88px);
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: none;
}
.side-column::-webkit-scrollbar { display: none; }

/* Card */
.card {
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05), 0 10px 20px -5px rgba(0,0,0,0.03);
  border: 1px solid var(--border-color);
  overflow: hidden;
  margin-bottom: 24px;
}

.card-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 16px;
}

.card-header.primary-header {
  background-color: var(--primary-color);
  color: white;
  border-bottom: none;
}

.card-icon {
  width: 40px;
  height: 40px;
  background: rgba(255,255,255,0.2);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-title {
  font-size: 18px;
  font-weight: 600;
}

.card-subtitle {
  font-size: 13px;
  opacity: 0.8;
  margin-top: 2px;
}

.card-body {
  padding: 24px;
}

/* Form Styles */
.form-section-title {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
  color: var(--text-main);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.required {
  color: var(--danger-color);
}

.form-control {
  padding: 10px 14px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 14px;
  outline: none;
  transition: all 0.2s;
  background-color: white;
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(43, 90, 237, 0.1);
}

select.form-control {
  appearance: none;
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

/* Toggle Group */
.toggle-group {
  display: flex;
  gap: 12px;
}

.toggle-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  background: white;
  gap: 8px;
}

.toggle-btn.active {
  border-color: var(--primary-color);
  background-color: var(--accent-color);
  color: var(--primary-color);
}

.radio-circle {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
}

.toggle-btn.active .radio-circle {
  border-color: var(--primary-color);
}

.toggle-btn.active .radio-circle::after {
  content: '';
  width: 8px;
  height: 8px;
  background: var(--primary-color);
  border-radius: 50%;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 24px;
}

.btn-large {
  padding: 12px 32px;
  border-radius: 8px;
  font-size: 15px;
  width: 100%;
}

/* Side Widgets */
.widget-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 15px;
}

.widget-body {
  padding: 20px;
}

/* Stepper */
.stepper {
  display: flex;
  flex-direction: column;
  position: relative;
}

.stepper::before {
  content: '';
  position: absolute;
  top: 10px;
  bottom: 30px;
  left: 17px;
  width: 2px;
  background: var(--border-color);
  z-index: 1;
}

.step {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  position: relative;
  z-index: 2;
}

.step-icon-container {
  width: 36px;
  height: 36px;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-color);
}

.step.completed .step-icon-container {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.step-content {
  flex: 1;
}

.step-title {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}

.step-desc {
  font-size: 12px;
  color: var(--text-muted);
}

.step-status {
  width: 20px;
  height: 20px;
  background: var(--accent-color);
  color: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
}

/* SLA Items */
.sla-item {
  display: flex;
  align-items: center;
  margin-bottom: 20px;
  gap: 12px;
}

.sla-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 3px solid white;
  box-shadow: 0 0 0 1px var(--border-color);
}

.sla-dot.green { background: var(--success-color); box-shadow: 0 0 0 1px var(--success-color); }
.sla-dot.orange { background: var(--warning-color); box-shadow: 0 0 0 1px var(--warning-color); }
.sla-dot.red { background: var(--danger-color); box-shadow: 0 0 0 1px var(--danger-color); }

.sla-content {
  flex: 1;
}

.sla-title {
  font-size: 14px;
  font-weight: 600;
}

.sla-desc {
  font-size: 12px;
  color: var(--text-muted);
}

.sla-badge {
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}

.sla-badge.green { background: rgba(16, 185, 129, 0.1); color: var(--success-color); }
.sla-badge.orange { background: rgba(245, 158, 11, 0.1); color: var(--warning-color); }
.sla-badge.red { background: rgba(239, 68, 68, 0.1); color: var(--danger-color); }

/* Document Upload UI */
.upload-container {
  display: flex;
  flex-direction: column;
  gap: 24px;
  margin-top: 24px;
}

.upload-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: white;
  border-radius: 8px;
}

.upload-header {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.upload-icon {
  color: #374151;
}

.upload-text {
  display: flex;
  flex-direction: column;
}

.upload-text h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #111827;
}

.upload-text p {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #6b7280;
}

.upload-text p a {
  color: #2b5aed;
  text-decoration: none;
  font-weight: 500;
}

.file-input-wrapper {
  display: flex;
  align-items: center;
  background-color: #f9fafb;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.file-input-wrapper input[type="file"] {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  z-index: 10;
}

.file-input-text {
  flex: 1;
  padding: 12px 16px;
  color: #6b7280;
  font-size: 14px;
}

.file-input-btn {
  background-color: #e0e7ff;
  color: #4338ca;
  padding: 12px 24px;
  font-weight: 500;
  font-size: 14px;
  border-left: 1px solid #c7d2fe;
}

.divider-or {
  display: flex;
  align-items: center;
  text-align: center;
  color: #4b5563;
  font-weight: 600;
  font-size: 14px;
  margin: 8px 0;
}

.divider-or::before,
.divider-or::after {
  content: '';
  flex: 1;
  border-bottom: 1px dashed #93c5fd;
}

.divider-or::before {
  margin-right: .5em;
}

.divider-or::after {
  margin-left: .5em;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 16px;
  margin-top: 32px;
}

.btn-outline {
  background: white;
  border: 1px solid #d1d5db;
  color: #374151;
  padding: 10px 16px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  text-align: center;
}

/* Dashboard Styles */
.dashboard-stats {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  flex: 1;
  background: white;
  border-radius: 12px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid #93c5fd;
  border-top: 4px solid #3b82f6;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  position: relative;
  overflow: hidden;
}

.stat-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 20px;
  background: linear-gradient(to top, rgba(219, 234, 254, 0.5), transparent);
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}

.stat-icon {
  background: #3b82f6;
  color: white;
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stat-content {
  display: flex;
  flex-direction: column;
}

.stat-value {
  font-size: 24px;
  font-weight: 700;
  color: #1e3a8a;
  line-height: 1;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 13px;
  color: #4b5563;
  font-weight: 500;
}

.dashboard-content {
  display: flex;
  gap: 24px;
}

.dashboard-main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.dashboard-sidebar {
  width: 320px;
  display: flex;
  flex-direction: column;
}

.dashboard-table {
  width: 100%;
  border-collapse: collapse;
}

.dashboard-table th {
  background: #f3f4f6;
  color: #4b5563;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  padding: 14px 16px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.dashboard-table td {
  padding: 16px;
  border-bottom: 1px solid #f3f4f6;
  font-size: 14px;
  color: #1f2937;
}

.dashboard-table tr:hover {
  background-color: #f9fafb;
}

.dashboard-table tr:nth-child(even) {
  background-color: #fcfcfc;
}

.status-down {
  color: #ef4444;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}

.team-list {
  display: flex;
  flex-direction: column;
}

.team-member {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid #e5e7eb;
}

.team-avatar {
  background: white;
  border: 1px solid #bfdbfe;
  color: #2563eb;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
}

.team-info {
  display: flex;
  flex-direction: column;
}

.team-name {
  font-size: 14px;
  font-weight: 600;
  color: #1f2937;
}

.team-role {
  font-size: 12px;
  color: #6b7280;
}

/* Pipeline status animations */
@keyframes spin {
  to { transform: rotate(360deg); }
}
@keyframes ping {
  0%   { transform: scale(1);   opacity: 0.5; }
  70%  { transform: scale(1.6); opacity: 0; }
  100% { transform: scale(1.6); opacity: 0; }
}

@keyframes shimmer {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(200%); }
}
@keyframes pulseNode {
  0%, 100% { box-shadow: 0 0 0 3px rgba(43,90,237,0.25); }
  50%       { box-shadow: 0 0 0 6px rgba(43,90,237,0.1); }
}
@keyframes fadeInOut {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.4; }
}

.nav-item-group { display: flex; flex-direction: column; }
.sub-menu { 
  display: flex; 
  flex-direction: column; 
  gap: 2px; 
  margin-top: 4px; 
  margin-bottom: 8px; 
  padding-left: 0;
}
.sub-nav-item { 
  text-decoration: none; 
  color: #64748b; 
  font-size: 13px; 
  padding: 8px 12px 8px 42px; 
  border-radius: 6px;
  transition: all 0.2s;
  font-weight: 500;
  display: flex;
  align-items: center;
}
.sub-nav-item:hover { 
  color: #3b82f6; 
  background: #f8fafc; 
}
.sub-nav-item.active { 
  background: #eff6ff; 
  color: #2563eb; 
  font-weight: 600; 
}
.order-details-container {
  background: white;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.order-header {
  padding: 16px 24px 0;
  border-bottom: 1px solid #e5e7eb;
}

.order-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 20px;
}

.order-title {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: #111827;
}

.badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.badge.dark {
  background: #1f2937;
  color: white;
}

.badge.warning {
  background: #fef3c7;
  color: #d97706;
}

.badge.light {
  background: #f3f4f6;
  color: #4b5563;
}

.order-actions {
  margin-left: auto;
  display: flex;
  gap: 8px;
}

.icon-btn {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 6px;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6b7280;
  cursor: pointer;
}

.icon-btn:hover {
  background: #f9fafb;
}

.order-tabs {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.tab-btn {
  background: none;
  border: none;
  padding: 12px 16px;
  font-size: 13px;
  font-weight: 500;
  color: #6b7280;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  border-bottom: 2px solid transparent;
}

.tab-btn.active {
  color: #2b5aed;
  border-bottom-color: #2b5aed;
  background: #eff6ff;
  border-top-left-radius: 6px;
  border-top-right-radius: 6px;
}

.btn-primary {
  background: #2b5aed;
  color: white;
  border: none;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  margin-bottom: 8px;
}

.order-content {
  flex: 1;
  overflow: hidden;
}

/* Findings Layout */
.findings-layout {
  display: flex;
  height: 100%;
}

.findings-sidebar {
  width: 380px;
  border-right: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.score-card {
  padding: 24px;
  border-bottom: 1px solid #e5e7eb;
}

.score-header {
  font-size: 11px;
  font-weight: 600;
  color: #6b7280;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

.score-circle {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  border: 4px solid #10b981;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.score-value {
  font-size: 28px;
  font-weight: 700;
  color: #10b981;
}

.score-label {
  font-size: 10px;
  font-weight: 600;
  color: #6b7280;
  margin-top: 4px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 16px;
  background: transparent;
}

.stat-box {
  background: white;
  border-radius: 8px;
  padding: 12px;
  text-align: center;
  transition: all 0.2s ease;
  user-select: none;
  border: 1px solid #e5e7eb;
}

.stat-box:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.stat-num {
  font-size: 18px;
  font-weight: 700;
  color: #111827;
}

.stat-label {
  font-size: 9px;
  font-weight: 700;
  color: #6b7280;
  margin-top: 4px;
}

.stat-box.success .stat-num { color: #10b981; }
.stat-box.danger .stat-num { color: #ef4444; }
.stat-box.warning .stat-num { color: #f59e0b; }
.stat-box.deferred .stat-num { color: #f97316; }
.stat-box.ai-review .stat-num { color: #8b5cf6; }
.stat-box.not-evaluated .stat-num { color: #475569; }
.stat-box.not-applicable .stat-num { color: #94a3b8; }

.stat-box.active-filter {
  border-color: #3b82f6;
  background: #eff6ff;
  box-shadow: inset 0 0 0 1px #3b82f6;
}

.stat-box.not-evaluated.active-filter {
  background: #f1f5f9;
  border-color: #64748b;
  box-shadow: inset 0 0 0 1px #64748b;
}

.stat-box.not-applicable.active-filter {
  background: #f8fafc;
  border-color: #94a3b8;
  box-shadow: inset 0 0 0 1px #94a3b8;
}

.filter-container {
  padding: 16px;
  border-bottom: 1px solid #e5e7eb;
}

.search-bar {
  display: flex;
  align-items: center;
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  padding: 8px 12px;
  margin-bottom: 16px;
}

.search-bar input {
  border: none;
  outline: none;
  flex: 1;
  font-size: 13px;
}

.filter-title {
  font-size: 11px;
  font-weight: 600;
  color: #6b7280;
  margin-bottom: 12px;
}

.filter-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.pill {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 500;
  color: #4b5563;
  cursor: pointer;
}

.pill.active {
  background: #8b5cf6;
  color: white;
  border-color: #8b5cf6;
}

.findings-list {
  flex: 1;
  padding: 16px;
}

.finding-item {
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 8px 12px;
  margin-bottom: 6px;
  border-left: 3px solid #10b981;
  box-shadow: none;
}

.finding-item.fatal { border-left-color: #ef4444; }
.finding-item.warnings { border-left-color: #f59e0b; }
.finding-item.deferred { border-left-color: #f97316; }
.finding-item.notevaluated { border-left-color: #6b7280; }

.finding-item-header {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

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

.finding-badge {
  font-size: 9px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid;
}

.finding-actions {
  display: flex;
  gap: 8px;
}

.finding-title {
  font-size: 12px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 4px;
}

.finding-desc {
  font-size: 12px;
  color: #6b7280;
}

/* Document Viewer */
.document-viewer {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #f9fafb;
}

.viewer-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  background: white;
  border-bottom: 1px solid #e5e7eb;
}

.pagination {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #6b7280;
  font-size: 13px;
}

.page-num {
  border: 1px solid #e5e7eb;
  padding: 2px 8px;
  border-radius: 4px;
  color: #2b5aed;
  background: #eff6ff;
}

.zoom {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #6b7280;
  font-size: 13px;
}

.viewer-actions {
  display: flex;
  gap: 16px;
  color: #6b7280;
}

.viewer-content {
  flex: 1;
  overflow: auto;
  padding: 24px;
  display: flex;
  justify-content: center;
}

.pdf-page {
  background: white;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
  width: 800px;
  min-height: 1000px;
  padding: 40px;
}

/* Order Info */
.order-info-tab {
  padding: 24px;
  overflow-y: auto;
  height: 100%;
}

.section-heading {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
  margin: 0 0 24px 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}

.info-label {
  font-size: 11px;
  font-weight: 600;
  color: #9ca3af;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 16px;
}

.info-sublabel {
  font-size: 11px;
  color: #6b7280;
  margin-bottom: 4px;
}

.info-val {
  font-size: 13px;
  font-weight: 500;
  color: #111827;
}

.divider {
  border: none;
  border-top: 1px solid #e5e7eb;
  margin: 32px 0;
}

/* Documents */
.documents-tab {
  padding: 24px;
  overflow-y: auto;
  height: 100%;
}

.docs-grid {
  display: flex;
  gap: 40px;
}

.docs-col {
  flex: 1;
}

.docs-col-header {
  font-size: 11px;
  font-weight: 600;
  color: #9ca3af;
  border-bottom: 1px solid #e5e7eb;
  padding-bottom: 8px;
  margin-bottom: 16px;
  display: flex;
  justify-content: center;
}

.docs-col:first-child .docs-col-header::before {
  content: "";
  display: block;
  width: 40%;
  border-top: 1px solid #e5e7eb;
  margin-right: 10px;
  margin-top: 6px;
}
.docs-col:first-child .docs-col-header::after {
  content: "";
  display: block;
  width: 40%;
  border-top: 1px solid #e5e7eb;
  margin-left: 10px;
  margin-top: 6px;
}
.docs-col:last-child .docs-col-header::before {
  content: "";
  display: block;
  width: 40%;
  border-top: 1px solid #e5e7eb;
  margin-right: 10px;
  margin-top: 6px;
}
.docs-col:last-child .docs-col-header::after {
  content: "";
  display: block;
  width: 40%;
  border-top: 1px solid #e5e7eb;
  margin-left: 10px;
  margin-top: 6px;
}

.doc-card {
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 16px;
}

.doc-icon {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.doc-icon.blue { background: #eff6ff; }
.doc-icon.green { background: #ecfdf5; }

.doc-info {
  flex: 1;
}

.doc-title {
  font-size: 14px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 4px;
}

.doc-desc {
  font-size: 12px;
  color: #6b7280;
}

.btn-outline {
  border: 1px solid #e5e7eb;
  background: white;
  color: #111827;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  text-decoration: none;
}

/* Scanner Loading */
.scanner-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  background: #f9fafb;
}

.scanner-card {
  background: white;
  border-radius: 16px;
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
  padding: 32px;
  width: 280px;
  position: relative;
  overflow: hidden;
  margin-bottom: 24px;
}

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

.logo-text {
  font-weight: 800;
  font-size: 20px;
  color: #2b5aed;
  letter-spacing: -0.5px;
}

.scanner-lines {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 32px;
}

.scanner-line {
  height: 8px;
  background: #f3f4f6;
  border-radius: 4px;
  width: 100%;
}

.scanner-line.half {
  width: 60%;
}

.scan-bar-container {
  position: absolute;
  left: 0;
  right: 0;
  top: 40%;
  height: 2px;
  background: #2b5aed;
  box-shadow: 0 0 10px #2b5aed;
  animation: scan 2s ease-in-out infinite alternate;
}

.scan-progress {
  position: absolute;
  left: 10px;
  top: 10px;
  font-size: 11px;
  font-weight: 600;
  color: #2b5aed;
}

.scanner-footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.sparkles {
  color: #8b5cf6;
  font-size: 20px;
  animation: pulse 1s infinite;
}

.scanner-status {
  background: white;
  padding: 12px 24px;
  border-radius: 24px;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 14px;
  font-weight: 500;
  color: #374151;
}

@keyframes scan {
  0% { top: 20%; }
  100% { top: 80%; }
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

/* Modal Overlay Styles */
.finding-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease-in-out;
}

.finding-modal-content {
  background: white;
  width: 100%;
  max-width: 650px;
  border-radius: 12px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  max-height: 90vh;
  animation: slideUp 0.2s ease-in-out;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  border-bottom: 1px solid #e5e7eb;
}

.modal-header h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #111827;
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.detail-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.detail-row {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.flex-1 {
  flex: 1;
  min-width: 250px;
}

.detail-label {
  font-size: 12px;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.detail-value {
  font-size: 14px;
  color: #374151;
  line-height: 1.5;
}

.detail-value.primary-text {
  font-size: 15px;
  font-weight: 500;
  color: #111827;
}

.detail-value.code-block {
  background-color: #f3f4f6;
  padding: 12px;
  border-radius: 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 13px;
  border: 1px solid #e5e7eb;
}

.empty-val {
  color: #9ca3af;
  font-style: italic;
}

.inline-badge {
  display: inline-flex;
  align-items: center;
  font-size: 13px;
  padding: 4px 10px;
  border: 1px solid transparent;
  border-radius: 12px;
}

.elaboration {
  background-color: #eff6ff;
  padding: 16px;
  border-radius: 8px;
  border-left: 4px solid #3b82f6;
}

.elaboration .detail-label {
  color: #2563eb;
}

.elaboration .detail-value.emphasis {
  color: #1e40af;
  font-style: italic;
  font-weight: 500;
  margin-top: 4px;
}

.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid #e5e7eb;
  display: flex;
  justify-content: flex-end;
  background-color: #f9fafb;
  border-bottom-left-radius: 12px;
  border-bottom-right-radius: 12px;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.finding-item:hover {
  background-color: #f9fafb;
}

.finding-item.selected {
  background-color: #eff6ff;
  border-left: 3px solid #3b82f6;
}

.stat-box.active-filter {
  background-color: #e0e7ff;
  border: 1px solid #4f46e5;
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.2);
}
/* =========================================================
   ReviewDocument — Modal Popup with PDF + Finding Markers
   ========================================================= */

/* Overlay */
.rd-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2000;
  background-color: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: rdFadeIn 0.25s ease-out;
}

@keyframes rdFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes rdSlideUp {
  from { opacity: 0; transform: translateY(24px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* Modal Container */
.rd-modal-container {
  width: 94vw;
  height: 90vh;
  max-width: 1600px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.35);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: rdSlideUp 0.3s ease-out;
}

/* Header */
.rd-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 24px;
  background: linear-gradient(135deg, #1e293b, #334155);
  color: white;
  flex-shrink: 0;
}

.rd-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.rd-header-left h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.rd-ref-badge {
  background: rgba(255, 255, 255, 0.15);
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.rd-header-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.rd-zoom-controls {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.1);
  padding: 4px 8px;
  border-radius: 8px;
}

.rd-zoom-controls button {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.12);
  border: none;
  border-radius: 4px;
  padding: 4px;
  color: white;
  cursor: pointer;
  transition: background 0.15s;
}

.rd-zoom-controls button:hover {
  background: rgba(255, 255, 255, 0.25);
}

.rd-zoom-label {
  font-size: 13px;
  font-weight: 600;
  min-width: 52px;
  text-align: center;
  color: rgba(255, 255, 255, 0.95);
  background: transparent !important;
  font-variant-numeric: tabular-nums;
}

.rd-zoom-controls .rd-fit-btn {
  gap: 4px;
  padding: 4px 8px;
  font-size: 12px;
  font-weight: 600;
  margin-left: 4px;
}

.rd-zoom-controls .rd-fit-btn.active {
  background: #3b82f6;
}

.rd-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: rgba(255, 255, 255, 0.8);
  cursor: pointer;
  user-select: none;
}

.rd-toggle input {
  accent-color: #3b82f6;
  cursor: pointer;
}

.rd-page-count {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.65);
  font-weight: 400;
}

.rd-close-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  border-radius: 8px;
  padding: 6px;
  color: white;
  cursor: pointer;
  transition: background 0.15s;
  margin-left: 4px;
}

.rd-close-btn:hover {
  background: rgba(239, 68, 68, 0.6);
}

/* Body */
.rd-modal-body {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* Sidebar */
.rd-sidebar {
  width: 380px;
  background: #ffffff;
  border-right: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.rd-sidebar-header {
  padding: 14px 16px 10px;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rd-sidebar-header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #111827;
  display: flex;
  align-items: center;
  gap: 8px;
}

.rd-findings-count {
  background: #e0e7ff;
  color: #3b5cf6;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 700;
}

.rd-sidebar-search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 6px 10px;
}

.rd-sidebar-search input {
  border: none;
  background: transparent;
  outline: none;
  flex: 1;
  font-size: 13px;
  color: #374151;
}

.rd-sidebar-search input::placeholder {
  color: #9ca3af;
}

/* Severity filter pills */
.rd-severity-filters {
  display: flex;
  gap: 6px;
  padding: 10px 16px;
  border-bottom: 1px solid #f3f4f6;
  flex-wrap: wrap;
}

.rd-sev-pill {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  background: #fafafa;
  font-size: 11px;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.rd-sev-pill:hover {
  background: #f3f4f6;
}

.rd-sev-pill.active {
  background: #1e293b;
  color: white;
  border-color: #1e293b;
}

.rd-sev-pill.fatal.active { background: #ef4444; border-color: #ef4444; }
.rd-sev-pill.warning.active { background: #f59e0b; border-color: #f59e0b; color: #1e293b; }
.rd-sev-pill.info.active { background: #3b82f6; border-color: #3b82f6; }

.rd-pill-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* Findings tree */
.rd-findings-tree {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
}

.rd-finding-category {
  margin-bottom: 4px;
}

.rd-category-header {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 8px;
  cursor: pointer;
  border-radius: 6px;
  user-select: none;
  color: #4b5563;
  font-size: 13px;
  transition: background 0.15s;
}

.rd-category-header:hover {
  background: #f3f4f6;
}

.rd-category-name {
  font-weight: 600;
  flex: 1;
  color: #374151;
}

.rd-category-count {
  background: #f3f4f6;
  color: #6b7280;
  padding: 1px 7px;
  border-radius: 10px;
  font-size: 11px;
  font-weight: 600;
}

.rd-category-items {
  margin-left: 12px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding: 2px 0;
}

.rd-finding-item {
  padding: 8px 10px;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.rd-finding-item:hover {
  background: #f9fafb;
  border-color: #e5e7eb;
}

.rd-finding-item.selected {
  background: #eff6ff;
  border-color: #bfdbfe;
  box-shadow: 0 0 0 1px #93c5fd;
}

.rd-finding-item.has-location {
  border-left: 2px solid #d1d5db;
}

.rd-finding-item.has-location.selected {
  border-left: 2px solid #3b82f6;
}

.rd-finding-top-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.rd-severity-badge {
  font-size: 9px;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 8px;
  border: 1px solid;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  flex-shrink: 0;
}

.rd-finding-rule-id {
  font-family: ui-monospace, monospace;
  font-size: 10px;
  color: #9ca3af;
  flex-shrink: 0;
}

.rd-location-indicator {
  font-size: 10px;
  margin-left: auto;
  color: #2563eb;
  font-weight: 600;
  white-space: nowrap;
}

.rd-location-indicator.page-only {
  color: #9ca3af;
  font-weight: 500;
}

.rd-finding-label {
  font-size: 12px;
  font-weight: 600;
  color: #1f2937;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rd-finding-msg {
  font-size: 11px;
  color: #6b7280;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* PDF Area */
.rd-pdf-area {
  flex: 1;
  overflow: auto;
  background: #374151;
  display: block;
  padding: 32px 48px;
  position: relative;
}

.rd-pdf-pages {
  display: flex;
  flex-direction: column;
  gap: 28px;
  align-items: center;
  width: max-content;
  min-width: 100%;
  margin: 0 auto;
}

.rd-pdf-page-wrapper {
  background: white;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  border-radius: 2px;
  position: relative;
  transition: box-shadow 0.25s ease;
}

.rd-pdf-page-wrapper.rd-page-active {
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.6), 0 8px 24px rgba(0, 0, 0, 0.35);
}

.rd-pdf-page-wrapper canvas {
  display: block;
}

.rd-page-number-badge {
  position: absolute;
  top: -20px;
  left: 0;
  font-size: 11px;
  color: rgba(255, 255, 255, 0.55);
  font-weight: 500;
}

/* Highlight Rect */
.rd-highlight-rect {
  transition: left 0.2s ease, top 0.2s ease, width 0.2s ease, height 0.2s ease;
}

.rd-highlight-selected {
  animation: rdFocusIn 0.5s ease-out, rdPulse 1.4s ease-in-out 0.5s infinite alternate;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--rd-glow) 35%, transparent),
              0 0 14px color-mix(in srgb, var(--rd-glow) 60%, transparent);
}

@keyframes rdFocusIn {
  0%   { transform: scale(2.2); opacity: 0; }
  60%  { transform: scale(0.95); opacity: 1; }
  100% { transform: scale(1); }
}

@keyframes rdPulse {
  from { box-shadow: 0 0 0 2px color-mix(in srgb, var(--rd-glow) 30%, transparent), 0 0 6px color-mix(in srgb, var(--rd-glow) 40%, transparent); }
  to   { box-shadow: 0 0 0 5px color-mix(in srgb, var(--rd-glow) 20%, transparent), 0 0 18px color-mix(in srgb, var(--rd-glow) 70%, transparent); }
}

.rd-highlight-page {
  animation: rdFadeIn 0.3s ease-out;
}

/* Pointer callout for the selected finding */
.rd-callout {
  position: absolute;
  transform: translateY(-100%);
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 6px;
  max-width: 420px;
  padding: 5px 10px;
  background: #111827;
  color: #f9fafb;
  border-left: 3px solid var(--rd-accent);
  border-radius: 6px;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
  pointer-events: none;
  animation: rdCalloutIn 0.35s ease-out;
}

.rd-callout::after {
  content: '';
  position: absolute;
  left: 10px;
  bottom: -6px;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 6px solid #111827;
}

.rd-callout.below {
  transform: none;
}

.rd-callout.below::after {
  bottom: auto;
  top: -6px;
  border-top: none;
  border-bottom: 6px solid #111827;
}

.rd-callout.page-level {
  transform: none;
}

.rd-callout.page-level::after {
  display: none;
}

.rd-callout-id {
  font-family: ui-monospace, monospace;
  font-weight: 700;
  color: var(--rd-accent);
}

.rd-callout-label {
  overflow: hidden;
  text-overflow: ellipsis;
}

.rd-callout-approx {
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #9ca3af;
  border: 1px solid #4b5563;
  border-radius: 4px;
  padding: 0 4px;
}

@keyframes rdCalloutIn {
  from { opacity: 0; margin-top: -6px; }
  to   { opacity: 1; margin-top: 0; }
}

/* Marker Dots */
.rd-marker-dot {
  transition: all 0.2s ease;
}

.rd-marker-dot:hover {
  transform: scale(1.4);
}

.rd-dot-selected {
  animation: rdDotPing 1s ease-in-out infinite alternate;
}

@keyframes rdDotPing {
  from { box-shadow: 0 0 4px currentColor; }
  to   { box-shadow: 0 0 12px currentColor; }
}

/* Loading / empty states */
.rd-loading-state {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 40px;
  color: rgba(255, 255, 255, 0.7);
  font-size: 14px;
}

.rd-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: rdSpin 0.6s linear infinite;
}

@keyframes rdSpin {
  to { transform: rotate(360deg); }
}

.rd-error-state {
  color: #f87171;
  padding: 40px;
  text-align: center;
}

.rd-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 14px;
  gap: 12px;
}

.rd-empty-findings {
  padding: 24px;
  text-align: center;
  color: #9ca3af;
  font-size: 13px;
}

/* Responsive */
@media (max-width: 900px) {
  .rd-modal-container {
    width: 98vw;
    height: 95vh;
    border-radius: 10px;
  }
  .rd-sidebar {
    width: 280px;
  }
  .rd-pdf-area {
    padding: 16px;
  }
}
/* Copyright 2014 Mozilla Foundation
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

:root {
  --react-pdf-annotation-layer: 1;
  --annotation-unfocused-field-background: url("data:image/svg+xml;charset=UTF-8,<svg width='1px' height='1px' xmlns='http://www.w3.org/2000/svg'><rect width='100%' height='100%' style='fill:rgba(0, 54, 255, 0.13);'/></svg>");
  --input-focus-border-color: Highlight;
  --input-focus-outline: 1px solid Canvas;
  --input-unfocused-border-color: transparent;
  --input-disabled-border-color: transparent;
  --input-hover-border-color: black;
  --link-outline: none;
}

@media screen and (forced-colors: active) {
  :root {
    --input-focus-border-color: CanvasText;
    --input-unfocused-border-color: ActiveText;
    --input-disabled-border-color: GrayText;
    --input-hover-border-color: Highlight;
    --link-outline: 1.5px solid LinkText;
  }
  .annotationLayer .textWidgetAnnotation :is(input, textarea):required,
  .annotationLayer .choiceWidgetAnnotation select:required,
  .annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) input:required {
    outline: 1.5px solid selectedItem;
  }

  .annotationLayer .linkAnnotation:hover {
    backdrop-filter: invert(100%);
  }
}

.annotationLayer {
  position: absolute;
  top: 0;
  left: 0;
  pointer-events: none;
  transform-origin: 0 0;
  z-index: 3;
}

.annotationLayer[data-main-rotation='90'] .norotate {
  transform: rotate(270deg) translateX(-100%);
}
.annotationLayer[data-main-rotation='180'] .norotate {
  transform: rotate(180deg) translate(-100%, -100%);
}
.annotationLayer[data-main-rotation='270'] .norotate {
  transform: rotate(90deg) translateY(-100%);
}

.annotationLayer canvas {
  position: absolute;
  width: 100%;
  height: 100%;
}

.annotationLayer section {
  position: absolute;
  text-align: initial;
  pointer-events: auto;
  box-sizing: border-box;
  margin: 0;
  transform-origin: 0 0;
}

.annotationLayer section .overlaidText {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  display: inline-block;
  overflow: hidden;
}

.annotationLayer .linkAnnotation {
  outline: var(--link-outline);
}

.textLayer.selecting ~ .annotationLayer section {
  pointer-events: none;
}

.annotationLayer :is(.linkAnnotation, .buttonWidgetAnnotation.pushButton) > a {
  position: absolute;
  font-size: 1em;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.annotationLayer :is(.linkAnnotation, .buttonWidgetAnnotation.pushButton) > a:hover {
  opacity: 0.2;
  background: rgba(255, 255, 0, 1);
  box-shadow: 0 2px 10px rgba(255, 255, 0, 1);
}

.annotationLayer .textAnnotation img {
  position: absolute;
  cursor: pointer;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.annotationLayer .textWidgetAnnotation :is(input, textarea),
.annotationLayer .choiceWidgetAnnotation select,
.annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) input {
  background-image: var(--annotation-unfocused-field-background);
  border: 2px solid var(--input-unfocused-border-color);
  box-sizing: border-box;
  font: calc(9px * var(--total-scale-factor)) sans-serif;
  height: 100%;
  margin: 0;
  vertical-align: top;
  width: 100%;
}

.annotationLayer .textWidgetAnnotation :is(input, textarea):required,
.annotationLayer .choiceWidgetAnnotation select:required,
.annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) input:required {
  outline: 1.5px solid red;
}

.annotationLayer .choiceWidgetAnnotation select option {
  padding: 0;
}

.annotationLayer .buttonWidgetAnnotation.radioButton input {
  border-radius: 50%;
}

.annotationLayer .textWidgetAnnotation textarea {
  resize: none;
}

.annotationLayer .textWidgetAnnotation :is(input, textarea)[disabled],
.annotationLayer .choiceWidgetAnnotation select[disabled],
.annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) input[disabled] {
  background: none;
  border: 2px solid var(--input-disabled-border-color);
  cursor: not-allowed;
}

.annotationLayer .textWidgetAnnotation :is(input, textarea):hover,
.annotationLayer .choiceWidgetAnnotation select:hover,
.annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) input:hover {
  border: 2px solid var(--input-hover-border-color);
}
.annotationLayer .textWidgetAnnotation :is(input, textarea):hover,
.annotationLayer .choiceWidgetAnnotation select:hover,
.annotationLayer .buttonWidgetAnnotation.checkBox input:hover {
  border-radius: 2px;
}

.annotationLayer .textWidgetAnnotation :is(input, textarea):focus,
.annotationLayer .choiceWidgetAnnotation select:focus {
  background: none;
  border: 2px solid var(--input-focus-border-color);
  border-radius: 2px;
  outline: var(--input-focus-outline);
}

.annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) :focus {
  background-image: none;
  background-color: transparent;
}

.annotationLayer .buttonWidgetAnnotation.checkBox :focus {
  border: 2px solid var(--input-focus-border-color);
  border-radius: 2px;
  outline: var(--input-focus-outline);
}

.annotationLayer .buttonWidgetAnnotation.radioButton :focus {
  border: 2px solid var(--input-focus-border-color);
  outline: var(--input-focus-outline);
}

.annotationLayer .buttonWidgetAnnotation.checkBox input:checked::before,
.annotationLayer .buttonWidgetAnnotation.checkBox input:checked::after,
.annotationLayer .buttonWidgetAnnotation.radioButton input:checked::before {
  background-color: CanvasText;
  content: '';
  display: block;
  position: absolute;
}

.annotationLayer .buttonWidgetAnnotation.checkBox input:checked::before,
.annotationLayer .buttonWidgetAnnotation.checkBox input:checked::after {
  height: 80%;
  left: 45%;
  width: 1px;
}

.annotationLayer .buttonWidgetAnnotation.checkBox input:checked::before {
  transform: rotate(45deg);
}

.annotationLayer .buttonWidgetAnnotation.checkBox input:checked::after {
  transform: rotate(-45deg);
}

.annotationLayer .buttonWidgetAnnotation.radioButton input:checked::before {
  border-radius: 50%;
  height: 50%;
  left: 30%;
  top: 20%;
  width: 50%;
}

.annotationLayer .textWidgetAnnotation input.comb {
  font-family: monospace;
  padding-left: 2px;
  padding-right: 0;
}

.annotationLayer .textWidgetAnnotation input.comb:focus {
  /*
   * Letter spacing is placed on the right side of each character. Hence, the
   * letter spacing of the last character may be placed outside the visible
   * area, causing horizontal scrolling. We avoid this by extending the width
   * when the element has focus and revert this when it loses focus.
   */
  width: 103%;
}

.annotationLayer .buttonWidgetAnnotation:is(.checkBox, .radioButton) input {
  appearance: none;
}

.annotationLayer .popupTriggerArea {
  height: 100%;
  width: 100%;
}

.annotationLayer .fileAttachmentAnnotation .popupTriggerArea {
  position: absolute;
}

.annotationLayer .popupWrapper {
  position: absolute;
  font-size: calc(9px * var(--total-scale-factor));
  width: 100%;
  min-width: calc(180px * var(--total-scale-factor));
  pointer-events: none;
}

.annotationLayer .popup {
  position: absolute;
  max-width: calc(180px * var(--total-scale-factor));
  background-color: rgba(255, 255, 153, 1);
  box-shadow: 0 calc(2px * var(--total-scale-factor)) calc(5px * var(--total-scale-factor))
    rgba(136, 136, 136, 1);
  border-radius: calc(2px * var(--total-scale-factor));
  padding: calc(6px * var(--total-scale-factor));
  margin-left: calc(5px * var(--total-scale-factor));
  cursor: pointer;
  font: message-box;
  white-space: normal;
  word-wrap: break-word;
  pointer-events: auto;
}

.annotationLayer .popup > * {
  font-size: calc(9px * var(--total-scale-factor));
}

.annotationLayer .popup h1 {
  display: inline-block;
}

.annotationLayer .popupDate {
  display: inline-block;
  margin-left: calc(5px * var(--total-scale-factor));
}

.annotationLayer .popupContent {
  border-top: 1px solid rgba(51, 51, 51, 1);
  margin-top: calc(2px * var(--total-scale-factor));
  padding-top: calc(2px * var(--total-scale-factor));
}

.annotationLayer .richText > * {
  white-space: pre-wrap;
  font-size: calc(9px * var(--total-scale-factor));
}

.annotationLayer .highlightAnnotation,
.annotationLayer .underlineAnnotation,
.annotationLayer .squigglyAnnotation,
.annotationLayer .strikeoutAnnotation,
.annotationLayer .freeTextAnnotation,
.annotationLayer .lineAnnotation svg line,
.annotationLayer .squareAnnotation svg rect,
.annotationLayer .circleAnnotation svg ellipse,
.annotationLayer .polylineAnnotation svg polyline,
.annotationLayer .polygonAnnotation svg polygon,
.annotationLayer .caretAnnotation,
.annotationLayer .inkAnnotation svg polyline,
.annotationLayer .stampAnnotation,
.annotationLayer .fileAttachmentAnnotation {
  cursor: pointer;
}

.annotationLayer section svg {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
}

.annotationLayer .annotationTextContent {
  position: absolute;
  width: 100%;
  height: 100%;
  opacity: 0;
  color: transparent;
  user-select: none;
  pointer-events: none;
}

.annotationLayer .annotationTextContent span {
  width: 100%;
  display: inline-block;
}
/* Copyright 2014 Mozilla Foundation
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

:root {
  --react-pdf-text-layer: 1;
}

[data-main-rotation='90'] {
  transform: rotate(90deg) translateY(-100%);
}
[data-main-rotation='180'] {
  transform: rotate(180deg) translate(-100%, -100%);
}
[data-main-rotation='270'] {
  transform: rotate(270deg) translateX(-100%);
}

.textLayer {
  color-scheme: only light;

  position: absolute;
  text-align: initial;
  inset: 0;
  overflow: clip;
  opacity: 1;
  line-height: 1;
  text-size-adjust: none;
  forced-color-adjust: none;
  transform-origin: 0 0;
  caret-color: CanvasText;
  z-index: 0;

  /* We multiply the font size by --min-font-size, and then scale the text
   * elements by 1/--min-font-size. This allows us to effectively ignore the
   * minimum font size enforced by the browser, so that the text layer <span>s
   * can always match the size of the text in the canvas. */
  --min-font-size: 1;
  --text-scale-factor: calc(var(--total-scale-factor) * var(--min-font-size));
  --min-font-size-inv: calc(1 / var(--min-font-size));
}

.textLayer :is(span, br) {
  color: transparent;
  position: absolute;
  white-space: pre;
  cursor: text;
  margin: 0;
  transform-origin: 0 0;
}

.textLayer > :not(.markedContent),
.textLayer .markedContent span:not(.markedContent) {
  z-index: 1;

  --font-height: 0; /* set by text_layer.js */
  font-size: calc(var(--text-scale-factor) * var(--font-height));

  --scale-x: 1;
  --rotate: 0deg;
  transform: rotate(var(--rotate)) scaleX(var(--scale-x)) scale(var(--min-font-size-inv));
}

.textLayer .markedContent {
  display: contents;
}

.textLayer span[role='img'] {
  user-select: none;
  cursor: default;
}

.textLayer .highlight {
  --highlight-bg-color: rgb(180 0 170 / 0.25);
  --highlight-selected-bg-color: rgb(0 100 0 / 0.25);
  --highlight-backdrop-filter: none;
  --highlight-selected-backdrop-filter: none;

  margin: -1px;
  padding: 1px;
  background-color: var(--highlight-bg-color);
  backdrop-filter: var(--highlight-backdrop-filter);
  border-radius: 4px;
}

@media screen and (forced-colors: active) {
  .textLayer .highlight {
    --highlight-bg-color: Highlight;
    --highlight-selected-bg-color: ButtonText;
  }
}

.textLayer .highlight.appended {
  position: initial;
}

.textLayer .highlight.begin {
  border-radius: 4px 0 0 4px;
}

.textLayer .highlight.end {
  border-radius: 0 4px 4px 0;
}

.textLayer .highlight.middle {
  border-radius: 0;
}

.textLayer .highlight.selected {
  background-color: var(--highlight-selected-bg-color);
  backdrop-filter: var(--highlight-selected-backdrop-filter);
}

.textLayer ::selection {
  background: rgba(0 0 255 / 0.25);
}

@supports (background: color-mix(in srgb, AccentColor, transparent 75%)) {
  .textLayer ::selection {
    background: color-mix(in srgb, AccentColor, transparent 75%);
  }
}

/* Avoids https://github.com/mozilla/pdf.js/issues/13840 in Chrome */
.textLayer br::selection {
  background: transparent;
}

.textLayer .endOfContent {
  display: block;
  position: absolute;
  inset: 100% 0 0;
  z-index: 0;
  cursor: default;
  user-select: none;
}

.textLayer.selecting .endOfContent {
  top: 0;
}

.hiddenCanvasElement {
  position: absolute;
  top: 0;
  left: 0;
  width: 0;
  height: 0;
  display: none;
}
/* =========================================================
   DocumentVerification.css — Figma-accurate split view
   Left: Findings to Verify (30%) | Resizer | Right: PDF Viewer (70%)
   ========================================================= */

.doc-verification-container {
  display: flex;
  flex-direction: row;
  background-color: #f8fafc;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  height: calc(100vh - 145px);
  min-height: 540px;
  margin-top: 10px;
  box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
  position: relative;
}

/* =========================================================
   LEFT PANE: Findings to Verify
   ========================================================= */

.dv-left-pane {
  display: flex;
  flex-direction: column;
  background: #ffffff;
  overflow: hidden;
  min-height: 0;
  position: relative;
}

/* Draggable Splitter Bar */
.dv-resizer {
  width: 8px;
  background: #f1f5f9;
  border-left: 1px solid #e2e8f0;
  border-right: 1px solid #e2e8f0;
  cursor: col-resize;
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
  flex-shrink: 0;
  transition: background 0.15s;
  z-index: 50;
}

.dv-resizer:hover, .dv-resizer:active {
  background: #3b82f6;
  border-color: #2563eb;
}

.dv-resizer-line {
  width: 2px;
  height: 24px;
  background: #cbd5e1;
  border-radius: 2px;
  transition: background 0.15s;
}

.dv-resizer:hover .dv-resizer-line, .dv-resizer:active .dv-resizer-line {
  background: #ffffff;
}

/* Top filter bar: Status pills */
.dv-top-filters {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px 6px;
  gap: 8px;
  flex-shrink: 0;
}

.dv-status-pills {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.dv-status-pill {
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  font-size: 12px;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.dv-status-pill:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.dv-status-pill.active {
  background: #1e293b;
  color: #ffffff;
  border-color: #1e293b;
}

.dv-status-pill.passed.active {
  background: #10b981;
  color: #ffffff;
  border-color: #10b981;
}

.dv-status-pill.failed.active {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
}

/* Search bar in left pane */
.dv-search-wrap {
  position: relative;
  flex: 1;
  min-width: 120px;
  max-width: 180px;
}

.dv-search-input {
  width: 100%;
  padding: 5px 8px 5px 26px;
  font-size: 11px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  outline: none;
  background: #f8fafc;
  transition: border-color 0.15s;
}

.dv-search-input:focus {
  border-color: #3b82f6;
  background: #ffffff;
}

.dv-search-icon {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  pointer-events: none;
}

/* Category Chips bar (Horizontal scrollable) */
.dv-category-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 4px 14px 8px;
  overflow-x: auto;
  scrollbar-width: thin;
  border-bottom: 1px solid #f1f5f9;
  flex-shrink: 0;
}

.dv-category-bar::-webkit-scrollbar {
  height: 3px;
}

.dv-category-bar::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}

.dv-category-chip {
  padding: 4px 10px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
  color: #334155;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}

.dv-category-chip:hover {
  background: #edf2f7;
  border-color: #cbd5e1;
}

.dv-category-chip.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
  font-weight: 600;
}

/* Section Header (AI FINDINGS SUMMARY) */
.dv-summary-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px 6px;
  background: #ffffff;
  flex-shrink: 0;
}

.dv-summary-title {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #1e293b;
  text-transform: uppercase;
}

.dv-summary-sparkle {
  color: #2563eb;
}

.dv-view-all-btn {
  background: none;
  border: none;
  color: #2563eb;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  padding: 0;
}

.dv-view-all-btn:hover {
  text-decoration: underline;
}

/* Findings Accordion Scroll List */
.dv-findings-list {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  padding: 6px 14px 20px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dv-findings-list::-webkit-scrollbar {
  width: 5px;
}

.dv-findings-list::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

/* Finding Card */
.dv-card {
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  transition: border-color 0.15s, box-shadow 0.15s;
  overflow: hidden;
  flex-shrink: 0; /* CRITICAL: Prevents crushing all cards into 1px stripes */
}

.dv-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.03);
}

.dv-card.selected {
  border-color: #3b82f6;
  box-shadow: 0 0 0 1px #3b82f6;
}

.dv-card.expanded {
  border-color: #f59e0b;
  box-shadow: 0 0 0 1px #f59e0b, 0 3px 10px rgba(245, 158, 11, 0.08);
}

.dv-card.expanded.passed-override {
  border-color: #10b981;
  box-shadow: 0 0 0 1px #10b981, 0 3px 10px rgba(16, 185, 129, 0.08);
}

.dv-card.expanded.failed-override {
  border-color: #ef4444;
  box-shadow: 0 0 0 1px #ef4444, 0 3px 10px rgba(239, 68, 68, 0.08);
}

/* Card Header */
.dv-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  cursor: pointer;
  user-select: none;
  background: #ffffff;
}

.dv-card-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  min-width: 0;
}

.dv-card-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.dv-card-icon.warning {
  background: #fef3c7;
  color: #f59e0b;
}

.dv-card-icon.fatal {
  background: #fee2e2;
  color: #ef4444;
}

.dv-card-icon.passed {
  background: #dcfce7;
  color: #10b981;
}

.dv-card-icon.info {
  background: #dbeafe;
  color: #3b82f6;
}

.dv-card-title-group {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.dv-card-rule-id {
  font-size: 12.5px;
  font-weight: 700;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dv-card-rule-desc {
  font-size: 11px;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dv-card-header-right {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
}

.dv-status-badge {
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 10px;
  text-transform: capitalize;
}

.dv-status-badge.to-verify {
  background: #f1f5f9;
  color: #64748b;
  border: 1px solid #e2e8f0;
}

.dv-status-badge.passed {
  background: #ecfdf5;
  color: #059669;
  border: 1px solid #a7f3d0;
}

.dv-status-badge.failed {
  background: #fef2f2;
  color: #dc2626;
  border: 1px solid #fecaca;
}

.dv-chevron-icon {
  color: #94a3b8;
  transition: transform 0.2s;
}

/* Card Body (Expanded) */
.dv-card-body {
  border-top: 1px solid #f1f5f9;
  padding: 10px 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  background: #ffffff;
}

/* Card Tabs */
.dv-card-tabs {
  display: flex;
  align-items: center;
  gap: 14px;
  border-bottom: 1px solid #e2e8f0;
  padding-bottom: 4px;
}

.dv-card-tab-btn {
  background: none;
  border: none;
  padding: 3px 1px;
  font-size: 11.5px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  position: relative;
  transition: color 0.15s;
}

.dv-card-tab-btn:hover {
  color: #1e293b;
}

.dv-card-tab-btn.active {
  color: #2563eb;
}

.dv-card-tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  right: 0;
  height: 2px;
  background: #2563eb;
  border-radius: 2px;
}

/* Finding Description */
.dv-section-heading {
  font-size: 11px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 2px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.dv-desc-text {
  font-size: 11.5px;
  color: #334155;
  line-height: 1.45;
}

/* Requirements Callout Box */
.dv-req-box {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  padding: 7px 10px;
  display: flex;
  gap: 8px;
  align-items: flex-start;
}

.dv-req-icon {
  color: #2563eb;
  flex-shrink: 0;
  margin-top: 1px;
}

.dv-req-content {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 0;
}

.dv-req-title {
  font-size: 11px;
  font-weight: 700;
  color: #1e40af;
}

.dv-req-text {
  font-size: 11px;
  color: #1e3a8a;
  line-height: 1.35;
}

/* Data Points Table */
.dv-data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  overflow: hidden;
}

.dv-data-table tr {
  border-bottom: 1px solid #e2e8f0;
}

.dv-data-table tr:last-child {
  border-bottom: none;
}

.dv-data-table td {
  padding: 5px 8px;
}

.dv-data-table td:first-child {
  background: #f8fafc;
  color: #64748b;
  font-weight: 600;
  width: 44%;
  border-right: 1px solid #e2e8f0;
}

.dv-data-table td:last-child {
  background: #ffffff;
  color: #0f172a;
  font-weight: 500;
  word-break: break-word;
}

/* Add Notes Input */
.dv-notes-wrap {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dv-notes-input {
  width: 100%;
  padding: 6px 10px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 11px;
  color: #1e293b;
  outline: none;
  min-height: 38px;
  resize: vertical;
  background: #f8fafc;
  transition: all 0.15s;
}

.dv-notes-input:focus {
  border-color: #3b82f6;
  background: #ffffff;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

/* Action Override Buttons */
.dv-action-buttons {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
}

.dv-btn-pass {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid #a7f3d0;
  background: #ecfdf5;
  color: #059669;
  transition: all 0.15s ease;
}

.dv-btn-pass:hover {
  background: #d1fae5;
  border-color: #6ee7b7;
}

.dv-btn-pass.selected {
  background: #10b981;
  color: #ffffff;
  border-color: #10b981;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.25);
}

.dv-btn-fail {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 7px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid #fecaca;
  background: #fef2f2;
  color: #dc2626;
  transition: all 0.15s ease;
}

.dv-btn-fail:hover {
  background: #fee2e2;
  border-color: #fca5a5;
}

.dv-btn-fail.selected {
  background: #ef4444;
  color: #ffffff;
  border-color: #ef4444;
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.25);
}

/* =========================================================
   RIGHT PANE: Embedded PDF Viewer
   ========================================================= */

.dv-right-pane {
  display: flex;
  flex-direction: column;
  background: #475569;
  overflow: hidden;
  position: relative;
  min-height: 0;
}

/* PDF Top Toolbar */
.dv-pdf-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 12px;
  background: #1e293b;
  color: #f8fafc;
  border-bottom: 1px solid #334155;
  flex-shrink: 0;
  gap: 8px;
  font-size: 11px;
}

.dv-toolbar-group {
  display: flex;
  align-items: center;
  gap: 4px;
}

.dv-tool-btn {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-radius: 4px;
  width: 26px;
  height: 26px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s;
}

.dv-tool-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.2);
}

.dv-tool-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

/* Page Input in Toolbar */
.dv-page-input-wrap {
  display: flex;
  align-items: center;
  gap: 3px;
  color: #cbd5e1;
  font-size: 11px;
}

.dv-page-input {
  width: 32px;
  padding: 2px 3px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
  border-radius: 4px;
  text-align: center;
  font-size: 11px;
  outline: none;
}

.dv-zoom-text {
  min-width: 38px;
  text-align: center;
  font-weight: 600;
  font-size: 11px;
  color: #e2e8f0;
}

/* In-PDF Search Bar */
.dv-toolbar-search {
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 5px;
  padding: 2px 6px;
}

.dv-pdf-search-input {
  background: transparent;
  border: none;
  color: #ffffff;
  font-size: 11px;
  outline: none;
  width: 95px;
}

.dv-pdf-search-input::placeholder {
  color: #94a3b8;
}

.dv-search-pill-match {
  background: #a3e635;
  color: #14532d;
  font-size: 9.5px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 8px;
  white-space: nowrap;
}

.dv-downloads-dropdown {
  display: flex;
  align-items: center;
  gap: 5px;
}

.dv-download-chip {
  display: flex;
  align-items: center;
  gap: 3px;
  padding: 3px 6px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.1);
  color: #93c5fd;
  text-decoration: none;
  font-size: 10.5px;
  border: 1px solid rgba(147, 197, 253, 0.25);
  transition: background 0.15s;
}

.dv-download-chip:hover {
  background: rgba(255, 255, 255, 0.2);
}

/* PDF Viewport Scroll Area */
.dv-pdf-viewport {
  flex: 1 1 0;
  min-height: 0;
  overflow: auto;
  padding: 18px 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  position: relative;
}

.dv-pdf-page-container {
  background: #ffffff;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.25);
  border-radius: 2px;
  position: relative;
  transition: box-shadow 0.2s ease;
}

.dv-pdf-page-container.active-page {
  box-shadow: 0 0 0 2px #3b82f6, 0 8px 24px rgba(0, 0, 0, 0.35);
}

.dv-page-badge {
  position: absolute;
  top: -18px;
  left: 0;
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.6);
  font-weight: 600;
}

/* Marker Highlights & Callout */
.dv-highlight-rect {
  position: absolute;
  pointer-events: none;
  z-index: 20;
  border-radius: 2px;
  transition: all 0.2s ease;
}

.dv-highlight-selected {
  box-shadow: 0 0 0 2px var(--rd-glow, #3b82f6), 0 0 12px var(--rd-glow, #3b82f6);
  animation: dvPulse 1.5s ease-in-out infinite alternate;
}

@keyframes dvPulse {
  from { opacity: 0.85; }
  to { opacity: 1; filter: drop-shadow(0 0 6px var(--rd-glow, #3b82f6)); }
}

.dv-callout {
  position: absolute;
  transform: translateY(-100%);
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 5px;
  max-width: 380px;
  padding: 3px 7px;
  background: #0f172a;
  color: #f8fafc;
  border-left: 3px solid var(--rd-accent, #3b82f6);
  border-radius: 4px;
  font-size: 10.5px;
  white-space: nowrap;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  pointer-events: none;
}

.dv-callout::after {
  content: '';
  position: absolute;
  left: 10px;
  bottom: -4px;
  border-left: 4px solid transparent;
  border-right: 4px solid transparent;
  border-top: 4px solid #0f172a;
}

.dv-callout.below {
  transform: none;
}

.dv-callout.below::after {
  bottom: auto;
  top: -4px;
  border-top: none;
  border-bottom: 4px solid #0f172a;
}

/* Loading & Empty States */
.dv-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: 100%;
  color: #94a3b8;
  font-size: 12px;
}

.dv-spinner {
  width: 24px;
  height: 24px;
  border: 3px solid rgba(255, 255, 255, 0.2);
  border-top-color: #3b82f6;
  border-radius: 50%;
  animation: dvSpin 0.8s linear infinite;
}

@keyframes dvSpin {
  to { transform: rotate(360deg); }
}
/* GOCIQ Bot Styling — Modern AI Chat Interface with Rich Glassmorphism & Micro-animations */

.gociq-bot-container {
  display: flex;
  height: calc(100vh - 70px);
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  overflow: hidden;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.bot-main-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
  overflow: hidden;
}

/* ── Top Bar ───────────────────────────────────────── */
.bot-topbar {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid #e2e8f0;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  z-index: 10;
}

.bot-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.bot-avatar-glow {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  box-shadow: 0 0 16px rgba(59, 130, 246, 0.35);
}

.bot-title-text h2 {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.rag-badge {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 7px;
  border-radius: 6px;
  background: #eff6ff;
  color: #2563eb;
  border: 1px solid #bfdbfe;
}

.bot-title-text p {
  font-size: 12px;
  color: #64748b;
  margin: 0;
}

.bot-controls {
  display: flex;
  align-items: center;
  gap: 12px;
}

.order-selector-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  padding: 4px 10px;
  border-radius: 8px;
  font-size: 13px;
  transition: all 0.2s;
}

.order-selector-wrap:focus-within {
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.15);
  background: white;
}

.order-select {
  border: none;
  background: transparent;
  font-size: 13px;
  font-weight: 600;
  color: #1e293b;
  cursor: pointer;
  outline: none;
}

.score-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  background: #dbeafe;
  color: #1d4ed8;
}

.score-badge.high {
  background: #d1fae5;
  color: #065f46;
}

.score-badge.med {
  background: #fef3c7;
  color: #92400e;
}

.new-chat-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: white;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s;
}

.new-chat-btn:hover {
  background: #f8fafc;
  color: #0f172a;
  border-color: #cbd5e1;
}

/* ── Chat Messages Container ───────────────────────── */
.chat-scroll-area {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  scroll-behavior: smooth;
}

/* Welcome Box */
.bot-welcome-card {
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 24px;
  margin: 0 auto;
  max-width: 780px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
}

.welcome-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
}

.welcome-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.welcome-header h3 {
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.welcome-header p {
  font-size: 13px;
  color: #64748b;
  margin: 2px 0 0 0;
}

.welcome-description {
  font-size: 13px;
  color: #334155;
  line-height: 1.6;
  margin-bottom: 16px;
}

.feature-pills-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 20px;
}

.feature-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 20px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  color: #475569;
}

.feature-pill svg {
  color: #2563eb;
}

/* Prompt Chips */
.prompt-chips-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #64748b;
  margin-bottom: 8px;
}

.prompt-chips-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 10px;
}

.prompt-chip {
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 500;
  color: #334155;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.prompt-chip:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  color: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.08);
}

/* Message Rows */
.message-row {
  display: flex;
  gap: 14px;
  max-width: 860px;
  width: 100%;
  margin: 0 auto;
}

.message-row.user {
  justify-content: flex-end;
}

.message-row.assistant {
  justify-content: flex-start;
}

.avatar-badge {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-weight: 700;
  font-size: 12px;
}

.avatar-badge.bot {
  background: linear-gradient(135deg, #3b82f6 0%, #1e40af 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.25);
}

.avatar-badge.user-avatar {
  background: #e2e8f0;
  color: #1e293b;
}

.message-bubble {
  max-width: 760px;
  border-radius: 14px;
  padding: 14px 18px;
  position: relative;
  font-size: 13.5px;
  line-height: 1.6;
}

.message-row.user .message-bubble {
  background: #2563eb;
  color: white;
  border-bottom-right-radius: 4px;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
}

.message-row.assistant .message-bubble {
  background: white;
  color: #1e293b;
  border: 1px solid #e2e8f0;
  border-bottom-left-radius: 4px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.03);
}

/* Response Method Badge */
.method-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 12px;
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.method-pill.sql {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.method-pill.hybrid {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.method-pill.genai {
  background: #faf5ff;
  color: #6b21a8;
  border: 1px solid #e9d5ff;
}

/* Formatted Content inside Bubble */
.markdown-body {
  word-break: break-word;
}

.markdown-body p {
  margin-bottom: 10px;
}

.markdown-body p:last-child {
  margin-bottom: 0;
}

.markdown-body ul, .markdown-body ol {
  padding-left: 20px;
  margin-bottom: 10px;
}

.markdown-body li {
  margin-bottom: 4px;
}

.markdown-body strong {
  font-weight: 600;
  color: #0f172a;
}

.markdown-body code {
  background: #f1f5f9;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: monospace;
  font-size: 12px;
  color: #0f172a;
}

/* Sources Accordion */
.sources-container {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed #e2e8f0;
}

.sources-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: none;
  border: none;
  font-size: 11px;
  font-weight: 600;
  color: #64748b;
  cursor: pointer;
  padding: 0;
}

.sources-toggle:hover {
  color: #2563eb;
}

.sources-list {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.source-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8fafc;
  padding: 4px 8px;
  border-radius: 6px;
  font-size: 11px;
  color: #475569;
  border: 1px solid #f1f5f9;
}

.source-left {
  display: flex;
  align-items: center;
  gap: 6px;
}

.source-sim {
  font-weight: 700;
  color: #2563eb;
}

/* Message Actions */
.message-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.action-btn {
  background: none;
  border: none;
  color: #94a3b8;
  cursor: pointer;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.2s;
  display: flex;
  align-items: center;
}

.action-btn:hover {
  color: #475569;
  background: #f1f5f9;
}

/* Typing / Loading Indicator */
.bot-typing-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
}

.typing-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #3b82f6;
  animation: typingBounce 1.4s infinite ease-in-out both;
}

.typing-dot:nth-child(1) { animation-delay: -0.32s; }
.typing-dot:nth-child(2) { animation-delay: -0.16s; }

@keyframes typingBounce {
  0%, 80%, 100% { transform: scale(0); opacity: 0.4; }
  40% { transform: scale(1); opacity: 1; }
}

/* ── Input Box Section ─────────────────────────────── */
.bot-input-area {
  padding: 16px 24px 20px 24px;
  background: white;
  border-top: 1px solid #e2e8f0;
  box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.02);
  z-index: 10;
}

.input-container {
  max-width: 860px;
  margin: 0 auto;
  position: relative;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  padding: 8px 12px;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 10px;
}

.input-container:focus-within {
  border-color: #3b82f6;
  background: white;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.chat-input {
  flex: 1;
  border: none;
  background: transparent;
  outline: none;
  font-size: 14px;
  color: #0f172a;
  resize: none;
  max-height: 120px;
  line-height: 1.5;
}

.chat-input::placeholder {
  color: #94a3b8;
}

.send-btn {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #2563eb;
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}

.send-btn:hover:not(:disabled) {
  background: #1d4ed8;
  transform: scale(1.04);
}

.send-btn:disabled {
  background: #cbd5e1;
  cursor: not-allowed;
  opacity: 0.7;
}

.input-disclaimer {
  text-align: center;
  font-size: 11px;
  color: #94a3b8;
  margin-top: 8px;
}

/* ── Right Context Sidebar ─────────────────────────── */
.order-context-panel {
  width: 320px;
  background: white;
  border-left: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  padding: 20px;
  overflow-y: auto;
}

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

.context-header h4 {
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.order-detail-card {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 16px;
}

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12.5px;
  margin-bottom: 8px;
}

.detail-row:last-child {
  margin-bottom: 0;
}

.detail-label {
  color: #64748b;
  font-weight: 500;
}

.detail-val {
  color: #0f172a;
  font-weight: 600;
}

.vector-status-pill {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  color: #059669;
  background: #ecfdf5;
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid #a7f3d0;
  margin-top: 8px;
}
/* ── Orders Workspace Master-Detail Layout ── */
.orders-workspace-container {
  display: flex;
  height: calc(100vh - 70px);
  width: 100%;
  background-color: #f8fafc;
  overflow: hidden;
  font-family: Inter, -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ── Left Collapsible Panel ── */
.orders-panel {
  width: 360px;
  min-width: 360px;
  background: #ffffff;
  border-right: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  height: 100%;
  transition: width 0.28s cubic-bezier(0.16, 1, 0.3, 1), min-width 0.28s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  z-index: 5;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.02);
}

.orders-panel.collapsed {
  width: 52px;
  min-width: 52px;
  background: #f8fafc;
}

/* Panel Header */
.orders-panel-header {
  padding: 16px 18px 12px;
  border-bottom: 1px solid #f1f5f9;
  background: #ffffff;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.orders-header-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.orders-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.orders-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #eff6ff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.orders-panel-heading {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  letter-spacing: -0.2px;
}

.orders-panel-subheading {
  font-size: 11px;
  color: #64748b;
  font-weight: 500;
}

.orders-header-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.order-icon-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s;
}

.order-icon-btn:hover {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #bfdbfe;
}

.order-icon-btn.rotating svg {
  animation: spin 1s linear infinite;
}

/* Search Input */
.orders-search-wrapper {
  position: relative;
  display: flex;
  align-items: center;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 6px 10px;
  transition: all 0.2s;
}

.orders-search-wrapper:focus-within {
  background: #ffffff;
  border-color: #3b82f6;
  box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.15);
}

.search-icon {
  color: #94a3b8;
  margin-right: 8px;
  flex-shrink: 0;
}

.orders-search-input {
  border: none;
  background: transparent;
  outline: none;
  font-size: 12.5px;
  color: #0f172a;
  width: 100%;
}

.orders-search-input::placeholder {
  color: #94a3b8;
}

.search-clear-btn {
  background: none;
  border: none;
  color: #94a3b8;
  font-size: 16px;
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.search-clear-btn:hover {
  color: #475569;
}

/* Filter Chips */
.orders-filter-chips {
  display: flex;
  gap: 6px;
}

.filter-chip {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all 0.15s;
}

.filter-chip:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.filter-chip.active {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff;
}

.live-pulse {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #3b82f6;
  animation: pulseDot 1.4s ease-in-out infinite;
}

@keyframes pulseDot {
  0% { transform: scale(0.9); opacity: 0.8; }
  50% { transform: scale(1.4); opacity: 1; box-shadow: 0 0 6px #3b82f6; }
  100% { transform: scale(0.9); opacity: 0.8; }
}

/* Orders Cards Scroll List */
.orders-list-scroll {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.orders-list-scroll::-webkit-scrollbar {
  width: 5px;
}

.orders-list-scroll::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

/* Individual Order Card */
.order-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
}

.order-card:hover {
  background: #fbfcfe;
  border-color: #cbd5e1;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.order-card.active {
  background: #eff6ff;
  border-color: #93c5fd;
  border-left: 4px solid #2563eb;
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.08);
}

.order-card.running-border {
  border-color: #93c5fd;
  background: #fdfefe;
}

.order-card-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.order-ref-block {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.order-index-badge {
  font-size: 10px;
  font-weight: 700;
  color: #64748b;
  background: #f1f5f9;
  border-radius: 4px;
  padding: 2px 5px;
  flex-shrink: 0;
}

.order-client-ref {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.order-status-badge {
  font-size: 10.5px;
  font-weight: 600;
  border-radius: 12px;
  padding: 2px 7px;
  display: flex;
  align-items: center;
  gap: 4px;
  flex-shrink: 0;
}

.order-status-badge.complete {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.order-status-badge.running {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.order-status-badge.failed {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.order-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  color: #64748b;
}

.order-type-tag {
  font-weight: 500;
  text-transform: capitalize;
}

.order-time-ago {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #94a3b8;
}

.order-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 2px;
  padding-top: 6px;
  border-top: 1px dashed #f1f5f9;
  font-size: 10.5px;
}

.order-uuid-chip {
  color: #94a3b8;
  font-family: monospace;
}

.order-score-chip {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
  border-radius: 6px;
  padding: 2px 6px;
  font-weight: 500;
}

.order-running-indicator {
  color: #2563eb;
  font-weight: 600;
  font-size: 10.5px;
}

/* Panel Footer */
.orders-panel-footer {
  padding: 12px 14px;
  border-top: 1px solid #e2e8f0;
  background: #ffffff;
}

.submit-new-order-btn {
  width: 100%;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  color: #2563eb;
  padding: 8px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  text-align: center;
}

.submit-new-order-btn:hover {
  background: #eff6ff;
  border-color: #93c5fd;
  border-style: solid;
}

/* Collapsed Mini Rail */
.orders-collapsed-rail {
  width: 52px;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 14px 6px;
  gap: 16px;
}

.expand-rail-btn {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #2563eb;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.expand-rail-btn:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
  transform: scale(1.05);
}

.rail-orders-count {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 10px;
  font-weight: 700;
  color: #64748b;
  gap: 2px;
}

.rail-orders-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  overflow-y: auto;
  width: 100%;
  align-items: center;
}

.rail-order-dot {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  background: #ffffff;
  color: #475569;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
}

.rail-order-dot:hover {
  background: #eff6ff;
  color: #2563eb;
  border-color: #bfdbfe;
}

.rail-order-dot.active {
  background: #2563eb;
  color: #ffffff;
  border-color: #2563eb;
  box-shadow: 0 2px 6px rgba(37, 99, 235, 0.3);
}

/* ── Right Main Order Details Area ── */
.orders-main-detail-area {
  flex: 1;
  min-width: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #ffffff;
  position: relative;
}

.order-detail-wrapper {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
}

/* Workspace Top Bar */
.workspace-top-bar {
  height: 48px;
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  padding: 0 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-shrink: 0;
}

.workspace-breadcrumb {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: #64748b;
}

.uncollapse-top-btn {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11.5px;
  font-weight: 600;
  color: #2563eb;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s;
}

.uncollapse-top-btn:hover {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.status-pill {
  font-size: 10.5px;
  font-weight: 600;
  border-radius: 12px;
  padding: 2px 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.status-pill.complete {
  background: #ecfdf5;
  color: #047857;
  border: 1px solid #a7f3d0;
}

.status-pill.running {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
}

.workspace-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.bot-chat-shortcut-btn {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  color: #1d4ed8;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.bot-chat-shortcut-btn:hover {
  background: #dbeafe;
  border-color: #93c5fd;
  transform: translateY(-1px);
}

.workspace-order-body {
  flex: 1;
  overflow: hidden;
  height: calc(100% - 48px);
}

/* Live Running State Display */
.live-processing-container {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  padding: 40px 20px;
  background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
  overflow-y: auto;
}

.live-processing-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 16px;
  padding: 36px 40px;
  max-width: 620px;
  width: 100%;
  text-align: center;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.live-spinner-glow {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #eff6ff;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
  box-shadow: 0 0 24px rgba(37, 99, 235, 0.15);
}

.live-processing-card h2 {
  font-size: 20px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 4px;
}

.live-ref-title {
  font-size: 13px;
  color: #475569;
  margin: 0 0 12px;
}

.live-desc {
  font-size: 13px;
  color: #64748b;
  line-height: 1.5;
  margin: 0 auto 24px;
  max-width: 480px;
}

.live-pipeline-steps {
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 24px;
}

.pipeline-step-item {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.pipeline-step-item .step-text {
  display: flex;
  flex-direction: column;
}

.pipeline-step-item .step-text strong {
  font-size: 12.5px;
  color: #0f172a;
}

.pipeline-step-item .step-text span {
  font-size: 11px;
  color: #64748b;
}

.pipeline-step-item.active .step-text strong {
  color: #2563eb;
}

.pipeline-step-item.pending {
  opacity: 0.5;
}

.live-auto-poll-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: #64748b;
  background: #f1f5f9;
  padding: 6px 14px;
  border-radius: 20px;
}

/* Empty State */
.no-order-selected {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  color: #64748b;
  text-align: center;
  padding: 40px;
}

.no-order-selected h3 {
  margin: 16px 0 6px;
  font-size: 18px;
  color: #0f172a;
}

.no-order-selected p {
  font-size: 13px;
  max-width: 400px;
  margin: 0;
}
.login-page {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: #f8fafc;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  overflow: hidden;
}

.login-background {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: 
    radial-gradient(circle at 50% 30%, rgba(224, 242, 254, 0.4) 0%, transparent 70%),
    radial-gradient(circle at 10% 80%, rgba(219, 234, 254, 0.5) 0%, transparent 60%);
  z-index: 0;
}

.login-background::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background-image: radial-gradient(#94a3b8 1px, transparent 1px);
  background-size: 20px 20px;
  opacity: 0.15;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 80%);
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 80%);
}

.login-container {
  flex: 1;
  display: flex;
  position: relative;
  z-index: 1;
  max-width: 1300px;
  margin: 0 auto;
  width: 100%;
  padding: 40px 20px;
}

.login-branding {
  flex: 1.2;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-right: 60px;
}

.login-logo-container {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.login-logo {
  height: 48px;
  object-fit: contain;
}

.login-subtitle {
  font-size: 11px;
  font-weight: 700;
  color: #3b82f6;
  letter-spacing: 0.05em;
  background: #eff6ff;
  padding: 6px 12px;
  border-radius: 20px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.subtitle-star {
  font-size: 14px;
}

.login-headline {
  font-size: 42px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
  margin: 0 0 16px 0;
  letter-spacing: -0.02em;
}

.highlight-text {
  color: #2563eb;
}

.login-description {
  font-size: 15px;
  color: #64748b;
  line-height: 1.5;
  max-width: 480px;
  margin: 0 0 32px 0;
}

.login-features-container {
  display: flex;
  flex-direction: column;
  max-width: 580px;
}

.login-feature-card {
  background: white;
  border: 1.5px solid #60a5fa;
  border-radius: 16px;
  padding: 24px 32px;
  margin-bottom: 16px;
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.05);
}

.feature-header {
  font-size: 14px;
  font-weight: 700;
  color: #1e293b;
  letter-spacing: 0.01em;
  margin-bottom: 16px;
}

.feature-content {
  display: flex;
  align-items: center;
  gap: 32px;
}

.score-circle-wrapper {
  width: 104px;
  height: 104px;
  border-radius: 50%;
  background: conic-gradient(from 180deg, #e2e8f0 0deg 30deg, #2563eb 30deg 360deg);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.score-circle-wrapper::before {
  content: "";
  position: absolute;
  inset: 10px;
  background: white;
  border-radius: 50%;
}

.score-number-container {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-top: -2px; /* Pull it slightly up to perfectly center inside the ring */
}

.score-number {
  font-size: 34px;
  font-weight: 800;
  color: #2563eb;
  display: flex;
  align-items: baseline;
  justify-content: center;
  line-height: 1;
}

.score-number span {
  font-size: 18px;
  display: inline-block;
  margin-left: 1px;
  font-weight: 800;
}

.score-label {
  font-size: 9px;
  font-weight: 800;
  color: #60a5fa;
  margin-top: 2px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  z-index: 10;

}

.feature-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: #475569;
  font-weight: 500;
}

.feature-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: white;
  border: 1.5px solid #60a5fa;
  border-radius: 16px;
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.05);
}

.stat-icon-wrapper {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #2563eb;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 0 4px #eff6ff;
}

.stat-info {
  display: flex;
  flex-direction: column;
}

.stat-val {
  font-size: 16px;
  font-weight: 800;
  color: #2563eb;
  line-height: 1.2;
}

.stat-sub {
  font-size: 12px;
  font-weight: 700;
  color: #0f172a;
  line-height: 1.2;
}

.stat-desc {
  font-size: 9px;
  font-weight: 600;
  color: #0f172a;
  margin-top: 3px;
  line-height: 1.2;
}

.feature-badges {
  display: flex;
  align-items: center;
  gap: 32px;
  padding-left: 12px;
}

.badge-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: #1e293b;
}

.badge-item .badge-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}


.login-form-container {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-form-box {
  background: white;
  width: 100%;
  max-width: 440px;
  border-radius: 16px;
  box-shadow: 0 20px 40px -10px rgba(0,0,0,0.1);
  padding: 32px;
}

.login-form-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.login-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.login-title-area h2 {
  font-size: 20px;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 4px 0;
}

.login-title-area p {
  font-size: 13px;
  color: #64748b;
  margin: 0;
}

.login-tabs {
  display: flex;
  background: #f1f5f9;
  border-radius: 8px;
  padding: 4px;
  margin-bottom: 24px;
}

.login-tab {
  flex: 1;
  background: transparent;
  border: none;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  padding: 8px 0;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.login-tab.active {
  background: #2563eb;
  color: white;
}

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

.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: #1e293b;
  margin-bottom: 6px;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 12px;
  color: #94a3b8;
}

.input-wrapper input {
  width: 100%;
  padding: 10px 12px 10px 36px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 14px;
  color: #0f172a;
  transition: border-color 0.2s;
}

.input-wrapper input:focus {
  outline: none;
  border-color: #2563eb;
  box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}

.form-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  font-size: 12px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #64748b;
  cursor: pointer;
}

.forgot-password {
  color: #2563eb;
  text-decoration: none;
  font-weight: 600;
}

.login-btn {
  width: 100%;
  background: #2563eb;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 12px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 20px;
  transition: background 0.2s;
}

.login-btn:hover {
  background: #1d4ed8;
}

.terms-text {
  text-align: center;
  font-size: 11px;
  color: #94a3b8;
  margin-bottom: 16px;
}

.terms-text a, .create-account-text a {
  color: #2563eb;
  text-decoration: none;
}

.create-account-text {
  text-align: center;
  font-size: 12px;
  color: #64748b;
}

.login-error {
  background: #fef2f2;
  color: #ef4444;
  border: 1px solid #fca5a5;
  padding: 10px;
  border-radius: 6px;
  font-size: 13px;
  margin-bottom: 16px;
}

.login-footer {
  position: relative;
  z-index: 1;
  background: #1e40af;
  color: rgba(255,255,255,0.8);
  text-align: center;
  padding: 16px;
  font-size: 12px;
  font-weight: 500;
}

@media (max-width: 900px) {
  .login-container {
    flex-direction: column;
  }
  .login-branding {
    padding-right: 0;
    margin-bottom: 40px;
  }
}
.submit-page-container {
  display: flex;
  gap: 24px;
  padding: 16px 32px;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  flex: 1;
  overflow-y: auto;
}

.submit-page-container .main-column {
  flex: 1;
  min-width: 0;
}

.submit-page-container .side-column {
  width: 320px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: sticky;
  top: 32px;
}

.submit-card {
  background: white;
  border-radius: 20px;
  box-shadow: 0 10px 40px -10px rgba(37, 99, 235, 0.1);
  border: 1px solid #eff6ff;
  width: 100%;
}

.submit-header {
  padding: 16px 24px 12px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  gap: 12px;
}

.submit-header-icon {
  width: 40px;
  height: 40px;
  border-radius: 16px;
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}

.submit-title {
  font-size: 20px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.01em;
  margin: 0 0 2px 0;
}

.submit-subtitle {
  font-size: 14px;
  color: #64748b;
  margin: 0;
}

.submit-body {
  padding: 16px 24px;
}

.form-section-title {
  font-size: 16px;
  font-weight: 800;
  color: #1e293b;
  margin-bottom: 12px;
}

.submit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 16px;
  margin-bottom: 16px;
}

.submit-label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  color: #475569;
  margin-bottom: 4px;
}

.required {
  color: #ef4444;
}

.submit-input {
  width: 100%;
  padding: 8px 12px;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  font-size: 13px;
  color: #0f172a;
  transition: all 0.2s;
  font-family: inherit;
  font-weight: 500;
}

.submit-input:focus {
  border-color: #2563eb;
  background: white;
  box-shadow: 0 0 0 4px #eff6ff;
  outline: none;
}

.submit-input.error-field, .custom-select-trigger.error-field {
  border-color: #ef4444 !important;
  background-color: #fef2f2 !important;
}

.submit-input:disabled {
  background: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
}

.custom-select-container {
  position: relative;
  width: 100%;
}

.custom-select-trigger {
  width: 100%;
  padding: 8px 12px;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  font-size: 13px;
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.2s;
  font-weight: 500;
}

.custom-select-trigger:hover, .custom-select-trigger:focus {
  border-color: #2563eb;
  background: white;
  box-shadow: 0 0 0 4px #eff6ff;
  outline: none;
}

.custom-select-trigger.disabled {
  background: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
}

.custom-select-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: white;
  border-radius: 12px;
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
  border: 1px solid #e2e8f0;
  z-index: 50;
  overflow: hidden;
  max-height: 250px;
  overflow-y: auto;
}

.custom-select-option {
  padding: 10px 16px;
  font-size: 14px;
  color: #475569;
  cursor: pointer;
  transition: background 0.1s;
}

.custom-select-option:hover {
  background: #eff6ff;
  color: #2563eb;
  font-weight: 500;
}

.toggle-group {
  display: flex;
  gap: 12px;
}

.toggle-btn {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  background: #f8fafc;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  color: #475569;
  transition: all 0.2s;
}

.toggle-btn.active {
  background: #eff6ff;
  border-color: #2563eb;
  color: #1d4ed8;
}

.radio-circle {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 2px solid #cbd5e1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toggle-btn.active .radio-circle {
  border-color: #2563eb;
}

.toggle-btn.active .radio-circle::after {
  content: '';
  width: 8px;
  height: 8px;
  background: #2563eb;
  border-radius: 50%;
}

.submit-btn {
  padding: 12px 24px;
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  color: white;
  font-size: 14px;
  font-weight: 700;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.submit-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4);
}

.submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
}

.submit-btn-outline {
  padding: 14px 28px;
  background: white;
  color: #475569;
  font-size: 15px;
  font-weight: 700;
  border: 1.5px solid #cbd5e1;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.2s;
}

.submit-btn-outline:hover {
  background: #f8fafc;
  color: #0f172a;
}

.form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #f1f5f9;
  position: sticky;
  bottom: 0;
  background: white;
  padding-bottom: 12px;
  z-index: 10;
  border-bottom-left-radius: 20px;
  border-bottom-right-radius: 20px;
}

.upload-container {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 20px;
  align-items: center;
  margin-top: 24px;
}

.upload-card {
  border: 1.5px dashed #cbd5e1;
  border-radius: 16px;
  padding: 24px;
  text-align: center;
  background: #f8fafc;
  transition: all 0.2s;
}

.upload-card:hover {
  border-color: #2563eb;
  background: #eff6ff;
}

.upload-icon {
  color: #60a5fa;
  margin-bottom: 12px;
}

.upload-text h4 {
  margin: 0 0 4px 0;
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.upload-text p {
  margin: 0;
  font-size: 12px;
  color: #64748b;
}

.file-input-wrapper {
  margin-top: 16px;
  display: flex;
  align-items: center;
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}

.file-input-wrapper input {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
}

.file-input-text {
  flex: 1;
  padding: 8px 12px;
  font-size: 12px;
  color: #64748b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: left;
}

.file-input-btn {
  background: #f1f5f9;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  border-left: 1px solid #e2e8f0;
}

.divider-or {
  font-size: 13px;
  font-weight: 700;
  color: #94a3b8;
}

/* Status Card */
.status-card {
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 24px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.status-card.success {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
}

.status-card.error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #991b1b;
}

/* Side Column Styles */
.side-card {
  background: #fff;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  overflow: hidden;
}

.side-card-header {
  padding: 14px 16px 12px;
  background: linear-gradient(135deg, #eef2ff 0%, #f8faff 100%);
  border-bottom: 1px solid #e0e7ff;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}
.my-amcs-page {
  padding: 24px;
  width: 100%;
}

.error-field {
  border-color: #ef4444 !important;
  background: #fef2f2 !important;
}

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

.page-header h2 {
  font-size: 24px;
  font-weight: 700;
  color: #0f172a;
  margin: 0;
}

.content-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
  align-items: start;
}

.amcs-column {
  display: flex;
  flex-direction: column;
}

.lenders-column {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  padding: 24px;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
  position: sticky;
  top: 24px;
}

.lenders-header {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
}

.lenders-list-full {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lender-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px;
  border-radius: 8px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  transition: all 0.2s;
}

.lender-item:hover {
  border-color: #cbd5e1;
  background: #f1f5f9;
}

.lender-name {
  font-size: 14px;
  font-weight: 600;
  color: #1e293b;
}

.lender-amc-tag {
  font-size: 11px;
  font-weight: 600;
  color: #4f46e5;
  background: #e0e7ff;
  padding: 4px 10px;
  border-radius: 12px;
}

.no-lenders-text {
  font-size: 13px;
  color: #64748b;
  text-align: center;
  padding: 20px 0;
}

.amc-card {
  cursor: pointer;
  transition: all 0.2s ease;
}

.amc-card:hover {
  border-color: #cbd5e1;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
  transform: translateY(-1px);
}

.amc-card.selected {
  border-color: #2563eb;
  box-shadow: 0 0 0 1px #2563eb, 0 4px 6px -1px rgba(0,0,0,0.05);
  background: #f8fafc;
}

.amc-card {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  margin-bottom: 16px;
  padding: 20px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  cursor: pointer;
  transition: all 0.2s ease;
}

.amc-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 1px solid #f1f5f9;
  padding-bottom: 16px;
  margin-bottom: 16px;
}

.amc-title-box {
  display: flex;
  gap: 16px;
  align-items: center;
}

.amc-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #eff6ff;
  color: #2563eb;
  display: flex;
  align-items: center;
  justify-content: center;
}

.amc-name {
  margin: 0 0 4px 0;
  font-size: 18px;
  font-weight: 600;
  color: #1e293b;
}

.amc-stats {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 13px;
  color: #64748b;
}

.tat-badge {
  background: #ecfdf5;
  color: #059669;
  padding: 2px 8px;
  border-radius: 12px;
  font-weight: 500;
  font-size: 12px;
}

.btn-edit {
  background: white;
  border: 1px solid #e2e8f0;
  color: #475569;
  padding: 6px 16px;
  border-radius: 6px;
  font-weight: 500;
  cursor: pointer;
}

.assignment-row {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 16px;
}

.assignment-row .label {
  font-size: 13px;
  color: #64748b;
  white-space: nowrap;
}

.assignment-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.avatar-list {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.avatar-item {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  padding: 4px 10px 4px 4px;
  border-radius: 16px;
}

.avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  color: white;
  font-weight: 600;
}

.bg-blue { background: #2563eb; }
.bg-indigo { background: #4f46e5; }

.name {
  font-size: 13px;
  color: #0f172a;
  font-weight: 500;
  white-space: nowrap;
}

.empty-lenders {
  font-size: 13px;
  color: #94a3b8;
}

/* Modals */
.modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
}

.modal-content {
  background: white;
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1);
  display: flex;
  flex-direction: column;
}

.amc-modal { width: 1050px; height: auto; max-height: 98vh; overflow: hidden; }
.lender-modal { width: 700px; height: auto; max-height: 98vh; }

.modal-header {
  padding: 16px 24px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

.amc-icon-header {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: #f3f4f6;
  color: #4f46e5;
  display: flex;
  align-items: center;
  justify-content: center;
}

.close-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  color: #64748b;
  padding: 4px;
}

.modal-body-noscroll {
  padding: 16px 24px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 0px;
}

.form-section {
  padding: 14px 0;
  border-bottom: 1px solid #e2e8f0;
}

.form-section.pt-0 { padding-top: 0; }
.form-section.pb-0 { padding-bottom: 0; }
.form-section.border-none { border-bottom: none; }

.section-label {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
}

.section-label.highlight-bg {
  background: #eff6ff;
  padding: 2px 4px;
  margin-bottom: 10px;
}

.sub-label {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 6px;
}

.required { color: #ef4444; }

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.input-icon {
  position: absolute;
  left: 12px;
  color: #64748b;
}

.input-field {
  width: 100%;
  padding: 8px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 13px;
  outline: none;
  color: #0f172a;
  background: #fff;
  box-sizing: border-box;
}

.input-field.pl-36 {
  padding-left: 36px;
}

.input-field::placeholder {
  color: #94a3b8;
}

.input-field:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37,99,235,0.1);
}

.row {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.flex-1 { flex: 1; }

.lender-input-row {
  display: flex;
  gap: 12px;
}

.btn-add-lender {
  white-space: nowrap;
}

.lender-hint {
  font-size: 11px;
  color: #64748b;
  margin-top: 6px;
}

.offline-coverage-box {
  display: flex;
  align-items: center;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 4px;
  background: #fff;
}

.offline-toggle {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #f1f5f9;
  color: #64748b;
  padding: 4px 12px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.offline-toggle.active {
  background: #ecfdf5;
  color: #059669;
}

.check-circle {
  width: 16px; height: 16px;
  border-radius: 50%;
  background: #059669;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
}

.offline-toggle:not(.active) .check-circle {
  background: #cbd5e1;
  color: #f1f5f9;
}

.offline-input-wrapper {
  display: flex;
  align-items: center;
  padding: 0 12px;
  gap: 8px;
}

.offline-icon {
  color: #0f172a;
}

.offline-input {
  flex: 1;
  border: none !important;
  background: transparent;
  outline: none;
  font-size: 13px;
  color: #94a3b8;
}

.modal-footer {
  padding: 12px 24px;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
}

.btn-cancel {
  background: white;
  border: 1px solid #cbd5e1;
  padding: 8px 24px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  color: #0f172a;
}

.btn-primary {
  background: #2563eb;
  color: white;
  border: none;
  padding: 8px 24px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

.btn-primary:disabled { opacity: 0.5; }

/* Lender Modal specific */
.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: normal !important;
  font-size: 14px !important;
  cursor: pointer;
}

.qc-box {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 16px;
}

.qc-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  margin-bottom: 8px;
}

.qc-hint {
  font-size: 12px;
  color: #64748b;
  margin-top: 12px;
}

.no-amcs {
  text-align: center;
  padding: 40px;
  color: #64748b;
  background: white;
  border-radius: 12px;
  border: 1px dashed #cbd5e1;
}

.custom-select-container {
  position: relative;
  width: 100%;
}

.custom-select-trigger {
  width: 100%;
  padding: 8px 12px;
  background: #fff;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 13px;
  color: #0f172a;
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  transition: all 0.2s;
  box-sizing: border-box;
}

.custom-select-trigger.pl-36 {
  padding-left: 36px;
}

.custom-select-trigger:hover, .custom-select-trigger:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 2px rgba(37,99,235,0.1);
  outline: none;
}

.custom-select-trigger.disabled {
  background: #f1f5f9;
  color: #94a3b8;
  cursor: not-allowed;
}

.custom-select-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: white;
  border-radius: 8px;
  box-shadow: 0 10px 25px -5px rgba(0,0,0,0.1);
  border: 1px solid #e2e8f0;
  z-index: 50;
  overflow: hidden;
  max-height: 200px;
  overflow-y: auto;
}

.custom-select-option {
  padding: 8px 12px;
  font-size: 13px;
  color: #475569;
  cursor: pointer;
  transition: background 0.1s;
}

.custom-select-option:hover {
  background: #eff6ff;
  color: #2563eb;
  font-weight: 500;
}
.team-container {
  padding: 24px 32px;
  height: 100vh;
  box-sizing: border-box;
  background: #f8fafc;
  overflow-y: auto;
}

.team-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
}

.team-column {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

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

.column-header h2 {
  margin: 0;
  font-size: 14px;
  font-weight: 800;
  color: #0f172a;
}

.btn-add {
  padding: 6px 16px;
  font-size: 13px;
}

.btn-add.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.cards-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.team-card {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(0,0,0,0.02);
  border-left: 4px solid #2563eb;
}

.team-card:nth-child(even) {
  border-left-color: #4f46e5;
}

.card-header {
  padding: 8px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid transparent;
  cursor: pointer;
}
.card-header:hover {
  background: #f8fafc;
}

.user-info {
  display: flex;
  gap: 12px;
  align-items: center;
}

.avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
}

.details h4 {
  margin: 0 0 2px 0;
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
}

.details p {
  margin: 0;
  font-size: 11px;
  color: #64748b;
}

.badges {
  display: flex;
  gap: 8px;
  align-items: center;
}

.role-badge {
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 800;
  color: white;
}

.role-am {
  background: #3b82f6;
}

.role-rev {
  background: #2563eb;
}

.status-badge {
  padding: 2px 8px;
  border-radius: 12px;
  font-size: 10px;
  font-weight: 700;
}

.status-active {
  background: #dcfce7;
  color: #166534;
}

.card-body {
  padding: 8px 12px;
  border-top: 1px solid #f1f5f9;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #f8fafc;
}

.status-row {
  background: #f1f5f9;
  border-radius: 6px;
  padding: 4px 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.blue-text {
  color: #2563eb;
  font-size: 11px;
  font-weight: 600;
}

.card-footer {
  /* removed in favor of inline */
}

.actions {
  display: flex;
  gap: 8px;
}

.btn-action {
  background: white;
  border: 1px solid #cbd5e1;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  color: #475569;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-remove {
  color: #ef4444;
  border-color: #f1f5f9;
}

.check-ring {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #dcfce7;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Modal styles */
.team-modal {
  width: 500px;
}

.team-modal .modal-header {
  padding: 16px 24px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.team-modal .modal-header h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: #0f172a;
}

.team-modal .modal-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 70vh;
  overflow-y: auto;
}

.input-label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: #0f172a;
  margin-bottom: 4px;
}

.team-modal .input-field {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 13px;
  outline: none;
  box-sizing: border-box;
}

.team-modal .input-with-icon .input-icon {
  color: #3b82f6;
}

.mb-0 {
  margin-bottom: 0;
}

.border-t {
  border-top: 1px solid #e2e8f0;
}

.page-card {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  width: 100%;
  box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
  display: flex;
  flex-direction: column;
  height: 100%;
}
.page-card-header {
  padding: 16px 32px;
  border-bottom: 1px solid #e2e8f0;
}
.page-card-header h3 { margin: 0; font-size: 20px; font-weight: 800; color: #0f172a; }
.page-card-body { 
  padding: 24px 32px; 
  display: flex; 
  flex-direction: column; 
  gap: 16px; 
  flex: 1;
  overflow-y: auto; 
}
.page-card-footer { padding: 16px 32px; display: flex; justify-content: flex-end; gap: 12px; background: #f8fafc; border-top: 1px solid #e2e8f0; margin: 0 -32px -24px -32px; border-bottom-left-radius: 12px; border-bottom-right-radius: 12px; }
.error-field { border-color: #ef4444 !important; background: #fef2f2 !important; }
.reports-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
}

.kpi-cards-wrapper {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.kpi-card {
  flex: 1;
  min-width: 200px;
  background: white;
  border-radius: 12px;
  padding: 20px;
  border: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  gap: 16px;
  position: relative;
  overflow: hidden;
}

.kpi-card::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 40px;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="%23eff6ff" fill-opacity="1" d="M0,192L48,197.3C96,203,192,213,288,229.3C384,245,480,267,576,250.7C672,235,768,181,864,181.3C960,181,1056,235,1152,234.7C1248,235,1344,181,1392,154.7L1440,128L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>') no-repeat bottom;
  background-size: cover;
  opacity: 0.6;
  z-index: 0;
}

.kpi-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #3b82f6;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.kpi-content {
  z-index: 1;
}

.kpi-value {
  font-size: 24px;
  font-weight: 700;
  color: #1e3a8a;
  line-height: 1.2;
}

.kpi-label {
  font-size: 13px;
  color: #64748b;
  font-weight: 500;
}

.reports-content-box {
  background: white;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
}

.reports-tabs {
  display: flex;
  padding: 16px;
  gap: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.report-tab {
  padding: 10px 20px;
  border-radius: 6px;
  border: 1px solid #e2e8f0;
  background: white;
  color: #475569;
  font-weight: 500;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
}

.report-tab:hover {
  background: #f8fafc;
}

.report-tab.active {
  background: #3b82f6;
  color: white;
  border-color: #3b82f6;
}

.reports-filters {
  padding: 16px;
  display: flex;
  gap: 16px;
  align-items: center;
  flex-wrap: wrap;
}

.date-range-filter {
  display: flex;
  align-items: center;
  gap: 12px;
}

.date-input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.date-input-wrapper input {
  padding: 10px 12px;
  padding-right: 32px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  font-size: 14px;
  color: #334155;
  width: 140px;
}

.date-input-wrapper svg {
  position: absolute;
  right: 10px;
  color: #94a3b8;
  pointer-events: none;
}

.dropdown-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  padding: 0 12px;
  height: 40px;
  min-width: 200px;
  background: white;
}

.dropdown-filter label {
  color: #64748b;
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
}

.dropdown-filter select {
  border: none;
  background: transparent;
  outline: none;
  flex: 1;
  color: #0f172a;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
}

.reports-table {
  width: 100%;
  border-collapse: collapse;
}

.reports-table th {
  background: #e0e7ff;
  color: #1e3a8a;
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  padding: 12px 24px;
}

.reports-table td {
  padding: 16px 24px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 14px;
  color: #334155;
}

.empty-state {
  padding: 60px 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  gap: 12px;
}

.empty-state svg {
  color: #cbd5e1;
}
