/* case-study.css — shared styles for all case study pages */

.cs-hero {
  background: var(--bg-dark);
  padding: calc(112px + 64px) 64px 80px;
}
.cs-hero-inner { max-width: 1280px; margin: 0 auto; display: flex; flex-direction: column; gap: 32px; }
.cs-back {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 14px; color: rgba(255,255,255,0.5); text-decoration: none;
  transition: color 0.2s;
}
.cs-back:hover { color: var(--accent); }
.cs-back svg { width: 16px; height: 16px; }
.cs-category {
  font-family: 'Inter', sans-serif; font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--accent);
}
.cs-title {
  font-family: 'Rubik', sans-serif; font-weight: 800;
  font-size: clamp(36px, 5vw, 72px); line-height: 1.1;
  color: #fff; max-width: 900px;
}
.cs-subtitle {
  font-size: 18px; line-height: 1.6;
  color: rgba(255,255,255,0.65); max-width: 720px;
}
.cs-meta {
  display: flex; gap: 8px; flex-wrap: wrap; padding-top: 8px;
}

/* cover image */
.cs-cover {
  background: #111; overflow: hidden;
  aspect-ratio: 16/7;
}
.cs-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cs-cover-placeholder {
  width: 100%; height: 100%;
}

/* content */
.cs-content { background: #fff; padding: 80px 64px; }
.cs-content-inner {
  max-width: 1280px; margin: 0 auto;
  display: grid; grid-template-columns: 260px 1fr; gap: 80px;
}

/* sticky sidebar */
.cs-sidebar { position: sticky; top: 100px; align-self: start; }
.cs-toc-label {
  font-size: 11px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--text-muted); margin-bottom: 16px;
}
.cs-toc { list-style: none; display: flex; flex-direction: column; gap: 2px; }
.cs-toc a {
  display: block; font-size: 14px; color: var(--text-muted);
  text-decoration: none; padding: 6px 0 6px 12px;
  border-left: 2px solid transparent; transition: all 0.2s;
}
.cs-toc a:hover, .cs-toc a.active {
  color: var(--text-black); border-left-color: var(--text-black);
}

/* metrics bar */
.cs-metrics {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 1px; background: rgba(7,2,4,0.1);
  border: 1px solid rgba(7,2,4,0.1);
  border-radius: 8px; overflow: hidden;
  margin-bottom: 64px;
}
.cs-metric {
  background: #fff; padding: 32px 24px;
  display: flex; flex-direction: column; gap: 8px;
}
.cs-metric-number {
  font-family: 'Rubik', sans-serif; font-weight: 800;
  font-size: clamp(32px, 3vw, 48px); line-height: 1;
  color: var(--text-black);
}
.cs-metric-label {
  font-size: 14px; line-height: 1.4; color: var(--text-muted);
}

/* rich text */
.cs-body { display: flex; flex-direction: column; gap: 48px; }
.cs-body h2 {
  font-family: 'Rubik', sans-serif; font-weight: 700;
  font-size: clamp(24px, 2.5vw, 36px); line-height: 1.2;
  color: var(--text-black); padding-top: 16px;
}
.cs-body h3 {
  font-family: 'Rubik', sans-serif; font-weight: 600;
  font-size: 20px; line-height: 1.3; color: var(--text-black);
}
.cs-body p {
  font-size: 17px; line-height: 1.75; color: #333;
}
.cs-body blockquote {
  border-left: 3px solid var(--text-black); padding-left: 24px;
  font-family: 'Rubik', sans-serif; font-size: 20px; line-height: 1.5;
  color: var(--text-black); font-style: italic;
}

/* image block */
.cs-img-block { display: flex; flex-direction: column; gap: 12px; }
.cs-img-block img {
  width: 100%; border-radius: 12px; display: block;
}
.cs-img-block .cs-img-placeholder {
  width: 100%; aspect-ratio: 16/9; border-radius: 12px;
  background: linear-gradient(135deg, #f0f0f0, #e0e0e0);
  display: flex; align-items: center; justify-content: center;
}
.cs-img-block .cs-img-placeholder span {
  font-size: 13px; color: #aaa; font-family: 'Inter', sans-serif;
}
.cs-caption {
  display: flex; gap: 10px; align-items: flex-start;
}
.cs-caption::before {
  content: ''; flex-shrink: 0;
  width: 2px; height: 18px; background: var(--text-black);
  margin-top: 2px;
}
.cs-caption p { font-size: 13px; color: var(--text-muted); line-height: 1.5; }

/* two-col grid for details */
.cs-two-col {
  display: grid; grid-template-columns: 1fr 1fr; gap: 32px;
}
.cs-detail-box {
  border: 1px solid rgba(7,2,4,0.12); border-radius: 8px;
  padding: 28px; display: flex; flex-direction: column; gap: 12px;
}
.cs-detail-box h4 {
  font-family: 'Rubik', sans-serif; font-weight: 700;
  font-size: 16px; color: var(--text-black);
}
.cs-detail-box p { font-size: 15px; line-height: 1.6; color: #555; }

/* table */
.cs-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.cs-table th {
  font-family: 'Rubik', sans-serif; font-weight: 600;
  font-size: 13px; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-muted); text-align: left;
  padding: 12px 16px; border-bottom: 2px solid rgba(7,2,4,0.1);
}
.cs-table td {
  padding: 16px; color: #333; line-height: 1.5;
  border-bottom: 1px solid rgba(7,2,4,0.06);
  vertical-align: top;
}
.cs-table tr:last-child td { border-bottom: none; }

/* next project */
.cs-next {
  background: var(--bg-dark); padding: 80px 64px;
}
.cs-next-inner {
  max-width: 1280px; margin: 0 auto;
  display: flex; justify-content: space-between; align-items: flex-end;
}
.cs-next-label {
  font-size: 12px; font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.1em; color: rgba(255,255,255,0.4); margin-bottom: 12px;
}
.cs-next-title {
  font-family: 'Rubik', sans-serif; font-weight: 800;
  font-size: clamp(28px, 4vw, 56px); color: #fff;
  text-decoration: none; display: block; transition: color 0.2s;
}
.cs-next-title:hover { color: var(--accent); }

/* mobile */
@media (max-width: 900px) {
  .cs-hero { padding: calc(64px + 56px) 20px 48px; }
  .cs-content { padding: 48px 20px; }
  .cs-content-inner { grid-template-columns: 1fr; }
  .cs-sidebar { position: static; }
  .cs-metrics { grid-template-columns: 1fr; }
  .cs-two-col { grid-template-columns: 1fr; }
  .cs-next { padding: 64px 20px; }
  .cs-next-inner { flex-direction: column; gap: 16px; align-items: flex-start; }
  .cs-title { font-size: 32px; }
  .cs-subtitle { font-size: 16px; }
}
