/* =========================
   VARIABLES
   ========================= */
:root {
  --bg-main: #000000;
  --bg-card: #171717;
  --bg-card-soft: #060606;

  --text-main: #ffffff;
  --text-muted: #d0d0d0;

  --accent-blue: #2f80ff;

  --radius-xl: 28px;
  --radius-lg: 22px;

  --font-title: "Inter", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: "Rubik", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;

  --transition: 0.35s ease-out;
}

/* =========================
   RESET
   ========================= */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
}

/* =========================
   PAGE WRAPPER
   ========================= */
.case {
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
  padding: 40px 20px 64px;
  position: relative;

  /* эффект плавного появления */
  opacity: 0;
  transform: translateY(16px);
  filter: blur(4px);
  transition: opacity 0.45s ease-out,
              transform 0.45s ease-out,
              filter 0.45s ease-out;
}

.case--visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}



/* =========================
   PROJECTS HEADER
   ========================= */
.projects-label {
  text-align: left;
  color: var(--text-muted);
  margin-bottom: 32px;
  font-size: 22px;
  opacity: 0.6;
}

/* =========================
   SLIDER ZONE (контейнер)
   ========================= */
.slider-zone {
  position: relative;
  
}

/* =========================
   NETFLIX-STYLE NAV ZONES
   ========================= */

.nav-zone {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 22%;
  max-width: 200px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease-out, background-color 0.25s ease-out;
  z-index: 30;
}

/* Базовая позиция (мобайл/планшет мы скрываем в media ниже) */
.nav-zone--left {

}

.nav-zone--right {
   background: transparent !important;

}

.nav-zone::after {
  content: "";
  position: absolute;
  top: 50%;
  width: 38px;
  height: 38px;
  transform: translateY(-50%);
  opacity: 0;
  transition: opacity 0.25s ease, transform 0.25s ease;
  background-size: 22px;
  background-repeat: no-repeat;
  background-position: center;
  filter: drop-shadow(0 0 6px rgba(0, 0, 0, 0.5));
}

/* Чисто белые стрелки */
.nav-zone--left::after {
  left: 12px;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28"><path d="M18 4 L8 14 L18 24" stroke="%23ffffff" stroke-width="3" fill="none" stroke-linecap="round" stroke-linejoin="round"/></svg>');
}

.nav-zone--right::after {
  right: 12px;
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="28" height="28"><path d="M10 4 L20 14 L10 24" stroke="%23ffffff" stroke-width="3" fill="none" stroke-linecap="round" stroke-linejoin="round"/></svg>');
}

/* Появление зон и стрелок при наведении на весь блок */
.slider-zone:hover .nav-zone {
  opacity: 0.22;
  pointer-events: auto;
}

.slider-zone:hover .nav-zone::after {
  opacity: 1;
}

/* Усиление при ховере именно по зоне */
.nav-zone:hover {
  background: transparent !important;
  opacity: 0.9; /* можешь регулировать интенсивность появления стрелки */
}

.nav-zone:hover::after {
  transform: translateY(-50%) scale(1.12);
}

/* МОБИЛА — зон нет */
@media (max-width: 1023px) {
  .nav-zone {
    display: none;
  }
}

/* ДЕСКТОП — выносим стрелки за пределы карточек */
@media (min-width: 1024px) {
  .nav-zone--left {
    left: -56px;  /* стрелка и зона чуть вынесены за блок влево */
  }
  .nav-zone--right {
    right: -56px; /* и вправо */
  }
}

/* =========================
   HEADER
   ========================= */
.case-header {
  margin-bottom: 24px;
}

.case-title {
  margin: 0 0 18px;
  margin-top: 100px;
  font-family: var(--font-title);
  font-weight: 500;
  font-size: 34px;
  line-height: 1.08;
}

.case-intro {
  margin: 0;
  font-size: 16px;
  line-height: 1.3;
  color: var(--text-muted);
}

/* =========================
   IMAGE SLIDER
   ========================= */
.media-card {
  background-color: transparent
  border-radius: 0px; 
  padding: 8px;
}

.slider {
  position: relative;
  overflow: hidden;
  border-radius: 0px; 
}

.slider-track {
  display: flex;
  width: 100%;
  transition: transform var(--transition);
  will-change: transform;
}

.slider-slide {
  flex: 0 0 100%;
}

.slider-slide--image img {
  width: 100%;
  border-radius: 0px;
}

