/* ===== Header（Kadence 頁首編輯器） ===== */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--p9); border-bottom: 1px solid var(--line); }
.site-header__inner { display: flex; align-items: center; gap: var(--s5); min-height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--p3); text-decoration: none; font-family: var(--font-heading); font-weight: var(--heading-weight); font-size: 1.25rem; letter-spacing: 0.08em; white-space: nowrap; }
.brand svg { width: 30px; height: 30px; color: var(--p1); flex: none; }
.brand:hover { color: var(--p3); }
.nav { display: flex; gap: var(--s1); margin-left: auto; }
.nav a { color: var(--p4); text-decoration: none; font-size: var(--fs-sm); font-weight: 500; padding: 8px 12px; border-radius: 6px; white-space: nowrap; }
.nav a:hover { color: var(--p1); background: var(--p8); }
.nav a[aria-current="page"] { color: var(--p1); }
.header-actions { display: flex; align-items: center; gap: var(--s2); }
.icon-btn { position: relative; display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; border: 0; background: transparent; color: var(--p4); cursor: pointer; text-decoration: none; }
.icon-btn:hover { background: var(--p8); color: var(--p1); }
.icon-btn svg { width: 22px; height: 22px; }
.icon-btn .count { position: absolute; top: 4px; right: 2px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 9px; background: var(--p1); color: var(--p9); font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.account { position: relative; }
.account__btn { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border: 1px solid var(--line); border-radius: 999px; background: var(--p9); cursor: pointer; font-size: var(--fs-sm); color: var(--p4); }
.avatar { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--tint); color: var(--p1); font-weight: 700; font-size: 14px; }
.account__menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 200px; padding: 8px; background: var(--p9); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); display: none; }
.account[data-open] .account__menu { display: block; }
.account__menu a { display: block; padding: 9px 12px; border-radius: 8px; color: var(--p4); text-decoration: none; font-size: var(--fs-sm); }
.account__menu a:hover { background: var(--p8); color: var(--p1); }
.account__menu hr { border: 0; border-top: 1px solid var(--line); margin: 6px 4px; }
[data-auth="in"] .only-out, [data-auth="out"] .only-in { display: none !important; }
.menu-toggle { display: none; }
.drawer { display: none; }
/* 8 個選單加較長的品牌名，1100px 以下放不下一排，改用收合選單。 */
@media (max-width: 1100px) {
  .nav, .header-actions .btn, .account { display: none; }
  .menu-toggle { display: inline-grid; }
  .header-actions { margin-left: auto; gap: 2px; }
  .drawer[data-open] { display: block; position: fixed; inset: 72px 0 0; z-index: 39; background: var(--p9); padding: var(--s5) var(--gutter); overflow-y: auto; }
  .drawer nav { display: flex; flex-direction: column; }
  .drawer nav a { padding: 14px 4px; border-bottom: 1px solid var(--line); color: var(--p3); text-decoration: none; font-size: var(--fs-lg); font-weight: 500; }
  .drawer .stack { margin-top: var(--s5); }
}

/* ===== Buttons ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 0 22px; border: 1.5px solid transparent; border-radius: var(--radius-btn); font-size: var(--fs-sm); font-weight: 700; letter-spacing: 0.04em; text-decoration: none; cursor: pointer; transition: background-color .18s, border-color .18s, color .18s, transform .18s; white-space: nowrap; }
.btn--primary { background: var(--p1); color: var(--p9); }
.btn--primary:hover { background: var(--p2); color: var(--p9); }
.btn--secondary { background: var(--p9); color: var(--p1); border-color: color-mix(in srgb, var(--p1) 45%, var(--p9)); }
.btn--secondary:hover { border-color: var(--p1); color: var(--p2); }
.btn--light { background: var(--p9); color: var(--p3); }
.btn--light:hover { background: var(--p8); color: var(--p3); }
.btn--outline-light { background: transparent; color: var(--p9); border-color: color-mix(in srgb, var(--p9) 60%, transparent); }
.btn--outline-light:hover { border-color: var(--p9); color: var(--p9); background: color-mix(in srgb, var(--p9) 12%, transparent); }
.btn--text { min-height: auto; padding: 0; color: var(--p1); background: none; border: 0; letter-spacing: 0.02em; }
.btn--text:hover { color: var(--p2); }
.btn--block { width: 100%; }
.btn--sm { min-height: 38px; padding: 0 16px; }
.btn[disabled], .btn[aria-disabled="true"] { background: var(--p7); color: var(--p6); border-color: transparent; cursor: not-allowed; }
.arrow { transition: transform .18s; }
a:hover > .arrow, button:hover > .arrow { transform: translateX(3px); }

/* ===== Badges / price / rating ===== */
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px; font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.04em; background: var(--tint); color: var(--p1); white-space: nowrap; }
.badge--solid { background: var(--p1); color: var(--p9); }
.badge--neutral { background: var(--p7); color: var(--p5); }
.badge--light { background: color-mix(in srgb, var(--p9) 90%, transparent); color: var(--p3); }
.price { display: inline-flex; align-items: baseline; gap: 8px; color: var(--p3); font-weight: 700; font-variant-numeric: tabular-nums; }
.price__cur { font-size: 0.8em; font-weight: 500; color: var(--p5); }
.price__was { color: var(--p6); font-weight: 400; font-size: 0.85em; text-decoration: line-through; }
.price--lg { font-size: 2rem; letter-spacing: 0.01em; }
.rating { display: inline-flex; align-items: center; gap: 6px; font-size: var(--fs-sm); color: var(--p5); }
.rating b { color: var(--p3); }
.stars { color: #C98A1B; letter-spacing: 1px; }

/* ===== Listing card（課程、服務、商品共用） ===== */
.card { display: flex; flex-direction: column; gap: var(--s4); color: inherit; text-decoration: none; }
.card__media { position: relative; overflow: hidden; border-radius: var(--radius-card); background: var(--p7); aspect-ratio: 3 / 2; }
.card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card__media img { transform: scale(1.04); }
.card__tags { position: absolute; left: 12px; top: 12px; display: flex; gap: 6px; flex-wrap: wrap; }
.card__body { display: flex; flex-direction: column; gap: var(--s2); flex: 1; }
.card__title { font-size: var(--fs-lg); color: var(--p3); transition: color .18s; }
.card:hover .card__title { color: var(--p1); }
.card__meta { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: var(--fs-sm); color: var(--p5); }
.card__meta span + span::before { content: ""; display: inline-block; width: 3px; height: 3px; margin: 0 10px 3px -7px; border-radius: 50%; background: var(--p6); vertical-align: middle; }
.card__foot { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); margin-top: auto; padding-top: var(--s3); border-top: 1px solid var(--line); }
.card__cta { font-size: var(--fs-sm); font-weight: 700; color: var(--p1); }
/* 網格卡片外框：課程、服務、文章、商品共用（Kadence 查詢迴圈卡片的邊框、圓角、陰影）。橫式列表不加框。 */
:is(.card, .post-grid .post, .products:not(.products--list) .product-card) { overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); box-shadow: var(--shadow-sm); transition: box-shadow .25s ease, transform .25s ease; }
:is(.card, .post-grid .post, .products:not(.products--list) .product-card):hover { box-shadow: var(--shadow); transform: translateY(-3px); }
:is(.card__media, .post-grid .post__media, .products:not(.products--list) .product-card__media) { border-radius: 0; }
:is(.card__body, .post-grid .post__body) { padding: 0 var(--s5) var(--s5); }
.products:not(.products--list) .product-card__body { flex: 1; padding: 0 var(--s4) var(--s4); }
.products:not(.products--list) .product-card__action { margin-top: auto; }

/* ===== Hero（首頁） ===== */
.hero { position: relative; display: grid; align-items: end; min-height: min(78svh, 760px); color: var(--p9); isolation: isolate; overflow: hidden; }
.hero__img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 70% 50%; animation: heroZoom 1.6s ease-out both; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, color-mix(in srgb, var(--p3) 78%, transparent) 0%, color-mix(in srgb, var(--p3) 42%, transparent) 46%, transparent 78%), linear-gradient(0deg, color-mix(in srgb, var(--p3) 45%, transparent), transparent 45%); }
.hero__content { padding-block: clamp(80px, 12vw, 140px) clamp(56px, 8vw, 96px); display: flex; flex-direction: column; gap: var(--s5); max-width: 36rem; }
.hero__content > * { animation: rise .8s cubic-bezier(.2,.7,.2,1) both; }
.hero__content > *:nth-child(2) { animation-delay: .08s; }
.hero__content > *:nth-child(3) { animation-delay: .16s; }
.hero__content > *:nth-child(4) { animation-delay: .24s; }
.hero h1 { color: var(--p9); font-size: var(--fs-hero); line-height: 1.18; }
.hero .eyebrow { color: color-mix(in srgb, var(--p9) 85%, transparent); }
.hero p { color: color-mix(in srgb, var(--p9) 88%, transparent); font-size: var(--fs-lg); max-width: 30em; }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes heroZoom { from { transform: scale(1.06); } to { transform: none; } }

/* ===== Page hero（總覽頁、內頁標題區） ===== */
.page-hero { background: var(--p8); border-bottom: 1px solid var(--line); }
.page-hero__inner { padding-block: clamp(48px, 7vw, 88px) clamp(32px, 4vw, 48px); display: flex; flex-direction: column; gap: var(--s3); }
.page-hero h1 { font-size: var(--fs-3xl); }
.breadcrumb { display: flex; flex-wrap: wrap; gap: 6px; font-size: var(--fs-xs); color: var(--p6); }
.breadcrumb a { color: var(--p5); text-decoration: none; }
.breadcrumb a:hover { color: var(--p1); }
.breadcrumb span[aria-hidden] { color: var(--line-strong); }

/* ===== Filter bar / chips / select / pagination ===== */
.filter-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s4); padding-block: var(--s5); border-bottom: 1px solid var(--line); margin-bottom: var(--s6); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 38px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--p9); color: var(--p4); font-size: var(--fs-sm); cursor: pointer; }
.chip:hover { border-color: var(--p1); color: var(--p1); }
.chip[aria-pressed="true"] { background: var(--p3); border-color: var(--p3); color: var(--p9); }
.result-count { font-size: var(--fs-sm); color: var(--p5); }
.select { min-height: 42px; padding: 0 38px 0 14px; border: 1px solid var(--line-strong); border-radius: var(--radius-input); background: var(--p9) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23857A72' stroke-width='1.6'/%3E%3C/svg%3E") no-repeat right 14px center; appearance: none; font-size: var(--fs-sm); }
.pagination { display: flex; justify-content: center; gap: 6px; margin-top: var(--s7); }
.pagination a, .pagination span { display: inline-grid; place-items: center; min-width: 42px; height: 42px; padding: 0 12px; border-radius: 8px; color: var(--p4); text-decoration: none; font-variant-numeric: tabular-nums; }
.pagination a:hover { background: var(--p8); color: var(--p1); }
.pagination [aria-current="page"] { background: var(--p3); color: var(--p9); }
.empty-state { display: flex; flex-direction: column; align-items: center; gap: var(--s3); padding: var(--s8) var(--s5); text-align: center; border: 1px dashed var(--line-strong); border-radius: var(--radius-card); background: var(--p8); }
.empty-state svg { width: 48px; height: 48px; color: var(--p6); }

/* ===== Teacher / quotes / features / FAQ / CTA ===== */
.media-frame { overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 4 / 5; background: var(--p7); }
.media-frame img { width: 100%; height: 100%; object-fit: cover; }
.facts { display: flex; flex-wrap: wrap; gap: var(--s5) var(--s6); padding-top: var(--s5); border-top: 1px solid var(--line); }
.facts div { display: flex; flex-direction: column; }
.facts b { font-family: var(--font-heading); font-size: var(--fs-xl); color: var(--p3); font-variant-numeric: tabular-nums; }
.facts span { font-size: var(--fs-sm); color: var(--p5); }
.quote-feature { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 72px); align-items: start; }
.quote { display: flex; flex-direction: column; gap: var(--s4); margin: 0; }
.quote blockquote { margin: 0; font-family: var(--font-heading); color: var(--p3); font-size: var(--fs-2xl); line-height: 1.5; font-weight: 500; }
.quote--sm blockquote { font-family: var(--font-body); font-size: var(--fs-base); line-height: 1.75; font-weight: 400; color: var(--p4); }
.quote--sm { padding-block: var(--s5); border-top: 1px solid var(--line); }
.quote figcaption { display: flex; align-items: center; gap: var(--s3); font-size: var(--fs-sm); color: var(--p5); }
.quote figcaption b { color: var(--p3); }
@media (max-width: 720px) { .quote-feature { grid-template-columns: minmax(0, 1fr); } }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); padding: 20px 4px; cursor: pointer; list-style: none; font-weight: 700; color: var(--p3); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; flex: none; width: 12px; height: 12px; border-right: 2px solid var(--p1); border-bottom: 2px solid var(--p1); transform: rotate(45deg) translate(-3px, -3px); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(-135deg) translate(-3px, -3px); }
.faq details p { padding: 0 4px 22px; color: var(--p5); max-width: var(--measure); }
.cta-band { background: var(--p3); color: var(--p9); border-radius: calc(var(--radius-card) + 8px); padding: clamp(40px, 6vw, 72px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s5); }
.cta-band h2 { color: var(--p9); }
.cta-band p { color: color-mix(in srgb, var(--p9) 78%, transparent); margin-top: var(--s2); }

