@font-face {
  font-family: 'NHaasGrotesk';
  src: url('fonts/nhaasgroteskdspro-75bd.otf') format('opentype');
  font-weight: 700;
  font-style: normal;
}

@font-face {
  font-family: 'MiGoMB1';
  src: url('fonts/A-OTF-MiGoMB1Std-DeBold.otf') format('opentype');
  font-weight: 700;
  font-style: normal;
}

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

html {
  font-size: 16px;
}

body {
  background: #fff;
  color: #000;
  font-family: 'NHaasGrotesk', 'Noto Sans JP', 'Hiragino Kaku Gothic ProN', sans-serif;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ===== OPENING ANIMATION ===== */
.opening {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1000;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.opening.done {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
}

.opening-slash {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  height: 100%;
  width: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  clip-path: inset(0 0 100% 0);
  transition: clip-path 1.0s cubic-bezier(0.22, 1, 0.36, 1);
}

.opening-slash.active {
  clip-path: inset(0 0 0 0);
}

.opening-slash.exit {
  clip-path: inset(100% 0 0 0);
  transition: clip-path 1.0s cubic-bezier(0.22, 1, 0.36, 1);
}

.opening-slash-img {
  height: 100%;
  width: auto;
}

.opening-logo {
  position: absolute;
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.opening-logo.active {
  opacity: 1;
  transform: translateY(0);
}

.opening-logo-img {
  height: 60px;
  width: auto;
}

/* Page hidden during opening */
.page-wrapper.hidden {
  visibility: hidden;
}

.page-wrapper {
  max-width: 540px;
  margin: 0 auto;
  padding: 0 0 40px;
}

/* ===== HERO SECTION ===== */
.hero {
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.hero.visible {
  opacity: 1;
  transform: none;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 24px 16px 0;
}

.header-left {
  font-weight: 700;
}

.header-logo {
  height: 48px;
  width: auto;
  display: block;
}

.header-right {
  display: flex;
  gap: 16px;
  font-size: 0.7rem;
  font-style: italic;
  opacity: 0.8;
  padding-top: 6px;
}

.header-right a {
  color: #000;
  text-decoration: none;
}

.header-right a:hover {
  text-decoration: underline;
}

.hero-title {
  position: relative;
  overflow: hidden;
  margin-top: 16px;
}

.hero-img {
  width: 100%;
  height: auto;
  display: block;
}

.hero + .manga-grid {
  margin-top: 6px;
}

.hero-title::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  transform-origin: right;
  transition: transform 1.2s cubic-bezier(0.77, 0, 0.175, 1) 0.4s;
  z-index: 2;
}

.hero.visible .hero-title::after {
  transform: scaleX(0);
}

/* ===== MANGA GRID ===== */
.manga-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0 16px;
}

/* Panel base */
.panel {
  overflow: hidden;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
              transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

.panel.visible {
  opacity: 1;
  transform: none;
}

/* Panel rows - each row has its own border */
.panel-row {
  display: flex;
  gap: 10px;
}

/* Individual panel borders */
.panel-row .panel {
  border: 7px solid #000;
}

/* ===== PARCO + SUBTITLE ===== */
.panel-parco {
  flex: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 50px 36px;
  background: #fff;
  min-height: 280px;
  transform: scale(0.9);
}
.panel-parco.visible { transform: scale(1); }

.parco-logo-img {
  width: 65%;
  height: auto;
  display: block;
}

.panel-subtitle {
  flex: 1;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  min-height: 280px;
  transform: translateX(20px);
}
.panel-subtitle.visible { transform: translateX(0); }

/* ===== SLASH + KODANSHA ===== */
.panel-slash {
  flex: 0.38;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  overflow: hidden;
  transform: translateX(-20px);
}
.panel-slash.visible { transform: translateX(0); }

.slash-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.panel-kodansha {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 28px;
  background: #fff;
  min-height: 160px;
  transform: scale(0.9);
}
.panel-kodansha.visible { transform: scale(1); }

.kodansha-logo-img {
  width: 82%;
  height: auto;
  display: block;
}

/* ===== COPY IMAGE (subtitle) ===== */
.copy-img {
  width: 50%;
  height: auto;
  display: block;
}

/* ===== TEXT BLOCKS ===== */
.panel-texts {
  border: 7px solid #000;
  padding: 20px;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

.body-img {
  width: 90%;
  height: auto;
  display: block;
}

/* ===== DATE BANNER ===== */
.panel-date {
  border: 7px solid #000;
  background: #000;
  color: #fff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px 24px;
  gap: 0;
}

.date-headline {
  font-family: 'MiGoMB1', 'Hiragino Mincho ProN', 'Yu Mincho', serif;
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.date-sub {
  font-family: 'MiGoMB1', 'Hiragino Mincho ProN', 'Yu Mincho', serif;
  font-size: 0.82rem;
  letter-spacing: 0.02em;
}

.date-note {
  font-family: 'MiGoMB1', 'Hiragino Mincho ProN', 'Yu Mincho', serif;
  font-size: 0.72rem;
  letter-spacing: 0.02em;
  opacity: 0.7;
}

/* ===== FOOTER ===== */
.footer {
  text-align: center;
  padding: 20px;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  opacity: 0;
  transition: opacity 0.6s ease 0.2s;
}

.footer.visible {
  opacity: 1;
}

/* ===== ANIMATION STAGGER ===== */
.panel-row .panel:nth-child(2) {
  transition-delay: 0.15s;
}

/* ===== SCROLL PROGRESS ===== */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: #000;
  z-index: 200;
  transform-origin: left;
  transform: scaleX(0);
  width: 100%;
  pointer-events: none;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 400px) {
  .page-wrapper {
    padding: 0 0 20px;
  }

  .manga-grid {
    margin: 0 6px;
    gap: 8px;
  }

  .panel-row {
    gap: 8px;
  }

  .header {
    padding: 14px 12px 0;
  }

  .body-text {
    font-size: 1.1rem;
    height: 480px;
  }
}
