:root {
  --black: #080808;
  --white: #fff;
  --soft: #f3f4f6;
  --gray: #666;
  --line: #d9d9d9;
  --blue: #315dff;
  --sans: "Noto Sans JP", "Hiragino Kaku Gothic ProN", sans-serif;
  --condensed: "Oswald", sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--black);
  background: var(--white);
  font-family: var(--sans);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 0.5rem;
  left: 0.5rem;
  padding: 0.6rem 1rem;
  color: var(--white);
  background: var(--black);
  transform: translateY(-150%);
}

.skip-link:focus { transform: translateY(0); }

.site-header {
  position: relative;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 82px;
  padding: 0 clamp(1.25rem, 4vw, 4.5rem);
  border-bottom: 1px solid var(--line);
  background: var(--white);
}

.wordmark,
.footer-wordmark {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1;
  text-decoration: none;
}

.wordmark .plane {
  display: block;
  width: 2.35rem;
  height: 2.35rem;
  margin-right: 0.2rem;
  border-radius: 50%;
  overflow: hidden;
}

.wordmark .plane img,
.account-avatar img,
.footer-emblem img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.wordmark small,
.footer-wordmark small {
  display: block;
  margin-left: 0.25rem;
  font-family: var(--condensed);
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  line-height: 1;
  transform: translateY(1px);
}

.site-header nav { display: flex; align-items: center; gap: clamp(1.3rem, 3vw, 3.5rem); }

.site-header nav a {
  font-family: var(--condensed);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-decoration: none;
}

.site-header nav a:not(.nav-instagram) { color: #555; }

.nav-instagram {
  padding: 0.7rem 1rem;
  color: var(--white);
  background: var(--black);
}

.hero {
  position: relative;
  display: grid;
  min-height: calc(100svh - 82px);
  grid-template-columns: minmax(0, 0.82fr) minmax(480px, 1.18fr);
  grid-template-rows: 1fr auto;
  overflow: hidden;
  color: var(--white);
  background: var(--black);
}

.hero-content {
  position: relative;
  z-index: 2;
  display: flex;
  justify-content: center;
  flex-direction: column;
  padding: clamp(4rem, 8vw, 8rem) 5vw clamp(5rem, 9vw, 8rem) max(5vw, calc((100vw - 1440px) / 2));
}

.hero-emblem {
  position: absolute;
  z-index: -1;
  right: -7rem;
  bottom: -8rem;
  width: min(37vw, 33rem);
  max-width: none;
  opacity: 0.055;
  filter: invert(1);
  mix-blend-mode: screen;
  pointer-events: none;
}

.hero-kicker,
.section-kicker {
  margin: 0 0 1.5rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.16em;
}

.hero-kicker span {
  display: block;
  margin-top: 0.3rem;
  color: rgba(255, 255, 255, 0.45);
  font-family: var(--condensed);
  font-size: 0.58rem;
  letter-spacing: 0.2em;
}

h1, h2, p { margin-top: 0; }

.hero h1 {
  max-width: 9.8em;
  margin-bottom: 2rem;
  font-size: clamp(3.1rem, 4.2vw, 4.6rem);
  font-weight: 900;
  line-height: 1.27;
  letter-spacing: -0.075em;
}

.hero h1 span { color: #75bfff; }

.hero-description {
  margin-bottom: 2.25rem;
  color: rgba(255, 255, 255, 0.68);
  font-size: clamp(0.85rem, 1.1vw, 1rem);
}

.hero-button,
.instagram-button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  width: min(100%, 22rem);
  padding: 1rem 1.15rem 1rem 1.4rem;
  color: var(--white);
  background: var(--blue);
  font-size: 0.85rem;
  font-weight: 800;
  text-decoration: none;
  transition: transform 180ms ease, background 180ms ease;
}

.hero-button:hover,
.instagram-button:hover { transform: translateY(-3px); background: #2147dd; }

.hero-photo {
  position: relative;
  display: grid;
  min-height: 620px;
  overflow: hidden;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: auto;
  align-content: center;
  gap: 1px;
  background: var(--black);
}

.hero-photo::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(90deg, rgba(8, 8, 8, 0.18), transparent 30%), linear-gradient(0deg, rgba(8, 8, 8, 0.18), transparent 40%);
  pointer-events: none;
}

.hero-photo img {
  width: 100%;
  height: auto;
  min-width: 0;
  min-height: 0;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center;
}

.hero-photo-label {
  position: absolute;
  z-index: 2;
  right: 1.2rem;
  bottom: 1.5rem;
  color: var(--white);
  font-family: var(--condensed);
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  line-height: 1.3;
  text-align: right;
}

.hero-ticker {
  position: relative;
  z-index: 3;
  grid-column: 1 / -1;
  overflow: hidden;
  padding: 0.65rem 0;
  color: var(--black);
  background: var(--white);
  white-space: nowrap;
}

.ticker-track {
  display: flex;
  width: max-content;
  will-change: transform;
  animation: ticker 36s linear infinite;
}

.ticker-group {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 1.6rem;
  min-width: 100vw;
  padding-right: 1.6rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.hero-ticker i { color: var(--blue); font-size: 0.42rem; }

@keyframes ticker { to { transform: translateX(-50%); } }

.about {
  display: grid;
  width: min(1260px, calc(100% - 3rem));
  margin: 0 auto;
  padding: clamp(6rem, 12vw, 11rem) 0;
  grid-template-columns: 0.12fr 1fr 0.92fr;
  gap: clamp(2rem, 5vw, 6rem);
}

.about-number {
  padding-top: 0.5rem;
  border-top: 2px solid var(--black);
  font-family: var(--condensed);
  font-size: 0.7rem;
}

.section-kicker {
  color: var(--blue);
  font-family: var(--condensed);
  font-weight: 700;
  letter-spacing: 0.19em;
}

.about h2,
.notes-heading h2,
.instagram-copy h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 4.25rem);
  font-weight: 900;
  line-height: 1.45;
  letter-spacing: -0.065em;
}