/* ===== Home：好評、關於、理念、文章 ===== */
.mode-switch { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: var(--s6); padding: 5px 5px 5px 12px; border: 1px dashed var(--line-strong); border-radius: 10px; background: var(--p9); font-size: var(--fs-xs); color: var(--p5); }
.mode-switch button { min-height: 32px; padding: 0 12px; border: 0; border-radius: 7px; background: transparent; color: var(--p4); font-size: var(--fs-xs); font-weight: 700; cursor: pointer; }
.mode-switch button[aria-pressed="true"] { background: var(--p3); color: var(--p9); }
.review-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 10px var(--s4); font-size: var(--fs-sm); color: var(--p5); }
.section-head > .review-summary { flex-direction: row; align-items: center; max-width: none; }
.review-summary .score { display: inline-flex; align-items: center; gap: 10px; }
.review-summary .score b { font-family: var(--font-heading); font-size: var(--fs-2xl); line-height: 1; color: var(--p3); font-variant-numeric: tabular-nums; }
.source-mark { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; border: 1px solid var(--line-strong); background: var(--p9); color: var(--p3); font: 700 13px/1 var(--font-body); }
.review-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s5); }
.review-card { display: flex; flex-direction: column; gap: var(--s4); margin: 0; padding: var(--s6); border-radius: var(--radius-card); background: var(--p9); }
.review-card blockquote { margin: 0; color: var(--p4); line-height: 1.8; display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.review-card footer { display: flex; align-items: center; gap: var(--s3); margin-top: auto; font-size: var(--fs-sm); color: var(--p5); }
.review-card footer b { display: block; color: var(--p3); }
.review-card footer a { color: var(--p1); font-weight: 700; text-decoration: none; }
@media (max-width: 960px) { .review-grid { grid-template-columns: minmax(0, 1fr); } }
.about-solo { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: center; }
.about-solo blockquote { margin: 0; padding-left: var(--s5); border-left: 2px solid var(--p1); font-family: var(--font-heading); font-size: var(--fs-lg); line-height: 1.7; color: var(--p3); }
.team-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s6) var(--s5); }
.team-card { display: flex; flex-direction: column; gap: var(--s4); color: inherit; text-decoration: none; }
.team-card img { transition: transform .5s ease; }
.team-card:hover img { transform: scale(1.03); }
.team-card .role { font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.08em; color: var(--p1); }
.team-card h3 { margin-block: 2px 6px; }
@media (max-width: 720px) {
  .about-solo { grid-template-columns: minmax(0, 1fr); }
  .team-grid { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 76%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: var(--s3); }
  .team-card { scroll-snap-align: start; }
  .team-grid--page { grid-template-columns: minmax(0, 1fr); grid-auto-flow: row; overflow: visible; }
}
.belief { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.belief__statement { font-size: var(--fs-3xl); line-height: 1.4; }
.belief__list { list-style: none; counter-reset: belief; border-top: 1px solid var(--line-strong); }
.belief__list li { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: var(--s4); padding-block: var(--s5); border-bottom: 1px solid var(--line-strong); }
.belief__list li::before { counter-increment: belief; content: "0" counter(belief); font-family: var(--font-heading); font-size: var(--fs-xl); line-height: 1.25; color: var(--p1); font-variant-numeric: tabular-nums; }
.belief__list h3 { margin-bottom: 4px; }
.belief__list p { font-size: var(--fs-sm); color: var(--p5); }
@media (max-width: 720px) { .belief { grid-template-columns: minmax(0, 1fr); } }
.posts { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: var(--s6); align-items: start; }
.posts__side { display: flex; flex-direction: column; }
.post { display: flex; flex-direction: column; gap: var(--s4); color: inherit; text-decoration: none; }
.post__media { overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 3 / 2; background: var(--p7); }
.post__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.post:hover .post__media img { transform: scale(1.04); }
.post__body { display: flex; flex-direction: column; gap: var(--s2); }
.post__meta { display: flex; align-items: center; gap: var(--s3); font-size: var(--fs-xs); color: var(--p5); }
.post :is(h2, h3) { transition: color .18s; word-break: keep-all; overflow-wrap: anywhere; }
.post:hover :is(h2, h3) { color: var(--p1); }
.post--lead h3 { font-size: var(--fs-xl); }
.post p { font-size: var(--fs-sm); color: var(--p5); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.post--row { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); align-items: center; gap: var(--s4); padding-block: var(--s5); }
.post--row:first-child { padding-top: 0; }
.post--row + .post--row { border-top: 1px solid var(--line); }
.post--row .post__media { aspect-ratio: 4 / 3; }
@media (max-width: 860px) { .posts { grid-template-columns: minmax(0, 1fr); } }
/* ===== 內容頁：關於老師、師資、文章、見證、常見問題 ===== */
.profile-hero { background: var(--p8); border-bottom: 1px solid var(--line); }
.profile-hero__inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.8fr); gap: clamp(32px, 6vw, 96px); align-items: center; padding-block: clamp(48px, 7vw, 96px); }
.story { display: grid; grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr); gap: clamp(32px, 6vw, 96px); align-items: start; }
.story > :first-child { position: sticky; top: 112px; }
.timeline { list-style: none; display: grid; border-left: 1px solid var(--line-strong); }
.timeline li { position: relative; display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: var(--s4); padding: 0 0 var(--s6) var(--s5); }
.timeline li::before { content: ""; position: absolute; left: -5px; top: 9px; width: 9px; height: 9px; border-radius: 50%; background: var(--p1); }
.timeline b { font-family: var(--font-heading); color: var(--p3); font-variant-numeric: tabular-nums; }
.timeline p { color: var(--p5); }
.stat-row { display: flex; flex-wrap: wrap; gap: var(--s5) var(--s7); }
.stat-row div { display: flex; flex-direction: column; }
.stat-row b { font-family: var(--font-heading); font-size: var(--fs-2xl); line-height: 1.2; color: var(--p3); font-variant-numeric: tabular-nums; }
.stat-row span { font-size: var(--fs-sm); color: var(--p5); }
.post--feature { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: var(--s6); align-items: center; padding-bottom: var(--s7); margin-bottom: var(--s7); border-bottom: 1px solid var(--line); }
.post--feature h2 { font-size: var(--fs-2xl); transition: color .18s; }
.post--feature:hover h2 { color: var(--p1); }
.post-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s7) var(--s5); }
.post-grid .post h3, .post-grid .post h2 { font-size: var(--fs-lg); }
.post-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(40px, 6vw, 80px); }
.article-head { display: flex; flex-direction: column; gap: var(--s4); padding-block: clamp(40px, 6vw, 72px) var(--s6); }
.article-head h1 { font-size: var(--fs-3xl); line-height: 1.35; }
.article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 18px; font-size: var(--fs-sm); color: var(--p5); }
.article-meta .course-by b { color: var(--p3); }
.article-cover { max-width: 60rem; margin: 0 auto var(--s7); overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 16 / 9; }
.article-cover img { width: 100%; height: 100%; object-fit: cover; }
.article-body { display: flex; flex-direction: column; gap: var(--s5); font-size: 1.125rem; line-height: 1.9; color: var(--p4); }
.article-body h2 { font-size: var(--fs-xl); margin-top: var(--s5); scroll-margin-top: 112px; }
.article-body ul, .article-body ol { padding-left: 1.4em; display: grid; gap: 6px; }
.article-body blockquote { margin: 0; padding: var(--s5) var(--s6); border-left: 3px solid var(--p1); background: var(--p8); border-radius: 0 var(--radius-card) var(--radius-card) 0; color: var(--p3); }
.article-body figure { margin: var(--s3) 0; }
.article-body figure img { border-radius: var(--radius-card); }
.article-body figcaption { margin-top: 8px; font-size: var(--fs-xs); color: var(--p6); text-align: center; }
.article-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s4); margin-top: var(--s7); padding-block: var(--s5); border-block: 1px solid var(--line); }
.author-box { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: var(--s5); align-items: start; margin-top: var(--s7); padding: var(--s6); border-radius: var(--radius-card); background: var(--p8); }
.author-box img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.post-side { display: flex; flex-direction: column; gap: var(--s7); padding-top: clamp(40px, 6vw, 72px); }
.side-block h2 { font-size: var(--fs-base); padding-bottom: var(--s3); margin-bottom: var(--s2); border-bottom: 1px solid var(--line); }
.side-toc ol { list-style: none; counter-reset: toc; }
.side-toc a { display: flex; gap: 12px; padding: 8px 0; color: var(--p4); text-decoration: none; font-size: var(--fs-sm); }
.side-toc a::before { counter-increment: toc; content: counter(toc, decimal-leading-zero); color: var(--p6); font-variant-numeric: tabular-nums; }
.side-toc a:hover { color: var(--p1); }
.side-cats { list-style: none; }
.side-cats a { display: flex; justify-content: space-between; gap: var(--s3); padding: 9px 0; color: var(--p4); text-decoration: none; font-size: var(--fs-sm); }
.side-cats span { color: var(--p6); font-variant-numeric: tabular-nums; }
.side-cats a:hover, .side-cats a[aria-current] { color: var(--p1); }
.side-cats a[aria-current] { font-weight: 700; }
.side-posts { list-style: none; display: grid; gap: var(--s4); padding-top: var(--s2); }
.side-posts a { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: var(--s3); align-items: center; color: inherit; text-decoration: none; }
.side-posts img { width: 72px; height: 72px; border-radius: 8px; object-fit: cover; }
.side-posts span { display: flex; flex-direction: column; gap: 4px; }
.side-posts b { font-size: var(--fs-sm); line-height: 1.5; color: var(--p3); transition: color .18s; word-break: keep-all; overflow-wrap: anywhere; }
.side-posts a:hover b { color: var(--p1); }
.side-posts time { font-size: var(--fs-xs); color: var(--p6); }
.side-course { position: sticky; top: 112px; }
.side-course .card { margin-top: var(--s2); }
.side-course .card__title { font-size: var(--fs-base); }
.testimonial-wall { columns: 3 280px; column-gap: var(--s5); }
.testimonial-wall .review-card { break-inside: avoid; margin-bottom: var(--s5); background: var(--p8); }
.testimonial-wall .review-card img { border-radius: 8px; aspect-ratio: 3 / 2; object-fit: cover; }
.faq-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(32px, 5vw, 72px); align-items: start; }
.faq-nav { position: sticky; top: 112px; display: flex; flex-direction: column; gap: 2px; }
.faq-nav a { padding: 10px 14px; border-radius: 8px; color: var(--p4); text-decoration: none; font-size: var(--fs-sm); font-weight: 700; }
.faq-nav a:hover { background: var(--p8); color: var(--p1); }
.faq-group + .faq-group { margin-top: var(--s7); }
.faq-group h2 { font-size: var(--fs-xl); margin-bottom: var(--s4); scroll-margin-top: 112px; }
.faq-search { position: relative; max-width: 32rem; }
.faq-search svg { position: absolute; left: 14px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); color: var(--p6); }
.faq-search .input { padding-left: 44px; }
@media (max-width: 960px) {
  .post-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .faq-layout { grid-template-columns: minmax(0, 1fr); }
  .faq-nav { position: static; flex-direction: row; flex-wrap: wrap; }
  .post-layout { grid-template-columns: minmax(0, 1fr); }
  .post-side { padding-top: var(--s7); }
  .side-toc { display: none; }
  .side-course { position: static; }
}
@media (max-width: 720px) {
  .profile-hero__inner, .story, .post--feature, .post-grid { grid-template-columns: minmax(0, 1fr); }
  .story > :first-child { position: static; }
  .profile-hero__inner .media-frame { order: -1; }
}
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .reveal { animation: revealUp linear both; animation-timeline: view(); animation-range: entry 0% entry 35%; }
    @keyframes revealUp { from { transform: translateY(24px); } to { transform: none; } }
  }
}

/* ===== 服務內頁（WooCommerce 服務分類的商品，Kadence Element 換成預約版型） ===== */
.svc-head { display: flex; flex-direction: column; gap: var(--s3); padding-block: var(--s5) var(--s5); }
.svc-head h1 { font-size: var(--fs-3xl); }
.svc-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; font-size: var(--fs-sm); color: var(--p5); }
.svc-meta b { color: var(--p3); }
.svc-gallery { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); grid-template-rows: repeat(2, minmax(0, 1fr)); gap: var(--s3); aspect-ratio: 21 / 9; }
.svc-gallery figure { position: relative; margin: 0; overflow: hidden; border-radius: var(--radius-card); background: var(--p7); }
.svc-gallery figure:first-child { grid-row: 1 / 3; }
.svc-gallery img { width: 100%; height: 100%; object-fit: cover; }
.svc-gallery .btn { position: absolute; right: 12px; bottom: 12px; }
.svc-body { padding-block: var(--s7) var(--section-y); }
.svc-main { display: flex; flex-direction: column; gap: var(--s7); }
.svc-main > section + section { padding-top: var(--s7); border-top: 1px solid var(--line); }
.svc-main h2 { font-size: var(--fs-xl); margin-bottom: var(--s4); }
.svc-facts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); margin: 0; }
.svc-facts div { display: grid; grid-template-columns: 24px minmax(0, 1fr); gap: 4px var(--s3); }
.svc-facts svg { grid-row: 1 / 3; width: 22px; height: 22px; color: var(--p1); }
.svc-facts dt { font-size: var(--fs-xs); color: var(--p6); letter-spacing: 0.04em; }
.svc-facts dd { margin: 0; font-size: var(--fs-sm); font-weight: 700; color: var(--p3); text-wrap: pretty; }
.incl { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); }
.incl h3 { font-size: var(--fs-base); margin-bottom: var(--s3); }
.incl ul { list-style: none; display: grid; gap: 8px; font-size: var(--fs-sm); color: var(--p4); }
.incl li { position: relative; padding-left: 24px; }
.incl li::before { content: ""; position: absolute; left: 2px; top: 7px; width: 12px; height: 7px; border-left: 2px solid var(--ok); border-bottom: 2px solid var(--ok); transform: rotate(-45deg); }
.incl--no li::before { top: 11px; width: 12px; height: 0; border-left: 0; border-bottom: 2px solid var(--p6); transform: none; }
.rating-big { display: flex; align-items: baseline; gap: var(--s3); margin-bottom: var(--s5); }
.rating-big b { font-family: var(--font-heading); font-size: var(--fs-3xl); line-height: 1; color: var(--p3); }
.svc-book { align-self: start; }
.svc-book .enroll__body { gap: var(--s4); padding: var(--s5); }
.svc-book .price { font-size: var(--fs-2xl); }
.svc-book .price small { font-size: var(--fs-sm); font-weight: 400; color: var(--p5); }
.book-label { font-size: var(--fs-sm); font-weight: 700; color: var(--p3); }
.plan label { align-items: flex-start; }
.plan label > span:first-child { display: flex; align-items: flex-start; gap: 10px; }
.plan input { margin-top: 5px; }
.plan b { display: block; color: var(--p3); }
.plan small { display: block; font-size: var(--fs-xs); color: var(--p5); text-wrap: balance; }
.plan .seat { font-weight: 700; color: var(--p3); font-size: var(--fs-sm); }
.who .chip { display: inline-flex; align-items: center; gap: 8px; padding-left: 6px; }
.who .chip img { width: 26px; height: 26px; border-radius: 50%; object-fit: cover; }
.who .chip:first-child { padding-left: 16px; }
.cal { display: grid; gap: var(--s2); }
.cal__head { display: flex; align-items: center; justify-content: space-between; font-size: var(--fs-sm); font-weight: 700; color: var(--p3); }
.cal__head button { width: 32px; height: 32px; border: 0; border-radius: 50%; background: none; color: var(--p4); cursor: pointer; }
.cal__head button:hover { background: var(--p8); }
.cal__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 2px; text-align: center; font-size: var(--fs-sm); }
.cal__grid abbr { padding-block: 4px; font-size: var(--fs-xs); color: var(--p6); text-decoration: none; }
.cal__grid button { height: 34px; border: 0; border-radius: 50%; background: none; color: var(--p3); font-weight: 700; font-variant-numeric: tabular-nums; cursor: pointer; }
.cal__grid button:hover:not(:disabled) { background: var(--tint); color: var(--p1); }
.cal__grid button:disabled { color: var(--line-strong); font-weight: 400; cursor: default; }
.cal__grid button[aria-pressed="true"] { background: var(--p1); color: var(--p9); }
.slots { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s2); }
.slots button { min-height: 42px; border: 1px solid var(--line-strong); border-radius: var(--radius-input); background: var(--p9); color: var(--p3); font-weight: 700; font-variant-numeric: tabular-nums; cursor: pointer; }
.slots button:hover:not(:disabled) { border-color: var(--p1); color: var(--p1); }
.slots button:disabled { background: var(--p8); color: var(--p6); font-weight: 400; text-decoration: line-through; cursor: not-allowed; }
.slots button[aria-pressed="true"] { border-color: var(--p1); background: var(--tint); color: var(--p1); }
.book-summary { font-size: var(--fs-sm); color: var(--p4); }
.teacher-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); }
.teacher-list p { margin-top: var(--s2); font-size: var(--fs-sm); color: var(--p5); }
.book-total { display: flex; align-items: baseline; justify-content: space-between; padding-top: var(--s4); border-top: 1px solid var(--line); font-size: var(--fs-sm); color: var(--p5); }
.book-total b { font-size: var(--fs-xl); color: var(--p3); font-variant-numeric: tabular-nums; }
@media (min-width: 961px) and (min-height: 1040px) { .svc-book { position: sticky; top: 96px; } }
@media (max-width: 960px) {
  .svc-gallery { aspect-ratio: 4 / 3; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-rows: minmax(0, 2fr) minmax(0, 1fr); }
  .svc-gallery figure:first-child { grid-row: auto; grid-column: 1 / 3; }
  .svc-book { order: -1; }
}
@media (max-width: 720px) {
  .svc-facts, .incl, .teacher-list { grid-template-columns: minmax(0, 1fr); }
}

