/* ============================================================
   朝顏 Asagao 學苑 — Education Template
   風格：nii.school 教學單純風（無襯線、扁平、教學導向）
   ============================================================ */

:root {
  --bg: #ffffff;
  --bg-soft: #f4eef9;          /* 偶數區塊的薰衣草淡底 */
  --bg-section: #e8def0;       /* 學員心得區的飽和一點 */
  --bg-card: #ffffff;
  --accent: #8b6dc8;           /* 朝顏紫（呼應品牌名 morning glory） */
  --accent-hover: #6f4eb3;
  --accent-tint: #e3d8f5;      /* 螢光筆底色 */
  --text: #1a1a1a;
  --text-mid: #4a4a4a;
  --text-soft: #8a8a8a;
  --border: #ebe4f3;           /* 帶紫 hint 邊框 */
  --border-strong: #cebee2;
  --sans: 'Inter', 'Noto Sans TC', -apple-system, BlinkMacSystemFont, sans-serif;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --radius: 10px;
  --radius-sm: 6px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.75;
  font-size: 15.5px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul { list-style: none; }
/* em：螢光筆畫底（教學筆記感），不換字型、不斜體 */
em {
  font-style: normal;
  font-weight: 700;
  color: var(--text);
  background-image: linear-gradient(180deg, transparent 60%, var(--accent-tint) 60%);
  padding: 0 3px;
  /* 鎖住高亮不被換行斷裂的部分破壞觀感 */
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}
/* 導覽 logo / 報名暗底 / footer：改用色塊文字，不畫底 */
.nav-logo em, .enroll-title em, .foot-brand em {
  background-image: none;
  color: var(--accent);
  padding: 0;
}

/* 中文排版：避免孤字成行 */
h1, h2, h3, h4 { text-wrap: balance; }
p { text-wrap: pretty; }

.container { width: min(1180px, 92%); margin: 0 auto; }

/* 拔掉「精品」裝飾 ----------------------------------------- */
.preloader { display: none !important; }
.hero-badge { display: none; }
.hero-tag { display: none; }
.path-line { display: none; }
.path-step::before { display: none; }
.story-card::before { display: none; }
.enroll-card::before { display: none; }
.pc-tag { display: none; }
.teacher-tags { display: none; }

/* ============ Reveal ============ */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

/* ============ Buttons（方角、明確） ============ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 24px;
  font-size: 15px; font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
  white-space: nowrap;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { border-color: var(--text); }
.btn-nav { background: var(--accent); color: #fff; padding: 10px 18px; font-size: 14px; }
.btn-nav:hover { background: var(--accent-hover); }
.btn-full { width: 100%; justify-content: center; padding: 15px; font-size: 16px; }

/* ============ NAV ============ */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: border-color .2s var(--ease);
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 0;
}
.nav-logo {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 18px; font-weight: 700;
  color: var(--text);
  letter-spacing: 0;
}
.nav-logo svg { color: var(--accent); }
.nav-logo em { font-size: 16px; font-weight: 700; }
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a:not(.btn) {
  font-size: 14.5px; font-weight: 500;
  color: var(--text-mid);
}
.nav-links a:not(.btn):hover { color: var(--accent); }
.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; width: 28px; }
.nav-toggle span { display: block; width: 100%; height: 2px; background: var(--text); border-radius: 2px; transition: all .25s var(--ease); }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.mobile-menu {
  position: fixed; top: 64px; left: 0; right: 0;
  background: var(--bg); border-bottom: 1px solid var(--border);
  padding: 12px 0 20px;
  transform: translateY(-110%); transition: transform .35s var(--ease);
  z-index: 99;
}
.mobile-menu.open { transform: translateY(0); }
.mobile-menu ul { display: flex; flex-direction: column; padding: 0 6%; }
.mobile-menu a {
  display: block; padding: 14px 4px;
  font-size: 16px; font-weight: 500; color: var(--text);
  border-bottom: 1px solid var(--border);
}

