:root {
  --color-navy: #1a2e5a;
  --color-navy-dark: #0f1d3d;
  --color-cream: #fdf6ed;
  --color-cyan: #7dd3e8;
  --color-white: #ffffff;
  --color-black: #000000;
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --transition-smooth: cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  height: 100%;
  height: 100dvh;
  overflow: hidden;
  background-color: var(--color-black);
  font-family: var(--font-body);
  color: var(--color-white);
  -webkit-font-smoothing: antialiased;
}

/* ---------- Video Background Layer ---------- */
.sales-op__bg-wrap {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  transition: opacity 0.8s ease;
}

.sales-op__bg-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.06);
  filter: brightness(0.35) contrast(1.1);
}

.sales-op__bg {
  display: none;
}

.sales-op__overlay {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.7) 100%);
}

/* Hide video bg when viewing online/offline detail */
body.is-online-view .sales-op__bg-wrap,
body.is-offline-view .sales-op__bg-wrap {
  opacity: 0;
  pointer-events: none;
}

/* ---------- Header & Top Label ---------- */
.sales-op__top-label {
  position: absolute;
  top: 32px;
  left: 60px;
  font-family: var(--font-body);
  font-size: 0.82rem;
  letter-spacing: 2px;
  color: var(--color-white);
  opacity: 0.85;
  z-index: 10;
  text-transform: uppercase;
}

/* ---------- Navbar ---------- */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 40px;
  z-index: 1000;
}

.navbar__logo {
  position: absolute;
  top: 50%;
  right: 100px;
  transform: translateY(-50%);
  height: 22px;
  opacity: 0.95;
}

.navbar__logo img {
  height: 100%;
  width: auto;
}

.burger {
  width: 36px;
  height: 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  cursor: pointer;
  z-index: 1010;
  position: relative;
  background: none;
  border: none;
}

.burger__line {
  width: 100%;
  height: 3px;
  background: var(--color-white);
  border-radius: 2px;
  transition: transform 0.4s var(--transition-smooth), opacity 0.4s var(--transition-smooth);
  transform-origin: center;
}

.burger.active .burger__line:nth-child(1) {
  transform: translateY(10.5px) rotate(45deg);
}

.burger.active .burger__line:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.burger.active .burger__line:nth-child(3) {
  transform: translateY(-10.5px) rotate(-45deg);
}

/* ---------- Slide-in Menu ---------- */
.nav-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 100%;
  max-width: 500px;
  height: 100vh;
  height: 100dvh;
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 60px 60px;
  z-index: 999;
  transition: right 0.5s var(--transition-smooth);
}

.nav-menu.open {
  right: 0;
}

.nav-menu__link {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 600;
  color: var(--color-white);
  margin-bottom: 30px;
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
  letter-spacing: 2px;
  text-decoration: none;
}

.nav-menu.open .nav-menu__link {
  opacity: 1;
  transform: translateX(0);
}

.nav-menu.open .nav-menu__link:nth-child(1) { transition-delay: 0.15s; }
.nav-menu.open .nav-menu__link:nth-child(2) { transition-delay: 0.25s; }
.nav-menu.open .nav-menu__link:nth-child(3) { transition-delay: 0.35s; }

.nav-menu__link:hover {
  color: var(--color-cyan);
}

.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(5px);
  z-index: 998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.nav-overlay.visible {
  opacity: 1;
  pointer-events: all;
}

/* ---------- Main Container ---------- */
.sales-op__main {
  position: relative;
  z-index: 5;
  width: 100%;
  height: 100%;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 60px;
  overflow-y: auto;
}