/* ===== WooCommerce 商品總覽與商品內頁（Kadence 預設商品版型，只換顏色字體） ===== */
.view-toggle { display: inline-flex; border: 1px solid var(--line-strong); border-radius: var(--radius-input); overflow: hidden; }
.view-toggle button { display: grid; place-items: center; width: 42px; height: 40px; border: 0; background: var(--p9); color: var(--p6); cursor: pointer; }
.view-toggle button + button { border-left: 1px solid var(--line-strong); }
.view-toggle button[aria-pressed="true"] { background: var(--p8); color: var(--p3); }
.view-toggle svg { width: 18px; height: 18px; }
.products { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s7) var(--s5); }
.product-card { display: flex; flex-direction: column; gap: var(--s3); }
.product-card__media { position: relative; display: block; overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 1; background: var(--p7); }
.product-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.product-card__media:hover img { transform: scale(1.04); }
.product-card__body { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.product-card__title { font-size: var(--fs-base); }
.product-card__title a { color: var(--p3); text-decoration: none; transition: color .18s; }
.product-card__title a:hover { color: var(--p1); }
.product-card .stars { font-size: var(--fs-xs); }
.product-card .price { flex-wrap: wrap; row-gap: 0; font-size: var(--fs-base); }
.product-card__excerpt { display: none; font-size: var(--fs-sm); color: var(--p5); }
.product-card__action { margin-top: var(--s1); font-size: var(--fs-sm); }
.product-card--soldout .product-card__media img { opacity: .72; }
.products--list { grid-template-columns: minmax(0, 1fr); gap: var(--s5); }
.products--list .product-card { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: var(--s5); align-items: center; padding-bottom: var(--s5); border-bottom: 1px solid var(--line); }
.products--list .product-card__title { font-size: var(--fs-lg); }
.products--list .product-card__excerpt { display: block; }
.price del { color: var(--p6); font-weight: 400; font-size: .85em; }
.price ins { text-decoration: none; }
.product-crumb { padding-top: var(--s5); }
.product-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 72px); align-items: start; padding-block: var(--s5) var(--s7); }
.gallery { display: flex; flex-direction: column; gap: var(--s3); }
.gallery__main { position: relative; overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 1; background: var(--p7); }
.gallery__main img { width: 100%; height: 100%; object-fit: cover; }
.gallery__zoom { position: absolute; right: 12px; top: 12px; display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 50%; background: var(--p9); color: var(--p3); box-shadow: var(--shadow); cursor: zoom-in; }
.gallery__zoom svg { width: 18px; height: 18px; }
.gallery__thumbs { list-style: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s3); }
.gallery__thumbs button { display: block; width: 100%; padding: 0; border: 0; border-radius: 8px; overflow: hidden; aspect-ratio: 1; background: var(--p7); opacity: .55; cursor: pointer; transition: opacity .18s; }
.gallery__thumbs button:hover, .gallery__thumbs button[aria-current="true"] { opacity: 1; }
.gallery__thumbs img { width: 100%; height: 100%; object-fit: cover; }
.summary { display: flex; flex-direction: column; gap: var(--s4); }
.summary__cat { align-self: flex-start; font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.08em; color: var(--p1); text-decoration: none; }
.summary h1 { font-size: var(--fs-3xl); line-height: 1.3; }
.summary .rating a { color: var(--p5); }
.summary .price { font-size: var(--fs-2xl); }
.summary__desc { display: flex; flex-direction: column; gap: var(--s3); color: var(--p4); }
.summary__desc ul { padding-left: 1.3em; display: grid; gap: 4px; }
.stock { font-size: var(--fs-sm); font-weight: 700; color: var(--ok); }
.cart-form { display: flex; flex-wrap: wrap; gap: var(--s3); padding-block: var(--s5); border-block: 1px solid var(--line); }
.cart-form .input { width: 88px; text-align: center; }
.cart-form .btn { flex: 1; min-width: 200px; min-height: 48px; }
.product-meta { display: flex; flex-direction: column; gap: 6px; font-size: var(--fs-sm); color: var(--p5); }
.product-meta a { color: var(--p3); }
.wc-tabs { padding-bottom: var(--s7); }
.wc-tabs .tab-panel h2 { font-size: var(--fs-xl); margin-bottom: var(--s4); }
.attr-table th { width: 28%; background: var(--p8); }
.review-list { list-style: none; display: grid; gap: var(--s5); max-width: 48rem; }
.review { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: var(--s4); padding-bottom: var(--s5); border-bottom: 1px solid var(--line); }
.review .avatar { width: 44px; height: 44px; font-size: var(--fs-base); }
.review__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; font-size: var(--fs-sm); color: var(--p5); }
.review__meta b { color: var(--p3); }
.review p { margin-top: 6px; color: var(--p4); }
.review-form { max-width: 48rem; margin-top: var(--s7); }
.star-input { display: flex; gap: 4px; }
.star-input button { padding: 0; border: 0; background: none; font-size: 1.5rem; line-height: 1; color: var(--line-strong); cursor: pointer; }
.star-input button[aria-pressed="true"] { color: #C98A1B; }
@media (max-width: 960px) {
  .products { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .product-top { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s6) var(--s4); }
  .products--list { grid-template-columns: minmax(0, 1fr); }
  .products--list .product-card { grid-template-columns: 112px minmax(0, 1fr); gap: var(--s4); }
  .products--list .product-card__excerpt { display: none; }
}

/* ===== Forms（Fluent Forms／Tutor／WooCommerce 共用外觀） ===== */
.form { display: grid; gap: var(--s5); }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); }
@media (max-width: 720px) { .form-row { grid-template-columns: minmax(0, 1fr); } }
.field { display: flex; flex-direction: column; gap: 8px; }
.field label, .field .label { font-size: var(--fs-sm); font-weight: 700; color: var(--p3); }
.field .req { color: var(--err); margin-left: 2px; }
.input, .textarea { width: 100%; min-height: 48px; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: var(--radius-input); background: var(--p9); font-size: var(--fs-base); transition: border-color .18s, box-shadow .18s; }
.textarea { min-height: 150px; resize: vertical; }
.input:focus, .textarea:focus, .select:focus { outline: none; border-color: var(--p1); box-shadow: 0 0 0 3px color-mix(in srgb, var(--p1) 18%, transparent); }
.input::placeholder, .textarea::placeholder { color: var(--p6); }
.field .help { font-size: var(--fs-xs); color: var(--p6); }
.field--error .input { border-color: var(--err); }
.field--error .help { color: var(--err); }
.check { display: flex; align-items: flex-start; gap: 10px; font-size: var(--fs-sm); color: var(--p5); }
.check input { width: 18px; height: 18px; margin-top: 4px; accent-color: var(--p1); flex: none; }

/* ===== Notices（Tutor／WooCommerce 提示訊息） ===== */
.notice { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; border-radius: 10px; font-size: var(--fs-sm); line-height: 1.6; }
.notice svg { width: 20px; height: 20px; flex: none; margin-top: 1px; }
.notice--ok { background: var(--ok-bg); color: var(--ok); }
.notice--warn { background: var(--warn-bg); color: var(--warn); }
.notice--err { background: var(--err-bg); color: var(--err); }
.notice--info { background: var(--tint); color: var(--p2); }

/* ===== Tabs / progress / table ===== */
.tabs { display: flex; gap: var(--s5); border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { position: relative; padding: 14px 2px; border: 0; background: none; color: var(--p5); font-weight: 700; font-size: var(--fs-sm); cursor: pointer; white-space: nowrap; }
.tab[aria-selected="true"] { color: var(--p3); }
.tab[aria-selected="true"]::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--p1); }
.tab-panel { padding-top: var(--s6); }
.progress { display: flex; flex-direction: column; gap: 6px; }
.progress__bar { height: 8px; border-radius: 999px; background: var(--p7); overflow: hidden; }
.progress__bar span { display: block; height: 100%; border-radius: inherit; background: var(--p1); }
.progress__label { display: flex; justify-content: space-between; font-size: var(--fs-xs); color: var(--p5); font-variant-numeric: tabular-nums; }
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius-card); }
.table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.table th, .table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
.table th { background: var(--p8); color: var(--p5); font-weight: 700; font-size: var(--fs-xs); letter-spacing: 0.04em; }
.table tr:last-child td { border-bottom: 0; }
.table td.num { text-align: right; font-variant-numeric: tabular-nums; }

/* ===== Tutor 課程內頁 ===== */
.course-head { display: flex; flex-direction: column; gap: var(--s4); }
.course-head h1 { font-size: var(--fs-3xl); }
.course-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; font-size: var(--fs-sm); color: var(--p5); }
.course-meta a { color: var(--p3); text-decoration: none; font-weight: 700; }
.course-lead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3) var(--s5); }
.course-by { display: inline-flex; align-items: center; gap: 8px; }
.course-by img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; }
.course-actions { display: flex; gap: var(--s5); }
.course-actions .btn--text { color: var(--p4); font-size: var(--fs-sm); gap: 6px; }
.course-actions svg { width: 18px; height: 18px; }
.course-cover { overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 16 / 9; background: var(--p7); position: relative; }
.course-cover img { width: 100%; height: 100%; object-fit: cover; }
.play { position: absolute; inset: 0; margin: auto; width: 72px; height: 72px; border-radius: 50%; border: 0; background: color-mix(in srgb, var(--p9) 92%, transparent); color: var(--p1); display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); }
.play svg { width: 26px; height: 26px; margin-left: 4px; }
.enroll { border: 1px solid var(--line); border-radius: calc(var(--radius-card) + 4px); background: var(--p9); box-shadow: var(--shadow); overflow: hidden; }
.enroll__body { display: flex; flex-direction: column; gap: var(--s5); padding: var(--s6); }
.enroll__meta { list-style: none; display: grid; gap: 12px; padding: var(--s5) var(--s6); border-top: 1px solid var(--line); font-size: var(--fs-sm); color: var(--p5); }
.enroll__meta li { display: flex; gap: 12px; align-items: center; }
.enroll__meta svg { width: 18px; height: 18px; color: var(--p3); flex: none; }
.enroll__list { list-style: none; display: grid; gap: 10px; font-size: var(--fs-sm); color: var(--p4); }
.enroll__list li { display: flex; gap: 10px; align-items: center; }
.enroll__list svg { width: 18px; height: 18px; color: var(--p1); flex: none; }
.enroll__note { font-size: var(--fs-xs); color: var(--p6); text-align: center; }
.session { display: grid; gap: 8px; }
.session label { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; border: 1px solid var(--line-strong); border-radius: 10px; cursor: pointer; font-size: var(--fs-sm); }
.session label:has(input:checked) { border-color: var(--p1); background: var(--tint); }
.session input { accent-color: var(--p1); }
.session .seat { font-size: var(--fs-xs); color: var(--p5); white-space: nowrap; }
.session .seat--low { color: var(--warn); }
.curriculum { display: flex; flex-direction: column; gap: var(--s3); }
.topic { border: 1px solid var(--line); border-radius: var(--radius-card); overflow: hidden; }
.topic summary { display: flex; justify-content: space-between; align-items: center; gap: var(--s3); padding: 16px 20px; background: var(--p8); cursor: pointer; list-style: none; font-weight: 700; color: var(--p3); }
.topic summary::-webkit-details-marker { display: none; }
.topic summary small { font-weight: 400; color: var(--p5); font-size: var(--fs-xs); }
.lesson { display: flex; align-items: center; gap: var(--s3); padding: 14px 20px; border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.lesson svg { width: 18px; height: 18px; color: var(--p6); flex: none; }
.lesson__title { flex: 1; color: var(--p4); }
.lesson__time { color: var(--p6); font-variant-numeric: tabular-nums; }
.lesson--done svg { color: var(--ok); }
.lesson--locked .lesson__title { color: var(--p5); }
.instructor { display: grid; grid-template-columns: 56px minmax(0, 1fr); gap: var(--s4); align-items: center; }
.instructor img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; }
.instructor span { display: block; font-size: var(--fs-xs); color: var(--p5); }
.side-more { display: flex; flex-direction: column; gap: var(--s6); margin-top: var(--s6); }
.side-more h3 { font-size: var(--fs-base); margin-bottom: var(--s3); }
.side-list { padding-left: 1.2em; display: grid; gap: 6px; font-size: var(--fs-sm); color: var(--p4); }
.prose { display: flex; flex-direction: column; gap: var(--s4); max-width: var(--measure); }
.prose h3 { margin-top: var(--s3); }
.checklist { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px var(--s5); }
.checklist li { position: relative; padding-left: 26px; font-size: var(--fs-sm); }
.checklist li::before { content: ""; position: absolute; left: 2px; top: 7px; width: 12px; height: 7px; border-left: 2px solid var(--p1); border-bottom: 2px solid var(--p1); transform: rotate(-45deg); }
@media (max-width: 720px) { .checklist { grid-template-columns: minmax(0, 1fr); } }

