/* style.css */

:root {
  --color-primary: #1A1A1A; /* Dark charcoal/black for text */
  --color-secondary: #8C8276; /* Sophisticated gray/beige */
  --color-bg: #F7F5F2; /* Creamy light background */
  --color-surface: #FFFFFF; /* Pure white for contrast */
  --font-serif: 'Cormorant Garamond', serif;
  --font-sans: 'Montserrat', sans-serif;
  --font-serif-jp: 'Noto Serif JP', serif;
  
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 5rem;
  --spacing-xl: 8rem;
  
  --transition-slow: 1.2s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-base: 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  color: var(--color-primary);
  background-color: var(--color-bg);
  line-height: 1.8;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: 0.05em;
  color: var(--color-primary);
}

p {
  font-family: var(--font-serif-jp); /* Use Japanese Serif for body by default for a high-end editorial look */
  font-weight: 300;
  letter-spacing: 0.06em;
  color: #444;
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 5%;
}

.section {
  padding: var(--spacing-xl) 0;
}

.text-center {
  text-align: center;
}

.text-right {
  text-align: right;
}

/* Typography Utility */
.italic {
  font-style: italic;
}

/* Button Styles */
.btn {
  display: inline-block;
  padding: 14px 40px;
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  transition: var(--transition-base);
  cursor: pointer;
  border-radius: 0;
}

.btn-outline {
  background-color: transparent;
  color: var(--color-primary);
  border: 1px solid var(--color-primary);
}

.btn-outline:hover {
  background-color: var(--color-primary);
  color: #fff;
}

/* Loading Screen */
.loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: var(--color-bg);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.8s;
}

.loader.is-hidden {
  opacity: 0;
  visibility: hidden;
}

.loader-logo {
  height: 40px;
  animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
  0% { transform: scale(0.95); opacity: 0.5; }
  50% { transform: scale(1.05); opacity: 0.9; }
  100% { transform: scale(0.95); opacity: 0.5; }
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 2rem 0;
  z-index: 100;
  transition: transform 0.35s ease, opacity 0.25s ease, background-color 0.5s ease, padding 0.5s ease, backdrop-filter 0.5s ease;
  background-color: transparent;
  will-change: transform, opacity;
}

.navbar.scrolled {
  background-color: rgba(247, 245, 242, 0.95);
  backdrop-filter: blur(15px);
  padding: 1.2rem 0;
}

.navbar.hidden {
  opacity: 0;
  transform: translateY(calc(-100% - 16px));
  visibility: hidden;
  pointer-events: none;
}

.nav-container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 4%;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.nav-brand .brand-logo {
  height: 40px;
  transition: transform var(--transition-base);
  opacity: 0.9;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 3rem;
  font-family: var(--font-sans);
}

.nav-links a {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  position: relative;
  transition: color 0.3s ease;
}

.nav-links a::after {
  content: '';
  position: absolute;
  width: 0;
  height: 1px;
  bottom: -4px;
  left: 0;
  background-color: var(--color-primary);
  transition: width 0.4s ease;
}

.nav-links a:hover::after {
  width: 100%;
}

.shop-btn {
  border: 1px solid var(--color-primary);
  padding: 10px 24px;
  border-radius: 50px;
}

.shop-btn::after {
  display: none !important;
}

.shop-btn:hover {
  background-color: var(--color-primary);
  color: #fff;
}

/* Mobile Menu Toggle & Overlay */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 10px;
  cursor: pointer;
  z-index: 1000;
  position: relative;
}

.menu-toggle .bar {
  height: 1px;
  width: 100%;
  background-color: var(--color-primary);
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
  transform-origin: center;
}

.menu-toggle.is-active .bar:nth-child(1) {
  transform: translateY(4.5px) rotate(45deg);
}

.menu-toggle.is-active .bar:nth-child(2) {
  transform: translateY(-4.5px) rotate(-45deg);
}

.nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: rgba(247, 245, 242, 0.98); /* var(--color-bg) but rgba */
  backdrop-filter: blur(15px);
  -webkit-backdrop-filter: blur(15px);
  z-index: 99;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.nav-overlay.is-active {
  opacity: 1;
  visibility: visible;
}

.overlay-content {
  text-align: center;
}

.overlay-content ul li {
  margin-bottom: 2.5rem;
  overflow: hidden;
}

.overlay-link {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  letter-spacing: 0.1em;
  color: var(--color-primary);
  display: inline-block;
  transform: translateY(110%);
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.nav-overlay.is-active .overlay-link {
  transform: translateY(0);
}

.overlay-content ul li:nth-child(1) .overlay-link { transition-delay: 0.1s; }
.overlay-content ul li:nth-child(2) .overlay-link { transition-delay: 0.2s; }
.overlay-content ul li:nth-child(3) .overlay-link { transition-delay: 0.3s; }
.overlay-content ul li:nth-child(4) .overlay-link { transition-delay: 0.4s; }

.overlay-link.shop-link {
  font-family: var(--font-sans);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  border-bottom: 1px solid var(--color-primary);
  padding-bottom: 0.5rem;
  margin-top: 2rem;
}

/* Hero Section */
.hero {
  position: relative;
  height: 100vh;
  min-height: 700px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

.hero-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 120%; /* Extra height for parallax */
  z-index: -2;
}

.hero-bg {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  transform-origin: center top;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(247,245,242,0.1) 0%, rgba(247,245,242,0.9) 100%);
  z-index: -1;
}

