/* ===================================================================
   MAXIM KUSTOV — RESUME & PORTFOLIO
   MD3 Components • Elevation • Tonal Surfaces • Precision Geometry
   =================================================================== */

/* -------------------------------------------------------------------
   1. HEADER (Clean MD3 Top App Bar)
   ------------------------------------------------------------------- */
body {
  padding-top: 72px;
}

.section {
  scroll-margin-top: 80px;
}

.header-md3 {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(254, 247, 255, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--md-sys-color-outline-variant);
  transition: transform 0.35s cubic-bezier(0.2, 0, 0, 1),
              box-shadow var(--md-sys-motion-duration-short) ease,
              background-color var(--md-sys-motion-duration-short) ease;
}

.header-md3.scrolled {
  background: rgba(254, 247, 255, 0.96);
  box-shadow: var(--md-sys-elevation-2);
}

.header-md3.header--hidden {
  transform: translateY(-100%);
}

.header-md3__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.header-md3__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.header-md3__name {
  font-family: var(--md-sys-font-brand);
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface);
}

.header-md3__actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.header-signal-logo img,
.header-signal-logo svg {
  height: 32px;
  width: auto;
  max-height: 32px;
  display: block;
}

/* -------------------------------------------------------------------
   2. HERO (Elevated Presentation Screen)
   ------------------------------------------------------------------- */
.hero-md3 {
  padding: 64px 0 48px;
}

.hero-md3__grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 900px) {
  .hero-md3__grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
}

.hero-md3__content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.hero-md3__title {
  font-family: var(--md-sys-font-brand);
  font-size: clamp(2.8rem, 6vw, 4.4rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface);
}

.hero-md3__title span {
  color: var(--md-sys-color-primary);
  display: block;
}

.hero-md3__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

.hero-md3__photo-card {
  position: relative;
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-2);
  overflow: hidden;
  max-width: 480px;
  margin: 0 auto;
}

.hero-md3__photo-card img {
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  object-position: center 18%;
  display: block;
}

/* -------------------------------------------------------------------
   3. ABOUT & STATS CARD (MD3 Elevated Container)
   ------------------------------------------------------------------- */
.about-card {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-1);
  padding: 40px;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 860px) {
  .about-card {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 24px;
  }
}

.about-text {
  font-size: 1.12rem;
  line-height: 1.7;
  color: var(--md-sys-color-on-surface);
  margin-top: 16px;
  margin-bottom: 24px;
}

.stats-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

@media (max-width: 480px) {
  .stats-grid-2 {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.stat-box {
  background: var(--md-sys-color-surface-container);
  border-radius: var(--md-sys-shape-corner-large);
  padding: 24px;
  border: 1px solid var(--md-sys-color-outline-variant);
  display: flex;
  flex-direction: column;
  gap: 8px;
  box-shadow: var(--md-sys-elevation-1);
  transition: transform var(--md-sys-motion-duration-short) ease;
}

.stat-box:hover {
  transform: translateY(-2px);
}

.stat-box__val {
  font-family: var(--md-sys-font-brand);
  font-size: 2.8rem;
  font-weight: 800;
  line-height: 1;
  color: var(--md-sys-color-primary);
}

.stat-box__label {
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--md-sys-color-on-surface-variant);
}

/* -------------------------------------------------------------------
   4. CITATIONS SECTION («Цитируемость» — Fixed Non-jumping Height)
   ------------------------------------------------------------------- */
.citations-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .citations-layout {
    grid-template-columns: 1fr;
  }
}

/* Static The Insider Main Card */
.insider-main-card {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-2);
  padding: 24px;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

.insider-main-card__badge-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 16px;
}

.insider-main-card__img {
  border-radius: var(--md-sys-shape-corner-medium);
  overflow: hidden;
  border: 1px solid var(--md-sys-color-outline-variant);
  cursor: zoom-in;
  display: flex;
  align-items: center;
  justify-content: center;
}

.insider-main-card__img img {
  width: 100%;
  height: auto;
  display: block;
}

