/* ===================================================
   CASES.CSS — Shared styles for all customer stories
   /our-work/*.html
   Requires: shared.css loaded first
   =================================================== */

/* ── Page body ── */
body {
  background: #fff;
}

/* ── Progress bar ── */
.progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 5px;
  width: 100%;
  background: linear-gradient(90deg, var(--teal), var(--orange));
  transform-origin: left center;
  transform: scaleX(0);
  z-index: 9999;
  box-shadow: 0 2px 8px rgba(55, 180, 167, 0.3);
}

/* ── Page layout ── */
.article-page {
  padding: 160px 0 96px;
}

.article-shell {
  width: min(calc(100% - 64px), 1240px);
  margin: 0 auto;
}

/* ── Hero ── */
.article-hero {
  padding-bottom: 36px;
  border-bottom: 1px solid var(--line);
}

.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .14em;
  padding: 8px 16px;
  border: 1px solid #b9ddd9;
  border-radius: 999px;
  color: var(--teal-dark);
  background: rgba(255, 255, 255, .8);
  margin-bottom: 28px;
}

.back-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 999px;
  border: 1px solid var(--teal);
  color: var(--teal);
  transition: all 0.2s ease;
  text-decoration: none;
  background: transparent;
  font-weight: 500;
  font-family: 'JetBrains Mono', monospace;
  text-transform: uppercase;
  letter-spacing: .08em;
  line-height: 1;
  cursor: pointer;
  font-size: 14px;
}

.back-link:hover {
  background: var(--teal);
  color: #fff;
  border-color: var(--teal);
  transform: translateX(-2px);
}

.back-link:hover {
  background: var(--teal);
  color: #fff;
  border-color: var(--teal);
  transform: translateX(-2px);
}

.article-title {
  font-size: clamp(30px, 3.4vw, 36px);
  line-height: 1.15;
  letter-spacing: -.04em;
  max-width: 860px;
  margin-bottom: 22px;
}

/* Partner logo — wrap title + logo: <div class="hero-title-row"><h1>...</h1><div class="hero-partner-logo">...</div></div> */
.hero-title-row {
  display: flex;
  align-items: flex-start;
  gap: 120px;
  margin-bottom: 22px;
}

.hero-title-row .article-title {
  flex: 1;
  margin-bottom: 0;
}

.hero-partner-logo {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding-top: 6px;
}

.hero-partner-logo span {
  font-size: 10px;
  font-family: 'JetBrains Mono', monospace;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-3, #888);
  white-space: nowrap;
}

.hero-partner-logo img {
  height: 48px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
  border-radius: 8px;
}

.partner-logos-row {
  display: flex;
  align-items: center;
  gap: 24px;
}

.partner-logos-row img {
  height: 48px;
  width: auto;
  max-width: 140px;
  object-fit: contain;
}

.partner-logos-row img:not(:last-child) {
  border-right: 1px solid var(--line);
  padding-right: 24px;
}

.accent-t {
  color: var(--teal);
}

.accent-o {
  color: var(--orange);
}

.hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
  margin-bottom: 24px;
}

.meta-date {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-2);
  background: var(--teal-bg);
  border: 1px solid var(--teal-soft);
  padding: 7px 14px;
  border-radius: 999px;
}

.meta-date svg {
  width: 13px;
  height: 13px;
  stroke: var(--teal);
  flex-shrink: 0;
}

.meta-sep {
  color: var(--ink-3);
  font-size: 20px;
  line-height: 1;
  font-weight: 300;
}

.meta-share {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.meta-share-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--ink-3);
  margin-right: 2px;
}

.share-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-2);
  transition: .2s;
  cursor: pointer;
  text-decoration: none;
}

.share-pill:hover {
  border-color: var(--teal);
  color: var(--teal);
  background: var(--teal-bg);
}

.share-pill svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}

.hero-banner {
  aspect-ratio: 1000/340;
  border-radius: 24px;
  overflow: hidden;
  background: #e8f0ef;
  box-shadow: 0 20px 56px -32px rgba(26, 31, 46, .22);
  margin-top: 28px;
}

.hero-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-summary-block {
  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 28px;
  align-items: start;
  margin-top: 28px;
  padding: 28px 32px;
  background: #f9f9f7;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.hero-summary-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--orange);
  padding-top: 4px;
}

.hero-summary-text {
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-2);
}

/* ── Article layout ── */
.article-layout {
  display: block;
}

/* ── Rail + TOC ── */
.article-rail {
  position: sticky;
  top: 140px;
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
  max-height: calc(100vh - 160px);
  overflow: visible;
}