.hero-content {
  margin-top: 15vh;
}

.hero-title {
  font-size: clamp(4rem, 10vw, 8rem);
  line-height: 1;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-family: var(--font-sans);
  font-size: clamp(0.9rem, 2vw, 1.2rem);
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--color-primary);
  opacity: 0.75;
  font-weight: 500;
}

/* Statement 1: Philosophy */
.philosophy {
  padding-bottom: var(--spacing-md);
}

.section-title {
  font-size: clamp(3rem, 6vw, 5rem);
  margin-bottom: 2rem;
  line-height: 1.1;
}

.japanese-lead {
  font-size: clamp(1.2rem, 3vw, 1.8rem);
  color: var(--color-secondary);
  line-height: 2.2;
}

/* Split Sections (Feature) */
.split-section {
  padding: var(--spacing-xl) 0;
}

.split-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8%;
}

.reverse .split-container {
  flex-direction: row-reverse;
}

.split-image-wrapper {
  flex: 1.1;
  position: relative;
  height: 80vh;
  min-height: 500px;
  max-height: 800px;
}

.image-mask {
  width: 100%;
  height: 100%;
  overflow: hidden; /* Important for parallax */
}

/* We make the image taller than container so it can move on scroll */
.image-mask img {
  width: 100%;
  height: 130%;
  object-fit: cover;
  transform: translateY(-15%); /* Initial offset */
}

.split-text-wrapper {
  flex: 0.9;
  padding: 0 2rem;
}

.feature-title {
  font-size: clamp(2.5rem, 5vw, 4.5rem);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.feature-title.italic {
  margin-left: 2rem;
  margin-bottom: 3rem;
  color: var(--color-secondary);
}

.reverse .feature-title.italic {
  margin-left: 0;
  margin-right: 2rem;
}

.feature-desc p {
  margin-bottom: 2rem;
  line-height: 2.2;
  font-size: 1rem;
}

/* Collections Section */
.collections {
  background-color: var(--color-surface);
  padding: var(--spacing-xl) 0;
}

.section-title.small {
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  margin-bottom: 4rem;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 5rem;
}

@media (min-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: auto auto;
    gap: 3rem 1.5rem;
  }
  
  /* Asymmetric Masonry feel */
  .gallery-item:nth-child(2) { margin-top: 4rem; }
  .gallery-item:nth-child(3) { margin-top: 2rem; }
  .gallery-item:nth-child(4) { margin-top: 6rem; }
  .gallery-item:nth-child(5) { margin-top: -3rem; }
  .gallery-item:nth-child(6) { margin-top: 1rem; }
  .gallery-item:nth-child(7) { margin-top: -1rem; }
}

.image-box {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4/5;
  background-color: var(--color-bg);
}

.image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-item:hover .image-box img {
  transform: scale(1.03);
}

/* Footprints (Achievements) Section */
.footprints {
  background-color: var(--color-bg);
}

.footprints-lead {
  font-size: 1.1rem;
  line-height: 2.2;
  margin-bottom: 4rem;
  color: var(--color-primary);
}

.footprints-gallery {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-bottom: 4rem;
}

.footprints-media {
  margin: 0;
}

.footprints-image-box {
  overflow: hidden;
  background-color: var(--color-surface);
  aspect-ratio: 4 / 5;
  box-shadow: 0 12px 30px rgba(0,0,0,0.05);
}

.footprints-image-box img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.footprints-media:hover .footprints-image-box img {
  transform: scale(1.03);
}

.footprints-media:nth-child(3) .footprints-image-box,
.footprints-media:nth-child(5) .footprints-image-box {
  aspect-ratio: 1 / 1;
}

.footprints-grid {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  text-align: left;
  max-width: 900px;
  margin: 0 auto;
}

@media (min-width: 768px) {
  .footprints-gallery {
    grid-template-columns: 1.1fr 0.9fr 0.9fr;
    gap: 1.5rem;
    align-items: end;
  }

  .footprints-media:nth-child(1) {
    grid-column: 1;
    grid-row: 1 / span 2;
  }

  .footprints-media:nth-child(2) {
    grid-column: 2;
    grid-row: 1;
  }

  .footprints-media:nth-child(3) {
    grid-column: 3;
    grid-row: 1;
  }

  .footprints-media:nth-child(4) {
    grid-column: 2;
    grid-row: 2;
  }

  .footprints-media:nth-child(5) {
    grid-column: 3;
    grid-row: 2;
  }

  .footprints-grid {
    flex-direction: row;
    gap: 4rem;
  }
}

