.tomoe-page {
  overflow: clip;
}

.tomoe-page a:not(.button) {
  text-decoration: none;
}

.tomoe-page a:not(.button) {
  background-image: linear-gradient(var(--color-crimson), var(--color-crimson));
  background-position: 0 calc(100% - 0.05em);
  background-repeat: no-repeat;
  background-size: 100% 1px;
  transition: color var(--transition-fast), background-size 180ms ease-out;
}

.tomoe-page a:not(.button):hover {
  background-size: 100% 2px;
}

.tomoe-section {
  position: relative;
  padding-block: var(--section-space);
}

.tomoe-section > .container {
  min-width: 0;
}

.tomoe-hero {
  position: relative;
  padding-block: clamp(3rem, 7vw, 6.5rem) var(--section-space);
  background: radial-gradient(circle at 82% 22%, rgb(74 41 77 / 0.26), transparent 28rem);
}

.tomoe-hero::before,
.tomoe-introduction::after,
.tomoe-temperament::before {
  position: absolute;
  pointer-events: none;
  content: "";
}

.tomoe-hero::before {
  inset: 10% 0 auto 55%;
  height: 14rem;
  opacity: 0.1;
  background: linear-gradient(120deg, transparent 10%, var(--color-antique-gold) 11%, transparent 13%, transparent 45%, var(--color-plum) 46%, transparent 49%);
}

.tomoe-hero__inner {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(22.5rem, 3fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5.5rem);
}

.tomoe-hero__copy {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: min(100%, 36.25rem);
  min-width: 0;
  gap: var(--space-4);
}

.tomoe-hero__copy > * {
  margin: 0;
}

.tomoe-hero__copy h1 {
  font-size: clamp(4rem, 6.1vw, 4.75rem);
}

.tomoe-hero__meta {
  width: 100%;
  padding-bottom: var(--space-3);
  border-bottom: var(--border-gold);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
}

.tomoe-hero__lead {
  max-width: 35rem;
  color: var(--color-parchment-white);
  font-size: clamp(1.125rem, 1.7vw, 1.25rem);
  line-height: 1.65;
}

.tomoe-hero__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  width: 100%;
  min-width: 0;
  gap: var(--space-5);
}

.tomoe-hero__actions > * {
  min-width: 0;
}

.tomoe-text-link {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  color: var(--color-parchment-white);
  font-size: var(--font-size-sm);
  font-weight: 700;
  letter-spacing: 0.05em;
  line-height: 1.3;
  text-transform: uppercase;
}

.tomoe-text-link span {
  margin-left: var(--space-2);
  color: var(--color-antique-gold);
}

.tomoe-hero__figure,
.tomoe-past__figure,
.tomoe-journey__figure {
  width: 100%;
  min-width: 0;
}

.tomoe-hero__figure {
  position: relative;
  margin: 0;
  box-shadow: var(--shadow-deep);
}

.tomoe-hero__figure picture,
.tomoe-hero__figure img {
  width: 100%;
}

.tomoe-hero__figure img {
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: right center;
  transition: filter var(--transition-base);
}

.tomoe-hero__figure::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgb(16 14 18 / 0.3), transparent 55%);
  content: "";
  pointer-events: none;
  transition: background-color var(--transition-base);
}

.tomoe-hero__figure:hover::after {
  background-color: rgb(16 14 18 / 0.08);
}

.tomoe-hero__figure figcaption,
.tomoe-past__figure figcaption,
.tomoe-journey__figure figcaption {
  position: relative;
  z-index: 1;
  max-width: 38rem;
  margin: var(--space-2) 0 0;
}

.tomoe-introduction {
  background: linear-gradient(100deg, rgb(41 38 49 / 0.22), transparent 62%);
}

.tomoe-introduction::after {
  top: 20%;
  right: 6%;
  width: 22rem;
  height: 16rem;
  opacity: 0.1;
  background: radial-gradient(ellipse at center, var(--color-plum), transparent 65%);
}

.tomoe-introduction__layout {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 3fr);
  gap: var(--space-8);
}

.tomoe-introduction__copy {
  width: min(100%, 42.5rem);
  min-width: 0;
}

.tomoe-introduction__article {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: var(--space-6);
}

.tomoe-introduction__block {
  min-width: 0;
  padding-left: var(--space-5);
  border-left: 1px solid rgb(185 147 82 / 0.72);
}

.tomoe-introduction__block h3,
.tomoe-past__main h3,
.tomoe-method h3,
.tomoe-code__content h3,
.tomoe-journey__content h3,
.tomoe-action__item h3,
.tomoe-frame__copy h3 {
  margin-bottom: var(--space-3);
}

