/* ==========================================================================
   NULLUM Studio — Cinema 3D & Creative Technology Layer
   GPU-accelerated spatial depth, volumetric lighting, interactive 3D Lab
   ========================================================================== */

:root {
  --cinema-obsidian: #07060b;
  --cinema-surface: rgba(18, 15, 28, 0.72);
  --cinema-surface-strong: rgba(22, 18, 35, 0.9);
  --cinema-border: rgba(255, 255, 255, 0.11);
  --cinema-border-bright: rgba(207, 190, 255, 0.42);
  --cinema-lilac: #d4c0ff;
  --cinema-cyan: #7be3ff;
  --cinema-glow: rgba(154, 114, 255, 0.24);
  --cinema-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

/* Global obsidian stage + subtle film/viewport atmosphere */
body {
  background:
    radial-gradient(ellipse 80% 55% at 72% -8%, rgba(114, 68, 226, 0.24), transparent 62%),
    radial-gradient(ellipse 55% 40% at 15% 18%, rgba(56, 156, 214, 0.12), transparent 60%),
    var(--cinema-obsidian) !important;
  position: relative;
}

/* Subtle perspective 3D grid behind hero */
.studio-hero,
.landing-hero {
  position: relative;
  isolation: isolate;
}

.studio-hero::before,
.landing-hero::before {
  content: "";
  position: absolute;
  inset: -4rem -10vw 0;
  z-index: -2;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(207, 190, 255, 0.055) 1px, transparent 1px),
    linear-gradient(90deg, rgba(207, 190, 255, 0.055) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 75% 65% at 50% 28%, #000 10%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 75% 65% at 50% 28%, #000 10%, transparent 78%);
}

/* Ambient 3D depth particle canvas */
.cinema-particles {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  opacity: 0.72;
}

/* Luminous scroll progress hairline under fixed header */
.cinema-progress {
  position: fixed;
  top: var(--studio-header, 72px);
  left: 0;
  right: 0;
  height: 2px;
  z-index: 65;
  pointer-events: none;
  background: transparent;
}
.cinema-progress span {
  display: block;
  height: 100%;
  width: 100%;
  transform-origin: 0 50%;
  transform: scaleX(0);
  background: linear-gradient(90deg, #8e63ff 0%, #d4c0ff 55%, #7be3ff 100%);
  box-shadow: 0 0 12px rgba(123, 227, 255, 0.75);
}

/* Header glass & luminous brand treatment */
.studio-header,
.landing-head {
  background: rgba(7, 6, 11, 0.78) !important;
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* Metallic chrome-lilac typography highlight on Hero H1 */
.studio-hero h1,
.landing-hero h1 {
  background: linear-gradient(180deg, #ffffff 18%, #e4dcff 72%, #b8a3f5 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.landing-hero h1 span {
  background: linear-gradient(120deg, var(--accent) 0%, #ffffff 55%, #7be3ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* High-tech telemetry kicker pill */
.studio-hero-kicker,
.landing-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  width: fit-content;
  padding: 0.38rem 0.85rem;
  border-radius: 999px;
  border: 1px solid rgba(207, 190, 255, 0.28);
  background: rgba(207, 190, 255, 0.08);
  font-family: var(--cinema-mono);
  font-size: 0.74rem !important;
  letter-spacing: 0.08em !important;
  box-shadow: 0 0 24px rgba(154, 114, 255, 0.18);
}

.studio-hero-kicker::before,
.landing-kicker::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7cf2b4;
  box-shadow: 0 0 10px #7cf2b4;
  animation: cinema-pulse 2.2s ease-in-out infinite;
}

@keyframes cinema-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.85); }
}

/* Primary CTA shimmer + glow */
.studio-button,
.landing-cta:not(.landing-whatsapp),
.quote-widget .quote-submit {
  position: relative;
  overflow: hidden;
  background: linear-gradient(135deg, #e5d8ff 0%, #c8b0ff 55%, #b196ff 100%);
  box-shadow: 0 8px 28px rgba(157, 117, 255, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.65);
  transition: transform 0.2s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.25s ease, filter 0.2s ease;
}

.studio-button:hover,
.landing-cta:not(.landing-whatsapp):hover,
.quote-widget .quote-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 34px rgba(164, 126, 255, 0.46), 0 0 18px rgba(123, 227, 255, 0.22);
  filter: brightness(1.04);
}

.studio-button-ghost {
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(8px);
  transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.studio-button-ghost:hover {
  transform: translateY(-2px);
  background: rgba(207, 190, 255, 0.09);
}

/* ---------- 3D INTERACTIVE ORB PARALLAX & SPECULAR RIM ---------- */
.nullum-orb-home {
  perspective: 1100px;
}

.nullum-orb-visual {
  transform-style: preserve-3d;
  border: 1px solid rgba(212, 192, 255, 0.34) !important;
  border-radius: 1.15rem !important;
  box-shadow:
    0 28px 80px rgba(0, 0, 0, 0.68),
    0 0 0 1px rgba(123, 227, 255, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.22);
  transition: transform 0.18s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.3s ease;
  will-change: transform;
}

.nullum-orb-visual::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(123, 227, 255, 0.18), rgba(212, 192, 255, 0.08) 40%, transparent 70%);
  transition: opacity 0.25s ease;
}
.nullum-orb-visual:hover::before { opacity: 1; }