/* ============ HERO ============ */
.hero { padding: 60px 0 80px; }
.hero-grid {
  display: grid; grid-template-columns: 1.15fr 1fr;
  gap: 64px; align-items: center;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13px; font-weight: 600;
  color: var(--accent);
  margin-bottom: 22px;
}
.hero-eyebrow .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.hero-title {
  font-size: clamp(30px, 3.6vw, 44px);
  font-weight: 800; line-height: 1.4;
  letter-spacing: 0;
  color: var(--text);
  margin-bottom: 24px;
}
.hero-deck {
  font-size: 16px; color: var(--text-mid);
  margin-bottom: 32px; max-width: 540px;
  line-height: 1.85;
}
.hero-actions {
  display: flex; gap: 12px; flex-wrap: wrap;
  margin-bottom: 48px;
}
.hero-stats {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}
.hs strong {
  display: block;
  font-size: 26px; font-weight: 800;
  color: var(--text); line-height: 1.1;
  margin-bottom: 6px;
  letter-spacing: 0;
}
.hs strong span { font-size: 16px; color: var(--accent); margin-left: 2px; }
.hs p { font-size: 13px; color: var(--text-soft); margin: 0; }

.hero-visual { position: relative; }
.hero-photo {
  border-radius: var(--radius); overflow: hidden;
  aspect-ratio: 5/6;
  border: 1px solid var(--border);
}
.hero-photo img { width: 100%; height: 100%; object-fit: cover; }

/* ============ Section Head ============ */
.section-head { max-width: 880px; margin-bottom: 48px; }
.section-kicker {
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 12px;
}
.section-title {
  font-size: clamp(24px, 2.8vw, 34px);
  font-weight: 800; line-height: 1.4;
  letter-spacing: 0;
  color: var(--text);
  margin-bottom: 14px;
}
.section-deck {
  font-size: 16px; color: var(--text-mid);
  max-width: 640px;
  line-height: 1.85;
}