/* ===== Footer（Kadence 頁尾） ===== */
.site-footer { background: var(--p3); color: color-mix(in srgb, var(--p9) 72%, transparent); padding-block: var(--s8) var(--s5); font-size: var(--fs-sm); }
.site-footer .brand { color: var(--p9); }
.site-footer .brand svg { color: color-mix(in srgb, var(--p9) 85%, transparent); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: var(--s6); }
.footer-grid h3 { color: var(--p9); font-family: var(--font-body); font-size: var(--fs-sm); letter-spacing: 0.08em; margin-bottom: var(--s3); }
.footer-grid ul { list-style: none; display: grid; gap: 8px; }
.footer-grid a { color: color-mix(in srgb, var(--p9) 72%, transparent); text-decoration: none; }
.footer-grid a:hover { color: var(--p9); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s3); margin-top: var(--s7); padding-top: var(--s5); border-top: 1px solid color-mix(in srgb, var(--p9) 14%, transparent); font-size: var(--fs-xs); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .footer-grid > :first-child { grid-column: 1 / -1; } }

/* ===== 設計規格與選擇網站風格共用（design-spec.html、styles.html） ===== */
.spec-section { padding-block: var(--s8); border-bottom: 1px solid var(--line); }
.spec-section > .container > h2 { margin-bottom: var(--s2); }
.spec-section > .container > .lead { margin-bottom: var(--s6); }
.presets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); }
.preset { display: flex; flex-direction: column; gap: var(--s4); padding: var(--s5); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); }
.preset header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.preset h3 { font-size: var(--fs-xl); }
.sw9 { display: grid; grid-template-columns: repeat(9, minmax(0, 1fr)); gap: 6px; }
.sw { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.sw i { display: block; aspect-ratio: 1; border-radius: 8px; border: 1px solid rgb(0 0 0 / .08); }
.sw b { font-size: 11px; color: var(--p3); }
.sw span { font-size: 10.5px; color: var(--p5); line-height: 1.3; }
.sw code { font-family: "IBM Plex Mono", monospace; font-size: 10px; color: var(--p6); white-space: nowrap; overflow: hidden; text-overflow: clip; }
.mini { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding-top: var(--s4); border-top: 1px solid var(--line); }
@media (max-width: 960px) { .presets { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) { .sw9 { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
.fonts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s5); }
.font-spec { display: flex; flex-direction: column; gap: var(--s3); padding: var(--s5); border: 1px solid var(--line); border-radius: var(--radius-card); }
.font-spec .spec-h { font-family: var(--font-heading); font-weight: var(--heading-weight); letter-spacing: var(--heading-tracking); color: var(--p3); font-size: 2rem; line-height: 1.3; }
.font-spec .spec-h2 { font-family: var(--font-heading); font-weight: var(--heading-weight); color: var(--p3); font-size: 1.25rem; }
@media (max-width: 960px) { .fonts { grid-template-columns: minmax(0, 1fr); } }
.scale { display: grid; gap: 0; border-top: 1px solid var(--line); }
.scale div { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: var(--s4); align-items: baseline; padding: 14px 0; border-bottom: 1px solid var(--line); }
.scale span:first-child { font-size: var(--fs-xs); color: var(--p5); }
.comp-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s6); }
.comp-grid > div { display: flex; flex-direction: column; gap: var(--s4); min-width: 0; }
.comp-grid h3 { font-size: var(--fs-base); }
.where { font-size: var(--fs-xs); color: var(--p5); }
@media (max-width: 860px) { .comp-grid { grid-template-columns: minmax(0, 1fr); } }
[data-page="styles"] .preset, [data-page="styles"] .font-spec { cursor: pointer; transition: border-color .18s, box-shadow .18s; }
.preset.is-picked, .font-spec.is-picked { border-color: var(--p3); box-shadow: 0 0 0 3px color-mix(in srgb, var(--p3) 14%, transparent); }
.preset header .btn { margin-left: auto; }
.font-spec .btn { align-self: flex-start; }
.style-layout .presets, .style-layout .fonts { grid-template-columns: minmax(0, 1fr); }
.spec-where { display: flex; flex-wrap: wrap; gap: 8px; }

/* ===== 審閱工具（只在 mockup 出現，不進 WordPress） ===== */
.review-fab { position: fixed; left: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 60; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px; border: 0; border-radius: 999px; background: #17181B; color: #fff; font: 700 13px/1 "Noto Sans TC", sans-serif; box-shadow: 0 8px 24px rgb(0 0 0 / .25); cursor: pointer; }
.review-fab i { width: 14px; height: 14px; border-radius: 50%; background: var(--p1); box-shadow: 0 0 0 2px #fff; }
.review-panel { position: fixed; left: 16px; bottom: calc(72px + env(safe-area-inset-bottom, 0px)); z-index: 60; width: min(340px, calc(100vw - 32px)); padding: 18px; border-radius: 16px; background: #17181B; color: #E9EAEC; font: 400 13px/1.5 "Noto Sans TC", sans-serif; box-shadow: 0 16px 40px rgb(0 0 0 / .35); display: none; }
.review-panel[data-open] { display: grid; gap: 14px; }
.review-panel h2 { color: #fff; font: 700 14px/1.4 "Noto Sans TC", sans-serif; letter-spacing: .02em; }
.review-panel .rp-label { color: #A6A9B0; font-size: 12px; margin-bottom: 6px; }
.rp-swatches { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.rp-swatches button { aspect-ratio: 1; border-radius: 10px; border: 2px solid transparent; cursor: pointer; }
.rp-swatches button[aria-pressed="true"] { border-color: #fff; box-shadow: 0 0 0 2px #17181B inset; }
.rp-options { display: flex; flex-wrap: wrap; gap: 6px; }
.rp-options button { min-height: 34px; padding: 0 12px; border-radius: 8px; border: 1px solid #3A3D44; background: #222429; color: #E9EAEC; font-size: 12px; cursor: pointer; }
.rp-options button[aria-pressed="true"] { background: #fff; color: #17181B; border-color: #fff; }
.rp-note { color: #8C9098; font-size: 11.5px; }
.review-only { outline: 2px dashed #E0A100; outline-offset: 4px; }
.review-tag { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 6px; background: #17181B; color: #fff; font: 700 12px/1.5 "Noto Sans TC", sans-serif; }
.state-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 10px var(--gutter); background: #17181B; color: #fff; font: 400 13px/1.4 "Noto Sans TC", sans-serif; }
.state-bar .rp-options button { min-height: 30px; }

/* ===== 展示站（showcase.html、styles.html、各頁角落按鈕；不進 WordPress） ===== */
.showcase-bar { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); z-index: 60; display: flex; align-items: center; gap: 4px; padding: 4px; border-radius: 999px; background: #17181B; box-shadow: 0 8px 24px rgb(0 0 0 / .25); font: 700 13px/1 "Noto Sans TC", sans-serif; }
.showcase-bar a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; border-radius: 999px; color: #fff; text-decoration: none; }
.showcase-bar a:hover { background: rgb(255 255 255 / .12); color: #fff; }
.showcase-bar .showcase-bar__cta { background: var(--p1); }
.showcase-bar .showcase-bar__cta:hover { background: var(--p2); }
@media (max-width: 480px) { .showcase-bar a:not(.showcase-bar__cta) { display: none; } }
.tier-ribbon { background: var(--tint); color: var(--p2); font-size: var(--fs-sm); }
.tier-ribbon .container { display: flex; flex-wrap: wrap; gap: 4px 12px; padding-block: 10px; }
.tier-ribbon b { color: var(--p1); }
.tier-ribbon--system { background: var(--p8); color: var(--p5); border-bottom: 1px solid var(--line); }
.tier-ribbon--system b { color: var(--p3); }
.sc-top { border-bottom: 1px solid var(--line); background: var(--p9); }
.sc-top .container { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); min-height: 64px; }
.sc-top b { font-size: var(--fs-sm); letter-spacing: 0.04em; color: var(--p3); }
.sc-hero { position: relative; display: grid; align-items: end; min-height: min(72svh, 680px); color: var(--p9); isolation: isolate; overflow: hidden; }
.sc-hero img { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; }
.sc-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, color-mix(in srgb, var(--p3) 80%, transparent), color-mix(in srgb, var(--p3) 35%, transparent) 60%, transparent), linear-gradient(0deg, color-mix(in srgb, var(--p3) 40%, transparent), transparent 50%); }
.sc-hero .container { display: flex; flex-direction: column; gap: var(--s5); padding-block: clamp(72px, 10vw, 120px) clamp(48px, 7vw, 88px); }
.sc-hero .container > * { max-width: 38rem; }
.sc-hero h1 { color: var(--p9); font-size: var(--fs-hero); line-height: 1.2; }
.sc-hero p { color: color-mix(in srgb, var(--p9) 88%, transparent); font-size: var(--fs-lg); }
.sc-hero .eyebrow { color: color-mix(in srgb, var(--p9) 85%, transparent); }
.sc-style { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--s5) var(--s7); align-items: center; }
.sc-swatches { display: flex; flex-wrap: wrap; gap: 10px; }
.sc-swatches span { width: 40px; height: 40px; border-radius: 50%; background: var(--p1); box-shadow: inset 0 0 0 3px rgb(255 255 255 / .35); }
.sc-pages { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 var(--s7); counter-reset: sc; }
.sc-pages a { display: grid; grid-template-columns: 30px 88px minmax(0, 1fr) auto; gap: var(--s4); align-items: center; padding-block: var(--s4); border-bottom: 1px solid var(--line); color: inherit; text-decoration: none; }
.sc-pages a::before { counter-increment: sc; content: counter(sc, decimal-leading-zero); font-size: var(--fs-xs); color: var(--p6); font-variant-numeric: tabular-nums; }
.sc-pages img { width: 88px; height: 64px; border-radius: 8px; object-fit: cover; }
.sc-pages b { display: block; color: var(--p3); transition: color .18s; }
.sc-subhead { display: flex; flex-direction: column; gap: var(--s2); margin-top: var(--s8); margin-bottom: var(--s3); }
.sc-pages small { display: block; margin-top: 2px; font-size: var(--fs-sm); color: var(--p5); text-wrap: pretty; }
.sc-pages a:hover b { color: var(--p1); }
.sc-pages .arrow { color: var(--p1); }
.sc-pages--addon a::before { content: "＋"; color: var(--p1); }
.sc-note { padding-block: var(--s6); font-size: var(--fs-xs); color: var(--p6); text-align: center; }
.sc-layouts { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s5); }
.sc-layout { display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); box-shadow: var(--shadow-sm); transition: box-shadow .25s ease, border-color .25s ease; }
.sc-layout[data-selected] { border-color: var(--p1); box-shadow: 0 0 0 2px var(--p1), var(--shadow); }
.sc-layout img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.sc-layout__body { display: flex; flex: 1; flex-direction: column; gap: var(--s2); padding: var(--s5); }
.sc-layout__body small { font-size: var(--fs-xs); letter-spacing: 0.06em; color: var(--p5); }
.sc-layout__body h3 { display: flex; align-items: center; gap: 10px; font-size: var(--fs-lg); }
.sc-layout__body p { font-size: var(--fs-sm); color: var(--p5); text-wrap: pretty; }
.sc-layout__dot { width: 14px; height: 14px; flex: none; border-radius: 50%; background: var(--p1); }
.sc-layout__brand { font-size: var(--fs-xs); color: var(--p6); }
.sc-layout__actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); margin-top: auto; padding-top: var(--s4); border-top: 1px solid var(--line); }
@media (max-width: 960px) { .sc-layouts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .sc-layouts { grid-template-columns: minmax(0, 1fr); } }
.style-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 400px); gap: clamp(32px, 5vw, 64px); align-items: start; }
.style-preview { display: flex; flex-direction: column; gap: var(--s4); padding: var(--s5); border-radius: calc(var(--radius-card) + 4px); background: var(--p8); }
.preview-card { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: var(--s3); align-items: center; padding: var(--s3); border-radius: var(--radius-card); background: var(--p9); }
.preview-card img { width: 96px; height: 72px; border-radius: 8px; object-fit: cover; }
.preview-card div { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; }
.preview-card b { font-family: var(--font-heading); color: var(--p3); line-height: 1.4; }
@media (min-width: 961px) and (min-height: 640px) { .style-preview { position: sticky; top: 96px; } }
.style-current { font-size: var(--fs-sm); color: var(--p5); }
.style-current b { color: var(--p3); }
@media (max-width: 960px) { .style-layout { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 720px) {
  .sc-style { grid-template-columns: minmax(0, 1fr); }
  .sc-pages { grid-template-columns: minmax(0, 1fr); }
  .sc-pages a { grid-template-columns: 24px 72px minmax(0, 1fr); }
  .sc-pages img { width: 72px; height: 56px; }
  .sc-pages .arrow { display: none; }
}

/* ================= Tutor 上課頁與學習中心（只換顏色字體，版面照 Tutor 4.1） ================= */
/* ===== Tutor 上課頁、學習中心（WIP：之後併入 components.css）=====
   結構照 Tutor 4.1 Modern 模式的 learning area 與學生儀表板，只換成網站的顏色、字型、按鈕。
   Tutor 色票對照：surface-base → --p8、surface-l1 → --p9、border → --line、brand → --p1。 */

/* ---- 共用小元件 ---- */
.tutor-ghost { background: transparent; color: var(--p4); border-color: transparent; }
.tutor-ghost:hover { background: var(--p7); color: var(--p3); }
.tutor-ghost svg, .tutor-icon-label svg { width: 18px; height: 18px; flex: none; }
.tutor-icon-label { gap: 6px; }
.tutor-card { background: var(--p9); border: 1px solid var(--line); border-radius: var(--radius-card); }
.tutor-label { font-size: var(--fs-xs); color: var(--p6); letter-spacing: 0.04em; }
.tutor-file { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: var(--s3); align-items: center; padding: var(--s3); }
.tutor-file__icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 8px; background: var(--tint); color: var(--p1); }
.tutor-file__icon svg { width: 20px; height: 20px; }
.tutor-file b { display: block; font-size: var(--fs-sm); color: var(--p3); overflow-wrap: anywhere; }
.tutor-file span { font-size: var(--fs-xs); color: var(--p6); font-variant-numeric: tabular-nums; }
.tutor-files { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
@media (max-width: 576px) { .tutor-files { grid-template-columns: minmax(0, 1fr); } }

/* ===== 上課頁（Tutor learning area） ===== */
.tutor-la { background: var(--p8); min-height: 100svh; }
.tutor-la-header { position: sticky; top: 0; z-index: 30; padding: var(--s2); background: var(--p8); }
.tutor-la-header__inner { display: flex; align-items: center; gap: var(--s3); min-height: 48px; padding: 0 var(--s2) 0 4px; border: 1px solid var(--line); border-radius: 8px; background: var(--p9); }
.tutor-la-header .icon-btn { width: 40px; height: 40px; flex: none; }
.tutor-la-title { flex: 1; min-width: 0; overflow: hidden; font-size: var(--fs-lg); white-space: nowrap; text-overflow: ellipsis; }
.tutor-la-title__content { display: none; }
.tutor-la-toggle { display: none !important; }
.tutor-la-body { display: grid; grid-template-columns: 320px minmax(0, 1fr); align-items: start; }

/* 側欄：課程進度 + 章節單元 + 更多 */
.tutor-la-sidebar { position: sticky; top: 64px; display: flex; flex-direction: column; gap: var(--s3); height: calc(100svh - 64px); padding: 0 var(--s2) var(--s2); }
.tutor-la-sidebar__head { display: none; align-items: center; gap: var(--s3); padding: var(--s2) var(--s2) 0 var(--s4); }
.tutor-la-sidebar__head p { flex: 1; min-width: 0; font-weight: 700; color: var(--p3); overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.tutor-la-curriculum { display: flex; flex-direction: column; flex: 1; min-height: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: var(--p9); }
.tutor-la-progress { display: grid; gap: var(--s2); padding: var(--s4) var(--s5); border-bottom: 1px solid var(--line); }
.tutor-la-progress p { font-size: var(--fs-sm); color: var(--p5); }
.tutor-la-progress b { color: var(--p3); font-variant-numeric: tabular-nums; }
.tutor-la-nav { display: flex; flex-direction: column; gap: 2px; padding: var(--s2); overflow-y: auto; }
.tutor-la-topic__head { display: flex; align-items: center; gap: var(--s2); width: 100%; padding: 8px 6px 8px 12px; border: 0; border-radius: 6px; background: none; color: var(--p3); font-size: var(--fs-sm); font-weight: 700; text-align: left; cursor: pointer; }
.tutor-la-topic__head:hover { background: var(--p8); }
.tutor-la-topic__head span:nth-child(2) { flex: 1; min-width: 0; }
.tutor-la-topic__head > svg { width: 20px; height: 20px; color: var(--p6); flex: none; transition: transform .2s; }
.tutor-la-topic__head[aria-expanded="true"] > svg { transform: rotate(180deg); }
.tutor-la-topic__body { display: flex; flex-direction: column; gap: 2px; padding-bottom: var(--s2); }
.tutor-la-ring { position: relative; flex: none; width: 18px; height: 18px; border-radius: 50%; background: conic-gradient(var(--p1) var(--pct, 0%), var(--p7) 0); }
.tutor-la-ring::after { content: ""; position: absolute; inset: 3px; border-radius: 50%; background: var(--p9); }
.tutor-la-item { position: relative; display: flex; align-items: flex-start; gap: var(--s2); min-height: 40px; padding: 8px 12px; border-radius: 6px; color: var(--p5); font-size: var(--fs-sm); font-weight: 500; line-height: 1.5; text-decoration: none; }
.tutor-la-item:hover { background: var(--p8); color: var(--p3); }
.tutor-la-item [data-icon] { display: flex; flex: none; margin-top: 1px; color: var(--p6); }
.tutor-la-item [data-icon] svg { width: 20px; height: 20px; }
.tutor-la-item small { display: block; font-size: var(--fs-xs); font-weight: 400; color: var(--p6); }
.tutor-la-item.is-done [data-icon] { color: var(--ok); }
.tutor-la-item[aria-current="page"] { background: var(--tint); color: var(--p3); }
.tutor-la-item[aria-current="page"]::before { content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px; border-radius: 2px; background: var(--p1); }
.tutor-la-item[aria-current="page"] [data-icon] { color: var(--p1); }
.tutor-la-pages { position: relative; }
.tutor-la-pages .btn { justify-content: flex-start; width: 100%; }
.tutor-la-pages__menu { position: absolute; left: 0; right: 0; bottom: calc(100% + 6px); z-index: 5; display: grid; gap: 2px; padding: 6px; border: 1px solid var(--line); border-radius: 10px; background: var(--p9); box-shadow: var(--shadow); }
.tutor-la-pages__menu a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px; color: var(--p4); font-size: var(--fs-sm); text-decoration: none; }
.tutor-la-pages__menu a:hover { background: var(--p8); color: var(--p1); }
.tutor-la-pages__menu svg { width: 18px; height: 18px; color: var(--p6); }
.tutor-la-sidebar__foot { display: flex; align-items: center; gap: var(--s2); }
.tutor-la-expand { border: 1px solid var(--line-strong) !important; border-radius: 8px !important; width: 38px !important; height: 38px !important; }
.tutor-la-sidebar__foot .tutor-la-complete-m { display: none; flex: 1; }
.tutor-la.is-fullscreen .tutor-la-body { grid-template-columns: 54px minmax(0, 1fr); }
.tutor-la.is-fullscreen .tutor-la-sidebar > :not(.tutor-la-sidebar__foot) { display: none; }
.tutor-la.is-fullscreen .tutor-la-sidebar { justify-content: flex-end; }

/* 主內容 */
.tutor-la-content { min-width: 0; padding: 0 var(--s2) 96px var(--s4); }
/* mockup 審閱按鈕：桌機移到側欄右邊，免得蓋住側欄底部的「更多」與全螢幕按鈕 */
@media (min-width: 993px) {
  [data-page="lesson"]:not([data-lesson-state="quiz"]) .tutor-la ~ :is(.review-fab, .review-panel) { left: 336px; }
  [data-page="lesson"]:not([data-lesson-state="quiz"]) .tutor-la.is-fullscreen ~ :is(.review-fab, .review-panel) { left: 70px; }
}
.tutor-la-container { max-width: 760px; margin-inline: auto; }
@media (min-width: 1400px) { .tutor-la-container { max-width: 860px; } }
.tutor-la-video { position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: var(--radius-card); background: var(--p3); }
.tutor-la-video img { width: 100%; height: 100%; object-fit: cover; }
.tutor-la-video__bar { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; gap: var(--s3); padding: var(--s5) var(--s4) var(--s3); background: linear-gradient(0deg, color-mix(in srgb, var(--p3) 70%, transparent), transparent); color: var(--p9); font-size: var(--fs-xs); font-variant-numeric: tabular-nums; }
.tutor-la-video__bar i { flex: 1; height: 4px; border-radius: 2px; background: color-mix(in srgb, var(--p9) 35%, transparent); }
.tutor-la-tabs { display: flex; gap: 4px; margin-block: var(--s4) var(--s3); padding: 4px; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); }
.tutor-la-tabs button { display: inline-flex; flex: 1; align-items: center; justify-content: center; gap: 8px; min-height: 40px; padding: 0 var(--s3); border: 0; border-radius: 8px; background: none; color: var(--p5); font-size: var(--fs-sm); font-weight: 700; cursor: pointer; white-space: nowrap; }
.tutor-la-tabs button:hover { color: var(--p3); }
.tutor-la-tabs button[aria-selected="true"] { background: var(--tint); color: var(--p1); }
.tutor-la-tabs svg { width: 18px; height: 18px; }
.tutor-la-panel { display: flex; flex-direction: column; gap: var(--s4); padding: var(--s6); }
.tutor-la-panel h2 { font-size: var(--fs-xl); }
.tutor-la-panel h3 { font-size: var(--fs-base); }
.tutor-la-panel ul { padding-left: 1.3em; display: grid; gap: 4px; }
.tutor-la-footer { display: flex; align-items: center; justify-content: flex-end; gap: var(--s2); margin-top: var(--s4); }
.tutor-la-footer .btn { flex: none; }
.tutor-la-mark svg { color: var(--p1); }
.tutor-comment-form { display: grid; gap: var(--s3); }
.tutor-comment-form__foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); }
.tutor-comment { display: grid; grid-template-columns: 36px minmax(0, 1fr); gap: var(--s3); padding-top: var(--s4); border-top: 1px solid var(--line); }
.tutor-comment .avatar { width: 36px; height: 36px; }
.tutor-comment__meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: var(--fs-sm); color: var(--p6); }
.tutor-comment__meta b { color: var(--p3); }
.tutor-comment p { margin-top: 4px; font-size: var(--fs-sm); color: var(--p4); }

