/*
Theme Name: HK AIRTA (香港人工智能康復治療協會)
Theme URI: https://hkairta.com
Author: Aadit Health Team
Description: AI Rehabilitation Therapy Association
Version: 3.0
Text Domain: hkairta
*/

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

:root {
  --bg: #FFFFFF;
  --bg-card: #FFFFFF;
  --bg-alt: #F8F9FA;
  --accent: #2563EB;
  --accent-light: rgba(37,99,235,0.06);
  --accent-hover: #1D4ED8;
  --slate: #64748B;
  --border: #E2E8F0;
  --text: #0F172A;
  --text-secondary: #64748B;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 40px rgba(0,0,0,0.08);
  --ff: 'Plus Jakarta Sans', 'Noto Sans TC', 'Microsoft JhengHei', 'PingFang TC', system-ui, -apple-system, sans-serif;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

body {
  font-family: var(--ff);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
.container { max-width: 1100px; margin: 0 auto; padding: 0 24px; }
.section { padding: 80px 0; }
.section-alt { background: var(--bg-alt); }

/* TYPOGRAPHY */
.section-label {
  display: inline-block;
  font-size: 14px; font-weight: 600; letter-spacing: 1px;
  color: var(--accent); margin-bottom: 14px;
  background: rgba(37,99,235,0.08);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 5px 16px;
  border-radius: 50px;
  border: 1px solid rgba(37,99,235,0.15);
}
.section-title {
  font-size: clamp(30px, 4vw, 42px); font-weight: 700; letter-spacing: -0.5px;
  margin-bottom: 14px; color: var(--text); line-height: 1.15;
}
.section-sub {
  font-size: 16px; color: var(--text-secondary); line-height: 1.7;
  max-width: 560px; font-weight: 400;
}

/* NAV */
.navbar {
  background: rgba(255,255,255,0.9); backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 100;
}
.navbar-inner { max-width: 1100px; margin: 0 auto; padding: 0 24px; height: 56px; display: flex; align-items: center; justify-content: space-between; }
.brand { font-weight: 700; font-size: 18px; color: var(--text); letter-spacing: -0.3px; }
.navbar-nav { display: flex; align-items: center; gap: 2px; }
.navbar-nav a {
  font-size: 15px; font-weight: 500; color: var(--text-secondary);
  padding: 6px 14px; border-radius: 8px; transition: all 0.2s;
}
.navbar-nav a:hover { color: var(--text); background: var(--bg-alt); }
.navbar-nav a.active { color: var(--accent); background: var(--accent-light); }
.navbar-right { display: flex; align-items: center; gap: 12px; }
.btn-nav-cta { background: var(--accent); color: #fff !important; padding: 7px 18px; border-radius: 8px; font-size: 13px; font-weight: 600; }
.lang-btn {
  background: none; border: 1px solid var(--border); border-radius: 8px;
  padding: 5px 12px; font-size: 12px; font-weight: 600; cursor: pointer;
  color: var(--text-secondary); font-family: var(--ff); transition: all 0.2s;
}
.lang-btn:hover { border-color: var(--accent); color: var(--accent); }

/* HERO */
.hero { padding: 80px 0; background: var(--bg); overflow: hidden; }
.hero-inner { max-width: 1100px; margin: 0 auto; padding: 0 24px; display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.hero-text { max-width: 480px; }
.hero-badge {
  font-size: 13px; font-weight: 600; letter-spacing: 1.5px;
  text-transform: uppercase; color: var(--accent); margin-bottom: 20px;
}
.hero h1 { font-size: clamp(34px, 4.5vw, 50px); font-weight: 700; letter-spacing: -0.8px; line-height: 1.08; margin-bottom: 20px; color: var(--text); }
.hero h1 em { color: var(--accent); font-style: normal; }
.hero p { font-size: 17px; color: var(--text-secondary); line-height: 1.8; margin-bottom: 32px; }
.hero-actions { display: flex; gap: 12px; }
.btn-primary { background: var(--accent); color: #fff; padding: 12px 28px; border-radius: 10px; font-size: 14px; font-weight: 600; transition: all 0.2s; display: inline-flex; align-items: center; gap: 6px; }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.btn-outline { border: 1.5px solid var(--border); color: var(--text); padding: 12px 28px; border-radius: 10px; font-size: 14px; font-weight: 500; transition: all 0.2s; }
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.hero-visual { position: relative; width: 100%; height: 400px; }

/* CARDS */
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 48px; }
.pillar-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: 32px 24px; transition: all 0.3s var(--ease); }
.pillar-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); border-color: transparent; }
.pillar-icon { font-size: 24px; font-weight: 700; color: var(--accent); margin-bottom: 14px; }
.pillar-img { margin: -32px -24px 20px -24px; border-radius: 16px 16px 0 0; overflow: hidden; height: 180px; }
.pillar-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pillar-card h3 { font-size: 18px; font-weight: 600; margin-bottom: 8px; color: var(--text); }
.pillar-card p { font-size: 15px; color: var(--text-secondary); line-height: 1.7; }

.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 48px; }
.stat-card { background: var(--bg-card); border-radius: var(--radius-lg); padding: 32px 24px; border: 1px solid var(--border); text-align: center; transition: all 0.3s; }
.stat-card:hover { box-shadow: var(--shadow-lg); border-color: transparent; }
.stat-num { font-size: 36px; font-weight: 700; color: var(--accent); margin-bottom: 4px; }
.stat-label { font-size: 15px; color: var(--text-secondary); font-weight: 500; }

