/* Japan Bike Store — custom.css
   Flagship Ginza gallery: museum-white, navy #1a3a6b, silver */

:root {
  --jbs-paper: #fafbfc;
  --jbs-navy: #1a3a6b;
  --jbs-navy-soft: #2a4f8a;
  --jbs-navy-deep: #122845;
  --jbs-silver: #c5cdd8;
  --jbs-silver-soft: #e8ecf1;
  --jbs-mute: #9aa6b5;
  --jbs-ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html.jbs-html,
html.lenis,
html.lenis body {
  height: auto;
}

html.lenis {
  scroll-behavior: auto !important;
}

body.jbs {
  background-color: var(--jbs-paper);
  color: var(--jbs-navy);
  overflow-x: hidden;
}

::selection {
  background: rgba(26, 58, 107, 0.14);
  color: var(--jbs-navy);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -3rem;
  z-index: 200;
  background: var(--jbs-navy);
  color: #fff;
  padding: 0.5rem 1rem;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 1rem;
}

/* Luxury page loader — white / blue thin line */
.page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--jbs-paper);
  transition: opacity 0.7s var(--jbs-ease), visibility 0.7s;
}

.page-loader.is-done {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.page-loader__inner {
  text-align: center;
  width: min(280px, 70vw);
}

.page-loader__mark {
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.75rem;
  letter-spacing: 0.45em;
  color: var(--jbs-navy);
}

.page-loader__jp {
  margin-top: 0.85rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.55rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  color: var(--jbs-navy);
}

.page-loader__place {
  margin-top: 0.4rem;
  font-size: 0.68rem;
  letter-spacing: 0.28em;
  color: var(--jbs-mute);
}

.page-loader__track {
  margin-top: 1.75rem;
  height: 1px;
  background: var(--jbs-silver-soft);
  overflow: hidden;
}

.page-loader__bar {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--jbs-silver), var(--jbs-navy));
  transition: width 0.35s ease;
}

/* Scroll progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 0%;
  z-index: 80;
  background: linear-gradient(90deg, var(--jbs-silver), var(--jbs-navy));
  pointer-events: none;
}

/* Soft custom cursor */
.cursor-dot,
.cursor-ring {
  position: fixed;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 10000;
  border-radius: 50%;
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity 0.3s ease;
}

.cursor-dot {
  width: 5px;
  height: 5px;
  background: var(--jbs-navy);
}

.cursor-ring {
  width: 36px;
  height: 36px;
  border: 1px solid rgba(26, 58, 107, 0.35);
  transition: width 0.25s var(--jbs-ease), height 0.25s var(--jbs-ease), border-color 0.25s ease, opacity 0.3s ease;
}

body.has-cursor .cursor-dot,
body.has-cursor .cursor-ring {
  opacity: 1;
}

body.has-cursor,
body.has-cursor a,
body.has-cursor button {
  cursor: none;
}

body.has-cursor .cursor-ring.is-hover {
  width: 54px;
  height: 54px;
  border-color: rgba(26, 58, 107, 0.55);
}

/* Header */
.site-header.is-scrolled {
  box-shadow: 0 8px 30px rgba(26, 58, 107, 0.06);
  background: rgba(250, 251, 252, 0.94);
}

.nav-desktop {
  flex: 1 1 auto;
  justify-content: center;
  gap: 1.35rem;
  min-width: 0;
}

.nav-link {
  position: relative;
  display: inline-block;
  flex-shrink: 0;
  white-space: nowrap;
}

.nav-link::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -0.35rem;
  width: 100%;
  height: 1px;
  background: var(--jbs-navy);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s var(--jbs-ease);
}

.nav-link:hover::after,
.nav-link.is-active::after {
  transform: scaleX(1);
}

.header-inner {
  min-height: 3.5rem;
}

@media (min-width: 1280px) {
  .nav-desktop {
    gap: 1.75rem;
  }
}

.mobile-nav:not([hidden]) {
  display: block;
}

body.nav-open {
  overflow: hidden;
}

body.nav-open #navToggle .hamburger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

body.nav-open #navToggle .hamburger-line:nth-child(2) {
  opacity: 0;
}