/* ВИДЕО-СЛАЙД: делаем его высоким 9:16 */
.slider-slide--video {
  position: relative;
  padding-top: 177.78%; /* вертикальное видео 9:16 */
  background: #000;
}

/* Само видео заполняет этот «кадр» */
.slider-slide--video .case-media--video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-radius: 11px
}
/* =========================
   DOTS (общий стиль)
   ========================= */
.slider-dots,
.text-slider-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 24px;
  margin-bottom: 24px;
  
}

.slider-dot,
.text-slider-dot {
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: #444;
  transition: width 0.2s, background 0.2s;
}

/* Активная точка — ПИЛЮЛЯ и для картинок, и для текста */
.slider-dot--active,
.text-slider-dot--active {
  width: 18px;
  background: #ffc5e7;
  
}

/* =========================
   TEXT SLIDER
   ========================= */
.text-slider {
  overflow: hidden;
}

.text-slider-track {
  display: flex;
  width: 100%;
  transition: transform var(--transition);
  will-change: transform;
}

.text-card {
  flex: 0 0 100%;
  background:  rgb(21, 21, 21);
  box-shadow: #444;
  
  border-radius: var(--radius-xl);
  padding: 20px;
  margin-top: 10px;
  
}

.text-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.text-card-dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: var(--accent-blue);
}

.text-card-title {
  margin: 0;
  font-size: 15px;
  font-weight: 500;
}

.text-card-body p {
  margin: 0 0 10px;
  color: var(--text-muted);
}

.text-card-body p:last-child {
  margin-bottom: 0;
}

/* =========================
   PROJECT NAME SLIDES
   ========================= */
.slider--projects {
  /* чтобы работало как обычный слайдер, но текст по центру */
}

.slider-slide--project-name {
  display: flex;
  justify-content: center;   /* центрируем внутреннюю пилюлю */
  align-items: center;
}

.project-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  border-radius: 999px;
  background: #161616;
  color: var(--text-muted);
  font-family: var(--font-title);
  font-size: 20px;
  letter-spacing: 0.02em;
  transition: background 5s ease, color 0.5s ease;
}

.project-pill--active {
  background: #000000;
  color: #ffffff;
  
}

/* =========================
   FADE-IN ANIMATION
   ========================= */
.fade-in {
  opacity: 0;
  transform: translateY(10px);
  filter: blur(1px);
}

.fade-in-visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
  transition: 0.4s ease-out;
}

/* =========================
   PARALLAX
   ========================= */
.parallax-item {
  will-change: transform;
  transition: transform 0.25s ease-out;
}

/* =========================
   ADAPTIVE
   ========================= */
@media (min-width: 600px) {
  .case {
    padding: 48px 28px 72px;
  }
  .case-title {
    font-size: 36px;
  }
}

@media (min-width: 768px) {
  .case {
    max-width: 600px;
  }
  .case-title {
    font-size: 38px;
  }
  .case-intro {
    font-size: 16px;
  }
}

@media (min-width: 1024px) {
  .case {
    max-width: 720px;
    padding: 94px 32px 96px;
  }
  .case-title {
    font-size: 40px;
  }
}

@media (min-width: 1440px) {
  .case {
    max-width: 780px;
  }
  .case-title {
    font-size: 42px;
  }
}

/* =========================
   HEADER LOGO + BURGER
   ========================= */
.site-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-left: 20px;
  padding-right: 20px;
  padding-top: 46px;
  position: sticky;
  top: 0;
  background-color: var(--bg-main);
  z-index: 100;
  max-width: 720px;
  margin: 0 auto;
 
}

.site-logo {
  height: 88px;
  width: auto;
  transition: color 0.3s ease, transform 0.3s ease;
  
  
  
}


.site-logo:hover {
  
  transform: translateX(14px); /* лёгкое смещение при наведении */
}

.site-nav {
  display: flex;
  gap: 24px;
  max-width: 720px;
}

.site-nav a {
  color: white;
  text-decoration: none;
  transition: opacity 0.3s;
  
}

.site-nav a:hover {
  opacity: 0.6;
}

.site-nav a:visited {
  color: white;
}




/* =========================
   FOOTER CAR IMAGE
   ========================= */
.footer {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  padding: 4rem 2rem;
  max-width: 720px;
  margin: 0 auto;
  flex-wrap: wrap;
}

.footer-left {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  color: white;
}

