/* Vazhi — Career Report Page Styles
   Standalone printable report: report.html
   Author: Vazhi வழி
*/

/* ── Reset & Base ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --brand:      #0F3098;
  --brand-light:#EBF0FF;
  --text1:      #111827;
  --text2:      #374151;
  --text3:      #6B7280;
  --border:     #E5E7EB;
  --bg:         #F9FAFB;
  --white:      #ffffff;
  --green:      #16a34a;
  --blue:       #2563eb;
  --amber:      #d97706;
  --red:        #dc2626;
  --radius:     10px;
  --font:       'Segoe UI', system-ui, -apple-system, sans-serif;
}

body {
  font-family: var(--font);
  font-size: 15px;
  color: var(--text1);
  background: var(--bg);
  line-height: 1.6;
}

/* ── Page wrapper ─────────────────────────────────────────────────────────── */
.report-page {
  max-width: 860px;
  margin: 0 auto;
  padding: 24px 20px 60px;
}

/* ── No-report fallback ────────────────────────────────────────────────────── */
.report-missing {
  text-align: center;
  padding: 80px 24px;
}
.report-missing h2 { font-size: 1.4rem; color: var(--text2); margin-bottom: 12px; }
.report-missing p  { color: var(--text3); margin-bottom: 24px; }
.report-missing a  {
  display: inline-block;
  padding: 12px 28px;
  background: var(--brand);
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
}

/* ── Top action bar (no-print) ─────────────────────────────────────────────── */
.report-action-bar {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-bottom: 20px;
}
.report-action-bar button {
  padding: 8px 20px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  border: none;
}
.btn-print {
  background: var(--brand);
  color: #fff;
}
.btn-print:hover { background: #0a2070; }
.btn-back {
  background: var(--white);
  color: var(--text2);
  border: 1.5px solid var(--border) !important;
}
.btn-back:hover { background: var(--bg); }

/* ── Cover Header ─────────────────────────────────────────────────────────── */
.report-header {
  background: var(--brand);
  color: #fff;
  border-radius: var(--radius);
  padding: 32px 36px;
  margin-bottom: 24px;
  position: relative;
  overflow: hidden;
}
.report-header::after {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 200px; height: 200px;
  background: rgba(255,255,255,0.05);
  border-radius: 50%;
}
.report-header-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}
.report-brand {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  opacity: 0.9;
}
.report-brand span { opacity: 0.7; font-weight: 400; font-size: 0.9rem; }
.report-meta {
  font-size: 0.82rem;
  opacity: 0.75;
  text-align: right;
  line-height: 1.8;
}
.report-student-name {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}
.report-student-name.unnamed { font-size: 1.3rem; opacity: 0.7; }
.report-tagline {
  font-size: 0.95rem;
  opacity: 0.8;
  margin-bottom: 24px;
}
.report-code-badges {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.report-code-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 18px;
  border-radius: 50px;
  background: rgba(255,255,255,0.2);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  backdrop-filter: blur(4px);
  border: 1.5px solid rgba(255,255,255,0.35);
}
.report-code-plus {
  align-self: center;
  font-size: 1.3rem;
  opacity: 0.6;
}

/* ── Summary line ──────────────────────────────────────────────────────────── */
.report-summary-line {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-left: 4px solid var(--brand);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 18px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text2);
  line-height: 1.6;
}

/* ── Section wrapper ──────────────────────────────────────────────────────── */
.report-section {
  background: var(--white);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  margin-bottom: 18px;
}
.report-section-title {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--text3);
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1.5px solid var(--border);
}

/* ── Holland profile hero ─────────────────────────────────────────────────── */
.report-holland-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--brand);
  margin-bottom: 6px;
}
.report-holland-sub {
  font-size: 0.88rem;
  color: var(--text3);
  margin-bottom: 14px;
}
.report-type-desc {
  font-size: 0.97rem;
  color: var(--text2);
  line-height: 1.7;
  margin-bottom: 14px;
}