.insider-legal-note {
  margin-top: 14px;
  font-size: 0.78rem;
  color: var(--md-sys-color-on-surface-variant);
  font-style: italic;
  line-height: 1.45;
  padding-top: 10px;
  border-top: 1px dashed var(--md-sys-color-outline-variant);
}

/* Interactive Citation Showcase with Fixed Viewport (Zero Jumps) */
.citation-feed {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-2);
  padding: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  gap: 16px;
}

.citation-showcase-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.citation-strip-viewer {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  padding: 16px 20px;
  box-shadow: var(--md-sys-elevation-1);
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Fixed Height Viewport so Switching Never Shakes Layout */
.citation-strip-viewer__img {
  height: 155px;
  border-radius: var(--md-sys-shape-corner-small);
  overflow: hidden;
  border: 1px solid var(--md-sys-color-outline-variant);
  background: #FFFFFF;
  cursor: zoom-in;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
}

.citation-strip-viewer__img img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
}

.citation-legal-note {
  margin-top: 14px;
  font-size: 0.78rem;
  color: var(--md-sys-color-on-surface-variant);
  font-style: italic;
  line-height: 1.45;
  padding-top: 10px;
  border-top: 1px dashed var(--md-sys-color-outline-variant);
}

.citation-nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.citation-dots-tape {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}

.citation-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--md-sys-color-outline-variant);
  cursor: pointer;
  transition: all 0.2s ease;
}

.citation-dot.active {
  width: 20px;
  border-radius: 9999px;
  background: var(--md-sys-color-primary);
}

/* -------------------------------------------------------------------
   5. FIELDWORK SECTION («Работа в поле» — Matched Proportions & Compact)
   ------------------------------------------------------------------- */
.fieldwork-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 32px;
  align-items: stretch;
}

@media (max-width: 960px) {
  .fieldwork-layout {
    grid-template-columns: 1fr;
  }
}

.fieldwork-photos {
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
}

.fieldwork-photo-main {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-2);
  flex: 1.45;
  min-height: 290px;
  display: flex;
}

.fieldwork-photo-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.fieldwork-photos-sub {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  flex: 1;
  min-height: 180px;
}

.fieldwork-sub-card {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-1);
  display: flex;
}

.fieldwork-sub-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.fieldwork-desc-card {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  padding: 24px 28px;
  box-shadow: var(--md-sys-elevation-1);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
  height: 100%;
}

.fieldwork-event-item {
  border-bottom: 1px solid var(--md-sys-color-outline-variant);
  padding-bottom: 16px;
}

.fieldwork-event-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.fieldwork-event-item__title {
  font-family: var(--md-sys-font-brand);
  font-size: 1.25rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface);
  margin-bottom: 6px;
}

.fieldwork-event-item__text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--md-sys-color-on-surface-variant);
}

/* -------------------------------------------------------------------
   6. GAMEDEV: «СМОТРЯЩИЙ» (Compact Width, 0 Black Bars, Visible Gauge Deltas)
   ------------------------------------------------------------------- */
.smotryaschiy-card-wrapper {
  background: #121114;
  color: #FFFFFF;
  border-radius: var(--md-sys-shape-corner-extra-large);
  padding: 36px 40px;
  box-shadow: var(--md-sys-elevation-3);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 40px;
  align-items: center;
}

@media (max-width: 960px) {
  .smotryaschiy-card-wrapper {
    grid-template-columns: 1fr;
    padding: 24px;
    gap: 32px;
  }
}

.smotryaschiy-info {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Mobile Frame (Reigns scale ~300px) */
.smotryaschiy-game-phone {
  background: #1C1B1F;
  border-radius: 36px;
  border: 3px solid #2E2C34;
  padding: 22px 16px 18px;
  max-width: 310px;
  margin: 0 auto;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
  user-select: none;
}

/* 4 Circular Indicators with Delta Badges */
.game-gauges-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  margin-bottom: 22px;
}

