*,
*::before,
*::after { box-sizing: border-box; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
  background: #f5f7fb;
  color: #111827;
  line-height: 1.6;
}

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

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255,255,255,0.95);
  border-bottom: 1px solid #e5e7eb;
  backdrop-filter: blur(10px);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}
.logo {
  font-weight: 700;
  font-size: 1.1rem;
}
.badge {
  margin-left: .4rem;
  padding: 2px 6px;
  font-size: .7rem;
  border-radius: 999px;
  background: #2563eb;
  color: #fff;
}
.nav a {
  margin-left: 1rem;
  font-size: .9rem;
  color: #4b5563;
}
.nav a:hover { color:#111827; }

/* hero */
.hero {
  border-bottom: 1px solid #e5e7eb;
  background: #ffffff;
}
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0,2fr) minmax(260px,1fr);
  gap: 2rem;
  padding: 2.5rem 0 2.5rem;
}
.kicker {
  font-size: .8rem;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #2563eb;
  margin-bottom: .5rem;
}
.hero h1 {
  margin: 0 0 .75rem;
  font-size: 2rem;
}
.highlight {
  background: #fef08a;
  padding: 0 .3rem;
  border-radius: .25rem;
}
.desc {
  color: #4b5563;
  max-width: 34rem;
}
.cta-group { margin-top: 1.1rem; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .6rem 1.2rem;
  border-radius: 999px;
  font-size: .9rem;
  font-weight: 500;
  border: 1px solid transparent;
}
.btn-primary {
  background: #2563eb;
  color:#fff;
  box-shadow:0 10px 25px rgba(37,99,235,.35);
}
.btn-outline {
  margin-left: .5rem;
  border-color:#c7d2fe;
  color:#1d4ed8;
  background:#eff6ff;
}

.hero-note {
  border-radius: .9rem;
  border: 2px dashed #cbd5e1;
  background:#f9fafb;
  padding: 1rem 1.3rem;
  font-size: .9rem;
}
.hero-note-title {
  font-weight: 600;
  margin: 0 0 .4rem;
}
.hero-note ol {
  padding-left: 1.2rem;
  margin: 0;
}

/* latest section */
.section {
  padding: 2rem 0 2.5rem;
}
.section-title {
  font-size: 1.3rem;
  display: flex;
  align-items: center;
  margin: 0 0 .5rem;
}
.dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background:#ef4444;
  margin-right: .5rem;
}
.section-subtitle {
  margin: 0 0 1rem;
  font-size: .9rem;
  color:#6b7280;
}

.card-list {
  display: grid;
  grid-template-columns: repeat(auto-fill,minmax(260px,1fr));
  gap: 1.25rem;
}
.card {
  background:#fff;
  border-radius:.9rem;
  box-shadow: 0 14px 40px rgba(15,23,42,.08);
  border:1px solid #e5e7eb;
  overflow: hidden;
  display:flex;
  flex-direction:column;
}
.thumb {
  background:#fbbf24;
  height:120px;
}
.card-body { padding: .9rem .95rem 1rem; }
.pill-row { display:flex; gap:.4rem; margin-bottom:.4rem; }
.pill {
  font-size:.7rem;
  padding:.13rem .55rem;
  border-radius:999px;
  background:#eef2ff;
  color:#4f46e5;
}
.pill-secondary {
  background:#e0f2fe;
  color:#0369a1;
}
.card-title {
  font-size: .98rem;
  margin:.1rem 0 .25rem;
}
.card-meta {
  font-size:.75rem;
  color:#6b7280;
  margin:0 0 .4rem;
}
.card-desc {
  font-size:.86rem;
  color:#4b5563;
  margin:0 0 .6rem;
}
.card-cta {
  font-size:.8rem;
  color:#1d4ed8;
  font-weight:500;
}

/* about */
.about { padding:2rem 0 3rem; }
.about h1 { font-size:1.6rem; margin-bottom:1rem; }

/* footer */
.site-footer {
  border-top:1px solid #e5e7eb;
  padding:1.2rem 0 1.4rem;
  font-size:.8rem;
  color:#6b7280;
  background:#ffffff;
}

/* responsive */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: minmax(0,1fr); }
}


/* =============================
   RWD 調整：平板與手機 v2.1
   ============================= */

