/* RAVID Report Real Single Owner v47
   Scoped only to #section-report.rv47-report-page. No landing/login/game/quiz/video logic touched. */
#section-report.rv47-report-page {
  --rv47-blue: #2563eb;
  --rv47-cyan: #0ea5e9;
  --rv47-ink: #08142f;
  --rv47-muted: #65748b;
  --rv47-line: rgba(96, 165, 250, 0.34);
  --rv47-card: rgba(255,255,255,0.92);
  color: var(--rv47-ink);
}

#section-report.rv47-report-page .rv47-shell {
  width: min(1120px, 100%);
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

#section-report.rv47-report-page .rv47-hero,
#section-report.rv47-report-page .rv47-main-card,
#section-report.rv47-report-page .rv47-side-card,
#section-report.rv47-report-page .rv47-error {
  border: 1px solid var(--rv47-line);
  background: linear-gradient(135deg, rgba(255,255,255,.96), rgba(239,248,255,.86));
  box-shadow: 0 24px 70px rgba(37, 99, 235, .09), inset 0 1px 0 rgba(255,255,255,.92);
}

#section-report.rv47-report-page .rv47-hero {
  position: relative;
  overflow: hidden;
  min-height: 280px;
  border-radius: 32px;
  padding: clamp(26px, 4vw, 42px);
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, .72fr);
  align-items: center;
  gap: 24px;
}

#section-report.rv47-report-page .rv47-hero::before {
  content: "";
  position: absolute;
  inset: -30% -10% auto 42%;
  height: 360px;
  pointer-events: none;
  background: radial-gradient(circle, rgba(14, 165, 233, .17), transparent 68%);
}

#section-report.rv47-report-page .rv47-hero > * { position: relative; z-index: 1; }
#section-report.rv47-report-page .rv47-hero h1 {
  margin: 18px 0 12px;
  font-size: clamp(42px, 5vw, 64px);
  line-height: .95;
  letter-spacing: -.065em;
  font-weight: 1000;
}
#section-report.rv47-report-page .rv47-hero p {
  max-width: 640px;
  margin: 0;
  color: var(--rv47-muted);
  font-weight: 750;
  line-height: 1.75;
}
#section-report.rv47-report-page .rv47-eyebrow,
#section-report.rv47-report-page .rv47-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  border-radius: 999px;
  border: 1px solid rgba(37, 99, 235, .18);
  background: rgba(239, 246, 255, .92);
  color: #1d4ed8;
  font-size: 12px;
  font-weight: 950;
}
#section-report.rv47-report-page .rv47-eyebrow { padding: 9px 14px; }
#section-report.rv47-report-page .rv47-privacy {
  margin-top: 22px;
  max-width: 440px;
  display: grid;
  grid-template-columns: 46px 1fr;
  gap: 13px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 20px;
  border: 1px solid rgba(96, 165, 250, .32);
  background: rgba(255,255,255,.82);
}
#section-report.rv47-report-page .rv47-privacy > span {
  width: 46px;
  height: 46px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #2563eb, #06b6d4);
}
#section-report.rv47-report-page .rv47-privacy strong { display:block; color:#1d4ed8; font-weight:1000; }
#section-report.rv47-report-page .rv47-privacy small { display:block; color:#475569; font-weight:800; line-height:1.45; }
#section-report.rv47-report-page .rv47-hero figure { margin:0; display:grid; place-items:center; }
#section-report.rv47-report-page .rv47-hero img { width:min(300px, 100%); filter: drop-shadow(0 22px 30px rgba(37,99,235,.17)); }
#section-report.rv47-report-page .rv47-back {
  position:absolute;
  top:24px;
  right:28px;
  z-index:3;
  border:1px solid rgba(37,99,235,.22);
  border-radius:999px;
  background:#fff;
  color:#1d4ed8;
  font-weight:950;
  padding:10px 15px;
  cursor:pointer;
}