.game-gauge-item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.gauge-circle {
  position: relative;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #25232A;
  transition: filter 0.2s ease, transform 0.2s ease;
}

.gauge-circle svg.icon {
  width: 20px;
  height: 20px;
  fill: #FFFFFF;
  transition: transform 0.2s ease;
}

.gauge-circle svg.ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.gauge-circle circle.track {
  fill: none;
  stroke: rgba(255, 255, 255, 0.15);
  stroke-width: 3;
}

.gauge-circle circle.fill {
  fill: none;
  stroke-width: 3.5;
  stroke-dasharray: 125.6;
  stroke-dashoffset: 62.8;
  transition: stroke-dashoffset 0.18s ease, stroke 0.18s ease, filter 0.18s ease;
}

.gauge-circle.gauge-budget circle.fill { stroke: #F59E0B; }
.gauge-circle.gauge-people circle.fill { stroke: #06B6D4; }
.gauge-circle.gauge-crime circle.fill { stroke: #EF4444; }
.gauge-circle.gauge-kremlin circle.fill { stroke: #10B981; }

.gauge-title {
  font-family: var(--md-sys-font-plain);
  font-size: 0.65rem;
  letter-spacing: 0.08em;
  color: #A09DAB;
  text-transform: uppercase;
}

/* Card: 100% Edge-to-Edge Art without Black Bars */
.game-card-drag {
  background: #25232A;
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.45);
  cursor: grab;
  position: relative;
  transition: transform 0.15s ease-out;
  width: 100%;
  user-select: none;
  -webkit-user-select: none;
}

.game-card-drag:active {
  cursor: grabbing;
}

.game-card-drag__art {
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: transparent;
  display: block;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.game-card-drag__art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  user-select: none;
  -webkit-user-select: none;
  -webkit-user-drag: none;
}

.game-card-drag__content {
  padding: 16px 14px 18px;
}

.game-card-drag__title {
  font-family: var(--md-sys-font-brand);
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #FFFFFF;
  margin-bottom: 6px;
}

.game-card-drag__text {
  font-size: 0.82rem;
  line-height: 1.45;
  color: #B8B5C3;
}

/* Stamp Overlay */
.game-stamp-badge {
  position: absolute;
  top: 45%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: #FFFFFF;
  color: #121212;
  border: 3px solid #000000;
  border-radius: 12px;
  padding: 8px 16px;
  font-family: var(--md-sys-font-brand);
  font-size: 1.1rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  opacity: 0;
  pointer-events: none;
  z-index: 10;
  white-space: nowrap;
  transition: opacity 0.12s ease;
}

/* Bottom Game Controls */
.game-phone-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 16px;
  padding: 0 4px;
}

.game-date-label {
  font-family: var(--md-sys-font-plain);
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #A09DAB;
}

.game-pause-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #25232A;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--md-sys-font-plain);
  font-weight: 700;
  font-size: 0.85rem;
}

/* -------------------------------------------------------------------
   7. GAMEDEV: «THE PRICE OF MEMORIES»
   ------------------------------------------------------------------- */
.pom-container {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-1);
  padding: 40px;
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 960px) {
  .pom-container {
    grid-template-columns: 1fr;
    padding: 24px;
    gap: 36px;
  }
}

.pom-device-stage {
  position: relative;
  min-height: 440px;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 600px) {
  .pom-device-stage {
    min-height: 320px;
  }
}

/* 1. PC Monitor (Gunmetal Titanium, Stand clearly visible) */
.model-monitor {
  position: relative;
  width: 88%;
  max-width: 480px;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  transition: transform 0.25s ease;
}

.model-monitor:hover {
  transform: translateY(-4px);
}

.model-monitor__screen {
  width: 100%;
  background: #18191E;
  border: 5px solid #282B33;
  border-radius: 12px 12px 0 0;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}

.model-monitor__screen img {
  width: 100%;
  height: auto;
  display: block;
}

