:root {
  --paper: #f8f6ef;
  --card: #fdfbf5;
  --ink: #292e28;
  --dim: #60645b;
  --line: #dcd9cd;
  --red: #a64632;
  --red2: #883825;
  --serif: 'Songti TC', 'Noto Serif TC', 'Songti SC', 'Hiragino Mincho ProN', 'PMingLiU', serif;
  --sans: 'DM Sans', 'PingFang TC', 'Noto Sans TC', 'Microsoft JhengHei', sans-serif;
  --mono: 'IBM Plex Mono', 'SFMono-Regular', Consolas, monospace;
}
* {
  box-sizing: border-box;
}
html {
  scroll-padding-top: 20px;
}
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
a {
  color: inherit;
  text-decoration: none;
}
button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: default;
  opacity: 0.55;
}
a,
button {
  touch-action: manipulation;
}
button {
  border: 0;
  background: none;
}
h1,
h2,
h3,
h4,
p,
figure {
  margin: 0;
}
h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  line-height: 1.28;
}
h1 {
  font-size: clamp(38px, 5vw, 64px);
  letter-spacing: 0.045em;
}
h2 {
  font-size: clamp(30px, 3.3vw, 43px);
  letter-spacing: 0.06em;
}
h3 {
  font-size: 23px;
}
p {
  color: var(--dim);
}
svg.icon {
  width: 1.15em;
  height: 1.15em;
  stroke: currentColor;
  stroke-width: 1.6;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.17em;
  flex: none;
}
.wrap {
  width: min(1232px, calc(100% - 112px));
  margin-inline: auto;
}
.top {
  border-bottom: 1px solid var(--line);
  background: #faf8f1;
}
.top-in,
.brand,
.top-actions,
nav,
.member,
.foot,
.foot > div,
.btn,
.text-link,
.label,
.filters,
.meta,
.slide-info,
.stepper,
.actions,
.tools,
.byline,
.tag,
.section-end {
  display: flex;
  align-items: center;
}
.top-in {
  height: 78px;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  gap: 10px;
  flex: none;
}
.brand img {
  width: 38px;
  height: 42px;
}
.brand span {
  display: grid;
}
.brand strong {
  font: 700 25px/1.2 var(--serif);
  letter-spacing: 0.13em;
}
.brand small {
  font: 9px/1.6 var(--mono);
  letter-spacing: 0.19em;
  color: #676859;
}
nav {
  gap: clamp(19px, 2.5vw, 38px);
  height: 100%;
}
nav a {
  position: relative;
  font-size: 14px;
  letter-spacing: 0.05em;
  font-weight: 520;
  white-space: nowrap;
  display: grid;
  align-items: center;
  height: 100%;
}
nav a.active,
nav a:hover,
.text-link:hover,
.foot a:hover {
  color: var(--red);
}
nav a.active:after {
  content: '';
  position: absolute;
  height: 2px;
  bottom: 16px;
  left: 22%;
  right: 22%;
  background: var(--red);
}
.member {
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid #a8a798;
  border-radius: 5px;
  font-size: 13px;
  font-weight: 600;
}
.member:hover,
.btn.secondary:hover {
  background: #eeece2;
}
.menu {
  display: none;
}
.skip {
  position: absolute;
  left: 12px;
  top: -80px;
  background: white;
  padding: 10px;
  z-index: 4;
}
.skip:focus {
  top: 10px;
}
:focus-visible {
  outline: 3px solid #9b7050;
  outline-offset: 4px;
}
.loading {
  padding: 70px 0;
}
.hero {
  padding: 48px 0 38px;
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 5%;
  align-items: center;
}
.label {
  color: var(--red);
  gap: 9px;
  font: 600 11px/1.5 var(--mono);
  letter-spacing: 0.105em;
}
.label:before {
  content: '';
  display: block;
  width: 22px;
  height: 2px;
  background: var(--red);
}
.hero h1 {
  font-size: clamp(47px, 4.65vw, 73px);
  line-height: 1.33;
  letter-spacing: 0.035em;
  margin: 20px 0 19px;
  font-weight: 750;
}
.hero h1 em {
  font-style: normal;
  color: var(--red);
}
.hero p {
  font-size: 15px;
  line-height: 1.95;
  letter-spacing: 0.045em;
}
.actions {
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 27px;
}
.btn {
  display: inline-flex;
  gap: 10px;
  justify-content: center;
  background: var(--red);
  color: #fffaf2;
  padding: 12px 22px;
  border-radius: 5px;
  font-weight: 600;
  font-size: 14px;
  line-height: 1.6;
  border: 1px solid var(--red);
  transition:
    background 0.2s,
    transform 0.2s;
}
.btn:hover {
  background: var(--red2);
}
.btn:active {
  transform: translateY(1px);
}
.btn.secondary {
  background: transparent;
  color: var(--ink);
  border-color: #bdbeb0;
}
.btn.small {
  padding: 7px 13px;
  font-size: 13px;
}
.text-link {
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
}
.text-link .icon {
  transition: transform 0.2s;
}
.text-link:hover .icon {
  transform: translateX(2px);
}
.hero-photo {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  background: #adab95;
  isolation: isolate;
  aspect-ratio: 1.65;
}
.hero-photo > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 48%;
  display: block;
  filter: saturate(0.81) contrast(0.97);
}
.hero-photo:after {
  content: '';
  position: absolute;
  inset: 53% 0 0;
  pointer-events: none;
  background: linear-gradient(transparent, rgba(26, 27, 18, 0.65));
  z-index: 0;
}
.location {
  position: absolute;
  bottom: 18px;
  left: 20px;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 9px;
  z-index: 1;
  font-size: 12px;
  letter-spacing: 0.055em;
}
.location .icon {
  width: 15px;
  height: 15px;
}
.photo-mast {
  position: absolute;
  right: 16px;
  top: 16px;
  writing-mode: vertical-rl;
  background: #f8f3e4ed;
  color: #615547;
  padding: 10px 5px;
  font: 600 12px/1.4 var(--serif);
  letter-spacing: 0.19em;
  border: 1px solid #fffc;
  border-radius: 2px;
}
.slide-info {
  justify-content: space-between;
  margin-top: 11px;
}
.slide-info > span {
  font: 10px/1.5 var(--mono);
  letter-spacing: 0.12em;
  color: #6d7167;
}
.stepper {
  gap: 10px;
}
.stepper button {
  border: 1px solid #c9cabb;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  padding: 0;
  font-size: 12px;
}
.stepper button:hover {
  border-color: var(--red);
  color: var(--red);
}
.stepper small {
  font: 10px var(--mono);
  letter-spacing: 0.06em;
}
.catalog {
  border-top: 1px solid var(--line);
  background: #f1f0e7;
  padding: 36px 0 54px;
}
.section-end {
  justify-content: space-between;
  gap: 20px;
  align-items: end;
}
.section-end h2,
.intro h1,
.blocktitle h2 {
  margin-top: 9px;
}
.filters {
  gap: 8px;
  flex-wrap: wrap;
  margin: 21px 0 19px;
}
.chip {
  padding: 6px 16px;
  border: 1px solid #c9c9bd;
  background: transparent;
  border-radius: 24px;
  font-size: 13px;
  line-height: 1.6;
  transition: background 0.18s;
}
.chip.active {
  background: #35483c;
  border-color: #35483c;
  color: white;
}
.chip:not(.active):hover {
  background: #e5e6da;
}
.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}
.course {
  background: var(--card);
  border: 1px solid #d2d2c5;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition:
    transform 0.22s,
    border-color 0.22s;
}
.course:hover {
  transform: translateY(-3px);
  border-color: #a8ac9b;
}
.cover {
  position: relative;
  aspect-ratio: 2.03;
  overflow: hidden;
}
.cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.35s;
}
.course:hover .cover img {
  transform: scale(1.025);
}
.badge {
  position: absolute;
  left: 13px;
  top: 12px;
  background: #f8f6eaf2;
  border: 1px solid #fff9;
  border-radius: 3px;
  padding: 3px 9px;
  font: 600 11px/1.4 var(--mono);
  color: #41473e;
}
.course-in {
  padding: 18px 21px 15px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.category {
  font-size: 12px;
  color: var(--red);
  letter-spacing: 0.07em;
}
.course h3 {
  margin: 6px 0 10px;
  letter-spacing: 0.03em;
}
.meta,
.byline {
  gap: 7px;
  color: var(--dim);
  font-size: 13px;
}
.course-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 15px;
  border-top: 1px solid var(--line);
  padding-top: 13px;
}
.price {
  font-family: var(--mono);
  font-weight: 650;
  color: var(--red);
  font-size: 18px;
}
.course-bottom .icon {
  width: 19px;
  height: 19px;
}
.quiet {
  font-size: 13px;
  color: var(--dim);
}
.home-note {
  display: grid;
  grid-template-columns: 0.58fr 1fr;
  gap: 5%;
  align-items: center;
  padding: 54px 0;
}
.home-note h2 {
  font-size: 32px;
}
.home-note p {
  margin: 8px 0 12px;
}
.word {
  border-left: 2px solid var(--red);
  padding-left: 24px;
}
.word strong {
  font: 600 31px var(--serif);
}
.word small {
  font: 12px var(--mono);
  color: var(--red);
  margin-left: 10px;
}
footer {
  border-top: 1px solid var(--line);
}
.foot {
  justify-content: space-between;
  gap: 18px;
  min-height: 85px;
}
.foot .brand strong {
  font-size: 18px;
}
.foot .brand img {
  width: 26px;
}
.foot > div {
  gap: 22px;
  font-size: 13px;
}
.foot small {
  color: var(--dim);
  font: 10px var(--mono);
  letter-spacing: 0.07em;
}
.page {
  min-height: 66vh;
  padding-block: 38px 65px;
}
.crumb {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--dim);
  font-size: 13px;
  margin-bottom: 25px;
}
.crumb:hover {
  color: var(--red);
}
.intro {
  margin-bottom: 26px;
  max-width: 820px;
}
.intro h1 {
  font-size: clamp(34px, 4.3vw, 55px);
}
.intro p {
  margin-top: 13px;
}
.tools {
  justify-content: space-between;
  gap: 15px;
  flex-wrap: wrap;
}
.search {
  max-width: 270px;
}
.split {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(240px, 0.75fr);
  gap: 25px;
  align-items: start;
}
.panel,
.thread,
.teacher-card {
  border: 1px solid var(--line);
  background: var(--card);
  border-radius: 8px;
  padding: clamp(19px, 2.4vw, 32px);
}
.panel h2,
.blocktitle h2 {
  font-size: 29px;
  margin-bottom: 12px;
}
.panel h3 {
  margin-bottom: 11px;
}
.panel + .panel,
.thread + .thread,
.topic-list,
.spacer {
  margin-top: 20px;
}
.details-art {
  width: 100%;
  aspect-ratio: 2.4;
  object-fit: cover;
  border-radius: 5px;
  margin-bottom: 19px;
}
.lesson,
.admin-row {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  text-align: left;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.lesson:last-child,
.admin-row:last-child {
  border: 0;
}
.lesson > span:first-child {
  display: flex;
  gap: 12px;
  align-items: center;
}
.lesson:hover {
  color: var(--red);
}
.number {
  color: var(--red);
  font: 12px var(--mono);
}
.tag {
  display: inline-flex;
  font-size: 12px;
  color: #45644b;
  background: #e5ecdf;
  border-radius: 4px;
  padding: 2px 8px;
}
.teacher-card .avatar,
.avatar {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border: 1px solid #0002;
  border-radius: 50%;
  font: 600 24px var(--serif);
  color: #fff;
  background: #677d65;
}
.teacher-card .rose {
  background: #ac745d;
}
.teacher-card .blue {
  background: #627e85;
}
.teacher-card h2 {
  font-size: 27px;
  margin: 15px 0 3px;
}
.teacher-card h3 {
  font: 600 15px var(--sans);
  margin: 20px 0 6px;
}
.teacher-card p {
  font-size: 14px;
}
.about {
  max-width: 780px;
}
.about .feature {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: 6px;
  margin: 10px 0 22px;
}
.about p + p {
  margin-top: 16px;
}
.topic-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.thread h3 {
  margin: 10px 0;
}
.thread p,
.reply p,
.admin-row,
.lesson {
  overflow-wrap: anywhere;
}
.reply {
  border-left: 2px solid #bcc6b2;
  padding-left: 16px;
  margin-top: 19px;
}
.thread form {
  margin-top: 20px;
}
.empty {
  border: 1px dashed #bdbdaf;
  padding: 24px;
  border-radius: 6px;
  color: var(--dim);
  margin: 18px 0;
}
.form {
  display: grid;
  gap: 14px;
}
label.field {
  display: grid;
  gap: 5px;
  font-size: 14px;
  font-weight: 600;
}
input,
select,
textarea {
  border: 1px solid #c4c5b8;
  background: #fffef8;
  border-radius: 4px;
  padding: 9px 11px;
  width: 100%;
  font-size: 15px;
  line-height: 1.5;
}
textarea {
  min-height: 80px;
  resize: vertical;
}
input[type='checkbox'] {
  width: auto;
}
fieldset {
  border: 1px solid var(--line);
  padding: 14px;
  border-radius: 4px;
  min-width: 0;
}
legend {
  font-weight: 650;
}
.two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.form .btn {
  justify-self: start;
}
.form[data-form='claimOwner'] summary {
  cursor: pointer;
  color: var(--red);
}
.form[data-form='claimOwner'] details[open] .field {
  margin-top: 8px;
}
.form[data-form='claimOwner'] input[name='code'] {
  -webkit-text-security: disc;
}
.form-error {
  color: #9c351e;
  font-size: 14px;
}
.inline-options {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}
.note {
  background: #eeede2;
  border-left: 3px solid #939f88;
  padding: 10px 14px;
  font-size: 14px;
  margin: 16px 0;
}
.account-tabs {
  display: flex;
  gap: 18px;
  border-bottom: 1px solid var(--line);
  margin: 17px 0;
}
.account-tabs button {
  padding: 5px 0 10px;
}
.account-tabs .selected {
  border-bottom: 2px solid var(--red);
  color: var(--red);
}
dialog {
  width: min(470px, calc(100% - 28px));
  max-height: 90dvh;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 32px;
  background: var(--card);
  color: var(--ink);
}
dialog::backdrop {
  background: #262b24a3;
}
dialog h2 {
  font-size: 28px;
}
.close {
  position: absolute;
  right: 10px;
  top: 8px;
  font-size: 25px;
  line-height: 1.2;
  width: 34px;
  height: 34px;
}
.video {
  width: 100%;
  background: #222;
  aspect-ratio: 16/9;
  border-radius: 5px;
  display: block;
}
.video-title {
  margin-top: 15px;
}
.credits {
  display: grid;
  gap: 10px;
}
.credits a,
.inside-link {
  color: var(--red);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.lesson-edit {
  display: grid;
  gap: 10px;
  margin: 12px 0;
}
.manage-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 22px;
}
.admin-row .actions {
  margin: 0;
}
.demo-tools {
  margin-top: 28px;
}
#toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: #34483b;
  color: white;
  border-radius: 6px;
  padding: 9px 18px;
  z-index: 5;
  max-width: 90%;
  pointer-events: none;
}
#toast:empty {
  display: none;
}
@media (min-width: 1550px) {
  .hero {
    padding: 60px 0 48px;
  }
}
@media (max-width: 990px) {
  .wrap {
    width: calc(100% - 56px);
  }
  .top-in {
    gap: 12px;
  }
  nav {
    gap: 16px;
  }
  nav a {
    font-size: 13px;
  }
  .hero {
    gap: 4%;
    padding-top: 38px;
  }
  .hero h1 {
    font-size: clamp(40px, 5.25vw, 53px);
  }
  .hero-photo {
    aspect-ratio: 1.38;
  }
  .course-in {
    padding: 15px;
  }
  .grid {
    gap: 13px;
  }
  .course h3 {
    font-size: 21px;
  }
  .actions {
    gap: 9px;
  }
  .btn {
    padding: 10px 16px;
  }
}
@media (max-width: 740px) {
  .wrap {
    width: calc(100% - 36px);
  }
  .top-in {
    height: 65px;
  }
  .brand img {
    width: 31px;
  }
  .brand strong {
    font-size: 21px;
  }
  .brand small {
    font-size: 8px;
  }
  .member {
    padding: 6px 10px;
    font-size: 12px;
  }
  .top-actions {
    gap: 7px;
  }
  .menu {
    display: grid;
    place-items: center;
    padding: 7px;
  }
  .top {
    position: relative;
    z-index: 3;
  }
  nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 65px;
    height: auto;
    background: var(--card);
    border-bottom: 1px solid var(--line);
    padding: 10px 18px 15px;
    box-shadow: 0 8px 15px #292e2812;
  }
  nav.open {
    display: grid;
    gap: 0;
  }
  nav a {
    padding: 10px 4px;
  }
  nav a.active:after {
    display: none;
  }
  .hero {
    grid-template-columns: 1fr;
    gap: 25px;
    padding: 30px 0 26px;
  }
  .hero h1 {
    font-size: clamp(41px, 8vw, 57px);
    margin: 13px 0;
  }
  .hero p {
    font-size: 14px;
  }
  .actions {
    margin-top: 18px;
  }
  .hero-photo {
    aspect-ratio: 1.85;
  }
  .catalog {
    padding: 27px 0 35px;
  }
  .section-end {
    gap: 8px;
  }
  .grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .section-end .text-link {
    font-size: 12px;
  }
  .filters {
    gap: 6px;
    margin: 16px 0;
  }
  .chip {
    padding: 6px 12px;
  }
  .home-note {
    grid-template-columns: 1fr;
    gap: 23px;
    padding: 32px 0;
  }
  .foot {
    flex-wrap: wrap;
    justify-content: start;
    gap: 12px 25px;
    padding-block: 15px;
  }
  .foot small {
    width: 100%;
  }
  .foot > div {
    gap: 13px;
  }
  .split {
    grid-template-columns: 1fr;
  }
  .page {
    padding-top: 25px;
  }
  .intro h1 {
    font-size: 36px;
  }
  .tools .search {
    width: 100%;
    max-width: none;
  }
  .hero p br {
    display: none;
  }
}
@media (max-width: 490px) {
  .grid {
    grid-template-columns: 1fr;
  }
  .course-in {
    padding: 17px 19px;
  }
  .course h3 {
    font-size: 24px;
  }
  .course .cover {
    aspect-ratio: 2.25;
  }
  .home-note h2 {
    font-size: 28px;
  }
  .two {
    grid-template-columns: 1fr;
  }
  .admin-row {
    align-items: start;
    flex-wrap: wrap;
  }
  .section-end h2 {
    font-size: 30px;
  }
  .stepper button {
    width: 30px;
    height: 30px;
  }
  .topic-head {
    align-items: start;
  }
  .label {
    font-size: 10px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    scroll-behavior: auto !important;
    transition: none !important;
    animation: none !important;
  }
}