#section-report.rv47-report-page .rv47-metrics {
  display:grid;
  grid-template-columns: repeat(4, minmax(0,1fr));
  gap:14px;
}
#section-report.rv47-report-page .rv47-metrics article {
  min-height:92px;
  display:flex;
  align-items:center;
  gap:14px;
  padding:16px;
  border:1px solid var(--rv47-line);
  border-radius:24px;
  background:rgba(255,255,255,.92);
  box-shadow:0 18px 48px rgba(15,23,42,.055);
}
#section-report.rv47-report-page .rv47-icon {
  flex:0 0 50px;
  width:50px;
  height:50px;
  border-radius:17px;
  display:grid;
  place-items:center;
  color:#fff;
  font-weight:1000;
}
#section-report.rv47-report-page .rv47-icon.blue { background:linear-gradient(135deg,#2563eb,#06b6d4); }
#section-report.rv47-report-page .rv47-icon.green { background:linear-gradient(135deg,#16a34a,#22c55e); }
#section-report.rv47-report-page .rv47-icon.purple { background:linear-gradient(135deg,#7c3aed,#a855f7); }
#section-report.rv47-report-page .rv47-icon.amber { background:linear-gradient(135deg,#f59e0b,#f97316); }
#section-report.rv47-report-page .rv47-metrics small { display:block; color:#334155; font-size:12px; font-weight:950; }
#section-report.rv47-report-page .rv47-metrics b { display:block; margin-top:3px; color:var(--rv47-ink); font-size:28px; line-height:1; letter-spacing:-.04em; }
#section-report.rv47-report-page .rv47-metrics em { display:block; margin-top:4px; color:#64748b; font-style:normal; font-size:11px; font-weight:850; }

#section-report.rv47-report-page .rv47-grid {
  display:grid;
  grid-template-columns:minmax(0,1.28fr) 320px;
  gap:18px;
  align-items:start;
}
#section-report.rv47-report-page .rv47-main-card,
#section-report.rv47-report-page .rv47-side-card { border-radius:26px; }
#section-report.rv47-report-page .rv47-main-card { padding:18px; overflow:hidden; }
#section-report.rv47-report-page .rv47-card-head { display:flex; justify-content:space-between; gap:14px; margin-bottom:14px; align-items:flex-start; }
#section-report.rv47-report-page .rv47-card-head h2,
#section-report.rv47-report-page .rv47-side-card h3 { margin:0; letter-spacing:-.045em; }
#section-report.rv47-report-page .rv47-card-head p,
#section-report.rv47-report-page .rv47-side-card p { margin:7px 0 0; color:#64748b; font-weight:750; line-height:1.55; }
#section-report.rv47-report-page .rv47-card-head > span { padding:8px 12px; border-radius:999px; background:#ecfeff; color:#0284c7; font-weight:950; border:1px solid #bae6fd; }
#section-report.rv47-report-page .rv47-table-wrap { overflow-x:auto; border:1px solid #dbeafe; border-radius:20px; }
#section-report.rv47-report-page table { width:100%; min-width:780px; border-collapse:collapse; }
#section-report.rv47-report-page th { text-align:left; padding:12px; background:#f8fbff; color:#475569; font-size:11px; text-transform:uppercase; letter-spacing:.045em; }
#section-report.rv47-report-page td { padding:14px 12px; border-top:1px solid #eaf2ff; color:#334155; font-weight:850; }
#section-report.rv47-report-page td span:not(.rv47-pill):not(.rv47-subject) { color:#64748b; }
#section-report.rv47-report-page .rv47-subject { display:inline-flex; align-items:center; gap:8px; color:#0f172a; }
#section-report.rv47-report-page .rv47-subject i { width:24px; height:24px; display:grid; place-items:center; border-radius:8px; background:#eff6ff; font-style:normal; }
#section-report.rv47-report-page .rv47-pill { justify-content:center; min-width:44px; padding:6px 10px; }
#section-report.rv47-report-page .rv47-pill.is-blue { background:#dbeafe; color:#2563eb; }
#section-report.rv47-report-page .rv47-pill.is-good { background:#dcfce7; color:#15803d; }
#section-report.rv47-report-page .rv47-pill.is-warn { background:#fef3c7; color:#b45309; }
#section-report.rv47-report-page .rv47-pill.is-bad { background:#fee2e2; color:#b91c1c; }
#section-report.rv47-report-page .rv47-pill.is-neutral { background:#f1f5f9; color:#64748b; }
#section-report.rv47-report-page .rv47-invalid-row { opacity:.76; }
#section-report.rv47-report-page .rv47-empty-row td { text-align:center; padding:28px !important; }
#section-report.rv47-report-page .rv47-empty-row strong { display:block; color:#0f172a; font-size:16px; }
#section-report.rv47-report-page .rv47-empty-row span { display:block; margin-top:6px; color:#64748b; }
#section-report.rv47-report-page .rv47-learning-actions { margin-top:14px; display:flex; gap:10px; flex-wrap:wrap; }
#section-report.rv47-report-page .rv47-learning-actions button,
#section-report.rv47-report-page .rv47-error button {
  border:1px solid rgba(37,99,235,.18);
  border-radius:999px;
  background:#fff;
  color:#1d4ed8;
  font-weight:950;
  padding:10px 14px;
  cursor:pointer;
}