.model-monitor__chin {
  width: 100%;
  height: 16px;
  background: #242730;
  display: flex;
  align-items: center;
  justify-content: center;
  border-top: 1px solid #363A45;
  border-bottom: 1px solid #1A1C22;
}

.model-monitor__led {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #10B981;
  box-shadow: 0 0 6px #10B981;
}

.model-monitor__neck {
  width: 36px;
  height: 48px;
  background: linear-gradient(to right, #383D48, #5A6273, #383D48);
  box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.5);
  position: relative;
  z-index: 1;
}

.model-monitor__base {
  width: 170px;
  height: 12px;
  background: linear-gradient(to bottom, #454B58, #252830);
  border-radius: 4px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
  position: relative;
  z-index: 1;
  border-top: 1px solid #636B7D;
}

/* 2. Laptop (Midnight Obsidian Black) */
.model-laptop {
  position: absolute;
  bottom: 10px;
  left: -20px;
  width: 60%;
  max-width: 320px;
  z-index: 2;
  transition: transform 0.25s ease, z-index 0.25s ease;
}

.model-laptop:hover {
  transform: translateY(-5px) scale(1.02);
  z-index: 5;
}

.model-laptop__lid {
  background: #12141A;
  border: 3px solid #1E232E;
  border-radius: 8px 8px 0 0;
  overflow: hidden;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.model-laptop__lid img {
  width: 100%;
  height: auto;
  display: block;
}

.model-laptop__base {
  width: 108%;
  margin-left: -4%;
  height: 18px;
  background: linear-gradient(to bottom, #2A303D, #161922);
  border-radius: 2px 2px 8px 8px;
  border-top: 1px solid #3F4758;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.model-laptop__notch {
  width: 36px;
  height: 3px;
  background: #0E1015;
  border-radius: 0 0 3px 3px;
  position: absolute;
  top: 0;
}

/* 3. Smartphone (Horizontal Landscape, Camera Punch-hole on Left, Elevated) */
.model-phone {
  position: absolute;
  bottom: 24px;
  right: -10px;
  width: 38%;
  max-width: 200px;
  z-index: 4;
  background: #0D0C0E;
  border: 3.5px solid #28242D;
  border-radius: 20px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.55);
  overflow: hidden;
  transition: transform 0.25s ease, z-index 0.25s ease;
}

.model-phone:hover {
  transform: translateY(-5px) scale(1.04);
  z-index: 6;
}

.model-phone__camera-hole {
  position: absolute;
  left: 8px;
  top: 50%;
  transform: translateY(-50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #000000;
  border: 1px solid rgba(255, 255, 255, 0.25);
  z-index: 6;
  box-shadow: inset 0 0 2px rgba(255, 255, 255, 0.4);
}

.model-phone__screen img {
  width: 100%;
  height: auto;
  display: block;
}

/* -------------------------------------------------------------------
   8. EDITORIAL AUTOMATION & AI (Compact 5G Pipeline + Interactive AI Lab)
   ------------------------------------------------------------------- */
.automation-card {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-1);
  padding: 26px 30px;
  margin-bottom: 28px;
}

@media (max-width: 768px) {
  .automation-card {
    padding: 20px 16px;
  }
}

/* Compact 4-Stage Interactive Pipeline Stepper */
.pipeline-stepper-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 18px;
  margin-bottom: 20px;
}

@media (max-width: 900px) {
  .pipeline-stepper-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 500px) {
  .pipeline-stepper-grid {
    grid-template-columns: 1fr;
  }
}

.pipeline-step-card {
  background: var(--md-sys-color-surface-container);
  border: 1px solid var(--md-sys-color-outline-variant);
  border-radius: var(--md-sys-shape-corner-medium);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: all 0.25s ease;
  cursor: pointer;
  min-height: 94px;
}

.pipeline-step-card.active {
  border-color: var(--md-sys-color-primary);
  background: var(--md-sys-color-surface-container-high);
  box-shadow: 0 4px 16px rgba(217, 35, 47, 0.15);
}

.pipeline-step-card.completed {
  border-color: #10B981;
}

.step-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.step-card-num {
  font-family: var(--md-sys-font-brand);
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--md-sys-color-primary);
}

