:root {
  --color-main: #24385a;
  --color-main-dark: #1a2a45;
  --color-main-pale: #e9eef4;
  --color-paper: #f5f0e6;
  --washi: url("../images/washi.jpg");
  --color-accent: #a8844e;
  --color-accent-text: #80612b;
  --color-ink: #2a2a2a;
  --color-sub: #6a645a;
  --color-line: #ddd4c4;
  --color-bg: #ffffff;
  --font-head: "Zen Old Mincho", "Hiragino Mincho ProN", serif;
  --font-hand: "Yuji Syuku", "Hiragino Mincho ProN", serif;
  --font-body: "Noto Sans JP", "Hiragino Sans", sans-serif;
  --wrap: 1080px;
  --gutter: 20px;
  --space-section: 72px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 64px;
}

body {
  margin: 0;
  padding-bottom: max(56px, 3.5rem);
  background: var(--color-bg);
  color: var(--color-ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.85;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

.section-title {
  margin-bottom: 32px;
  font-family: var(--font-head);
  font-size: 1.625rem;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.06em;
  color: var(--color-main);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 8px 28px;
  border: 1px solid transparent;
  border-radius: 2px;
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-align: center;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}

.button--primary {
  background: var(--color-main);
  color: #fff;
}

.button--primary:hover {
  background: var(--color-main-dark);
}

.button--primary::after {
  content: "";
  width: 22px;
  height: 6px;
  margin-left: 14px;
  border-right: 1px solid currentColor;
  border-bottom: 1px solid currentColor;
  transform: skewX(45deg) translateY(-3px);
  transition: transform 0.25s;
}

.button--primary:hover::after {
  transform: translateX(5px) skewX(45deg) translateY(-3px);
}

.button--ghost {
  border-color: var(--color-main);
  background: transparent;
  color: var(--color-main);
}

.button--ghost:hover {
  background: color-mix(in srgb, var(--color-main) 6%, transparent);
}

.button--light {
  background: #fff;
  color: var(--color-main);
}

.button--light:hover {
  background: var(--color-main-pale);
}

.header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--color-line);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 4px 16px;
  max-width: var(--wrap);
  min-height: 56px;
  margin: 0 auto;
  padding: 4px var(--gutter);
}

.header__logo {
  font-family: var(--font-head);
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--color-main);
  text-decoration: none;
}

.header__nav {
  display: none;
}

.hero {
  position: relative;
  overflow: hidden;
  padding: 24px 0 64px;
  background-color: var(--color-paper);
  background-image: var(--washi);
  background-size: 600px;
}

.hero__visual {
  container-type: inline-size;
  position: relative;
  max-width: 1240px;
  margin: 0 auto;
}

.hero__visual::before {
  content: "";
  position: absolute;
  top: 22%;
  right: -50vw;
  left: -50vw;
  height: 50%;
  background-color: var(--color-main);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='60' height='104' viewBox='0 0 60 104'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='0.12' stroke-width='1'%3E%3Cpath d='M30 0L60 17.3V52L30 69.3L0 52V17.3Z'/%3E%3Cpath d='M30 0V34.7M60 17.3L30 34.7M0 17.3L30 34.7M30 69.3V34.7M60 52L30 34.7M0 52L30 34.7'/%3E%3Cpath d='M30 69.3V104M0 52V86.7L30 104L60 86.7V52'/%3E%3Cpath d='M30 69.3L0 86.7M30 69.3L60 86.7M30 104L0 86.7M30 104L60 86.7'/%3E%3C/g%3E%3C/svg%3E");
}

.hero__photo {
  position: relative;
  margin-right: 44px;
}

.hero__photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.hero__card {
  position: absolute;
  right: var(--gutter);
  bottom: -36px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  padding: 26px 18px 24px;
  background: #fff;
  border: 1px solid var(--color-main);
  outline: 1px solid var(--color-main);
  outline-offset: -6px;
  writing-mode: vertical-rl;
}

.hero__title {
  font-family: var(--font-head);
  font-size: 1.75rem;
  font-weight: 700;
  line-height: 1.55;
  letter-spacing: 0.2em;
  color: var(--color-main);
}

.hero__tagline {
  font-family: var(--font-head);
  font-size: 0.75rem;
  letter-spacing: 0.3em;
  color: var(--color-accent-text);
}

.hero__body {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 64px var(--gutter) 0;
}

.hero__lead {
  font-size: 0.9375rem;
  line-height: 2;
  word-break: auto-phrase;
}

.hero__facts {
  display: grid;
  gap: 6px;
  margin-top: 24px;
  padding: 18px 0;
  border-top: 1px solid var(--color-line);
  border-bottom: 1px solid var(--color-line);
  font-size: 0.875rem;
}

