/*
  Generosity Roundtable — Obsidian Publish styles
  Auto-loaded by Obsidian Publish from the vault root (no toggle needed).
  Self-contained: colors and fonts are declared here so the component
  renders correctly even when the grt-theme snippet is not enabled for
  the published site.
*/

@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@600;700;800&family=Inter:wght@400;500;600;700&display=swap');

/* ------------------------------------------------------------------ */
/*  Devotion Scale — the five-stage "devotion ladder"                  */
/* ------------------------------------------------------------------ */

.devotion-scale {
  --ds-cream: #faf7f0;
  --ds-ink: #161616;
  display: flex;
  flex-direction: column;
  margin: 2.2rem 0 2.6rem;
  position: relative;
}

/* Cool-to-warm ramp: attention rising into commitment. */
.devotion-scale .ds-1 { --c: #55c0e7; } /* sky      */
.devotion-scale .ds-2 { --c: #16839f; } /* teal     */
.devotion-scale .ds-3 { --c: #5bba47; } /* green    */
.devotion-scale .ds-4 { --c: #f36c21; } /* orange   */
.devotion-scale .ds-5 { --c: #ef463e; } /* coral    */

.devotion-scale .ds-stage {
  display: grid;
  grid-template-columns: 4.5rem 1fr;
  align-items: stretch;
  position: relative;
}

/* The rail column: vertical spine, node marker, and stage number. */
.devotion-scale .ds-rail {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 1.5rem;
}

.devotion-scale .ds-rail::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: -0.1rem;
  left: 50%;
  width: 4px;
  transform: translateX(-50%);
  background: var(--c);
  opacity: 0.4;
}

.devotion-scale .ds-stage:first-child .ds-rail::before { top: 2.1rem; }
.devotion-scale .ds-stage:last-child  .ds-rail::before { height: 2.1rem; bottom: auto; }

.devotion-scale .ds-node {
  position: relative;
  z-index: 2;
  width: 1.4rem;
  height: 1.4rem;
  border-radius: 50%;
  background: var(--ds-cream);
  border: 4px solid var(--c);
  box-shadow: 0 0 0 5px var(--ds-cream);
}

.devotion-scale .ds-num {
  font-family: 'Baloo 2', system-ui, sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--c);
  margin-top: 0.5rem;
  letter-spacing: 0.04em;
}

/* The card. */
.devotion-scale .ds-card {
  background: #ffffff;
  border: 2px solid var(--ds-ink);
  border-left: 8px solid var(--c);
  border-radius: 14px;
  padding: 1rem 1.25rem;
  margin: 0 0 1rem 0.4rem;
  box-shadow: 4px 4px 0 rgba(22, 22, 22, 0.92);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.devotion-scale .ds-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 6px 6px 0 var(--c);
}

.devotion-scale .ds-name {
  display: block;
  font-family: 'Baloo 2', system-ui, sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  font-size: 1.35rem;
  line-height: 1.05;
  color: var(--ds-ink);
}

.devotion-scale .ds-desc {
  display: block;
  font-family: 'Inter', system-ui, sans-serif;
  font-size: 0.98rem;
  line-height: 1.5;
  color: #333333;
  margin-top: 0.4rem;
}

/* Intensity meter: filled pips equal the stage number. */
.devotion-scale .ds-meter {
  display: flex;
  gap: 0.35rem;
  margin-top: 0.85rem;
}

.devotion-scale .ds-pip {
  width: 2.4rem;
  height: 0.5rem;
  border-radius: 999px;
  background: rgba(22, 22, 22, 0.12);
}

.devotion-scale .ds-1 .ds-pip:nth-child(-n+1),
.devotion-scale .ds-2 .ds-pip:nth-child(-n+2),
.devotion-scale .ds-3 .ds-pip:nth-child(-n+3),
.devotion-scale .ds-4 .ds-pip:nth-child(-n+4),
.devotion-scale .ds-5 .ds-pip:nth-child(-n+5) {
  background: var(--c);
}

/* Narrow screens: tighten the rail and let pips flex. */
@media (max-width: 480px) {
  .devotion-scale .ds-stage { grid-template-columns: 3.2rem 1fr; }
  .devotion-scale .ds-pip { width: auto; flex: 1; }
}
