/* ============================================================
   VdP Assessment — gray liquid glass country page
   ============================================================ */

/* full-bleed root so iOS overscroll / safe-area never shows white on the sides */
html:has(body.assess-body) { background: #c6c9cd; }
html[data-theme="dark"]:has(body.assess-body) { background: #14171b; }
body.assess-body {
  background:
    radial-gradient(130% 80% at 50% -20%, rgba(255,255,255,0.75) 0%, rgba(255,255,255,0) 55%),
    linear-gradient(180deg, #dcdee1 0%, #c6c9cd 45%, #b4b8bd 100%);
  color: #25292e;
}
body.assess-body::after { opacity: 0.045; }

/* nav stays in dark-text mode on gray */
.assess-body .nav {
  background: linear-gradient(135deg, rgba(255,255,255,0.55) 0%, rgba(255,255,255,0.26) 100%);
  border-color: rgba(255,255,255,0.85);
  box-shadow: 0 12px 40px rgba(40, 46, 56, 0.14), inset 0 1px 0 rgba(255,255,255,0.9);
  color: #25292e;
}
.assess-body .nav-links a:hover { background: rgba(37, 41, 46, 0.07); }
.assess-body .nav-links a.current { background: rgba(37, 41, 46, 0.09); }
.assess-body .nav-brand img { filter: invert(1); opacity: 0.75; }
.assess-body .lang-toggle { background: rgba(37,41,46,0.05); border-color: rgba(37,41,46,0.16); }
.assess-body .lang-toggle button { color: rgba(37,41,46,0.6); }
.assess-body .lang-toggle button.active { background: #25292e; color: #fff; box-shadow: 0 2px 8px rgba(37,41,46,0.3); }

/* ---- ambient depth behind the glass — makes transparency visible ---- */
/* NOTE: no filter:blur here — huge blurred layers are GPU-expensive; the radial gradients are already soft */
.as-ambient {
  position: fixed;
  top: -20%; right: -20%; bottom: -20%; left: -20%;
  z-index: 0;
  pointer-events: none;
}
.as-ambient i {
  position: absolute;
  border-radius: 50%;
  opacity: 0.55;
  will-change: transform;
}
.as-ambient i:nth-child(1) { width: 44vw; height: 44vw; left: 4%;  top: 12%; background: radial-gradient(circle, #f4f5f7 0%, rgba(244,245,247,0) 70%); animation: amb-drift 26s ease-in-out infinite alternate; }
.as-ambient i:nth-child(2) { width: 38vw; height: 38vw; right: 2%; top: 30%; background: radial-gradient(circle, #8e939b 0%, rgba(142,147,155,0) 70%); opacity: 0.35; animation: amb-drift 34s ease-in-out infinite alternate-reverse; }
.as-ambient i:nth-child(3) { width: 30vw; height: 30vw; left: 30%; bottom: 4%; background: radial-gradient(circle, #d9c9a3 0%, rgba(217,201,163,0) 70%); opacity: 0.30; animation: amb-drift 40s ease-in-out infinite alternate; }
@keyframes amb-drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(6vw, -4vh) scale(1.12); }
}
body.assess-body > *:not(.as-ambient):not(.nav) { position: relative; z-index: 1; }
body.assess-body .nav { position: fixed; z-index: 300; }

/* ---- shared glass on gray ---- */
.g-pane {
  background: linear-gradient(150deg, rgba(255,255,255,0.30) 0%, rgba(255,255,255,0.07) 100%);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.65);
  border-radius: var(--radius-lg);
  box-shadow:
    0 16px 48px rgba(40, 46, 56, 0.18),
    inset 0 1px 0 rgba(255,255,255,0.85),
    inset 0 -1px 0 rgba(255,255,255,0.15);
}

/* ---- hero ---- */
.as-hero {
  padding: 190px 24px 30px;
  text-align: center;
  position: relative;
}
.as-hero .kicker {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  opacity: 0.5;
}
.as-hero h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(44px, 6.4vw, 84px);
  line-height: 1.04;
  margin-top: 18px;
  color: #1d2126;
  text-wrap: balance;
}
.as-hero .sub {
  font-size: clamp(14px, 1.5vw, 17px);
  margin-top: 16px;
  opacity: 0.6;
  font-weight: 500;
}

/* ---- main grid ---- */
.as-grid {
  max-width: 1160px;
  margin: 56px auto 0;
  padding: 0 24px;
  display: grid;
  grid-template-columns: minmax(320px, 460px) 1fr;
  gap: 30px;
  align-items: stretch;
}

/* ---- sculpture pane ---- */
.bear-pane {
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.bear-stage {
  perspective: 1100px;
  flex: 1;
  display: grid;
  place-items: center;
}
.bear-3d {
  position: relative;
  border-radius: calc(var(--radius-lg) - 10px);
  overflow: hidden;
  transform-style: preserve-3d;
  will-change: transform;
  box-shadow: 0 30px 70px rgba(30, 34, 40, 0.35);
  transition: box-shadow 0.4s ease;
}
.bear-3d img {
  width: 100%;
  height: auto;
  display: block;
  transition: filter 0.8s ease;
}
/* gold reveal layer — more visible as erosion grows */
.bear-gild {
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background:
    radial-gradient(38% 30% at 46% 48%, rgba(214, 168, 60, 0.55) 0%, rgba(214,168,60,0) 100%),
    radial-gradient(26% 18% at 62% 88%, rgba(214, 168, 60, 0.5) 0%, rgba(214,168,60,0) 100%),
    radial-gradient(20% 16% at 30% 64%, rgba(226, 188, 90, 0.4) 0%, rgba(226,188,90,0) 100%);
  mix-blend-mode: overlay;
  opacity: 0;
  transition: opacity 0.8s ease;
  pointer-events: none;
}
/* plaster heal layer — whitens as community votes up */
.bear-heal {
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  background: linear-gradient(180deg, rgba(250, 250, 252, 0.55), rgba(250, 250, 252, 0.30));
  opacity: 0;
  transition: opacity 0.8s ease;
  pointer-events: none;
}
/* glass shine sweep on tilt */
.bear-shine {
  position: absolute;
  top: -40%; right: -40%; bottom: -40%; left: -40%;
  background: linear-gradient(115deg, rgba(255,255,255,0) 42%, rgba(255,255,255,0.30) 50%, rgba(255,255,255,0) 58%);
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
  transform: translateX(var(--shine-x, 0%));
}
.bear-stage:hover .bear-shine { opacity: 1; }

/* debris canvas overlays the whole sculpture pane */
.bear-pane { position: relative; overflow: visible; }
.debris-canvas {
  position: absolute;
  left: -30px; right: -30px; top: -30px; bottom: -60px;
  width: calc(100% + 60px);
  height: calc(100% + 90px);
  pointer-events: none;
  z-index: 5;
}
/* jolt on erode, glow on heal */
@keyframes bear-jolt {
  0%, 100% { translate: 0 0; }
  20% { translate: -3px 1px; }
  40% { translate: 3px -1px; }
  60% { translate: -2px 2px; }
  80% { translate: 2px 0; }
}
.bear-3d.jolt { animation: bear-jolt 0.45s ease-in-out; }
@keyframes bear-glow {
  0%, 100% { box-shadow: 0 30px 70px rgba(30, 34, 40, 0.35); }
  40% { box-shadow: 0 30px 80px rgba(63, 174, 106, 0.45); }
}
.bear-3d.glow { animation: bear-glow 1.1s ease-in-out; }

.bear-caption {
  font-size: 12.5px;
  line-height: 1.6;
  opacity: 0.55;
  text-align: center;
  text-wrap: pretty;
}

/* erosion meter */
.erosion {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border-radius: 16px;
  background: rgba(255,255,255,0.28);
  border: 1px solid rgba(255,255,255,0.65);
}
.erosion .lbl {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.55;
  white-space: nowrap;
}
.erosion .track {
  flex: 1;
  display: block;
  height: 8px;
  border-radius: 99px;
  background: rgba(37,41,46,0.12);
  overflow: hidden;
}
.erosion .fill {
  display: block;
  height: 100%;
  border-radius: 99px;
  background: linear-gradient(90deg, #c9a046, #b3782f);
  width: 50%;
  transition: width 0.8s cubic-bezier(.2,.8,.2,1);
}
.erosion .pct {
  font-family: var(--font-mono, monospace);
  font-size: 14px;
  font-weight: 600;
  color: #8a6420;
  min-width: 46px;
  text-align: right;
}

/* ---- indicators pane ---- */
.ind-pane { padding: 38px 38px 30px; display: flex; flex-direction: column; }
.ind-pane .ind-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 26px;
  color: #1d2126;
}
.ind-pane .ind-sub {
  font-size: 13.5px;
  opacity: 0.55;
  margin-top: 6px;
  line-height: 1.6;
  text-wrap: pretty;
}
.ind-list {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}
.ind-row {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border-radius: 18px;
  background: linear-gradient(150deg, rgba(255,255,255,0.34), rgba(255,255,255,0.14));
  border: 1px solid rgba(255,255,255,0.7);
  box-shadow: 0 6px 20px rgba(40,46,56,0.10), inset 0 1px 0 rgba(255,255,255,0.8);
  transition: transform 0.3s cubic-bezier(.2,.8,.2,1), box-shadow 0.3s ease;
}
.ind-row:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(40,46,56,0.13), inset 0 1px 0 rgba(255,255,255,0.95);
}
.ind-name {
  font-size: 14.5px;
  font-weight: 600;
  color: #2a2e33;
}
.ind-name a { border-bottom: 1px dotted rgba(42,46,51,0.35); }
.ind-name a:hover { border-bottom-style: solid; }
.ind-dots {
  display: flex;
  gap: 7px;
  margin-top: 10px;
}
.dot {
  width: 15px;
  height: 15px;
  border-radius: 50%;
  background: rgba(255,255,255,0.75);
  border: 1px solid rgba(37,41,46,0.12);
  box-shadow: inset 0 1px 2px rgba(37,41,46,0.10);
  transition: background 0.4s ease, box-shadow 0.4s ease, transform 0.4s ease;
}
.dot.on-red    { background: #e0452f; border-color: #c33a26; box-shadow: 0 0 10px rgba(224,69,47,0.55), inset 0 1px 0 rgba(255,255,255,0.4); }
.dot.on-amber  { background: #e8a13c; border-color: #cd8a2c; box-shadow: 0 0 10px rgba(232,161,60,0.55), inset 0 1px 0 rgba(255,255,255,0.4); }
.dot.on-green  { background: #3fae6a; border-color: #339157; box-shadow: 0 0 10px rgba(63,174,106,0.55), inset 0 1px 0 rgba(255,255,255,0.4); }
.dot.ghost-up   { background: rgba(63,174,106,0.30); border-color: rgba(63,174,106,0.45); }
.dot.ghost-down { box-shadow: 0 0 6px rgba(224,69,47,0.3), inset 0 1px 2px rgba(37,41,46,0.1); opacity: 0.55; }

/* vote cluster */
.vote {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}
.vote button {
  width: 36px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.38);
  color: rgba(37,41,46,0.55);
  cursor: pointer;
  font-size: 12px;
  line-height: 1;
  transition: all 0.25s ease;
  box-shadow: 0 2px 8px rgba(40,46,56,0.10), inset 0 1px 0 rgba(255,255,255,0.7);
}
.vote button:hover { background: rgba(255,255,255,0.85); color: #25292e; transform: translateY(-1px); }
.vote button.sel-up { background: #3fae6a; border-color: #339157; color: #fff; box-shadow: 0 0 12px rgba(63,174,106,0.45); }
.vote button.sel-down { background: #e0452f; border-color: #c33a26; color: #fff; box-shadow: 0 0 12px rgba(224,69,47,0.45); }

.ind-foot {
  margin-top: 22px;
  font-size: 12px;
  line-height: 1.65;
  opacity: 0.5;
  text-wrap: pretty;
}

/* ---- overview text sections ---- */
.as-sections {
  max-width: 880px;
  margin: 70px auto 0;
  padding: 0 24px 30px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.as-card {
  padding: 34px 38px;
}
.as-card p strong { color: #1d2126; }
.as-card .tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.5;
  white-space: nowrap;
}
.as-card .tag .pip { width: 9px; height: 9px; border-radius: 50%; }
.as-card h3 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 28px;
  color: #1d2126;
  margin-top: 12px;
}
.as-card p {
  font-size: 15.5px;
  line-height: 1.8;
  color: rgba(37, 41, 46, 0.78);
  margin-top: 14px;
  text-wrap: pretty;
}

/* footnote */
.as-note {
  max-width: 880px;
  margin: 30px auto 0;
  padding: 0 24px 120px;
  text-align: center;
  font-size: 12.5px;
  line-height: 1.7;
  opacity: 0.5;
  text-wrap: pretty;
}

@media (max-width: 980px) {
  .as-grid { grid-template-columns: 1fr; }
  .bear-pane { max-width: 460px; margin: 0 auto; width: 100%; }
}
@media (max-width: 520px) {
  .as-hero { padding: 150px 18px 20px; }
  .as-grid { margin-top: 36px; padding: 0 16px; gap: 18px; }
  .bear-pane { padding: 16px; }
  .ind-pane { padding: 26px 20px 22px; }
  .ind-row { padding: 13px 14px; gap: 10px; }
  .ind-dots { gap: 5px; }
  .dot { width: 13px; height: 13px; }
  .vote button { width: 40px; height: 30px; }
  .as-sections { margin-top: 48px; padding: 0 16px 20px; }
  .as-card { padding: 26px 22px; }
}
@media (prefers-reduced-motion: reduce) {
  .bear-3d { transform: none !important; }
}