#section-report.rv47-report-page .rv47-side { display:grid; gap:14px; }
#section-report.rv47-report-page .rv47-side-card { padding:18px; }
#section-report.rv47-report-page .rv47-ring {
  --deg: 0deg;
  width:138px;
  height:138px;
  margin:14px auto;
  border-radius:999px;
  display:grid;
  place-items:center;
  position:relative;
  background:conic-gradient(#2563eb var(--deg), #e8f1ff 0deg);
}
#section-report.rv47-report-page .rv47-ring.green { background:conic-gradient(#22c55e var(--deg), #e8f1ff 0deg); }
#section-report.rv47-report-page .rv47-ring::after { content:""; position:absolute; inset:18px; border-radius:inherit; background:#fff; box-shadow:inset 0 0 0 1px #dbeafe; }
#section-report.rv47-report-page .rv47-ring span { position:relative; z-index:1; text-align:center; color:#0f172a; font-size:26px; font-weight:1000; line-height:1; }
#section-report.rv47-report-page .rv47-ring small { display:block; margin-top:5px; color:#64748b; font-size:10px; font-weight:950; line-height:1.2; }
#section-report.rv47-report-page .rv47-progress { height:10px; border-radius:999px; overflow:hidden; background:#e5efff; }
#section-report.rv47-report-page .rv47-progress i { display:block; height:100%; border-radius:inherit; background:linear-gradient(90deg,#22c55e,#2563eb); }
#section-report.rv47-report-page .rv47-subject-bar { margin-top:14px; }
#section-report.rv47-report-page .rv47-subject-bar > div { display:flex; justify-content:space-between; gap:10px; font-weight:950; color:#0f172a; }
#section-report.rv47-report-page .rv47-subject-bar em { display:block; margin-top:7px; height:9px; border-radius:999px; background:#e5efff; overflow:hidden; }
#section-report.rv47-report-page .rv47-subject-bar i { display:block; height:100%; border-radius:inherit; background:#ef4444; }
#section-report.rv47-report-page .rv47-subject-bar.good i { background:#22c55e; }
#section-report.rv47-report-page .rv47-subject-bar.warn i { background:#f59e0b; }
#section-report.rv47-report-page .rv47-subject-bar small { display:block; margin-top:5px; color:#64748b; font-weight:800; font-size:11px; }
#section-report.rv47-report-page .rv47-empty-chart { margin-top:12px; padding:14px; border-radius:16px; background:#f8fbff; color:#64748b; font-weight:800; line-height:1.5; }
#section-report.rv47-report-page .rv47-tip { background:linear-gradient(135deg,#fff,#f0fdf4); }
#section-report.rv47-report-page .rv47-error { border-radius:28px; padding:38px; text-align:center; }
#section-report.rv47-report-page .rv47-error span { font-size:34px; }

@media (max-width: 1020px) {
  #section-report.rv47-report-page .rv47-hero,
  #section-report.rv47-report-page .rv47-grid { grid-template-columns:1fr; }
  #section-report.rv47-report-page .rv47-metrics { grid-template-columns:repeat(2,minmax(0,1fr)); }
  #section-report.rv47-report-page .rv47-back { position:static; width:fit-content; }
}
@media (max-width: 680px) {
  #section-report.rv47-report-page .rv47-metrics { grid-template-columns:1fr; }
  #section-report.rv47-report-page .rv47-hero { padding:24px; }
}

/* RAVID Report v51 - maximized proportional layout guard. */
#section-report.rv47-report-page {
  --rv51-report-max: 1188px;
  --rv51-side-width: 252px;
  --rv51-grid-gap: 12px;
}

#section-report.rv47-report-page .rv47-shell {
  width: min(var(--rv51-report-max), calc(100vw - 24px));
  gap: 14px;
}

#section-report.rv47-report-page .rv47-hero {
  min-height: 238px;
  padding: clamp(22px, 3vw, 34px) clamp(28px, 4vw, 42px);
  grid-template-columns: minmax(0, 1.35fr) minmax(210px, .48fr);
}

#section-report.rv47-report-page .rv47-hero h1 {
  font-size: clamp(40px, 4.8vw, 60px);
}

#section-report.rv47-report-page .rv47-hero img {
  width: min(250px, 100%);
}