body.nav-open #navToggle .hamburger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* About page hero */
.about-hero {
  position: relative;
  min-height: clamp(280px, 48vw, 520px);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}

.about-hero__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.about-hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(18, 40, 69, 0.35) 0%, rgba(18, 40, 69, 0.72) 100%);
}

.about-hero__content {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 72rem;
  margin: 0 auto;
  padding: 4.5rem 1.25rem 3rem;
  text-align: center;
}

@media (min-width: 768px) {
  .about-hero__content {
    padding: 6rem 2rem 4rem;
  }
}

/* Hero image cover */
.video-hero__video {
  object-fit: cover;
}

/* Responsive hardening */
img, video {
  max-width: 100%;
  height: auto;
}

.video-hero {
  min-height: 100svh;
}

.video-hero__content {
  padding-left: max(1rem, env(safe-area-inset-left));
  padding-right: max(1rem, env(safe-area-inset-right));
  padding-bottom: max(4rem, env(safe-area-inset-bottom));
}

.hero-brand {
  font-size: clamp(2rem, 8vw, 4.6rem);
  word-break: keep-all;
}

.hero-actions {
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.75rem;
}

@media (max-width: 639px) {
  .btn-hero,
  .btn-hero-ghost {
    width: 100%;
    justify-content: center;
  }

  .hero-stats {
    display: none;
  }
}

@media (max-height: 520px) and (orientation: landscape) {
  .video-hero {
    min-height: 100vh;
  }
  .hero-line {
    display: none;
  }
}

.page-loader {
  display: none !important;
}

/* ========== VIDEO HERO (unique) ========== */
.video-hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #e8ecf1;
}

.video-hero__media {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.video-hero__video,
.video-hero__poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background-size: cover;
  background-position: center;
}

.video-hero__poster[hidden] {
  display: none;
}

.video-hero__overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(18, 40, 69, 0.42) 0%, rgba(26, 58, 107, 0.28) 40%, rgba(18, 40, 69, 0.55) 100%),
    radial-gradient(ellipse 70% 55% at 50% 45%, rgba(250, 251, 252, 0.12) 0%, transparent 70%);
  pointer-events: none;
}

.video-hero__mesh {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    radial-gradient(ellipse 50% 40% at 20% 30%, rgba(197, 205, 216, 0.22), transparent 60%),
    radial-gradient(ellipse 40% 35% at 80% 70%, rgba(26, 58, 107, 0.18), transparent 55%);
  pointer-events: none;
  mix-blend-mode: soft-light;
}

.video-hero__orbs {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(48px);
  opacity: 0.45;
  animation: orbFloat 14s ease-in-out infinite;
}

.orb-a {
  width: 280px;
  height: 280px;
  top: 12%;
  left: 8%;
  background: rgba(197, 205, 216, 0.55);
}

.orb-b {
  width: 220px;
  height: 220px;
  bottom: 18%;
  right: 12%;
  background: rgba(42, 79, 138, 0.35);
  animation-delay: -4s;
}

.orb-c {
  width: 160px;
  height: 160px;
  top: 40%;
  left: 55%;
  background: rgba(250, 251, 252, 0.35);
  animation-delay: -7s;
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(18px, -22px) scale(1.08); }
}

.video-hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 52rem;
  margin-inline: auto;
  padding: 6rem 1.25rem 7rem;
  text-align: center;
  color: #fff;
}

.hero-kicker {
  font-size: 0.72rem;
  letter-spacing: 0.32em;
  color: rgba(255, 255, 255, 0.72);
}

.hero-brand {
  margin-top: 1.1rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(2.6rem, 7.5vw, 5.2rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: 0.2em;
  color: #fff;
  text-shadow: 0 8px 40px rgba(18, 40, 69, 0.25);
}

.hero-en {
  margin-top: 0.75rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 0.85rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: rgba(197, 205, 216, 0.9);
}

.hero-rule {
  width: 48px;
  height: 1px;
  margin: 1.5rem auto;
  background: rgba(255, 255, 255, 0.55);
}

.hero-line {
  max-width: 28rem;
  margin-inline: auto;
  font-size: clamp(0.98rem, 2vw, 1.15rem);
  line-height: 1.85;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.82);
}

