/* ==========================================================================
   RD 四季講堂｜秋・個人色彩美學
   Design tokens
   ========================================================================== */

:root {
  /* Color — extracted from the hero photography */
  --bg: #F5F1EA;
  --bg-deep: #EFE8DC;
  --bg-alt: #ECE4D6;          /* payment info block */
  --text-primary: #2B2B28;
  --text-secondary: #6D6963;
  --text-faint: #9A948B;
  --clay: #B7836F;            /* brand terracotta accent */
  --clay-deep: #9C6C5A;
  --hairline: #D7C4B7;
  --hairline-soft: #E3D6C9;
  --sage: #9AA08C;
  --mist: #8A9BAA;
  --gold: #C9A46B;           /* 主視覺色布中的駝色調 */
  --rose: #A9878A;           /* 柔霧玫瑰灰，取自人物膚色與布料陰影 */

  /* Type */
  --font-display: "Noto Serif TC", "Songti TC", serif;
  --font-body: "Noto Sans TC", "PingFang TC", sans-serif;
  --font-caption: "EB Garamond", "Noto Serif TC", serif;

  /* Rhythm */
  --measure: 620px;
  --section-pad-y: clamp(72px, 12vw, 148px);
  --page-pad-x: clamp(20px, 6vw, 96px);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-weight: 300;
  line-height: 1.85;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.eyebrow {
  font-family: var(--font-caption);
  font-size: 13px;
  letter-spacing: 0.22em;
  color: var(--clay-deep);
  text-transform: none;
}

.hairline {
  border: none;
  border-top: 1px solid var(--hairline);
  margin: 0;
}

.section {
  padding: var(--section-pad-y) var(--page-pad-x);
}

.section-title {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(24px, 3vw, 30px);
  letter-spacing: 0.04em;
  margin: 0 0 40px;
  color: var(--text-primary);
}

.measure {
  max-width: var(--measure);
}

.link-quiet {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-caption);
  font-size: 15px;
  letter-spacing: 0.04em;
  color: var(--clay-deep);
  border-bottom: 1px solid var(--hairline);
  padding-bottom: 3px;
  transition: border-color 0.5s var(--ease), color 0.5s var(--ease);
}
.link-quiet:hover {
  border-color: var(--clay-deep);
  color: var(--text-primary);
}
.link-quiet svg {
  width: 13px;
  height: 13px;
  transition: transform 0.5s var(--ease);
}
.link-quiet:hover svg {
  transform: translateX(3px);
}

/* Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 16px 38px;
  font-family: var(--font-body);
  font-size: 15px;
  letter-spacing: 0.06em;
  color: var(--bg);
  background: var(--clay-deep);
  border: 1px solid var(--clay-deep);
  cursor: pointer;
  transition: background 0.5s var(--ease), color 0.5s var(--ease), transform 0.3s var(--ease);
}
.btn:hover {
  background: transparent;
  color: var(--clay-deep);
}
.btn:active {
  transform: scale(0.98);
}

/* ==========================================================================
   01 — Hero
   ========================================================================== */

.hero {
  min-height: 100svh;
  display: grid;
  grid-template-columns: 1fr;
}

@media (min-width: 900px) {
  .hero {
    grid-template-columns: 0.92fr 1.08fr;
    align-items: stretch;
  }
}

.hero__content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 28px;
  padding: 120px var(--page-pad-x) 64px;
}

@media (min-width: 900px) {
  .hero__content {
    padding: 0 clamp(40px, 6vw, 100px) 0 var(--page-pad-x);
  }
}

.hero__eyebrow-rule {
  display: flex;
  align-items: center;
  gap: 16px;
}
.hero__eyebrow-rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--hairline);
  max-width: 80px;
}

.hero h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(40px, 7vw, 64px);
  letter-spacing: 0.06em;
  margin: 0;
  color: var(--text-primary);
}

.hero__subtitle {
  font-family: var(--font-caption);
  font-style: italic;
  font-size: clamp(17px, 2vw, 20px);
  color: var(--clay-deep);
  letter-spacing: 0.02em;
  margin: 0;
}

