/* ==========================================================================
   PAGES/SHOWCASE-ARTICLE.CSS — Individual Case Study Template (_beta)
   - Aligned with landing & showcase hub (Light/Dark floating sheets on #454545 / #333333 canvas)
   - Big typographic poster header
   - Technical spec cartouche & exterior crop marks inspired by test_layout.html
   - Vertical stream of all project plates (images, MP4 videos, YouTube embeds)
   - Shared bricks (.sc-light-sheet, .sc-wrap, tokens) live in 00-tokens.css & 03-components.css
   ========================================================================== */

#showcase-article-main.sc-article-canvas {
  background-color: var(--sc-canvas) !important;
  margin-top: 0 !important;
  padding: var(--sc-section-gap) var(--sc-outer-margin) calc(var(--sc-section-gap) * 1.6) !important;
  display: flex;
  flex-direction: column;
  gap: var(--sc-section-gap);
  min-height: 85vh;
  overflow: visible !important;
  transition: background-color 0.3s ease;
}

/* ==========================================================================
   1. PROJECT TOP NAVIGATION BAR (Back to Showcase + Prev / Next)
   ========================================================================== */
.sc-case-topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: var(--sc-quicknav-bg) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 0 !important;
}

.sc-case-topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  flex-wrap: wrap;
}

.sc-back-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--sc-btn-border);
  background: var(--sc-pill-bg);
  color: var(--sc-ink) !important;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none !important;
  transition: all 0.2s ease;
}

.sc-back-pill:hover {
  border-color: var(--sc-accent);
  background: var(--sc-accent);
  color: #ffffff !important;
  transform: translateY(-1px);
}

.sc-case-adj-nav {
  display: flex;
  align-items: center;
  gap: 10px;
}

.sc-adj-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px;
  border-radius: 999px;
  border: 1px solid var(--sc-pill-border);
  background: var(--sc-pill-bg);
  color: var(--sc-ink) !important;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none !important;
  transition: all 0.2s ease;
  max-width: 280px;
}

.sc-adj-link:hover {
  border-color: var(--sc-accent);
  color: var(--sc-accent) !important;
  transform: translateY(-1px);
}

.sc-adj-label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sc-adj-label b {
  color: var(--sc-accent);
  font-weight: 800;
  margin-right: 4px;
}

.sc-adj-arrow {
  font-weight: 800;
  color: var(--sc-accent);
  flex-shrink: 0;
}

/* ==========================================================================
   2. MAIN POSTER SHEET: HEADER + CARTOUCHE + VERTICAL MEDIA LIST
   ========================================================================== */
.sc-poster-sheet {
  padding: clamp(32px, 4.5vw, 60px) 0 clamp(44px, 5.5vw, 76px);
}

.poster-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  width: 100%;
  height: auto !important;
  position: relative !important;
  background: transparent !important;
  padding: 0 0 clamp(24px, 3vw, 36px) 0 !important;
  border-bottom: 1px solid var(--sc-line);
  margin: 0 0 clamp(36px, 4vw, 52px) 0 !important;
}

.header-left {
  display: flex;
  flex-direction: column;
  max-width: 900px;
}

.use-case-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--sc-accent);
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin: 0 0 14px 0 !important;
  line-height: 1;
}

.use-case-tag::before {
  content: "";
  width: 24px;
  height: 2px;
  background: var(--sc-accent);
  display: inline-block;
}

.poster-header h1.main-title,
.main-title {
  font-family: 'Inter', sans-serif !important;
  font-size: clamp(2.4rem, 5.8vw, 5rem) !important;
  font-weight: 900 !important;
  letter-spacing: -0.04em !important;
  line-height: 0.94 !important;
  color: var(--sc-ink) !important;
  text-transform: uppercase !important;
  margin: 0 0 14px 0 !important;
  padding: 0 !important;
}

.poster-header h2.sub-title,
.sub-title {
  font-family: 'Inter', sans-serif !important;
  font-size: clamp(1.05rem, 2vw, 1.65rem) !important;
  font-weight: 700 !important;
  letter-spacing: -0.015em !important;
  line-height: 1.15 !important;
  color: var(--sc-muted) !important;
  text-transform: uppercase !important;
  margin: 0 !important;
  padding: 0 !important;
}

.sub-title span {
  color: var(--sc-ink);
}

.header-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  text-align: right;
  flex-shrink: 0;
  font-family: 'JetBrains Mono', monospace;
}

.poster-spec-stamp {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 6px 12px;
  border: 1px solid var(--cartouche-border);
  background: var(--cartouche-bg);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--sc-ink);
}

.cmyk-patches {
  display: inline-flex;
  gap: 2px;
}

.cmyk-patch {
  width: 6.5px;
  height: 6.5px;
  border: 0.5px solid rgba(0, 0, 0, 0.25);
}

