@charset "UTF-8";

.materials-page {
  background: #f5f1e8;
}

.materials-page .top-line {
  background: linear-gradient(90deg, #2f7970 0%, #8fc8bd 58%, #f2d766 100%);
}

.materials-page .brand-mark,
.materials-page .nav-cta {
  background: #235e58;
}

.materials-page .global-nav a[aria-current="page"] {
  color: #2f7970;
}

.materials-shell {
  width: min(1160px, calc(100% - 80px));
  margin-inline: auto;
}

.materials-hero {
  position: relative;
  padding: 176px 0 82px;
  overflow: hidden;
  background:
    radial-gradient(circle at 82% 14%, rgba(132, 202, 190, 0.24) 0 110px, transparent 111px),
    linear-gradient(140deg, #f9f6ef 0%, #eef6f2 100%);
}

.materials-hero::after {
  position: absolute;
  right: -80px;
  bottom: -190px;
  width: 380px;
  height: 380px;
  border: 1px solid rgba(47, 121, 112, 0.2);
  border-radius: 50%;
  content: "";
}

.materials-hero .eyebrow {
  margin-bottom: 18px;
  color: #2f7970;
}

.materials-hero h1 {
  margin: 0;
  font-size: clamp(46px, 7vw, 76px);
  letter-spacing: -0.055em;
  line-height: 1.2;
}

.materials-hero > .materials-shell > p:last-child {
  max-width: 700px;
  margin: 24px 0 0;
  color: #53584f;
  font-size: clamp(15px, 1.5vw, 18px);
}

.materials-list {
  padding: 90px 0 128px;
}

.materials-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}

.materials-section-heading p {
  margin: 0 0 5px;
  color: #2f7970;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.2em;
}

.materials-section-heading h2 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 40px);
  letter-spacing: -0.04em;
}

.materials-section-heading > span {
  color: #686d66;
  font-size: 12px;
  font-weight: 700;
}

.material-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(380px, 0.92fr);
  overflow: hidden;
  border: 1px solid rgba(36, 77, 71, 0.12);
  border-radius: 34px;
  background: #fffdfa;
  box-shadow: 0 26px 70px rgba(48, 77, 69, 0.13);
}

.material-status--onsale {
  position: absolute;
  z-index: 2;
  top: 20px;
  left: 20px;
  margin: 0;
  padding: 8px 17px;
  border-radius: 999px;
  background: #235e58;
  box-shadow: 0 6px 16px rgba(35, 94, 88, 0.26);
  color: #fff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.material-cover {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 24px;
  background: #e6f0ec;
}

.material-cover img {
  width: 100%;
  /* The cover art is a 16:9 key visual whose title sits in the top-left.
     Stretching it to the grid row height and cropping with object-fit: cover
     cut the title off, so keep its own ratio and show the whole frame. */
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: contain;
  border-radius: 22px;
  box-shadow: 0 14px 30px rgba(34, 63, 58, 0.14);
}

.material-details {
  display: flex;
  min-width: 0;
  flex-direction: column;
  padding: clamp(34px, 4vw, 58px);
}

.material-edition {
  width: fit-content;
  margin: 0 0 18px;
  padding: 7px 15px;
  border-radius: 999px;
  background: #2f7970;
  color: #fff;
  font-size: 10px;
  font-style: italic;
  font-weight: 800;
  letter-spacing: 0.11em;
}

.material-details h3 {
  margin: 0;
  font-size: clamp(28px, 3.2vw, 43px);
  letter-spacing: -0.055em;
  line-height: 1.35;
  text-wrap: balance;
}

.material-facts {
  display: grid;
  gap: 0;
  margin: 30px 0 0;
}

.material-facts > div {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 18px;
  padding: 13px 0;
  border-bottom: 1px solid rgba(35, 94, 88, 0.13);
}

.material-facts dt,
.material-facts dd {
  margin: 0;
}

.material-facts dt {
  color: #6a706b;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.material-facts dd {
  color: #29302d;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.65;
}

.material-purchase {
  display: grid;
  grid-template-columns: auto minmax(210px, 1fr);
  align-items: end;
  gap: 30px;
  margin-top: auto;
  padding-top: 34px;
}

