/* ===== 光隱閣 共用 CSS ===== */
:root {
  --bg: #06080c;
  --bg-2: #0a0d14;
  --panel: rgba(255,255,255,0.05);
  --panel-2: rgba(255,255,255,0.03);
  --line: rgba(255,255,255,0.1);
  --text: #f4efe7;
  --muted: rgba(244,239,231,0.68);
  --gold: #d4a55c;
  --gold-soft: rgba(212,165,92,0.16);
  --cyan: #73d6ff;
  --cyan-soft: rgba(115,214,255,0.16);
  --white-soft: rgba(255,255,255,0.08);
  --radius: 28px;
  --shadow: 0 30px 120px rgba(0,0,0,0.32);
  --max: 1240px;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "PingFang TC", "Microsoft JhengHei", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 12% 10%, rgba(212,165,92,0.11), transparent 24%),
    radial-gradient(circle at 88% 14%, rgba(115,214,255,0.10), transparent 26%),
    radial-gradient(circle at 50% 100%, rgba(255,255,255,0.05), transparent 32%),
    var(--bg);
  min-height: 100vh;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed; inset: 0;
  background:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: radial-gradient(circle at center, black 0%, black 52%, transparent 86%);
  pointer-events: none; opacity: .5;
}
a { color: inherit; text-decoration: none; }
.shell { width: min(var(--max), calc(100vw - 40px)); margin: 0 auto; }

/* ===== 導覽列 ===== */
.topbar {
  position: sticky; top: 0; z-index: 500;
  backdrop-filter: blur(18px);
  background: rgba(7,10,16,0.92);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.topbar-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  padding: 14px 0;
}
.brand { display:flex; align-items:center; gap:12px; min-width: 0; flex: 0 0 auto; }
.brand-badge {
  width: 40px; height: 40px; border-radius: 14px;
  border: 1px solid rgba(212,165,92,0.2);
  background: rgba(212,165,92,0.1);
  display:grid; place-items:center; color:#efcd96; flex: 0 0 auto;
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
  font-size: 18px;
}
.brand-title { font-size: 16px; font-weight: 700; letter-spacing: .18em; }
.brand-sub { font-size: 11px; color: rgba(255,255,255,0.4); margin-top: 2px; }
.brand-name-text { font-size: 22px; font-weight: 700; color: rgba(255,255,255,0.92); letter-spacing: 0.12em; white-space: nowrap; line-height: 1.2; }
.brand-action-text { font-size: 11px; color: rgba(255,255,255,0.5); letter-spacing: 0.08em; font-weight: 500; white-space: nowrap; line-height: 1.3; }
.brand-tagline-text { font-size: 10px; color: rgba(212,165,92,0.75); letter-spacing: 0.1em; font-weight: 400; white-space: nowrap; line-height: 1.3; }
.nav { display:flex; align-items:center; gap: 2px; flex-wrap: nowrap; }
.nav a {
  padding: 9px 12px; border-radius: 999px; color: rgba(255,255,255,0.72); font-size: 14px;
  transition: .2s ease; white-space: nowrap;
}
.nav a:hover, .nav a.active { background: rgba(255,255,255,0.08); color: white; }
.header-actions { display:flex; align-items:center; gap: 8px; flex: 0 0 auto; }