/* ---------- Section 1: Chooser (Online / Offline) ---------- */
.explore-chooser {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 36px;
  width: 100%;
  max-width: 860px;
  animation: fadeInChooser 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInChooser {
  from {
    opacity: 0;
    transform: scale(0.94) translateY(20px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

.explore-chooser__card {
  position: relative;
  width: 320px;
  height: 230px;
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s ease;
}

.explore-chooser__card:hover {
  transform: translateY(-8px) scale(1.03);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.explore-chooser__card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s ease;
}

.explore-chooser__card:hover img {
  transform: scale(1.08);
}

.explore-chooser__card-label {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--color-white);
  letter-spacing: 2.5px;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.85);
  pointer-events: none;
}

/* ---------- Section 2: Online Detail (Collage + Flowchart) ---------- */
.explore-online-detail {
  width: 100%;
  max-width: 1400px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
  animation: fadeInDetail 0.6s ease forwards;
}

.explore-online-detail--alt {
  flex-direction: row-reverse;
}

/* Left: Overlapping Photo Collage */
.explore-online-collage {
  position: relative;
  width: 44%;
  aspect-ratio: 44 / 50; /* Maintains stable proportions (roughly 1:1.1) across all screen sizes */
  height: auto;
  max-height: 70vh;
  flex-shrink: 0;
  top: -15%;
}

.explore-online-collage__item {
  position: absolute;
  overflow: hidden;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), z-index 0.2s ease;
}

.explore-online-collage__item:hover {
  transform: scale(1.05);
  z-index: 10 !important;
}

.explore-online-collage__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Specific Card Positioning Matching Custom Layout */
.explore-online-collage__item--1 {
  top: -9%;
  right: 15%;
  width: 65%;
  height: 28%;
  z-index: 1;
}

.explore-online-collage__item--2 {
  top: 18%;
  left: 10%;
  width: 60%;
  height: 28%;
  z-index: 4;
}

.explore-online-collage__item--2 img {
  object-position: top;
}

.explore-online-collage__item--3 {
  top: 45%;
  left: 0;
  width: 78%;
  height: 35%;
  z-index: 3;
}

.explore-online-collage__item--4 {
  bottom: 35%;
  right: 5%;
  width: 35%;
  height: 35%;
  z-index: 4;
}

.explore-online-collage__item--4 img {
  object-position: top;
}

.explore-online-collage__item--5 {
  bottom: 0;
  left: 7%;
  width: 25%;
  height: 35%;
  z-index: 5;
}

.explore-online-collage__item--5 img {
  object-position: top;
}

/* Specific Card Positioning for Alt Layout (Sales Operation) */
.explore-online-collage__item--alt-1 {
  top: 10%;
  right: 0;
  width: 55%;
  height: 75%;
  z-index: 1;
}

.explore-online-collage__item--alt-2 {
  top: 18%;
  left: 25%;
  width: 35%;
  height: 55%;
  z-index: 2;
}

.explore-online-collage__item--alt-3 {
  bottom: -5%;
  left: 32%;
  width: 32%;
  height: 40%;
  z-index: 3;
}

.explore-online-collage__item--alt-4 {
  bottom: -25%;
  right: 15%;
  width: 28%;
  height: 55%;
  z-index: 4;
}

.explore-online-collage__item--alt-4 img {
  object-position: top;
}

/* Right: Process Flowchart */
.explore-online-flow {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 54%;
}

.explore-online-flow img {
  width: 100%;
  height: auto;
  max-height: clamp(380px, 70vh, 600px);
  object-fit: contain;
  transition: transform 0.3s ease;
  mix-blend-mode: screen;
}

.explore-online-flow img:hover {
  transform: scale(1.01);
}

/* ---------- Section 3: Offline Detail ---------- */
.explore-offline-detail {
  position: fixed;
  inset: 0;
  z-index: 6;
  width: 100%;
  height: 100%;
  height: 100dvh;
  background-image: url('../assets/PAGE-2/slide-2-explore/offline/BG-compressed.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  overflow: hidden;
  padding: 80px 0 60px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  animation: fadeInDetail 0.6s ease forwards;
}

.explore-offline-categories {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  margin-bottom: 0;
}

.explore-offline-cat {
  position: relative;
  overflow: hidden;
  height: clamp(180px, 32vh, 300px);
  border-right: 1px solid #ffffff;
}

.explore-offline-cat:last-child {
  border-right: none;
}

.explore-offline-cat img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.explore-offline-cat:hover img {
  transform: scale(1.05);
}

.explore-offline-cat__label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-white);
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.9);
  white-space: nowrap;
  letter-spacing: 1px;
}

/* HR Divider between images and lists */
.explore-offline-divider {
  border: none;
  border-top: 1px solid #ffffff;
  margin: 0 0 16px 0;
}