/* 手機優化：寬度 <= 600px */
@media (max-width: 600px) {
  .hero-inner {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 1.25rem;
    padding: 1.8rem 0 2.1rem;
  }
  .hero h1 {
    font-size: 1.5rem;
  }
  .highlight {
    padding: 0 0.15rem;
  }
  .desc {
    font-size: 0.9rem;
  }
  .cta-group {
    margin-top: 0.9rem;
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
  .btn {
    width: 100%;
    justify-content: center;
    margin-bottom: 0.45rem;
    padding: 0.55rem 1.1rem;
    font-size: 0.9rem;
  }
  .btn-outline {
    margin-left: 0;
  }
  .hero-note {
    margin-top: 0.5rem;
    padding: 0.9rem 1rem;
  }
  .hero-note ol {
    line-height: 1.6;
  }
  .section {
    padding: 1.7rem 0 2.1rem;
  }
  .card-list {
    grid-template-columns: minmax(0, 1fr);
  }
  .thumb {
    height: 90px;
  }
  .card-title {
    font-size: 0.96rem;
  }
  .card-desc {
    font-size: 0.85rem;
  }
}

/* 平板優化：600px ~ 900px */
@media (min-width: 600px) and (max-width: 900px) {
  .hero-inner {
    grid-template-columns: minmax(0, 1.3fr) minmax(260px, 1fr);
    column-gap: 1.75rem;
    padding: 2.2rem 0 2.4rem;
  }
  .hero h1 {
    font-size: 1.75rem;
  }
  .cta-group {
    margin-top: 1rem;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .btn {
    padding: 0.55rem 1.2rem;
    font-size: 0.92rem;
  }
  .card-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .thumb {
    height: 110px;
  }
}


/* v2.2 – 手機左右留白加寬，避免文字貼邊 */
@media (max-width: 600px) {
  .container {
    padding-left: 1.75rem;
    padding-right: 1.75rem;
  }
}

/* 小手機（例如 390px 寬 iPhone 12 / 14 Pro）再多一點留白 */
@media (max-width: 430px) {
  .container {
    padding-left: 1.9rem;
    padding-right: 1.9rem;
  }
}


/* v2.3 – header 換行優化、卡片 hover、平板左右邊界 */

/* 平板與小型桌機：header 改為上下兩排，避免文字尷尬斷行 */
@media (max-width: 900px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
    height: auto;
    padding-top: 0.6rem;
    padding-bottom: 0.6rem;
    gap: 0.2rem;
  }
  .nav {
    width: 100%;
  }
  .nav a {
    margin-left: 0;
    margin-right: 1rem;
    font-size: 0.86rem;
  }
}

/* iPad 系列左右留白加大 */
@media (min-width: 600px) and (max-width: 1024px) {
  .container {
    padding-left: 2rem;
    padding-right: 2rem;
  }
}

/* 卡片 hover / 點擊狀態（桌機為主，行動裝置也適用） */
.card {
  cursor: pointer;
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}
.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 45px rgba(15, 23, 42, 0.16);
}
.card:active {
  transform: translateY(-1px);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.16);
}
.card-title-link {
  text-decoration: none;
}
.card-title-link:hover .card-title {
  text-decoration: underline;
}


.card-link {
  display: block;
  color: inherit;
  text-decoration: none;
  height: 100%;
}
.card-link:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 3px;
}


.card:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 3px;
}


/* About 頁面：體驗課 CTA 區塊 */
.about-cta {
  margin-top: 2.5rem;
  padding: 1.5rem 1.4rem;
  border-radius: 1rem;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
}
.about-cta h2 {
  margin: 0 0 0.4rem;
  font-size: 1.25rem;
}
.about-cta p {
  margin: 0 0 0.9rem;
  font-size: 0.92rem;
  color: #4b5563;
}
.about-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.4rem;
  border-radius: 999px;
  background: #2563eb;
  color: #ffffff;
  font-size: 0.92rem;
  font-weight: 500;
  text-decoration: none;
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.3);
}
.about-cta-btn:hover {
  background: #1d4ed8;
}
.about-cta-btn:active {
  transform: translateY(1px);
}
@media (max-width: 600px) {
  .about-cta {
    padding: 1.3rem 1.2rem;
  }
  .about-cta h2 {
    font-size: 1.1rem;
  }
}


.about-cta-frame-wrap {
  margin-top: 1rem;
  border-radius: 1rem;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 10px 30px rgba(15, 23, 42, 0.08);
}
.about-cta-frame {
  width: 100%;
  min-height: 700px;
  border: none;
}
.about-cta-note {
  margin-top: 0.8rem;
  font-size: 0.82rem;
  color: #6b7280;
}
.about-cta-note a {
  color: #1d4ed8;
  text-decoration: underline;
}

@media (max-width: 600px) {
  .about-cta-frame {
    min-height: 780px;
  }
}


/* About 預約表單：本地樣式 */
.booking-form {
  margin-top: 1.1rem;
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}
.form-row {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.form-row-inline {
  flex-direction: row;
  align-items: center;
}
.booking-form label {
  font-size: 0.9rem;
  color: #374151;
}
.booking-form input[type="text"],
.booking-form input[type="tel"],
.booking-form input[type="email"],
.booking-form select {
  border-radius: 0.75rem;
  border: 1px solid #d1d5db;
  padding: 0.55rem 0.75rem;
  font-size: 0.92rem;
  outline: none;
}
.booking-form input:focus,
.booking-form select:focus {
  border-color: #2563eb;
  box-shadow: 0 0 0 1px rgba(37, 99, 235, 0.25);
}
.checkbox-label {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.86rem;
  color: #4b5563;
}
.booking-note {
  margin: 0.2rem 0 0.4rem;
  font-size: 0.82rem;
  color: #6b7280;
}
.booking-submit {
  margin-top: 0.3rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.6rem 1.4rem;
  border-radius: 999px;
  border: none;
  background: #2563eb;
  color: #ffffff;
  font-size: 0.94rem;
  font-weight: 500;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(37, 99, 235, 0.35);
}
.booking-submit:hover {
  background: #1d4ed8;
}
.booking-submit:active {
  transform: translateY(1px);
}

@media (max-width: 600px) {
  .form-row-inline {
    flex-direction: column;
    align-items: flex-start;
  }
}