/* 作業（Tutor Pro assignments） */
.tutor-assign { display: flex; flex-direction: column; gap: var(--s5); }
.tutor-assign__title { display: flex; flex-direction: column; align-items: flex-start; gap: var(--s2); }
.tutor-assign__title h2 { font-size: var(--fs-2xl); }
.tutor-assign-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin: 0; overflow: hidden; }
.tutor-assign-summary div { display: flex; flex-direction: column-reverse; gap: 2px; padding: var(--s4); }
.tutor-assign-summary div + div { border-left: 1px solid var(--line); }
.tutor-assign-summary dt { font-size: var(--fs-xs); color: var(--p5); }
.tutor-assign-summary dd { margin: 0; font-weight: 700; color: var(--p3); font-variant-numeric: tabular-nums; }
.tutor-assign-summary dd small { display: block; font-size: var(--fs-xs); font-weight: 400; color: var(--p6); }
.tutor-assign-block { display: flex; flex-direction: column; gap: var(--s2); }
.tutor-assign-block p { color: var(--p4); }
.tutor-assign-form { display: flex; flex-direction: column; gap: var(--s5); padding: var(--s6); }
.tutor-assign-form header { display: flex; flex-direction: column; gap: 2px; }
.tutor-assign-form header p { font-size: var(--fs-sm); color: var(--p1); font-weight: 700; }
.tutor-assign-form header h2 { font-size: var(--fs-2xl); }
.tutor-editor { overflow: hidden; border: 1px solid var(--line-strong); border-radius: var(--radius-input); background: var(--p9); }
.tutor-editor:focus-within { border-color: var(--p1); box-shadow: 0 0 0 3px color-mix(in srgb, var(--p1) 18%, transparent); }
.tutor-editor__bar { display: flex; flex-wrap: wrap; gap: 2px; padding: 6px; border-bottom: 1px solid var(--line); background: var(--p8); }
.tutor-editor__bar button { display: grid; place-items: center; width: 32px; height: 32px; border: 0; border-radius: 6px; background: none; color: var(--p4); font-size: var(--fs-sm); cursor: pointer; }
.tutor-editor__bar button:hover { background: var(--p7); }
.tutor-editor__bar svg { width: 16px; height: 16px; }
.tutor-editor .textarea { min-height: 140px; border: 0; border-radius: 0; }
.tutor-editor .textarea:focus { box-shadow: none; }
.tutor-drop { display: flex; flex-direction: column; align-items: center; gap: var(--s2); padding: var(--s6) var(--s5); border: 1.5px dashed var(--line-strong); border-radius: var(--radius-card); background: var(--p8); text-align: center; }
.tutor-drop > svg { width: 32px; height: 32px; color: var(--p6); }
.tutor-drop b { color: var(--p3); font-size: var(--fs-sm); }
.tutor-drop span { font-size: var(--fs-xs); color: var(--p6); text-wrap: balance; }
.tutor-drop .btn { margin-top: var(--s2); }

/* 測驗作答中（Tutor 收起上方列與側欄，整頁作答） */
.tutor-quiz-head { position: sticky; top: 0; z-index: 30; border-bottom: 1px solid var(--line); background: var(--p9); }
.tutor-quiz-head__inner, .tutor-quiz-body, .tutor-quiz-foot__inner { max-width: 760px; margin-inline: auto; }
@media (min-width: 1400px) { .tutor-quiz-head__inner, .tutor-quiz-body, .tutor-quiz-foot__inner { max-width: 860px; } }
.tutor-quiz-head__inner { display: flex; align-items: center; gap: var(--s3); padding: var(--s3) var(--s4); }
.tutor-quiz-head__meta { display: flex; flex: 1; align-items: center; gap: var(--s3); min-width: 0; }
.tutor-quiz-head h1 { min-width: 0; overflow: hidden; font-size: var(--fs-lg); white-space: nowrap; text-overflow: ellipsis; }
.tutor-quiz-timer { display: inline-flex; align-items: center; gap: 6px; flex: none; padding: 4px 10px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--p8); color: var(--p3); font-weight: 700; font-variant-numeric: tabular-nums; }
.tutor-quiz-timer svg { width: 16px; height: 16px; color: var(--p1); }
.tutor-quiz-head .progress__bar { height: 4px; border-radius: 0; }
.tutor-quiz-body { display: flex; flex-direction: column; gap: var(--s5); padding: var(--s7) var(--s4); }
.tutor-quiz-no { font-size: var(--fs-sm); color: var(--p5); }
.tutor-quiz-no strong { color: var(--p3); font-variant-numeric: tabular-nums; }
.tutor-quiz-q { margin: 0; padding: 0; border: 0; min-width: 0; }
.tutor-quiz-q__head { display: flex; align-items: flex-start; gap: var(--s3); margin-bottom: var(--s5); }
.tutor-quiz-q__num { display: grid; place-items: center; flex: none; width: 28px; height: 28px; margin-top: 2px; border: 1px solid var(--line); border-radius: 6px; background: var(--p8); color: var(--p3); font-weight: 700; font-variant-numeric: tabular-nums; }
.tutor-quiz-q__head h2 { flex: 1; font-size: var(--fs-xl); }
.tutor-quiz-q__head .badge { margin-top: 4px; }
.tutor-quiz-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4); }
.tutor-quiz-options label { display: flex; align-items: flex-start; gap: var(--s3); padding: var(--s4); border: 1px solid var(--line-strong); border-radius: 10px; background: var(--p9); color: var(--p3); cursor: pointer; transition: border-color .18s, background-color .18s; }
.tutor-quiz-options label:hover { border-color: var(--p6); background: var(--p8); }
.tutor-quiz-options label:has(input:checked) { border-color: var(--p1); background: var(--tint); }
.tutor-quiz-options input { width: 18px; height: 18px; margin-top: 5px; flex: none; accent-color: var(--p1); }
.tutor-quiz-foot { position: sticky; bottom: 0; z-index: 30; border-top: 1px solid var(--line); background: var(--p9); }
.tutor-quiz-foot__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s4); }
.tutor-quiz-foot__inner > div { display: flex; gap: var(--s2); }
[data-lesson-state="quiz"] .tutor-la-header, [data-lesson-state="quiz"] .tutor-la-sidebar { display: none; }
[data-lesson-state="quiz"] .tutor-la-body { display: block; }
[data-lesson-state="quiz"] .tutor-la-content { padding: 0; }
[data-lesson-state="quiz"] .tutor-la-container { max-width: none; }
[data-view="quiz"] { display: flex; flex-direction: column; min-height: 100svh; }
.tutor-quiz-body { flex: 1; width: 100%; }
/* 底部固定列出現時，把 mockup 的審閱按鈕往上移，免得擋住 Tutor 的按鈕 */
[data-lesson-state="quiz"] :is(.review-fab, .showcase-bar) { bottom: calc(88px + env(safe-area-inset-bottom, 0px)); }
[data-lesson-state="quiz"] .review-panel { bottom: calc(144px + env(safe-area-inset-bottom, 0px)); }