.rail-content {
  width: 100%;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.rail-meter {
  width: 2px;
  background: #e2e5e8;
  height: 100%;
  min-height: 320px;
  border-radius: 999px;
  position: relative;
  margin-left: 8px;
  grid-row: 1;
}

.rail-meter-fill {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 0%;
  background: linear-gradient(180deg, var(--teal), var(--orange));
  border-radius: 999px;
  transition: height .08s linear;
}

.toc {
  padding-top: 2px;
}

.toc-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .14em;
  color: var(--teal-dark);
  margin-bottom: 16px;
}

.toc ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.toc a {
  color: var(--ink-3);
  font-size: 13px;
  line-height: 1.35;
  display: block;
  transition: .2s;
}

.toc a:hover {
  color: var(--ink);
}

.toc a.active {
  color: var(--orange);
  font-weight: 600;
}

.toc .toc-h3 {
  padding-left: 14px;
  font-size: 12px;
}

/* ── Entry content ── */
.article-main {
  min-width: 0;
}

.entry-content {
  margin: 0 auto;
}

.entry-content>*+* {
  margin-top: 20px;
}

/* Strip CMS-injected borders/shadows from <section> wrappers */
.entry-content section {
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  background: transparent !important;
  padding: 0 !important;
}

/* Readable spacing between content blocks and paragraphs */
.entry-content section+section {
  margin-top: 24px;
}

.entry-content p+p {
  margin-top: 18px;
}

/* Headings */
.entry-content h2 {
  font-size: clamp(20px, 2vw, 28px);
  line-height: 1.2;
  letter-spacing: -.025em;
  color: var(--teal);
  margin-top: 52px;
  scroll-margin-top: 150px;
}

.entry-content h3 {
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.25;
  letter-spacing: -.02em;
  color: var(--teal);
  margin-top: 36px;
  scroll-margin-top: 150px;
}

/* h4 = Challenge / Process / Solution / Results labels */
.entry-content h4 {
  font-size: 20px;
  font-family: 'Poppins', sans-serif;
  font-weight: 800;
  color: var(--orange);
  margin-top: 48px;
  margin-bottom: 8px;
  scroll-margin-top: 150px;
}

.entry-content h5 {
  font-size: 15px;
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  color: var(--teal);
  margin-top: 24px;
  margin-bottom: 6px;
}

.entry-content p {
  font-size: 16px;
  color: var(--ink-2);
  line-height: 1.8;
}

.entry-content p strong,
.entry-content p b {
  color: var(--ink);
}

.entry-content ul,
.entry-content ol {
  padding-left: 24px;
  color: var(--ink-2);
  font-size: 16px;
  line-height: 1.8;
}

.entry-content li+li {
  margin-top: 9px;
}

/* Links inside content */
.entry-content a {
  position: relative;
  text-decoration: none;
  font-weight: inherit;
  color: var(--teal);
  transition: all .2s ease-out;
}

.entry-content a:hover {
  color: var(--orange);
}

.entry-content a::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 1px;
  background-color: var(--teal);
  transition: all .2s ease-out;
}

.entry-content a:hover::after {
  height: 3px;
  background-color: var(--orange);
}

/* Utility link colours */
.link-teal {
  color: var(--teal);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.link-orange {
  color: var(--orange);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ── Callout boxes ── */
.callout {
  padding: 20px 22px;
  border-radius: 14px;
  border: 1px solid rgba(255, 141, 78, .2);
  background: rgba(255, 141, 78, .05);
}

.callout.teal-line {
  border-color: rgba(55, 180, 167, .2);
  background: rgba(55, 180, 167, .06);
}

.callout-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 8px;
}

.callout.teal-line .callout-label {
  color: var(--teal-dark);
}

.callout p {
  margin-top: 0 !important;
  font-size: 16px;
}

/* ── Wide media (full-width showcase images) ── */
.wide-media {
  margin-top: 28px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 14px 36px -24px rgba(26, 31, 46, .18);
}

.wide-media img,
.wide-media video {
  width: 100%;
  height: auto;
  display: block;
}

/* ── Content images & videos ── */
.entry-content img,
.entry-content video,
.entry-content figure {
  border-radius: 16px !important;
  overflow: hidden;
  display: block;
  margin: 28px auto;
}

.entry-content img,
.entry-content video {
  max-width: 580px;
  height: auto;
  max-height: 420px;
  object-fit: contain;
}

/* ── Two-column layout ── */
.two-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: center;
  margin-top: 24px;
}

.two-columns img,
.two-columns video {
  max-width: 100%;
  max-height: 380px;
  margin: 0;
  object-fit: contain;
  border-radius: 16px !important;
}