.hero__meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 15px;
  color: var(--text-secondary);
  padding: 4px 0 4px 0;
  border-top: 1px solid var(--hairline-soft);
  border-bottom: 1px solid var(--hairline-soft);
  margin: 6px 0;
}
.hero__meta div {
  padding: 6px 0;
  display: flex;
  align-items: center;
}
.hero__meta-icon {
  width: 15px;
  height: 15px;
  margin-right: 10px;
  color: var(--clay-deep);
  flex-shrink: 0;
}
.hero__meta-label {
  display: inline-block;
  min-width: 5.5em;
  font-family: var(--font-caption);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--text-faint);
  margin-right: 6px;
}

.hero__price {
  display: flex;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}
.hero__price strong {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 400;
  color: var(--text-primary);
}
.hero__price span {
  font-size: 14px;
  color: var(--text-faint);
  letter-spacing: 0.02em;
}

.hero__cta {
  margin-top: 8px;
  align-self: flex-start;
}

.hero__visual {
  position: relative;
  overflow: hidden;
  min-height: 46vh;
}
@media (min-width: 900px) {
  .hero__visual {
    min-height: auto;
  }
}
.hero__visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 78% 45%;
}

/* ==========================================================================
   02 — About
   ========================================================================== */

.about {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.about p {
  font-size: 17px;
  line-height: 1.95;
  color: var(--text-secondary);
  margin: 0;
}

.about__dots {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}
.about__dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
}
.about__dots span:nth-child(1) { background: var(--clay); }
.about__dots span:nth-child(2) { background: var(--sage); }
.about__dots span:nth-child(3) { background: var(--mist); }

/* ==========================================================================
   03 — Course
   ========================================================================== */

.course__row {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 24px;
  padding: 34px 0;
  border-top: 1px solid var(--hairline);
}
.course__row:last-of-type {
  border-bottom: 1px solid var(--hairline);
}

.course__num {
  font-family: var(--font-caption);
  font-size: 15px;
  color: var(--text-faint);
  letter-spacing: 0.04em;
  padding-top: 4px;
}

.course__row h3 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 20px;
  margin: 0 0 10px;
  letter-spacing: 0.02em;
}
.course__row p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 16px;
  max-width: 520px;
}

.course__syllabus {
  margin-top: 36px;
  font-size: 14.5px;
  color: var(--text-faint);
  letter-spacing: 0.01em;
  line-height: 2;
}

/* ==========================================================================
   04 — Instructor
   ========================================================================== */

.instructor-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
}

@media (min-width: 860px) {
  .instructor-layout {
    grid-template-columns: minmax(220px, 320px) 1fr;
    gap: clamp(48px, 6vw, 96px);
    align-items: center;
  }
}

.instructor__portrait {
  overflow: hidden;
  max-width: 320px;
}
@media (min-width: 860px) {
  .instructor__portrait {
    max-width: none;
  }
}
.instructor__portrait img {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: 50% 18%;
}

.instructor {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.instructor__name {
  font-family: var(--font-display);
  font-size: 19px;
  letter-spacing: 0.02em;
}
.instructor p {
  color: var(--text-secondary);
  font-size: 16.5px;
  margin: 0;
  line-height: 1.95;
}

/* ==========================================================================
   05 — Event info
   ========================================================================== */

.info-section {
  background: var(--bg-deep);
}

.info-list {
  max-width: 640px;
  border-top: 1px solid var(--hairline);
}

.info-row {
  position: relative;
  display: grid;
  grid-template-columns: 6em 1fr;
  gap: 24px;
  padding: 22px 0 22px 24px;
  border-bottom: 1px solid var(--hairline);
  align-items: start;
}

.info-row::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  height: 22px;
  width: 3px;
  background: var(--accent);
}

.info-row__label {
  font-family: var(--font-display);
  font-size: 15px;
  color: var(--text-faint);
  letter-spacing: 0.08em;
  padding-top: 2px;
}