.tomoe-status {
  margin: 0 0 var(--space-2);
  color: var(--color-antique-gold);
  font-size: var(--font-size-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-label);
  line-height: 1.3;
  text-transform: uppercase;
}

.tomoe-scope-note {
  width: min(100%, 33.75rem);
  padding: var(--space-5);
  border: var(--border-subtle);
  border-left: 3px solid var(--color-crimson);
  background: var(--color-graphite-gray);
}

.tomoe-scope-note p:last-child,
.tomoe-reader-note p:last-child,
.tomoe-method p:last-child,
.tomoe-temperament__item p:last-child,
.tomoe-code__content p:last-child,
.tomoe-journey__content p:last-child,
.tomoe-action__item p:last-of-type,
.tomoe-frame__copy p:last-child {
  margin-bottom: 0;
}

.tomoe-introduction__space {
  min-width: 0;
}

.tomoe-temperament {
  background: var(--color-ink-black);
}

.tomoe-temperament::before {
  top: 18%;
  left: 0;
  width: 25%;
  height: 24rem;
  opacity: 0.07;
  background: linear-gradient(165deg, transparent 18%, var(--color-warm-mist) 19%, transparent 20%, transparent 45%, var(--color-plum) 46%, transparent 49%);
}

.tomoe-temperament__grid,
.tomoe-action__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-6);
}

.tomoe-temperament__item,
.tomoe-action__item {
  min-width: 0;
}

.tomoe-temperament__item {
  padding-top: var(--space-5);
  border-top: var(--border-gold);
}

.tomoe-temperament__number,
.tomoe-action__number {
  margin: 0 0 var(--space-3);
  color: var(--color-antique-gold);
  font-family: var(--font-heading);
  font-size: 2rem;
  letter-spacing: var(--tracking-heading);
  line-height: 1;
}

.tomoe-temperament__number--accent {
  color: var(--color-crimson);
}

.tomoe-temperament__item h3 {
  margin-bottom: var(--space-3);
}

.tomoe-temperament__summary {
  color: var(--color-warm-mist);
  font-style: italic;
}

.tomoe-past {
  background: linear-gradient(180deg, rgb(41 38 49 / 0.46), var(--color-ink-black) 78%);
}

.tomoe-past__grid {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 2fr) minmax(0, 2fr);
  align-items: start;
  gap: var(--space-6);
}

.tomoe-past__main,
.tomoe-method {
  min-width: 0;
}

.tomoe-past__main {
  width: min(100%, 40rem);
}

.tomoe-method {
  padding: var(--space-5);
  border: var(--border-subtle);
  background: rgb(24 21 28 / 0.84);
}

.tomoe-past__figure {
  margin: 0;
}

.tomoe-past__figure picture,
.tomoe-past__figure img {
  width: 100%;
}

.tomoe-past__figure img {
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center;
}

.tomoe-reader-note {
  width: min(100%, 42.5rem);
  margin-top: var(--space-6);
  padding: var(--space-4) var(--space-5);
  border-top: var(--border-gold);
  border-bottom: var(--border-subtle);
}

.tomoe-code {
  background: var(--color-ink-black);
}

.tomoe-code__list {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: var(--space-6);
}

.tomoe-code__item {
  display: grid;
  grid-template-columns: minmax(6rem, 10%) minmax(0, 1fr);
  min-width: 0;
  padding: var(--space-5) 0;
  border-top: var(--border-gold);
}

.tomoe-code__item--muted {
  padding-inline: var(--space-5);
  border-left: 3px solid var(--color-crimson);
  background: var(--color-graphite-gray);
}

.tomoe-code__number {
  min-width: 0;
  margin: 0;
  color: var(--color-antique-gold);
  font-family: var(--font-heading);
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1;
}

.tomoe-code__content {
  width: min(100%, 42.5rem);
  min-width: 0;
}

.tomoe-quote-section {
  background: radial-gradient(circle at 50% 50%, rgb(74 41 77 / 0.2), transparent 29rem);
}

.tomoe-quote-section > .container {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  gap: var(--space-5);
}

.tomoe-editorial-quote {
  width: min(100%, 51.25rem);
  margin: 0;
  padding: clamp(1.5rem, 4vw, 3rem);
  border-left: 4px solid var(--color-crimson);
  background: var(--color-parchment-white);
  color: var(--color-ink-black);
  box-shadow: var(--shadow-deep);
}

.tomoe-editorial-quote p {
  margin: 0;
  font-family: var(--font-heading);
  font-size: clamp(1.8rem, 4vw, 2.625rem);
  letter-spacing: 0.02em;
  line-height: 1.05;
  text-transform: uppercase;
}

.tomoe-editorial-quote footer {
  margin-top: var(--space-5);
  color: var(--color-deep-crimson);
  font-size: var(--font-size-sm);
  font-weight: 700;
}