/* ── "You are…" bullets ───────────────────────────────────────────────────── */
.report-traits {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 16px;
  margin-top: 12px;
}
.report-trait {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.9rem;
  color: var(--text2);
  line-height: 1.4;
}
.report-trait::before {
  content: '✓';
  color: var(--green);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 1px;
}

/* ── Top-3 fits (best fit + 2 runner-ups, each with a % score) ──────────────── */
.report-top3-row { margin-top: 12px; }
.report-subtype-lbl { font-size: 0.82rem; color: var(--text3); }
.report-top3-list { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.report-top3-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 12px; border-radius: 10px;
  background: var(--bg); border: 1px solid var(--border);
}
.report-top3-item.report-top3-best {
  background: var(--brand-light); border: 1px solid #BDD0FF;
}
.report-top3-icon { font-size: 1.1rem; flex-shrink: 0; }
.report-top3-body { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.report-top3-name { font-size: 0.85rem; font-weight: 700; color: var(--text1); }
.report-top3-fitlabel { font-size: 0.72rem; color: var(--text3); }
.report-top3-best .report-top3-fitlabel { color: var(--brand); font-weight: 600; }
.report-top3-pct { font-size: 0.85rem; font-weight: 800; color: var(--brand); flex-shrink: 0; }

/* ── RIASEC bar chart ─────────────────────────────────────────────────────── */
.report-bars { display: flex; flex-direction: column; gap: 10px; }

.report-bar-row {
  display: grid;
  grid-template-columns: 140px 1fr 48px;
  align-items: center;
  gap: 10px;
}
.report-bar-row.top-type .report-bar-label { font-weight: 700; }
.report-bar-row.top-type .report-bar-fill-wrap {
  border: 1.5px solid currentColor;
  border-radius: 4px;
  opacity: 1;
}

.report-bar-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.88rem;
  color: var(--text2);
}
.report-bar-type-code {
  font-weight: 800;
  font-size: 0.92rem;
}
.report-bar-track {
  background: #F3F4F6;
  border-radius: 6px;
  height: 14px;
  overflow: hidden;
}
.report-bar-fill {
  height: 100%;
  border-radius: 6px;
  transition: width 1s cubic-bezier(0.4,0,0.2,1);
}
.report-bar-pct {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text2);
  text-align: right;
}