.info-row__value {
  font-size: 17px;
  color: var(--text-primary);
  line-height: 1.6;
}

.info-row__address {
  display: inline-block;
  font-size: 14.5px;
  color: var(--text-secondary);
  margin-top: 4px;
}

.info-row__map-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 8px;
  font-family: var(--font-caption);
  font-size: 13.5px;
  letter-spacing: 0.03em;
  color: var(--clay-deep);
  border-bottom: 1px solid var(--hairline);
  padding-bottom: 2px;
  transition: border-color 0.4s var(--ease), color 0.4s var(--ease);
}
.info-row__map-link:hover {
  border-color: var(--clay-deep);
  color: var(--text-primary);
}
.info-row__map-link svg {
  width: 11px;
  height: 11px;
  transition: transform 0.4s var(--ease);
}
.info-row__map-link:hover svg {
  transform: translateX(3px);
}

.info-cta {
  margin-top: 56px;
  display: flex;
  justify-content: center;
}

/* ==========================================================================
   06 — Signup
   ========================================================================== */

.signup__head {
  margin-bottom: 44px;
}
.signup__sub {
  color: var(--text-secondary);
  font-size: 15.5px;
  margin: 14px 0 0;
}

.tally-embed {
  min-height: 480px;
  border-top: 1px solid var(--hairline);
  padding-top: 40px;
}
.tally-embed iframe {
  width: 100%;
  border: none;
}
#tally-form-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 420px;
  color: var(--text-faint);
  font-size: 14px;
  letter-spacing: 0.05em;
  border: 1px dashed var(--hairline);
}

.payment-note {
  background: var(--bg-alt);
  padding: 36px clamp(24px, 4vw, 44px);
  margin-top: 48px;
}
.payment-note h4 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 16px;
  margin: 0 0 18px;
  letter-spacing: 0.04em;
}
.payment-note ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.payment-note li {
  font-size: 14.5px;
  color: var(--text-secondary);
  line-height: 1.8;
  padding-left: 18px;
  position: relative;
}
.payment-note li::before {
  content: "・";
  position: absolute;
  left: 0;
  color: var(--clay-deep);
}
.payment-note li strong {
  color: var(--text-primary);
  font-weight: 500;
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  padding: 56px var(--page-pad-x) 120px;
  border-top: 1px solid var(--hairline);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
}
@media (min-width: 640px) {
  .site-footer {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 56px;
  }
}
.site-footer__logo {
  height: 22px;
  width: auto;
  flex-shrink: 0;
  align-self: flex-start;
}
.site-footer__links {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.site-footer__links a {
  font-size: 13.5px;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  transition: color 0.4s var(--ease);
}
.site-footer__links a:hover {
  color: var(--clay-deep);
}

/* ==========================================================================
   Mobile sticky CTA
   ========================================================================== */

.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 62px;
  padding: 0 20px;
  background: var(--bg);
  border-top: 1px solid var(--hairline);
  transform: translateY(0);
  transition: transform 0.45s var(--ease);
}
.sticky-cta.is-hidden {
  transform: translateY(100%);
}
.sticky-cta__price {
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--text-primary);
  white-space: nowrap;
}
.sticky-cta__price small {
  display: block;
  font-family: var(--font-body);
  font-size: 11px;
  color: var(--text-faint);
  letter-spacing: 0.04em;
}
.sticky-cta .btn {
  padding: 12px 26px;
  font-size: 14px;
  flex-shrink: 0;
}

@media (min-width: 900px) {
  .sticky-cta {
    display: none;
  }
}

/* ==========================================================================
   Scroll reveal
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Focus visibility */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--clay-deep);
  outline-offset: 3px;
}

/* ==========================================================================
   Responsive paragraph & padding safety
   ========================================================================== */

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }
  .section {
    padding-left: 20px;
    padding-right: 20px;
  }
  .info-row {
    grid-template-columns: 5em 1fr;
    gap: 16px;
    padding: 18px 0 18px 20px;
  }
}