#section-report.rv47-report-page .rv47-metrics {
  gap: 12px;
}

#section-report.rv47-report-page .rv47-metrics article {
  min-height: 78px;
  padding: 12px 14px;
}

#section-report.rv47-report-page .rv47-metrics b {
  font-size: 25px;
}

#section-report.rv47-report-page .rv47-grid {
  grid-template-columns: minmax(0, 1fr) minmax(224px, var(--rv51-side-width));
  gap: var(--rv51-grid-gap);
}

#section-report.rv47-report-page .rv47-main-card {
  min-width: 0;
  padding: 16px;
  overflow: visible;
}

#section-report.rv47-report-page .rv47-side {
  min-width: 0;
  gap: 12px;
}

#section-report.rv47-report-page .rv47-side-card {
  min-width: 0;
  padding: 14px;
}

#section-report.rv47-report-page .rv47-side-card h3 {
  font-size: 18px;
}

#section-report.rv47-report-page .rv47-side-card p {
  font-size: 12.5px;
  line-height: 1.5;
}

#section-report.rv47-report-page .rv47-ring {
  width: 112px;
  height: 112px;
  margin: 10px auto 12px;
}

#section-report.rv47-report-page .rv47-ring::after {
  inset: 14px;
}

#section-report.rv47-report-page .rv47-ring span {
  font-size: 23px;
}

#section-report.rv47-report-page .rv47-ring small {
  font-size: 9.5px;
}

#section-report.rv47-report-page .rv47-card-head {
  align-items: flex-start;
  gap: 10px;
}

#section-report.rv47-report-page .rv47-card-head h2 {
  font-size: clamp(20px, 1.8vw, 24px);
}

#section-report.rv47-report-page .rv47-card-head p {
  max-width: 760px;
  font-size: 13px;
  line-height: 1.45;
}

#section-report.rv47-report-page .rv47-card-head > span {
  flex: 0 0 auto;
  padding: 7px 10px;
  font-size: 12px;
  line-height: 1.15;
}

#section-report.rv47-report-page .rv47-table-wrap {
  width: 100%;
  max-width: 100%;
  overflow-x: visible;
  border-radius: 18px;
}

#section-report.rv47-report-page table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

#section-report.rv47-report-page th,
#section-report.rv47-report-page td {
  box-sizing: border-box;
  padding: 10px 7px;
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  word-break: normal;
  overflow-wrap: anywhere;
}

#section-report.rv47-report-page th {
  font-size: 9px;
  letter-spacing: .028em;
}

#section-report.rv47-report-page td {
  font-size: 12px;
  line-height: 1.25;
}

#section-report.rv47-report-page th:nth-child(1),
#section-report.rv47-report-page td:nth-child(1) { width: 18%; }
#section-report.rv47-report-page th:nth-child(2),
#section-report.rv47-report-page td:nth-child(2) { width: 20%; }
#section-report.rv47-report-page th:nth-child(3),
#section-report.rv47-report-page td:nth-child(3) { width: 10%; }
#section-report.rv47-report-page th:nth-child(4),
#section-report.rv47-report-page td:nth-child(4) { width: 9%; }
#section-report.rv47-report-page th:nth-child(5),
#section-report.rv47-report-page td:nth-child(5) { width: 15%; }
#section-report.rv47-report-page th:nth-child(6),
#section-report.rv47-report-page td:nth-child(6) { width: 13%; }
#section-report.rv47-report-page th:nth-child(7),
#section-report.rv47-report-page td:nth-child(7) { width: 15%; }

#section-report.rv47-report-page .rv47-subject {
  gap: 6px;
  max-width: 100%;
}

#section-report.rv47-report-page .rv47-subject i {
  width: 19px;
  height: 19px;
  flex: 0 0 19px;
  border-radius: 7px;
}

#section-report.rv47-report-page .rv47-subject b {
  min-width: 0;
  line-height: 1.15;
}

#section-report.rv47-report-page .rv47-pill {
  min-width: 0;
  max-width: 100%;
  padding: 5px 7px;
  font-size: 10.5px;
  line-height: 1.15;
  white-space: normal;
}

#section-report.rv47-report-page .rv47-learning-actions {
  gap: 9px;
  margin-top: 12px;
}

#section-report.rv47-report-page .rv47-learning-actions button {
  padding: 9px 12px;
  font-size: 12px;
}

@media (min-width: 1181px) {
  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: minmax(0, 1fr) 250px;
  }
}