.footer-email {
  font-weight: 400;
  opacity: 0.7;
}

.footer-location {
  font-weight: 400;
}

.footer-socials a {
  color: white;
  text-decoration: none;
  font-size: 2rem;
  display: block;
  margin-bottom: 0.5rem;
  transition: color 0.3s ease, transform 0.3s ease;
}

.footer-socials a:hover {
  color: #ababab; /* розовый или любой другой цвет */
  transform: translateX(4px); /* лёгкое смещение при наведении */
}


.footer-car img {
  max-width: 300px;
  height: auto;
  transition: color 0.1s ease, transform 0.8s ease;
  transform: translateX(14px);
}

.footer-car img:hover {
  max-width: 300px;
  height: auto;
  transition: color 0.1s ease, transform 0.8s ease;
  transform: translateX(44px);
}

/* Responsive */
@media (max-width: 768px) {
  .footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-car {
    align-self: center;
  }
}



.intro-modal {
  position: fixed;
  z-index: 9999;
  inset: 0;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.992);
  transition: background 0.5s ease;
}

  


.intro-modal-content {
  background: #1b1b1b;
  color: white;
  padding: 2rem;
  border-radius: 1.25rem;
  max-width: 90vw;
  width: 560px;
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  animation: fadeIn 0.5s ease-out;
}


.intro-modal-text p {
  margin: 0;
  font-family: 'Helvetica Neue', sans-serif;
}

.intro-greeting {
  font-size: 1.5rem;
  padding-bottom: 2rem;
}

.intro-name {
  font-size: 2.4rem;
  line-height: 1.2;
}

.intro-name strong {
  font-weight: 500;
}

.intro-role {
  font-size: 1.5rem;
  line-height: 1.2;
  padding-bottom: 1.5rem;
  padding-top: 0.5rem;
}

.intro-contact {
  font-size: 0.85rem;
  color: #aaa;
  
}

.intro-button {
  background: white;
  color: black;
  font-size: 1.2rem;
  padding: 0.75rem 1.5rem;
  border: none;
  border-radius: 2rem;
  cursor: pointer;
  width: 100%;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ===============================
   WORKS GRID
   =============================== */

.page--works {
  background-color: var(--bg-main, #000);
}

/* -------- Page layout -------- */

.works {
  max-width: 720px;
  margin: 0 auto;
  padding: 80px 24px 160px;
}

.works-header {
  margin-bottom: 64px;
}

.works-title {
  font-size: 48px;
  font-weight: 300;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.works-intro {
  font-size: 16px;
  opacity: 0.7;
  max-width: 520px;
}

/* -------- Grid -------- */

.works-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}


/* -------- Card -------- */

.work-card {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.work-card-media {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 12px;
  background-color: #111;
}

.work-card-media img,
.work-card-media video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s cubic-bezier(.34,0.6,.64,1);
}

.work-card:hover .work-card-media img,
.work-card:hover .work-card-media video {
  transform: scale(1.04);
}

/* -------- Text -------- */

.work-card-title {
  font-size: 16px;
  font-weight: 300;
}

.work-card-meta {
  font-size: 14px;
  opacity: 0.6;
}

/* -------- Video badge -------- */

.work-card-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  padding: 6px 10px;
  font-size: 12px;
  border-radius: 999px;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(6px);
}

/* -------- Responsive -------- */

@media (max-width: 1200px) {
  .works-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

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

  .works {
    padding-top: 96px;
  }
}

@media (max-width: 560px) {
  .works-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}


/* =========================
   INTRO ACTIONS
   ========================= */

.intro-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.intro-button--secondary {
  background: transparent;
  color: white;
  border: 1px solid rgba(255,255,255,0.3);
}

/* ----- make slides not glue together ----- */
.text-slider-track .text-card {
  width: calc(100% - 32px); /* 16px слева + 16px справа */
  margin: 0 auto;           /* центрируем внутри 100% слайда */
}

/* каждый текстовый СЛАЙД занимает 100% */
.text-slide {
  flex: 0 0 100%;
  padding: 0 8px;          /* вот он — “воздух” между вагонами */
  box-sizing: border-box;
}

/* карточка теперь внутри */
.text-slide .text-card {
  width: 100%;
}


/* чуть визуально отделим карточки при движении */
.text-card {
  box-shadow: 0 12px 30px rgba(0,0,0,0.35);
  border: 1px solid rgba(255,255,255,0.06);
}