.two-columns figure {
  margin: 0;
  border-radius: 16px !important;
  overflow: hidden;
}

.stack-columns {
  display: flex;
  flex-direction: column;
  gap: 32px;
  margin-top: 24px;
}

/* ── Tags ── */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0 0 40px 0;
}

.tags li a {
  display: inline-block;
  padding: 10px 15px;
  border: 1px solid var(--teal-soft);
  border-radius: 100px;
  font-size: 10px;
  font-weight: 500;
  color: var(--teal-dark);
  background: rgba(55, 180, 167, .12);
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: .02em;
  text-transform: uppercase;
  text-decoration: none;
  transition: all 0.2s ease;
}

.tags li a:hover {
  background: var(--teal);
  color: #fff;
}

.tags li a::after {
  display: none;
}

/* ── Case intro ── */
.case-intro {
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-2);
  margin-bottom: 32px;
}

/* ── Blockquotes ── */
.entry-content blockquote {
  position: relative;
  margin: 60px auto;
  width: 100%;
  max-width: 574px;
  padding: 34px;
  border: 2px solid var(--teal);
  border-radius: 20px;
  font-style: normal;
  background: transparent;
}

.entry-content blockquote::before {
  content: "\201C";
  position: relative;
  display: inline-block;
  margin-right: 6px;
  font-family: "Stack Sans Text", sans-serif;
  font-size: 100px;
  color: rgba(255, 141, 78, .25);
  line-height: 1;
  pointer-events: none;
  margin-right: 0;
}

.entry-content blockquote p {
  font-size: 14px;
  line-height: 1.71;
  color: var(--ink-2);
  text-wrap: pretty;
  margin: 0;
}

/* ── Profile quote (testimonials) ── */
.profile-quote {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 10px;
  border-left: 2px solid var(--orange);
  padding: 5px 30px;
  text-wrap: pretty;
  margin: 30px 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
}

.profile-quote.narrow {
  max-width: 550px;
}

.profile-quote .profile {
  display: flex;
  flex-direction: row;
  justify-content: flex-start;
  align-items: center;
  gap: 10px;
  border-top: none;
  padding-top: 0;
  margin-bottom: 0;
}

.profile-quote .profile .name {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  gap: 0;
  line-height: 1.4;
  font-weight: bold;
  padding-top: 2px;
}

.profile-quote .profile .name>span {
  color: var(--orange);
  font-size: 16px;
}

.profile-quote .profile .name .role {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .07em;
  color: var(--ink-2);
  text-transform: uppercase;
}

.profile-quote .profile .picture {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
}

.profile-quote .picture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  margin: 0;
}

.profile-quote .quote {
  font-weight: 400;
  font-size: 14px;
  color: var(--ink-2);
  line-height: 1.72;
  font-style: normal;
  margin-bottom: 0;
}

/* ── Cases grid (related cases cards) ── */
.cases-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  margin-top: 32px;
  margin-bottom: 64px;
}

.case-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  overflow: hidden;
  transition: .35s cubic-bezier(.2, .8, .2, 1);
  display: flex;
  flex-direction: column;
  position: relative;
  height: 100%;
  min-height: 380px;
}

.case-card:hover {
  border-color: var(--teal-soft);
  transform: translateY(-4px);
  box-shadow: 0 20px 40px rgba(26, 31, 46, .08);
}

.case-card .cover {
  width: 100%;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--paper);
}

.case-card .cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s;
}

.case-card:hover .cover img {
  transform: scale(1.05);
}

.case-card .card-body {
  padding: 22px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.case-card h4 {
  font-size: 17px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -.01em;
  margin-bottom: 10px;
  color: var(--ink);
  font-family: 'Poppins', sans-serif;
}

.case-card h4 .orange {
  color: var(--orange);
}

.case-card .summary {
  font-size: 13px;
  color: var(--ink-2);
  line-height: 1.55;
  flex: 1;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 10px;
  font-family: 'Poppins', sans-serif;
}

.case-card .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  list-style: none;
  margin-top: auto;
  padding: 0;
}

.case-card .tags li {
  list-style: none;
  padding: 0;
  margin: 0;
}

.case-card .tags li a {
  display: inline-block;
  font-size: 10px;
  font-weight: 500;
  padding: 6px 12px;
  border-radius: 100px;
  background: rgba(55, 180, 167, .12);
  color: var(--teal-dark);
  font-family: 'JetBrains Mono', monospace;
  letter-spacing: .02em;
  text-transform: uppercase;
  border: 1px solid var(--teal-soft) !important;
  text-decoration: none;
  transition: all 0.2s ease;
}