@media (max-width: 1180px) {
  #section-report.rv47-report-page .rv47-shell {
    width: min(1100px, calc(100vw - 20px));
  }

  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: minmax(0, 1fr) 238px;
  }

  #section-report.rv47-report-page th,
  #section-report.rv47-report-page td {
    padding: 9px 6px;
  }

  #section-report.rv47-report-page td {
    font-size: 11.6px;
  }
}

@media (max-width: 980px) {
  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: 1fr;
  }

  #section-report.rv47-report-page .rv47-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  #section-report.rv47-report-page .rv47-shell {
    width: min(100%, calc(100vw - 16px));
  }

  #section-report.rv47-report-page .rv47-table-wrap {
    overflow-x: auto;
  }

  #section-report.rv47-report-page table {
    min-width: 720px;
  }
}

/* RAVID Report v51.1 - balanced readable layout after v51 anti-clipping. */
#section-report.rv47-report-page {
  --rv511-report-max: 1320px;
  --rv511-side-width: 292px;
  --rv511-grid-gap: 16px;
}

#section-report.rv47-report-page .rv47-shell {
  width: min(var(--rv511-report-max), calc(100vw - 28px));
  max-width: var(--rv511-report-max);
  gap: 16px;
}

#section-report.rv47-report-page .rv47-hero {
  min-height: 260px;
  padding: clamp(28px, 3.2vw, 44px) clamp(34px, 4vw, 52px);
  grid-template-columns: minmax(0, 1.42fr) minmax(230px, .52fr);
}

#section-report.rv47-report-page .rv47-hero h1 {
  font-size: clamp(48px, 5vw, 70px);
  line-height: .95;
}

#section-report.rv47-report-page .rv47-hero p {
  font-size: 14.5px;
  line-height: 1.75;
  max-width: 720px;
}

#section-report.rv47-report-page .rv47-hero img {
  width: min(286px, 100%);
}

#section-report.rv47-report-page .rv47-metrics {
  gap: 14px;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

#section-report.rv47-report-page .rv47-metrics article {
  min-height: 92px;
  padding: 16px 18px;
}

#section-report.rv47-report-page .rv47-metrics b {
  font-size: 32px;
  line-height: 1;
}

#section-report.rv47-report-page .rv47-metrics span,
#section-report.rv47-report-page .rv47-metrics small {
  line-height: 1.35;
}

#section-report.rv47-report-page .rv47-grid {
  grid-template-columns: minmax(0, 1fr) minmax(270px, var(--rv511-side-width));
  gap: var(--rv511-grid-gap);
  align-items: start;
}

#section-report.rv47-report-page .rv47-main-card {
  padding: 20px;
  min-width: 0;
  overflow: visible;
}

#section-report.rv47-report-page .rv47-card-head {
  gap: 14px;
  margin-bottom: 18px;
}

#section-report.rv47-report-page .rv47-card-head h2 {
  font-size: clamp(24px, 2vw, 30px);
}

#section-report.rv47-report-page .rv47-card-head p {
  max-width: 840px;
  font-size: 14.2px;
  line-height: 1.65;
}

#section-report.rv47-report-page .rv47-card-head > span {
  padding: 10px 13px;
  font-size: 13.2px;
  border-radius: 999px;
}

#section-report.rv47-report-page .rv47-table-wrap {
  overflow-x: visible;
  border-radius: 20px;
}

#section-report.rv47-report-page table {
  width: 100%;
  table-layout: fixed;
}

#section-report.rv47-report-page th,
#section-report.rv47-report-page td {
  padding: 12px 10px;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
}

#section-report.rv47-report-page th {
  font-size: 10px;
  letter-spacing: .035em;
}

#section-report.rv47-report-page td {
  font-size: 13.4px;
  line-height: 1.35;
}

#section-report.rv47-report-page th:nth-child(1),
#section-report.rv47-report-page td:nth-child(1) { width: 19%; }
#section-report.rv47-report-page th:nth-child(2),
#section-report.rv47-report-page td:nth-child(2) { width: 21%; }
#section-report.rv47-report-page th:nth-child(3),
#section-report.rv47-report-page td:nth-child(3) { width: 10%; }
#section-report.rv47-report-page th:nth-child(4),
#section-report.rv47-report-page td:nth-child(4) { width: 9%; }
#section-report.rv47-report-page th:nth-child(5),
#section-report.rv47-report-page td:nth-child(5) { width: 15%; }
#section-report.rv47-report-page th:nth-child(6),
#section-report.rv47-report-page td:nth-child(6) { width: 12%; }
#section-report.rv47-report-page th:nth-child(7),
#section-report.rv47-report-page td:nth-child(7) { width: 14%; }

