/* ============================================================
  📁 LIUQU 琉急式 - 模块化 CSS
  ============================================================ */

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 📌 1️⃣ 基础重置与全局样式
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --nav-h: 80px;
  --marquee-h: 42px;
  --primary-green: #006a94;
  --primary-teal: #006a94;
  --primary-blue: #0583cc;
  --accent-gold: #ffd700;
  --text-white: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.95);
}

html, body {
  width: 100%;
  overflow-x: hidden;
}

body {
  font-family: "Noto Sans TC", sans-serif;
  background: #637281;
  color: white;
  position: relative;
  padding-top: calc(var(--nav-h) + var(--marquee-h) + 10px);
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 🎬 2️⃣ 背景与动画层
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.custom-photo-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -4;
  background-image: url('圖片/IMG_1606.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 1;
  transition: opacity 0.9s ease;
  filter: saturate(1.05) brightness(0.9);
}

.custom-photo-background.is-hidden {
  opacity: 0;
}

.ocean-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -3;
  display: block !important;
  opacity: 1 !important;
  background: linear-gradient(
    180deg,
    rgba(5, 23, 44, 0.60) 0%,
    rgba(8, 46, 78, 0.52) 25%,
    rgba(8, 84, 134, 0.44) 55%,
    rgba(17, 125, 181, 0.34) 75%,
    rgba(75, 186, 227, 0.22) 100%
  ) !important;
}

.wave-layer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -2;
  display: block !important;
  opacity: 0.9 !important;
}

.wave-layer::before,
.wave-layer::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 200%;
  height: 100%;
  display: block !important;
}

.wave-layer::before {
  background:
    radial-gradient(circle at 15% 25%, rgba(255,255,255,0.08) 0 2px, transparent 3px),
    radial-gradient(circle at 45% 60%, rgba(255,255,255,0.05) 0 2px, transparent 3px),
    radial-gradient(circle at 75% 35%, rgba(125, 249, 255, 0.08) 0 2px, transparent 3px),
    linear-gradient(180deg, transparent 0%, rgba(255,255,255,0.03) 100%);
  background-size: 160px 160px, 240px 240px, 190px 190px, 100% 100%;
  animation: liuqiuWaveFlowA 20s linear infinite;
}

.wave-layer::after {
  background:
    radial-gradient(circle at 20% 75%, rgba(138, 236, 255, 0.09) 0 2px, transparent 3px),
    radial-gradient(circle at 65% 25%, rgba(255,255,255,0.07) 0 2px, transparent 3px),
    radial-gradient(circle at 88% 70%, rgba(67, 222, 255, 0.07) 0 2px, transparent 3px);
  background-size: 200px 200px, 280px 280px, 220px 220px;
  animation: liuqiuWaveFlowB 28s linear infinite reverse;
  opacity: 0.78;
}

@keyframes liuqiuWaveFlowA {
  0% {
    transform: translateX(0) translateY(0);
  }
  50% {
    transform: translateX(-12%) translateY(2.5%);
  }
  100% {
    transform: translateX(-24%) translateY(0);
  }
}

@keyframes liuqiuWaveFlowB {
  0% {
    transform: translateX(0) translateY(0);
  }
  50% {
    transform: translateX(-10%) translateY(-2%);
  }
  100% {
    transform: translateX(-20%) translateY(1.2%);
  }
}

@keyframes oceanFlow {
  0% { transform: translateX(0) translateY(0); }
  33% { transform: translateX(-10%) translateY(5%); }
  66% { transform: translateX(-20%) translateY(-3%); }
  100% { transform: translateX(-30%) translateY(2%); }
}

.island-overlay {
  position: fixed;
  bottom: -10%;
  right: -5%;
  width: 400px;
  height: 300px;
  z-index: -1;
  opacity: 0.12;
  display: block !important;
  transform: rotate(-15deg);
  animation: islandFloat 20s ease-in-out infinite;
}

.island-overlay::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  background: radial-gradient(ellipse at center,
   rgba(34, 139, 34, 0.8) 0%,
   rgba(34, 139, 34, 0.6) 30%,
   rgba(139, 69, 19, 0.4) 50%,
   rgba(255, 218, 185, 0.3) 70%,
   transparent 100%
  );
  border-radius: 60% 40% 70% 30%;
  filter: blur(2px);
}

@keyframes islandFloat {
  0%, 100% {
   transform: rotate(-15deg) translateY(0);
   opacity: 0.15;
  }
  50% {
   transform: rotate(-12deg) translateY(-20px);
   opacity: 0.25;
  }
}

.boat-trail {
  position: fixed;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: -1;
  pointer-events: none;
  display: block !important;
  opacity: 0.85;
}

.boat {
  position: absolute;
  width: 6px;
  height: 3px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 50% 50% 0 0;
  animation: boatPath1 40s linear infinite;
  display: block !important;
  filter: blur(0.2px);
}

.boat:nth-child(2) {
  animation: boatPath2 45s linear infinite;
  animation-delay: -15s;
  background: rgba(99, 230, 190, 0.4);
}

.boat:nth-child(3) {
  animation: boatPath3 35s linear infinite;
  animation-delay: -25s;
  background: rgba(250, 82, 82, 0.4);
}

.boat::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 50%;
  transform: translateX(-50%);
  width: 2px;
  height: 20px;
  background: linear-gradient(to bottom, rgba(255, 255, 255, 0.3), transparent);
  border-radius: 0 0 50% 50%;
}

@keyframes boatPath1 {
  0% { top: 80%; left: -5%; transform: rotate(45deg); }
  25% { top: 60%; left: 30%; transform: rotate(0deg); }
  50% { top: 40%; left: 70%; transform: rotate(-30deg); }
  75% { top: 60%; left: 90%; transform: rotate(-60deg); }
  100% { top: 80%; left: 105%; transform: rotate(-90deg); }
}

@keyframes boatPath2 {
  0% { top: 70%; left: 105%; transform: rotate(-135deg); }
  25% { top: 50%; left: 70%; transform: rotate(-180deg); }
  50% { top: 30%; left: 40%; transform: rotate(150deg); }
  75% { top: 50%; left: 10%; transform: rotate(90deg); }
  100% { top: 70%; left: -5%; transform: rotate(45deg); }
}

@keyframes boatPath3 {
  0% { top: 90%; left: 50%; transform: rotate(0deg); }
  30% { top: 20%; left: 80%; transform: rotate(-45deg); }
  60% { top: 30%; left: 20%; transform: rotate(180deg); }
  100% { top: 90%; left: 50%; transform: rotate(360deg); }
}

.seagulls {
  position: fixed;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  z-index: -1;
  pointer-events: none;
  display: block !important;
  opacity: 0.95;
}

.seagull {
  position: absolute;
  color: rgba(255, 255, 255, 0.4);
  font-size: 12px;
  animation: seagullFly 25s linear infinite;
  display: block !important;
}

.seagull:nth-child(1) {
  top: 20%;
  animation-delay: 0s;
  font-size: 10px;
}

.seagull:nth-child(2) {
  top: 25%;
  animation-delay: -8s;
  font-size: 14px;
}

.seagull:nth-child(3) {
  top: 30%;
  animation-delay: -15s;
  font-size: 11px;
}

@keyframes seagullFly {
  0% {
   left: -10%;
   transform: translateY(0) scale(1);
   opacity: 0;
  }
  10% { opacity: 0.4; }
  50% {
   transform: translateY(-20px) scale(1.2);
   opacity: 0.6;
  }
  90% { opacity: 0.4; }
  100% {
   left: 110%;
   transform: translateY(10px) scale(0.8);
   opacity: 0;
  }
}

.sunlight {
  position: fixed;
  top: 10%;
  right: 20%;
  width: 200px;
  height: 200px;
  background: radial-gradient(circle,
   rgba(255, 255, 255, 0.1) 0%,
   rgba(255, 255, 0, 0.05) 30%,
   transparent 70%
  );
  border-radius: 50%;
  z-index: -2;
  opacity: 0.55;
  display: block !important;
  filter: blur(2px);
  animation: sunGlimmer 8s ease-in-out infinite;
}

@keyframes sunGlimmer {
  0%, 100% {
   transform: scale(1);
   opacity: 0.3;
  }
  50% {
   transform: scale(1.2);
   opacity: 0.1;
  }
}

.particles {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1;
  display: block !important;
  opacity: 1 !important;
}

.particle {
  position: absolute;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  animation: float 6s ease-in-out infinite;
  display: block !important;
}

.particle:nth-child(1) { width: 6px; height: 6px; left: 10%; animation-delay: 0s; }
.particle:nth-child(2) { width: 8px; height: 8px; left: 20%; animation-delay: 1s; }
.particle:nth-child(3) { width: 4px; height: 4px; left: 30%; animation-delay: 2s; }
.particle:nth-child(4) { width: 10px; height: 10px; left: 40%; animation-delay: 0.5s; }
.particle:nth-child(5) { width: 6px; height: 6px; left: 50%; animation-delay: 1.5s; }
.particle:nth-child(6) { width: 8px; height: 8px; left: 60%; animation-delay: 2.5s; }
.particle:nth-child(7) { width: 5px; height: 5px; left: 70%; animation-delay: 0.8s; }
.particle:nth-child(8) { width: 7px; height: 7px; left: 80%; animation-delay: 1.8s; }
.particle:nth-child(9) { width: 4px; height: 4px; left: 90%; animation-delay: 3s; }