.step-card-status {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface-variant);
}

.pipeline-step-card.active .step-card-status {
  color: var(--md-sys-color-primary);
}

.pipeline-step-card.completed .step-card-status {
  color: #10B981;
}

.step-card-title {
  font-family: var(--md-sys-font-brand);
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface);
}

.step-card-desc {
  font-size: 0.78rem;
  line-height: 1.35;
  color: var(--md-sys-color-on-surface-variant);
}

/* Compact Crossposting Live Playground */
.crosspost-playground {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 18px;
  align-items: stretch;
  transition: all 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}

.crosspost-playground.initial-centered {
  grid-template-columns: 1fr;
  max-width: 480px;
  margin: 0 auto;
}

.crosspost-playground.initial-centered .crosspost-connector-box,
.crosspost-playground.initial-centered #max-post-card {
  display: none !important;
}

@media (max-width: 860px) {
  .crosspost-playground {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

.channel-card {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: 20px;
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-2);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 410px;
  transition: all 0.4s ease;
}

.channel-card__post-wrap {
  min-height: 340px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.channel-card__header {
  padding: 12px 16px;
  background: var(--md-sys-color-surface-container);
  border-bottom: 1px solid var(--md-sys-color-outline-variant);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
}

.channel-card__header-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.channel-card__img {
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: 130px;
  object-fit: cover;
  display: block;
}

.channel-card__body {
  padding: 12px 16px;
  font-size: 0.85rem;
  line-height: 1.45;
  color: var(--md-sys-color-on-surface);
  flex-grow: 1;
}

.channel-card__footer {
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed var(--md-sys-color-outline-variant);
  font-size: 0.8rem;
  font-weight: 700;
  display: none; /* Injected dynamically during Stage 4 */
}

/* Staging Standby Placeholder State */
.channel-staging-standby {
  padding: 28px 18px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 340px;
  transition: opacity 0.3s ease;
}

.staging-pulse-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--md-sys-color-surface-container);
  color: var(--md-sys-color-outline);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px dashed var(--md-sys-color-outline-variant);
  animation: pulseGhostIcon 2.4s infinite ease-in-out;
}

@keyframes pulseGhostIcon {
  0%, 100% { transform: scale(1); opacity: 0.7; }
  50% { transform: scale(1.06); opacity: 1; border-color: var(--md-sys-color-primary); color: var(--md-sys-color-primary); }
}

.staging-standby-title {
  font-family: var(--md-sys-font-brand);
  font-size: 0.95rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface);
}

.staging-standby-desc {
  font-size: 0.8rem;
  color: var(--md-sys-color-on-surface-variant);
  max-width: 240px;
  line-height: 1.4;
}

.channel-published-content {
  transition: opacity 0.4s ease;
}

.crosspost-connector-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.crosspost-bridge-line {
  position: relative;
  width: 60px;
  height: 4px;
  background: var(--md-sys-color-outline-variant);
  border-radius: 999px;
}

@media (max-width: 860px) {
  .crosspost-bridge-line {
    width: 4px;
    height: 32px;
  }
}

.bridge-pulse {
  position: absolute;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--md-sys-color-primary);
  opacity: 0;
}

/* Watermark Bot Layout (GPU Accelerated 120 FPS) */
.watermark-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 36px;
  align-items: center;
}

@media (max-width: 900px) {
  .watermark-layout {
    grid-template-columns: 1fr;
  }
}

.watermark-slider-box {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-2);
  user-select: none;
  touch-action: pan-y;
}

.watermark-slider-box img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
}

.watermark-slider-box .img-before {
  z-index: 1;
}

.watermark-slider-box .img-after {
  z-index: 2;
  will-change: clip-path;
  transform: translate3d(0, 0, 0);
  clip-path: polygon(0% 0%, 23% 0%, 23% 100%, 0% 100%);
}