.about-copy {
  padding-top: 3.8rem;
  color: var(--gray);
  font-size: 0.92rem;
}

.account-line {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-top: 2.3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--line);
  color: var(--black);
}

.account-avatar {
  flex: 0 0 auto;
  width: 3.3rem;
  height: 3.3rem;
  border-radius: 50%;
  overflow: hidden;
}

.account-line div { display: flex; flex-direction: column; }
.account-line strong { font-size: 0.83rem; }
.account-line small { color: var(--gray); font-size: 0.7rem; }

.travel-notes {
  padding: clamp(5rem, 9vw, 9rem) max(1.25rem, calc((100vw - 1440px) / 2));
  color: var(--white);
  background: var(--black);
}

.notes-heading {
  display: grid;
  width: min(1260px, calc(100% - 3rem));
  margin: 0 auto 4rem;
  grid-template-columns: 1fr 1fr;
  align-items: end;
}

.notes-heading .section-kicker { grid-column: 1 / -1; }
.notes-heading > p:last-child { justify-self: end; margin-bottom: 0.8rem; color: rgba(255,255,255,.5); font-size: 0.8rem; }

.post-grid {
  display: grid;
  width: min(1320px, calc(100% - 3rem));
  margin: 0 auto;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.8rem;
}

.post-card {
  position: relative;
  display: flex;
  min-height: 0;
  aspect-ratio: 1;
  padding: 1.6rem;
  overflow: hidden;
  flex-direction: column;
  justify-content: flex-end;
  color: var(--white);
  background-color: #126bbe;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  text-decoration: none;
  transition: filter 180ms ease, transform 180ms ease;
}

.post-card:hover { filter: saturate(1.15); transform: translateY(-5px); }
.post-card-1 { background-image: url("assets/posts/ishikiriyama.jpg"); }
.post-card-2 { background-image: url("assets/posts/station-scenery.jpg"); }
.post-card-3 { background-image: url("assets/posts/fukuchiyama-line.jpg"); }