.nullum-orb-visual::after {
  content: "NULLUM // PORTAL 3D · INTERACTIVO";
  position: absolute;
  top: 0.9rem;
  left: 1rem;
  z-index: 4;
  font-family: var(--cinema-mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: rgba(235, 226, 255, 0.72);
  padding: 0.28rem 0.58rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(9, 8, 15, 0.62);
  backdrop-filter: blur(8px);
  pointer-events: none;
}

.nullum-orb-frame {
  transform: translate3d(var(--orb-dx, 0px), var(--orb-dy, 0px), 34px);
}

.nullum-orb-open span {
  border-color: rgba(212, 192, 255, 0.62) !important;
  box-shadow: 0 0 26px rgba(145, 108, 255, 0.36);
  backdrop-filter: blur(10px);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.nullum-orb-open:hover span {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 0 34px rgba(123, 227, 255, 0.45);
}

/* ---------- CINEMA VIEWPORT FRAME ON REEL ---------- */
.studio-reel {
  border-radius: 1.1rem;
  border: 1px solid rgba(212, 192, 255, 0.25);
  box-shadow:
    0 32px 90px rgba(0, 0, 0, 0.72),
    0 0 42px rgba(126, 86, 240, 0.14) !important;
}
.studio-reel::after {
  content: "ACEScg · 24 FPS · CGI REEL";
  position: absolute;
  top: 0.85rem;
  right: 0.9rem;
  z-index: 2;
  padding: 0.3rem 0.6rem;
  border-radius: 0.3rem;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(9, 8, 15, 0.74);
  backdrop-filter: blur(8px);
  font-family: var(--cinema-mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  color: rgba(240, 234, 255, 0.85);
  pointer-events: none;
}
.studio-playing.studio-reel::after { opacity: 0.35; }

/* ---------- SEAMLESS BRAND MARQUEE ---------- */
.studio-trust-bar {
  overflow: hidden;
  border-block: 1px solid rgba(255, 255, 255, 0.1) !important;
  background: linear-gradient(90deg, rgba(207, 190, 255, 0.03), rgba(123, 227, 255, 0.04), rgba(207, 190, 255, 0.03));
  padding: 1.1rem 1.25rem !important;
  border-radius: 0.9rem;
}

.studio-brand-marquee {
  flex: 1 1 32rem;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}

.studio-brand-track {
  display: flex;
  align-items: center;
  gap: 2.4rem;
  width: max-content;
  margin: 0;
  padding: 0;
  list-style: none;
  animation: cinema-marquee 26s linear infinite;
}
.studio-brand-marquee:hover .studio-brand-track { animation-play-state: paused; }

.studio-brand-track li {
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(248, 246, 255, 0.78);
  white-space: nowrap;
}
.studio-brand-track li::after {
  content: "◆";
  margin-left: 2.4rem;
  font-size: 0.55rem;
  vertical-align: middle;
  color: rgba(207, 190, 255, 0.45);
}

@keyframes cinema-marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- CONTINUOUS DARK OBSIDIAN EDITORIAL (Replaces jarring light bands) ---------- */
.studio-light,
.landing-light {
  background:
    radial-gradient(ellipse 70% 45% at 50% 0%, rgba(132, 86, 246, 0.11), transparent 70%),
    linear-gradient(180deg, #0c0a14 0%, #090810 100%) !important;
  color: #f8f6ff !important;
  color-scheme: dark !important;
  border-block: 1px solid rgba(255, 255, 255, 0.08);
}

.studio-light p,
.landing-light .landing-intro,
.landing-work .landing-credit {
  color: #b7b1ca !important;
}

.studio-work-card {
  position: relative;
  padding: 1rem;
  border-radius: 1rem;
  background: var(--cinema-surface);
  border: 1px solid var(--cinema-border);
  transition: transform 0.25s cubic-bezier(0.2, 0.8, 0.2, 1), border-color 0.25s ease, box-shadow 0.25s ease;
}

.studio-work-card::before,
.landing-deliverable::before,
.cinema-spec-card::before,
.studio-process li::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
  background: radial-gradient(360px circle at var(--spot-x, 50%) var(--spot-y, 50%), rgba(207, 190, 255, 0.14), transparent 65%);
  transition: opacity 0.25s ease;
}

.studio-work-card:hover,
.landing-deliverable:hover,
.cinema-spec-card:hover {
  transform: translateY(-4px);
  border-color: var(--cinema-border-bright);
  box-shadow: 0 22px 54px rgba(0, 0, 0, 0.55), 0 0 28px rgba(154, 114, 255, 0.12);
}

.studio-work-card:hover::before,
.landing-deliverable:hover::before,
.cinema-spec-card:hover::before {
  opacity: 1;
}

.studio-project-video,
.studio-work-image {
  border-radius: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.studio-work-card h3 a { color: #f8f6ff; }
.studio-work-card h3 a:hover { color: var(--cinema-lilac); }
.studio-work-quote { color: var(--cinema-cyan) !important; }
.studio-work-credits { color: #b7b1ca !important; }

.landing-work .landing-film {
  background: var(--cinema-surface) !important;
  color: #f8f6ff !important;
  border-color: var(--cinema-border) !important;
}

.studio-process li {
  position: relative;
  padding: 1.5rem;
  border-radius: 1rem;
  border: 1px solid var(--cinema-border);
  background: var(--cinema-surface);
  list-style-position: inside;
}
.studio-process li::marker { color: var(--cinema-cyan) !important; }
.studio-process { padding-inline-start: 0 !important; }

.studio-faq-list details {
  border-color: rgba(255, 255, 255, 0.14) !important;
}
.studio-faq-list summary { color: #f8f6ff !important; }
.studio-faq-list summary::after { color: var(--cinema-lilac) !important; }

/* ---------- SIGNATURE INTERACTIVE 3D LAB (WIREFRAME ↔ FINAL RENDER) ---------- */
.cinema-lab {
  position: relative;
  padding-block: clamp(3.5rem, 7vw, 6.8rem);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(ellipse 60% 50% at 85% 30%, rgba(123, 227, 255, 0.09), transparent 65%),
    radial-gradient(ellipse 55% 45% at 12% 70%, rgba(145, 96, 255, 0.13), transparent 65%);
}

.cinema-lab-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.4rem 2.5rem;
  margin-bottom: clamp(1.8rem, 3.6vw, 3rem);
}

.cinema-lab-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.85rem;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  border: 1px solid rgba(123, 227, 255, 0.35);
  background: rgba(123, 227, 255, 0.08);
  color: var(--cinema-cyan);
  font-family: var(--cinema-mono);
  font-size: 0.74rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.cinema-lab-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.cinema-lab-tab {
  min-height: 44px;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--cinema-border);
  background: rgba(255, 255, 255, 0.03);
  color: #c5bfd8;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: 0.2s ease;
}

.cinema-lab-tab[aria-pressed="true"],
.cinema-lab-tab:hover {
  border-color: var(--cinema-lilac);
  background: rgba(207, 190, 255, 0.16);
  color: #ffffff;
}

.cinema-lab-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.32fr) minmax(0, 0.88fr);
  gap: clamp(1.4rem, 3.2vw, 3rem);
  align-items: center;
}

.cinema-compare {
  position: relative;
  border-radius: 1.15rem;
  overflow: hidden;
  border: 1px solid rgba(212, 192, 255, 0.3);
  background: #0d0b14;
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.65), 0 0 36px rgba(145, 96, 255, 0.15);
  user-select: none;
  touch-action: pan-y;
}

.cinema-compare-stage {
  position: relative;
  aspect-ratio: 4 / 3;
  width: 100%;
  overflow: hidden;
  --split: 50%;
}

.cinema-compare-stage img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 22%;
  display: block;
  pointer-events: none;
}

.cinema-compare-after {
  clip-path: inset(0 0 0 var(--split));
}

.cinema-compare-line {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--split);
  width: 2px;
  background: linear-gradient(180deg, #7be3ff, #ffffff, #d4c0ff);
  box-shadow: 0 0 18px rgba(123, 227, 255, 0.9);
  pointer-events: none;
  z-index: 3;
}

.cinema-compare-handle {
  position: absolute;
  top: 50%;
  left: var(--split);
  transform: translate(-50%, -50%);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 2px solid #ffffff;
  background: rgba(11, 9, 18, 0.85);
  backdrop-filter: blur(10px);
  color: #ffffff;
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.92rem;
  letter-spacing: 0.05em;
  box-shadow: 0 0 26px rgba(123, 227, 255, 0.55);
  pointer-events: none;
  z-index: 4;
}

.cinema-compare-range {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: ew-resize;
  z-index: 5;
}

.cinema-compare-badges {
  position: absolute;
  inset: auto 0.9rem 0.9rem;
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
  pointer-events: none;
  z-index: 4;
}

.cinema-compare-badges span {
  padding: 0.34rem 0.68rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(8, 7, 14, 0.78);
  backdrop-filter: blur(8px);
  font-family: var(--cinema-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #f8f6ff;
}

.cinema-compare-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.75rem 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(10, 9, 16, 0.92);
  font-family: var(--cinema-mono);
  font-size: 0.74rem;
  color: #bcb6cf;
}

.cinema-presets {
  display: flex;
  gap: 0.4rem;
}

.cinema-presets button {
  padding: 0.35rem 0.65rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.04);
  color: #e9e4fa;
  font-family: inherit;
  font-size: 0.72rem;
  cursor: pointer;
}
.cinema-presets button:hover {
  border-color: var(--cinema-cyan);
  color: #ffffff;
}

