:root {
  --paper: #fbfaf7;
  --ink: #241610;
  --muted: #6f6a61;
  --line: #e5e0d7;
  --red: #c9412c;
  --red-dark: #9f2f20;
  --card: #ffffff;
  --sakura: #f7dde2;
  --sakura-mid: #eeb4c1;
  --sakura-deep: #c96f86;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Zen Kaku Gothic New", "Hiragino Sans", sans-serif;
  line-height: 1.65;
}
a { color: inherit; }
a:focus-visible, button:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 4px;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to { opacity: 1; transform: translateY(0); }
}
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .65s ease, transform .65s ease;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation: none !important; }
}

.wrap {
  width: min(1120px, calc(100% - 48px));
  margin: 0 auto;
}
.accent-bar {
  height: 5px;
  width: 100%;
  background: linear-gradient(90deg, var(--red) 0%, var(--red) 55%, var(--sakura-mid) 100%);
}

header {
  background: rgba(251,250,247,.94);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(12px);
}
.header-row {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  text-decoration: none;
}
.wordmark {
  font-family: "Shippori Mincho", serif;
  font-size: 23px;
  font-weight: 700;
  letter-spacing: -.01em;
  color: var(--ink);
}
nav ul {
  list-style: none;
  display: flex;
  gap: 28px;
  margin: 0;
  padding: 0;
}
nav a {
  text-decoration: none;
  color: var(--muted);
  font-size: 14px;
  font-weight: 500;
  transition: color .2s ease;
}
nav a:hover, nav a[aria-current="page"] { color: var(--red); }