.hero__fact-key {
  display: inline-block;
  width: 5.5em;
  color: var(--color-accent-text);
}

.hero__actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 28px;
}

.hero__fact-key i,
.access__key i {
  width: 1.3em;
  margin-right: 6px;
  text-align: center;
}

.access__key {
  white-space: nowrap;
}

.teacher__value,
.access__value {
  flex: 1 1 12em;
  min-width: 0;
  overflow-wrap: anywhere;
}

.button i,
.contact__note i {
  margin-right: 8px;
}

.footer__sns {
  display: flex;
  gap: 14px;
  margin: 6px 0;
}

.footer__link {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border: 1px solid var(--color-line);
  border-radius: 50%;
  color: var(--color-main);
  text-decoration: none;
}

.footer__link:hover {
  border-color: var(--color-accent);
  color: var(--color-accent-text);
}

.fixed-cta {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 20;
}

.fixed-cta__item {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 56px;
  padding: 6px 12px;
  line-height: 1.4;
  text-align: center;
  background: var(--color-main);
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.about {
  position: relative;
  overflow: hidden;
  padding: var(--space-section) 0;
}

.about__ume {
  position: absolute;
  top: -10px;
  right: -60px;
  width: 200px;
  opacity: 0.45;
  pointer-events: none;
}

.about__inner {
  position: relative;
}

.about__inner,
.course__inner,
.flow__inner,
.faq__inner,
.access__inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.about__intro {
  align-self: center;
  writing-mode: vertical-rl;
  font-family: var(--font-head);
  font-size: 1.0625rem;
  line-height: 2.3;
  letter-spacing: 0.14em;
  color: var(--color-main);
}

.about__side {
  container-type: inline-size;
  display: flex;
  flex-direction: column;
  margin-bottom: 40px;
}

.about__photo {
  margin-top: 36px;
}

.about__photo img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.about__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
}

.about__item {
  padding-left: 18px;
  border-left: 2px solid var(--color-accent);
}

.about__heading {
  margin-bottom: 8px;
  font-family: var(--font-head);
  font-size: 1.1875rem;
  font-weight: 700;
  color: var(--color-main);
}

.about__text {
  font-size: 0.9375rem;
  color: var(--color-sub);
}

.course {
  position: relative;
  overflow: hidden;
  padding: var(--space-section) 0;
  background-color: var(--color-paper);
  background-image: var(--washi);
  background-size: 600px;
}

.course__inner {
  position: relative;
}

.course__deco {
  position: absolute;
  pointer-events: none;
}

.course__deco--obijime {
  top: 20px;
  right: -36px;
  width: 150px;
  transform: rotate(-12deg);
}

.teacher__photo {
  position: relative;
}

.course__list {
  display: grid;
  gap: 1px;
  background: var(--color-line);
  border: 1px solid var(--color-line);
}

.course__item {
  padding: 28px 24px;
  background: #fff;
}

.course__item--main {
  border-top: 4px solid var(--color-main);
}

.course__name {
  font-family: var(--font-head);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-main);
}

.course__price {
  margin-top: 8px;
  font-size: 0.9375rem;
}

.course__amount {
  font-family: var(--font-head);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.course__note {
  font-size: 0.8125rem;
  color: var(--color-sub);
}

.course__text {
  margin-top: 12px;
  font-size: 0.9375rem;
}

.course__spec {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px dashed var(--color-line);
  font-size: 0.875rem;
  color: var(--color-sub);
}

.course__spec-item::before {
  content: "";
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-right: 10px;
  vertical-align: middle;
  background: var(--color-accent);
  transform: rotate(45deg);
}

.teacher {
  overflow-x: clip;
  padding: var(--space-section) 0;
}

.teacher__inner {
  display: grid;
  gap: 32px;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.teacher__photo img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.teacher__name {
  font-family: var(--font-head);
  font-size: 1.5rem;
  font-weight: 700;
}

.teacher__role {
  margin-left: 12px;
  font-family: var(--font-body);
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--color-sub);
}

.teacher__text {
  margin-top: 16px;
  font-size: 0.9375rem;
}

.teacher__profile {
  margin-top: 24px;
  border-top: 1px solid var(--color-line);
}

.teacher__row,
.access__row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--color-line);
  font-size: 0.9375rem;
}

.teacher__key,
.access__key {
  flex: 0 0 8em;
  font-weight: 700;
  color: var(--color-main);
}

.flow {
  position: relative;
  overflow: hidden;
  padding: var(--space-section) 0;
  background-color: var(--color-paper);
  background-image: var(--washi);
  background-size: 600px;
}

.flow__list {
  display: grid;
  gap: 24px;
  counter-reset: flow;
}