/* ===== 漢堡選單按鈕 ===== */
.hamburger {
  display: none;
  flex-direction: column; justify-content: center; align-items: center; gap: 5px;
  width: 40px; height: 40px; border-radius: 12px; cursor: pointer;
  background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1);
  transition: .2s ease; flex: 0 0 auto;
}
.hamburger:hover { background: rgba(255,255,255,0.1); }
.hamburger span {
  display: block; width: 20px; height: 2px;
  background: rgba(255,255,255,0.8); border-radius: 2px;
  transition: .25s ease;
}
.hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== 手機版側拉選單 ===== */
.mobile-menu {
  display: none;
  position: fixed; top: 0; right: 0; bottom: 0; width: min(300px, 85vw);
  background: rgba(7,10,16,0.97); backdrop-filter: blur(24px);
  border-left: 1px solid rgba(255,255,255,0.08);
  z-index: 490; padding: 80px 28px 120px;
  flex-direction: column; gap: 6px;
  transform: translateX(100%); transition: transform .3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
}
.mobile-menu.open {
  display: flex;
  transform: translateX(0);
}
.mobile-menu a {
  padding: 14px 18px; border-radius: 14px; font-size: 16px; font-weight: 600;
  color: rgba(255,255,255,0.8); transition: .18s ease;
  border: 1px solid transparent;
}
.mobile-menu a:hover, .mobile-menu a.active {
  background: rgba(255,255,255,0.06); color: white;
  border-color: rgba(255,255,255,0.08);
}
.mobile-menu .mobile-divider {
  height: 1px; background: rgba(255,255,255,0.08); margin: 12px 0;
}
.mobile-menu .mobile-cta {
  margin-top: 16px; padding: 16px 18px; border-radius: 16px; text-align: center;
  background: linear-gradient(135deg, #d4a55c, #f1d3a4); color: #1a1200;
  font-weight: 800; font-size: 15px; border: none;
}
.mobile-overlay {
  display: none; position: fixed; inset: 0; z-index: 480;
  background: rgba(0,0,0,0.6); backdrop-filter: blur(2px);
}
.mobile-overlay.open { display: block; }

/* ===== 音樂按鈕 ===== */
.music-btn {
  position: fixed; bottom: 76px; left: 16px; z-index: 450;
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(10,13,20,0.88); border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.65); font-size: 18px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: .2s ease; backdrop-filter: blur(12px);
  box-shadow: 0 4px 20px rgba(0,0,0,0.4);
}
.music-btn:hover { background: rgba(212,165,92,0.15); border-color: rgba(212,165,92,0.4); color: #e5c189; }
.music-btn.playing { color: #e5c189; border-color: rgba(212,165,92,0.4); background: rgba(212,165,92,0.1); }

/* ===== 按鈕 ===== */
.btn {
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  padding: 13px 22px; border-radius: 18px; border: 1px solid transparent;
  font-weight: 700; font-size: 14px; transition: .18s ease; cursor: pointer;
  text-decoration: none; white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }
.btn-gold { background: linear-gradient(135deg, #d4a55c, #f1d3a4); color: #1a1200; border: none; }
.btn-gold:hover { box-shadow: 0 8px 28px rgba(212,165,92,0.38); }
.btn-secondary { background: rgba(255,255,255,0.04); color: rgba(255,255,255,0.9); border-color: rgba(255,255,255,0.1); }
.btn-ghost { background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.85); border-color: rgba(255,255,255,0.08); }
.btn-cyan { background: linear-gradient(135deg, #38bdf8, #73d6ff); color: #001a2e; border: none; }
.btn-cyan:hover { box-shadow: 0 8px 28px rgba(115,214,255,0.35); }
.btn-outline-gold { background: transparent; color: #e7c489; border-color: rgba(212,165,92,0.4); }
.btn-outline-gold:hover { background: rgba(212,165,92,0.1); }
.btn-lg { padding: 17px 32px; font-size: 16px; border-radius: 22px; }

/* ===== 通用版面 ===== */
section { padding: 80px 0; position: relative; }
.section-head { max-width: 820px; }
.badge {
  display:inline-flex; align-items:center; gap: 10px; padding: 9px 14px; border-radius: 999px;
  background: rgba(212,165,92,0.1); border:1px solid rgba(212,165,92,0.2);
  color: #e5c189; font-size: 12px; letter-spacing: .22em; text-transform: uppercase;
}
.badge-cyan { background: rgba(115,214,255,0.1); border-color: rgba(115,214,255,0.2); color: #8de4ff; }
.badge-purple { background: rgba(167,139,250,0.1); border-color: rgba(167,139,250,0.2); color: #c4b5fd; }
h1 { font-size: clamp(38px, 6vw, 88px); line-height: 1.05; letter-spacing: -0.03em; font-weight: 800; }
h2 { margin: 18px 0 0; font-size: clamp(26px, 4vw, 52px); line-height: 1.1; letter-spacing: -0.03em; }
h3 { font-size: 22px; }
.section-desc { margin-top: 16px; font-size: 18px; line-height: 1.85; color: var(--muted); }
.card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: var(--radius);
  backdrop-filter: blur(12px);
  padding: 28px;
}
.card h3 { margin: 18px 0 0; }
.card p { margin: 14px 0 0; color: rgba(255,255,255,0.65); line-height: 1.85; font-size: 15px; }
.iconbox {
  width: 48px; height: 48px; border-radius: 16px; display:grid; place-items:center;
  border:1px solid rgba(212,165,92,0.18); background: rgba(212,165,92,0.1); color:#e7c795;
  font-size: 18px;
}
.grid-4 { display:grid; gap: 16px; grid-template-columns: repeat(4,minmax(0,1fr)); margin-top: 30px; }
.grid-3 { display:grid; gap: 16px; grid-template-columns: repeat(3,minmax(0,1fr)); margin-top: 30px; }
.grid-2 { display:grid; gap: 16px; grid-template-columns: repeat(2,minmax(0,1fr)); margin-top: 30px; }
.cta-row { display:flex; gap: 14px; flex-wrap: wrap; margin-top: 36px; }
.divider { height: 1px; background: var(--line); margin: 0; }

/* ===== 浮動底部按鈕 ===== */
.float-bar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 400;
  display: flex;
  background: rgba(7,10,16,0.95);
  backdrop-filter: blur(18px);
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}
.float-bar a {
  flex: 1; display:flex; align-items:center; justify-content:center; gap: 8px;
  padding: 14px 12px; font-size: 14px; font-weight: 700; color: var(--text);
  transition: .18s ease; min-height: 52px;
}
.float-bar a:first-child { border-right: 1px solid rgba(255,255,255,0.08); }
.float-bar a:hover { background: rgba(255,255,255,0.04); }
.float-bar .dot { width: 8px; height: 8px; border-radius: 50%; background: #22c55e; box-shadow: 0 0 8px rgba(34,197,94,0.6); flex: 0 0 auto; }

/* ===== Footer ===== */
.footer {
  background: rgba(0,0,0,0.4);
  border-top: 1px solid rgba(255,255,255,0.08);
  padding: 60px 0 120px;
}
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px;
}
.footer-brand-title { font-size: 18px; font-weight: 700; letter-spacing: .18em; margin-bottom: 12px; }
.footer-brand-desc { font-size: 14px; color: rgba(255,255,255,0.45); line-height: 1.8; max-width: 280px; }
.footer-col h4 { font-size: 13px; letter-spacing: .18em; text-transform: uppercase; color: rgba(255,255,255,0.4); margin-bottom: 16px; }
.footer-col a { display: block; font-size: 14px; color: rgba(255,255,255,0.65); margin-bottom: 10px; transition: .18s; }
.footer-col a:hover { color: #d4a55c; }
.footer-bottom { margin-top: 40px; padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.06); }
.footer-bottom p { font-size: 13px; color: rgba(255,255,255,0.28); line-height: 1.8; }

/* ===== 動畫 ===== */
@keyframes floatY { 0%,100%{transform:translateY(-50%) translateY(0)} 50%{transform:translateY(-50%) translateY(-18px)} }
@keyframes pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:.6;transform:scale(.88)} }
@keyframes fadeInUp { from{opacity:0;transform:translateY(24px)} to{opacity:1;transform:translateY(0)} }
.fade-in { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* ===== 桌面版：隱藏漢堡 ===== */
@media (min-width: 901px) {
  .hamburger { display: none !important; }
  .mobile-menu, .mobile-overlay { display: none !important; }
  .header-actions { display: flex; }
}

/* ===== 平板/手機版 ===== */
@media (max-width: 900px) {
  .nav { display: none; }
  .header-actions { display: none; }
  .hamburger { display: flex; }
  .grid-4 { grid-template-columns: repeat(2,1fr); }
  .grid-3 { grid-template-columns: repeat(2,1fr); }
  .grid-2 { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .cta-row { flex-direction: column; }
  .cta-row .btn { width: 100%; justify-content: center; }
  .section-desc { font-size: 16px; }
}

/* ===== 手機版（小螢幕）===== */
@media (max-width: 600px) {
  h1 { font-size: clamp(32px, 9vw, 44px); }
  h2 { font-size: clamp(24px, 7vw, 34px); }
  h3 { font-size: 18px; }
  section { padding: 52px 0; }
  .shell { width: calc(100vw - 32px); }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .footer { padding: 48px 0 120px; }
  .grid-4, .grid-3 { grid-template-columns: 1fr; }
  .card { padding: 20px; }
  .btn-lg { padding: 15px 24px; font-size: 15px; }
  .badge { font-size: 11px; padding: 8px 12px; }
  .music-btn { bottom: 72px; left: 12px; width: 40px; height: 40px; font-size: 16px; }
  .float-bar a { font-size: 13px; padding: 12px 8px; }
}