/* Hero */
.hero-band {
  background:
    radial-gradient(circle at 86% 18%, rgba(201,65,44,.11), transparent 24%),
    radial-gradient(circle at 14% 12%, rgba(238,180,193,.4), transparent 28%),
    radial-gradient(circle at 8% 92%, rgba(0,0,0,.035), transparent 25%),
    var(--paper);
  border-bottom: 1px solid var(--line);
  position: relative;
  overflow: hidden;
}
.hero {
  min-height: 470px;
  padding: 82px 0 70px;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
  gap: 70px;
}
.hero-copy { animation: rise .75s ease both; }
.hero-jp {
  font-family: "Shippori Mincho", serif;
  font-weight: 700;
  color: var(--red);
  font-size: clamp(52px, 7vw, 82px);
  line-height: .95;
  margin: 0 0 20px;
}
.hero h1 {
  font-family: "Shippori Mincho", serif;
  font-size: clamp(34px, 5vw, 52px);
  line-height: 1.15;
  margin: 0 0 18px;
  letter-spacing: -.025em;
}
.hero p {
  max-width: 57ch;
  color: var(--muted);
  font-size: 16px;
  margin: 0;
}
.hero-photo {
  min-height: 350px;
  border-radius: 2px;
  box-shadow: 18px 18px 0 rgba(238,180,193,.55);
  animation: rise .75s ease .12s both;
  position: relative;
  overflow: hidden;
}
.hero-photo::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(0,0,0,.03), rgba(0,0,0,.1));
  z-index: 1;
  pointer-events: none;
}
.hero-slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background-repeat: no-repeat, repeat;
  background-position: center, top left;
  background-size: cover, 34px 34px;
  opacity: 0;
  transition: opacity 1s ease;
}
.hero-slide.is-active { opacity: 1; }
.hero-slide:nth-child(1) { --ph-pattern: repeating-linear-gradient(135deg, #e7c3cd 0 14px, #f2d6de 14px 28px); }
.hero-slide:nth-child(2) { --ph-pattern: repeating-linear-gradient(135deg, #d9cdbf 0 14px, #ebe1d6 14px 28px); }
.hero-slide:nth-child(3) { --ph-pattern: repeating-linear-gradient(135deg, #d2a99f 0 14px, #e6c6be 14px 28px); }
.hero-slide:nth-child(4) { --ph-pattern: repeating-linear-gradient(135deg, #b9a89d 0 14px, #d8ccc1 14px 28px); }
.hero-slide:not([style*="background-image"]) { background-image: var(--ph-pattern); }
.hero-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.85);
  color: var(--ink);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, transform .2s ease;
}
.hero-arrow:hover { background: #fff; transform: translateY(-50%) scale(1.06); }
.hero-arrow.prev { left: 14px; }
.hero-arrow.next { right: 14px; }
.hero-dots {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  display: flex;
  gap: 8px;
}
.hero-dot {
  width: 8px;
  height: 8px;
  padding: 0;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,.55);
  cursor: pointer;
  transition: background .2s ease, transform .2s ease;
}
.hero-dot:hover { background: rgba(255,255,255,.8); }
.hero-dot.is-active { background: #fff; transform: scale(1.2); }
.petal {
  position: absolute;
  border-radius: 0 60% 60% 60%;
  background: linear-gradient(135deg, var(--sakura), var(--sakura-mid));
  animation: drift 7s ease-in-out infinite;
}
.petals {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  overflow: hidden;
}
@keyframes drift {
  0%, 100% { transform: translateY(0) rotate(var(--rot, 20deg)); }
  50% { transform: translateY(10px) rotate(calc(var(--rot, 20deg) + 8deg)); }
}
.hero-photo::after {
  content: "NIHONTOPIA";
  position: absolute;
  top: 16px;
  left: 20px;
  color: #fff;
  font-size: 11px;
  letter-spacing: .2em;
  font-weight: 700;
  text-shadow: 0 1px 8px rgba(0,0,0,.45);
  z-index: 2;
  pointer-events: none;
}

/* Sections */
main.wrap { padding-bottom: 80px; }
.section-heading-wrap {
  padding-top: 70px;
  margin-top: 0;
}
.section-heading {
  font-family: "Shippori Mincho", serif;
  font-size: 28px;
  line-height: 1.2;
  margin: 0 0 7px;
}
.section-heading::after {
  content: "";
  display: block;
  width: 42px;
  height: 4px;
  background: linear-gradient(90deg, var(--red), var(--sakura-mid));
  margin-top: 12px;
}
.section-sub {
  color: var(--muted);
  font-size: 14px;
  margin: 0 0 26px;
}

/* Featured cards */
.showcase-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.showcase-card {
  background: var(--card);
  border: 1px solid var(--line);
  transition: transform .28s ease, box-shadow .28s ease;
  overflow: hidden;
}
.showcase-card:hover {
  transform: translateY(-7px);
  box-shadow: 0 18px 35px rgba(201,111,134,.16);
}
.showcase-art {
  height: 205px;
  margin: 0;
  border-radius: 0;
  background-repeat: no-repeat, repeat;
  background-position: center, top left;
  background-size: cover, 28px 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}
.showcase-art::after {
  content: "FEATURED";
  position: absolute;
  left: 16px;
  top: 15px;
  background: var(--red);
  color: #fff;
  padding: 5px 9px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: .13em;
}
.showcase-card:nth-child(1) .showcase-art {
  --ph-pattern: repeating-linear-gradient(135deg, #f2d6de 0 14px, #f7e3e8 14px 28px);
}
.showcase-card:nth-child(2) .showcase-art {
  --ph-pattern: repeating-linear-gradient(135deg, #ebe1d6 0 14px, #f5efe7 14px 28px);
}
.showcase-card:nth-child(3) .showcase-art {
  --ph-pattern: repeating-linear-gradient(135deg, #e6c6be 0 14px, #f0dcd6 14px 28px);
}
.showcase-art:not([style*="background-image"]) { background-image: var(--ph-pattern); }
.showcase-card h3 {
  font-family: "Shippori Mincho", serif;
  font-size: 20px;
  line-height: 1.35;
  margin: 20px 20px 8px;
}
.showcase-card h3 a {
  text-decoration: none;
  transition: color .2s ease;
}
.showcase-card h3 a:hover { color: var(--red); }
.showcase-card p {
  color: var(--muted);
  font-size: 14px;
  margin: 0 20px 22px;
}

/* Recent posts */
.posts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.post {
  background: var(--card);
  border: 1px solid var(--line);
  padding: 0;
  transition: transform .28s ease, box-shadow .28s ease;
  overflow: hidden;
}
.post:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(201,111,134,.14);
}
.post-art {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 170px;
  background-repeat: no-repeat, repeat;
  background-position: center, top left;
  background-size: cover, 26px 26px;
}
.post:nth-child(1) .post-art {
  --ph-pattern: repeating-linear-gradient(135deg, #d8ccc1 0 14px, #ece4da 14px 28px);
}
.post:nth-child(2) .post-art {
  --ph-pattern: repeating-linear-gradient(135deg, #f2d6de 0 14px, #f7e3e8 14px 28px);
}
.post:nth-child(3) .post-art {
  --ph-pattern: repeating-linear-gradient(135deg, #ebe1d6 0 14px, #f5efe7 14px 28px);
}
.post-art:not([style*="background-image"]) { background-image: var(--ph-pattern); }
.post-meta {
  margin: 20px 20px 7px;
  color: var(--red-dark);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.post h3 {
  font-family: "Shippori Mincho", serif;
  font-size: 20px;
  line-height: 1.35;
  margin: 0 20px 8px;
}
.post h3 a {
  text-decoration: none;
  transition: color .2s ease;
}
.post h3 a:hover { color: var(--red); }
.post p {
  color: var(--muted);
  font-size: 14px;
  margin: 0 20px 24px;
}

/* Footer */
footer {
  margin-top: 20px;
  background: #1b110c;
  color: #fff;
  border-top: 4px solid var(--red);
  border-image: linear-gradient(90deg, var(--red) 0%, var(--red) 55%, var(--sakura-mid) 100%) 1;
}
.footer-inner {
  padding: 58px 0 38px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 30px;
}
.footer-wordmark {
  font-family: "Shippori Mincho", serif;
  font-size: 26px;
  font-weight: 700;
}
.footer-tagline {
  margin: 3px 0 0;
  color: rgba(255,255,255,.52);
  font-size: 13px;
}
.footer-nav ul { gap: 22px; }
.footer-nav a { color: rgba(255,255,255,.68); }
.footer-nav a:hover { color: #fff; }
.footer-copyright {
  margin: 0;
  color: rgba(255,255,255,.4);
  font-size: 12px;
}

@media (max-width: 820px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 38px;
    padding-top: 58px;
  }
  .hero-photo { min-height: 310px; }
  .showcase-grid, .posts { grid-template-columns: 1fr 1fr; }
  .footer-inner { flex-wrap: wrap; }
}
@media (max-width: 560px) {
  .wrap { width: min(100% - 32px, 1120px); }
  .header-row { min-height: 70px; align-items: flex-start; padding: 18px 0; flex-direction: column; }
  nav ul { gap: 15px; flex-wrap: wrap; }
  .hero { padding: 48px 0 52px; }
  .hero-photo { min-height: 250px; box-shadow: 10px 10px 0 rgba(238,180,193,.55); }
  .showcase-grid, .posts { grid-template-columns: 1fr; }
  .showcase-art { height: 220px; }
  .post-art { height: 210px; }
  .footer-inner { flex-direction: column; align-items: flex-start; }
}

/* Events calendar */
.calendar {
  background: var(--card);
  border: 1px solid var(--line);
  padding: 26px;
  margin: 0 0 48px;
}
.calendar-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.calendar-title {
  font-family: "Shippori Mincho", serif;
  font-size: 21px;
  margin: 0;
}
.calendar-nav { display: flex; gap: 8px; }
.calendar-nav button {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.calendar-nav button:hover {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}
.calendar-weekday {
  text-align: center;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--muted);
  padding-bottom: 8px;
}
.calendar-day {
  position: relative;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-family: inherit;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  padding: 0;
  margin: 0;
}
.calendar-day.is-outside { background: transparent; border-color: transparent; }
.calendar-day.is-today { border-color: var(--red); font-weight: 700; }
button.calendar-day { cursor: pointer; background: #fff; transition: background .2s ease; }
button.calendar-day:hover { background: var(--sakura); }
.calendar-day .event-dot {
  position: absolute;
  bottom: 5px;
  left: 50%;
  transform: translateX(-50%);
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--red);
}

/* Events agenda list */
.agenda-list { display: flex; flex-direction: column; gap: 18px; }
.event-card {
  display: flex;
  background: var(--card);
  border: 1px solid var(--line);
  overflow: hidden;
  scroll-margin-top: 110px;
  outline: 2px solid transparent;
  outline-offset: -2px;
  transition: outline-color .3s ease;
}
.event-card.is-highlighted { outline-color: var(--red); }
.event-card-art {
  flex: 0 0 160px;
  background-repeat: no-repeat, repeat;
  background-position: center, top left;
  background-size: cover, 24px 24px;
  --ph-pattern: repeating-linear-gradient(135deg, #f2d6de 0 14px, #f7e3e8 14px 28px);
}
.event-card-art:not([style*="background-image"]) { background-image: var(--ph-pattern); }
.event-card-body { padding: 20px 22px; flex: 1; }
.event-type-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--red-dark);
  background: var(--sakura);
  padding: 4px 9px;
  margin-bottom: 10px;
}
.event-date {
  color: var(--muted);
  font-size: 13px;
  margin: 0 0 4px;
}
.event-card h3 {
  font-family: "Shippori Mincho", serif;
  font-size: 19px;
  margin: 0 0 8px;
}
.event-desc {
  color: var(--muted);
  font-size: 14px;
  margin: 0;
}

@media (max-width: 560px) {
  .event-card { flex-direction: column; }
  .event-card-art { width: 100%; height: 150px; }
  .calendar { padding: 18px; }
  .calendar-day { font-size: 12px; }
}

/* Google Calendar embed (replaces the custom calendar) */
.calendar-embed {
  background: var(--card);
  border: 1px solid var(--line);
  padding: 4px;
}
.calendar-embed iframe {
  display: block;
  width: 100%;
  min-height: 650px;
}
@media (max-width: 560px) {
  .calendar-embed iframe { min-height: 500px; }
}

/* Who We Are page */
.about-body {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
  max-width: 70ch;
  margin-top: 18px;
}
.about-body p { margin: 0 0 18px; }
.about-body a { color: var(--red); text-decoration: underline; }

.team-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.team-card {
  background: var(--card);
  border: 1px solid var(--line);
  text-align: center;
  padding: 26px 18px;
}
.team-photo {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  margin: 0 auto 16px;
  background-repeat: no-repeat, repeat;
  background-position: center, top left;
  background-size: cover, 20px 20px;
  --ph-pattern: repeating-linear-gradient(135deg, #f2d6de 0 14px, #f7e3e8 14px 28px);
}
.team-photo:not([style*="background-image"]) { background-image: var(--ph-pattern); }
.team-card h3 {
  font-family: "Shippori Mincho", serif;
  font-size: 17px;
  margin: 0 0 4px;
}
.team-role {
  color: var(--red-dark);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  margin: 0 0 12px;
}
.team-bio {
  color: var(--muted);
  font-size: 13px;
  margin: 0;
}

@media (max-width: 820px) {
  .team-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .team-grid { grid-template-columns: 1fr; }
}

/* Photos gallery */
.photo-grid {
  columns: 3;
  column-gap: 20px;
}
.photo-item {
  display: block;
  position: relative;
  width: 100%;
  margin: 0 0 20px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--card);
  overflow: hidden;
  cursor: zoom-in;
  break-inside: avoid;
  transition: transform .28s ease, box-shadow .28s ease;
}
.photo-item:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(201,111,134,.14);
}
.photo-item img {
  display: block;
  width: 100%;
  height: auto;
}
.photo-item-title {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 28px 14px 10px;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  text-align: left;
  background: linear-gradient(transparent, rgba(27,17,12,.7));
  opacity: 0;
  transition: opacity .25s ease;
}
.photo-item:hover .photo-item-title,
.photo-item:focus-visible .photo-item-title { opacity: 1; }

/* Slideshow popup */
.lightbox {
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 0;
  border: none;
  background: rgba(27,17,12,.94);
  color: #fff;
}
.lightbox[open] {
  display: flex;
  align-items: center;
  justify-content: center;
}
.lightbox::backdrop { background: rgba(27,17,12,.94); }
.lightbox-figure {
  margin: 0;
  max-width: min(1000px, calc(100% - 140px));
  max-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.lightbox-img {
  max-width: 100%;
  max-height: calc(100vh - 190px);
  object-fit: contain;
  box-shadow: 14px 14px 0 rgba(238,180,193,.4);
}
.lightbox-caption {
  display: flex;
  flex-direction: column;
  gap: 4px;
  text-align: center;
  max-width: 62ch;
}
.lightbox-title {
  font-family: "Shippori Mincho", serif;
  font-size: 20px;
}
.lightbox-title:empty, .lightbox-desc:empty { display: none; }
.lightbox-desc {
  color: rgba(255,255,255,.78);
  font-size: 14px;
}
.lightbox-count {
  margin-top: 4px;
  color: var(--sakura-mid);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
}
.lightbox-close,
.lightbox-arrow {
  position: absolute;
  border: none;
  border-radius: 50%;
  background: rgba(255,255,255,.85);
  color: var(--ink);
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, transform .2s ease;
}
.lightbox-close:hover, .lightbox-arrow:hover { background: #fff; }
.lightbox-close { top: 20px; right: 20px; width: 40px; height: 40px; font-size: 24px; }
.lightbox-arrow { top: 50%; width: 46px; height: 46px; font-size: 24px; transform: translateY(-50%); }
.lightbox-arrow:hover { transform: translateY(-50%) scale(1.06); }
.lightbox-arrow.prev { left: 24px; }
.lightbox-arrow.next { right: 24px; }

@media (max-width: 820px) { .photo-grid { columns: 2; } }
@media (max-width: 560px) {
  .photo-grid { columns: 1; }
  .lightbox-figure { max-width: calc(100% - 32px); }
  .lightbox-arrow { top: auto; bottom: 20px; transform: none; }
  .lightbox-arrow:hover { transform: scale(1.06); }
  .lightbox-arrow.prev { left: 20px; }
  .lightbox-arrow.next { right: 20px; }
  .lightbox-img { max-height: calc(100vh - 260px); box-shadow: 8px 8px 0 rgba(238,180,193,.4); }
}

/* Logo */
.logo img {
  display: block;
  height: 40px;
  width: auto;
}
.footer-brand {
  display: flex;
  align-items: center;
  gap: 11px;
}
.footer-brand img {
  display: block;
  height: 32px;
  width: auto;
}
