/* ===== FONTS (локально, без Google Fonts — доступность из РФ) ===== */
@font-face { font-family:'Inter'; font-style:normal; font-weight:400; font-display:swap; src:url('/fonts/inter-400-latin.woff2') format('woff2'); unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:400; font-display:swap; src:url('/fonts/inter-400.woff2') format('woff2'); unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:500; font-display:swap; src:url('/fonts/inter-500-latin.woff2') format('woff2'); unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:500; font-display:swap; src:url('/fonts/inter-500.woff2') format('woff2'); unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:600; font-display:swap; src:url('/fonts/inter-600-latin.woff2') format('woff2'); unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:600; font-display:swap; src:url('/fonts/inter-600.woff2') format('woff2'); unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:700; font-display:swap; src:url('/fonts/inter-700-latin.woff2') format('woff2'); unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:700; font-display:swap; src:url('/fonts/inter-700.woff2') format('woff2'); unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:900; font-display:swap; src:url('/fonts/inter-900-latin.woff2') format('woff2'); unicode-range:U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+2074,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD; }
@font-face { font-family:'Inter'; font-style:normal; font-weight:900; font-display:swap; src:url('/fonts/inter-900.woff2') format('woff2'); unicode-range:U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0a0a0a;
  --surface:   #111111;
  --surface-2: #1a1a1a;
  --border:    #222222;
  --text:      #ffffff;
  --muted:     #777777;
  --accent:    #ff4d00;
  --accent-h:  #e84400;
  --radius:    12px;
  --nav-h:     68px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ===== NAV ===== */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  transition: background 0.3s;
}

.nav-inner {
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-logo {
  font-size: 20px;
  font-weight: 900;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}
.nav-logo span { color: var(--accent); }

.nav-links {
  display: flex;
  list-style: none;
  gap: 8px;
  flex: 1;
}

.nav-links a {
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.nav-links a:hover { color: var(--text); border-color: var(--border); }

.nav-phone {
  font-size: 14px;
  font-weight: 500;
  color: var(--muted);
  white-space: nowrap;
  transition: color 0.2s;
  margin-left: auto;
}
.nav-phone:hover { color: var(--text); }

.nav-burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  margin-left: auto;
}
.nav-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.3s;
}

.nav-mobile {
  display: none;
  flex-direction: column;
  padding: 12px 24px 20px;
  border-top: 1px solid var(--border);
  background: var(--bg);
}
.nav-mobile.open { display: flex; }
.nav-mobile-link {
  font-size: 15px;
  color: var(--muted);
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  transition: color 0.2s;
}
.nav-mobile-link:last-child { border-bottom: none; }
.nav-mobile-link:hover { color: var(--text); }

/* ===== HERO ===== */
.hero {
  min-height: 85vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: var(--nav-h);
  padding-bottom: 40px;
  position: relative;
  overflow: hidden;
}

/* gradient-fade в works-section — плавный переход */
.hero::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 140px;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
  z-index: 1;
}

.hero::before {
  content: 'DUVISION';
  position: absolute;
  bottom: -60px;
  left: 50%;
  transform: translateX(-50%);
  font-size: clamp(80px, 18vw, 260px);
  font-weight: 900;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.04);
  white-space: nowrap;
  pointer-events: none;
  letter-spacing: -0.04em;
  -webkit-user-select: none;
  user-select: none;
}

.hero-inner {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1fr 480px;
  gap: 56px;
  align-items: center;
  width: 100%;
  max-width: 1160px;
  padding: 0 24px;
}

.hero-left {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 28px;
}

.hero-sub {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.3em;
  color: var(--muted);
  text-transform: uppercase;
}

.hero-title {
  font-size: clamp(64px, 10vw, 140px);
  font-weight: 900;
  letter-spacing: -0.04em;
  line-height: 0.9;
  text-transform: uppercase;
}

/* ===== HERO FEATURED CARD ===== */
.hero-right {
  position: relative;
  z-index: 2;
}

.hero-featured {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  aspect-ratio: 16/10;
  background: var(--surface);
  box-shadow: 0 24px 64px rgba(0,0,0,0.6);
}

.hero-featured-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.5s ease;
}
.hero-featured:hover .hero-featured-thumb { transform: scale(1.04); }

.hero-featured-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  transition: background 0.3s;
}
.hero-featured:hover .hero-featured-overlay { background: rgba(0,0,0,0.62); }

.hero-featured-label {
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  padding: 0 20px;
  color: rgba(255,255,255,0.9);
  letter-spacing: 0.01em;
}

/* ===== BUTTONS ===== */
.btn-primary {
  display: inline-block;
  background: var(--accent);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  padding: 14px 32px;
  border-radius: 40px;
  transition: background 0.2s, transform 0.15s;
  white-space: nowrap;
}
.btn-primary:hover { background: var(--accent-h); transform: translateY(-1px); }

/* ===== SECTION LABELS ===== */
.section-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.06em;
  margin-bottom: 36px;
}
.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
  flex-shrink: 0;
}

/* ===== FILTERS ===== */
.works-section {
  padding: 0 0 80px;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 48px;
}

.filter-btn {
  font-size: 14px;
  font-weight: 500;
  padding: 9px 20px;
  border-radius: 24px;
  border: 1px solid var(--border);
  color: var(--muted);
  background: transparent;
  transition: all 0.2s;
  white-space: nowrap;
}
.filter-btn:hover { color: var(--text); border-color: #444; }
.filter-btn.active { background: var(--text); color: var(--bg); border-color: var(--text); }

/* ===== WORKS GRID ===== */
.works-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.work-card {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  cursor: pointer;
  aspect-ratio: 16/10;
}
.work-card:hover .work-overlay { opacity: 1; }
.work-card:hover .work-thumb { transform: scale(1.04); }

.work-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.work-thumb-placeholder {
  width: 100%;
  height: 100%;
  background: var(--surface-2);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  font-size: 40px;
}

.work-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.75);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  opacity: 0;
  transition: opacity 0.3s;
}

