/*
Theme Name: Manlearn Child
Theme URI: https://manlearn.com
Description: manlearn.com 首頁自訂子主題，基於 Twenty Twenty-Five。
Author: Manlearn
Template: twentytwentyfive
Version: 4.5.0
Text Domain: manlearn-child
*/

/* ==========================================================================
   Manlearn front page — scoped under .ml-home to avoid leaking into
   other pages that still use the parent Twenty Twenty-Five templates.
   ========================================================================== */

.ml-home {
  --ml-dark: #10262d;
  --ml-dark-2: #0a2e36;
  --ml-teal: #1f6b73;
  --ml-teal-light: #e9f2f2;
  --ml-bg-alt: #f7f7f7;
  --ml-bg-warm: #faf6f1;
  --ml-text: #1a2023;
  --ml-text-muted: #656e72;
  --ml-border: #e7e8e8;
  --ml-gold: #c9a24a;
  --ml-radius: 14px;

  font-family: -apple-system, BlinkMacSystemFont, "PingFang TC", "Microsoft JhengHei", "Heiti TC", "Segoe UI", Arial, sans-serif;
  color: var(--ml-text);
  background: #fff;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.ml-home * { box-sizing: border-box; }
.ml-home img { max-width: 100%; display: block; }
.ml-home a { text-decoration: none; color: inherit; }
.ml-home ul { list-style: none; margin: 0; padding: 0; }
.ml-home svg { flex-shrink: 0; }

.ml-container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }
.ml-section-pad { padding: 64px 0; }
.ml-section-title { font-size: 26px; font-weight: 800; text-align: center; margin: 0 0 10px; }
.ml-section-sub { font-size: 13.5px; color: var(--ml-text-muted); text-align: center; margin: 0 0 40px; }