.flow__step {
  position: relative;
  padding-left: 64px;
  counter-increment: flow;
}

.flow__step::before {
  content: counter(flow);
  position: absolute;
  top: 0;
  left: 0;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--color-main);
  border-radius: 50%;
  font-family: var(--font-head);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-main);
}

.flow__heading {
  font-family: var(--font-head);
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--color-main);
}

.flow__text {
  margin-top: 4px;
  font-size: 0.9375rem;
  color: var(--color-sub);
}

.faq {
  position: relative;
  overflow: hidden;
  padding: var(--space-section) 0;
}

.faq__ume {
  position: absolute;
  top: -16px;
  left: -60px;
  width: 170px;
  opacity: 0.28;
  transform: rotate(8deg);
  pointer-events: none;
}

.faq__inner {
  position: relative;
}

.faq__list {
  border-top: 1px solid var(--color-line);
}

.faq__item {
  border-bottom: 1px solid var(--color-line);
}

.faq__question {
  position: relative;
  padding: 20px 36px 20px 0;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}

.faq__question::-webkit-details-marker {
  display: none;
}

.faq__question::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 8px;
  width: 10px;
  height: 10px;
  margin-top: -7px;
  border-right: 1.5px solid var(--color-main);
  border-bottom: 1.5px solid var(--color-main);
  transform: rotate(45deg);
  transition: transform 0.2s;
}

.faq__item[open] .faq__question::after {
  margin-top: -2px;
  transform: rotate(-135deg);
}

.faq__answer {
  padding: 0 0 20px;
  font-size: 0.9375rem;
  color: var(--color-sub);
}

.access {
  padding: var(--space-section) 0 calc(var(--space-section) + 26px);
  background-color: var(--color-paper);
  background-image: var(--washi);
  background-size: 600px;
}

.access__table {
  border-top: 1px solid var(--color-line);
}

.access__map {
  margin-top: 28px;
}

.access__map iframe {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border: 0;
}

.contact {
  position: relative;
  padding: 80px 0 64px;
  background: var(--color-main);
  color: #fff;
  text-align: center;
  overflow-x: clip;
}

.contact::before {
  content: "";
  position: absolute;
  top: -25px;
  right: 0;
  left: 0;
  height: 26px;
  background: var(--color-main);
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 40' preserveAspectRatio='none'%3E%3Cpath d='M0 40V22l38 6 41-9 37 12 55-7 30 10 48-11 42 6 36-8 50 13 33-9 44 5 39-10 57 12 29-6 46 9 38-12 51 8 34-5 47 11 40-9 36 6 52-10 31 7 45-8 39 12 48-6 37 5 42-11 30 9L1200 26V40Z' fill='%23fff'/%3E%3C/svg%3E") center bottom / 100% 100% no-repeat;
}

.contact__ume {
  position: absolute;
  right: -120px;
  bottom: 0;
  width: 520px;
  max-width: none;
  opacity: 0.2;
  filter: brightness(0) invert(1);
  pointer-events: none;
}

.contact__inner {
  position: relative;
  max-width: 640px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.contact__title {
  font-family: var(--font-head);
  font-size: 1.625rem;
  font-weight: 700;
  letter-spacing: 0.06em;
}

.contact__text {
  margin: 12px 0 28px;
  font-size: 0.9375rem;
}

.contact__note {
  margin-top: 20px;
  font-size: 0.8125rem;
  color: rgba(255, 255, 255, 0.75);
}

.contact__tel {
  color: #fff;
  white-space: nowrap;
}

.contact__hours {
  display: inline-block;
}

.footer {
  padding: 28px 0;
  border-top: 1px solid var(--color-line);
}

.footer__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.footer__logo {
  font-family: var(--font-head);
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--color-main);
}

.footer__copy {
  font-size: 0.75rem;
  color: var(--color-sub);
}

h1,
h2,
h3 {
  font-feature-settings: "palt";
  word-break: auto-phrase;
  text-wrap: balance;
}

dt,
th,
td,
summary,
label,
figcaption {
  word-break: auto-phrase;
  overflow-wrap: break-word;
}

p {
  text-wrap: pretty;
}

.hero__hand {
  margin-bottom: 12px;
  font-family: var(--font-hand);
  font-size: 1.375rem;
  color: var(--color-accent-text);
}

.header__sub {
  display: none;
}

.teacher__hand {
  margin-top: 10px;
  font-family: var(--font-hand);
  font-size: 1.125rem;
  color: var(--color-accent-text);
}

.side-tab {
  display: none;
}

.pagetop {
  position: fixed;
  right: 16px;
  bottom: 72px;
  z-index: 20;
  display: none;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--color-main);
  color: #fff;
  text-decoration: none;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
}