@media (max-width: 992px) {
  .tutor-la-body { grid-template-columns: minmax(0, 1fr); }
  .tutor-la-toggle { display: inline-grid !important; }
  .tutor-la-sidebar { position: fixed; inset: 0; z-index: 70; width: 100%; height: 100svh; padding: var(--s2); background: var(--p8); overflow-y: auto; transform: translateX(100%); visibility: hidden; transition: transform .3s ease, visibility .3s; }
  .tutor-la-sidebar.is-open { transform: none; visibility: visible; }
  .tutor-la-sidebar__head { display: flex; }
  .tutor-la-curriculum { flex: none; overflow: visible; }
  .tutor-la-nav { overflow: visible; }
  .tutor-la-content { padding: 0 var(--s2) 96px; }
  .tutor-la.is-fullscreen .tutor-la-body { grid-template-columns: minmax(0, 1fr); }
  .tutor-la-expand { display: none !important; }
}
@media (max-width: 768px) {
  .tutor-la-complete { display: none !important; }
  .tutor-la-sidebar__foot .tutor-la-complete-m { display: inline-flex; }
  .tutor-la-title { font-size: var(--fs-base); }
  .tutor-la-title__course { display: none; }
  .tutor-la-title__content { display: inline; }
  .tutor-assign-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tutor-assign-summary div:nth-child(3) { border-left: 0; }
  .tutor-assign-summary div:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (max-width: 576px) {
  .tutor-la-content { padding-bottom: 0; }
  .tutor-la-video { margin-inline: calc(var(--s2) * -1); border-radius: 0; }
  .tutor-la-tabs button { flex-direction: column; gap: 2px; min-height: 52px; font-size: var(--fs-xs); }
  .tutor-la-panel, .tutor-assign-form { padding: var(--s5) var(--s4); }
  /* 手機版 Tutor 把上一個／下一個固定在畫面底部：單元內容不夠長時，也讓底部列貼齊畫面下緣 */
  .tutor-la-container > [data-view]:not([data-view="quiz"]) { display: flex; flex-direction: column; min-height: calc(100svh - 64px); }
  .tutor-la-container > [data-view="video"] .tutor-la-panel { margin-bottom: var(--s5); }
  .tutor-la-footer { position: sticky; bottom: 0; z-index: 20; justify-content: space-between; gap: 6px; margin: auto calc(var(--s2) * -1) 0 !important; padding: var(--s3) var(--s4); border-top: 1px solid var(--line); background: var(--p9); }
  .tutor-la-footer .btn--sm { padding: 0 10px; }
  [data-lesson-state]:not([data-lesson-state="quiz"]) :is(.review-fab, .showcase-bar) { bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
  [data-lesson-state]:not([data-lesson-state="quiz"]) .review-panel { bottom: calc(136px + env(safe-area-inset-bottom, 0px)); }
  .tutor-quiz-options { grid-template-columns: minmax(0, 1fr); }
  .tutor-quiz-body { padding-block: var(--s6); }
  .tutor-quiz-q__head { flex-wrap: wrap; }
  .tutor-quiz-q__head h2 { flex-basis: calc(100% - 40px); }
  .tutor-quiz-q__head .badge { margin-left: 40px; margin-top: -8px; }
  .tutor-quiz-foot__inner .btn { padding: 0 14px; }
}

/* ===== 學習中心（Tutor 學生儀表板） ===== */
.tutor-db { background: var(--p8); }
.tutor-db-layout { display: grid; grid-template-columns: 274px minmax(0, 1fr); min-height: calc(100svh - 72px); }
.tutor-db-sidebar { position: sticky; top: 72px; align-self: start; display: flex; flex-direction: column; min-height: calc(100svh - 72px); padding: var(--s5) var(--s4); border-right: 1px solid var(--line); background: var(--p9); }
.tutor-db-nav ul { list-style: none; display: flex; flex-direction: column; gap: 4px; }
.tutor-db-nav a { display: flex; align-items: center; gap: var(--s3); padding: 10px 12px; border-radius: 8px; color: var(--p4); font-size: var(--fs-sm); font-weight: 500; text-decoration: none; }
.tutor-db-nav a:hover { background: var(--p8); color: var(--p3); }
.tutor-db-nav a[aria-current="page"] { background: var(--tint); color: var(--p1); font-weight: 700; }
.tutor-db-nav svg { width: 20px; height: 20px; flex: none; }
.tutor-db-explore { display: flex; align-items: center; gap: 6px; margin-top: auto; padding: 8px 12px; border-radius: 8px; color: var(--p4); font-size: var(--fs-sm); text-decoration: none; }
.tutor-db-explore:hover { background: var(--p8); color: var(--p1); }
.tutor-db-explore svg { width: 18px; height: 18px; }
.tutor-db-main { min-width: 0; }
.tutor-db-header { position: sticky; top: 72px; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: var(--s4); min-height: 80px; padding: var(--s4) var(--s5); border-bottom: 1px solid var(--line); background: var(--p8); }
.tutor-db-hi { font-family: var(--font-body); font-size: var(--fs-xl); font-weight: 500; }
.tutor-db-hi span { color: var(--p6); }
.tutor-db-user { position: relative; }
.tutor-db-user__btn { display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid var(--line); border-radius: 50%; background: var(--p9); cursor: pointer; }
.tutor-db-user__btn .avatar { width: 34px; height: 34px; }
.tutor-db-user__btn[aria-expanded="true"] { border-color: var(--p1); }
.tutor-db-user__menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; width: 260px; padding: var(--s2); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); box-shadow: var(--shadow); }
.tutor-db-user__profile { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: var(--s4) var(--s3); text-align: center; border-bottom: 1px solid var(--line); margin-bottom: var(--s2); }
.tutor-db-user__profile .avatar { width: 48px; height: 48px; font-size: var(--fs-lg); margin-bottom: 4px; }
.tutor-db-user__profile b { color: var(--p3); }
.tutor-db-user__profile span { font-size: var(--fs-xs); color: var(--p6); }
.tutor-db-user__menu ul { list-style: none; display: grid; gap: 2px; }
.tutor-db-user__menu a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px; color: var(--p4); font-size: var(--fs-sm); text-decoration: none; }
.tutor-db-user__menu a:hover { background: var(--p8); color: var(--p1); }
.tutor-db-user__menu svg { width: 18px; height: 18px; color: var(--p6); }
.tutor-db-page { max-width: 760px; margin-inline: auto; padding: var(--s5) var(--s4) var(--s8); }
@media (min-width: 1400px) { .tutor-db-page { max-width: 860px; } }
.tutor-db-page > section { display: flex; flex-direction: column; gap: var(--s6); }
.tutor-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s4); }
.tutor-stat { display: flex; flex-direction: column; justify-content: space-between; gap: var(--s4); min-height: 140px; padding: var(--s4); color: inherit; text-decoration: none; transition: background-color .2s, border-color .2s; }
a.tutor-stat:hover { border-color: var(--line-strong); background: var(--p8); }
.tutor-stat__head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s2); }
.tutor-stat h3 { font-family: var(--font-body); font-size: var(--fs-sm); font-weight: 400; color: var(--p4); }
.tutor-stat svg { width: 20px; height: 20px; color: var(--p1); flex: none; }
.tutor-stat b { font-family: var(--font-heading); font-size: 2rem; line-height: 1.25; color: var(--p3); font-variant-numeric: tabular-nums; }
.tutor-db-sechead { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); margin-bottom: var(--s3); }
.tutor-db-sechead h2 { font-family: var(--font-body); font-size: var(--fs-base); }
.tutor-pcards { display: flex; flex-direction: column; gap: var(--s4); }
.tutor-pcard { position: relative; display: flex; gap: var(--s3); padding: var(--s2); color: inherit; text-decoration: none; transition: border-color .2s, box-shadow .2s; }
.tutor-pcard:hover { border-color: var(--line-strong); box-shadow: var(--shadow-sm); }
.tutor-pcard__thumb { flex: 0 0 200px; overflow: hidden; aspect-ratio: 16 / 9; border-radius: 8px; background: var(--p7); }
.tutor-pcard__thumb img { width: 100%; height: 100%; object-fit: cover; }
.tutor-pcard__body { display: flex; flex: 1; flex-direction: column; justify-content: space-between; gap: var(--s3); min-width: 0; padding: 4px var(--s2) 4px 0; }
.tutor-pcard__cat { font-size: var(--fs-xs); color: var(--p5); }
.tutor-pcard__title { font-family: var(--font-body); font-size: var(--fs-base); color: var(--p3); transition: color .18s; }
.tutor-pcard__title a { color: inherit; text-decoration: none; }
.tutor-pcard__title a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.tutor-pcard:hover .tutor-pcard__title { color: var(--p1); }
.tutor-pcard__detail { display: flex; flex-wrap: wrap; gap: 4px 8px; margin-bottom: 6px; font-size: var(--fs-xs); color: var(--p5); font-variant-numeric: tabular-nums; }
.tutor-pcard__head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--s3); }
.tutor-pcard__actions { position: relative; z-index: 1; display: flex; flex: none; gap: 6px; }
.tutor-pcard__actions .btn { min-height: 34px; padding: 0 12px; font-size: var(--fs-xs); }
.tutor-db-card { overflow: hidden; }
.tutor-db-card__tabs { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; padding: var(--s4); border-bottom: 1px solid var(--line); }
.tutor-db-card__tabs button { display: inline-flex; align-items: center; gap: 6px; flex: none; min-height: 36px; padding: 0 12px; border: 0; border-radius: 8px; background: none; color: var(--p5); font-size: var(--fs-sm); font-weight: 700; cursor: pointer; white-space: nowrap; }
.tutor-db-card__tabs button:hover { background: var(--p8); color: var(--p3); }
.tutor-db-card__tabs button[aria-selected="true"] { background: var(--tint); color: var(--p1); }
.tutor-db-card__tabs .count { min-width: 22px; padding: 0 6px; border-radius: 999px; background: var(--p7); color: var(--p5); font-size: var(--fs-xs); text-align: center; font-variant-numeric: tabular-nums; }
.tutor-db-card__tabs [aria-selected="true"] .count { background: var(--p9); color: var(--p1); }
.tutor-db-card__panel { padding: var(--s5); }
.tutor-db-card__panel .table-wrap { border-radius: 10px; }
.tutor-db-card__panel .card { max-width: 300px; }

/* 帳號設定（Tutor 4 的帳號頁：不顯示儀表板側欄） */
.tutor-acc-header { position: sticky; top: 72px; z-index: 20; border-bottom: 1px solid var(--line); background: var(--p9); }
.tutor-acc-header__inner, .tutor-acc { max-width: 1080px; margin-inline: auto; padding-inline: var(--gutter); }
.tutor-acc-header__inner { display: flex; align-items: center; gap: var(--s3); min-height: 68px; }
.tutor-acc-header h1 { flex: 1; font-size: var(--fs-xl); }
.tutor-acc-header .badge { display: none; }
.tutor-acc-header.is-dirty .badge { display: inline-flex; }
.tutor-acc { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: var(--s6); align-items: start; padding-block: var(--s6) var(--s8); }
.tutor-acc-tabs { display: flex; flex-direction: column; gap: 4px; padding: var(--s4); }
.tutor-acc-tabs button { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 2px var(--s3); align-items: start; padding: 10px 12px; border: 0; border-radius: 8px; background: none; text-align: left; cursor: pointer; }
.tutor-acc-tabs button:hover { background: var(--p8); }
.tutor-acc-tabs button[aria-selected="true"] { background: var(--tint); }
.tutor-acc-tabs svg { grid-row: 1 / 3; width: 20px; height: 20px; margin-top: 2px; color: var(--p6); }
.tutor-acc-tabs [aria-selected="true"] svg { color: var(--p1); }
.tutor-acc-tabs b { font-size: var(--fs-sm); color: var(--p3); }
.tutor-acc-tabs small { font-size: var(--fs-xs); color: var(--p6); line-height: 1.5; }
.tutor-acc-panel { display: flex; flex-direction: column; gap: var(--s6); padding: var(--s6); }
.tutor-acc-panel h3 { font-size: var(--fs-lg); }
.tutor-acc-cover { position: relative; margin-bottom: 44px; }
.tutor-acc-cover__img { overflow: hidden; aspect-ratio: 700 / 230; border-radius: var(--radius-card); background: var(--p7); }
.tutor-acc-cover__img img { width: 100%; height: 100%; object-fit: cover; }
.tutor-acc-cover > .btn { position: absolute; right: 12px; top: 12px; }
.tutor-acc-avatar { position: absolute; left: var(--s5); bottom: -40px; display: flex; align-items: flex-end; gap: var(--s3); }
.tutor-acc-avatar .avatar { width: 88px; height: 88px; border: 4px solid var(--p9); font-size: 2rem; }
.tutor-acc-avatar .btn { margin-bottom: 4px; }
.tutor-acc-note { font-size: var(--fs-xs); color: var(--p6); }