.watermark-slider-handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 23%;
  width: 3px;
  background: #FFFFFF;
  cursor: ew-resize;
  z-index: 10;
  box-shadow: 0 0 12px rgba(0, 0, 0, 0.4), 0 0 6px rgba(255, 255, 255, 0.8);
  transform: translate3d(-50%, 0, 0);
  will-change: left, transform;
}

.watermark-slider-knob {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #FFFFFF;
  color: var(--md-sys-color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35), 0 0 0 2px rgba(255, 255, 255, 0.9);
  cursor: ew-resize;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  user-select: none;
}

.watermark-slider-handle:hover .watermark-slider-knob,
.watermark-slider-handle.dragging .watermark-slider-knob {
  transform: translate(-50%, -50%) scale(1.14);
  box-shadow: 0 6px 22px rgba(0, 0, 0, 0.45), 0 0 0 3px var(--md-sys-color-primary);
}

/* -------------------------------------------------------------------
   9. INTERACTIVE AI EDITORIAL LAB (Interactive Audio Wave & Modes)
   ------------------------------------------------------------------- */
.ai-lab-tabs-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 20px;
  margin-bottom: 20px;
}

.ai-tab-btn {
  background: var(--md-sys-color-surface-container);
  border: 1px solid var(--md-sys-color-outline-variant);
  border-radius: 9999px;
  padding: 8px 18px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--md-sys-color-on-surface);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all var(--md-sys-motion-duration-short) ease;
}

.ai-tab-btn:hover {
  background: var(--md-sys-color-surface-container-high);
}

.ai-tab-btn.active {
  background: var(--md-sys-color-primary);
  color: var(--md-sys-color-on-primary);
  border-color: var(--md-sys-color-primary);
  box-shadow: 0 4px 12px rgba(217, 35, 47, 0.2);
}

.ai-lab-interactive-stage {
  background: var(--md-sys-color-surface-container);
  border: 1px solid var(--md-sys-color-outline-variant);
  border-radius: var(--md-sys-shape-corner-large);
  padding: 24px 28px;
  min-height: 200px;
  box-shadow: var(--md-sys-elevation-1);
}

/* Mode 1: Audio Dictaphone */
.ai-audio-player-box {
  display: flex;
  align-items: center;
  gap: 20px;
  background: var(--md-sys-color-surface-container-lowest);
  padding: 16px 20px;
  border-radius: var(--md-sys-shape-corner-medium);
  border: 1px solid var(--md-sys-color-outline-variant);
  margin-bottom: 16px;
}

.audio-play-circle-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--md-sys-color-primary);
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 12px rgba(217, 35, 47, 0.3);
  transition: transform 0.2s ease;
  flex-shrink: 0;
}

.audio-play-circle-btn:hover {
  transform: scale(1.08);
}

.audio-wave-container {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 32px;
  flex-grow: 1;
}

.ai-transcript-box {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-medium);
  border: 1px solid var(--md-sys-color-outline-variant);
  padding: 18px 20px;
  font-family: var(--md-sys-font-plain);
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--md-sys-color-on-surface);
}

/* Mode 2: Summarization & Live Document Scanner */
.ai-doc-scanner-box {
  position: relative;
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-medium);
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-1);
}

.ai-doc-scanner-header {
  background: var(--md-sys-color-surface-container);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--md-sys-color-outline-variant);
  font-size: 0.8rem;
  font-weight: 700;
}

.scanner-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--md-sys-color-on-surface);
}

.scanner-live-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--md-sys-color-primary);
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.05em;
}

.scanner-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--md-sys-color-primary);
  animation: pulseLaserDot 1.4s infinite ease-in-out;
}

@keyframes pulseLaserDot {
  0%, 100% { transform: scale(1); opacity: 0.6; }
  50% { transform: scale(1.4); opacity: 1; }
}

.ai-doc-scanner-body {
  position: relative;
  padding: 18px 20px;
}