.work-play {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.7);
  display: flex;
  align-items: center;
  justify-content: center;
}
.work-play::after {
  content: '';
  display: block;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 8px 0 8px 16px;
  border-color: transparent transparent transparent rgba(255,255,255,0.9);
  margin-left: 4px;
}

.work-overlay-title {
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  padding: 0 16px;
  max-width: 240px;
}

.work-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 4px 10px;
  border-radius: 12px;
  background: rgba(0,0,0,0.7);
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.8);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

/* ===== ABOUT ===== */
.about-section {
  padding: 80px 0;
  border-top: 1px solid var(--border);
}

.about-layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 64px;
  align-items: start;
}

.about-blocks {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.about-block {
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
  line-height: 1.7;
  color: rgba(255,255,255,0.85);
}
.about-block:first-child { padding-top: 0; }

.about-brand {
  font-size: 18px;
  font-weight: 700;
  color: var(--text);
  padding: 20px 0;
  letter-spacing: 0.06em;
}

.about-photo {
  position: sticky;
  top: calc(var(--nav-h) + 24px);
}

.about-photo img {
  width: 100%;
  border-radius: var(--radius);
  object-fit: cover;
  aspect-ratio: 3/4;
}

.about-photo-caption {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-top: 16px;
}
.about-photo-name {
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.about-photo-role {
  font-size: 13px;
  font-weight: 500;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ===== CONTACTS ===== */
.contacts-section {
  padding: 80px 0 60px;
  border-top: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.contacts-row {
  display: flex;
  gap: 80px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.contacts-left, .contacts-right {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.contact-link {
  font-size: 22px;
  font-weight: 600;
  transition: color 0.2s;
}
.contact-link:hover { color: var(--accent); }

.social-link {
  font-size: 16px;
  font-weight: 500;
  color: var(--muted);
  transition: color 0.2s;
}
.social-link:hover { color: var(--text); }

.contacts-watermark {
  position: absolute;
  bottom: -40px;
  right: -20px;
  font-size: clamp(80px, 16vw, 180px);
  font-weight: 900;
  color: transparent;
  -webkit-text-stroke: 1px rgba(255,255,255,0.04);
  white-space: nowrap;
  pointer-events: none;
  letter-spacing: -0.04em;
  -webkit-user-select: none;
  user-select: none;
}

/* ===== FOOTER ===== */
.footer {
  border-top: 1px solid var(--border);
  padding: 24px 0;
}

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

.footer-copy {
  font-size: 13px;
  color: var(--muted);
}

.footer-admin {
  font-size: 12px;
  color: #333;
  transition: color 0.2s;
}
.footer-admin:hover { color: var(--muted); }

/* ===== MODAL ===== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.modal.open {
  opacity: 1;
  pointer-events: all;
}

.modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.9);
}

.modal-box {
  position: relative;
  width: 100%;
  max-width: 1000px;
  background: var(--surface);
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 320px;
  transform: scale(0.96);
  transition: transform 0.3s;
}
.modal.open .modal-box { transform: scale(1); }

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(0,0,0,0.6);
  color: #fff;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}
.modal-close:hover { background: rgba(255,255,255,0.15); }

.modal-video-wrap {
  position: relative;
  background: #000;
  aspect-ratio: 16/9;
  align-self: center;
}

.modal-video {
  position: absolute;
  inset: 0;
}

.modal-video iframe,
.modal-video video {
  width: 100%;
  height: 100%;
  border: none;
  object-fit: contain;
  background: #000;
}

/* Спиннер загрузки видео */
.modal-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 44px;
  height: 44px;
  margin: -22px 0 0 -22px;
  border: 3px solid rgba(255,255,255,0.15);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: modal-spin 0.8s linear infinite;
  z-index: 1;
}
@keyframes modal-spin { to { transform: rotate(360deg); } }

/* Вертикальный режим для рилсов */
.modal-box.modal-vertical {
  max-width: 760px;
}
.modal-box.modal-vertical .modal-video-wrap {
  aspect-ratio: 9/16;
  max-height: 82vh;
}

.modal-no-video {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
  padding: 24px;
}

.modal-info {
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
}

.modal-cat {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent);
}

.modal-title {
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
}

.modal-desc-label {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-top: 8px;
}

.modal-desc {
  font-size: 14px;
  line-height: 1.7;
  color: rgba(255,255,255,0.75);
}

/* ===== EMPTY STATE ===== */
.works-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 80px 0;
  color: var(--muted);
  font-size: 16px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 960px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .hero-left { align-items: center; text-align: center; }
  .hero-right { max-width: 480px; margin: 0 auto; width: 100%; }
}

@media (max-width: 900px) {
  .works-grid { grid-template-columns: repeat(2, 1fr); }
  .about-layout { grid-template-columns: 1fr; }
  .about-photo { position: static; order: -1; max-width: 280px; }
  .modal-box { grid-template-columns: 1fr; }
  .modal-video-wrap { aspect-ratio: 16/9; }
  .modal-info { padding: 24px; }
}

@media (max-width: 640px) {
  .works-grid { grid-template-columns: 1fr; }
  .nav-links, .nav-phone { display: none; }
  .nav-burger { display: flex; }
  .contacts-row { gap: 32px; }
  .contact-link { font-size: 18px; }
  .hero-title { font-size: clamp(56px, 14vw, 120px); }
  .hero-right { display: none; }
}