/* ============ WHY US ============ */
.why { padding: 72px 0; background: var(--bg-soft); }
.why-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.why-card {
  background: var(--bg-card);
  padding: 28px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.why-num {
  font-size: 13px; font-weight: 700;
  color: var(--accent);
  margin-bottom: 14px;
  letter-spacing: 0.05em;
}
.why-card h3 {
  font-size: 18px; font-weight: 700;
  line-height: 1.55;
  color: var(--text);
  margin-bottom: 10px;
}
.why-card p {
  font-size: 14.5px; color: var(--text-mid);
  line-height: 1.8;
}

/* ============ COURSE PATH（三階段，扁平卡片） ============ */
.path { padding: 80px 0; }
.path-track { display: flex; flex-direction: column; gap: 16px; }
.path-step {
  display: grid; grid-template-columns: 180px 1fr;
  gap: 32px; align-items: stretch;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 32px;
}
.path-marker { display: flex; flex-direction: column; justify-content: center; }
.pm-stage {
  display: block;
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.12em; color: var(--accent);
  margin-bottom: 6px;
}
.pm-name {
  display: block;
  font-size: 28px; font-weight: 800;
  color: var(--text); line-height: 1.2;
}
.path-card { padding: 0; border: none; background: transparent; }
.pc-head { margin-bottom: 14px; }
.pc-head h3 {
  font-size: 20px; font-weight: 700;
  color: var(--text);
  display: flex; align-items: baseline; gap: 12px;
  flex-wrap: wrap;
}
.pc-head h3 span {
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.15em; color: var(--text-soft);
}
.pc-line {
  font-size: 15px; color: var(--text);
  line-height: 1.85; margin-bottom: 14px;
  font-weight: 500;
}
.pc-list {
  display: flex; flex-direction: column; gap: 4px;
  margin-bottom: 16px;
}
.pc-list li {
  font-size: 14px; color: var(--text-mid);
  padding-left: 16px; position: relative;
  line-height: 1.7;
}
.pc-list li::before {
  content: '·'; position: absolute;
  left: 4px; top: 0;
  color: var(--accent); font-weight: 700;
  font-size: 22px; line-height: 1.4;
}
.pc-foot {
  display: flex; gap: 18px; flex-wrap: wrap;
  padding-top: 14px; border-top: 1px solid var(--border);
}
.pc-duration, .pc-level {
  font-size: 13px; color: var(--text-mid); font-weight: 500;
}
.pc-level { color: var(--accent); font-weight: 600; }

/* ============ COURSES ============ */
.courses { padding: 80px 0; background: var(--bg-soft); }
.course-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 16px; margin-bottom: 36px;
}
.course-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  display: flex; flex-direction: column;
}
.course-meta { display: flex; gap: 6px; margin-bottom: 14px; }
.cm-level, .cm-lang {
  font-size: 11.5px; font-weight: 700;
  letter-spacing: 0.05em;
  padding: 4px 10px;
  border-radius: 4px;
  background: var(--bg-soft);
  color: var(--text-mid);
}
.cm-level.cm-hot { background: var(--accent); color: #fff; }
.cm-lang { background: var(--accent-tint); color: var(--accent-hover); }
.course-card h3 {
  font-size: 18px; font-weight: 700;
  color: var(--text);
  margin-bottom: 8px; line-height: 1.45;
}
.course-card > p {
  font-size: 14.5px; color: var(--text-mid);
  line-height: 1.75; margin-bottom: 18px;
  flex: 1;
}
.course-foot {
  display: flex; justify-content: space-between; align-items: baseline;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
.course-foot > span:first-child {
  font-size: 12.5px; color: var(--text-soft);
}
.course-price {
  font-size: 17px; font-weight: 700;
  color: var(--accent);
}
.courses-foot { text-align: left; }

/* ============ TEACHERS ============ */
.teachers { padding: 80px 0; }
.teacher-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.teacher-card {
  background: transparent;
  border: none;
}
.teacher-photo {
  aspect-ratio: 4/5; overflow: hidden;
  background: var(--bg-soft);
  border-radius: var(--radius);
  margin-bottom: 14px;
}
.teacher-photo img { width: 100%; height: 100%; object-fit: cover; }
.teacher-body { padding: 0; }
.teacher-body h3 {
  font-size: 18px; font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
  display: flex; align-items: baseline; gap: 6px;
}
.teacher-body h3 span {
  font-size: 12px; font-weight: 500;
  color: var(--text-soft);
}
.teacher-from {
  font-size: 13px; color: var(--accent);
  font-weight: 600;
  margin-bottom: 6px;
}
.teacher-bio {
  font-size: 14px; color: var(--text-mid);
  line-height: 1.75;
}

/* ============ STORIES ============ */
.stories { padding: 80px 0; background: var(--bg-section); }
.story-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.story-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  display: flex; flex-direction: column;
}
.story-quote {
  font-size: 15px; color: var(--text);
  line-height: 1.9;
  margin-bottom: 22px; flex: 1;
  font-weight: 400;
}
.story-meta {
  display: flex; align-items: center; gap: 12px;
  padding-top: 18px; border-top: 1px solid var(--border);
}
.story-meta img {
  width: 40px; height: 40px;
  border-radius: 50%; object-fit: cover;
}
.story-meta strong { display: block; font-size: 14.5px; font-weight: 700; color: var(--text); }
.story-meta span { display: block; font-size: 12.5px; color: var(--text-soft); margin-top: 2px; }

/* ============ ENROLL ============ */
.enroll { padding: 80px 0; }
.enroll-card {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 48px;
  background: var(--text); color: #fff;
  border-radius: var(--radius);
  padding: 48px;
}
.enroll-kicker {
  font-size: 13px; font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--accent);
  margin-bottom: 14px;
}
.enroll-title {
  font-size: clamp(22px, 2.2vw, 28px);
  font-weight: 800; line-height: 1.55;
  color: #fff;
  margin-bottom: 18px;
}
.enroll-title em { color: var(--accent); font-weight: 800; }
.enroll-deck {
  font-size: 15px; color: rgba(255, 255, 255, 0.72);
  line-height: 1.85; margin-bottom: 24px;
}
.enroll-perks { display: flex; flex-direction: column; gap: 8px; }
.enroll-perks li {
  font-size: 14px; color: rgba(255, 255, 255, 0.88);
  padding-left: 20px; position: relative;
  line-height: 1.7;
}
.enroll-perks li::before {
  content: ''; position: absolute;
  left: 0; top: 11px;
  width: 12px; height: 2px;
  background: var(--accent);
}
.enroll-form {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 32px;
  color: var(--text);
}
.enroll-form h3 {
  font-size: 20px; font-weight: 700;
  margin-bottom: 20px;
  color: var(--text);
}
.enroll-form label { display: block; margin-bottom: 14px; }
.enroll-form label span {
  display: block;
  font-size: 13px; font-weight: 600;
  color: var(--text-mid);
  margin-bottom: 5px;
}
.enroll-form input,
.enroll-form select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  font-family: var(--sans);
  font-size: 14.5px;
  color: var(--text);
  background: var(--bg);
  transition: border-color .2s var(--ease);
}
.enroll-form input:focus,
.enroll-form select:focus { outline: none; border-color: var(--accent); }
.enroll-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23999' stroke-width='2' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
}
.enroll-form .btn { margin-top: 4px; }
.form-note {
  font-size: 11.5px; color: var(--text-soft);
  margin-top: 12px; line-height: 1.6;
}