@media (max-width: 960px) {
  .tutor-pcard__thumb { flex-basis: 160px; }
  .tutor-acc { grid-template-columns: minmax(0, 1fr); }
  .tutor-acc-tabs { flex-direction: row; overflow-x: auto; scrollbar-width: none; padding: var(--s2); }
  .tutor-acc-tabs button { flex: none; grid-template-columns: 20px auto; }
  .tutor-acc-tabs small { display: none; }
  .tutor-acc-tabs svg { grid-row: auto; }
}
.tutor-db-mnav { position: sticky; bottom: 0; z-index: 25; display: none; justify-content: space-around; padding: 6px var(--s2) calc(6px + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--line); background: var(--p9); }
@media (max-width: 768px) {
  .tutor-db-layout { grid-template-columns: minmax(0, 1fr); }
  .tutor-db-sidebar { display: none; }
  .tutor-db-mnav { display: flex; }
}
.tutor-db-mnav a { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 64px; padding: 6px; border-radius: 8px; color: var(--p5); font-size: var(--fs-xs); text-decoration: none; }
.tutor-db-mnav a[aria-current="page"] { color: var(--p1); font-weight: 700; }
.tutor-db-mnav svg { width: 22px; height: 22px; }
@media (max-width: 576px) {
  .tutor-db-header { position: static; min-height: 0; padding: var(--s4); border-bottom: 0; }
  .tutor-db-hi { font-size: var(--fs-lg); }
  .tutor-db-page { padding-top: 0; }
  .tutor-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
  .tutor-stat { min-height: 112px; padding: var(--s3); }
  .tutor-stat b { font-size: 1.625rem; }
  .tutor-pcard { flex-direction: column; }
  .tutor-pcard__thumb { flex: none; }
  .tutor-pcard__body { padding: 0 4px 4px; }
  .tutor-pcard__actions { position: absolute; top: var(--s4); right: var(--s4); }
  .tutor-pcard__actions .badge { background: var(--p9) !important; }
  .tutor-db-card { border: 0; background: none; }
  .tutor-db-card__tabs { padding: 0 0 var(--s3); border-bottom: 0; }
  .tutor-db-card__panel { padding: 0; }
  .tutor-acc-header { top: 0; position: static; }
  .tutor-acc-panel { padding: var(--s5) var(--s4); }
  .tutor-acc-avatar { left: var(--s4); }
  .tutor-acc-avatar .avatar { width: 72px; height: 72px; }
  .tutor-acc-cover { margin-bottom: 48px; }
  [data-page="learning-center"] :is(.review-fab, .showcase-bar) { bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
  [data-page="learning-center"] .review-panel { bottom: calc(136px + env(safe-area-inset-bottom, 0px)); }
}

/* ================= WooCommerce 登入、購物車、結帳、訂單完成、通知信（只換顏色字體，版面照 WooCommerce 11.1） ================= */
/* ===== WooCommerce 登入、購物車、結帳、訂單完成、通知信（Kadence 預設版型，只換顏色字體） =====
   WIP：之後併入 components.css。只用 tokens，class 一律 wc- 開頭。 */

/* 頁面外框（Kadence 內容區，頁面標題在內容上方） */
.wc-page { padding-block: var(--s7) var(--section-y); }
.wc-page__title { margin-bottom: var(--s6); }
.wc-narrow { max-width: 800px; margin-inline: auto; }

/* 白底框：購物車總計、您的訂單、登入框、訂單明細 */
.wc-box { padding: clamp(20px, 3vw, 32px); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); box-shadow: var(--shadow-sm); }
.wc-box > h2, .wc-h2 { font-size: var(--fs-xl); margin-bottom: var(--s4); }
.wc-box--tint { background: var(--p8); box-shadow: none; }
@media (min-width: 961px) { .wc-sticky { position: sticky; top: 96px; } }

/* Woo 表格（shop_table）：購物車、購物車總計、您的訂單、訂單詳細資料 */
.wc-table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); font-variant-numeric: tabular-nums; }
.wc-table th, .wc-table td { padding: 14px 12px; text-align: left; vertical-align: middle; border-bottom: 1px solid var(--line); }
.wc-table th:first-child, .wc-table td:first-child { padding-left: 0; }
.wc-table th:last-child, .wc-table td:last-child { padding-right: 0; text-align: right; }
.wc-table thead th { padding-block: 10px; font-size: var(--fs-xs); font-weight: 700; letter-spacing: 0.04em; color: var(--p5); border-bottom-color: var(--line-strong); }
.wc-table tbody th { font-weight: 500; color: var(--p5); }
.wc-table:not(.wc-cart-table) thead th:first-child { width: 62%; }
.wc-table tfoot th { font-weight: 500; color: var(--p5); }
.wc-table tfoot td { color: var(--p3); }
.wc-table .product-name { color: var(--p3); }
.wc-table .product-name a { color: var(--p3); font-weight: 700; text-decoration: none; }
.wc-table .product-name a:hover { color: var(--p1); }
.wc-table .product-quantity-x { color: var(--p5); font-weight: 400; white-space: nowrap; }
.wc-table .order-total th, .wc-table .order-total td { border-bottom: 0; padding-top: var(--s4); font-weight: 700; color: var(--p3); }
.wc-table .order-total td { font-size: var(--fs-xl); }
.wc-table small { display: block; font-size: var(--fs-xs); color: var(--p6); font-weight: 400; }
.wc-table .shipped-via { display: inline-block; font-size: var(--fs-xs); color: var(--p5); white-space: nowrap; }

/* 購物車商品表格 */
.wc-cart-table .product-remove { width: 36px; }
.wc-cart-table .product-thumbnail { width: 96px; }
.wc-cart-table .product-thumbnail img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; background: var(--p7); }
.wc-cart-table .product-name a { color: var(--p3); font-size: var(--fs-base); font-weight: 700; text-decoration: none; }
.wc-cart-table .product-name a:hover { color: var(--p1); }
.wc-cart-table .product-subtotal { font-weight: 700; color: var(--p3); }
.wc-remove { display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: var(--p6); font-size: 22px; line-height: 1; text-decoration: none; }
.wc-remove:hover { background: var(--err-bg); color: var(--err); }
.input.wc-qty { width: 76px; min-height: 42px; padding: 8px 6px; text-align: center; font-variant-numeric: tabular-nums; }
.input.wc-qty[readonly] { border-color: transparent; background: transparent; box-shadow: none; }
.wc-cart-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); padding-top: var(--s5); }
.wc-coupon { display: flex; flex-wrap: wrap; gap: var(--s2); }
.wc-coupon .input { width: 200px; min-height: 46px; }
.wc-totals-note { margin-top: 4px; font-size: var(--fs-xs); color: var(--p5); font-weight: 400; }
.wc-totals .btn { margin-top: var(--s5); min-height: 52px; font-size: var(--fs-base); }
.wc-coupon-remove { font-size: var(--fs-xs); font-weight: 400; }

/* 手機：Woo 的 shop_table_responsive，每一列變成一張卡片，欄名放左邊 */
@media (max-width: 720px) {
  .wc-table--responsive thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .wc-table--responsive, .wc-table--responsive tbody, .wc-table--responsive tr, .wc-table--responsive td { display: block; }
  .wc-table--responsive td { display: flex; justify-content: space-between; align-items: center; gap: var(--s4); padding: 8px 0; border: 0; text-align: right; }
  .wc-table--responsive td:last-child { padding-right: 0; }
  .wc-table--responsive td[data-title]::before { content: attr(data-title); color: var(--p5); font-weight: 700; font-size: var(--fs-xs); text-align: left; }
  .wc-cart-table tr.cart_item { position: relative; display: grid; grid-template-columns: 72px minmax(0, 1fr); column-gap: var(--s4); padding-block: var(--s4); border-bottom: 1px solid var(--line); }
  .wc-cart-table tr.cart_item:first-child { border-top: 1px solid var(--line); }
  .wc-cart-table td.product-remove { position: absolute; top: var(--s3); right: 0; width: auto; padding: 0; }
  .wc-cart-table td.product-thumbnail { width: auto; padding: 0; }
  .wc-cart-table td.product-name { display: block; align-self: center; padding: 0 36px 0 0; text-align: left; }
  .wc-cart-table td.product-name::before { content: none; }
  .wc-cart-table td.product-price, .wc-cart-table td.product-quantity, .wc-cart-table td.product-subtotal { grid-column: 1 / -1; }
  .wc-cart-table td.product-price { margin-top: var(--s3); padding-top: var(--s3); border-top: 1px dashed var(--line); }
  .wc-cart-actions { flex-direction: column; align-items: stretch; }
  .wc-coupon { flex-wrap: nowrap; }
  .wc-coupon .input { flex: 1; width: auto; min-width: 0; }
  .wc-cart-actions > .btn { width: 100%; }
}

/* 結帳：上方兩條提示（老顧客登入、折價券）＋展開的小表單 */
.wc-checkout-notices { display: grid; gap: var(--s2); margin-bottom: var(--s6); }
.wc-checkout-notices .notice a { color: inherit; font-weight: 700; }
.wc-inline-form { display: grid; gap: var(--s4); padding: var(--s5); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); }
.wc-inline-form > p { font-size: var(--fs-sm); color: var(--p5); }
.wc-checkout-layout { grid-template-columns: minmax(0, 1fr) 420px; }
@media (max-width: 960px) { .wc-checkout-layout { grid-template-columns: minmax(0, 1fr); } }
.wc-form h2 { font-size: var(--fs-xl); }
.wc-form .select { width: 100%; min-height: 56px; font-size: var(--fs-base); }
.wc-form .field--error .select { border-color: var(--err); }
.wc-optional { margin-left: 4px; font-weight: 400; color: var(--p6); }
.wc-row-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s5); }
@media (max-width: 720px) { .wc-row-3 { grid-template-columns: minmax(0, 1fr); } }
.wc-section-gap { margin-top: var(--s4); padding-top: var(--s6); border-top: 1px solid var(--line); }
.wc-error-list { list-style: none; display: grid; gap: 4px; }
.wc-error-list strong { font-weight: 700; }

/* 結帳：付款方式（payment_methods） */
.wc-payment { list-style: none; display: grid; gap: var(--s2); margin-top: var(--s4); }
.wc-payment > li { border: 1px solid var(--line); border-radius: 10px; background: var(--p9); transition: border-color .18s, box-shadow .18s; }
.wc-payment > li:has(input:checked) { border-color: var(--p1); box-shadow: 0 0 0 1px var(--p1); }
.wc-payment__label { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; padding: 14px 16px; color: var(--p3); font-size: var(--fs-sm); font-weight: 700; cursor: pointer; }
.wc-payment__label input { width: 18px; height: 18px; margin: 0; accent-color: var(--p1); flex: none; }
.wc-payment__icons { display: inline-flex; gap: 4px; margin-left: auto; }
.wc-brand { padding: 1px 6px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--p9); color: var(--p5); font-size: 10.5px; font-weight: 700; letter-spacing: 0.02em; line-height: 1.6; }
.wc-payment__box { display: grid; gap: var(--s3); margin: 0 16px 16px; padding: 14px 16px; border-radius: 8px; background: var(--p8); color: var(--p5); font-size: var(--fs-sm); }
.wc-sdk { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s3); }
.wc-sdk .field:first-child { grid-column: 1 / -1; }
.wc-sdk .field label { font-size: var(--fs-xs); }
.wc-sdk .input { min-height: 44px; padding: 10px 12px; font-size: var(--fs-sm); }
.wc-sdk__note { grid-column: 1 / -1; font-size: var(--fs-xs); color: var(--p6); }
.wc-terms { display: grid; gap: var(--s3); margin-top: var(--s5); padding-top: var(--s5); border-top: 1px solid var(--line); font-size: var(--fs-sm); color: var(--p5); }
.wc-terms .check { color: var(--p4); }
.wc-place-order { margin-top: var(--s5); min-height: 54px; font-size: var(--fs-base); }

/* 訂單完成（thankyou） */
.wc-thanks { display: flex; flex-direction: column; align-items: center; gap: var(--s4); text-align: center; }
.wc-thanks h1 { font-size: var(--fs-2xl); }
.wc-thanks p { max-width: 34em; color: var(--p5); text-wrap: balance; }
.wc-mark { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: var(--ok-bg); color: var(--ok); animation: rise .6s cubic-bezier(.2,.7,.2,1) both; }
.wc-mark--wait { background: var(--warn-bg); color: var(--warn); }
.wc-mark--err { background: var(--err-bg); color: var(--err); }
.wc-mark svg { width: 34px; height: 34px; }
.wc-gw-notice { text-align: left; }
.wc-gw-notice > div { display: grid; gap: 6px; min-width: 0; }
.wc-gw-notice h2, .wc-gw-notice h3 { color: inherit; font-family: var(--font-body); font-size: var(--fs-base); }
.wc-gw-notice ul { list-style: none; display: grid; gap: 2px; }
.wc-gw-notice .btn { justify-self: start; margin-top: 4px; }
.wc-overview { list-style: none; display: flex; flex-wrap: wrap; gap: 1px; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--line); text-align: left; }
.wc-overview li { flex: 1 1 auto; display: flex; flex-direction: column; gap: 2px; padding: 14px 18px; background: var(--p9); font-size: var(--fs-xs); color: var(--p5); }
.wc-overview strong { color: var(--p3); font-size: var(--fs-sm); font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 720px) {
  .wc-overview { flex-direction: column; }
  .wc-overview li { flex-direction: row; justify-content: space-between; align-items: baseline; gap: var(--s4); padding: 10px 14px; }
  .wc-overview strong { white-space: normal; text-align: right; overflow-wrap: anywhere; }
}
.wc-atm { display: grid; margin: 0; border: 1px solid var(--line); border-radius: 10px; background: var(--p9); color: var(--p4); }
.wc-atm > div { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px var(--s4); padding: 10px 14px; }
.wc-atm > div + div { border-top: 1px solid var(--line); }
.wc-atm dt { color: var(--p5); }
.wc-atm dd { margin: 0; color: var(--p3); font-weight: 700; font-variant-numeric: tabular-nums; }
.wc-addresses { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); text-align: left; }
.wc-addresses address { font-style: normal; line-height: 1.8; color: var(--p4); }
.wc-addresses h2 { font-size: var(--fs-lg); margin-bottom: var(--s3); }
@media (max-width: 720px) { .wc-addresses { grid-template-columns: minmax(0, 1fr); } }