.tomoe-quote-section__link {
  width: min(100%, 37.5rem);
  margin: 0 auto;
  text-align: center;
}

.tomoe-journey {
  background: linear-gradient(120deg, var(--color-ink-black), rgb(41 38 49 / 0.56));
}

.tomoe-journey__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(20.625rem, 3fr);
  align-items: start;
  gap: clamp(2rem, 5vw, 5.5rem);
}

.tomoe-journey__steps {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: var(--space-6);
}

.tomoe-journey__step {
  display: grid;
  grid-template-columns: 4.5rem minmax(0, 1fr);
  min-width: 0;
  gap: var(--space-4);
}

.tomoe-journey__number {
  position: relative;
  min-width: 0;
  margin: 0;
  color: var(--color-antique-gold);
  font-family: var(--font-heading);
  font-size: 1.875rem;
  line-height: 1;
}

.tomoe-journey__number::after {
  position: absolute;
  top: 2.5rem;
  bottom: calc(var(--space-6) * -1);
  left: 0.7rem;
  width: 1px;
  background: rgb(185 147 82 / 0.48);
  content: "";
}

.tomoe-journey__step:last-child .tomoe-journey__number::after {
  display: none;
}

.tomoe-journey__content {
  width: min(100%, 35rem);
  min-width: 0;
}

.tomoe-journey__figure {
  margin: 0;
}

.tomoe-journey__figure picture,
.tomoe-journey__figure img {
  width: 100%;
}

.tomoe-journey__figure img {
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: right center;
  box-shadow: var(--shadow-deep);
}

.tomoe-action {
  background: var(--color-ink-black);
}

.tomoe-action__item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 100%;
  padding: var(--space-5);
  border-top: var(--border-gold);
  border-bottom: var(--border-subtle);
  gap: var(--space-3);
}

.tomoe-action__item--elevated {
  border: var(--border-subtle);
  border-left: 3px solid var(--color-crimson);
  background: var(--color-ink-black-elevated);
}

.tomoe-action__item > * {
  margin: 0;
}

.tomoe-action__item .tomoe-text-link {
  margin-top: auto;
  padding-top: var(--space-3);
}

.tomoe-frames {
  background: linear-gradient(180deg, rgb(41 38 49 / 0.42), var(--color-ink-black));
}

.tomoe-frames__list {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: var(--space-4);
}

.tomoe-frame {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 6fr);
  min-width: 0;
  padding: var(--space-5);
  border: var(--border-subtle);
  gap: var(--space-5);
}

.tomoe-frame__label,
.tomoe-frame__copy {
  min-width: 0;
}

.tomoe-frame__label p {
  margin: 0;
  color: var(--color-antique-gold);
  font-size: var(--font-size-xs);
  font-weight: 700;
  letter-spacing: var(--tracking-label);
  line-height: 1.3;
  text-transform: uppercase;
}

.tomoe-frame__copy {
  width: min(100%, 45rem);
}

.tomoe-frame--fact {
  border-color: transparent;
  background: var(--color-parchment-white);
  color: var(--color-ink-black);
}

.tomoe-frame--fact h3,
.tomoe-frame--fact p {
  color: var(--color-ink-black);
}

.tomoe-frame--fact .tomoe-frame__label {
  border-right: 1px solid var(--color-antique-gold);
}

.tomoe-frame--editorial {
  background: var(--color-graphite-gray);
}

.tomoe-frame--visual {
  border-left: 4px solid var(--color-crimson);
  background: var(--color-ink-black-elevated);
}

.tomoe-reading {
  padding-bottom: calc(var(--section-space) + var(--space-6));
}

.tomoe-reading__lead {
  width: min(100%, 37.5rem);
  color: var(--color-warm-mist);
  font-size: var(--font-size-md);
}

.tomoe-reading__list {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border-top: var(--border-gold);
}

.tomoe-reading__link {
  display: grid;
  grid-template-columns: minmax(4rem, 10%) minmax(0, 70%) minmax(9rem, 20%);
  align-items: center;
  width: 100%;
  min-width: 0;
  padding: var(--space-5);
  border-bottom: var(--border-subtle);
  gap: var(--space-4);
  color: var(--color-parchment-white);
}

.tomoe-reading__link--elevated {
  background: var(--color-ink-black-elevated);
}

.tomoe-reading__number,
.tomoe-reading__content,
.tomoe-reading__indicator {
  min-width: 0;
}

.tomoe-reading__number {
  color: var(--color-antique-gold);
  font-family: var(--font-heading);
  font-size: 1.875rem;
  line-height: 1;
}