.cinema-lab-info {
  display: grid;
  gap: 1.15rem;
}

.cinema-lab-info h3 {
  font-size: clamp(1.6rem, 2.8vw, 2.3rem);
  line-height: 1.05;
}

.cinema-lab-info > p {
  color: #bfb9d4;
}

.cinema-specs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.cinema-spec-card {
  position: relative;
  padding: 1rem 1.05rem;
  border-radius: 0.85rem;
  border: 1px solid var(--cinema-border);
  background: var(--cinema-surface);
  transition: transform 0.22s ease, border-color 0.22s ease;
}

.cinema-spec-card small {
  display: block;
  font-family: var(--cinema-mono);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--cinema-cyan);
  margin-bottom: 0.3rem;
}

.cinema-spec-card strong {
  display: block;
  font-size: 0.98rem;
  color: #ffffff;
}

.cinema-pipeline-stack {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.cinema-pipeline-stack span {
  padding: 0.34rem 0.68rem;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: rgba(255, 255, 255, 0.035);
  font-family: var(--cinema-mono);
  font-size: 0.75rem;
  color: #d8d2ec;
}

/* ---------- SERVICES LIST TECH POLISH ---------- */
.studio-service-list a {
  position: relative;
  padding: 1.6rem 1.25rem !important;
  margin-bottom: 0.65rem;
  border: 1px solid var(--cinema-border) !important;
  border-radius: 0.95rem;
  background: var(--cinema-surface);
  transition: transform 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}
.studio-service-list a:hover {
  transform: translateX(6px);
  border-color: var(--cinema-border-bright) !important;
  background: rgba(26, 21, 42, 0.92);
}

/* Quote widget glass elevation */
.quote-widget {
  background: linear-gradient(165deg, rgba(22, 18, 36, 0.92) 0%, rgba(12, 11, 18, 0.96) 100%) !important;
  border: 1px solid rgba(212, 192, 255, 0.26) !important;
  box-shadow: 0 26px 70px rgba(0, 0, 0, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.landing-deliverable {
  position: relative;
  background: var(--cinema-surface) !important;
  border-color: var(--cinema-border) !important;
  transition: transform 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

/* ---------- CHOREOGRAPHED SCROLL REVEAL ---------- */
html.cinema-ready [data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.65s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.65s cubic-bezier(0.2, 0.8, 0.2, 1);
}
html.cinema-ready [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

@media (max-width: 58rem) {
  .cinema-lab-grid { grid-template-columns: 1fr; }
}

@media (max-width: 40rem) {
  .cinema-specs { grid-template-columns: 1fr; }
  .studio-reel::after { display: none; }
  .nullum-orb-visual::after { font-size: 0.62rem; }
}

@media (prefers-reduced-motion: reduce) {
  .cinema-particles { display: none; }
  .studio-brand-track { animation: none; }
  .studio-hero-kicker::before, .landing-kicker::before { animation: none; }
  html.cinema-ready [data-reveal] { opacity: 1; transform: none; transition: none; }
  .nullum-orb-visual { transform: none !important; }
}