.hero-actions {
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.btn-hero {
  background: #fff;
  border-color: #fff;
  color: var(--jbs-navy);
}

.btn-hero:hover {
  background: transparent;
  color: #fff;
  border-color: #fff;
}

.btn-hero-ghost {
  border-color: rgba(255, 255, 255, 0.7);
  color: #fff;
}

.btn-hero-ghost:hover {
  background: #fff;
  color: var(--jbs-navy);
  border-color: #fff;
}

/* GSAP initial state for hero entrance */
.video-hero [data-hero] {
  opacity: 0;
  filter: blur(12px);
  transform: translateY(24px);
}

.video-hero.is-ready [data-hero] {
  /* GSAP owns transforms after init */
}

/* Scroll indicator */
.scroll-indicator {
  position: absolute;
  bottom: 1.75rem;
  left: 50%;
  z-index: 3;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
}

.scroll-indicator__label {
  font-size: 0.62rem;
  letter-spacing: 0.28em;
}

.scroll-indicator__line {
  display: block;
  width: 1px;
  height: 42px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.8), transparent);
  animation: scrollPulse 2.2s ease-in-out infinite;
  transform-origin: top;
}

@keyframes scrollPulse {
  0%, 100% { transform: scaleY(0.45); opacity: 0.4; }
  50% { transform: scaleY(1); opacity: 1; }
}

/* Floating glass stats — after first scroll */
.hero-stats {
  position: absolute;
  bottom: 5.5rem;
  left: 50%;
  z-index: 3;
  transform: translateX(-50%) translateY(16px);
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
  width: min(92vw, 640px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.7s var(--jbs-ease), transform 0.7s var(--jbs-ease);
}

.hero-stats.is-visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
  pointer-events: auto;
}

.glass-chip {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 110px;
  padding: 0.7rem 1rem;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(250, 251, 252, 0.14);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: #fff;
}

.hero-stats__num {
  font-size: 1.35rem;
  line-height: 1;
}

.hero-stats__num small {
  font-size: 0.75rem;
  margin-left: 0.1rem;
}

.hero-stats__label {
  margin-top: 0.3rem;
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.7);
}

@media (max-width: 640px) {
  .hero-stats {
    bottom: 4.5rem;
  }
  .glass-chip {
    min-width: 96px;
    padding: 0.55rem 0.7rem;
  }
}

/* Brand marquee */
.brand-strip {
  border-block: 1px solid rgba(197, 205, 216, 0.55);
  background: #fff;
  position: relative;
  z-index: 2;
}

.brand-strip__track {
  display: flex;
  gap: 3.5rem;
  width: max-content;
  animation: brandMarquee 32s linear infinite;
}

@keyframes brandMarquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* Sections */
.section-pad {
  padding-block: clamp(4.5rem, 8vw, 7rem);
}

.eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.28em;
  color: var(--jbs-mute);
}

.section-title {
  margin-top: 0.75rem;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: clamp(1.85rem, 3.5vw, 2.65rem);
  font-weight: 600;
  letter-spacing: 0.08em;
  color: var(--jbs-navy);
  text-align: center;
}

.section-title.text-left {
  text-align: left;
}

.section-lead {
  margin-top: 0.9rem;
  color: rgba(26, 58, 107, 0.7);
  text-align: center;
  line-height: 1.8;
}

.section-lead.text-left {
  text-align: left;
}

.line-thin {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--jbs-silver), transparent);
}

/* Spec panels */
.spec-panel {
  border: 1px solid rgba(197, 205, 216, 0.65);
  background: var(--jbs-paper);
  padding: 1.35rem 1.25rem;
}

.spec-panel__k {
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  color: var(--jbs-mute);
}

.spec-panel__v {
  margin-top: 0.65rem;
  font-size: 1.05rem;
  line-height: 1.45;
  color: var(--jbs-navy);
}

/* Swiper */
.bike-swiper .swiper-slide {
  height: auto;
}