@keyframes float {
  0%, 100% { transform: translateY(100vh) rotate(0deg); opacity: 0; }
  10% { opacity: 1; }
  90% { opacity: 1; }
  100% { transform: translateY(-100vh) rotate(360deg); opacity: 0; }
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 🧭 3️⃣ 导航栏与顶部UI
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

#nav-fixed {
    display: flex;
  justify-content: space-between;
  align-items: center;
  background: rgba(0, 0, 0, 0.1);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1rem 2rem;
  position: fixed;
  top: 0;
  width: 100%;
  height: var(--nav-h);
  z-index: 9999;
  transition: all 0.3s ease;
}

#nav-fixed.scrolled {
    background: linear-gradient(to right, rgba(0, 51, 102, 0.7), #006994);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.nav-left img {
  height: 55px;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3));
  transition: transform 0.3s ease;
}

.nav-left img:hover {
  transform: scale(1.05);
}

.nav-right {
  display: flex;
  gap: 2rem;
}

.nav-right a {
  color: white;
  text-decoration: none;
  font-weight: 500;
  font-size: 1.1rem;
  padding: 0.5rem 1rem;
  border-radius: 25px;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.nav-right a::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.nav-right a:hover::before {
  left: 100%;
}

.nav-right a:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

[id] { scroll-margin-top: calc(var(--nav-h) + 12px); }

.marquee-pill {
  position: fixed;
  top: var(--nav-h);
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: min(900px, 92vw);
  padding: 0 12px;
  overflow: hidden;
  box-sizing: border-box;
  z-index: 999;
}

/* =========================================================
   🛠️ Safari 專用跑馬燈修復補丁
   ========================================================= */

/* 1. 頂部公告跑馬燈 Safari 修復 */
.marquee-track {
  display: inline-block;
  white-space: nowrap;
  will-change: transform;
  /* 強制 Safari 開啟 GPU 加速 */
  -webkit-transform: translate3d(0, 0, 0);
  transform: translate3d(0, 0, 0);
  -webkit-animation: marquee-slide 18s linear infinite;
  animation: marquee-slide 18s linear infinite;
}

/* 2. 使用者評論跑馬燈 Safari 修復 */
.reviews-34-mask {
  overflow: hidden;
  position: relative;
  /* Safari 對 mask-image 非常挑剔，必須加前綴且確保黑色區域正確 */
  -webkit-mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
  mask-image: linear-gradient(to right, transparent, black 10%, black 90%, transparent);
}

.reviews-34-track {
  display: -webkit-inline-box; /* Safari 舊版相容 */
  display: inline-flex;
  gap: 24px;
  will-change: transform;
  /* 強制 Safari 開啟 GPU 加速 */
  -webkit-transform: translate3d(0, 0, 0);
  transform: translate3d(0, 0, 0);
  -webkit-animation: reviews34-slide 36s linear infinite;
  animation: reviews34-slide 36s linear infinite;
}

/* 3. Safari 專用 Keyframes 補丁 */
@-webkit-keyframes marquee-slide {
  0%   { -webkit-transform: translate3d(0, 0, 0); }
  100% { -webkit-transform: translate3d(-50%, 0, 0); }
}

@keyframes marquee-slide {
  0%   { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-50%, 0, 0); }
}

@-webkit-keyframes reviews34-slide {
  0%   { -webkit-transform: translate3d(0, 0, 0); }
  100% { -webkit-transform: translate3d(-50%, 0, 0); }
}

@keyframes reviews34-slide {
  0%   { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-50%, 0, 0); }
}