.footprints-box {
  flex: 1;
  padding: 3rem 2rem;
  background-color: var(--color-surface);
  box-shadow: 0 10px 40px rgba(0,0,0,0.03);
  border-top: 2px solid var(--color-secondary);
}

.footprints-box h4 {
  font-size: 1.8rem;
  color: var(--color-secondary);
  line-height: 1.2;
  margin-bottom: 1.5rem;
}

.footprints-box p {
  font-size: 0.95rem;
  color: #555;
  line-height: 1.9;
}

/* Closing Section */
.closing {
  padding: var(--spacing-lg) 0 var(--spacing-xl);
}

.closing h3 {
  font-size: 3rem;
}

/* Footer Element */
.footer {
  background-color: var(--color-primary);
  color: #fff;
  padding: 6rem 0 3rem;
  text-align: center;
}

.footer-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3rem;
}

.footer-logo {
  height: 50px;
  filter: invert(1) brightness(2);
}

.footer-social {
  display: flex;
  gap: 4rem;
  font-family: var(--font-sans);
}

.social-link {
  font-size: 0.8rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.6);
  position: relative;
  transition: color 0.4s ease;
}

.social-link::after {
  content: '';
  position: absolute;
  width: 0;
  height: 1px;
  bottom: -6px;
  left: 0;
  background-color: #fff;
  transition: width 0.4s ease;
}

.social-link:hover {
  color: #fff;
}

.social-link:hover::after {
  width: 100%;
}

.footer-copy {
  margin-top: 2rem;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.1em;
}

/* =========================================
   ANIMATIONS (Text Reveal, Fade, Parallax)
   ========================================= */

/* Reveal Text Wrapper (Masking container) */
.reveal-text-wrap {
  overflow: hidden;
  display: inline-block; /* Or block depending on element */
  vertical-align: top;
}

/* Reveal Text Content */
.reveal-text {
  display: inline-block;
  transform: translateY(110%);
  transition: transform 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-text-wrap.active .reveal-text {
  transform: translateY(0);
}

/* Reveal Fade Content */
.reveal-fade {
  opacity: 0;
  transform: translateY(30px);
  transition: all 1.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-fade.active {
  opacity: 1;
  transform: translateY(0);
}

/* Staggering Delays */
.delay-1 { transition-delay: 0.15s; }
.delay-2 { transition-delay: 0.3s; }
.delay-3 { transition-delay: 0.45s; }

/* Responsive Styles */
@media (max-width: 768px) {
  .section,
  .split-section,
  .collections {
    padding: 5rem 0;
  }

  .nav-links {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .navbar {
    padding: 1.25rem 0;
  }

  .nav-brand .brand-logo {
    height: 34px;
  }

  .hero {
    height: 88svh;
    min-height: 540px;
  }

  .hero-content {
    margin-top: 8vh;
    padding: 0 1.25rem;
  }
  
  .split-container, .reverse .split-container {
    flex-direction: column;
    gap: 2rem;
  }
  
  .split-image-wrapper {
    height: 42vh;
    min-height: 320px;
    width: 100%;
  }
  
  .split-text-wrapper {
    padding: 0;
    text-align: center;
  }
  
  .feature-title.italic, .reverse .feature-title.italic {
    margin: 0 0 1.25rem 0;
  }
  
  .reverse .split-text-wrapper {
    text-align: center;
  }

  .feature-desc p,
  .footprints-box p {
    line-height: 1.9;
    font-size: 0.95rem;
  }

  .footprints-lead {
    font-size: 1rem;
    line-height: 2;
    margin-bottom: 2rem;
  }
  
  .gallery-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 3rem;
  }

  .footprints-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.75rem;
    margin-bottom: 2rem;
  }

  .image-box {
    aspect-ratio: 1 / 1.18;
  }

  .footprints-image-box {
    aspect-ratio: 1 / 1.15;
  }

  .footprints-box {
    padding: 2rem 1.25rem;
  }

  .footprints-grid {
    gap: 1.25rem;
  }
  
  .hero-title {
    font-size: clamp(3rem, 16vw, 4.5rem);
  }

  .hero-subtitle {
    font-size: 0.8rem;
    letter-spacing: 0.18em;
  }
  
  .section-title {
    font-size: 2.25rem;
    margin-bottom: 1.5rem;
  }

  .section-title.small {
    margin-bottom: 2.5rem;
  }

  .japanese-lead {
    line-height: 1.8;
  }

  .btn {
    padding: 12px 28px;
    font-size: 0.72rem;
  }

  .footer {
    padding: 4rem 0 2.5rem;
  }

  .footer-container {
    gap: 2rem;
  }

  .footer-social {
    gap: 1.5rem;
    flex-direction: column;
  }

  .footer-copy {
    margin-top: 0;
  }
}