/* ============ FOOTER ============ */
.footer { background: var(--text); color: #fff; padding: 56px 0 28px; }
.footer-grid {
  display: grid; grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: 40px;
  padding-bottom: 36px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.foot-brand .nav-logo { color: #fff; margin-bottom: 14px; }
.foot-brand .nav-logo em { color: var(--accent); }
.foot-brand p {
  font-size: 14px; color: rgba(255, 255, 255, 0.6);
  line-height: 1.8;
}
.foot-col h4 {
  font-size: 14px; font-weight: 700;
  color: #fff;
  margin-bottom: 14px;
}
.foot-col ul { display: flex; flex-direction: column; gap: 8px; }
.foot-col li, .foot-col a {
  font-size: 13.5px; color: rgba(255, 255, 255, 0.6);
}
.foot-col a:hover { color: var(--accent); }
.footer-bottom {
  display: flex; justify-content: space-between;
  padding-top: 22px;
  font-size: 12.5px; color: rgba(255, 255, 255, 0.42);
  flex-wrap: wrap; gap: 12px;
}
.footer-bottom a:hover { color: var(--accent); }

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
  .why-grid, .teacher-grid { grid-template-columns: repeat(2, 1fr); }
  .course-grid, .story-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 760px) {
  body { font-size: 15px; }
  .nav-links { display: none; }
  .nav-toggle { display: flex; }
  .hero { padding: 40px 0 56px; }
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-stats { grid-template-columns: repeat(2, 1fr); gap: 18px 14px; }
  .hs strong { font-size: 22px; }
  .hero-visual { max-width: 420px; margin: 0 auto; }
  .why, .path, .courses, .teachers, .stories, .enroll { padding: 56px 0; }
  .why-grid, .course-grid, .teacher-grid, .story-grid { grid-template-columns: 1fr; gap: 14px; }
  .path-step { grid-template-columns: 1fr; gap: 14px; padding: 22px 22px; }
  .path-marker { flex-direction: row; align-items: baseline; gap: 10px; }
  .pm-stage { margin-bottom: 0; }
  .pm-name { font-size: 24px; }
  .enroll-card { grid-template-columns: 1fr; gap: 32px; padding: 32px 24px; }
  .enroll-form { padding: 24px 22px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; padding-bottom: 28px; }
  .footer-bottom { flex-direction: column; }
}

@media (max-width: 420px) {
  .hero-title { font-size: 26px; }
  .section-title { font-size: 22px; }
}
