/* =====================================================
   cta.css — Styles for partials/cta.php (bottom CTA section)
   -----------------------------------------------------
   Single source of truth so any page that includes
   partials/cta.php gets the correct presentation by
   loading this file after base.css + layout.css +
   components.css (the title mark, the arrow link and the
   打消し表示 .stat-note are design-system components).
   ===================================================== */

.section-cta {
  position: relative;
  overflow: hidden;
  background-color: var(--bg-cream);
  isolation: isolate;
  display: flex;
  align-items: center;
  min-height: clamp(420px, 56vh, 560px);
  /* No padding here: the element already carries .section, so it keeps the
     site's 96px / 64px band rhythm instead of a second, fluid formula. */
}
.cta-visual { position: absolute; inset: 0; z-index: 0; }
.cta-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 78% 50%;
  display: block;
}
.cta-overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(
      90deg,
      rgba(250, 247, 243, 0.96) 0%,
      rgba(250, 247, 243, 0.92) 30%,
      rgba(250, 247, 243, 0.78) 46%,
      rgba(250, 247, 243, 0.35) 62%,
      rgba(250, 247, 243, 0)    80%
    );
  pointer-events: none;
}
.cta-inner { position: relative; z-index: 2; width: 100%; }
.cta-content { max-width: min(540px, 50%); }
.cta-header { position: relative; z-index: 1; margin: 0 0 1.75rem; }
.cta-title {
  font-size: var(--fs-h1);   /* a section title like every other band's */
  font-weight: var(--fw-head);
  line-height: var(--lh-h1);
  margin-bottom: var(--sp-4);
}
.cta-title-break { display: inline; }
.cta-header-desc {
  font-size: var(--fs-body);
  color: var(--text-light);
  line-height: var(--lh-body);
  margin-top: var(--sp-4);
  /* Running text (three or four lines on a phone): it fills the line — no
     auto-phrase, no pretty (design-system.md, Type rules; WebKit's pretty
     shortens every line). 「カリキュラム案」 is kept whole by its own
     .app-nowrap in partials/cta.php. */
}
.cta-header-desc em {
  font-style: normal;
  font-weight: 700;
  color: var(--text-main);
}
.cta-header-desc sup { font-size: 0.6em; vertical-align: super; }
.cta-header-break { display: inline; }
.cta-body { position: relative; z-index: 1; }
.cta-action { margin: 0 0 1.25rem; }
.cta-btn:hover { transform: none; }
.cta-btn-arrow {
  display: inline-block;
  margin-left: 0.35em;
  transition: transform var(--transition);
}
.cta-btn:hover .cta-btn-arrow { transform: translateX(4px); }
.cta-btn-note {
  margin: 0.85rem 0 0;
  font-size: var(--fs-caption);
  font-weight: 700;
  color: var(--text-light);
}
.cta-checks {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 0.4rem 1.25rem;
  margin: 1.25rem 0 0;
  padding: 0;
  list-style: none;
}
.cta-checks li {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: var(--fs-body-sm);
  font-weight: 700;
  color: var(--text-light);
}
.cta-check-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: rgba(0, 174, 239, 0.12);
  color: var(--ink-sky);   /* 4.9:1 on the tint; the display blue was 2.4:1 */
  font-size: var(--fs-caption);
  font-weight: 800;
  line-height: 1;
  flex-shrink: 0;
}
.cta-alt {
  font-size: var(--fs-body-md);
  color: var(--ink-quiet);
  margin: 1.85rem 0 0;
}

@media (max-width: 1023px) {
  .cta-img { object-position: 86% 50%; }
  .cta-overlay {
    background:
      linear-gradient(
        90deg,
        rgba(250, 247, 243, 0.97) 0%,
        rgba(250, 247, 243, 0.93) 38%,
        rgba(250, 247, 243, 0.70) 58%,
        rgba(250, 247, 243, 0.25) 82%,
        rgba(250, 247, 243, 0)    100%
      );
  }
  .section-cta { min-height: clamp(400px, 50vh, 520px); }
  .cta-content { max-width: min(460px, 60%); }
}
@media (max-width: 767px) {
  .cta-img { object-position: 70% 92%; }
  .cta-overlay {
    background:
      linear-gradient(
        180deg,
        rgba(250, 247, 243, 0.96) 0%,
        rgba(250, 247, 243, 0.90) 50%,
        rgba(250, 247, 243, 0.55) 100%
      );
  }
  .section-cta {
    min-height: auto;
    padding: var(--sp-section) 0;
    align-items: stretch;
  }
  .cta-content { max-width: 100%; }
  .cta-header { margin-bottom: 1.5rem; }
}
@media (max-width: 520px) {
  .cta-header-break { display: none; }
  .cta-btn { width: 100%; }
  .cta-checks { gap: 0.4rem 0.95rem; margin-top: 1rem; }
  .cta-alt { margin-top: 1.5rem; }
}

/* ---- Tap target: the alternative link is a standalone control ---- */
.cta-alt-link { min-height: 44px; }

/* ---- Narrowest phones: base.css lets every .btn wrap; the CTA also drops
       its trailing arrow so the label keeps the full measure ---- */
@media (max-width: 360px) {
  .cta-btn-arrow { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .cta-btn-arrow { transition: none; }
}
