/* ═══════════════════════════════════════════════════
   KAVE — Hero Section + Custom Cursor + Video Overlay
   ═══════════════════════════════════════════════════ */

/* ── Custom Cursor ── */
.cursor {
  position: fixed;
  top: 0;
  left: 0;
  width: 12px;
  height: 12px;
  background: var(--color-text);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  transform: translate(-50%, -50%);
  transition: width var(--duration-fast), height var(--duration-fast), background-color var(--duration-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-body);
  font-size: 10px;
  text-transform: uppercase;
  opacity: 0;
}

.cursor.active {
  width: 80px;
  height: 80px;
  background: rgba(17, 29, 41, 0.9);
}

/* ── Hero Layout ── */
.hero {
  height: 100vh;
  display: flex;
  position: relative;
  padding-top: 80px;
}

.hero-left {
  width: 45%;
  padding: 0 0 100px var(--gutter);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  position: relative;
  z-index: 2;
  background: #eaeaea;
}

.hero-right {
  width: 55%;
  height: 90vh;
  position: relative;
  overflow: hidden;
  border-radius: 4px 0 0 4px;
  cursor: pointer;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.1);
}

.hero-title {
  font-family: var(--font-heading);
  font-size: clamp(40px, 5.5vw, 86px);
  line-height: 1.05;
  margin-bottom: 25px;
  width: 130%;
  position: relative;
  z-index: 3;
}

.hero-title span {
  display: block;
  overflow: hidden;
}

.hero-title span i {
  display: block;
  font-style: normal;
}

.hero-subtitle {
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--color-text-muted);
  max-width: 400px;
  line-height: 1.5;
  margin-bottom: 40px;
}

.hero-buttons {
  display: flex;
  align-items: center;
  gap: 30px;
}

/* ── Magnetic Circular Button ── */
.magnetic-wrap {
  position: absolute;
  top: 50%;
  left: 45%;
  transform: translate(-50%, -50%);
  width: 150px;
  height: 150px;
  z-index: 10;
}

.magnetic-btn {
  position: relative;
  width: 100%;
  height: 100%;
  background: none;
  border: none;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  will-change: transform;
}

.magnetic-btn .disk {
  position: absolute;
  inset: 0;
  background: var(--color-text);
  border-radius: 50%;
  z-index: 1;
  will-change: transform;
}

.magnetic-btn .label {
  position: relative;
  z-index: 2;
  color: #fff;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 1.4;
  text-align: center;
  white-space: nowrap;
  mix-blend-mode: difference;
}

/* ── Fullscreen Video Overlay ── */
.video-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: #111D29;
  opacity: 0;
  pointer-events: none;
  clip-path: inset(0 0 0 0);
  will-change: clip-path, opacity;
}

.video-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.video-overlay video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #111D29;
}

.overlay-close {
  position: absolute;
  top: 28px;
  right: 28px;
  width: 52px;
  height: 52px;
  background: var(--color-text);
  border: 2px solid var(--color-text);
  border-radius: 50%;
  z-index: 2;
  opacity: 0;
  overflow: hidden;
  isolation: isolate;
  transition: opacity 0.5s ease 0.3s;
}

.video-overlay.active .overlay-close {
  opacity: 1;
}

/* Fill hover animation — same as primary-btn */
.overlay-close::before {
  content: '';
  position: absolute;
  inset: 0;
  background: #fff;
  border-radius: 50%;
  transform: translateY(101%);
  transition: transform var(--duration-slow) var(--ease);
  z-index: 1;
}

.overlay-close:hover::before {
  transform: translateY(0);
}

.overlay-close span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 18px;
  height: 2px;
  background: #fff;
  z-index: 2;
  transition: background var(--duration-slow) var(--ease);
}

.overlay-close:hover span {
  background: var(--color-text);
}

.overlay-close span:nth-child(1) { transform: translate(-50%, -50%) rotate(45deg); }
.overlay-close span:nth-child(2) { transform: translate(-50%, -50%) rotate(-45deg); }

/* ═══ TABLET (≤960px) ═══ */
@media (max-width: 960px) {
  .hero-left { padding: 0 0 60px var(--gutter); }
  .magnetic-wrap { width: 120px; height: 120px; }
  .magnetic-btn .label { font-size: 11px; }
}

/* ═══ MOBILE (≤760px) ═══ */
@media (max-width: 760px) {
  .cursor { display: none !important; }

  .hero {
    flex-direction: column;
    height: auto;
    min-height: auto;
    padding-top: 60px;
  }

  .hero-left {
    width: 100%;
    padding: 32px var(--gutter) 56px;
    order: 2;
    justify-content: flex-start;
  }

  .hero-right {
    width: 100%;
    height: 58vh;
    order: 1;
    border-radius: 0;
  }

  .hero-title {
    width: 100% !important;
    font-size: clamp(34px, 8.5vw, 52px);
    margin-bottom: 20px;
  }

  .hero-subtitle { font-size: 15px; margin-bottom: 32px; max-width: 100%; }
  .hero-buttons { gap: 20px; flex-wrap: wrap; }

  /* Magnetic circle at video/text seam */
  .magnetic-wrap {
    display: flex !important;
    position: absolute;
    top: calc(60px + 58vh);
    right: 8px;
    left: auto;
    transform: translateY(-50%);
    width: 112px;
    height: 112px;
    margin: 0;
    z-index: 5;
  }

  .magnetic-btn .label { font-size: 11px; letter-spacing: 0.5px; }
  .overlay-close { top: 18px; right: 18px; width: 46px; height: 46px; }
}

@media (max-width: 420px) {
  .hero-title { font-size: clamp(30px, 9vw, 42px); }
  .hero-buttons { flex-direction: column; align-items: flex-start; gap: 18px; }
  .magnetic-wrap { right: 4px; width: 100px; height: 100px; }
}
