/* вынесен из inline-<style> страницы gallery.html (SEC-11: style-src без unsafe-inline) */
    * { box-sizing: border-box; }
    body { background: #07050d; color: #f4f1ff; margin: 0; min-height: 100vh; overflow-x: hidden; }
    .container { max-width: 1320px; margin: 0 auto; padding: 0 24px; }

    /* HEADER */
    .nv-header {
      position: sticky; top: 0; z-index: 100;
      background: rgba(7,5,13,0.78);
      backdrop-filter: blur(24px) saturate(180%);
      -webkit-backdrop-filter: blur(24px) saturate(180%);
      border-bottom: 1px solid rgba(167,139,255,0.08);
      padding: 16px 0;
    }
    .nv-header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
    .nv-logo {
      display: inline-flex; align-items: center; gap: 10px;
      font-weight: 800; font-size: 1.05rem; letter-spacing: -0.01em;
      text-decoration: none; color: #fff;
    }
    .nv-logo-mark {
      width: 32px; height: 32px; border-radius: 9px;
      background: linear-gradient(135deg, #8b5cff 0%, #ff3ec9 100%);
      display: flex; align-items: center; justify-content: center;
      font-weight: 900; color: #fff; font-size: 0.92rem;
      box-shadow: 0 4px 14px rgba(139,92,255,0.45);
    }
    .nv-nav { display: flex; gap: 28px; font-size: 0.88rem; font-weight: 500; }
    .nv-nav a {
      color: rgba(244,241,255,0.65); text-decoration: none;
      transition: color 0.15s; position: relative;
    }
    .nv-nav a.active, .nv-nav a:hover { color: #fff; }
    .nv-nav a.active::after, .nv-nav a:hover::after {
      content: ''; position: absolute; left: 0; right: 0; bottom: -6px; height: 2px;
      background: linear-gradient(90deg, #8b5cff, #ff3ec9);
    }
    @media (max-width: 880px) { .nv-nav { display: none; } }
    .nv-cta-mini {
      padding: 10px 20px;
      background: linear-gradient(135deg, #8b5cff 0%, #ff3ec9 100%);
      color: #fff; border-radius: 11px; font-weight: 700; font-size: 0.86rem;
      text-decoration: none; transition: transform 0.15s, box-shadow 0.25s;
      box-shadow: 0 4px 16px rgba(139,92,255,0.35);
      display: inline-flex; align-items: center; gap: 8px;
    }
    .nv-cta-mini:hover { transform: translateY(-1px); box-shadow: 0 8px 24px rgba(139,92,255,0.5); }

    /* PAGE HEAD */
    .page-head { padding: 60px 0 30px; text-align: center; position: relative; }
    .page-head::before {
      content: ''; position: absolute; top: 0; left: 50%;
      transform: translateX(-50%);
      width: 900px; height: 350px;
      background:
        radial-gradient(ellipse 400px 250px at 30% 50%, rgba(0,229,255,0.2) 0%, transparent 70%),
        radial-gradient(ellipse 400px 250px at 70% 50%, rgba(255,62,201,0.18) 0%, transparent 70%);
      pointer-events: none; z-index: 0;
    }
    .page-head-inner { position: relative; z-index: 1; }
    .page-eyebrow {
      display: inline-block; padding: 6px 16px;
      background: rgba(0,229,255,0.1);
      border: 1px solid rgba(0,229,255,0.3);
      border-radius: 99px;
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.7rem; font-weight: 700;
      letter-spacing: 0.16em; text-transform: uppercase;
      color: #00e5ff; margin-bottom: 22px;
    }
    .page-title {
      font-size: clamp(2rem, 4.2vw, 3rem);
      font-weight: 800; letter-spacing: -0.025em;
      margin: 0 0 14px; line-height: 1.1;
    }
    .page-title .grad {
      background: linear-gradient(135deg, #00e5ff, #a78bff, #ff3ec9);
      -webkit-background-clip: text; background-clip: text; color: transparent;
    }
    .page-sub {
      font-size: 1.02rem; color: rgba(244,241,255,0.6);
      max-width: 620px; margin: 0 auto;
      line-height: 1.55;
    }

    /* FILTERS */
    .filters {
      padding: 22px 0;
      position: sticky; top: 64px; z-index: 50;
      background: rgba(7,5,13,0.85);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      border-bottom: 1px solid rgba(167,139,255,0.08);
    }
    .filters-inner { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
    .filter-group { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
    .filter-label {
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.66rem; font-weight: 700;
      letter-spacing: 0.16em; text-transform: uppercase;
      color: rgba(244,241,255,0.4);
      margin-right: 6px;
    }
    .filter-chip {
      padding: 7px 14px;
      background: rgba(244,241,255,0.04);
      border: 1px solid rgba(167,139,255,0.18);
      border-radius: 99px;
      font-size: 0.82rem; font-weight: 600;
      color: rgba(244,241,255,0.7);
      cursor: pointer; transition: all 0.15s;
      white-space: nowrap;
    }
    .filter-chip:hover { background: rgba(167,139,255,0.12); color: #fff; }
    .filter-chip.active {
      background: linear-gradient(135deg, #00e5ff, #8b5cff);
      border-color: transparent;
      color: #07050d;
      font-weight: 800;
      box-shadow: 0 4px 14px rgba(0,229,255,0.3);
    }
    .filter-count {
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.78rem; color: rgba(244,241,255,0.5);
      margin-left: auto;
    }

    /* PINTEREST-STYLE MASONRY */
    .gallery { padding: 40px 0 80px; }
    .gallery-masonry {
      column-count: 4;
      column-gap: 16px;
    }
    @media (max-width: 1100px) { .gallery-masonry { column-count: 3; } }
    @media (max-width: 720px)  { .gallery-masonry { column-count: 2; column-gap: 10px; } }
    @media (max-width: 420px)  { .gallery-masonry { column-count: 1; } }

    .gallery-item {
      display: block;
      width: 100%;
      margin-bottom: 16px;
      break-inside: avoid;
      position: relative;
      border-radius: 16px;
      overflow: hidden;
      cursor: pointer;
      background: #0d0a18;
      border: 1px solid rgba(167,139,255,0.1);
      transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
      text-decoration: none;
    }
    .gallery-item:hover {
      transform: translateY(-4px);
      border-color: rgba(0,229,255,0.4);
      box-shadow: 0 20px 40px rgba(0,229,255,0.15);
    }
    .gallery-item img {
      width: 100%; height: auto;
      display: block;
      transition: transform 0.5s;
    }
    .gallery-item:hover img {
      transform: scale(1.04);
    }

    .gallery-item-overlay {
      position: absolute;
      inset: 0;
      background: linear-gradient(to top, rgba(7,5,13,0.95) 0%, rgba(7,5,13,0.3) 40%, transparent 70%);
      opacity: 0;
      transition: opacity 0.25s;
      display: flex;
      flex-direction: column;
      justify-content: flex-end;
      padding: 20px;
      z-index: 2;
    }
    .gallery-item:hover .gallery-item-overlay { opacity: 1; }
    @media (hover: none) {
      .gallery-item-overlay { opacity: 1; }
    }

    .gallery-item-film {
      font-family: 'JetBrains Mono', monospace;
      font-size: 0.66rem; font-weight: 800;
      letter-spacing: 0.16em; text-transform: uppercase;
      color: #00e5ff;
      margin-bottom: 4px;
    }
    .gallery-item-title {
      font-size: 0.95rem; font-weight: 800;
      color: #fff; letter-spacing: -0.01em;
      margin-bottom: 12px;
    }
    .gallery-item-try {
      display: inline-flex;
      align-items: center;
      gap: 6px;
      padding: 8px 14px;
      background: linear-gradient(135deg, #00e5ff, #8b5cff);
      color: #07050d;
      border-radius: 99px;
      font-size: 0.78rem;
      font-weight: 800;
      letter-spacing: 0.01em;
      box-shadow: 0 4px 14px rgba(0,229,255,0.3);
      width: fit-content;
    }

    .gallery-empty {
      padding: 100px 30px;
      text-align: center;
      color: rgba(244,241,255,0.5);
      grid-column: 1 / -1;
    }
    .gallery-empty-icon {
      width: 80px; height: 80px;
      border-radius: 50%;
      background: rgba(0,229,255,0.08);
      border: 1px solid rgba(0,229,255,0.2);
      display: inline-flex; align-items: center; justify-content: center;
      font-size: 2.4rem;
      margin-bottom: 22px;
    }
    .gallery-empty-title {
      font-size: 1.3rem; font-weight: 800;
      color: #fff;
      margin-bottom: 10px;
    }
    .gallery-empty-text {
      font-size: 0.95rem;
      line-height: 1.55;
      max-width: 480px;
      margin: 0 auto 26px;
    }
    .gallery-empty-cta {
      display: inline-flex;
      align-items: center; gap: 10px;
      padding: 14px 30px;
      background: linear-gradient(135deg, #8b5cff, #ff3ec9);
      color: #fff;
      border-radius: 13px;
      font-weight: 800;
      font-size: 0.94rem;
      text-decoration: none;
      box-shadow: 0 10px 28px rgba(139,92,255,0.4);
      transition: transform 0.15s, box-shadow 0.25s;
    }
    .gallery-empty-cta:hover {
      transform: translateY(-2px);
      box-shadow: 0 14px 36px rgba(139,92,255,0.55);
    }

    /* Skeleton during load */
    .gallery-skeleton {
      width: 100%;
      margin-bottom: 16px;
      break-inside: avoid;
      border-radius: 16px;
      background: linear-gradient(90deg,
        rgba(167,139,255,0.04) 0%,
        rgba(167,139,255,0.1) 50%,
        rgba(167,139,255,0.04) 100%);
      background-size: 200% 100%;
      animation: shimmer 1.6s ease-in-out infinite;
    }
    @keyframes shimmer {
      0%   { background-position: -200% 0; }
      100% { background-position: 200% 0; }
    }

    /* LIGHTBOX */
    .lightbox {
      position: fixed; inset: 0;
      background: rgba(7,5,13,0.94);
      backdrop-filter: blur(20px);
      -webkit-backdrop-filter: blur(20px);
      z-index: 200; display: none;
      align-items: center; justify-content: center;
      padding: 24px;
    }
    .lightbox.visible { display: flex; }
    .lightbox-content {
      max-width: 1100px;
      max-height: 92vh;
      position: relative;
      display: flex;
      flex-direction: column;
      gap: 16px;
    }
    .lightbox-media {
      max-height: 78vh;
      border-radius: 18px;
      overflow: hidden;
      border: 1px solid rgba(167,139,255,0.2);
      box-shadow: 0 40px 100px rgba(0,0,0,0.7);
    }
    .lightbox-media img {
      max-width: 100%;
      max-height: 78vh;
      display: block;
    }
    .lightbox-actions {
      display: flex;
      gap: 12px;
      justify-content: center;
      flex-wrap: wrap;
    }
    .lightbox-btn {
      padding: 12px 24px;
      background: linear-gradient(135deg, #8b5cff, #ff3ec9);
      color: #fff;
      border: none;
      border-radius: 12px;
      font-weight: 800;
      font-size: 0.92rem;
      text-decoration: none;
      cursor: pointer;
      display: inline-flex; align-items: center; gap: 8px;
      box-shadow: 0 8px 24px rgba(139,92,255,0.4);
      transition: transform 0.15s, box-shadow 0.25s;
    }
    .lightbox-btn:hover {
      transform: translateY(-1px);
      box-shadow: 0 12px 32px rgba(139,92,255,0.55);
    }
    .lightbox-btn-ghost {
      background: rgba(244,241,255,0.06);
      border: 1px solid rgba(167,139,255,0.25);
      box-shadow: none;
    }
    .lightbox-btn-ghost:hover {
      background: rgba(167,139,255,0.12);
      border-color: rgba(167,139,255,0.5);
    }
    .lightbox-close {
      position: absolute;
      top: -50px; right: 0;
      width: 40px; height: 40px;
      border-radius: 50%;
      background: rgba(244,241,255,0.08);
      border: 1px solid rgba(167,139,255,0.25);
      color: #fff;
      font-size: 1.2rem;
      cursor: pointer;
      display: flex; align-items: center; justify-content: center;
      transition: background 0.15s, transform 0.15s;
    }
    .lightbox-close:hover {
      background: rgba(255,62,201,0.2);
      transform: rotate(90deg);
    }

    /* FOOTER */
    .nv-footer {
      padding: 40px 0 30px;
      border-top: 1px solid rgba(167,139,255,0.08);
      font-size: 0.86rem; color: rgba(244,241,255,0.4);
    }
    .nv-footer-inner {
      display: flex; flex-wrap: wrap; gap: 24px;
      justify-content: space-between; align-items: center;
    }
    .nv-footer-links { display: flex; gap: 22px; }
    .nv-footer-links a {
      color: rgba(244,241,255,0.55); text-decoration: none;
      transition: color 0.15s;
    }
    .nv-footer-links a:hover { color: #fff; }
  