/* 修正 Safari 下可能導致內容消失的隱藏屬性 */
.marquee-track *, .reviews-34-track * {
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 📝 4️⃣ 标题与文字样式
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

h1 {
  font-size: 3.5rem;
  font-weight: 900;
  margin-bottom: 2rem;
  background: linear-gradient(135deg, #fff 0%, #63e6be 50%, #12b886 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  letter-spacing: 2px;
  position: relative;
  animation: glow 2s ease-in-out infinite alternate;
}

@keyframes glow {
  from { filter: drop-shadow(0 0 20px rgba(99, 230, 190, 0.3)); }
  to { filter: drop-shadow(0 0 40px rgba(99, 230, 190, 0.6)); }
}

.festival-title {
  font-size: 2rem;
  font-weight: 900;
  background: linear-gradient(135deg, #ffd700 0%, #ff8800 40%, #cc0000 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: #ffd700;
  background-clip: text;
  text-shadow:
   0 2px 4px rgba(255, 0, 0, 0.6),
   0 0 8px rgba(255, 0, 0, 0.7),
   0 0 16px rgba(255, 128, 0, 0.6),
   0 0 24px rgba(255, 215, 0, 0.8);
  animation: templeGlow 2.5s ease-in-out infinite alternate;
}

@keyframes templeGlow {
  0% {
   text-shadow:
    0 2px 4px rgb(255, 0, 0),
    0 0 8px rgba(255, 0, 0, 0.8),
    0 0 16px rgba(255, 128, 0, 0.7),
    0 0 24px rgba(255, 215, 0, 0.9);
   transform: scale(1);
  }
  50% {
   text-shadow:
    0 2px 6px rgba(255, 0, 0, 0.7),
    0 0 12px rgba(255, 69, 0, 1),
    0 0 20px rgba(255, 140, 0, 0.9),
    0 0 32px rgba(255, 215, 0, 1);
   transform: scale(1.05) rotate(-1deg);
  }
  100% {
   text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.6),
    0 0 10px rgba(255, 0, 0, 0.8),
    0 0 18px rgba(255, 128, 0, 0.7),
    0 0 28px rgba(255, 215, 0, 0.9);
   transform: scale(1);
  }
}

.festival-title-blue {
  font-size: 3rem;
  font-weight: 900;
  background: linear-gradient(135deg, #bfe9ff 0%, #3aa8ff 45%, #0047b3 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: #bfe9ff;
  background-clip: text;
  text-shadow:
   0 2px 4px rgba(0, 0, 0, 0.45),
   0 0 8px rgba(58, 168, 255, 0.7),
   0 0 16px rgba(10, 120, 255, 0.55),
   0 0 24px rgba(0, 71, 179, 0.6);
  animation: templeGlowBlue 2.5s ease-in-out infinite alternate;
}

@keyframes templeGlowBlue {
  0% {
   text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.45),
    0 0 8px rgba(58, 168, 255, 0.8),
    0 0 16px rgba(10, 120, 255, 0.65),
    0 0 24px rgba(0, 71, 179, 0.7);
   transform: scale(1);
  }
  50% {
   text-shadow:
    0 2px 6px rgba(0, 0, 0, 0.55),
    0 0 12px rgba(30, 144, 255, 1),
    0 0 20px rgba(3, 105, 201, 0.95),
    0 0 32px rgba(0, 55, 145, 0.95);
   transform: scale(1.05) rotate(-1deg);
  }
  100% {
   text-shadow:
    0 2px 4px rgba(0, 0, 0, 0.45),
    0 0 10px rgba(58, 168, 255, 0.8),
    0 0 18px rgba(10, 120, 255, 0.65),
    0 0 28px rgba(0, 71, 179, 0.75);
   transform: scale(1);
  }
}

.hero-section {
  max-width: 800px;
  animation: fadeInUp 1s ease-out;
}

@keyframes fadeInUp {
  from {
   opacity: 0;
   transform: translateY(50px);
  }
  to {
   opacity: 1;
   transform: translateY(0);
  }
}

.hero-title {
  font-size: clamp(2.2rem, 4.2vw, 3.6rem);
  font-weight: 900;
  margin: 0 0 0.45rem 0;
  background: linear-gradient(135deg, #ffffff 0%, #63e6be 50%, #12b886 100%);
  -webkit-text-fill-color: transparent;
  letter-spacing: 1.6px;
}

.hero-sub {
  margin: 0 0 0.6rem 0;
  font-size: clamp(0.95rem, 1.25vw, 1.05rem);
  color: rgba(255, 255, 255, 0.95);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.subtitle {
  font-size: 1.1rem;
  margin-bottom: 2rem;
}

.reviews-34-marquee h1 {
  font-size: 3rem;
  font-weight: 900;
  text-align: center;
  margin-bottom: 2rem;
  background: linear-gradient(135deg, #ffffff 0%, #f0f8ff 40%, #e0f0ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  text-shadow:
   0 2px 8px rgba(255, 255, 255, 0.4),
   0 0 16px rgba(255, 255, 255, 0.2);
  filter: blur(0.8px);
  transition: filter 0.3s ease;
}

.reviews-34-marquee h1:hover {
  filter: blur(0);
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 🎯 5️⃣ 按钮基础样式与主题
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.btn-group {
  display: flex;
  gap: 2rem;
  flex-wrap: wrap;
  justify-content: center;
  animation: fadeInUp 1s ease-out 0.6s both;
}

.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  width: min(82vw, 320px);
  min-height: 56px;
  padding: 0.9rem 1.4rem;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;
  color: #fff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  transition: all 0.18s ease;
  text-shadow: none;
  border: 1px solid rgba(0, 0, 0, 0.1);
}

.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: none;
  transition: none;
}

.btn:hover::before {
  left: 120%;
}

.btn-icon {
  margin-right: 0.5rem;
  font-size: 1.2rem;
  transition: none;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 🎨 6️⃣ 按钮颜色主题
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.btn.primary {
  background: #27ae60;
  color: #fff;
  border: none;
}

.btn.primary:hover {
  background: #229954;
}

.btn.secondary {
  position: relative;
  overflow: hidden;
  border: 2px solid #3498db;
  background: #3498db;
  z-index: 1;
}

.btn.secondary .btn-icon,
.btn.secondary span {
  position: relative;
  z-index: 5;
}

.btn.secondary:hover {
  background: #2980b9;
  border-color: #2980b9;
}

.btn.secondary:hover .shine {
  left: 120%;
}

.btn.live {
  background: #3498db;
}

.btn.live:hover {
  background: #2980b9;
}

.btn.liv {
  background: #f39c12;
}

.btn.liv:hover {
  background: #e67e22;
}

.btn.GOGO {
  background: #e74c3c;
}

.btn.GOGO:hover {
  background: #c0392b;
}

.btn.mm { background: #f39c12; }
.btn.mm:hover { background: #e67e22; }

.btn.rr { background: #e67e22; }
.btn.rr:hover { background: #d35400; }

.btn.gg { background: #f39c12; }
.btn.gg:hover { background: #e67e22; }

.btn.oo { background: #e74c3c; }
.btn.oo:hover { background: #c0392b; }

.btn.LOLO { background: #1abc9c; }
.btn.LOLO:hover { background: #16a085; }

.btn.OO { background: #8e44ad; }
.btn.OO:hover { background: #7d3c98; }

.btn.kk { background: #2c3e50; color: #ffffff; }
.btn.kk:hover { background: #1a252f; }

.btn.SOSO { background: #3498db; }
.btn.SOSO:hover { background: #2980b9; }

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 🖼️ 7️⃣ 特殊按钮样式（背景图片、Emoji等）
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.btn.pp {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.7rem;
  border: 1px solid rgba(0, 0, 0, 0.1);
  overflow: hidden;
  backdrop-filter: none;
  text-shadow: none;
  transition: all 0.18s ease;
  z-index: 0;
  background: #34495e;
}

.btn.pp::before {
  content: "";
  position: absolute;
  inset: 0;
  background: none;
  filter: none;
  z-index: -1;
  transition: none;
  border-radius: inherit;
}

.btn.pp:hover {
  background: #2c3e50;
  transform: translateY(-2px);
}

.btn.pp:hover::before {
  filter: none;
  transform: none;
}

.btn.pp > * {
  position: relative;
  z-index: 1;
}

.btn.pp .btn-icon {
  font-size: 1.2em;
}

.btn.qq {
  position: relative;
  overflow: hidden;
  z-index: 1;
  background: #9b59b6;
  border: 1px solid rgba(0, 0, 0, 0.1);
  color: #ffffff;
}

.btn.qq::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: none;
  background-size: none;
  background-repeat: none;
  opacity: 0;
  animation: none;
  z-index: -1;
}

.btn.qq:hover {
  background: #8e44ad;
  transform: translateY(-2px);
}

@keyframes emojiMove {
  0% { background-position: 0 0; }
  100% { background-position: 600px 600px; }
}

.btn.ll {
  position: relative;
  overflow: hidden;
  z-index: 1;
  padding: 0.9rem 1.4rem;
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: 0px;
  color: #ffffff;
  background: #e74c3c;
  border: 1px solid rgba(0, 0, 0, 0.1);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  transition: all 0.18s ease;
}

.btn.ll::before {
  content: "";
  position: absolute;
  inset: -30%;
  z-index: -1;
  background: none;
  opacity: 0;
}

.btn.ll:hover {
  background: #c0392b;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn.aed {
  position: relative;
  overflow: hidden;
  z-index: 1;
  background: #e74c3c;
  border: 1px solid rgba(0, 0, 0, 0.1);
  color: #ffffff;
}

.btn.aed::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: none;
  background-size: none;
  background-repeat: none;
  opacity: 0;
  animation: none;
  z-index: -1;
}

@keyframes aedBgMove {
  0% { background-position: 0 0; }
  100% { background-position: 600px 600px; }
}

.btn.aed:hover {
  background: #c0392b;
  transform: translateY(-2px);
}

.btn.ss {
  position: relative;
  overflow: hidden;
  background: #2c3e50;
  color: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.1);
  z-index: 3;
}

.btn.ss .star {
  position: absolute;
  width: 4px;
  height: 4px;
  background: none;
  border-radius: 50%;
  opacity: 0;
  z-index: 1;
  animation: none;
}

@keyframes twinkle {
  0%, 100% { opacity: 0.2; transform: scale(0.8); filter: brightness(1); }
  40% { opacity: 1; transform: scale(1.4); filter: brightness(2) drop-shadow(0 0 8px #fff); }
  70% { opacity: 0.5; transform: scale(1); filter: brightness(1.3); }
}

/* =========================================================
   🔒 琉急式 - 統一封鎖規格（含紅色警告動畫版）
   ========================================================= */

/* 1. 定義動畫：呼吸與紅色警告 */
@keyframes lockBreath {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(1.05); }
}

@keyframes redLockAlert {
  0%, 100% { 
    box-shadow: 0 4px 10px rgba(0,0,0,0.2); 
    transform: scale(1);
    border-color: #a0a8b0;
  }
  50% { 
    box-shadow: 0 0 25px rgba(255, 50, 50, 0.6), inset 0 0 10px rgba(255, 50, 50, 0.4); 
    transform: scale(1.03); 
    border-color: rgba(255, 50, 50, 0.8);
  }
}

/* 2. 封鎖效果主體：ID 卡片與 hh 類別 */
#bus-card, #fishing-card, #drone-card, .app-card.hh {
  position: relative !important;
  pointer-events: auto !important;
  cursor: not-allowed !important;
  overflow: hidden !important;
  aspect-ratio: 1 / 1 !important; /* 強制正方形 */
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px !important;
  
  /* 基礎視覺：灰色、無動畫 */
  background: linear-gradient(145deg, #7f8a96, #6a7580) !important;
  border: 1px solid #a0a8b0 !important;
  filter: grayscale(100%) brightness(0.8);
  animation: none !important; /* 🚫 移除平常的漂浮動畫 */
  text-decoration: none !important;
  transition: all 0.2s ease;
}

/* 3. 🔥 滑鼠觸碰時：觸發紅色警告動畫 */
#bus-card:hover, 
#fishing-card:hover, 
#drone-card:hover, 
.app-card.hh:hover {
  background: #1a1a1a !important; /* 背景變深讓紅光更明顯 */
  animation: redLockAlert 0.6s ease-in-out infinite !important; /* 🚨 紅色警告動畫 */
  filter: grayscale(0) brightness(1.1) !important; /* 暫時恢復色彩增加視覺衝擊 */
  z-index: 50; /* 確保警告時在最上層 */
}

/* 4. 特效：斜紋遮罩層（平常就有，增加鎖定感） */
#bus-card::after, #fishing-card::after, #drone-card::after, .app-card.hh::after {
  content: "" !important;
  position: absolute !important;
  inset: 0 !important;
  background: repeating-linear-gradient(
    45deg, 
    transparent, 
    transparent 10px, 
    rgba(255, 255, 255, 0.05) 10px, 
    rgba(255, 255, 255, 0.05) 20px
  ) !important;
  z-index: 10 !important;
  pointer-events: none !important;
}

/* 5. 鎖頭圖示細微呼吸感 */
#bus-card i, #fishing-card i, #drone-card i, .app-card.hh i {
  animation: lockBreath 2.5s ease-in-out infinite !important;
}

/* 6. 文字樣式統一（半透明白色） */
#bus-card .app-label, .app-card.hh .app-label {
  opacity: 0.7 !important;
  color: #ffffff !important;
  font-size: 0.95rem !important;
  font-weight: 600 !important;
  text-shadow: none !important;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 📱 首頁快捷功能整理版＋海象背景動畫回歸
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.app-home-section {
  position: relative;
  z-index: 2;
  width: 100%;
}

.app-dashboard-enhanced {
  width: 100%;
  max-width: 460px;
  margin: 26px auto 42px;
  padding: 0 16px 10px;
}

.app-grid-enhanced {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

/* 分類分隔符 */
.app-category-divider {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 0 12px;
  margin: 8px 0 4px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  border-bottom: 2px solid rgba(255, 255, 255, 0.15);
}

.app-category-divider i {
  font-size: 1.3rem;
  color: #12b886;
}

.app-category-divider.coming-soon {
  color: rgba(255, 255, 255, 0.6);
  border-bottom-color: rgba(255, 165, 0, 0.2);
  margin-top: 20px;
}

.app-category-divider.coming-soon i {
  color: #ffa500;
}

.app-dashboard-enhanced .app-section-title {
  font-size: 2rem;
  font-weight: 900;
  letter-spacing: 1.2px;
  color: #ffffff;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  margin-bottom: 1.2rem;
  position: relative;
  display: inline-block;
  padding-bottom: 0.8rem;
}

.app-dashboard-enhanced .app-section-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, #27ae60, #3498db, #e74c3c);
  border-radius: 2px;
}

.app-grid-enhanced .app-card {
  position: relative;
  aspect-ratio: 1 / 1;
  min-height: 100px;
  border-radius: 15px;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #f0f2f5;
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.app-grid-enhanced .app-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: none;
  pointer-events: none;
}

.app-grid-enhanced .app-card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.12);
  background: #f5f7f9;
}

/* 卡片顏色主題 */
.card-red {
  background: linear-gradient(135deg, #e74c3c, #e63946) !important;
  color: white;
}

.card-red .app-label { color: white !important; text-shadow: 0 2px 4px rgba(255, 255, 255, 0.3); }

.card-green {
  background: linear-gradient(135deg, #27ae60, #229954) !important;
  color: white;
}

.card-green .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-indigo {
  background: linear-gradient(135deg, #5dade2, #3498db) !important;
  color: white;
}

.card-indigo .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-yellow {
  background: linear-gradient(135deg, #f39c12, #e67e22) !important;
  color: white;
}

.card-yellow .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-light-blue {
  background: linear-gradient(135deg, #264285, #3498db) !important;
  color: white;
}

.card-light-blue .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

/* 友善連結：白色卡片主題 */
.card-Association {
  background: #ffffff !important; /* 直接用純白 */
  border: 1px solid rgba(0, 0, 0, 0.08) !important; /* 增加極淡邊框來代替重陰影 */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05) !important; /* 卡片本身的陰影調到極淡 (0.05) */
  transition: transform 0.2s ease;
}

/* 文字樣式：移除重陰影 */
.card-Association .app-label {
  color: #333333 !important; /* 改用深灰色，比純黑更有質感 */
  text-shadow: none !important; /* 徹底移除文字陰影 */
  font-weight: 700;
}

/* 圖片樣式：降低 Logo 陰影 */
.card-Association img {
  /* 使用極淡的投射陰影 (0.08) */
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.08)) !important;
}

/* 滑鼠移上去時的效果 */
.card-Association:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1) !important;
}

.card-tide {
  background: linear-gradient(
    135deg,
    #0f172a 0%,
    #155e75 45%,
    #0f766e 100%
  ) !important;

  color: white;
  position: relative;
  overflow: hidden;
}

.card-tide .app-label {
  color: white !important;
  text-shadow: 0 2px 5px rgba(0,0,0,0.35);
}

.card-tide::before {
  content: "";
  position: absolute;
  top: -20px;
  right: -20px;
  width: 80px;
  height: 80px;
  background: rgba(255,255,255,0.08);
  border-radius: 50%;
  filter: blur(8px);
}
.card-orange {
  background: linear-gradient(135deg, #e67e22, #d35400) !important;
  color: white;
}

.card-orange .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-orange-light {
  background: linear-gradient(135deg, #f39c12, #e67e22) !important;
  color: white;
}

.card-orange-light .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-pink {
  background: linear-gradient(135deg, #ec407a, #e91e63) !important;
  color: white;
}

.card-pink .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-gold {
  background: linear-gradient(135deg, #f39c12, #e67e22) !important;
  color: white;
}

.card-gold .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

/* ============================================================
  🚑 救護車：左進 → 中停 → 右出 (循環動畫)
  ============================================================ */

.card-red-dark {
  background: linear-gradient(135deg, #c0392b, #a93226) !important;
  color: white;
  overflow: hidden; /* 確保車子不會跑出方框 */
  position: relative;
}

.card-red-dark .app-label { 
  color: white !important; 
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); 
  position: relative;
  z-index: 5; /* 確保文字在最上層 */
}

/* 救護車圖示動畫 */
.card-red-dark .icon-box i {
  display: inline-block;
  font-size: 1.8rem;
  /* 動畫總長 4 秒，無限循環 */
  animation: ambulanceDrivePause 4s ease-in-out infinite;
  position: relative;
}

@keyframes ambulanceDrivePause {
  /* 0% - 20%: 從左側外衝到中間 (費時約 0.8 秒) */
  0% { transform: translateX(-70px); opacity: 0; }
  20% { transform: translateX(0); opacity: 1; }

  /* 20% - 70%: 停在中間 (維持約 2 秒) */
  /* 在這段期間加入微小的 translateY 震動，模擬引擎發動感 */
  25% { transform: translateX(0) translateY(-1px); }
  35% { transform: translateX(0) translateY(0px); }
  45% { transform: translateX(0) translateY(-1.5px); }
  55% { transform: translateX(0) translateY(0px); }
  65% { transform: translateX(0) translateY(-1px); }

  /* 70% - 85%: 向右衝出畫面 (費時約 0.6 秒) */
  70% { transform: translateX(0); opacity: 1; }
  85% { transform: translateX(70px); opacity: 0; }

  /* 85% - 100%: 在畫面外等待重啟 */
  100% { transform: translateX(-70px); opacity: 0; }
}

/* 加碼：警示燈紅光閃爍效果 */
.card-red-dark::after {
  content: "";
  position: absolute;
  inset: 0;
  /* 產生一個紅色的擴散光暈 */
  background: radial-gradient(circle, rgba(255, 0, 0, 0.3) 0%, transparent 70%);
  animation: sirenFlash 0.5s infinite alternate;
  pointer-events: none;
}

@keyframes sirenFlash {
  from { opacity: 0.2; }
  to { opacity: 0.8; }
}

.card-teal {
  background: linear-gradient(135deg, #1abc9c, #16a085) !important;
  color: white;
}

.card-teal .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-teal-dark {
  background: linear-gradient(135deg, #0d8a77, #099268) !important;
  color: white;
}

.card-teal-dark .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-sky {
  background: linear-gradient(135deg, #3498db, #2980b9) !important;
  color: white;
}

.card-sky .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-purple {
  background: linear-gradient(135deg, #af7ac5, #9b59b6) !important;
  color: white;
}

.card-purple .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-magenta {
  background: linear-gradient(135deg, #e91e63, #c2185b) !important;
  color: white;
}

.card-magenta .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-cyan {
  background: linear-gradient(135deg, #00bcd4, #17a2b8) !important;
  color: white;
}

.card-cyan .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-amber {
  background: linear-gradient(135deg, #ffa500, #ff9500) !important;
  color: white;
}

.card-amber .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-gray {
  background: linear-gradient(135deg, #95a5a6, #7f8c8d) !important;
  color: white;
  opacity: 0.6;
}

.card-gray .app-label { color: white !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3); }

.card-indigo {
  background: linear-gradient(135deg, #4834d4 0%, #130f40 100%) !important;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.1) !important; 
}

.card-indigo .app-label {
  color: #ffffff !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
  font-weight: 700;
}

/* 如果要增加「正在連線」的細微發光效果 */
.card-indigo:hover {
  box-shadow: 0 0 20px rgba(72, 52, 212, 0.4) !important;
}

.card-coral {
  background: linear-gradient(135deg, #FF6B6B 0%, #FF8E53 100%) !important;
  color: white;
}

.card-coral .app-label {
  color: white !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* 贊助卡片 */
.card-support {
  background: linear-gradient(135deg, #FF9A9E 0%, #F6416C 100%) !important;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
}

.card-support .app-label {
  color: white !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
  font-weight: 800; 
}

/* 動感流光行事曆 */
.card-calendar {
  /* 使用四個反差較大的顏色：深藍、紫、亮粉、青色 */
  background: linear-gradient(270deg, #240b36, #c31432, #7028e4, #00d2ff) !important;
  background-size: 400% 400% !important;
  animation: fastGradient 4s ease infinite !important;
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3) !important;
  position: relative;
  overflow: hidden;
}

@keyframes fastGradient {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.card-calendar .app-label {
  color: white !important;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
  font-weight: 800;
  z-index: 1;
}

/* ============================================================
  🚨 緊急求助按鈕 - 完全對齊與特效修正版
  ============================================================ */

.card-sos-call {
  /* 1. 確保基礎尺寸與其他按鈕完全一致 */
  aspect-ratio: 1 / 1 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 12px !important;
  padding: 0 !important; /* 讓 grid 統一控制尺寸 */
  
  /* 2. 背景與邊框 */
  background: linear-gradient(135deg, #f5020a 0%, #f91d51 100%) !important;
  color: white !important;
  /* 邊框必須跟其他按鈕一樣是 1px，不然會多出 1-2px 高度 */
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  position: relative;
  overflow: hidden; /* 確保發光不會超出圓角 */
}

/* 確保內部的圖示盒不佔額外空間 */
.card-sos-call .icon-box {
  margin-bottom: 0 !important; 
}

/* 確保特效是「浮在上面」的，不會撐開高度 */
.sos-glow {
  position: absolute; /* 核心修正：這行沒加高度就會壞掉 */
  inset: 0;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.4) 0%, transparent 70%);
  animation: sosPulse 1.5s infinite ease-in-out;
  pointer-events: none;
  z-index: 1;
}

/* 文字層級要在特效之上 */
.card-sos-call .app-label {
  position: relative;
  z-index: 2;
  color: white !important;
  font-weight: 800;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.card-sos-call .icon-box i {
  position: relative;
  z-index: 2;
  animation: iconShake 0.5s infinite alternate;
}

/* 動畫定義 */
@keyframes sosPulse {
  0% { opacity: 0.2; transform: scale(0.8); }
  50% { opacity: 0.6; transform: scale(1.2); }
  100% { opacity: 0.2; transform: scale(0.8); }
}

@keyframes iconShake {
  from { transform: rotate(-8deg); }
  to { transform: rotate(8deg); }
}
/* ============================================================
  🚨 緊急求助彈窗 - UI 強化重寫版 (小琉球專用)
  ============================================================ */

/* 1. 彈窗背景遮罩 - 初始隱藏 */
.sos-modal {
  display: none; 
  position: fixed;
  inset: 0;
  z-index: 99999;
  background: rgba(0, 0, 0, 0.45); 
  backdrop-filter: blur(15px) saturate(180%); 
  -webkit-backdrop-filter: blur(15px) saturate(180%);
  align-items: center;
  justify-content: center;
  padding: 20px;
}

/* 2. 當有 .active class 時才顯示 */
.sos-modal.active {
  display: flex !important; /* 加上 !important 確保顯示 */
  animation: modalPop 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

/* 卡片主體 */
.sos-modal-content {
  background: rgba(30, 30, 30, 0.8) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  width: 100%;
  max-width: 350px;
  border-radius: 30px;
  padding: 30px 24px;
  text-align: center;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
  color: #ffffff;
}


/* 3. 頂部標題區 */
.sos-modal-header i {
  font-size: 2.8rem;
  color: #ff3b30;
  margin-bottom: 12px;
  filter: drop-shadow(0 0 8px rgba(255, 59, 48, 0.5));
}

.sos-modal-header h3 {
  font-size: 1.4rem;
  font-weight: 900;
  color: #ffffff !important;
  margin-bottom: 5px;
}

.sos-modal-header p {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.6) !important;
  margin-bottom: 20px;
}

/* 4. 按鈕群組 */
.sos-btn-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

/* 5. 通用撥打按鈕樣式 */
.sos-call-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 15px;
  border-radius: 16px;
  text-decoration: none !important;
  font-weight: 800;
  font-size: 1.05rem;
  color: #ffffff !important;
  transition: transform 0.1s;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.sos-call-btn:active {
  transform: scale(0.97);
}

/* --- 按鈕個別色彩定義 --- */

/* 119 - 紅色 */
.btn-119 {
  background: linear-gradient(135deg, #ff3b30 0%, #d70015 100%);
  border-bottom: 3px solid #a30000;
}

/* 110 - 深藍 */
.btn-110 {
  background: linear-gradient(135deg, #007aff 0%, #0040dd 100%);
  border-bottom: 3px solid #0030a0;
}

/* 118 - 橘色 */
.btn-118 {
  background: linear-gradient(135deg, #ff9500 0%, #ff5e00 100%);
  border-bottom: 3px solid #cc4b00;
}

/* 救護船 - 深藍靛色 */
.btn-boat {
  background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
  border-bottom: 3px solid #0f1c3a;
}

/* 衛生所 - 青綠色 */
.btn-clinic {
  background: linear-gradient(135deg, #12b886 0%, #087f5b 100%);
  border-bottom: 3px solid #04523a;
}

/* ============================================================
   空拍機禁限航區地圖
   需先刪除所有舊版 drone CSS
   ============================================================ */

/* 卡片本體：尺寸交給原本 .app-card 控制 */
#drone-map-card.card-drone {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: #fff !important;
  background:
    radial-gradient(
      circle at 50% 38%,
      rgba(75, 194, 216, 0.16),
      transparent 38%
    ),
    linear-gradient(
      145deg,
      #123b4b 0%,
      #0e5365 100%
    ) !important;
  border: 1px solid rgba(116, 216, 235, 0.32) !important;
  box-shadow:
    0 10px 22px rgba(3, 34, 46, 0.28),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  opacity: 1 !important;
  filter: none !important;
  pointer-events: auto !important;
  cursor: pointer !important;
  transition:
    transform 0.25s ease,
    border-color 0.25s ease,
    box-shadow 0.25s ease;
}

/* 清除舊版卡片偽元素 */
#drone-map-card.card-drone::before,
#drone-map-card.card-drone::after {
  display: none !important;
  content: none !important;
}

/* 雷達固定在卡片中央偏上 */
#drone-map-card .drone-radar {
  position: absolute;
  top: 42%;
  left: 50%;
  z-index: 0;
  width: 86px;
  height: 86px;
  pointer-events: none;
  background:
    linear-gradient(
      rgba(111, 220, 239, 0.08) 1px,
      transparent 1px
    ),
    linear-gradient(
      90deg,
      rgba(111, 220, 239, 0.08) 1px,
      transparent 1px
    ),
    repeating-radial-gradient(
      circle,
      transparent 0 13px,
      rgba(108, 218, 237, 0.17) 14px 15px
    );
  background-size:
    12px 12px,
    12px 12px,
    auto;
  border: 1px solid rgba(118, 224, 242, 0.2);
  border-radius: 50%;
  opacity: 0.85;
  transform: translate(-50%, -50%);
}

/* 雷達掃描 */
#drone-map-card .drone-radar::before {
  position: absolute;
  inset: 0;
  background: conic-gradient(
    from 0deg,
    transparent 0deg 292deg,
    rgba(108, 224, 242, 0.02) 315deg,
    rgba(117, 229, 246, 0.46) 359deg,
    transparent 360deg
  );
  border-radius: 50%;
  content: "";
  animation: drone-radar-spin 4.5s linear infinite;
}

/* 雷達中心 */
#drone-map-card .drone-radar::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 4px;
  height: 4px;
  background: #c8f8ff;
  border-radius: 50%;
  box-shadow: 0 0 7px rgba(180, 244, 255, 0.85);
  content: "";
  transform: translate(-50%, -50%);
}

/* 雷達紅點 */
#drone-map-card .radar-dot {
  position: absolute;
  z-index: 2;
  display: block;
  background: #ff665e;
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: 50%;
  box-shadow:
    0 0 4px rgba(255, 83, 75, 0.95),
    0 0 8px rgba(255, 83, 75, 0.48);
  animation: drone-target 2.2s ease-in-out infinite;
}

#drone-map-card .dot-1 {
  top: 18%;
  left: 67%;
  width: 6px;
  height: 6px;
  animation-delay: 0s;
}

#drone-map-card .dot-2 {
  top: 38%;
  left: 19%;
  width: 4px;
  height: 4px;
  animation-delay: 0.6s;
}

#drone-map-card .dot-3 {
  top: 68%;
  left: 73%;
  width: 7px;
  height: 7px;
  animation-delay: 1.1s;
}

#drone-map-card .dot-4 {
  top: 76%;
  left: 39%;
  width: 4px;
  height: 4px;
  animation-delay: 1.6s;
}

/* 中間 H 圖示：固定不動 */
#drone-map-card .icon-box.drone {
  position: relative;
  z-index: 3;
  display: grid !important;
  place-items: center !important;
  width: 43px !important;
  height: 43px !important;
  margin: 0 !important;
  color: #fff !important;
  background: rgba(12, 70, 87, 0.9) !important;
  border: 1px solid rgba(157, 232, 245, 0.4) !important;
  border-radius: 13px !important;
  box-shadow:
    0 6px 13px rgba(1, 27, 37, 0.34),
    0 0 12px rgba(80, 202, 224, 0.18);
  opacity: 1 !important;
  filter: none !important;
  transform: none !important;
  animation: none !important;
}

/* H 圖示本身固定不動 */
#drone-map-card .icon-box.drone i {
  display: block;
  margin: 0 !important;
  color: #fff !important;
  font-size: 22px !important;
  line-height: 1 !important;
  opacity: 1 !important;
  filter: drop-shadow(0 2px 3px rgba(0, 22, 31, 0.46));
  transform: none !important;
  animation: none !important;
}

/* 標題只處理圖層，不修改既有文字設定 */
#drone-map-card .app-label {
  position: relative;
  z-index: 4;
  color: #fff !important;
}

#drone-map-card .app-label::before,
#drone-map-card .app-label::after {
  display: none !important;
  content: none !important;
}

/* 滑鼠移入 */
#drone-map-card.card-drone:hover {
  color: #fff !important;
  border-color: rgba(132, 226, 243, 0.68) !important;
  box-shadow:
    0 15px 29px rgba(3, 34, 46, 0.38),
    0 0 18px rgba(64, 189, 213, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.15);
  transform: translateY(-3px);
}

#drone-map-card.card-drone:active {
  transform: translateY(-1px) scale(0.985);
}

#drone-map-card.card-drone:focus-visible {
  outline: 4px solid rgba(91, 207, 230, 0.38);
  outline-offset: 3px;
}

@keyframes drone-radar-spin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

@keyframes drone-target {
  0%,
  35%,
  100% {
    opacity: 0.35;
    transform: scale(0.75);
  }

  55%,
  75% {
    opacity: 1;
    transform: scale(1.15);
  }
}

@media (prefers-reduced-motion: reduce) {
  #drone-map-card .drone-radar::before,
  #drone-map-card .radar-dot {
    animation: none;
  }
}

/* 6. 取消按鈕 */
.sos-close-btn {
  margin-top: 18px;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: rgba(255, 255, 255, 0.7) !important;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  padding: 10px 40px;
  border-radius: 50px;
}

.sos-close-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  color: #fff !important;
}

/* 動畫 */
@keyframes modalPop {
  from { opacity: 0; transform: scale(0.9) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

/* 透明灰色卡片 - 輔助功能 */
.card-gray-light {
  background: linear-gradient(135deg, rgba(180, 188, 199, 0.45), rgba(160, 170, 185, 0.35)) !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
  backdrop-filter: blur(6px);
  color: rgba(255, 255, 255, 0.95);
}

.card-gray-light .app-label { 
  color: rgba(255, 255, 255, 0.95) !important; 
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.app-grid-enhanced .app-card:active {
  transform: scale(0.97);
}

.app-grid-enhanced .app-label {
  position: relative;
  z-index: 1;
  font-size: 0.90rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0.3px;
  color: #2d3748;
  text-align: center;
  text-shadow: none;
  padding: 0 4px;
}

.app-grid-enhanced .icon-box {
  position: relative;
  z-index: 1;
  width: 48px;
  height: 48px;
  border-radius: 11px;
  margin-bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.7rem;
  background: none;
  border: none;
  box-shadow: none;
  text-shadow: none;
  filter: none;
}

.icon-box.red      { color: #ffffff; }
.icon-box.green    { color: #ffffff; }
.icon-box.blue     { color: #ffffff; }
.icon-box.indigo   { color: #ffffff; }
.icon-box.yellow   { color: #ffffff; }
.icon-box.orange   { color: #ffffff; }
.icon-box.teal     { color: #ffffff; }
.icon-box.purple   { color: #ffffff; }
.icon-box.pink     { color: #ffffff; }
.icon-box.gold     { color: #ffffff; }
.icon-box.dark-red { color: #ffffff; }
.icon-box.gray     { color: #ffffff; }
.icon-box.sky      { color: #ffffff; }
.icon-box.dark     { color: #ffffff; }

.app-grid-enhanced .disabled {
  opacity: 1;
  filter: grayscale(0) !important;
  pointer-events: none;
  position: relative;
}

.app-grid-enhanced .disabled::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(200, 200, 200, 0.75), rgba(180, 180, 180, 0.75));
  border-radius: 16px;
  z-index: 2;
  pointer-events: none;
}

.app-grid-enhanced .disabled .app-label,
.app-grid-enhanced .disabled .icon-box {
  position: relative;
  z-index: 3;
}

.special-bg-pp {
  background: linear-gradient(135deg, rgba(0, 0, 0, 0.311), rgba(37, 37, 37, 0.286));
  position: relative;
  overflow: hidden;
}

.special-bg-pp::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("圖片/DSC_1850.webp");
  background-size: cover;
  background-position: center;
  opacity: 0.15;
  filter: none;
  z-index: 0;
}

.star-card {
  overflow: visible;
  background: linear-gradient(135deg, #2d3748, #1a202c) !important;
  position: relative;
}

.star-card .app-label {
  color: #ffffff !important;
  position: relative;
  z-index: 2;
}

.star-card .icon-box {
  color: #ffffff !important;
  position: relative;
  z-index: 2;
}

.sea-wave-card {
  overflow: hidden;
  background: linear-gradient(180deg, #3b9fd9, #2e7fb8) !important;
  position: relative;
}

.sea-wave-card .app-label {
  color: #ffffff !important;
  position: relative;
  z-index: 2;
}

.sea-wave-card .icon-box {
  color: #ffffff !important;
  position: relative;
  z-index: 2;
}

.wave {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 200%;
  height: 80px;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1200 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0,50 Q300,20 600,50 T1200,50 L1200,120 L0,120 Z' fill='rgba(255,255,255,0.15)' /%3E%3C/svg%3E");
  background-repeat: repeat-x;
  background-position: 0 0;
  background-size: 600px 80px;
  animation: waveFloat 8s linear infinite;
  z-index: 1;
}

.wave-2 {
  bottom: 10px;
  animation: waveFloat 6s linear infinite reverse;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1200 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0,50 Q300,20 600,50 T1200,50 L1200,120 L0,120 Z' fill='rgba(255,255,255,0.08)' /%3E%3C/svg%3E");
  height: 60px;
  background-size: 600px 60px;
}

.wave-3 {
  bottom: 20px;
  animation: waveFloat 10s linear infinite;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 1200 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0,50 Q300,20 600,50 T1200,50 L1200,120 L0,120 Z' fill='rgba(255,255,255,0.1)' /%3E%3C/svg%3E");
  height: 70px;
  background-size: 600px 70px;
}

@keyframes waveFloat {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 600px 0;
  }
}

.star {
  position: absolute;
  width: 3px;
  height: 3px;
  background: #ffd700;
  border-radius: 50%;
  opacity: 0.15;
  box-shadow: 0 0 6px rgba(255, 215, 0, 1), 0 0 10px rgba(255, 215, 0, 0.8);
  animation: twinkleStar 1.8s ease-in-out infinite;
  z-index: 10;
}

.star-dot {
  position: absolute;
  border-radius: 999px;
  background: #ffd700;
  box-shadow: 0 0 8px rgba(255, 215, 0, 0.8), 0 0 12px rgba(255, 215, 0, 0.6);
  animation: twinkleStar 2.8s ease-in-out infinite;
  z-index: 10;
}

.star-dot-1 {
  width: 4px;
  height: 4px;
  top: 20%;
  left: 25%;
  opacity: 0.9;
}

.star-dot-2 {
  width: 3px;
  height: 3px;
  top: 30%;
  right: 22%;
  opacity: 0.9;
  animation-delay: 1s;
}

@keyframes twinkleStar {
  0%, 100% { opacity: 0.15; }
  25% { opacity: 0.6; }
  50% { opacity: 1; }
  75% { opacity: 0.6; }
}

@keyframes starBlink {
  0%, 100% { opacity: 0.3; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.5); }
}

.hero-cta-row {
  width: 100%;
  max-width: 460px;
  margin: 0 auto 18px;
  padding: 0 16px;
}

.hero-btn-content {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 16px 20px;
  position: relative;
  z-index: 1;
}

.hero-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,0.14);
  color: #fff;
  font-size: 1.25rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.18);
}

.hero-texts {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  text-align: left;
}

.hero-texts .hero-title {
  font-size: 1.15rem;
  font-weight: 900;
  line-height: 1.15;
  color: #fff;
  letter-spacing: 0.4px;
}

.hero-texts .hero-sub {
  margin-top: 2px;
  font-size: 0.88rem;
  font-weight: 700;
  color: rgba(255,255,255,0.88);
  letter-spacing: 0.2px;
}
/* =========================================================
   ✨ 強化卡片內容立體感 (圖示與文字陰影)
   ========================================================= */

/* 1. 為 FontAwesome 圖示加上陰影 */
.app-grid-enhanced .icon-box i {
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.25);
  /* 讓圖示看起來更有厚度 */
}

/* 2. 為圖片形式的圖示 (如 AED) 加上投射陰影 */
.app-grid-enhanced .icon-box img {
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.648));
}

/* 3. 為文字標籤加上細微陰影，提升辨識度 */
.app-grid-enhanced .app-label {
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.494);
  /* 確保在淺色或飽和度高的背景上文字依然清晰 */
}

/* 4. 滑鼠懸停時的動態效果 (選配：讓陰影變深一點點) */
.app-grid-enhanced .app-card:hover .icon-box i {
  text-shadow: 0 3px 8px rgba(0, 0, 0, 0.4);
  transform: scale(1.05); /* 稍微放大增加互動感 */
  transition: all 0.25s ease;
}

.app-grid-enhanced .app-card:hover .app-label {
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.4);
  transition: all 0.25s ease;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 📊 1️⃣0️⃣ 廣告輪播與內容區塊
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.main-content {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 2rem;
  position: relative;
}

@media (min-width: 1024px) {
  .main-content {
   justify-content: flex-start;
   min-height: auto;
   padding-top: 1rem;
   gap: 1.5rem;
  }
}

.bc-ad {
  margin-bottom: 14px;
  padding: 0 12px;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  overflow: hidden;
  position: relative;
  display: block;
}

.bc-ad-track {
  display: flex;
  width: 100%;
  transform: translateX(0);
}

.bc-ad-item {
  flex: 0 0 100%;
  width: 100%;
  display: block;
}

.bc-ad-item img {
  width: 100%;
  display: block;
  object-fit: cover;
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28);
}

/* =========================================================
   💻 電腦版快捷功能 → 一列五個（商業化設計）
   ========================================================= */
@media (min-width: 1200px) {
  .app-dashboard-enhanced {
    max-width: 950px !important;
  }

  .app-grid-enhanced {
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    gap: 16px !important;
  }

  .app-grid-enhanced .app-card {
    min-height: 110px;
    border-radius: 16px;
  }

  .app-grid-enhanced .app-label {
    font-size: 1rem;
    font-weight: 600;
  }

  .app-grid-enhanced .icon-box {
    width: 52px;
    height: 52px;
    font-size: 1.75rem;
  }
}
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 👤 1️⃣1️⃣ 作者卡片与社交链接
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

.mini-author-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: rgba(255, 255, 255, 0.05);
  padding: 1rem 1.2rem;
  border-radius: 1rem;
  max-width: 350px;
  margin: 2.5rem auto;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(8px);
}

.mini-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 2px solid #63e6be;
  object-fit: cover;
  object-position: center;
  aspect-ratio: 1 / 1;
}

.mini-author-text h3 {
  font-size: 1.05rem;
  margin: 0;
  color: #63e6be;
  font-weight: 700;
}

.mini-author-text p {
  font-size: 0.9rem;
  margin: 0.2rem 0 0.5rem 0;
  color: #f0f0f0cc;
  line-height: 1.5;
}

.social-links {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.8rem;
  flex-wrap: wrap;
}

.ig-link,
.threads-link {
  flex: 1 1 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: #f8f9fa;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.08);
  padding: 0.5rem 1rem;
  border-radius: 999px;
  transition: all 0.3s ease;
  min-width: 140px;
}

.ig-link i,
.threads-link i {
  font-size: 1.1rem;
}

.ig-link:hover {
  background: #e1306c;
  color: #fff;
}

.threads-link:hover {
  background: #000;
  color: #fff;
}

.mini-author-card.vertical {
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1.5rem 1.8rem;
  max-width: 360px;
}

/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */
/* 📈 1️⃣2️⃣ 訪客計數與其他實用組件
/* ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ */

#visitor-count {
  display: inline-block;
  padding: 0.5rem 1.2rem;
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  font-size: 1rem;
  font-weight: 500;
  border-radius: 999px;
  backdrop-filter: blur(6px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  margin: 2rem auto 2.5rem auto;
  text-align: center;
  animation: fadeIn 1s ease-out;
}

#visitor-count:hover {
  background: rgba(0, 0, 0, 0.6);
  transform: scale(1.05);
  transition: all 0.3s ease;
}

@keyframes fadeIn {
  0% { opacity: 0; }
  100% { opacity: 1; }
}

.pwa-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  background: rgba(255, 255, 255, 0.95);
  padding: 1.5rem;
  border-radius: 1rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
}

.pwa-icon {
  width: 60px;
  height: 60px;
  border-radius: 12px;
}

.pwa-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: #333;
  margin: 0;
}

.pwa-sub {
  font-size: 0.9rem;
  color: #666;
  margin: 0.25rem 0 0 0;
}

.pwa-actions {
  display: flex;
  gap: 0.75rem;
  margin-left: auto;
}

.pwa-btn {
  padding: 0.6rem 1.2rem;
  border: none;
  border-radius: 8px;
  background: #0ca678;
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.pwa-btn:hover {
  background: #087f5b;
  transform: scale(1.05);
}

.pwa-link {
  background: transparent;
  border: none;
  color: #666;
  font-weight: 600;
  cursor: pointer;
  transition: color 0.3s ease;
}

.pwa-link:hover {
  color: #333;
}

.pwa-hidden { display: none; }

.btn-container {
  display: grid;
  gap: 1rem;
  grid-template-columns: 1fr;
}

@media (min-width: 1024px) {
  .btn-container {
   grid-template-columns: repeat(4, minmax(260px, 1fr));
   max-width: 1400px;
   margin: 0 auto;
   padding: 1.5rem 0;
  }
}

/* =========================================================
   🎫 訂票系統 Modern UI 完整重寫版
   不吃舊樣式、不跟舊 CSS 打架
   ========================================================= */

.ticket-modern-wrap {
  position: relative;
  z-index: 20;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 28px 0 36px;
  padding: 0 16px;
}

/* =========================
   主按鈕
   ========================= */
.ticket-modern-main {
  width: min(92vw, 420px);
  min-height: 78px;
  border: 0;
  border-radius: 22px;
  cursor: pointer;
  padding: 16px 18px;

  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;

  color: #ffffff;
  background:
    linear-gradient(180deg, rgba(232, 92, 120, 0.96) 0%, rgba(212, 76, 104, 0.96) 100%);
  box-shadow:
    0 12px 30px rgba(201, 79, 103, 0.28),
    0 4px 12px rgba(0, 0, 0, 0.14);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease,
    filter 0.25s ease;
}

.ticket-modern-main:hover {
  transform: translateY(-2px);
  box-shadow:
    0 16px 34px rgba(201, 79, 103, 0.32),
    0 8px 16px rgba(0, 0, 0, 0.16);
  filter: brightness(1.02);
}

.ticket-modern-main:active {
  transform: translateY(0) scale(0.985);
}

.ticket-modern-main__icon {
  width: 42px;
  height: 42px;
  min-width: 42px;
  border-radius: 999px;
  display: flex;
  align-items: center;
  justify-content: center;

  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  font-size: 1rem;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16);
}

.ticket-modern-main__text {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  min-width: 0;
  text-align: center;
  color: #ffffff;
}

.ticket-modern-main__title {
  display: block;
  color: #ffffff;
  font-size: 1.08rem;
  font-weight: 900;
  letter-spacing: 0.3px;
  line-height: 1.15;
}

.ticket-modern-main__sub {
  display: block;
  margin-top: 4px;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.15;
}

.ticket-modern-main__arrow {
  width: 24px;
  min-width: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.92);
  font-size: 0.9rem;
  transition: transform 0.28s ease;
}

.ticket-modern-main.is-open .ticket-modern-main__arrow {
  transform: rotate(180deg);
}

/* =========================
   展開面板
   ========================= */
.ticket-modern-panel {
  width: min(92vw, 760px);
  margin-top: 12px;

  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;

  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transform: translateY(-10px);
  pointer-events: none;

  transition:
    max-height 0.38s ease,
    opacity 0.26s ease,
    transform 0.26s ease,
    margin-top 0.26s ease;
}

.ticket-modern-panel.is-open {
  max-height: 420px;
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* =========================
   子卡片
   ========================= */
.ticket-modern-card {
  min-height: 58px;
  border-radius: 16px;
  padding: 0 16px;

  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;

  text-decoration: none;
  color: #ffffff;

  background:
    linear-gradient(180deg, rgba(82, 108, 126, 0.92) 0%, rgba(62, 86, 102, 0.92) 100%);
  box-shadow:
    0 8px 18px rgba(0, 0, 0, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);

  transition:
    transform 0.22s ease,
    filter 0.22s ease,
    box-shadow 0.22s ease,
    background 0.22s ease;
}

.ticket-modern-card:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);
  box-shadow:
    0 12px 24px rgba(0, 0, 0, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}

.ticket-modern-card:active {
  transform: scale(0.985);
}

.ticket-modern-card__icon {
  width: 22px;
  min-width: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.95);
  font-size: 0.95rem;
}

.ticket-modern-card__label {
  color: #ffffff;
  font-size: 0.98rem;
  font-weight: 800;
  letter-spacing: 0.2px;
  line-height: 1;
}

/* =========================================================
   🖥️ 電腦版精緻縮小版 (修復版：回歸經典作者卡片 + 緊湊導覽列)
   ========================================================= */
@media (min-width: 1024px) {
  /* 1. 溫和縮小：基準字體設為 15px，保持穩定不崩壞 */
  html {
    font-size: 15px !important;
  }

  /* 2. 導覽列縮減 (精緻小巧感) */
  :root {
    --nav-h: 60px !important; 
  }

  #nav-fixed .nav-logo {
    height: 42px !important; 
  }

  #nav-fixed .nav-right a {
    font-size: 0.95rem !important;
    padding: 0.4rem 0.9rem !important;
  }

  /* 3. 頂部 Hero 區塊間距拉近 */
  .header-layout-container {
    padding-top: 1.5rem !important;
  }

  .hero-section h1 {
    font-size: 2.6rem !important;
    margin-bottom: 0.5rem !important;
  }

  .hero-section .subtitle {
    font-size: 0.95rem !important;
    margin-bottom: 1.2rem !important;
  }

  /* 4. 天氣卡與廣告間距優化 */
  .weather-bar {
    width: min(80%, 720px) !important;
    margin: 0.8rem auto !important;
    transform: scale(0.95);
  }

  .bc-ad {
    max-width: 600px !important;
    margin-bottom: 10px !important;
  }

  /* 5. 訂票按鈕精簡化 */
  .ticket-modern-wrap {
    margin: 12px 0 24px !important;
  }

  .ticket-modern-main {
    width: 320px !important;
    min-height: 66px !important;
    border-radius: 16px !important;
  }

  /* 6. 快捷網格 (維持 7 列精緻感) */
  .app-dashboard-enhanced {
    max-width: 1050px !important;
  }

  .app-grid-enhanced {
    grid-template-columns: repeat(7, minmax(0, 1fr)) !important;
    gap: 12px !important;
  }

  .app-grid-enhanced .app-card {
    min-height: 85px !important;
    border-radius: 12px !important;
  }

  .app-grid-enhanced .icon-box {
    width: 44px !important;
    height: 44px !important;
    font-size: 1.6rem !important;
  }

  .app-grid-enhanced .app-label {
    font-size: 0.9rem !important;
  }

  /* 7. 作者卡片：回歸垂直經典樣式 (縮小版) */
  .mini-author-card.vertical {
    flex-direction: column !important; /* 強制垂直 */
    text-align: center !important;
    max-width: 350px !important; /* 縮窄卡片 */
    padding: 1.5rem !important;
    margin: 2.5rem auto !important;
    gap: 1rem !important;
  }

  .mini-avatar.top {
    width: 80px !important;
    height: 80px !important;
    margin: 0 auto 0.5rem !important;
  }

  .social-links {
    flex-direction: row !important; /* 按鈕恢復橫向或交錯排列 */
    flex-wrap: wrap !important;
    justify-content: center !important;
    gap: 0.6rem !important;
  }

  .social-links a {
    flex: 1 1 auto !important;
    min-width: 140px !important;
    font-size: 0.85rem !important;
    padding: 0.4rem 0.8rem !important;
  }
}

/* 超大螢幕補強 */
@media (min-width: 1400px) {
  .app-grid-enhanced {
    grid-template-columns: repeat(8, minmax(0, 1fr)) !important;
  }
}

/* =========================
   手機版微調
   ========================= */
@media (max-width: 520px) {
  .ticket-modern-wrap {
    margin: 22px 0 30px;
    padding: 0 14px;
  }

  .ticket-modern-main {
    width: min(92vw, 320px);
    min-height: 74px;
    border-radius: 20px;
    padding: 14px 16px;
    gap: 10px;
  }

  .ticket-modern-main__icon {
    width: 38px;
    height: 38px;
    min-width: 38px;
    font-size: 0.92rem;
  }

  .ticket-modern-main__title {
    font-size: 1rem;
  }

  .ticket-modern-main__sub {
    font-size: 0.74rem;
  }

  .ticket-modern-panel {
    width: min(92vw, 320px);
    gap: 9px;
  }

  .ticket-modern-panel.is-open {
    max-height: 360px;
  }

  .ticket-modern-card {
    min-height: 54px;
    border-radius: 14px;
    padding: 0 12px;
    gap: 8px;
  }

  .ticket-modern-card__label {
    font-size: 0.92rem;
  }
}

/* =========================
   文字強制白色，避免吃到全域規則
   ========================= */
.ticket-modern-main,
.ticket-modern-main *,
.ticket-modern-panel,
.ticket-modern-panel *,
.ticket-modern-card,
.ticket-modern-card * {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  text-shadow: none !important;
  background-clip: initial !important;
  -webkit-background-clip: initial !important;
}

.ocean-background, .wave-layer, .custom-photo-background {
  transform: translateZ(0); /* 強制開啟 GPU 加速 */
  backface-visibility: hidden;
}
/* =========================================================
   🚀 全裝置通用：極致壓縮標題上方空白
   ========================================================= */

/* 1. 減少 Body 頂部的預留空間 (原本是 + 10px，改為 + 2px) */
body {
  padding-top: calc(var(--nav-h) + var(--marquee-h) + 2px) !important;
}

/* 2. 壓縮標題容器頂部的內距 */
.header-layout-container {
  padding-top: 1rem !important; /* 原本可能是 1rem 或更多，現在縮到最小 */
}

/* 3. 確保標題區塊沒有額外的外距 */
.hero-section {
  margin-top: 0 !important;
}

/* 4. 移除大標題 H1 文字本身的頂部預設外距 */
.hero-section h1 {
  margin-top: 0 !important;
  padding-top: 0 !important;
  line-height: 1 !important; /* 稍微縮小行高，讓標題更緊湊 */
}

/* 5. 如果有跑馬燈 (marquee-pill)，確保它不要撐得太高 */
.marquee-pill {
  margin-bottom: 2px !important;
}

/* 廣告輪播點點容器 */
.bc-ad-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: -5px; /* 緊貼廣告下方 */
  margin-bottom: 15px;
  z-index: 10;
}

/* 基礎點點樣式 */
.bc-ad-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* 當前活動的點點 (變成長條膠囊狀) */
.bc-ad-dot.active {
  background: #ffffff;
  width: 20px;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* ==================================================
   琉編資訊區｜海洋玻璃風格
   ================================================== */

.editor-panel {
  position: relative;
  isolation: isolate;
  width: min(calc(100% - 32px), 860px);
  margin: 42px auto 105px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 24px;
  background: rgba(10, 48, 65, 0.56);
  color: #fff;
  box-shadow:
    0 24px 55px rgba(0, 25, 38, 0.25),
    inset 0 1px 0 rgba(255, 255, 255, 0.25),
    inset 0 -1px 0 rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(22px) saturate(135%);
  -webkit-backdrop-filter: blur(22px) saturate(135%);
}

/* 玻璃表面的淡淡反光 */
.editor-panel::before {
  content: "";
  position: absolute;
  z-index: -1;
  top: -120px;
  left: -80px;
  width: 360px;
  height: 260px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.11);
  filter: blur(30px);
  pointer-events: none;
}

/* 青綠色光影 */
.editor-panel::after {
  content: "";
  position: absolute;
  z-index: -1;
  right: -90px;
  bottom: -130px;
  width: 300px;
  height: 250px;
  border-radius: 50%;
  background: rgba(45, 212, 191, 0.13);
  filter: blur(42px);
  pointer-events: none;
}

.editor-panel__main {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 30px;
  padding: 28px;
}

/* ==================================================
   作者介紹
   ================================================== */

.editor-profile {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  align-items: center;
  gap: 19px;
  min-width: 0;
}

.editor-profile__avatar {
  width: 88px;
  height: 88px;
  border: 2px solid rgba(116, 238, 216, 0.9);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.16);
  object-fit: cover;
  box-shadow:
    0 0 0 5px rgba(116, 238, 216, 0.08),
    0 10px 24px rgba(0, 0, 0, 0.25);
}

.editor-profile__content {
  min-width: 0;
}

.editor-profile__label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  color: #75ead7;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.editor-profile__content h2 {
  margin: 0 0 8px;
  color: #fff;
  font-size: 22px;
  font-weight: 900;
  line-height: 1.25;
  text-shadow: 0 3px 14px rgba(0, 0, 0, 0.18);
}

.editor-profile__content p {
  margin: 0;
  max-width: 500px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.8;
}

/* 信箱與社群 */
.editor-profile__contact {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 13px;
}

.editor-profile__contact a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  min-height: 32px;
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.09);
  color: rgba(255, 255, 255, 0.9);
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease;
}

.editor-profile__contact a:first-child {
  gap: 7px;
}

.editor-profile__contact a:hover {
  border-color: rgba(117, 234, 215, 0.45);
  background: rgba(117, 234, 215, 0.13);
  color: #fff;
  transform: translateY(-2px);
}

.editor-profile__contact i {
  color: #75ead7;
}

/* ==================================================
   主要入口
   ================================================== */

.editor-actions {
  position: static;
  display: flex;
  flex-direction: column;
  gap: 9px;
  width: auto;
  height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.editor-actions > a {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  min-height: 58px;
  padding: 9px 12px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.09);
  color: #fff;
  text-decoration: none;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.09),
    0 5px 14px rgba(0, 24, 36, 0.08);
  transition:
    background 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.editor-actions > a:hover {
  border-color: rgba(117, 234, 215, 0.4);
  background: rgba(255, 255, 255, 0.15);
  transform: translateX(3px);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.14),
    0 8px 18px rgba(0, 24, 36, 0.14);
}

.editor-actions__icon {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid rgba(117, 234, 215, 0.18);
  border-radius: 11px;
  background: rgba(117, 234, 215, 0.11);
  color: #75ead7;
  font-size: 14px;
}

.editor-actions > a > span:nth-child(2) {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.editor-actions strong {
  color: #fff;
  font-size: 12px;
  font-weight: 800;
}

.editor-actions small {
  margin-top: 3px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.52);
  font-size: 9px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.editor-actions__arrow {
  color: rgba(255, 255, 255, 0.38);
  font-size: 9px;
  transition: transform 0.2s ease;
}

.editor-actions > a:hover .editor-actions__arrow {
  color: #75ead7;
  transform: translateX(2px);
}