.ai-scan-laser-line {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--md-sys-color-primary), #FF6B6B, transparent);
  box-shadow: 0 0 10px rgba(217, 35, 47, 0.7), 0 0 20px rgba(217, 35, 47, 0.4);
  animation: scanLaserLine 3.2s infinite ease-in-out;
  pointer-events: none;
  z-index: 5;
}

@keyframes scanLaserLine {
  0% { top: 0%; opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { top: 100%; opacity: 0; }
}

.ai-doc-dense-text {
  font-size: 0.9rem;
  line-height: 1.7;
  color: var(--md-sys-color-on-surface-variant);
}

.ai-fact-highlight {
  background: rgba(217, 35, 47, 0.12);
  color: var(--md-sys-color-on-surface);
  border-bottom: 2px solid var(--md-sys-color-primary);
  padding: 1px 4px;
  border-radius: 2px;
  font-weight: 600;
  transition: background 0.3s ease;
}

.ai-fact-highlight:hover {
  background: rgba(217, 35, 47, 0.22);
}

.ai-summary-points {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}

.ai-summary-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  background: var(--md-sys-color-surface-container-lowest);
  padding: 12px 16px;
  border-radius: var(--md-sys-shape-corner-small);
  border-left: 3px solid var(--md-sys-color-primary);
  font-size: 0.9rem;
  line-height: 1.45;
}

.ai-summary-num {
  font-family: var(--md-sys-font-brand);
  font-weight: 800;
  font-size: 0.85rem;
  color: var(--md-sys-color-primary);
}

/* Compression Gauge Footer */
.ai-compression-footer {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--md-sys-color-outline-variant);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.ai-compression-bar-wrap {
  flex: 1;
  min-width: 240px;
}

.ai-compression-label {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: var(--md-sys-color-on-surface-variant);
  margin-bottom: 6px;
}

.ai-compression-label strong {
  color: var(--md-sys-color-primary);
}

.ai-compression-track {
  width: 100%;
  height: 6px;
  border-radius: 999px;
  background: var(--md-sys-color-surface-container-highest);
  overflow: hidden;
}

.ai-compression-fill {
  width: 94%;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--md-sys-color-primary), #10B981);
  animation: growCompressionFill 1.8s ease-out;
}

@keyframes growCompressionFill {
  0% { width: 0%; }
  100% { width: 94%; }
}

.ai-compression-stat {
  font-size: 0.78rem;
  font-weight: 700;
  color: #10B981;
}

/* -------------------------------------------------------------------
   10. SPECIAL PROJECTS («Спецпроекты»: Научпоп и Театр)
   ------------------------------------------------------------------- */
.unp-card {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-1);
  overflow: hidden;
  margin-bottom: 36px;
}

.unp-banner-box {
  width: 100%;
  height: 220px;
  overflow: hidden;
  background: #000;
}

.unp-banner-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.unp-body {
  padding: 32px;
}

.unp-videos-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: 24px;
}

@media (max-width: 860px) {
  .unp-videos-grid {
    grid-template-columns: 1fr;
  }
}

.unp-video-box {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-medium);
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-1);
  display: block;
  text-decoration: none;
}

.unp-video-box__thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  overflow: hidden;
}

.unp-video-box__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.unp-video-box__title {
  padding: 14px;
  font-family: var(--md-sys-font-brand);
  font-size: 1.05rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--md-sys-color-on-surface);
  line-height: 1.3;
}

/* Theater Productions */
.theater-container {
  background: var(--md-sys-color-surface-container-low);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-1);
  padding: 36px;
}

@media (max-width: 768px) {
  .theater-container {
    padding: 24px;
  }
}

/* 6 Musicals in 3x2 Grid (3 on top, 3 on bottom) */
.theater-musicals-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 24px;
  margin-bottom: 32px;
}

@media (max-width: 960px) {
  .theater-musicals-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .theater-musicals-grid {
    grid-template-columns: 1fr;
  }
}

.musical-card {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-medium);
  border: 1px solid var(--md-sys-color-outline-variant);
  padding: 18px;
  box-shadow: var(--md-sys-elevation-1);
  display: flex;
  flex-direction: column;
}

