/* Case study pages (Dapplegrove). Uses site tokens; works with the dark theme. */
.cs-meta { margin: 1.4rem 0 2rem; }
.cs-note { font-size: .92rem; color: var(--muted); margin-top: .9rem; }
.cs-steps { list-style: none; counter-reset: cs; margin: 1.2rem 0 2rem; padding: 0; display: grid; gap: .75rem; }
.cs-steps li { counter-increment: cs; position: relative; background: var(--sun, #fff); border: 1px solid var(--line); padding: 1rem 1.15rem 1rem 3.4rem; }
.cs-steps li::before { content: counter(cs); position: absolute; left: 1.05rem; top: 1rem; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--moss); color: #fff; font: 600 .85rem/1.6rem var(--serif); text-align: center; }
.cs-steps strong { display: block; color: var(--forest); font-family: var(--serif); font-weight: 600; margin-bottom: .2rem; }
.cs-steps span { color: var(--muted); font-size: .98rem; }
.cs-fig { margin: 1.4rem 0 1.8rem; }
.cs-fig a { display: block; background: #fff; border: 1px solid var(--line); }
.cs-fig img { width: 100%; height: auto; }
.cs-fig figcaption { font-size: .88rem; color: var(--muted); padding-top: .55rem; }
.cs-figs { display: grid; gap: 1.2rem; }
@media (min-width: 820px) { .cs-figs.two { grid-template-columns: 1fr 1fr; } }
.cs-facts { list-style: none; margin: 1rem 0 1.5rem; padding: 0; display: grid; gap: .5rem; }
.cs-facts li { padding-left: 1.1rem; position: relative; color: var(--muted); font-size: 1rem; }
.cs-facts li::before { content: ""; position: absolute; left: 0; top: .7em; width: .45rem; height: 2px; background: var(--moss); }
.cs-facts b { color: var(--forest); font-weight: 600; }
.cs-tag { display: inline; font: 500 .68rem var(--mono); letter-spacing: .06em; padding: .1rem .4rem; border: 1px solid var(--line); border-radius: 3px; color: var(--accent-text); white-space: nowrap; margin-left: .15rem; background: none; box-shadow: none; }
.cs-tag.unk { color: var(--muted); }
.cs-table-wrap { overflow-x: auto; margin: 1.2rem 0 1.5rem; border: 1px solid var(--line); }
.cs-table { width: 100%; border-collapse: collapse; font-size: .93rem; min-width: 640px; }
.cs-table th, .cs-table td { text-align: left; vertical-align: top; padding: .65rem .8rem; border-bottom: 1px solid var(--line); }
.cs-table th { font: 600 .78rem var(--serif); letter-spacing: .08em; text-transform: uppercase; color: var(--forest); background: rgba(127,127,127,.08); }
.cs-table td { color: var(--muted); }
.cs-table td:first-child { color: var(--forest); font-weight: 600; }
.cs-table tr:last-child td { border-bottom: 0; }
.cs-sources { font-size: .9rem; color: var(--muted); }
.cs-sources li { margin-bottom: .35rem; }

@media (max-width: 640px) {
  .cs-table-wrap { border: 0; overflow: visible; }
  .cs-table { min-width: 0; }
  .cs-table thead { position: absolute; left: -9999px; }
  .cs-table, .cs-table tbody, .cs-table tr, .cs-table td { display: block; width: 100%; }
  .cs-table tr { border: 1px solid var(--line); margin-bottom: .8rem; background: var(--sun, #fff); }
  .cs-table td { border-bottom: 1px solid var(--line); padding: .5rem .8rem; }
  .cs-table td:first-child { background: rgba(127,127,127,.08); }
  .cs-table td[data-label]:not(:first-child)::before { content: attr(data-label); display: block; font: 600 .7rem var(--serif); letter-spacing: .08em; text-transform: uppercase; color: var(--accent-text); margin-bottom: .1rem; }
}

.cs-outcome { font: 500 1.15rem/1.4 var(--serif); color: var(--accent-text); border: 1px dashed var(--line); padding: 1rem 1.2rem; background: rgba(224,112,63,.08); }