.cmyk-c { background: #009ee0; }
.cmyk-m { background: #e5007d; }
.cmyk-y { background: #fff100; }
.cmyk-k { background: #000000; }

.poster-year-big {
  font-family: 'Inter', sans-serif;
  font-size: clamp(1.6rem, 2.8vw, 2.5rem);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 1;
  color: var(--sc-ink);
  opacity: 0.85;
}

/* ==========================================================================
   3. POSTER BODY GRID: CARTOUCHE LEFT | MEDIA LIST RIGHT
   ========================================================================== */
.poster-grid-layout {
  display: grid;
  grid-template-columns: var(--cartouche-width) 1fr;
  gap: var(--layout-gap);
  align-items: start;
  position: relative;
  width: 100%;
}

.block-cartouche-col {
  position: sticky;
  top: 76px;
  z-index: 15;
}

.block-cartouche {
  width: 100%;
  background: var(--cartouche-bg);
  border: 1px solid var(--cartouche-border);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
  position: relative;
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.cartouche-header-band {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  background: var(--sc-ink);
  color: var(--sc-sheet-bg);
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.cartouche-row {
  padding: 12px 15px 13px;
  border-bottom: 1px solid var(--cartouche-divider);
  flex: 0 0 auto;
}

.cartouche-row:last-child {
  border-bottom: none;
}

.cartouche-row-title {
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sc-ink);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.cartouche-row-title small {
  font-family: 'JetBrains Mono', monospace;
  font-size: 9.5px;
  color: var(--sc-muted);
  font-weight: 600;
}

.cartouche-row-body {
  font-size: 12px;
  line-height: 1.5;
  color: var(--sc-muted);
  font-weight: 500;
}

.cartouche-row-body p {
  margin: 0 0 3px 0;
}

.cartouche-row-body p:last-child {
  margin-bottom: 0;
}

.cartouche-row-body strong {
  color: var(--sc-ink);
  font-weight: 700;
}

.cartouche-desc-text {
  white-space: pre-line;
  line-height: 1.55;
  font-size: 12.5px;
  color: var(--sc-ink);
  opacity: 0.9;
}

.cartouche-ext-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--sc-accent) !important;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  text-decoration: none !important;
  word-break: break-all;
}

.cartouche-ext-link:hover {
  text-decoration: underline !important;
}

.cartouche-gauges {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 4px;
}

.cartouche-gauge-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.cartouche-gauge-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  font-size: 11px;
  font-weight: 600;
  color: var(--sc-ink);
}

.cartouche-gauge-val {
  font-family: 'JetBrains Mono', monospace;
  font-size: 10px;
  font-weight: 700;
  color: var(--sc-muted);
}

.cartouche-gauge-bar {
  width: 100%;
  height: 6px;
  background: var(--gauge-track);
  overflow: hidden;
  position: relative;
}

.cartouche-gauge-fill {
  height: 100%;
  background: var(--sc-accent);
  width: 0;
  transition: width 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.cartouche-gauge-bar.is-zero .cartouche-gauge-fill {
  background: var(--cartouche-border);
}

.cartouche-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 4px;
}

.cartouche-tag-pill {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--sc-btn-border);
  background: var(--sc-pill-bg);
  color: var(--sc-ink) !important;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  text-decoration: none !important;
  transition: all 0.2s ease;
}

.cartouche-tag-pill:hover {
  background: var(--sc-accent);
  border-color: var(--sc-accent);
  color: #ffffff !important;
}

/* ==========================================================================
   4. RIGHT COLUMN: VERTICAL STREAM OF ALL MEDIA PLATES WITH CROP MARKS
   ========================================================================== */
.poster-media-list {
  display: flex;
  flex-direction: column;
  gap: 54px;
  width: 100%;
  min-width: 0;
}

.block-image-item {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  z-index: 10;
}

.block-image-frame {
  position: relative;
  width: 100%;
  height: auto;
  background: var(--sc-media-bg);
  transition: border-image-outset 0.25s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease, box-shadow 0.25s ease;
  overflow: visible;
  line-height: 0;
}

.block-image-frame:hover {
  border-color: var(--sc-accent);
}

.crop-meta-info {
position: absolute;
    bottom: calc(100% + 5px);
    left: 8px;
    right: 2px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 9.5px;
    letter-spacing: 0.06em;
    color: var(--crop-meta-ink);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    pointer-events: none;
    z-index: 1;
    white-space: nowrap;
    line-height: 1;
}

.crop-meta-left {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.crop-meta-left b {
  color: var(--sc-ink);
  font-weight: 700;
}

.image-clip-wrapper {
  width: 100%;
  height: auto;
  overflow: hidden;
  position: relative;
  display: block;
  line-height: 0;
  background: var(--sc-media-bg);
}

.image-clip-wrapper .visual-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: contain;
  cursor: zoom-in;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

.image-clip-wrapper.is-video-embed {
  aspect-ratio: 16 / 9;
  background: #000000;
}

.image-clip-wrapper.is-video-embed video,
.image-clip-wrapper.is-video-embed iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  object-fit: contain;
  background: #000000;
}

.plate-zoom-btn {
  position: absolute;
  bottom: 14px;
  right: 14px;
  z-index: 15;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(11, 12, 12, 0.72);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  opacity: 0;
  transform: scale(0.92);
  transition: opacity 0.2s ease, transform 0.2s ease, background-color 0.2s ease;
  padding: 0;
}

.block-image-frame:hover .plate-zoom-btn {
  opacity: 1;
  transform: scale(1);
}

.plate-zoom-btn:hover {
  background: var(--sc-accent);
  border-color: var(--sc-accent);
}

.plate-zoom-btn svg {
  width: 16px;
  height: 16px;
}

.plate-caption-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 10px;
    padding: 0px 7px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 11px;
    color: var(--sc-muted);
    line-height: 0;
    font-size: 10px;
}

/* ==========================================================================
   5. RELATED PROJECTS SECTION (.sc-related-sheet)
   ========================================================================== */
.sc-related-sheet {
  padding: clamp(32px, 4vw, 52px) 0;
}

.sc-related-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 26px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--sc-line);
  flex-wrap: wrap;
}

