/* ============================================================
   ACE Website — Global Styles
   Colors: Teal #0E7B8C | Dark Blue #1A5276 | Accent #3A9BAB
   ============================================================ */

:root {
  --teal:       #0E7B8C;
  --teal-light: #3A9BAB;
  --teal-pale:  #E8F4F6;
  --navy:       #1A5276;
  --text:       #2C3E50;
  --text-muted: #5D6D7E;
  --bg:         #F8FAFB;
  --white:      #FFFFFF;
  --border:     #D5E8ED;
  --radius:     10px;
  --shadow:     0 4px 16px rgba(14, 123, 140, 0.10);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans TC", sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.7;
  font-size: 16px;
}

a { color: var(--teal); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ── Navbar ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--white);
  border-bottom: 2px solid var(--teal-pale);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.nav-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  align-items: center;
  height: 64px;
  gap: 32px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--teal);
  text-decoration: none;
}

.nav-brand img { height: 36px; width: auto; }

.nav-links {
  display: flex;
  gap: 4px;
  margin-left: auto;
  list-style: none;
}

.nav-links a {
  display: block;
  padding: 6px 16px;
  border-radius: 6px;
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 500;
  transition: background 0.15s, color 0.15s;
}

.nav-links a:hover,
.nav-links a.active {
  background: var(--teal-pale);
  color: var(--teal);
  text-decoration: none;
}

/* ── Hero ── */
.hero {
  background: linear-gradient(135deg, var(--navy) 0%, var(--teal) 100%);
  color: var(--white);
  padding: 80px 24px 64px;
  text-align: center;
}

.hero-badge {
  display: inline-block;
  background: rgba(255,255,255,0.18);
  border: 1px solid rgba(255,255,255,0.35);
  border-radius: 20px;
  padding: 4px 16px;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: 2.6rem;
  font-weight: 800;
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.hero .subtitle {
  font-size: 1.15rem;
  opacity: 0.88;
  max-width: 560px;
  margin: 0 auto 32px;
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: pointer;
}
.btn:hover { transform: translateY(-1px); text-decoration: none; }

.btn-white {
  background: var(--white);
  color: var(--teal);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255,255,255,0.7);
  margin-left: 12px;
}

/* ── Sections ── */
section { padding: 64px 24px; }
section.bg-gray { background: var(--bg); }

.section-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.section-title {
  font-size: 1.7rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 8px;
}

.section-subtitle {
  color: var(--text-muted);
  margin-bottom: 40px;
  font-size: 1rem;
}

/* ── Card Grid ── */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(14, 123, 140, 0.15);
}

.card-icon {
  font-size: 2rem;
  margin-bottom: 14px;
}

.card h3 {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--teal);
  margin-bottom: 8px;
}

.card p {
  color: var(--text-muted);
  font-size: 0.92rem;
  line-height: 1.65;
}

/* ── Pillar Cards ── */
.pillar {
  border-top: 4px solid var(--teal);
}

/* ── Stat Strip ── */
.stat-strip {
  background: var(--teal);
  color: var(--white);
  padding: 32px 24px;
  text-align: center;
}

.stat-row {
  max-width: 900px;
  margin: 0 auto;
  display: flex;
  justify-content: center;
  gap: 64px;
  flex-wrap: wrap;
}

.stat-item strong {
  display: block;
  font-size: 2.2rem;
  font-weight: 800;
}

.stat-item span {
  font-size: 0.9rem;
  opacity: 0.85;
}

/* ── Course List ── */
.course-list { display: flex; flex-direction: column; gap: 20px; }

.course-item {
  background: var(--white);
  border: 1px solid var(--border);
  border-left: 5px solid var(--teal);
  border-radius: var(--radius);
  padding: 24px 28px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  box-shadow: var(--shadow);
}

.course-num {
  background: var(--teal-pale);
  color: var(--teal);
  font-weight: 800;
  font-size: 1.1rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.course-info h3 { font-size: 1.05rem; color: var(--navy); margin-bottom: 4px; }
.course-info p  { color: var(--text-muted); font-size: 0.9rem; }
.course-tag {
  display: inline-block;
  background: var(--teal-pale);
  color: var(--teal);
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 4px;
  padding: 2px 8px;
  margin-top: 8px;
}

/* ── Video Embed ── */
.video-wrap {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #000;
}
.video-wrap iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: 0;
}

.video-placeholder {
  background: var(--teal-pale);
  border: 2px dashed var(--teal-light);
  border-radius: var(--radius);
  padding: 60px 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* ── Resource Links ── */
.resource-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.resource-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 500;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.resource-link:hover {
  border-color: var(--teal);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: var(--teal);
}
.resource-link .icon { font-size: 1.3rem; }

/* ── Alert Box ── */
.alert {
  background: var(--teal-pale);
  border-left: 4px solid var(--teal);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 16px 20px;
  font-size: 0.92rem;
  color: var(--text);
  margin: 24px 0;
}

/* ── Footer ── */
footer {
  background: var(--navy);
  color: rgba(255,255,255,0.75);
  text-align: center;
  padding: 32px 24px;
  font-size: 0.88rem;
}
footer a { color: rgba(255,255,255,0.85); }
footer strong { color: var(--white); }

/* ── Responsive ── */
@media (max-width: 640px) {
  .hero h1 { font-size: 1.9rem; }
  .hero .subtitle { font-size: 1rem; }
  .nav-links { gap: 0; }
  .nav-links a { padding: 6px 10px; font-size: 0.88rem; }
  .stat-row { gap: 32px; }
  .btn-outline { display: none; }
  .course-item { flex-direction: column; gap: 12px; }
}
