/* /projects/survivable_hybrid_cloud/common/css/report.css */

/* ==========================================
   REPORT NAVIGATION BAR
   ========================================== */
.report-nav {
  background: white;
  border-bottom: 2px solid #e5e7eb;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  position: sticky;
  top: 0;
  z-index: 999;
}

.report-nav-container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0.75rem 1rem;
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.nav-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: white;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  transition: all 0.2s ease;
}

.nav-btn:hover {
  background: #eff6ff;
  border-color: #3b82f6;
  color: #1e40af;
  transform: translateY(-1px);
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.2);
}

.nav-btn:active {
  transform: translateY(0);
}

.nav-icon {
  width: 1.25rem;
  height: 1.25rem;
  flex-shrink: 0;
}

/* Hide text on very small screens */
@media (max-width: 480px) {
  .nav-btn span {
    display: none;
  }
  .nav-btn {
    padding: 0.5rem;
  }
}

/* ==========================================
   REPORT MAIN CONTENT
   ========================================== */
.report-main {
  max-width: 1100px;
  margin: 2rem auto;
  padding: 0 1rem;
}

.report-article {
  background: white;
  border-radius: 0.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  padding: 2rem;
}

/* ==========================================
   REPORT HEADER
   ========================================== */
.report-header {
  border-bottom: 3px solid #004080;
  padding-bottom: 1.5rem;
  margin-bottom: 2rem;
}

.report-title {
  font-size: 1.875rem;
  font-weight: 700;
  color: #004080;
  margin-bottom: 1rem;
  line-height: 1.2;
}

.report-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.9375rem;
}

.meta-item {
  color: #4b5563;
}

.meta-item strong {
  color: #1f2937;
}

/* ==========================================
   REPORT SECTIONS
   ========================================== */
.report-section {
  margin-bottom: 2.5rem;
}

.report-section h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #e5e7eb;
}

/* ==========================================
   SUMMARY BOX
   ========================================== */
.summary-box {
  background: linear-gradient(135deg, #eff6ff 0%, #dbeafe 100%);
  border-left: 4px solid #3b82f6;
  padding: 1.5rem;
  border-radius: 0.5rem;
  margin-bottom: 2rem;
}

.summary-box h2 {
  color: #1e40af;
  border-bottom: none;
  margin-bottom: 0.75rem;
}

.summary-box p {
  line-height: 1.7;
  color: #1e3a8a;
}

/* ==========================================
   REPORT TABLE
   ========================================== */
.table-container {
  overflow-x: auto;
  margin-bottom: 1rem;
}

.report-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
}

.report-table th {
  background: #e8eefc;
  color: #004080;
  font-weight: 600;
  text-align: left;
  padding: 1rem;
  width: 25%;
  vertical-align: top;
  border-bottom: 1px solid #d1d5db;
}

.report-table td {
  padding: 1rem;
  border-bottom: 1px solid #e5e7eb;
  vertical-align: top;
  line-height: 1.6;
}

.report-table tr:last-child td,
.report-table tr:last-child th {
  border-bottom: none;
}

.impact-list {
  margin: 0;
  padding-left: 1.25rem;
}

.impact-list li {
  margin-bottom: 0.5rem;
}

/* Mobile table optimization */
@media (max-width: 768px) {
  .report-table,
  .report-table tbody,
  .report-table tr,
  .report-table th,
  .report-table td {
    display: block;
    width: 100%;
  }

  .report-table tr {
    margin-bottom: 1rem;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    overflow: hidden;
  }

  .report-table th {
    background: #004080;
    color: white;
    padding: 0.75rem;
    border-bottom: none;
  }

  .report-table td {
    padding: 0.75rem;
    border-bottom: 1px dashed #d1d5db;
  }

  .report-table tr:last-child td {
    border-bottom: none;
  }
}

/* ==========================================
   TIMELINE
   ========================================== */
.timeline {
  position: relative;
  padding-left: 2rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 0.5rem;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #d1d5db;
}

.timeline-item {
  position: relative;
  padding-bottom: 1.5rem;
}