h2.sc-related-title,
.sc-related-title {
  font-size: clamp(1.5rem, 2.8vw, 2.4rem) !important;
  font-weight: 900 !important;
  letter-spacing: -0.03em !important;
  text-transform: uppercase !important;
  margin: 4px 0 0 0 !important;
  color: var(--sc-ink) !important;
}

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

.sc-related-card {
  display: flex;
  flex-direction: column;
  background: var(--sc-panel);
  border: 1px solid var(--sc-line);
  border-radius: 0 !important;
  overflow: hidden;
  text-decoration: none !important;
  color: var(--sc-ink) !important;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.25s ease, box-shadow 0.3s ease;
}

.sc-related-card:hover {
  transform: translateY(-4px);
  border-color: var(--sc-accent);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.14);
}

.sc-related-media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: var(--sc-media-bg);
  overflow: hidden;
}

.sc-related-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
}

.sc-related-card:hover .sc-related-media img {
  transform: scale(1.05);
}

.sc-related-body {
  padding: 14px 16px 16px;
}

.sc-related-client {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sc-accent);
  margin-bottom: 4px;
}

.sc-related-name {
  font-size: 15px;
  font-weight: 700;
  margin: 0;
  color: var(--sc-ink);
}

/* ==========================================================================
   6. FULLSCREEN LIGHTBOX (High-Res Plate Inspection)
   ========================================================================== */
#lightboxOverlay {
  display: none;
  position: fixed;
  z-index: 9999;
  inset: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(8, 9, 9, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  align-items: center;
  justify-content: center;
  user-select: none;
}

#lightboxTitle {
  position: absolute;
  top: 20px;
  left: 24px;
  z-index: 10002;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(17, 18, 18, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #f4f3ee;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  pointer-events: none;
}

#lightboxClose {
  position: absolute;
  top: 18px;
  right: 24px;
  z-index: 10002;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(17, 18, 18, 0.78);
  color: #ffffff;
  font-size: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
  line-height: 1;
}

#lightboxClose:hover {
  background: var(--sc-accent);
  border-color: var(--sc-accent);
  transform: scale(1.06);
}

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10001;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(17, 18, 18, 0.75);
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  padding: 0;
}

.lightbox-arrow:hover {
  background: var(--sc-accent);
  border-color: var(--sc-accent);
  transform: translateY(-50%) scale(1.08);
}

.lightbox-arrow svg {
  width: 22px;
  height: 22px;
}

.lightbox-prev { left: 24px; }
.lightbox-next { right: 24px; }

/* ==========================================================================
   7. RESPONSIVE DESIGN (Tablet & Mobile)
   ========================================================================== */
@media (max-width: 1024px) {
  .poster-grid-layout {
    grid-template-columns: 1fr;
    gap: 44px;
  }

  .block-cartouche-col {
    position: static;
    order: 1;
  }

  .poster-media-list {
    order: 2;
  }
}

@media (max-width: 767px) {
  .poster-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header-right {
    align-items: flex-start;
    text-align: left;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 12px;
  }

  .sc-related-grid {
    grid-template-columns: 1fr;
  }

  .sc-adj-label {
    display: none;
  }

  .crop-meta-info {
    font-size: 8px;
  }
}