.material-price {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.material-price > span {
  color: #686d66;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
}

.material-price strong {
  color: #235e58;
  font-family: var(--font-serif);
  font-size: clamp(42px, 4vw, 58px);
  line-height: 1;
}

.material-price small {
  margin-left: 5px;
  font-family: var(--font-sans);
  font-size: 16px;
}

.material-checkout-button {
  display: flex;
  min-height: 58px;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 15px 24px;
  border-radius: 999px;
  background: #235e58;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.material-checkout-button:not([aria-disabled="true"]):hover {
  box-shadow: 0 12px 24px rgba(35, 94, 88, 0.24);
  transform: translateY(-2px);
}

.material-checkout-button[aria-disabled="true"] {
  background: #9ba8a4;
  cursor: not-allowed;
}

.material-checkout p {
  margin: 9px 4px 0;
  color: #737a75;
  font-size: 10px;
  line-height: 1.6;
}

.materials-note {
  margin: 24px 4px 0;
  color: #626862;
  font-size: 12px;
}

/* ---- 制作中の教材（Coming soon） ---- */

.materials-upcoming {
  padding: 0 0 124px;
  border-top: 1px solid rgba(36, 77, 71, 0.12);
  padding-top: 82px;
}

.upcoming-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 26px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.upcoming-card {
  display: flex;
  overflow: hidden;
  min-width: 0;
  flex-direction: column;
  border: 1px solid rgba(36, 77, 71, 0.12);
  border-radius: 26px;
  background: #fffdfa;
  box-shadow: 0 16px 40px rgba(48, 77, 69, 0.09);
}

.upcoming-band {
  display: flex;
  min-height: 132px;
  flex-direction: column;
  justify-content: center;
  padding: 28px clamp(22px, 3vw, 32px);
  background: var(--material-surface, #2f7970);
  color: #fff;
}

.upcoming-name-ja {
  margin: 0;
  font-size: clamp(21px, 2.3vw, 27px);
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.34;
  text-wrap: balance;
}

.upcoming-name-en {
  margin: 9px 0 0;
  color: rgba(255, 255, 255, 0.88);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.upcoming-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 24px clamp(22px, 3vw, 32px) 28px;
}

.upcoming-badge {
  width: fit-content;
  margin: 0 0 14px;
  padding: 6px 14px;
  border: 1px solid var(--material-deep, #235e58);
  border-radius: 999px;
  color: var(--material-deep, #235e58);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.upcoming-lead {
  margin: 0;
  color: #3b423e;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.75;
}

/* 区分ごとの小見出し。カード群を教材の系統でまとめる。 */

.upcoming-group {
  margin-top: 54px;
}

.upcoming-group:first-of-type {
  margin-top: 0;
}

.upcoming-group-heading {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin: 0 4px 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(36, 77, 71, 0.14);
}

.upcoming-group-heading h3 {
  margin: 0;
  color: #24443f;
  font-size: clamp(18px, 2vw, 21px);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.upcoming-group-heading span {
  color: #626862;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

/*
  区分ごとの控えめな色。PRODUCT-THEME-COLORS-20260903.md に値がある教材は
  カード側の style 属性で正典値を直接指定する。ここで定義するのは、正典に
  値がない未着手区分のための補助色のみ（正典は書き換えない）。
*/

.upcoming-card--fulledition {
  --material-surface: #2f6f7a;
  --material-deep: #1f4e56;
}

.upcoming-card--core {
  --material-surface: #5a6e9b;
  --material-deep: #3f4f75;
}

.upcoming-card--grammar {
  --material-surface: #8c6d46;
  --material-deep: #6a5132;
}

.upcoming-card--wordlist {
  --material-surface: #3f8f72;
  --material-deep: #2c6a54;
}

.upcoming-card--phrase {
  --material-surface: #3fae8a;
  --material-deep: #2a7f63;
}

.upcoming-card--flagship {
  --material-surface: #4a5250;
  --material-deep: #333937;
}

/* 単語リストのうち TSL / BSL は正典の予備枠が色を持つ。 */

.upcoming-card--wordlist-tsl {
  --material-surface: #b8478f;
  --material-deep: #8f326e;
}

.upcoming-card--wordlist-bsl {
  --material-surface: #6b7d8c;
  --material-deep: #4d5c68;
}

.upcoming-note {
  margin: 44px 4px 0;
  color: #53584f;
  font-size: 14px;
  line-height: 1.8;
}

.upcoming-note a {
  color: #235e58;
  font-weight: 800;
  text-decoration: underline;
  text-underline-offset: 3px;
}

@media (max-width: 980px) {
  .material-card {
    grid-template-columns: 1fr;
  }

  .material-cover {
    padding: 20px;
  }

  .material-cover img {
    height: auto;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 620px) {
  .materials-shell {
    width: min(100% - 36px, 560px);
  }

  .materials-hero {
    padding: 132px 0 64px;
  }

  .materials-hero h1 {
    font-size: clamp(40px, 13vw, 58px);
  }

  .materials-list {
    padding: 62px 0 92px;
  }

  .materials-section-heading {
    align-items: start;
  }

  .material-card {
    border-radius: 24px;
  }

  .material-cover {
    padding: 12px;
  }

  .material-cover img {
    border-radius: 16px;
  }

  .material-details {
    padding: 28px 22px 30px;
  }

  .material-details h3 {
    font-size: clamp(27px, 8.5vw, 36px);
  }

  .material-facts > div {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .material-purchase {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .material-checkout-button {
    width: 100%;
  }

  .materials-upcoming {
    padding-top: 58px;
    padding-bottom: 88px;
  }

  .upcoming-grid {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .upcoming-group {
    margin-top: 40px;
  }

  .upcoming-group-heading {
    flex-direction: column;
    align-items: start;
    gap: 4px;
    margin-bottom: 16px;
  }

  .upcoming-card {
    border-radius: 20px;
  }

  .upcoming-band {
    min-height: 0;
    padding: 22px 20px;
  }

  .upcoming-body {
    padding: 20px 20px 24px;
  }

  /* 上に重ねるとキービジュアルのタイトルに被るため、モバイルでは帯の上に積む。 */
  .material-status--onsale {
    position: static;
    width: fit-content;
    justify-self: start;
    margin: 14px 0 0 14px;
    padding: 7px 14px;
    box-shadow: none;
    font-size: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .material-checkout-button {
    transition: none;
  }
}

/* Preserve the complete portrait cover and its book-like depth. */
.material-cover:has(.material-book-cover) { justify-content: center; padding: 56px 36px; }
.material-cover .material-book-cover { width: min(100%, 330px); height: auto; aspect-ratio: 992 / 1586; border-radius: 4px 10px 10px 4px; transform: perspective(1200px) rotateY(-5deg) rotate(1deg); box-shadow: 3px 3px 0 #d8dedb, 6px 6px 0 #edf0ec, 8px 8px 0 #b9c5bf, 0 12px 20px rgba(10,45,42,.2), 0 26px 38px -12px rgba(10,45,42,.38); }
@media (max-width: 700px) { .material-cover:has(.material-book-cover) { padding: 54px 30px 42px; } .material-cover .material-book-cover { width: min(90%, 290px); } }