/* ── Skill bars ───────────────────────────────────────────────────────────── */
.report-skill-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 20px;
}
.report-skill-row {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.report-skill-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.report-skill-name { font-size: 0.85rem; font-weight: 600; color: var(--text2); }
.report-skill-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 1px 8px;
  border-radius: 50px;
}
.skill-excellent { background: #dcfce7; color: #15803d; }
.skill-good      { background: #dbeafe; color: #1d4ed8; }
.skill-average   { background: #fef3c7; color: #92400e; }
.skill-developing{ background: #fee2e2; color: #991b1b; }

.report-skill-track {
  background: #F3F4F6;
  border-radius: 4px;
  height: 8px;
  overflow: hidden;
}
.report-skill-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 1s cubic-bezier(0.4,0,0.2,1);
}
.report-skill-desc { font-size: 0.78rem; color: var(--text3); line-height: 1.4; }

/* ── Work style ───────────────────────────────────────────────────────────── */
.report-workstyle-items { display: flex; flex-direction: column; gap: 10px; }
.report-ws-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text2);
  background: var(--bg);
  border-radius: 8px;
  padding: 10px 14px;
}
.report-ws-ico { font-size: 1.1rem; flex-shrink: 0; }
.report-ws-text strong { color: var(--brand); }

/* ── Career cards ─────────────────────────────────────────────────────────── */
.report-career-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.report-career-card {
  border-radius: 8px;
  padding: 14px 16px;
  border: 1.5px solid var(--border);
  border-top-width: 3px;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}
.report-career-ico { font-size: 1.6rem; flex-shrink: 0; }
.report-career-body { flex: 1; min-width: 0; }
.report-career-title { font-size: 0.95rem; font-weight: 700; margin-bottom: 2px; }
.report-career-roles { font-size: 0.78rem; color: var(--text3); line-height: 1.5; margin-bottom: 6px; }
.report-career-exams { font-size: 0.75rem; color: var(--text3); margin-bottom: 6px; }
.report-why-line {
  font-size: 0.85rem;
  color: var(--text3);
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px dashed var(--border);
}
.report-career-link {
  font-size: 0.75rem;
  color: var(--brand);
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}
.report-career-link:hover { text-decoration: underline; }

/* ── Stream recommendation (8-10) ────────────────────────────────────────── */
.report-stream-card {
  border-left: 4px solid var(--brand);
  padding: 14px 18px;
  background: var(--bg);
  border-radius: 0 8px 8px 0;
  margin-bottom: 12px;
}
.report-stream-badge {
  display: inline-block;
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 50px;
  margin-bottom: 8px;
}
.report-stream-subjects { font-size: 0.88rem; color: var(--text2); margin-bottom: 4px; }
.report-stream-leads    { font-size: 0.85rem; color: var(--text3); margin-bottom: 6px; }
.report-stream-tip      { font-size: 0.85rem; color: var(--text2); font-style: italic; }
.report-stream-alt      { font-size: 0.85rem; color: var(--text3); margin-top: 8px; }
.report-focus-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.report-focus-tag {
  background: var(--brand-light);
  color: var(--brand);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 50px;
  border: 1px solid #BDD0FF;
}

/* ── Next steps ───────────────────────────────────────────────────────────── */
.report-steps { display: flex; flex-direction: column; gap: 10px; }
.report-step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--bg);
  border-radius: 8px;
  padding: 12px 16px;
}
.report-step-num {
  background: var(--brand);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 700;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.report-step-text { font-size: 0.9rem; color: var(--text2); line-height: 1.5; }
.report-step-text a { color: var(--brand); font-weight: 600; }

/* ── Footer / Disclaimer ──────────────────────────────────────────────────── */
.report-footer {
  text-align: center;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1.5px solid var(--border);
  color: var(--text3);
  font-size: 0.8rem;
  line-height: 1.8;
}
.report-footer strong { color: var(--text2); }
.report-disclaimer {
  font-style: italic;
  font-size: 0.78rem;
  color: var(--text3);
  margin-top: 8px;
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
}

/* ── Tamil secondary text ─────────────────────────────────────────────────── */
.rpt-ta   { display: block; font-size: 1em; font-weight: 600; line-height: 1.4; }
.rpt-en-sub { display: block; font-size: 0.82em; color: var(--text3); margin-top: 2px; }

/* ── Print styles ─────────────────────────────────────────────────────────── */
@media print {
  body { background: #fff; font-size: 11pt; }

  .report-action-bar { display: none !important; }
  .no-print          { display: none !important; }

  .report-page { padding: 0; max-width: 100%; }

  .report-header {
    border-radius: 0;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .report-section {
    break-inside: avoid;
    border: 1px solid #ddd;
    margin-bottom: 12px;
  }

  .report-career-grid { grid-template-columns: 1fr 1fr; }
  .report-skill-grid  { grid-template-columns: 1fr 1fr; }

  .report-bar-fill,
  .report-skill-fill {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  .report-code-badge,
  .report-stream-badge {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  a { color: inherit; text-decoration: none; }
}

/* ── Responsive (screens narrower than 600px) ─────────────────────────────── */
@media (max-width: 600px) {
  .report-header { padding: 22px 20px; }
  .report-student-name { font-size: 1.5rem; }
  .report-section { padding: 18px 16px; }
  .report-traits  { grid-template-columns: 1fr; }
  .report-skill-grid   { grid-template-columns: 1fr; }
  .report-career-grid  { grid-template-columns: 1fr; }
  .report-bar-row { grid-template-columns: 100px 1fr 40px; }
}