.musical-card--featured {
  background: var(--md-sys-color-primary-container);
  border-color: transparent;
  color: var(--md-sys-color-on-primary-container);
  margin-bottom: 20px;
  padding: 24px;
  border-radius: var(--md-sys-shape-corner-large);
}

.musical-card__tag {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--md-sys-color-primary);
  margin-bottom: 4px;
}

.musical-card--featured .musical-card__tag {
  color: var(--md-sys-color-on-primary-container);
}

.musical-card__title {
  font-family: var(--md-sys-font-brand);
  font-size: 1.25rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.musical-card__desc {
  font-size: 0.88rem;
  color: var(--md-sys-color-on-surface-variant);
  line-height: 1.45;
}

.musical-card--featured .musical-card__desc {
  color: var(--md-sys-color-on-primary-container);
  font-size: 0.95rem;
}

/* Magazine Editorial Stage Gallery (1 Portrait Anchor + 4 Landscapes) */
.theater-editorial-gallery {
  display: grid;
  grid-template-columns: 1fr 1.6fr;
  gap: 16px;
  align-items: stretch;
}

@media (max-width: 860px) {
  .theater-editorial-gallery {
    grid-template-columns: 1fr;
  }
}

.stage-card-portrait {
  background: #111;
  border-radius: var(--md-sys-shape-corner-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-2);
  cursor: zoom-in;
  display: flex;
}

.stage-card-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.stage-grid-landscapes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.stage-card-landscape {
  background: #111;
  border-radius: var(--md-sys-shape-corner-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  overflow: hidden;
  box-shadow: var(--md-sys-elevation-1);
  cursor: zoom-in;
  display: flex;
}

.stage-card-landscape img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* -------------------------------------------------------------------
   11. FOOTER (Clean MD3 with Official VK SVG & Sleek Social Pills)
   ------------------------------------------------------------------- */
.footer-md3 {
  background: var(--md-sys-color-surface-container);
  border-top: 1px solid var(--md-sys-color-outline-variant);
  padding: 36px 0;
}

.footer-md3__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
}

.footer-md3__contacts {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
}

.footer-social-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 18px;
  border-radius: 9999px;
  background: var(--md-sys-color-surface-container-high);
  border: 1px solid var(--md-sys-color-outline-variant);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--md-sys-color-on-surface);
  text-decoration: none;
  transition: all var(--md-sys-motion-duration-short) ease;
}

.footer-social-pill:hover {
  background: var(--md-sys-color-primary);
  color: var(--md-sys-color-on-primary);
  border-color: var(--md-sys-color-primary);
  transform: translateY(-2px);
  box-shadow: var(--md-sys-elevation-2);
}

.footer-social-pill svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  display: block;
}

.footer-md3__copy {
  font-size: 0.85rem;
  color: var(--md-sys-color-on-surface-variant);
}

/* -------------------------------------------------------------------
   12. LIGHTBOX MODAL
   ------------------------------------------------------------------- */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(18, 18, 18, 0.88);
  backdrop-filter: blur(8px);
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.lightbox-modal.active {
  display: flex;
}

.lightbox-modal__content {
  background: var(--md-sys-color-surface-container-lowest);
  border-radius: var(--md-sys-shape-corner-extra-large);
  border: 1px solid var(--md-sys-color-outline-variant);
  box-shadow: var(--md-sys-elevation-3);
  padding: 16px;
  max-width: 90vw;
  max-height: 85vh;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-modal__img {
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
  border-radius: var(--md-sys-shape-corner-medium);
}

.lightbox-modal__caption {
  margin-top: 12px;
  font-size: 0.88rem;
  color: var(--md-sys-color-on-surface);
  text-align: center;
}

.lightbox-modal__close {
  position: absolute;
  top: -40px;
  right: 0;
  color: #FFFFFF;
  font-size: 1.8rem;
  cursor: pointer;
  background: transparent;
  border: none;
}
