/* ==========================================================================
   PALS GATEWAY — Landing Page Styles
   Scoped to body.pals-gateway to avoid collisions.
   ========================================================================== */

body.pals-gateway {
  --gw-black: #000000;
  --gw-white: #ffffff;
  --gw-accent-consult: #f4f100; /* overridden inline from theme.json */
  --gw-accent-studio: #fc0d1c;  /* overridden inline from theme.json */
  --gw-font-display: "HelveticaNowDisplayCondensedExtraBlack", ui-sans-serif, system-ui;
  --gw-font-body: "Helvetica Now Var", ui-sans-serif, system-ui;
}

body.pals-gateway,
body.pals-gateway *,
body.pals-gateway *::before,
body.pals-gateway *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body.pals-gateway {
  height: 100vh;
  overflow: hidden;
  background: var(--gw-black);
  color: var(--gw-white);
  font-family: var(--gw-font-body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ==========================================================================
   LOADER
   ========================================================================== */
.gw-loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: var(--gw-black);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s ease, visibility 0.6s ease;
}

.gw-loader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.gw-logo {
  width: auto;
  height: 40px;
  max-width: 60vw;
  animation: gwPulse 1.4s ease-in-out infinite;
}

.gw-logo-fallback {
  font-family: var(--gw-font-display);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  opacity: 0.75;
}

@keyframes gwPulse {
  0%,
  100% {
    opacity: 0.4;
    transform: scale(0.95);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

/* ==========================================================================
   GRAIN OVERLAY
   ========================================================================== */
.gw-grain {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 200px;
}

/* ==========================================================================
   TOP BAR
   ========================================================================== */
.gw-topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px 40px;
  opacity: 0;
  animation: gwFadeDown 0.8s ease 0.8s forwards;
}

.pals-gateway .gw-topbar {
  padding: 28px 40px;
}

.gw-topbar .gw-logo {
  height: 28px;
  animation: none;
}

@keyframes gwFadeDown {
  to {
    opacity: 1;
  }
}

/* ==========================================================================
   SPLIT LAYOUT — always horizontal (left / right)
   ========================================================================== */
.gw-split {
  display: flex;
  flex-direction: row !important;
  height: 100vh;
  width: 100%;
  position: relative;
}

.gw-panel {
  flex: 1;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 28px;
  cursor: pointer;
  overflow: hidden;
  transition: flex 0.7s cubic-bezier(0.65, 0, 0.35, 1);
  outline: none;
}

.gw-panel:focus-visible {
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.35);
}

.gw-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  z-index: 10;
  transition: opacity 0.5s ease;
}

.gw-split.is-hovered .gw-divider {
  opacity: 0;
}

.gw-divider::before {
  content: "";
  position: absolute;
  top: 12%;
  bottom: 12%;
  left: 0;
  width: 1px;
  background: linear-gradient(
    to bottom,
    transparent,
    rgba(240, 239, 233, 0.15) 30%,
    rgba(240, 239, 233, 0.15) 70%,
    transparent
  );
}

.gw-split.is-hover-left .gw-panel--consult {
  flex: 1.4;
}
.gw-split.is-hover-left .gw-panel--studio {
  flex: 0.6;
}
.gw-split.is-hover-right .gw-panel--studio {
  flex: 1.4;
}
.gw-split.is-hover-right .gw-panel--consult {
  flex: 0.6;
}

.gw-panel--consult::before,
.gw-panel--studio::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.7s ease;
  pointer-events: none;
}

.gw-panel--consult::before {
  background: radial-gradient(ellipse at 50% 55%, rgba(244, 241, 0, 0.07) 0%, transparent 65%);
  background: radial-gradient(ellipse at 50% 55%, color-mix(in srgb, var(--gw-accent-consult) 12%, transparent) 0%, transparent 65%);
}

.gw-panel--studio::before {
  background: radial-gradient(ellipse at 50% 55%, rgba(252, 13, 28, 0.07) 0%, transparent 65%);
  background: radial-gradient(ellipse at 50% 55%, color-mix(in srgb, var(--gw-accent-studio) 12%, transparent) 0%, transparent 65%);
}

.gw-panel:hover::before {
  opacity: 1;
}

/* ==========================================================================
   PANEL CONTENT
   ========================================================================== */
.gw-panel__inner {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 380px;
  gap: 8px;
}

.gw-panel__number {
  font-family: var(--gw-font-display);
  font-weight: 800;
  font-size: 13px;
  margin-bottom: 28px;
  opacity: 0;
}

.gw-panel--consult .gw-panel__number {
  color: var(--gw-accent-consult);
}
.gw-panel--studio .gw-panel__number {
  color: var(--gw-accent-studio);
}

.gw-panel__title {
  font-family: var(--gw-font-display);
  font-weight: 800;
  font-size: clamp(1.5rem, 3.5vw, 3.8rem);
  line-height: 1.05;
  letter-spacing: -0.03em;
  margin-bottom: 18px;
  opacity: 0;
  text-transform: uppercase;
}

.gw-panel__subtitle {
  font-family: var(--gw-font-body);
  font-size: clamp(12px, 1.6vw, 16px);
  line-height: 1.55;
  color: rgba(240, 239, 233, 0.5);
  margin-bottom: 36px;
  opacity: 0;
  max-width: 260px;
}

.pals-gateway .gw-panel__cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--gw-font-display);
  font-weight: 800;
  font-size: clamp(13px, 1.2vw, 18px);
  line-height: 1;
  text-transform: uppercase;
  text-decoration: none;
  padding: 10px 24px;
  border-radius: 100px;
  border: 2px solid rgba(240, 239, 233, 0.28);
  color: var(--gw-white);
  transition: all 0.4s ease;
  opacity: 0;
  white-space: nowrap;
}