#section-report.rv47-report-page .rv47-subject {
  gap: 8px;
}

#section-report.rv47-report-page .rv47-subject i {
  width: 22px;
  height: 22px;
  flex-basis: 22px;
  border-radius: 8px;
}

#section-report.rv47-report-page .rv47-pill {
  padding: 6px 9px;
  font-size: 11.4px;
  line-height: 1.2;
}

#section-report.rv47-report-page .rv47-learning-actions {
  gap: 11px;
  margin-top: 16px;
}

#section-report.rv47-report-page .rv47-learning-actions button {
  padding: 11px 16px;
  font-size: 13.2px;
}

#section-report.rv47-report-page .rv47-side {
  gap: 14px;
}

#section-report.rv47-report-page .rv47-side-card {
  padding: 17px;
  border-radius: 22px;
}

#section-report.rv47-report-page .rv47-side-card h3 {
  font-size: 20px;
}

#section-report.rv47-report-page .rv47-side-card p {
  font-size: 13.4px;
  line-height: 1.62;
}

#section-report.rv47-report-page .rv47-ring {
  width: 134px;
  height: 134px;
  margin: 12px auto 14px;
}

#section-report.rv47-report-page .rv47-ring::after {
  inset: 17px;
}

#section-report.rv47-report-page .rv47-ring span {
  font-size: 29px;
}

#section-report.rv47-report-page .rv47-ring small {
  font-size: 10.5px;
  line-height: 1.1;
}

@media (min-width: 1360px) {
  #section-report.rv47-report-page .rv47-shell {
    width: min(1320px, calc(100vw - 40px));
  }

  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: minmax(0, 1fr) 300px;
  }
}

@media (max-width: 1180px) {
  #section-report.rv47-report-page .rv47-shell {
    width: min(1120px, calc(100vw - 20px));
  }

  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: minmax(0, 1fr) 260px;
  }

  #section-report.rv47-report-page td {
    font-size: 12.2px;
  }

  #section-report.rv47-report-page th,
  #section-report.rv47-report-page td {
    padding: 10px 7px;
  }
}

@media (max-width: 980px) {
  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: 1fr;
  }

  #section-report.rv47-report-page .rv47-side {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 720px) {
  #section-report.rv47-report-page .rv47-shell {
    width: min(100%, calc(100vw - 16px));
  }

  #section-report.rv47-report-page .rv47-metrics {
    grid-template-columns: 1fr;
  }

  #section-report.rv47-report-page .rv47-table-wrap {
    overflow-x: auto;
  }

  #section-report.rv47-report-page table {
    min-width: 760px;
  }
}

/* RAVID Report v51.2 - parent grid expansion and anti clipping.
   Fokus: perbesar kartu induk/page shell agar Daftar Aktivitas & Hasil tidak dipotong. */
body:has(#section-report.rv47-report-page:not(.hidden)) .main-container {
  padding-left: clamp(10px, 1.3vw, 22px);
  padding-right: clamp(10px, 1.3vw, 22px);
}

body:has(#section-report.rv47-report-page:not(.hidden)) .card {
  width: min(1480px, calc(100vw - 36px));
  max-width: min(1480px, calc(100vw - 36px));
  overflow: visible;
  padding-left: clamp(22px, 2.2vw, 36px);
  padding-right: clamp(22px, 2.2vw, 36px);
}

#section-report.rv47-report-page {
  width: 100%;
  max-width: none;
  overflow: visible;
}

#section-report.rv47-report-page .rv47-shell {
  width: 100%;
  max-width: 1420px;
  margin-inline: auto;
  overflow: visible;
}

#section-report.rv47-report-page .rv47-hero {
  width: 100%;
  overflow: hidden;
}

#section-report.rv47-report-page .rv47-metrics {
  width: 100%;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

#section-report.rv47-report-page .rv47-grid {
  width: 100%;
  grid-template-columns: minmax(0, 1fr) minmax(310px, 340px);
  gap: 16px;
  overflow: visible;
  align-items: start;
}

#section-report.rv47-report-page .rv47-main-card {
  min-width: 0;
  width: 100%;
  overflow: visible;
  padding: 20px 18px;
}

#section-report.rv47-report-page .rv47-side {
  min-width: 0;
  width: 100%;
}

#section-report.rv47-report-page .rv47-side-card {
  overflow: hidden;
}