/* 我的帳號：登入／註冊／忘記密碼 */
.wc-login-wrap { padding-block: clamp(48px, 8vw, 96px); background: var(--p8); }
.wc-login { max-width: 440px; margin-inline: auto; }
.wc-login .tabs { gap: 0; margin-bottom: var(--s5); overflow: visible; }
.wc-login .tab { flex: 1; font-size: var(--fs-base); }
.wc-login__title { font-size: var(--fs-xl); }
.wc-login__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3); font-size: var(--fs-sm); }
.wc-login__row .check input { margin-top: 3px; }
.wc-login__back { justify-self: center; font-size: var(--fs-sm); }
.wc-pw { position: relative; display: block; }
.wc-pw .input { padding-right: 52px; }
.wc-pw__toggle { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); display: grid; place-items: center; width: 40px; height: 40px; border: 0; border-radius: 6px; background: none; color: var(--p6); cursor: pointer; }
.wc-pw__toggle:hover { color: var(--p1); background: var(--p8); }
.wc-pw__toggle svg { width: 20px; height: 20px; }

/* 購物通知信（Woo 經典信件版型：Logo、主色標題列、訂單表格、地址） */
.wc-mail-page { min-height: 100vh; padding: var(--s7) var(--s4) var(--s8); background: var(--p7); }
.wc-mail { max-width: 600px; margin-inline: auto; color: var(--p4); font-size: 14px; line-height: 1.65; }
.wc-mail__logo { display: flex; justify-content: center; padding: 0 0 var(--s5); }
.wc-mail__container { overflow: hidden; border: 1px solid var(--line); border-radius: 6px; background: var(--p9); box-shadow: var(--shadow-sm); }
.wc-mail__header { padding: 32px 40px; background: var(--p1); }
.wc-mail__header h1 { color: var(--p9); font-family: var(--font-body); font-size: 26px; font-weight: 500; line-height: 1.3; }
.wc-mail__body { display: flex; flex-direction: column; gap: 16px; padding: 36px 40px 32px; }
.wc-mail__body h2 { margin-top: 8px; color: var(--p1); font-family: var(--font-body); font-size: 17px; }
.wc-mail__body h2 a { color: inherit; }
.wc-mail__btn { align-self: flex-start; }
.wc-mail-table { width: 100%; border: 1px solid var(--line); border-collapse: collapse; color: var(--p4); font-size: 14px; font-variant-numeric: tabular-nums; }
.wc-mail-table th, .wc-mail-table td { padding: 12px; border: 1px solid var(--line); text-align: left; vertical-align: middle; overflow-wrap: break-word; }
.wc-mail-table thead th, .wc-mail-table tbody td:not(:first-child) { white-space: nowrap; }
.wc-mail-table thead th, .wc-mail-table tfoot th { color: var(--p3); }
.wc-mail-table tfoot tr:first-child th, .wc-mail-table tfoot tr:first-child td { border-top-width: 4px; }
.wc-mail-table .shipped-via { font-size: 12px; color: var(--p5); }
.wc-mail__addresses { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.wc-mail__addresses address { padding: 12px; border: 1px solid var(--line); font-style: normal; line-height: 1.8; }
.wc-mail__footer { padding: var(--s5) 0; text-align: center; font-size: 12px; color: var(--p6); }
@media (max-width: 600px) {
  .wc-mail-page { padding: var(--s5) var(--s3) var(--s7); }
  .wc-mail__header { padding: 24px 20px; }
  .wc-mail__header h1 { font-size: 22px; }
  .wc-mail__body { padding: 24px 20px; }
  .wc-mail-table { font-size: 13px; }
  .wc-mail-table th, .wc-mail-table td { padding: 8px; }
  .wc-mail__addresses { grid-template-columns: minmax(0, 1fr); }
}

/* ================= 會員中心、法務頁、404、搜尋結果（只換顏色字體） ================= */
/* 暫存：新頁面的樣式，之後併入 components.css。只用 tokens。 */

/* ===== 會員中心（dba-account-center 外掛固定頁：版面照外掛，只換顏色字體）・account.html ===== */
.acct-wrap { padding-block: var(--s7) var(--s8); }
.acct { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: clamp(24px, 3vw, 40px); align-items: start; }
.acct-side, .acct-main { min-width: 0; }
.acct-id { display: flex; align-items: center; gap: var(--s3); padding: var(--s2) var(--s2) var(--s5); }
.acct-id .avatar { width: 48px; height: 48px; font-size: 1.25rem; flex: none; }
.acct-id strong { display: block; color: var(--p3); line-height: 1.4; }
.acct-nav ul { list-style: none; display: grid; gap: 4px; }
.acct-nav a { display: block; padding: 11px 16px; border-radius: var(--radius-btn); color: var(--p5); font-size: var(--fs-sm); font-weight: 500; text-decoration: none; }
.acct-nav a:hover { background: var(--p8); color: var(--p1); }
.acct-nav a[aria-current="page"] { background: var(--tint); color: var(--p1); font-weight: 700; }
.acct-mnav { display: none; }
.acct-head { display: flex; flex-direction: column; gap: var(--s2); margin-bottom: var(--s6); }
.acct-head h2 { font-size: var(--fs-2xl); }
.acct-head p { font-size: var(--fs-sm); color: var(--p5); }
.acct-stack { display: flex; flex-direction: column; gap: var(--s5); }
.acct-card { padding: var(--s5); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); }
.acct-card > h3, .acct-card > .acct-row { margin-bottom: var(--s4); }
.acct-card > .acct-row--solo { margin-bottom: 0; }
.acct-row { display: flex; align-items: center; justify-content: space-between; gap: var(--s4); }
.acct-row h3 { margin-bottom: 2px; }
.acct-muted { font-size: var(--fs-sm); color: var(--p5); }
.acct-card > .acct-muted { margin-bottom: var(--s4); }
.acct-link { font-size: var(--fs-sm); font-weight: 700; color: var(--p1); text-decoration: none; white-space: nowrap; }
.acct-link:hover { color: var(--p2); text-decoration: underline; }
.acct-notice:empty { display: none; }
.acct-notice { margin-bottom: var(--s5); }
/* 總覽「最近訂單」列 */
.acct-order { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) minmax(0, 1fr) auto; gap: var(--s3); align-items: center; padding-block: var(--s4); border-top: 1px solid var(--line); font-size: var(--fs-sm); }
.acct-order:last-child { padding-bottom: 0; }
.acct-order strong { color: var(--p3); font-variant-numeric: tabular-nums; }
.acct-order small { display: block; font-size: var(--fs-xs); color: var(--p6); }
.acct-order .badge { justify-self: start; }
.acct-order__actions { display: flex; flex-wrap: wrap; gap: 8px 12px; }
/* 我的課程（dba-account-tutor 擴充） */
.acct-courses { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s5); }
.acct-course { display: flex; flex-direction: column; min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); }
.acct-course__cover { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--p7); }
.acct-course__cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.acct-course__cover:hover img { transform: scale(1.04); }
.acct-course__body { display: flex; flex: 1; flex-direction: column; align-items: flex-start; gap: 6px; padding: var(--s4); }
.acct-course h3 { font-size: var(--fs-base); line-height: 1.45; word-break: keep-all; overflow-wrap: anywhere; }
.acct-course small { font-size: var(--fs-xs); color: var(--p5); }
.acct-course .acct-link { margin-top: auto; padding-top: var(--s3); }
.acct-toolbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s4) var(--s5); margin-bottom: var(--s6); }
.acct-sort { display: flex; align-items: center; gap: var(--s3); }
.acct-sort label { display: flex; align-items: center; gap: 10px; font-size: var(--fs-sm); color: var(--p5); white-space: nowrap; }
.acct-sort .select { width: 150px; }
.acct-sort .btn { min-height: 42px; }
.acct-after { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s5); margin-top: var(--s5); }
.acct-session { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: var(--s4); padding-block: var(--s4); border-top: 1px solid var(--line); }
.acct-session:last-child { padding-bottom: 0; }
.acct-session time { font-weight: 700; color: var(--p3); font-variant-numeric: tabular-nums; }
.acct-session strong { display: block; color: var(--p3); }
.acct-session p { font-size: var(--fs-sm); color: var(--p5); }
.acct-session .acct-link { display: inline-block; margin-top: var(--s2); }
/* 帳戶資料表單、地址、WooCommerce 提示框 */
.acct-form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4) var(--s5); }
.acct-form--single { grid-template-columns: minmax(0, 1fr); }
.acct-form > .btn { grid-column: 1 / -1; justify-self: start; }
.acct-info { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--s3) var(--s4); padding: var(--s5); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p8); font-size: var(--fs-sm); color: var(--p5); }
.acct-addresses { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s5); }
.acct-addresses address { font-style: normal; font-size: var(--fs-sm); line-height: 1.8; color: var(--p4); overflow-wrap: anywhere; }
/* WooCommerce 訂單表格（手機變卡片，照外掛的 account.css） */
.acct-orders .table td { vertical-align: middle; }
.acct-orders .table td a:not(.btn) { font-weight: 700; text-decoration: none; }
@media (max-width: 1023px) {
  .acct { grid-template-columns: 180px minmax(0, 1fr); }
  .acct-courses { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--s4); }
}
@media (max-width: 767px) {
  .acct-wrap { padding-top: var(--s5); }
  .acct { display: block; }
  .acct-id { padding: 0 0 var(--s4); }
  .acct-nav { display: none; }
  .acct-mnav { display: block; margin-bottom: var(--s6); font-size: var(--fs-sm); font-weight: 700; color: var(--p3); }
  .acct-mnav .select { display: block; width: 100%; min-height: 48px; margin-top: 6px; font-size: var(--fs-base); color: var(--p3); }
  .acct-mnav small { display: block; margin-top: 6px; font-size: var(--fs-xs); font-weight: 400; color: var(--p6); }
  .acct-head h2 { font-size: var(--fs-xl); }
  .acct-card { padding: var(--s4); }
  .acct-row { flex-wrap: wrap; align-items: flex-start; gap: var(--s2) var(--s4); }
  .acct-courses { grid-template-columns: none; grid-auto-flow: column; grid-auto-columns: 78%; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: var(--s3); }
  .acct-course { scroll-snap-align: start; }
  .acct-courses--history { grid-template-columns: minmax(0, 1fr); grid-auto-flow: row; overflow: visible; }
  .acct-order { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "sum status" "total actions"; gap: var(--s2) var(--s4); }
  .acct-order__sum { grid-area: sum; }
  .acct-order .badge { grid-area: status; justify-self: end; align-self: start; }
  .acct-order__total { grid-area: total; }
  .acct-order__actions { grid-area: actions; justify-content: flex-end; }
  .acct-toolbar { display: block; }
  .acct-toolbar .chips { margin-bottom: var(--s4); }
  .acct-sort { align-items: flex-end; }
  .acct-sort label { flex: 1; display: block; min-width: 0; }
  .acct-sort .select { display: block; width: 100%; margin-top: 6px; }
  .acct-session { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .acct-form, .acct-addresses { grid-template-columns: minmax(0, 1fr); }
  .acct-orders.table-wrap { overflow: visible; border: 0; border-radius: 0; }
  .acct-orders .table, .acct-orders .table tbody, .acct-orders .table tr { display: block; }
  .acct-orders .table thead { display: none; }
  .acct-orders .table tr { margin-bottom: var(--s4); padding: 4px var(--s4); border: 1px solid var(--line); border-radius: var(--radius-card); background: var(--p9); }
  .acct-orders .table tr td { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: 12px 0; border-bottom: 1px solid var(--line); white-space: normal; text-align: right; }
  .acct-orders .table tr td:last-child { border-bottom: 0; }
  .acct-orders .table td::before { content: attr(data-title); flex: none; color: var(--p5); font-weight: 500; text-align: left; }
}

/* ===== 法務頁（一般文字頁）・privacy.html、terms.html、refund.html ===== */
.legal-narrow { max-width: calc(46rem + var(--gutter) * 2); }
.legal-updated { font-size: var(--fs-sm); color: var(--p5); }
.legal-body { font-size: var(--fs-base); line-height: 1.85; gap: var(--s4); }
.legal-body h2 { font-size: var(--fs-lg); margin-top: var(--s6); scroll-margin-top: 112px; }
.legal-body .table td { white-space: normal; min-width: 8em; }
.legal-body .table-wrap { margin-block: var(--s2); }

/* ===== 搜尋表單（Kadence 內建 get_search_form；404 與搜尋結果共用） ===== */
.search-form { position: relative; width: 100%; max-width: 32rem; }
.search-form .input { padding-right: 56px; }
.search-form .input::-webkit-search-cancel-button { display: none; }
.search-form button { position: absolute; top: 50%; right: 4px; display: grid; place-items: center; width: 44px; height: 40px; border: 0; border-radius: calc(var(--radius-input) - 2px); background: transparent; color: var(--p5); cursor: pointer; transform: translateY(-50%); }
.search-form button:hover { background: var(--p8); color: var(--p1); }
.search-form button svg { width: 20px; height: 20px; }

/* ===== 搜尋結果（Kadence 搜尋頁，清單排版，只換顏色字體）・search.html ===== */
.search-results { list-style: none; }
.filter-bar + .search-results { margin-top: calc(var(--s6) * -1); }
.search-result { display: grid; grid-template-columns: 180px minmax(0, 1fr); gap: var(--s5); align-items: start; padding-block: var(--s5); border-bottom: 1px solid var(--line); }
.search-result__media { display: block; overflow: hidden; border-radius: var(--radius-card); aspect-ratio: 3 / 2; background: var(--p7); }
.search-result__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.search-result:hover .search-result__media img { transform: scale(1.04); }
.search-result__body { display: flex; flex-direction: column; align-items: flex-start; gap: var(--s2); min-width: 0; }
.search-result h2 { font-size: var(--fs-lg); word-break: keep-all; overflow-wrap: anywhere; }
.search-result h2 a { color: var(--p3); text-decoration: none; transition: color .18s; }
.search-result h2 a:hover { color: var(--p1); }
.search-result p { font-size: var(--fs-sm); color: var(--p5); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.search-reco { margin-top: var(--s8); }
.search-reco h2 { font-size: var(--fs-xl); margin-bottom: var(--s5); }
@media (max-width: 720px) {
  .search-result { grid-template-columns: 88px minmax(0, 1fr); gap: var(--s4); }
  .search-result__media { aspect-ratio: 1; border-radius: 8px; }
  .search-result h2 { font-size: var(--fs-base); }
}

/* ===== 404（Kadence 內建 404，只換顏色字體）・404.html ===== */
.nf { display: flex; flex-direction: column; align-items: center; gap: var(--s4); max-width: 34rem; margin-inline: auto; text-align: center; }
.nf__code { font-family: var(--font-heading); font-weight: var(--heading-weight); font-size: var(--fs-3xl); line-height: 1; letter-spacing: 0.04em; color: color-mix(in srgb, var(--p1) 24%, var(--p9)); font-variant-numeric: tabular-nums; }
.nf .search-form { margin-top: var(--s2); }