.act-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; margin-top: 48px; }
.act-card { background: rgba(255,255,255,0.6); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255,255,255,0.8); border-radius: var(--radius-lg); padding: 28px 24px; transition: all 0.3s var(--ease); box-shadow: 0 4px 24px rgba(37,99,235,0.04); }
.act-card:hover { box-shadow: 0 8px 32px rgba(37,99,235,0.1); transform: translateY(-4px); border-color: rgba(37,99,235,0.2); background: rgba(255,255,255,0.8); }
.act-num { font-size: 32px; font-weight: 700; color: var(--accent); margin-bottom: 8px; background: linear-gradient(135deg, var(--accent), #60A5FA); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.act-card h3 { font-size: 17px; font-weight: 600; margin-bottom: 8px; color: var(--text); }
.act-card p { font-size: 14px; color: var(--text-secondary); line-height: 1.7; }

/* Act cards with images (about page) */
.act-row { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: center; margin-bottom: 24px; }
.act-row:nth-child(even) .act-card-img { order: 1; }
.act-row:nth-child(even) .act-card { order: 0; }
.act-card-img { border-radius: var(--radius-lg); overflow: hidden; height: 200px; }
.act-card-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.act-row .act-card { margin: 0; }

/* FOOTER */
.footer { background: #0F172A; padding: 48px 0; text-align: center; }
.footer-inner { max-width: 600px; margin: 0 auto; padding: 0 24px; }
.footer h3 { font-size: 14px; font-weight: 600; color: #fff; margin-bottom: 12px; }
.footer h3 span { color: var(--accent); }
.footer p { font-size: 14px; color: rgba(255,255,255,0.5); line-height: 1.8; margin-bottom: 20px; }
.footer-bottom { font-size: 12px; color: rgba(255,255,255,0.25); }

/* SCROLL ANIMATIONS */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.6s, transform 0.6s var(--ease); }
.reveal-left { opacity: 0; transform: translateX(-24px); transition: opacity 0.6s, transform 0.6s var(--ease); }
.reveal-right { opacity: 0; transform: translateX(24px); transition: opacity 0.6s, transform 0.6s var(--ease); }
.reveal.visible, .reveal-left.visible, .reveal-right.visible { opacity: 1; transform: translate(0); }
.stagger > * { opacity: 0; transform: translateY(16px); transition: opacity 0.5s, transform 0.5s var(--ease); }
.stagger.visible > *:nth-child(1) { opacity: 1; transform: translateY(0); transition-delay: 0ms; }
.stagger.visible > *:nth-child(2) { opacity: 1; transform: translateY(0); transition-delay: 100ms; }
.stagger.visible > *:nth-child(3) { opacity: 1; transform: translateY(0); transition-delay: 200ms; }
.stagger.visible > *:nth-child(4) { opacity: 1; transform: translateY(0); transition-delay: 300ms; }
.stagger.visible > *:nth-child(5) { opacity: 1; transform: translateY(0); transition-delay: 400ms; }
.stagger.visible > *:nth-child(6) { opacity: 1; transform: translateY(0); transition-delay: 500ms; }

/* MOBILE */
.menu-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; flex-direction: column; gap: 4px; }
.menu-toggle span { display: block; width: 20px; height: 2px; background: var(--text); border-radius: 2px; transition: all 0.3s; }

@media (max-width: 768px) {
  .menu-toggle { display: flex; }
  .navbar.menu-open { position: fixed; top: 0; left: 0; right: 0; bottom: 0; z-index: 99999; background: rgba(255,255,255,0.98); }
  .navbar.menu-open .navbar-nav { display: flex; flex-direction: column; position: absolute; top: 56px; left: 0; right: 0; padding: 16px 24px; gap: 2px; }
  .navbar.menu-open .navbar-nav a { font-size: 16px; padding: 12px 16px; width: 100%; border-radius: 10px; }
  .navbar.menu-open .menu-toggle span:nth-child(1) { transform: rotate(45deg) translate(4px, 4px); }
  .navbar.menu-open .menu-toggle span:nth-child(2) { opacity: 0; }
  .navbar.menu-open .menu-toggle span:nth-child(3) { transform: rotate(-45deg) translate(4px, -4px); }
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .hero h1 { font-size: 30px; }
  .hero-visual { height: 280px; }
  .act-row { grid-template-columns: 1fr; }
  .pillars, .stats-grid, .act-grid { grid-template-columns: 1fr; }
  [style*="grid-template-columns:repeat(4,1fr)"] { grid-template-columns: repeat(2,1fr) !important; }
  .navbar-nav { display: none; }
  .section { padding: 48px 0; }
}