@media (min-width: 768px) {
  .pals-gateway .gw-panel__cta {
    padding: 12px 32px;
  }
}

.pals-gateway .gw-panel--consult .gw-panel__cta:hover {
  background: var(--gw-accent-consult);
  border-color: var(--gw-accent-consult);
  color: var(--gw-black);
  box-shadow: 0 0 50px color-mix(in srgb, var(--gw-accent-consult) 22%, transparent);
}

.pals-gateway .gw-panel--studio .gw-panel__cta:hover {
  background: var(--gw-accent-studio);
  border-color: var(--gw-accent-studio);
  color: var(--gw-black);
  box-shadow: 0 0 50px color-mix(in srgb, var(--gw-accent-studio) 22%, transparent);
}

.gw-arrow {
  display: inline-block;
  transition: transform 0.3s ease;
  font-size: 14px;
}

.gw-panel__cta:hover .gw-arrow {
  transform: translateX(5px);
}

/* ==========================================================================
   STAGGERED ENTRANCE ANIMATIONS
   ========================================================================== */
.gw-panel--consult .gw-panel__number {
  animation: gwFadeUpAccent 0.7s ease 1s forwards;
}
.gw-panel--consult .gw-panel__title {
  animation: gwFadeUp 0.7s ease 1.12s forwards;
}
.gw-panel--consult .gw-panel__subtitle {
  animation: gwFadeUp 0.7s ease 1.24s forwards;
}
.gw-panel--consult .gw-panel__cta {
  animation: gwFadeUp 0.7s ease 1.36s forwards;
}

.gw-panel--studio .gw-panel__number {
  animation: gwFadeUpAccent 0.7s ease 1.06s forwards;
}
.gw-panel--studio .gw-panel__title {
  animation: gwFadeUp 0.7s ease 1.18s forwards;
}
.gw-panel--studio .gw-panel__subtitle {
  animation: gwFadeUp 0.7s ease 1.3s forwards;
}
.gw-panel--studio .gw-panel__cta {
  animation: gwFadeUp 0.7s ease 1.42s forwards;
}

@keyframes gwFadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes gwFadeUpAccent {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 0.7;
    transform: translateY(0);
  }
}

/* ==========================================================================
   DECORATIVE RINGS
   ========================================================================== */
.gw-panel__ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(240, 239, 233, 0.04);
  pointer-events: none;
}

.gw-panel--consult .gw-panel__ring {
  width: 500px;
  height: 500px;
  top: -120px;
  left: -120px;
  animation: gwSpin 50s linear infinite;
}

.gw-panel--studio .gw-panel__ring {
  width: 420px;
  height: 420px;
  bottom: -100px;
  right: -100px;
  animation: gwSpin 45s linear infinite reverse;
}

@keyframes gwSpin {
  to {
    transform: rotate(360deg);
  }
}

/* ==========================================================================
   BOTTOM TEXT
   ========================================================================== */
.gw-bottom {
  position: fixed;
  bottom: 24px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: var(--gw-font-display);
  font-weight: 800;
  font-size: 11px;
  text-transform: uppercase;
  color: rgba(240, 239, 233, 0.2);
  z-index: 50;
  opacity: 0;
  animation: gwFadeUp 0.7s ease 1.8s forwards;
}

/* ==========================================================================
   PAGE TRANSITION OVERLAYS (horizontal wipe)
   ========================================================================== */
.gw-transition {
  position: fixed;
  inset: 0;
  z-index: 80;
  transform: scaleX(0);
  pointer-events: none;
}

.gw-transition--consult {
  background: var(--gw-accent-consult);
  transform-origin: left;
  transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1);
}

.gw-transition--studio {
  background: var(--gw-accent-studio);
  transform-origin: right;
  transition: transform 0.6s cubic-bezier(0.65, 0, 0.35, 1);
}

.gw-transition.is-active {
  transform: scaleX(1);
}

/* ==========================================================================
   RESPONSIVE — stays side-by-side, content scales down
   ========================================================================== */
@media (max-width: 768px) {
  .gw-topbar,
  .pals-gateway .gw-topbar {
    padding: 18px 16px;
  }
  .gw-topbar .gw-logo {
    height: 22px;
  }
  .gw-panel {
    padding: 40px 16px;
  }
  .gw-panel__number {
    font-size: 11px;
    margin-bottom: 20px;
  }
  .gw-panel__title {
    margin-bottom: 14px;
  }
  .gw-panel__subtitle {
    margin-bottom: 28px;
  }
  .gw-panel__cta {
    padding: 11px 20px;
  }
  .gw-panel__ring {
    display: none;
  }
}

@media (max-width: 420px) {
  .gw-panel {
    padding: 30px 12px;
  }
  .gw-panel__number {
    font-size: 10px;
    letter-spacing: 2px;
    margin-bottom: 16px;
  }
  .gw-panel__title {
    font-size: clamp(1.1rem, 5vw, 1.5rem);
    margin-bottom: 10px;
  }
  .gw-panel__subtitle {
    font-size: 11px;
    margin-bottom: 22px;
    max-width: 140px;
  }
  .gw-panel__cta {
    padding: 10px 16px;
    font-size: 9px;
    letter-spacing: 1.5px;
    gap: 5px;
  }
  .gw-arrow {
    font-size: 12px;
  }
  .gw-bottom {
    font-size: 8px;
    bottom: 14px;
  }
  .gw-topbar .gw-logo {
    height: 18px;
  }
}