.explore-offline-lists {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.explore-offline-list {
  list-style: none;
  padding: 0 20px;
  border-right: 1px solid #ffffff;
}

.explore-offline-list:last-child {
  border-right: none;
}

.explore-offline-list li {
  font-size: clamp(1rem, 1.1vw, 0.88rem);
  padding: 6px 0;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255);
  border-bottom: 1px solid rgba(255, 255, 255);
  opacity: 0.9;
  letter-spacing: 0.3px;
}

.explore-offline-mobile {
  display: none;
}

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

/* ---------- Bottom Navigation: BACK Button ---------- */
.sales-op__back-btn {
  position: absolute;
  bottom: 40px;
  left: 60px;
  font-family: var(--font-heading);
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--color-white);
  background: rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 10px 24px;
  border-radius: 30px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  cursor: pointer;
  z-index: 10;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  transition: opacity 0.3s ease, transform 0.3s ease, background 0.3s ease;
}

.sales-op__back-btn:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: translateX(-3px);
}

/* ---------- Image Modal (Lightbox) ---------- */
.image-modal {
  display: none; /* Hidden by default, toggled via JS */
  position: fixed;
  z-index: 2000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.9);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  align-items: center;
  justify-content: center;
  animation: fadeInModal 0.3s ease;
}

.image-modal.show {
  display: flex;
}

@keyframes fadeInModal {
  from { opacity: 0; }
  to { opacity: 1; }
}

.image-modal__close {
  position: absolute;
  top: 30px;
  right: 40px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: 0.3s;
  z-index: 2010;
}

.image-modal__close:hover,
.image-modal__close:focus {
  color: var(--color-cyan);
  text-decoration: none;
  cursor: pointer;
}

.image-modal__content {
  margin: auto;
  display: block;
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  animation: zoomInModal 0.4s ease;
  mix-blend-mode: screen;
}

@keyframes zoomInModal {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@media (max-width: 1024px) {
  .sales-op__main {
    padding: 90px 40px;
  }

  .explore-chooser {
    gap: 24px;
  }

  .explore-chooser__card {
    width: 280px;
    height: 200px;
  }
}

@media (max-width: 768px) {
  .sales-op__top-label {
    top: 24px;
    left: 24px;
    font-size: 0.75rem;
  }

  .navbar {
    padding: 0 24px;
    background: linear-gradient(to bottom, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0) 100%);
  }

  .navbar__logo {
    right: 75px;
  }

  .sales-op__main {
    padding: 85px 20px 70px;
    justify-content: flex-start;
  }

  .explore-chooser {
    flex-direction: column;
    gap: 20px;
    margin-top: auto;
    margin-bottom: auto;
  }

  .explore-chooser__card {
    width: 100%;
    max-width: 320px;
    height: 180px;
  }

  .explore-online-detail {
    flex-direction: column;
    gap: 30px;
    height: auto;
    margin-top: auto;
    margin-bottom: auto;
  }

  .explore-online-collage {
    display: none;
  }

  .explore-online-flow {
    width: 100%;
    max-width: 100%;
  }

  .explore-online-flow img {
    max-height: none;
  }

  .explore-offline-detail {
    padding: 110px 0 90px;
    overflow-y: auto;
    justify-content: flex-start;
  }

  /* Hide Desktop Layout */
  .explore-offline-categories,
  .explore-offline-divider,
  .explore-offline-lists {
    display: none;
  }

  /* Show Mobile Grouped Layout */
  .explore-offline-mobile {
    display: flex;
    flex-direction: column;
    gap: 60px;
    margin-top: -40px;
  }

  .explore-offline-group {
    display: flex;
    flex-direction: column;
    gap: 15px;
  }

  .explore-offline-cat {
    height: 120px;
    border-right: none;
  }

  .explore-offline-cat__label {
    font-size: 1rem;
  }

  .explore-offline-list {
    border-right: none;
    padding: 0 20px;
  }

  .explore-offline-list li {
    font-size: 0.85rem;
    padding: 8px 0;
  }

  .sales-op__back-btn {
    position: fixed;
    bottom: 24px;
    left: 24px;
    font-size: 0.85rem;
    padding: 8px 20px;
    z-index: 20;
  }
}