.tomoe-reading__content {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.tomoe-reading__content strong {
  font-family: var(--font-heading);
  font-size: clamp(1.5rem, 3vw, 1.875rem);
  font-weight: 400;
  letter-spacing: var(--tracking-heading);
  line-height: 1;
  text-transform: uppercase;
}

.tomoe-reading__content span {
  width: min(100%, 32.5rem);
  color: var(--color-warm-mist);
  font-size: var(--font-size-sm);
  line-height: 1.55;
}

.tomoe-reading__indicator {
  display: inline-flex;
  justify-content: flex-end;
  color: var(--color-antique-gold);
  font-size: var(--font-size-sm);
  font-weight: 700;
  letter-spacing: 0.04em;
  line-height: 1.35;
  text-align: right;
  text-transform: uppercase;
  transition: transform var(--transition-fast);
}

.tomoe-reading__link:hover .tomoe-reading__indicator {
  transform: translateX(2px);
}

@media (max-width: 63.74rem) {
  .tomoe-past__grid {
    grid-template-columns: minmax(0, 5fr) minmax(0, 3fr);
  }

  .tomoe-past__main {
    grid-column: 1 / 2;
  }

  .tomoe-method {
    grid-column: 1 / 2;
    width: min(100%, 40rem);
  }

  .tomoe-past__figure {
    grid-column: 2 / 3;
    grid-row: 1 / 3;
  }
}

@media (max-width: 61.24rem) {
  .tomoe-hero__inner,
  .tomoe-journey__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-6);
  }

  .tomoe-hero__figure,
  .tomoe-journey__figure {
    grid-row: 1;
    width: calc(100% + (var(--container-padding) * 2));
    margin-inline: calc(var(--container-padding) * -1);
  }

  .tomoe-hero__copy,
  .tomoe-journey__steps {
    grid-row: 2;
  }

  .tomoe-hero__copy {
    width: min(100%, 36.25rem);
  }

  .tomoe-hero__figure img,
  .tomoe-journey__figure img {
    aspect-ratio: 4 / 5;
  }

  .tomoe-hero__figure figcaption,
  .tomoe-journey__figure figcaption {
    padding-inline: var(--container-padding);
  }
}

@media (max-width: 57.49rem) {
  .tomoe-temperament__grid,
  .tomoe-action__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
  }

  .tomoe-temperament__item {
    width: min(100%, 38.75rem);
  }

  .tomoe-action__item {
    width: 100%;
  }
}

@media (max-width: 47.49rem) {
  .tomoe-introduction__layout,
  .tomoe-past__grid {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
  }

  .tomoe-introduction__space {
    display: none;
  }

  .tomoe-past__main,
  .tomoe-method,
  .tomoe-past__figure {
    grid-column: 1;
    grid-row: auto;
    width: 100%;
  }

  .tomoe-past__figure {
    width: calc(100% + (var(--container-padding) * 2));
    margin-inline: calc(var(--container-padding) * -1);
  }

  .tomoe-past__figure figcaption {
    padding-inline: var(--container-padding);
  }

  .tomoe-code__item {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
  }

  .tomoe-code__item--muted {
    padding-inline: var(--space-4);
  }

  .tomoe-frame {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
  }

  .tomoe-frame--fact .tomoe-frame__label {
    padding-bottom: var(--space-3);
    border-right: 0;
    border-bottom: 1px solid var(--color-antique-gold);
  }

  .tomoe-reading__link {
    grid-template-columns: minmax(0, 1fr);
    justify-items: start;
    gap: var(--space-3);
  }

  .tomoe-reading__indicator {
    justify-content: flex-start;
    min-height: 2.75rem;
    text-align: left;
  }
}

@media (max-width: 43.74rem) {
  .tomoe-hero__copy h1 {
    font-size: clamp(2.9rem, 14vw, 3.4rem);
  }

  .tomoe-hero__actions {
    align-items: stretch;
    flex-direction: column;
    gap: var(--space-3);
  }

  .tomoe-hero__actions .button {
    width: 100%;
  }

  .tomoe-hero__actions .tomoe-text-link {
    width: fit-content;
  }

  .tomoe-introduction__block {
    padding-top: var(--space-3);
    padding-left: 0;
    border-top: 2px solid rgb(185 147 82 / 0.72);
    border-left: 0;
  }

  .tomoe-journey__step {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-3);
  }

  .tomoe-journey__number::after {
    top: 2.25rem;
    bottom: calc(var(--space-6) * -1);
    left: 0.75rem;
  }

  .tomoe-editorial-quote p {
    font-size: clamp(1.55rem, 8vw, 1.875rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  .tomoe-page a:not(.button),
  .tomoe-hero__figure img,
  .tomoe-hero__figure::after,
  .tomoe-reading__indicator {
    transition: none;
  }
}
