/* /css/compass-report.css */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap');

body {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 2rem;
}

.report-container {
    display: flex;
    max-width: 1200px;
    margin: auto;
    background-color: #fff;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.report-sidebar {
    width: 90px;
    background-color: #f3f4f6; /* gray-100 */
    border-right: 1px solid #e5e7eb; /* gray-200 */
    position: sticky;
    top: 2rem;
    height: calc(100vh - 4rem);
    display: flex;
    flex-direction: column;
}

.sidebar-item {
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    text-align: center;
    padding: 1rem 0.5rem;
    text-decoration: none;
    color: #4b5563; /* gray-600 */
    font-weight: bold;
    border-left: 4px solid transparent;
    transition: all 0.2s ease-in-out;
}
.sidebar-item:hover {
    background-color: #e5e7eb; /* gray-200 */
}
.sidebar-item.active {
    background-color: #d1fae5; /* green-100 */
    color: #047857; /* green-700 */
    border-left: 4px solid #10b981; /* green-500 */
}

.report-main {
    flex: 1;
    padding: 2rem 3rem;
    position: relative;
}

.report-header {
    background-color: #1e3a8a; /* blue-900 */
    color: white;
    padding: 0.75rem 1.5rem;
    font-size: 1.5rem;
    font-weight: bold;
    text-align: center;
    margin: -2rem -3rem 2rem -3rem;
    position: relative;
}
.compass-logo {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: white;
    color: #1e3a8a;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    border: 4px solid #1e3a8a;
}

.report-footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid #e5e7eb;
    font-size: 1.25rem;
    color: #6b7280;
}

.report-page {
    padding-bottom: 5rem; /* Space for footer */
    margin-bottom: 2rem;
    border-bottom: 1px dashed #ccc;
}
.report-page:last-child {
    border-bottom: none;
}
.report-title {
    font-size: 1.75rem;
    font-weight: bold;
    color: #1f2937;
    margin-bottom: 1.5rem;
    border-bottom: 2px solid #e5e7eb;
    padding-bottom: 0.5rem;
}
.report-page p {
    line-height: 1.6;
    margin-bottom: 1rem;
    color: #374151;
}

.stats-card {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}
.stats-title {
    font-size: 1.25rem;
    font-weight: bold;
    margin-bottom: 1rem;
}
.bar-chart {
    display: flex;
    justify-content: space-around;
    height: 150px;
    align-items: flex-end;
}
.bar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 12%;
}
.bar-item .bar {
    width: 100%;
    background-color: #60a5fa;
    border-radius: 4px 4px 0 0;
}
.bar-item span {
    font-size: 0.75rem;
    margin-top: 0.5rem;
    text-align: center;
    color: #4b5563;
}
.pie-chart {
    display: flex;
    align-items: center;
    gap: 2rem;
}
@property --p{ syntax: '<number>'; inherits: true; initial-value: 1; }
.pie {
  --p:20; --b:1rem; --c:darkred; --w:100px;
  width: var(--w); aspect-ratio: 1; position: relative;
  display: inline-grid; place-content: center; font-size: 1rem; font-weight: bold;
}
.pie:before, .pie:after {
  content: ""; position: absolute; border-radius: 50%;
}
.pie:before {
  inset: 0; background: radial-gradient(farthest-side,var(--c) 98%,#0000) top/var(--b) var(--b) no-repeat, conic-gradient(var(--c) calc(var(--p)*1%),#0000 0);
  -webkit-mask: radial-gradient(farthest-side,#0000 calc(99% - var(--b)),#000 calc(100% - var(--b)));
  mask: radial-gradient(farthest-side,#0000 calc(99% - var(--b)),#000 calc(100% - var(--b)));
}
.pie:after {
  inset: calc(50% - var(--b)/2); background: var(--c);
  transform: rotate(calc(var(--p)*3.6deg)) translateY(calc(50% - var(--w)/2));
}
.animate { animation: p 1s .5s both; }
@keyframes p { from{--p:0} }

.pie-legend { list-style: none; padding: 0; }
.pie-legend li { display: flex; align-items: center; margin-bottom: 0.5rem; }
.pie-legend i { margin-right: 0.5rem; }

.tag-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag { padding: 0.25rem 0.75rem; border-radius: 9999px; font-size: 0.875rem; }
.tag.generated { background-color: #dbeafe; color: #1e40af; }
.tag.custom { background-color: #d1fae5; color: #065f46; border: 1px solid #065f46; }

.q-a-block { margin-bottom: 2rem; }
.q-a-question { font-weight: bold; font-size: 1.1rem; margin-bottom: 0.5rem; }
.q-a-answer { margin-top: 0.5rem; background: #f9fafb; padding: 0.75rem; border-radius: 4px; border-left: 3px solid #60a5fa; }
.q-a-category { font-size: 0.8rem; color: #6b7280; margin-bottom: 0.75rem; }
.q-a-category .category { display: inline-block; padding: 0.1rem 0.5rem; background: #e5e7eb; border-radius: 4px; margin-right: 0.25rem; }
.q-a-category .category.custom { background-color: #d1fae5; }
.q-a-category .category.generated { background-color: #e0e7ff; }

.answer-chart { margin-top: 0.75rem; space-y-1; }
.answer-bar { display: flex; align-items: center; gap: 0.75rem; }
.answer-bar .label { width: 35%; text-align: right; font-size: 0.9rem; color: #4b5563; }
.answer-bar .bar { height: 1.5rem; line-height: 1.5rem; padding: 0 0.5rem; color: #1f2937; border-radius: 4px; font-weight: bold; text-align: right; font-size: 0.8rem;}

.doc-list { list-style: none; padding: 0; }
.doc-list li { padding: 0.75rem; border-bottom: 1px solid #e5e7eb; display: flex; flex-direction: column; }
.doc-list li a { text-decoration: none; color: #2563eb; font-weight: bold; }
.doc-list li a:hover { text-decoration: underline; }
.doc-list li span { font-size: 0.8rem; color: #6b7280; margin-top: 0.25rem; }