.timeline-marker {
  position: absolute;
  left: -1.5rem;
  top: 0.25rem;
  width: 1rem;
  height: 1rem;
  border-radius: 50%;
  background: #3b82f6;
  border: 2px solid white;
  box-shadow: 0 0 0 2px #3b82f6;
}

.timeline-marker.critical {
  background: #ef4444;
  box-shadow: 0 0 0 2px #ef4444;
}

.timeline-marker.resolved {
  background: #10b981;
  box-shadow: 0 0 0 2px #10b981;
}

.timeline-content {
  padding-left: 1rem;
  line-height: 1.6;
}

.timeline-content strong {
  color: #1f2937;
  font-weight: 600;
}

/* ==========================================
   FINDINGS GRID
   ========================================== */
.findings-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
  margin-top: 1rem;
}

.finding-card {
  padding: 1.5rem;
  border-radius: 0.5rem;
  border-left: 4px solid;
}

.finding-card h3 {
  font-size: 1.125rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.finding-card p {
  line-height: 1.6;
  color: #4b5563;
}

.finding-card.vulnerability {
  background: #fef2f2;
  border-color: #ef4444;
}

.finding-card.vulnerability h3 {
  color: #991b1b;
}

.finding-card.threat {
  background: #fef3c7;
  border-color: #f59e0b;
}

.finding-card.threat h3 {
  color: #92400e;
}

.finding-card.impact {
  background: #ede9fe;
  border-color: #8b5cf6;
}

.finding-card.impact h3 {
  color: #5b21b6;
}

.finding-card.lesson {
  background: #dbeafe;
  border-color: #3b82f6;
}

.finding-card.lesson h3 {
  color: #1e40af;
}

/* ==========================================
   RECOMMENDATIONS
   ========================================== */
.recommendations {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.recommendation-item {
  padding: 1rem;
  background: #f9fafb;
  border-left: 4px solid #9ca3af;
  border-radius: 0.375rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.rec-priority {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  flex-shrink: 0;
}

.rec-priority.high {
  background: #fecaca;
  color: #991b1b;
}

.rec-priority.medium {
  background: #fed7aa;
  color: #92400e;
}

.rec-priority.low {
  background: #bfdbfe;
  color: #1e40af;
}

.recommendation-item p {
  margin: 0;
  line-height: 1.6;
}

/* ==========================================
   REFERENCES
   ========================================== */
.references {
  background: #f9fafb;
  padding: 1.5rem;
  border-radius: 0.5rem;
}

.reference-list {
  margin: 0;
  padding-left: 1.5rem;
  line-height: 2;
}

.reference-list li {
  margin-bottom: 0.5rem;
  color: #4b5563;
}

/* ==========================================
   FOOTER
   ========================================== */
.report-footer {
  text-align: center;
  padding: 2rem 1rem;
  color: #6b7280;
  font-size: 0.875rem;
}

/* ==========================================
   PRINT STYLES
   ========================================== */
@media print {
  body {
    background: white;
  }

  .report-nav,
  #header-container,
  .report-footer {
    display: none;
  }

  .report-main {
    margin: 0;
    padding: 0;
  }

  .report-article {
    box-shadow: none;
    padding: 1rem;
  }

  .report-section {
    page-break-inside: avoid;
  }

  .finding-card,
  .recommendation-item {
    page-break-inside: avoid;
  }

  .timeline-item {
    page-break-inside: avoid;
  }

  a[href]:after {
    content: " (" attr(href) ")";
    font-size: 0.8em;
    color: #666;
  }
}

/* ==========================================
   RESPONSIVE ADJUSTMENTS
   ========================================== */
@media (max-width: 768px) {
  .report-article {
    padding: 1rem;
  }

  .report-title {
    font-size: 1.5rem;
  }

  .report-meta {
    flex-direction: column;
    gap: 0.5rem;
  }

  .findings-grid {
    grid-template-columns: 1fr;
  }

  .recommendation-item {
    flex-direction: column;
    gap: 0.5rem;
  }
}