.post-arrow {
  position: absolute;
  right: 1.3rem;
  bottom: 1.3rem;
  display: grid;
  place-items: center;
  width: 2.6rem;
  height: 2.6rem;
  border: 1px solid rgba(255,255,255,.8);
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.48);
  backdrop-filter: blur(4px);
}

.instagram-section {
  display: grid;
  width: min(1260px, calc(100% - 3rem));
  margin: 0 auto;
  padding: clamp(6rem, 12vw, 11rem) 0;
  grid-template-columns: 1.05fr 0.95fr;
  align-items: center;
  gap: clamp(3rem, 8vw, 8rem);
}

.instagram-preview {
  position: relative;
  aspect-ratio: 1.25 / 1;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--soft);
  box-shadow: 1.5rem 1.5rem 0 var(--soft);
}

.instagram-preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.instagram-copy > p:not(.section-kicker) { margin: 1.5rem 0 2.2rem; color: var(--gray); font-size: 0.9rem; }

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 2.5rem clamp(1.25rem, 5vw, 5rem);
  color: var(--white);
  background: var(--black);
}

.footer-wordmark { font-size: 1.25rem; }
.footer-emblem {
  display: inline-block;
  width: 2.25rem;
  height: 2.25rem;
  margin-right: 0.25rem;
  border-radius: 50%;
  overflow: hidden;
  filter: invert(1);
}
.site-footer p { margin: 0; color: rgba(255,255,255,.45); font-family: var(--condensed); font-size: .65rem; letter-spacing: .12em; }

.reveal { opacity: 0; transform: translateY(20px); animation: reveal .72s cubic-bezier(.22,1,.36,1) forwards; }
.delay-1 { animation-delay: .12s; }
.delay-2 { animation-delay: .24s; }
.delay-3 { animation-delay: .36s; }

@keyframes reveal { to { opacity: 1; transform: translateY(0); } }

@media (max-width: 900px) {
  .site-header nav a:not(.nav-instagram) { display: none; }

  .hero {
    min-height: auto;
    grid-template-columns: 1fr;
  }

  .hero-content { padding: 5.5rem 1.5rem 4.5rem; }
  .hero h1 { font-size: clamp(3rem, 13vw, 5.5rem); }
  .hero-photo {
    min-height: min(150vw, 900px);
    grid-template-columns: repeat(2, 1fr);
    grid-template-rows: none;
  }

  .about { grid-template-columns: .12fr 1fr; }
  .about-copy { grid-column: 2; padding-top: 0; }

  .notes-heading { grid-template-columns: 1fr; }
  .notes-heading > p:last-child { justify-self: start; margin-top: 1.5rem; }

  .post-grid { grid-template-columns: 1fr; }
  .post-card { min-height: 0; }

  .instagram-section { grid-template-columns: 1fr; }
  .instagram-preview { order: 2; }
}

@media (max-width: 560px) {
  .site-header { height: 68px; padding-inline: 1rem; }
  .wordmark { font-size: 1.15rem; }
  .wordmark .plane { width: 2rem; height: 2rem; }
  .wordmark small { display: none; }
  .nav-instagram { padding: .55rem .7rem !important; font-size: .62rem !important; }

  .hero { min-height: calc(100svh - 68px); }
  .hero-content { padding: 4rem 1.25rem; }
  .hero-emblem { right: -5rem; bottom: -2rem; width: 22rem; opacity: 0.04; }
  .hero h1 { font-size: clamp(2.8rem, 12.5vw, 4.1rem); }
  .hero-photo { min-height: 150vw; }

  .about,
  .notes-heading,
  .post-grid,
  .instagram-section { width: calc(100% - 2.5rem); }

  .about { display: block; }
  .about-number { width: 2.5rem; margin-bottom: 2rem; }
  .about-copy { margin-top: 2rem; }

  .travel-notes { padding-inline: 0; }
  .post-card { min-height: 0; }

  .instagram-preview { box-shadow: .75rem .75rem 0 var(--soft); }
  .instagram-button { width: 100%; }
  .site-footer { align-items: flex-start; flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .ticker-track { animation: none; }
}