#section-report.rv47-report-page .rv47-table-wrap {
  width: 100%;
  overflow-x: visible;
  overflow-y: visible;
}

#section-report.rv47-report-page table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
}

#section-report.rv47-report-page th,
#section-report.rv47-report-page td {
  box-sizing: border-box;
  padding: 12px 9px;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
}

#section-report.rv47-report-page th:nth-child(1),
#section-report.rv47-report-page td:nth-child(1) { width: 19%; }
#section-report.rv47-report-page th:nth-child(2),
#section-report.rv47-report-page td:nth-child(2) { width: 20%; }
#section-report.rv47-report-page th:nth-child(3),
#section-report.rv47-report-page td:nth-child(3) { width: 10%; }
#section-report.rv47-report-page th:nth-child(4),
#section-report.rv47-report-page td:nth-child(4) { width: 8%; }
#section-report.rv47-report-page th:nth-child(5),
#section-report.rv47-report-page td:nth-child(5) { width: 14%; }
#section-report.rv47-report-page th:nth-child(6),
#section-report.rv47-report-page td:nth-child(6) { width: 14%; }
#section-report.rv47-report-page th:nth-child(7),
#section-report.rv47-report-page td:nth-child(7) { width: 15%; }

#section-report.rv47-report-page .rv47-pill {
  white-space: normal;
  min-width: 0;
  max-width: 100%;
}

#section-report.rv47-report-page .rv47-card-head > span {
  flex: 0 0 auto;
}

@media (min-width: 1500px) {
  body:has(#section-report.rv47-report-page:not(.hidden)) .card {
    width: min(1520px, calc(100vw - 48px));
    max-width: min(1520px, calc(100vw - 48px));
  }

  #section-report.rv47-report-page .rv47-shell {
    max-width: 1460px;
  }

  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: minmax(0, 1fr) 350px;
  }
}

@media (max-width: 1320px) {
  body:has(#section-report.rv47-report-page:not(.hidden)) .card {
    width: min(1240px, calc(100vw - 24px));
    max-width: min(1240px, calc(100vw - 24px));
    padding-left: 20px;
    padding-right: 20px;
  }

  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: minmax(0, 1fr) minmax(285px, 305px);
    gap: 14px;
  }

  #section-report.rv47-report-page .rv47-side-card {
    padding: 15px;
  }

  #section-report.rv47-report-page .rv47-ring {
    width: 120px;
    height: 120px;
  }

  #section-report.rv47-report-page .rv47-ring span {
    font-size: 25px;
  }
}

@media (max-width: 1120px) {
  #section-report.rv47-report-page .rv47-grid {
    grid-template-columns: 1fr;
  }

  #section-report.rv47-report-page .rv47-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    display: grid;
  }
}

@media (max-width: 720px) {
  body:has(#section-report.rv47-report-page:not(.hidden)) .card {
    width: calc(100vw - 14px);
    max-width: calc(100vw - 14px);
    padding-left: 12px;
    padding-right: 12px;
  }

  #section-report.rv47-report-page .rv47-side {
    grid-template-columns: 1fr;
  }

  #section-report.rv47-report-page .rv47-table-wrap {
    overflow-x: auto;
  }

  #section-report.rv47-report-page table {
    min-width: 760px;
  }
}

/* RAVID v56 - Report Flexible Parent Guard */
#section-report:not(.hidden),
#section-report:not(.hidden) .rv47-shell {
  height: auto !important;
  min-height: auto !important;
  max-height: none !important;
  overflow: visible !important;
}

#section-report:not(.hidden) .rv47-content-grid {
  align-items: start !important;
  overflow: visible !important;
}

#section-report:not(.hidden) .rv47-panel,
#section-report:not(.hidden) .rv47-side-card {
  overflow: visible !important;
  height: auto !important;
}

/* RAVID Report v57 - Parent Flow Guard
   Tujuan: parent/container terbesar halaman Rapor harus mengikuti tinggi seluruh child,
   terutama ketika sidebar kanan lebih tinggi daripada kartu Daftar Aktivitas.
   Tidak mengubah rumus data v50 dan tidak menyentuh app.js/backend. */

body:has(#section-report.rv47-report-page:not(.hidden)) {
  overflow-y: auto !important;
}

body:has(#section-report.rv47-report-page:not(.hidden)) .main-container {
  display: block !important;
  height: auto !important;
  min-height: 100vh !important;
  max-height: none !important;
  overflow: visible !important;
  padding-bottom: clamp(56px, 5vw, 96px) !important;
}

