/* Shared light-mode overrides for embedded interactive whitepapers */
:root {
  --wp-bg: #09090b;
  --wp-panel: #0a0a0a;
  --wp-text: #ffffff;
  --wp-muted: #a1a1aa;
  --wp-muted-dim: #52525b;
  --wp-muted-faint: #3f3f46;
  --wp-border: rgba(255, 255, 255, 0.08);
  --wp-border-subtle: rgba(255, 255, 255, 0.04);
  --wp-glass-bg: rgba(255, 255, 255, 0.03);
  --wp-glass-hover: rgba(255, 255, 255, 0.06);
  --wp-track: #18181b;
}

.light {
  --wp-bg: #ffffff;
  --wp-panel: #f8fafc;
  --wp-text: #0b1220;
  --wp-muted: #4b5563;
  --wp-muted-dim: #6b7280;
  --wp-muted-faint: #9ca3af;
  --wp-border: rgba(15, 23, 42, 0.12);
  --wp-border-subtle: rgba(15, 23, 42, 0.08);
  --wp-glass-bg: rgba(15, 23, 42, 0.04);
  --wp-glass-hover: rgba(15, 23, 42, 0.07);
  --wp-track: #e5e7eb;
}

.light body {
  background: var(--wp-bg);
  color: var(--wp-text);
}

.light ::-webkit-scrollbar-thumb {
  background: #d1d5db;
}

.light ::selection {
  background: rgba(5, 150, 105, 0.2);
  color: var(--wp-text);
}

/* Shell */
.light #sidebar {
  background: rgba(255, 255, 255, 0.98);
  border-right-color: var(--wp-border-subtle);
}

.light #topnav {
  background: rgba(255, 255, 255, 0.95);
  border-bottom-color: var(--wp-border-subtle);
}

.light #mobpanel {
  background: #ffffff;
  border-right-color: var(--wp-border-subtle);
}

.light #moboverlay {
  background: rgba(15, 23, 42, 0.35);
}

/* Sidebar / top nav */
.light .sb-label {
  color: var(--wp-muted-faint);
}

.light .sb-btn {
  color: var(--wp-muted);
}

.light .sb-btn:hover {
  color: var(--wp-text);
  background: rgba(15, 23, 42, 0.04);
}

.light .sb-btn.active {
  color: #059669;
  background: rgba(5, 150, 105, 0.08);
}

.light .sb-btn .n {
  color: var(--wp-muted-faint);
}

.light .sb-divider {
  background: var(--wp-border-subtle);
}

.light .tn-btn {
  color: var(--wp-muted);
}

.light .tn-btn:hover {
  color: var(--wp-text);
  background: rgba(15, 23, 42, 0.04);
}

.light .tn-btn.active {
  color: var(--wp-text);
  background: rgba(15, 23, 42, 0.06);
}

/* Cards & surfaces */
.light .glass {
  background: var(--wp-glass-bg);
  border-color: var(--wp-border);
}

.light .glass:hover {
  background: var(--wp-glass-hover);
  border-color: rgba(15, 23, 42, 0.16);
}

.light .gtxt {
  background: linear-gradient(to right, #0b1220, #4b5563);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.light .hgrad {
  background: radial-gradient(ellipse at top, rgba(5, 150, 105, 0.12), #ffffff 70%, #f1f5f9);
}

.light .gridbg {
  background-image:
    linear-gradient(to right, rgba(15, 23, 42, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(15, 23, 42, 0.05) 1px, transparent 1px);
}

/* Common inline text colors */
.light [style*="color:#fff"],
.light [style*="color:#ffffff"] {
  color: var(--wp-text) !important;
}

.light [style*="color:#a1a1aa"] {
  color: var(--wp-muted) !important;
}

.light [style*="color:#71717a"] {
  color: var(--wp-muted) !important;
}

.light [style*="color:#52525b"] {
  color: var(--wp-muted-dim) !important;
}

.light [style*="color:#3f3f46"] {
  color: var(--wp-muted-dim) !important;
}

.light [style*="background:none"][style*="color:#71717a"][style*="border:1px solid rgba(255,255,255,.08)"] {
  color: var(--wp-muted) !important;
  border-color: var(--wp-border) !important;
}

/* Full-width layout inside #main (beside fixed sidebar) */
#main [style*="max-width:800px"],
#main [style*="max-width: 800px"],
#main [style*="max-width:640px"],
#main [style*="max-width: 640px"],
#main [style*="max-width:600px"],
#main [style*="max-width: 600px"],
#main [style*="max-width:560px"],
#main [style*="max-width: 560px"] {
  max-width: none !important;
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  box-sizing: border-box;
}

#main [style*="margin:0 auto"],
#main [style*="margin: 0 auto"] {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

#main .pg {
  width: 100%;
}

@media (min-width: 1024px) {
  #main [style*="padding:32px"],
  #main [style*="padding:40px 32px"],
  #main [style*="padding:20px 32px"],
  #main [style*="padding:40px 32px 20px"],
  #main [style*="padding:40px 32px 50px"] {
    padding-left: 48px !important;
    padding-right: 48px !important;
  }
}

.light [style*="background:rgba(255,255,255,.03)"] {
  background: rgba(15, 23, 42, 0.04) !important;
}

.light [style*="background:rgba(255,255,255,.04)"] {
  background: rgba(15, 23, 42, 0.05) !important;
}

.light [style*="background:rgba(255,255,255,.06)"] {
  background: rgba(15, 23, 42, 0.06) !important;
}

.light [style*="border:1px solid rgba(255,255,255,.08)"],
.light [style*="border:1px solid rgba(255,255,255,.04)"] {
  border-color: var(--wp-border) !important;
}

.light [style*="border-top:1px solid rgba(255,255,255,.04)"],
.light [style*="border-bottom:1px solid rgba(255,255,255,.04)"] {
  border-color: var(--wp-border-subtle) !important;
}

.light [style*="height:1px;background:rgba(255,255,255,.04)"] {
  background: var(--wp-border-subtle) !important;
}

.light [style*="background:#18181b"] {
  background: var(--wp-track) !important;
}

/* Primary CTA buttons stay high-contrast */
.light [style*="background:#fff"][style*="color:#09090b"],
.light [style*="background:#14b8a6"][style*="color:#09090b"] {
  /* keep as-is */
}

/* Ghost nav buttons */
.light [style*="background:none"][style*="color:#71717a"][style*="border:1px solid rgba(255,255,255,.08)"] {
  color: var(--wp-muted) !important;
  border-color: var(--wp-border) !important;
}