/* ---------- buttons ---------- */
.ml-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 26px; border-radius: 8px; font-size: 14.5px; font-weight: 600;
  border: 1.5px solid transparent; cursor: pointer; white-space: nowrap;
  transition: opacity .15s ease, background-color .15s ease;
}
.ml-btn.ml-btn-primary { background: var(--ml-teal); color: #fff; }
.ml-btn.ml-btn-primary:hover { opacity: .88; color: #fff; }
.ml-btn.ml-btn-outline { background: #fff; color: var(--ml-dark); border-color: var(--ml-dark); font-weight: 700; }
.ml-btn.ml-btn-outline:hover { background: var(--ml-dark); color: #fff; }
.ml-btn.ml-btn-outline-light { background: transparent; color: #fff; border-color: rgba(255,255,255,.5); }
.ml-btn.ml-btn-outline-light:hover { border-color: #fff; }
.ml-btn-sm { padding: 9px 18px; font-size: 13px; }
.ml-btn-block { width: 100%; }

/* ---------- header / nav ---------- */
.ml-header { border-bottom: 1px solid var(--ml-border); background: #fff; position: sticky; top: 0; z-index: 50; }
.ml-header-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 24px; }
.ml-logo { display: flex; align-items: center; gap: 10px; }
.ml-logo-full { height: 52px; width: auto; object-fit: contain; }
.ml-logo-icon { width: 38px; height: 38px; object-fit: contain; flex-shrink: 0; }
.ml-logo-text { line-height: 1.25; }
.ml-logo-text .ml-logo-main { font-size: 16px; font-weight: 700; color: var(--ml-text); }
.ml-logo-text .ml-logo-sub { font-size: 9.5px; letter-spacing: .06em; color: var(--ml-text-muted); }
.ml-nav { display: flex; align-items: center; gap: 26px; }
.ml-nav a { font-size: 14px; font-weight: 700; color: var(--ml-text); white-space: nowrap; }
.ml-nav a:hover, .ml-nav a.current { color: var(--ml-teal); }

/* ---------- hero (full-width photo background) ---------- */
.ml-hero-full { position: relative; overflow: hidden; min-height: 580px; display: flex; align-items: center; background: #fff; }
.ml-hero-full > .ml-container { width: 100%; }
.ml-hero-full-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% center; z-index: 0; }
.ml-hero-full-overlay {
  position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, #fff 0%, #fff 34%, rgba(255,255,255,0) 54%, rgba(255,255,255,0) 100%);
}
.ml-hero-full-content { position: relative; z-index: 2; max-width: 540px; padding: 56px 0; }
.ml-badge-pill {
  display: inline-block;
  padding: 7px 16px;
  border-radius: 999px;
  background: var(--ml-teal-light);
  color: var(--ml-teal);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 18px;
}
.ml-hero-full-content h1 { font-size: 36px; font-weight: 800; line-height: 1.35; margin: 0 0 12px; }
.ml-hero-full-content h1 .ml-accent { color: var(--ml-teal); }
.ml-hero-full-content p.ml-lead { font-size: 14.5px; color: var(--ml-text-muted); margin: 0 0 20px; }
.ml-check-list li { display: flex; align-items: center; gap: 8px; font-size: 13.5px; color: var(--ml-text); margin-top: 9px; }
.ml-check-list li svg { color: var(--ml-teal); }
.ml-hero-actions { display: flex; gap: 14px; margin: 26px 0 22px; flex-wrap: wrap; }
.ml-trust-row { display: flex; gap: 20px; flex-wrap: wrap; }
.ml-trust-row span { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ml-text-muted); font-weight: 500; }
.ml-trust-row svg { color: var(--ml-teal); }

/* ---------- pain points ---------- */
.ml-pain-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

/* entrance animation — fades/slides up as cards scroll into view */
.ml-reveal { opacity: 0; transform: translateY(28px); transition: opacity .65s cubic-bezier(.2,.7,.3,1), transform .65s cubic-bezier(.2,.7,.3,1); }
.ml-reveal.is-visible { opacity: 1; transform: translateY(0); }
.ml-pain-grid .ml-reveal:nth-child(1) { transition-delay: .04s; }
.ml-pain-grid .ml-reveal:nth-child(2) { transition-delay: .11s; }
.ml-pain-grid .ml-reveal:nth-child(3) { transition-delay: .18s; }
.ml-pain-grid .ml-reveal:nth-child(4) { transition-delay: .11s; }
.ml-pain-grid .ml-reveal:nth-child(5) { transition-delay: .18s; }
.ml-pain-grid .ml-reveal:nth-child(6) { transition-delay: .25s; }
@media (prefers-reduced-motion: reduce) {
  .ml-reveal { opacity: 1; transform: none; transition: none; }
}
.ml-pain-card {
  position: relative; border-radius: var(--ml-radius); overflow: hidden;
  min-height: 150px; padding: 18px 52% 18px 18px;
  background: var(--ml-bg-warm); border: 1px solid #efe6da;
}
.ml-pain-card img {
  position: absolute; right: 0; top: 0; height: 100%; width: 48%; object-fit: cover;
  mask-image: linear-gradient(to right, transparent, #000 30%);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 30%);
}
.ml-pain-icon {
  width: 34px; height: 34px; border-radius: 50%; background: #fff;
  display: flex; align-items: center; justify-content: center; color: var(--ml-gold);
  border: 1px solid #ecdfc9; margin-bottom: 10px;
}
.ml-pain-card h3 { font-size: 15px; font-weight: 700; margin: 0 0 8px; }
.ml-pain-card p { font-size: 12px; color: var(--ml-text-muted); margin: 0; line-height: 1.6; }

/* ---------- six modules ---------- */
.ml-modules-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.ml-modules-section { background-color: #fff; background-repeat: no-repeat; background-position: center; background-size: cover; }
.ml-section-dash { width: 32px; height: 3px; border-radius: 2px; background: var(--ml-teal); margin: 0 auto 32px; }
.ml-module-card {
  border: 1px solid var(--ml-border); border-radius: 14px; padding: 22px 14px; text-align: center;
  background: #fff; box-shadow: 0 4px 16px rgba(16,38,45,.05);
  transition: transform .2s ease, box-shadow .2s ease;
}
.ml-module-card:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(16,38,45,.09); }
.ml-module-card.is-active { background: var(--ml-teal-light); border-color: var(--ml-teal); }
.ml-module-num {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 34px; height: 26px; padding: 0 8px; border-radius: 8px;
  border: 1.5px solid var(--ml-teal); color: var(--ml-teal); background: #fff;
  font-size: 12px; font-weight: 700; margin-bottom: 14px;
}
.ml-module-card.is-active .ml-module-num { background: var(--ml-teal); color: #fff; border-color: var(--ml-teal); }
.ml-module-card .ml-module-icon { color: var(--ml-teal); margin: 6px auto 14px; display: flex; justify-content: center; }
.ml-module-card h3 { font-size: 15px; font-weight: 700; margin: 0 0 8px; }
.ml-module-card p { font-size: 11.5px; color: var(--ml-text-muted); margin: 0; line-height: 1.5; }
.ml-module-dash { width: 20px; height: 2px; border-radius: 2px; background: var(--ml-border); margin: 16px auto 0; }
.ml-module-card.is-active .ml-module-dash { background: var(--ml-teal); }

/* ---------- radar test banner (dark, full-width) ---------- */
.ml-radar-banner {
  position: relative; overflow: hidden;
  background: linear-gradient(115deg, var(--ml-dark) 0%, var(--ml-dark-2) 100%);
  padding: 48px 0;
}
.ml-radar-banner-photo {
  position: absolute; right: 0; top: 0; height: 100%; width: 22%; min-width: 220px;
  object-fit: cover; object-position: center;
  mask-image: linear-gradient(to right, transparent, #000 38%);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 38%);
  opacity: .9;
}
.ml-radar-banner-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr auto 1fr; gap: 40px; align-items: center;
}
.ml-radar-banner-text h3 { font-size: 22px; font-weight: 800; margin: 0 0 10px; color: #fff; }
.ml-radar-banner-text p { font-size: 13px; color: #c3d6d6; line-height: 1.7; margin: 0 0 22px; }
.ml-radar-wrap { display: flex; justify-content: center; }
.ml-radar-checklist li {
  display: flex; align-items: center; gap: 9px;
  font-size: 13.5px; color: #fff; font-weight: 500; margin-top: 14px;
}
.ml-radar-checklist li:first-child { margin-top: 0; }
.ml-radar-checklist li svg { color: #7fd1d6; flex-shrink: 0; }

/* ---------- 5 advantages ---------- */
.ml-adv-panel {
  border: 1px solid var(--ml-border); border-radius: 18px; padding: 36px 24px;
  box-shadow: 0 6px 24px rgba(16,38,45,.06);
  display: grid; grid-template-columns: repeat(5, 1fr);
}
.ml-adv-item { text-align: center; padding: 0 12px; position: relative; }
.ml-adv-item + .ml-adv-item::before {
  content: ""; position: absolute; left: 0; top: 6px; bottom: 6px; width: 1px; background: var(--ml-border);
}
.ml-adv-icon {
  width: 56px; height: 56px; border-radius: 50%; background: var(--ml-teal-light);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 14px; color: var(--ml-teal);
}
.ml-adv-item h4 { font-size: 13.5px; font-weight: 700; margin: 0 0 6px; }
.ml-adv-item p { font-size: 11.5px; color: var(--ml-text-muted); margin: 0; line-height: 1.5; }

/* ---------- coaches ---------- */
.ml-coaches-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.ml-coach-card { border: 1px solid var(--ml-border); border-radius: var(--ml-radius); overflow: hidden; }
.ml-coach-card img { width: 100%; aspect-ratio: 3/4; object-fit: cover; }
.ml-coach-card-body { padding: 18px; }
.ml-coach-card h3 { font-size: 17px; font-weight: 800; margin: 0 0 3px; }
.ml-coach-card .ml-coach-role { font-size: 13px; color: var(--ml-teal); font-weight: 600; margin: 0 0 12px; }
.ml-coach-card ul li { display: flex; align-items: flex-start; gap: 6px; font-size: 12.5px; color: var(--ml-text-muted); margin-top: 6px; }
.ml-coach-card ul li svg { color: var(--ml-teal); margin-top: 2px; }
.ml-coach-card .ml-btn { margin-top: 14px; }
.ml-coach-team-body { text-align: center; padding: 22px 18px; }
.ml-coach-team-body h3 { font-size: 16px; font-weight: 800; margin: 0 0 4px; }
.ml-coach-team-body p { font-size: 12px; color: var(--ml-text-muted); margin: 0 0 14px; }

/* ---------- stats + testimonials ---------- */
.ml-stats-panel {
  border: 1px solid var(--ml-border); border-radius: var(--ml-radius);
  display: grid; grid-template-columns: repeat(5, 1fr) 1.3fr; align-items: center;
  margin-bottom: 22px; overflow: hidden;
}
.ml-stats-panel > div { padding: 20px 14px; text-align: center; border-right: 1px solid var(--ml-border); }
.ml-stats-panel > div:last-child { border-right: none; background: var(--ml-bg-alt); text-align: left; }
.ml-stats-panel svg { color: var(--ml-teal); margin-bottom: 6px; }
.ml-stats-panel .ml-stat-num { font-size: 19px; font-weight: 800; }
.ml-stats-panel .ml-stat-label { font-size: 11px; color: var(--ml-text-muted); margin-top: 3px; }
.ml-stats-panel .ml-stars { color: var(--ml-gold); font-size: 12px; margin-top: 2px; }
.ml-stats-cta h4 { font-size: 14px; font-weight: 700; margin: 0 0 4px; }
.ml-stats-cta p { font-size: 11px; color: var(--ml-text-muted); margin: 0 0 10px; }

.ml-testimonial-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.ml-testimonial-card { border: 1px solid var(--ml-border); border-radius: 12px; padding: 16px; }
.ml-testimonial-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.ml-testimonial-head img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.ml-testimonial-head span { font-size: 12px; color: var(--ml-text-muted); font-weight: 600; }
.ml-testimonial-card p { font-size: 12.5px; color: var(--ml-text); line-height: 1.6; margin: 0; }

/* ---------- FAQ (native <details>, no JS needed) ---------- */
.ml-faq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 24px; }
.ml-faq-item { border: 1px solid var(--ml-border); border-radius: 10px; padding: 4px 18px; }
.ml-faq-item summary {
  cursor: pointer; list-style: none; padding: 14px 0;
  display: flex; align-items: center; justify-content: space-between;
  font-size: 13.5px; font-weight: 600;
}
.ml-faq-item summary::-webkit-details-marker { display: none; }
.ml-faq-item summary::after { content: "+"; font-size: 18px; color: var(--ml-text-muted); font-weight: 400; }
.ml-faq-item[open] summary::after { content: "−"; }
.ml-faq-item p { font-size: 12.5px; color: var(--ml-text-muted); margin: 0 0 16px; line-height: 1.6; }

/* ---------- CTA banner ---------- */
.ml-cta-banner {
  position: relative; border-radius: 18px; overflow: hidden; background: var(--ml-dark-2);
  padding: 46px 40px; display: grid; grid-template-columns: 1.3fr 1fr; align-items: center; gap: 24px;
}
.ml-cta-banner img {
  position: absolute; right: 0; top: 0; height: 100%; width: 52%; object-fit: cover; object-position: right 20%;
  mask-image: linear-gradient(to right, transparent, #000 40%);
  -webkit-mask-image: linear-gradient(to right, transparent, #000 40%);
}
.ml-cta-banner::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, var(--ml-dark-2) 0%, rgba(10,46,54,.55) 32%, rgba(10,46,54,0) 60%);
}
.ml-cta-banner-content { position: relative; z-index: 1; color: #fff; }
.ml-cta-banner-content h3 { font-size: 22px; font-weight: 800; line-height: 1.5; margin: 0 0 18px; }
.ml-cta-banner-actions { display: flex; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.ml-cta-banner-content .ml-trust-row span { color: #cfe1e1; }
.ml-cta-banner-content .ml-trust-row svg { color: #7fb8bb; }

/* ---------- footer ---------- */
.ml-footer { background: var(--ml-dark-2); color: #b9cbcc; padding: 48px 0 0; }
.ml-footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.2fr; gap: 24px; padding-bottom: 34px; border-bottom: 1px solid rgba(255,255,255,.08); }
.ml-footer-brand .ml-logo-main { color: #fff; }
.ml-footer-brand .ml-logo-sub { color: #7d9899; }
.ml-footer-brand p { font-size: 12px; color: #93aaab; margin: 12px 0 14px; }
.ml-footer-social { display: flex; gap: 10px; }
.ml-footer-social a {
  width: 30px; height: 30px; border-radius: 50%; border: 1px solid rgba(255,255,255,.25);
  display: flex; align-items: center; justify-content: center; color: #cfe1e1;
}
.ml-footer h4 { font-size: 13px; font-weight: 700; color: #fff; margin: 0 0 14px; }
.ml-footer-links li { margin-bottom: 9px; }
.ml-footer-links a { font-size: 12.5px; color: #b9cbcc; }
.ml-footer-links a:hover { color: #fff; }
.ml-footer-contact li { display: flex; align-items: center; gap: 8px; font-size: 12px; color: #b9cbcc; margin-bottom: 10px; }
.ml-footer-contact svg { color: #7fb8bb; }
.ml-footer-bottom { display: flex; justify-content: space-between; align-items: center; padding: 18px 0; font-size: 11.5px; color: #7d9899; flex-wrap: wrap; gap: 8px; }
.ml-footer-bottom a { color: #7d9899; margin-left: 14px; }
.ml-footer-bottom a:hover { color: #fff; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1000px) {
  .ml-modules-grid { grid-template-columns: repeat(3, 1fr); row-gap: 20px; }
  .ml-adv-panel { grid-template-columns: repeat(3, 1fr); row-gap: 20px; }
  .ml-radar-banner-grid { grid-template-columns: 1fr; text-align: center; }
  .ml-radar-banner-photo { display: none; }
  .ml-radar-checklist { display: inline-block; text-align: left; }
  .ml-stats-panel { grid-template-columns: repeat(3, 1fr); }
  .ml-stats-panel > div:last-child { grid-column: 1 / -1; text-align: center; }
  .ml-footer-grid { grid-template-columns: 1fr 1fr; row-gap: 28px; }
}

@media (max-width: 820px) {
  .ml-nav { display: none; }
  .ml-hero-full { min-height: 460px; }
  .ml-hero-full-bg { object-position: 75% center; }
  .ml-hero-full-overlay { background: linear-gradient(180deg, #fff 0%, #fff 40%, rgba(255,255,255,0) 62%, rgba(255,255,255,0) 100%); }
  .ml-hero-full-content { max-width: 100%; }
  .ml-pain-grid { grid-template-columns: 1fr 1fr; }
  .ml-coaches-grid { grid-template-columns: 1fr; }
  .ml-testimonial-grid { grid-template-columns: 1fr 1fr; }
  .ml-faq-grid { grid-template-columns: 1fr; }
  .ml-cta-banner { grid-template-columns: 1fr; }
  .ml-cta-banner img { display: none; }
}

@media (max-width: 560px) {
  .ml-hero-full-content h1 { font-size: 28px; }
  .ml-hero-full { min-height: 400px; }
  .ml-pain-grid { grid-template-columns: 1fr; }
  .ml-modules-grid { grid-template-columns: 1fr 1fr; }
  .ml-adv-panel { grid-template-columns: 1fr 1fr; }
  .ml-stats-panel { grid-template-columns: 1fr 1fr; }
  .ml-testimonial-grid { grid-template-columns: 1fr; }
  .ml-footer-grid { grid-template-columns: 1fr; }
}