.bike-swiper .swiper-pagination-bullet {
  background: var(--jbs-silver);
  opacity: 1;
}

.bike-swiper .swiper-pagination-bullet-active {
  background: var(--jbs-navy);
}

.bike-swiper .swiper-button-prev,
.bike-swiper .swiper-button-next {
  color: var(--jbs-navy);
  width: 2.5rem;
  height: 2.5rem;
}

.bike-swiper .swiper-button-prev::after,
.bike-swiper .swiper-button-next::after {
  font-size: 1rem;
  font-weight: 700;
}

/* Tilt cards */
.tilt-card {
  transform-style: preserve-3d;
  transition: box-shadow 0.4s ease;
  will-change: transform;
}

.tilt-card:hover {
  box-shadow: 0 18px 40px rgba(26, 58, 107, 0.08);
}

/* Page banner */
.page-banner {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse 70% 80% at 50% 0%, #ffffff 0%, #f3f6f9 55%, #e8ecf1 100%);
  border-bottom: 1px solid rgba(197, 205, 216, 0.5);
}

.page-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 15% 40%, rgba(197, 205, 216, 0.35), transparent 40%),
    radial-gradient(circle at 85% 60%, rgba(26, 58, 107, 0.06), transparent 42%);
  pointer-events: none;
}

.page-banner > * {
  position: relative;
  z-index: 1;
}

.page-banner__rule {
  width: 48px;
  height: 1px;
  background: var(--jbs-navy);
  margin-inline: auto;
}

/* Reveal fallback (non-AOS) */
[data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* FAQ */
.faq-item summary {
  list-style: none;
  cursor: pointer;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item[open] summary .faq-icon {
  transform: rotate(45deg);
}

.faq-icon {
  transition: transform 0.25s ease;
}

/* Form */
.jbs-input {
  width: 100%;
  border: 1px solid var(--jbs-silver);
  background: #fff;
  padding: 0.85rem 1rem;
  color: var(--jbs-navy);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.jbs-input:focus {
  border-color: var(--jbs-navy);
  box-shadow: 0 0 0 3px rgba(26, 58, 107, 0.08);
}

.jbs-label {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.82rem;
  letter-spacing: 0.08em;
  color: var(--jbs-mute);
}

.map-placeholder {
  background:
    linear-gradient(135deg, rgba(232, 236, 241, 0.9), rgba(197, 205, 216, 0.35)),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 24px,
      rgba(26, 58, 107, 0.04) 24px,
      rgba(26, 58, 107, 0.04) 25px
    ),
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 24px,
      rgba(26, 58, 107, 0.04) 24px,
      rgba(26, 58, 107, 0.04) 25px
    );
}

.img-soft {
  transition: transform 0.7s var(--jbs-ease), filter 0.5s ease;
}

.group:hover .img-soft {
  transform: scale(1.03);
}

.btn-navy {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid var(--jbs-navy);
  background: var(--jbs-navy);
  color: #fff;
  padding: 0.85rem 1.6rem;
  letter-spacing: 0.1em;
  font-size: 0.85rem;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.25s ease;
}

.btn-navy:hover {
  background: var(--jbs-navy-soft);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  border: 1px solid var(--jbs-navy);
  background: transparent;
  color: var(--jbs-navy);
  padding: 0.85rem 1.6rem;
  letter-spacing: 0.1em;
  font-size: 0.85rem;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.btn-ghost:hover {
  background: var(--jbs-navy);
  color: #fff;
}

.form-success {
  display: none;
}

.form-success.is-visible {
  display: block;
}

.magnetic {
  display: inline-flex;
  will-change: transform;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .brand-strip__track,
  .orb,
  .scroll-indicator__line,
  .page-loader__bar {
    animation: none !important;
  }

  .video-hero [data-hero] {
    opacity: 1 !important;
    filter: none !important;
    transform: none !important;
  }

  .hero-stats {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
  }

  .tilt-card {
    transform: none !important;
  }

  .cursor-dot,
  .cursor-ring {
    display: none !important;
  }

  body.has-cursor,
  body.has-cursor a,
  body.has-cursor button {
    cursor: auto;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