@media (min-width: 768px) {
  :root {
    --gutter: 40px;
    --space-section: 112px;
  }

  .header__inner {
    min-height: 64px;
  }

  body {
    padding-bottom: 0;
  }

  .fixed-cta {
    display: none;
  }

  .header__nav {
    display: block;
    margin-left: auto;
  }

  .header__list {
    display: flex;
    gap: 28px;
  }

  .header__link {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.875rem;
    line-height: 1.3;
    text-decoration: none;
  }

  .header__sub {
    display: block;
    font-family: var(--font-hand);
    font-size: 0.6875rem;
    color: var(--color-accent-text);
  }

  .hero__hand {
    font-size: 1.75rem;
  }

  .pagetop {
    bottom: 24px;
    display: grid;
  }

  .header__link:hover {
    color: var(--color-accent-text);
  }

  .side-tab {
    position: fixed;
    top: 50%;
    right: 0;
    z-index: 20;
    display: block;
    padding: 22px 13px;
    background: var(--color-main);
    color: #fff;
    font-family: var(--font-head);
    font-size: 0.9375rem;
    font-weight: 700;
    letter-spacing: 0.24em;
    text-decoration: none;
    writing-mode: vertical-rl;
    transform: translateY(-50%);
  }

  .side-tab:hover {
    background: var(--color-main-dark);
  }

  .hero {
    padding: 48px 0 104px;
  }

  .hero__visual::before {
    top: 18%;
    height: 56%;
  }

  .hero__photo {
    width: 70%;
    margin: 0 0 0 4%;
  }

  .hero__photo img {
    aspect-ratio: 16 / 10;
    object-position: 50% 35%;
  }

  .hero__card {
    top: 50%;
    right: 12%;
    bottom: auto;
    gap: 10px;
    padding: 44px 30px 40px;
    transform: translateY(-50%);
  }

  .hero__title {
    font-size: 2.75rem;
  }

  .hero__tagline {
    font-size: 0.875rem;
  }

  .hero__lead {
    font-size: 1rem;
  }

  .hero__actions {
    flex-direction: row;
  }

  .hero__actions .button {
    flex: 1;
    padding: 0 16px;
  }

  .section-title {
    font-size: 2rem;
  }

  .about__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
  }

  .about__inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    column-gap: 80px;
    align-items: start;
  }

  .about__inner .section-title {
    grid-column: 1 / -1;
  }

  .about__intro {
    align-self: flex-start;
    font-size: 1.125rem;
  }

  .course__deco--obijime {
    top: 40px;
    right: 4%;
    width: 220px;
  }

  .teacher__inner {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    align-items: center;
    gap: 64px;
  }

  .faq__inner,
  .access__inner {
    max-width: 840px;
  }

  .contact {
    padding: 96px 0;
  }

  .contact__title {
    font-size: 2.125rem;
  }

  .about__ume {
    top: 24px;
    right: 3%;
    width: 340px;
  }

  .faq__ume {
    top: 40px;
    left: -80px;
    width: 340px;
    opacity: 0.35;
  }

  .contact__ume {
    right: 2%;
    bottom: 0;
    width: 760px;
  }
}

@media (min-width: 1024px) {
  .hero__body {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 440px);
    gap: 64px;
    align-items: start;
    padding-top: 72px;
  }

  .hero__facts {
    margin-top: 0;
  }

  .about__side {
    flex-direction: row-reverse;
    justify-content: center;
    align-items: flex-start;
    gap: 80px;
    margin-bottom: 0;
  }

  .about__photo {
    flex: 0 1 440px;
    min-width: 0;
    margin-top: 72px;
  }

  .about__grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 32px;
    margin-top: 80px;
  }

  .course__list {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr);
  }

  .flow__list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 40px;
  }
}

@container (max-width: 18em) {
  .hero__card {
    position: relative;
    right: auto;
    bottom: auto;
    margin: -36px var(--gutter) 0;
    writing-mode: horizontal-tb;
  }
}

@container (max-width: 17.25em) {
  .about__intro {
    writing-mode: horizontal-tb;
    letter-spacing: 0.06em;
    line-height: 2;
  }
}

@media (prefers-reduced-motion: no-preference) {
  .hero__photo img {
    animation: fade-in 1.6s ease-out both;
  }

  .hero__card {
    animation: card-in 1.1s cubic-bezier(0.22, 0.61, 0.36, 1) 0.5s both;
  }

  @keyframes fade-in {
    from {
      opacity: 0;
    }

    to {
      opacity: 1;
    }
  }

  @keyframes card-in {
    from {
      opacity: 0;
      clip-path: inset(0 0 100% 0);
    }

    to {
      opacity: 1;
      clip-path: inset(0 0 0 0);
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    transition: none !important;
  }
}