.case-card .tags li a:hover {
  background: var(--teal);
  color: #fff;
}

.case-card .tags li.more {
  font-size: 10px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 100px;
  background: var(--orange-soft);
  color: var(--orange-dark);
  font-family: 'JetBrains Mono', monospace;
  text-transform: uppercase;
}

.case-card>a {
  position: absolute;
  inset: 0;
  z-index: 2;
}

/* ── Share end ── */
.share-end {
  margin-top: 56px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  align-items: center;
}

.share-end-label {
  font-family: 'JetBrains Mono', monospace;
  text-transform: uppercase;
  letter-spacing: .1em;
  font-size: 10px;
  color: var(--ink-3);
  margin-right: 2px;
}

/* ── Recommended section ── */
.recommended {
  padding-top: 72px;
  border-top: 1px solid var(--line);
  margin-top: 80px;
}

.recommended-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 32px;
}

.recommended-title {
  font-size: clamp(22px, 2.4vw, 30px);
  letter-spacing: -.03em;
  line-height: 1.1;
}

.recommended-all {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--teal);
  font-weight: 600;
  white-space: nowrap;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: .2s;
  text-decoration: none;
}

.recommended-all:hover {
  color: var(--orange);
}

.rec-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

/* ── Blog cards (in recommended) ── */
.blog-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: rgba(255, 255, 255, .7);
  border: 1px solid rgba(26, 31, 46, .1);
  border-radius: 16px;
  overflow: hidden;
  transition: box-shadow .3s, border-color .3s;
  text-decoration: none;
}

.blog-card:hover {
  box-shadow: 0 14px 40px -12px rgba(26, 31, 46, .14);
  border-color: rgba(55, 180, 167, .3);
}

.blog-card>a.card-link {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.card-cover {
  position: relative;
  background: linear-gradient(135deg, #edf7f5, #fdf5ef);
  overflow: hidden;
  aspect-ratio: 16/9;
}

.card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .4s ease;
}

.blog-card:hover .card-cover img {
  transform: scale(1.04);
}

.card-tags {
  position: absolute;
  bottom: 10px;
  left: 10px;
  display: flex;
  gap: 6px;
  z-index: 2;
}

.card-tag {
  display: inline-flex;
  align-items: center;
  height: 20px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--orange);
  font-family: 'JetBrains Mono', monospace;
  font-size: 9px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--ink);
}

.card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 10px;
  padding: 18px 18px 16px;
}

.blog-card h4 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.38;
  letter-spacing: -.018em;
  color: var(--ink);
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-top: 1px solid rgba(26, 31, 46, .07);
  padding-top: 10px;
  margin-top: auto;
  gap: 8px;
}

.card-author {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.card-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--teal);
  color: #fff;
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card-author-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.card-author-name {
  font-size: 11px;
  font-weight: 600;
  color: var(--ink);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.card-date {
  font-size: 10px;
  color: var(--ink-3);
  white-space: nowrap;
}

.card-readtime {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 10px;
  color: var(--ink-3);
  white-space: nowrap;
  flex-shrink: 0;
}

.card-readtime svg {
  width: 11px;
  height: 11px;
}

/* ── Responsive ── */
@media (max-width: 1100px) {
  .article-layout {
    grid-template-columns: 1fr;
  }

  .article-rail {
    position: relative;
    top: auto;
    grid-template-columns: 1fr;
  }

  .rail-meter {
    display: none;
  }

  .toc ul {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 18px;
  }
}

@media (max-width: 860px) {
  .article-shell {
    width: min(calc(100% - 40px), 1240px);
  }

  .article-title {
    font-size: clamp(26px, 8vw, 40px);
  }

  .toc ul {
    grid-template-columns: 1fr;
  }

  .entry-content p,
  .entry-content ul,
  .entry-content ol {
    font-size: 16px;
  }

  .rec-grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
  }
}

@media (max-width: 768px) {
  .hero-title-row {
    flex-direction: column;
    gap: 32px;
    align-items: flex-start;
  }

  .hero-partner-logo {
    align-items: flex-start;
  }

  .partner-logos-row {
    flex-wrap: wrap;
    gap: 16px;
  }

  .partner-logos-row img:not(:last-child) {
    border-right: none;
    padding-right: 0;
  }

  .two-columns {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .article-page {
    padding-top: 130px;
  }

  .rec-grid {
    grid-template-columns: 1fr;
  }

  .recommended-header {
    flex-direction: column;
    gap: 8px;
  }

  .hero-summary-block {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}