/* =========================================================
CPIP | STRATEGIC AUDIT REPORT CSS STYLESHEET
========================================================= */

:root {
  --gold: #d4af37;
  --dark: #050505;
  --paper: #ffffff;
}
body {
  font-family: "Inter", sans-serif;
  background-color: #f4f7f6;
  margin: 0;
  padding: 0;
}

.no-print {
  max-width: 900px;
  margin: 20px auto;
  background: var(--dark);
  color: white;
  padding: 25px;
  border-radius: 8px;
  display: flex;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
  align-items: center;
}

.download-btn {
  background: var(--gold);
  color: black;
  padding: 12px 30px;
  border: none;
  font-weight: 900;
  cursor: pointer;
  text-transform: uppercase;
  border-radius: 50px;
  transition: 0.3s;
}
.download-btn:hover {
  background: white;
  transform: scale(1.05);
}

.decision-btn {
  background: transparent;
  color: var(--gold);
  border: 2px solid var(--gold);
  padding: 10px 25px;
  border-radius: 50px;
  cursor: pointer;
  font-weight: bold;
  transition: 0.3s;
  text-transform: uppercase;
}
.decision-btn:hover {
  background: var(--gold);
  color: black;
}

#report-wrapper {
  width: 210mm;
  margin: 0 auto;
}

.report-page {
  width: 210mm;
  min-height: 297mm;
  background: var(--paper);
  padding: 15mm;
  box-sizing: border-box;
  border-top: 10px solid var(--dark);
  position: relative;
  margin-bottom: 20px;
  page-break-after: always;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
}

.report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--gold);
  padding-bottom: 10px;
  margin-bottom: 20px;
}
.logo-text {
  font-family: "Cinzel", serif;
  font-size: 1.4rem;
  font-weight: 900;
  color: var(--dark);
}

.section-title {
  font-weight: 900;
  text-transform: uppercase;
  color: var(--gold);
  border-bottom: 1px solid #eee;
  padding-bottom: 5px;
  margin-top: 15px;
  margin-bottom: 10px;
  font-size: 0.8rem;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 15px;
}
.data-table th,
.data-table td {
  text-align: left;
  padding: 10px;
  border: 1px solid #eee;
  font-size: 0.8rem;
}
.data-table th {
  background: #f9f9f9;
  width: 35%;
  color: #333;
}

.chart-container {
  margin: 10px 0;
  height: 230px;
  width: 100%;
}

.feedback-box {
  background: #fcfbf7;
  border: 1px solid var(--gold);
  padding: 12px;
  font-style: italic;
  line-height: 1.5;
  border-radius: 5px;
  font-size: 0.95rem;
  color: #333;
}

.signature-area {
  margin-top: 35px;
  display: flex;
  justify-content: space-between;
}
.sig-block {
  text-align: center;
  width: 45%;
}
.sig-line {
  border-top: 1px solid #333;
  margin-top: 30px;
  padding-top: 8px;
  font-weight: bold;
  text-transform: uppercase;
  font-size: 0.7rem;
}

.qa-card {
  background: #f9f9f9;
  padding: 10px;
  border-radius: 5px;
  margin-bottom: 10px;
  border-left: 4px solid var(--gold);
}
.q-label {
  font-weight: bold;
  font-size: 0.75rem;
  color: var(--dark);
  display: block;
  margin-bottom: 3px;
}
.a-label {
  font-size: 0.8rem;
  color: #555;
}

.core-box {
  background: #fffdf5;
  border: 2px solid var(--gold);
  padding: 20px;
  border-radius: 10px;
  margin-top: 25px;
}
.core-header {
  font-weight: 900;
  color: var(--gold);
  font-size: 0.9rem;
  margin-bottom: 10px;
  text-transform: uppercase;
  border-bottom: 1px solid var(--gold);
  display: inline-block;
}

.footer-info {
  position: absolute;
  bottom: 8mm;
  left: 15mm;
  right: 15mm;
  text-align: center;
  font-size: 0.6rem;
  color: #999;
  border-top: 1px solid #eee;
  padding-top: 5px;
}

@media print {
  .no-print {
    display: none !important;
  }
}

/* ==========================================================================
SEMANTIC STRUCTURE WRAPPERS
========================================================================== */

.semantic-structure {
  display: contents;
}

@media screen and (max-width: 768px) {
  body {
    margin: 0;
    padding: 12px;
    overflow-x: hidden;
  }

  #report-wrapper,
  .report-page {
    width: 100%;
    max-width: 100%;
    min-height: 0;
    padding: 18px 14px 48px;
    box-sizing: border-box;
  }

  .report-header,
  .signature-area {
    gap: 16px;
    flex-direction: column;
    align-items: stretch;
  }

  .sig-block {
    width: 100%;
  }

  .data-table {
    display: block;
    width: 100%;
    overflow-x: auto;
  }

  .footer-info {
    left: 14px;
    right: 14px;
    bottom: 10px;
  }
}
.audit-status {
  width: 100%;
  margin-top: 10px;
  color: #00ffcc;
  font-size: 0.85rem;
  font-weight: bold;
  text-align: center;
}

.report-meta {
  color: #666;
  font-size: 0.6rem;
}

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

.report-identity-title {
  font-size: 0.85rem;
  font-weight: 900;
}

.report-title {
  margin-bottom: 20px;
  color: var(--dark);
  font-family: "Cinzel", serif;
  font-size: 1.5rem;
  text-align: center;
}

.model-result,
.audit-score {
  font-weight: bold;
}

.audit-score {
  color: green;
}

.protocol-signature {
  color: var(--gold);
}

.dynamic-question {
  margin-bottom: 12px;
  color: #333;
  font-size: 0.9rem;
  font-weight: bold;
}
.physician-role {
  color: var(--dark);
}

.ai-role {
  color: var(--gold);
}
