/* 
=========================================
   TechCerta Manufacturer Demo CSS
=========================================
*/

:root {
  --tc-navy: #0c1e36;
  --tc-blue-primary: #1a56db;
  --tc-blue-hover: #1648c0;
  --tc-light-bg: #f8fafc;
  --tc-border: #e2e8f0;
  --tc-text-dark: #1e293b;
  --tc-text-muted: #64748b;
  
  /* Status Colors */
  --tc-success: #10b981;
  --tc-success-light: #ecfdf5;
  --tc-warning: #f59e0b;
  --tc-warning-light: #fffbeb;
  --tc-danger: #ef4444;
  --tc-danger-light: #fef2f2;
}

body {
  font-family: 'Inter', sans-serif;
  background-color: var(--tc-light-bg);
  color: var(--tc-text-dark);
  font-size: 14px;
}

h1, h2, h3, h4, h5, h6, .brand-title {
  font-family: 'Bricolage Grotesque', sans-serif;
}

/* ── Top Header Navigation ── */
.tc-header {
  background-color: var(--tc-navy);
  padding: 0.5rem 1.5rem;
}

.tc-header .navbar-brand {
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.tc-header .nav-link {
  color: rgba(255, 255, 255, 0.8) !important;
  font-weight: 500;
  font-size: 0.9rem;
  padding: 0.5rem 0.8rem !important;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.tc-header .nav-link:hover, 
.tc-header .nav-link.active {
  color: #fff !important;
  background-color: rgba(255, 255, 255, 0.1);
}

.mfr-badge {
  background-color: #eff6ff;
  color: var(--tc-blue-primary);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  border: 1px solid rgba(26, 86, 219, 0.2);
}

/* ── Superadmin Alert Bar ── */
.superadmin-banner {
  background-color: #dc2626;
  color: #fff;
  font-weight: 600;
  font-size: 0.82rem;
  text-align: center;
  padding: 0.45rem 1rem;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.superadmin-banner a {
  color: #fff;
  text-decoration: underline;
  margin-left: 0.4rem;
}

/* ── Main Layout Container ── */
.main-content {
  padding: 2rem 1.5rem;
  min-height: calc(100vh - 120px);
}

/* ── Custom Cards & KPI Widgets ── */
.kpi-card-outline {
  background: #fff;
  border: 1px solid var(--tc-border);
  border-radius: 12px;
  padding: 1.25rem;
  height: 100%;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.kpi-card-outline:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.06);
}

.kpi-card-outline.border-danger-custom {
  border-left: 4px solid var(--tc-danger);
}
.kpi-card-outline.border-warning-custom {
  border-left: 4px solid var(--tc-warning);
}
.kpi-card-outline.border-success-custom {
  border-left: 4px solid var(--tc-success);
}

.kpi-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.07em;
  color: var(--tc-text-muted);
}

.kpi-value {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
  margin: 0.35rem 0;
}

.kpi-desc {
  font-size: 0.8rem;
  color: var(--tc-text-muted);
}

.kpi-btn-outline {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  text-align: center;
  display: inline-block;
  text-decoration: none;
  transition: all 0.15s ease;
}

.kpi-btn-outline.red-btn {
  border: 1px solid rgba(239, 68, 68, 0.3);
  color: var(--tc-danger);
}
.kpi-btn-outline.red-btn:hover {
  background-color: var(--tc-danger-light);
}

.kpi-btn-outline.blue-btn {
  border: 1px solid rgba(26, 86, 219, 0.3);
  color: var(--tc-blue-primary);
}
.kpi-btn-outline.blue-btn:hover {
  background-color: #f0f6ff;
}

/* ── Financial overview color blocks ── */
.fin-block {
  border-radius: 12px;
  padding: 1.5rem;
  color: #fff;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.06);
}

.fin-block.blue {
  background: linear-gradient(135deg, #1d4ed8, #2563eb);
}
.fin-block.green {
  background: linear-gradient(135deg, #059669, #10b981);
}
.fin-block.red {
  background: linear-gradient(135deg, #dc2626, #ef4444);
}

.fin-block-label {
  font-size: 0.76rem;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  opacity: 0.9;
}

.fin-block-val {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  margin: 0.4rem 0 0.1rem;
}

/* ── Custom Flat Stat Cards ── */
.stat-card-flat {
  background: #fff;
  border: 1px solid var(--tc-border);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  text-align: center;
  box-shadow: 0 1px 2px rgba(0,0,0,0.03);
}

.stat-flat-val {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--tc-navy);
}

.stat-flat-lbl {
  font-size: 0.78rem;
  color: var(--tc-text-muted);
  font-weight: 600;
}

/* ── Tables Customization ── */
.tc-table-card {
  background: #fff;
  border: 1px solid var(--tc-border);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.tc-table thead th {
  background-color: #f8fafc;
  color: var(--tc-text-muted);
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.74rem;
  letter-spacing: 0.05em;
  padding: 0.85rem 1rem;
  border-bottom: 2px solid var(--tc-border);
}

.tc-table.dark-header thead th {
  background-color: #1e293b;
  color: #fff;
  border-bottom: none;
}

.tc-table tbody td {
  padding: 0.85rem 1rem;
  vertical-align: middle;
  border-bottom: 1px solid var(--tc-border);
}

.tc-table tbody tr:last-child td {
  border-bottom: none;
}

/* ── Alerts & Warnings ── */
.alert-box {
  border-radius: 8px;
  padding: 0.75rem 1.25rem;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-weight: 500;
  font-size: 0.88rem;
  border-width: 1px;
  border-style: solid;
}

.alert-box.red {
  background-color: var(--tc-danger-light);
  border-color: rgba(239, 68, 68, 0.25);
  color: #b91c1c;
}

.alert-box.yellow {
  background-color: var(--tc-warning-light);
  border-color: rgba(245, 158, 11, 0.25);
  color: #b45309;
}

/* ── Drag & Drop Uploader ── */
.upload-dropzone {
  border: 2px dashed rgba(26, 86, 219, 0.35);
  border-radius: 14px;
  background-color: #fff;
  padding: 3rem 2rem;
  text-align: center;
  transition: all 0.2s ease;
  cursor: pointer;
}

.upload-dropzone:hover, .upload-dropzone.dragover {
  border-color: var(--tc-blue-primary);
  background-color: #f0f6ff;
}

.upload-icon {
  font-size: 2.75rem;
  color: var(--tc-blue-primary);
  margin-bottom: 1rem;
  animation: floatIcon 2s infinite ease-in-out;
}

@keyframes floatIcon {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

/* ── Interactive Calculator Styles ── */
.calc-card {
  background: #fff;
  border: 1px solid var(--tc-border);
  border-radius: 16px;
  padding: 1.75rem;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.04);
}

.calc-slider-wrap {
  margin-bottom: 1.5rem;
}

.calc-slider-wrap label {
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: flex;
  justify-content: space-between;
}

.calc-slider-wrap .slider-val {
  color: var(--tc-blue-primary);
  font-weight: 800;
}

.calc-results {
  background-color: var(--tc-navy);
  color: #fff;
  border-radius: 12px;
  padding: 1.5rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.calc-res-title {
  font-size: 0.85rem;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.6);
}

.calc-res-value {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 2.2rem;
  font-weight: 800;
  color: #fff;
  margin-bottom: 1rem;
}

.calc-res-value.savings {
  color: #34d399;
}

/* ── Reports Center Tiles ── */
.report-tile {
  background: #fff;
  border: 1px solid var(--tc-border);
  border-radius: 10px;
  padding: 1.15rem;
  transition: all 0.2s ease;
  height: 100%;
}

.report-tile:hover {
  border-color: #c7d2fe;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.04);
}

.report-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.5rem;
}

.report-title {
  font-weight: 700;
  font-size: 0.94rem;
  color: var(--tc-navy);
}

.report-desc {
  font-size: 0.78rem;
  color: var(--tc-text-muted);
  line-height: 1.4;
  margin-bottom: 1rem;
}

/* ── Signature Verification Scan Effect ── */
.signature-box-wrap {
  border: 1px solid var(--tc-border);
  background-color: #fafbfc;
  border-radius: 10px;
  padding: 1rem;
  position: relative;
  overflow: hidden;
}

.sig-image-container {
  height: 100px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.sig-image-container img {
  max-height: 90px;
  max-width: 100%;
}

/* The scanning laser line */
.scanline {
  display: none;
  width: 100%;
  height: 3px;
  background: linear-gradient(to right, transparent, var(--tc-success), transparent);
  position: absolute;
  top: 0;
  left: 0;
  z-index: 10;
  box-shadow: 0 0 8px var(--tc-success);
}

.scanning .scanline {
  display: block;
  animation: laserScan 1.6s infinite ease-in-out;
}

@keyframes laserScan {
  0%, 100% { top: 0%; }
  50% { top: 100%; }
}

.scanning::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(16, 185, 129, 0.04);
  z-index: 5;
  pointer-events: none;
}

/* ── Custom Toasts ── */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 1090;
}

/* ── Custom Footer ── */
.tc-footer {
  background-color: #1e293b;
  color: #94a3b8;
  padding: 3rem 1.5rem 1.5rem;
  font-size: 0.85rem;
  border-top: 1px solid #334155;
}

.tc-footer a {
  color: #cbd5e1;
  text-decoration: none;
  transition: color 0.15s ease;
}

.tc-footer a:hover {
  color: #fff;
}

.tc-footer h6 {
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  margin-bottom: 0.85rem;
}