body:has(#section-report.rv47-report-page:not(.hidden)) #card-root.card,
body:has(#section-report.rv47-report-page:not(.hidden)) .card#card-root {
  display: block !important;
  height: auto !important;
  min-height: fit-content !important;
  max-height: none !important;
  overflow: visible !important;
  contain: none !important;
  isolation: isolate !important;
  padding-bottom: clamp(34px, 3vw, 56px) !important;
}

body:has(#section-report.rv47-report-page:not(.hidden)) #card-root.card::before,
body:has(#section-report.rv47-report-page:not(.hidden)) #card-root.card::after {
  pointer-events: none !important;
}

#section-report.rv47-report-page:not(.hidden) {
  display: block !important;
  position: relative !important;
  height: auto !important;
  min-height: fit-content !important;
  max-height: none !important;
  overflow: visible !important;
  padding-bottom: clamp(26px, 2.4vw, 44px) !important;
  contain: none !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-shell {
  display: grid !important;
  grid-template-columns: 1fr !important;
  grid-auto-rows: max-content !important;
  align-content: start !important;
  height: auto !important;
  min-height: fit-content !important;
  max-height: none !important;
  overflow: visible !important;
  padding-bottom: clamp(20px, 2vw, 34px) !important;
  contain: none !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-hero,
#section-report.rv47-report-page:not(.hidden) .rv47-metrics,
#section-report.rv47-report-page:not(.hidden) .rv47-grid {
  position: relative !important;
  width: 100% !important;
  height: auto !important;
  min-height: auto !important;
  max-height: none !important;
  contain: none !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-grid {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(305px, 335px) !important;
  align-items: stretch !important;
  gap: clamp(14px, 1.35vw, 20px) !important;
  overflow: visible !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-main-card {
  align-self: stretch !important;
  height: auto !important;
  min-height: 100% !important;
  max-height: none !important;
  overflow: visible !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-side {
  align-self: stretch !important;
  display: grid !important;
  grid-template-columns: 1fr !important;
  grid-auto-rows: max-content !important;
  align-content: start !important;
  gap: clamp(14px, 1.25vw, 18px) !important;
  height: auto !important;
  min-height: 100% !important;
  max-height: none !important;
  overflow: visible !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-side-card,
#section-report.rv47-report-page:not(.hidden) .rv47-panel,
#section-report.rv47-report-page:not(.hidden) .rv47-table-wrap,
#section-report.rv47-report-page:not(.hidden) .rv47-learning-actions {
  position: relative !important;
  height: auto !important;
  min-height: auto !important;
  max-height: none !important;
  overflow: visible !important;
  contain: none !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-side-card {
  width: 100% !important;
  flex: 0 0 auto !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-table-wrap {
  overflow-x: visible !important;
  overflow-y: visible !important;
}

#section-report.rv47-report-page:not(.hidden) table.rv47-table,
#section-report.rv47-report-page:not(.hidden) table {
  width: 100% !important;
  min-width: 0 !important;
  table-layout: fixed !important;
}

#section-report.rv47-report-page:not(.hidden) th,
#section-report.rv47-report-page:not(.hidden) td {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  overflow-wrap: anywhere !important;
}

#section-report.rv47-report-page:not(.hidden) .rv47-pill {
  white-space: normal !important;
  overflow-wrap: anywhere !important;
  line-height: 1.15 !important;
}

@media (min-width: 1440px) {
  #section-report.rv47-report-page:not(.hidden) .rv47-grid {
    grid-template-columns: minmax(0, 1fr) minmax(320px, 350px) !important;
  }
}

@media (max-width: 1180px) {
  #section-report.rv47-report-page:not(.hidden) .rv47-grid {
    grid-template-columns: 1fr !important;
  }

  #section-report.rv47-report-page:not(.hidden) .rv47-side {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

@media (max-width: 760px) {
  body:has(#section-report.rv47-report-page:not(.hidden)) #card-root.card,
  body:has(#section-report.rv47-report-page:not(.hidden)) .card#card-root {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  #section-report.rv47-report-page:not(.hidden) .rv47-side {
    grid-template-columns: 1fr !important;
  }

  #section-report.rv47-report-page:not(.hidden) .rv47-table-wrap {
    overflow-x: auto !important;
  }

  #section-report.rv47-report-page:not(.hidden) table.rv47-table,
  #section-report.rv47-report-page:not(.hidden) table {
    min-width: 760px !important;
  }
}
