:root {
    --primary: #0ea5e9;
    --primary-dark: #0284c7;
    --secondary: #10b981;
    --accent: #f59e0b;
    --bg-color: #0f172a;
    --bg-light: #1e293b;
    --text-main: #f8fafc;
    --text-muted: #cbd5e1;
    --glass-bg: rgba(30, 41, 59, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);
    --card-hover-y: -10px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Noto Sans TC', 'Outfit', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
}
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
h1, h2, h3, h4 {
    font-family: 'Outfit', 'Noto Sans TC', sans-serif;
    font-weight: 700; line-height: 1.2;
}
.text-gradient {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.container { max-width: 1280px; margin: 0 auto; padding: 0 2rem; }
.section { padding: 6rem 0; }
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 0.8rem 1.8rem; border-radius: 50px; font-weight: 600;
    font-size: 1rem; transition: var(--transition); cursor: pointer;
    border: 2px solid transparent;
}
.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white; box-shadow: 0 4px 15px rgba(14, 165, 233, 0.3);
}
.btn-primary:hover {
    transform: translateY(-2px); box-shadow: 0 8px 25px rgba(14, 165, 233, 0.4);
}
.btn-outline {
    background: transparent; border-color: var(--text-muted); color: var(--text-main);
}
.btn-outline:hover {
    border-color: var(--primary); color: var(--primary);
}

/* Navbar */
.navbar {
    position: fixed; top: 0; left: 0; width: 100%; z-index: 1000;
    padding: 1rem 0; transition: var(--transition);
    border-bottom: 1px solid transparent;
}
.navbar.scrolled {
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.8rem 0; box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}
.nav-container {
    max-width: 1280px; margin: 0 auto; padding: 0 2rem;
    display: flex; justify-content: space-between; align-items: center;
}
.logo { display: flex; align-items: center; gap: 0.8rem; }
.logo-icon { font-size: 2rem; }
.logo-text { display: flex; flex-direction: column; }
.logo-title { font-weight: 800; font-size: 1.2rem; letter-spacing: 1px; color:#fff;}
.logo-subtitle { font-size: 0.75rem; color: var(--primary); font-weight: 500; }
.nav-links { display: flex; gap: 2rem; }
.nav-links li a {
    font-size: 1rem; font-weight: 500; color: var(--text-muted);
    position: relative; padding: 0.5rem 0; transition: var(--transition);
}
.nav-links li a::after {
    content: ''; position: absolute; bottom: 0; left: 0; width: 0;
    height: 2px; background-color: var(--primary);
    transition: var(--transition); border-radius: 2px;
}
.nav-links li a:hover, .nav-links li a.active { color: var(--text-main); }
.nav-links li a:hover::after, .nav-links li a.active::after { width: 100%; }

/* Mobile Menu & Overlay */
.mobile-menu-btn {
    display: none; flex-direction: column; gap: 6px; cursor: pointer; z-index: 1001;
}
.mobile-menu-btn span {
    width: 30px; height: 3px; background: var(--text-main);
    border-radius: 3px; transition: var(--transition);
}
.mobile-menu-btn.active span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.mobile-menu-btn.active span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.active span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }
.mobile-menu-overlay {
    position: fixed; top: 0; left: 0; width: 100%; height: 100vh;
    background: rgba(15, 23, 42, 0.95); backdrop-filter: blur(10px);
    z-index: 999; display: flex; align-items: center; justify-content: center;
    opacity: 0; pointer-events: none; transition: var(--transition);
}
.mobile-menu-overlay.active { opacity: 1; pointer-events: all; }
.mobile-nav-links {
    display: flex; flex-direction: column; gap: 2rem; text-align: center;
    transform: translateY(20px); transition: var(--transition);
}
.mobile-menu-overlay.active .mobile-nav-links { transform: translateY(0); }
.mobile-nav-links a { font-size: 1.5rem; font-weight: 600; color: var(--text-main); }

/* Hero Section */
.hero {
    position: relative; min-height: 100vh; display: flex;
    align-items: center; justify-content: center;
    padding: 8rem 2rem 4rem; overflow: hidden;
}
.hero-bg {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background-size: cover; background-position: center; background-repeat: no-repeat;
    z-index: -2; transform: scale(1.05);
    animation: slowZoom 20s ease-in-out infinite alternate;
}
@keyframes slowZoom {
    0% { transform: scale(1.05); } 100% { transform: scale(1.1); }
}
.hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.7), rgba(15, 23, 42, 0.95));
    z-index: -1;
}
.hero-content {
    text-align: center; max-width: 800px; z-index: 1;
    display: flex; flex-direction: column; align-items: center;
    opacity: 0; transform: translateY(30px);
    animation: fadeUp 1s ease forwards 0.3s;
}
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }
.badge {
    background: rgba(14, 165, 233, 0.2); border: 1px solid rgba(14, 165, 233, 0.5);
    color: #38bdf8; padding: 0.4rem 1rem; border-radius: 30px;
    font-size: 0.85rem; font-weight: 600; letter-spacing: 1px; margin-bottom: 1.5rem;
}
.hero-title { font-size: clamp(3rem, 5vw, 4.5rem); margin-bottom: 1.5rem; line-height: 1.1; }
.hero-subtitle {
    font-size: 1.1rem; color: var(--text-muted); margin-bottom: 2.5rem; max-width: 600px;
}
.hero-cta { display: flex; gap: 1rem; }
.scroll-indicator {
    position: absolute; bottom: 2rem; left: 50%; transform: translateX(-50%);
    display: flex; flex-direction: column; align-items: center; gap: 0.5rem;
    opacity: 0.7; animation: bounce 2s infinite;
}
.scroll-indicator .mouse {
    width: 24px; height: 36px; border: 2px solid var(--text-muted);
    border-radius: 12px; position: relative;
}
.scroll-indicator .mouse::before {
    content: ''; position: absolute; top: 6px; left: 50%; transform: translateX(-50%);
    width: 4px; height: 6px; background: var(--text-main); border-radius: 2px;
    animation: scrollWheel 1.5s infinite;
}
.scroll-indicator p { font-size: 0.75rem; letter-spacing: 1px; color: var(--text-muted); }
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateY(0) translateX(-50%); }
    40% { transform: translateY(-10px) translateX(-50%); }
    60% { transform: translateY(-5px) translateX(-50%); }
}
@keyframes scrollWheel {
    0% { opacity: 1; top: 6px; } 100% { opacity: 0; top: 16px; }
}

/* Sections Common */
.section-header { text-align: center; margin-bottom: 4rem; }
.section-header h2 {
    font-size: 2.5rem; margin-bottom: 1rem; display: inline-block; position: relative;
}
.section-header h2::after {
    content: ''; position: absolute; bottom: -10px; left: 50%;
    transform: translateX(-50%); width: 60px; height: 3px;
    background: var(--primary); border-radius: 2px;
}
.section-header p {
    color: var(--text-muted); font-size: 1.1rem; max-width: 600px; margin: 0 auto;
}

/* Units Grid */
.units-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 2rem;
}
.unit-card {
    background: var(--bg-light); border-radius: 16px; overflow: hidden;
    border: 1px solid var(--glass-border); transition: var(--transition);
    display: flex; flex-direction: column; height: 100%; position: relative;
}
.unit-card:hover {
    transform: translateY(var(--card-hover-y));
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border-color: var(--unit-accent);
}
.unit-card-img { height: 220px; position: relative; overflow: hidden; }
.unit-card-img img {
    width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease;
}
.unit-card:hover .unit-card-img img { transform: scale(1.05); }
.unit-number {
    position: absolute; top: 1rem; left: 1rem;
    background: var(--unit-accent); color: #fff;
    font-weight: 800; font-size: 1.2rem; padding: 0.3rem 1rem;
    border-radius: 30px; box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}
.unit-card-body {
    padding: 2rem; display: flex; flex-direction: column; flex-grow: 1;
}
.unit-card-body h3 { font-size: 1.4rem; margin-bottom: 0.8rem; color: var(--text-main); }
.unit-card-body p {
    color: var(--text-muted); font-size: 0.95rem; margin-bottom: 1.5rem; flex-grow: 1;
}
.unit-enter {
    color: var(--unit-accent); font-weight: 600; display: flex;
    align-items: center; gap: 0.5rem; transition: var(--transition);
    align-self: flex-start;
}
.unit-card:hover .unit-enter { gap: 0.8rem; }

/* Unit Detail Pages */
.unit-hero {
    position: relative; padding: 10rem 2rem 6rem;
    min-height: 50vh; display: flex; align-items: flex-end; overflow: hidden;
}
.unit-hero-bg {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: -2;
}
.unit-hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.unit-hero-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.75), var(--bg-color)); z-index: -1;
}
.unit-hero-content {
    max-width: 1280px; margin: 0 auto; width: 100%; z-index: 1;
}
.back-link {
    display: inline-block; color: var(--text-muted); font-size: 0.95rem; font-weight: 600;
    margin-bottom: 2rem; transition: var(--transition);
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
}
.back-link:hover { color: #fff; transform: translateX(-5px); }
.unit-badge {
    display: inline-block; background: var(--unit-accent); color: #fff;
    padding: 0.3rem 1rem; border-radius: 20px; font-weight: 700; font-size: 0.9rem;
    margin-bottom: 1rem; box-shadow: 0 2px 8px rgba(0,0,0,0.5);
}
.unit-hero-content h1 {
    font-size: clamp(2.5rem, 4vw, 4rem); margin-bottom: 1rem; color: #ffffff;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8);
}
.unit-hero-desc {
    font-size: 1.25rem; color: #e2e8f0; max-width: 700px; font-weight: 500;
    text-shadow: 0 2px 10px rgba(0,0,0,0.9);
}
.unit-content-section { padding: 4rem 0 6rem; }
.unit-content-grid {
    display: grid; grid-template-columns: 1fr 300px; gap: 4rem; max-width: 1280px; margin: 0 auto;
}
.unit-main { display: flex; flex-direction: column; gap: 3rem; }
.content-block h2 {
    font-size: 1.8rem; margin-bottom: 1.5rem; padding-bottom: 0.8rem;
    border-bottom: 1px solid var(--glass-border); display: flex; align-items: center; gap: 0.8rem;
}
.content-block p {
    font-size: 1.05rem; color: var(--text-muted); line-height: 1.8;
}
.learning-objectives { list-style: none; padding: 0; }
.learning-objectives li {
    position: relative; padding-left: 2rem; margin-bottom: 1rem;
    color: var(--text-muted); font-size: 1.05rem;
}
.learning-objectives li::before {
    content: '✓'; position: absolute; left: 0; top: 2px;
    color: var(--unit-accent, var(--primary)); font-weight: bold;
}
.concept-cards {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 240px), 1fr)); gap: 1.5rem;
}
.concept-card {
    background: var(--bg-light); border: 1px solid var(--glass-border);
    border-radius: 12px; padding: 1.5rem; transition: var(--transition);
}
.concept-card:hover { transform: translateY(-5px); border-color: var(--unit-accent, var(--primary)); }
.concept-icon { font-size: 2.5rem; margin-bottom: 1rem; }
.concept-card h4 { font-size: 1.2rem; margin-bottom: 0.5rem; color: var(--text-main); }
.concept-card p { font-size: 0.9rem; color: var(--text-muted); margin: 0; }
.unit-sidebar { display: flex; flex-direction: column; gap: 2rem; }
.sidebar-card {
    background: var(--bg-light); border: 1px solid var(--glass-border);
    border-radius: 12px; padding: 1.5rem;
}
.sidebar-card h3 {
    font-size: 1.2rem; margin-bottom: 1.2rem; padding-bottom: 0.8rem;
    border-bottom: 1px solid var(--glass-border);
}
.unit-nav-list { display: flex; flex-direction: column; gap: 0.8rem; }
.unit-nav-item {
    display: flex; align-items: center; gap: 0.8rem; color: var(--text-muted);
    font-size: 0.95rem; transition: var(--transition); padding: 0.5rem; border-radius: 8px;
}
.nav-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.unit-nav-item:hover { background: rgba(255, 255, 255, 0.05); color: var(--text-main); }
.unit-nav-item.active { background: rgba(255, 255, 255, 0.1); color: var(--text-main); font-weight: 600; }
.sidebar-note { font-size: 0.9rem; color: var(--text-muted); font-style: italic; }
.unit-pagination {
    display: flex; justify-content: space-between; align-items: center;
    margin-top: 4rem; padding-top: 2rem; border-top: 1px solid var(--glass-border);
}
.pagination-btn {
    display: inline-flex; align-items: center; padding: 0.8rem 1.5rem;
    background: var(--bg-light); border: 1px solid var(--glass-border);
    border-radius: 50px; color: var(--text-main); font-weight: 500; transition: var(--transition);
}
.pagination-btn:hover:not(.disabled) {
    background: rgba(255, 255, 255, 0.1); border-color: rgba(255, 255, 255, 0.3); transform: translateY(-2px);
}
.pagination-btn.disabled { opacity: 0.5; cursor: not-allowed; }

/* Games Section */
.dark-section {
    background-color: var(--bg-light); border-top: 1px solid var(--glass-border); position: relative;
}
.dark-section::before {
    content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle at top right, rgba(14, 165, 233, 0.1) 0%, transparent 40%),
                radial-gradient(circle at bottom left, rgba(56, 189, 248, 0.05) 0%, transparent 40%);
    pointer-events: none;
}

/* ── Two-column games grid ── */
.games-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem;
}
.game-card {
    background: var(--bg-color); border: 1px solid var(--glass-border);
    border-radius: 20px; overflow: hidden;
    display: flex; flex-direction: column;
    transition: var(--transition);
}
.game-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 24px 50px rgba(0,0,0,0.4);
    border-color: rgba(245, 158, 11, 0.4);
}
.game-card-river:hover {
    border-color: rgba(14, 165, 233, 0.5);
    box-shadow: 0 24px 50px rgba(14, 165, 233, 0.15);
}
.game-card-preview { padding: 1.2rem 1.2rem 0; }
.game-card-info { padding: 1.5rem 1.8rem 1.8rem; display: flex; flex-direction: column; flex: 1; }

.game-badge {
    display: inline-block; padding: 0.3rem 0.8rem; background: rgba(245, 158, 11, 0.2);
    color: var(--accent); border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: 20px; font-size: 0.8rem; font-weight: 600; margin-bottom: 1rem;
}
.game-badge-river {
    background: rgba(14, 165, 233, 0.15); color: #38bdf8;
    border-color: rgba(14, 165, 233, 0.35);
}
.game-title { font-size: 1.6rem; margin-bottom: 0.8rem; }
.game-desc { color: var(--text-muted); margin-bottom: 1.2rem; font-size: 0.95rem; line-height: 1.7; flex: 1; }
.feature-list { margin-bottom: 1.5rem; }
.feature-list li {
    margin-bottom: 0.6rem; display: flex; align-items: center; gap: 0.7rem; color: var(--text-main); font-size: 0.95rem;
}
.check {
    color: var(--secondary); background: rgba(16, 185, 129, 0.1);
    width: 22px; height: 22px; display: flex; align-items: center;
    justify-content: center; border-radius: 50%; font-size: 0.8rem; flex-shrink: 0;
}
.check-river {
    color: #38bdf8; background: rgba(14, 165, 233, 0.12);
}
.action-wrap { display: flex; align-items: center; gap: 1.2rem; flex-wrap: wrap; }
.play-btn { font-size: 1rem; padding: 0.85rem 2rem; }
.play-btn-river {
    background: linear-gradient(135deg, #0ea5e9, #0284c7) !important;
    box-shadow: 0 4px 15px rgba(14,165,233,0.35) !important;
}
.play-btn-river:hover {
    box-shadow: 0 8px 25px rgba(14,165,233,0.55) !important;
}
.play-icon { margin-right: 0.4rem; font-size: 0.85em; }
.hint { font-size: 0.8rem; color: var(--text-muted); }

/* Glassmorphism preview frame */
.glass-frame {
    background: var(--glass-bg); border: 1px solid var(--glass-border);
    border-radius: 12px; padding: 10px; backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px); box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
    position: relative; overflow: hidden;
}
.glass-frame-river {
    border-color: rgba(14, 165, 233, 0.2);
    box-shadow: 0 20px 40px -10px rgba(14, 165, 233, 0.1);
}
.mock-browser {
    height: 26px; display: flex; align-items: center; padding: 0 8px; margin-bottom: 10px;
}
.dots { display: flex; gap: 5px; }
.dots span { width: 9px; height: 9px; border-radius: 50%; }
.dots span:nth-child(1) { background: #ef4444; }
.dots span:nth-child(2) { background: #f59e0b; }
.dots span:nth-child(3) { background: #10b981; }
.preview-img-container {
    position: relative; border-radius: 7px; overflow: hidden; aspect-ratio: 16/9;
}
.preview-img {
    width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease;
}
.play-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(15, 23, 42, 0.55); display: flex; align-items: center;
    justify-content: center; opacity: 0; transition: var(--transition);
}
.glass-frame:hover .play-overlay { opacity: 1; }
.glass-frame:hover .preview-img { transform: scale(1.05); }
.pulse-play {
    width: 64px; height: 64px; background: var(--primary);
    border-radius: 50%; display: flex; align-items: center; justify-content: center;
    font-size: 1.4rem; color: white; box-shadow: 0 0 0 0 rgba(14, 165, 233, 0.7);
    animation: pulse 2s infinite; text-decoration: none;
}
.pulse-play-river {
    background: linear-gradient(135deg, #0ea5e9, #7c3aed);
    box-shadow: 0 0 0 0 rgba(14, 165, 233, 0.7);
    animation: pulseRiver 2s infinite;
}
@keyframes pulse {
    0%   { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(14, 165, 233, 0.7); }
    70%  { transform: scale(1);    box-shadow: 0 0 0 18px rgba(14, 165, 233, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(14, 165, 233, 0); }
}
@keyframes pulseRiver {
    0%   { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(56, 189, 248, 0.6); }
    70%  { transform: scale(1);    box-shadow: 0 0 0 18px rgba(56, 189, 248, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(56, 189, 248, 0); }
}

/* ── River Preview Art (CSS-drawn game UI preview) ── */
.river-preview-bg {
    background: radial-gradient(ellipse at 35% 55%, #0d2550 0%, #020b18 65%);
}
.river-preview-art {
    position: absolute; inset: 0; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 0.7rem;
    padding: 1rem; pointer-events: none; z-index: 1;
}
.rpa-formula {
    display: flex; align-items: center; gap: 0.5rem;
    background: rgba(255,255,255,0.06); border: 1px solid rgba(99,179,255,0.2);
    border-radius: 10px; padding: 0.45rem 1rem;
    font-weight: 800; font-size: 0.85rem;
}
.rpa-q  { color: #38bdf8; }
.rpa-v  { color: #a78bfa; }
.rpa-e  { color: #f59e0b; }
.rpa-op { color: rgba(255,255,255,0.4); font-size: 0.9rem; }
.rpa-zones {
    display: flex; align-items: center; gap: 0.4rem;
}
.rpa-zone {
    font-size: 0.72rem; font-weight: 700; padding: 0.25rem 0.6rem;
    border-radius: 8px; border: 1px solid;
}
.rpa-erosion   { color: #ef4444; background: rgba(239,68,68,0.12);    border-color: rgba(239,68,68,0.35);   }
.rpa-transport { color: #a78bfa; background: rgba(167,139,250,0.12);  border-color: rgba(167,139,250,0.35); }
.rpa-deposit   { color: #34d399; background: rgba(52,211,153,0.12);   border-color: rgba(52,211,153,0.35);  }
.rpa-arrow { color: rgba(255,255,255,0.3); font-size: 0.65rem; }
.rpa-sliders { width: 100%; display: flex; flex-direction: column; gap: 0.35rem; }
.rpa-slider-row {
    display: flex; align-items: center; gap: 0.5rem; font-size: 0.7rem; color: rgba(255,255,255,0.55);
}
.rpa-slider-row span { min-width: 60px; white-space: nowrap; }
.rpa-bar {
    flex: 1; height: 4px; background: rgba(255,255,255,0.1);
    border-radius: 2px; overflow: hidden;
}
.rpa-fill {
    height: 100%; border-radius: 2px;
    background: linear-gradient(90deg, #1d5ea3, #38bdf8);
    transition: width 0.5s ease;
}
.rpa-fill-v { background: linear-gradient(90deg, #5b21b6, #a78bfa); }

/* Footer */
.footer {
    background: #0b1120; padding: 3rem 0; border-top: 1px solid rgba(255, 255, 255, 0.05);
}
.footer-content {
    display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 1rem;
}
.footer-brand { display: flex; align-items: center; gap: 0.8rem; opacity: 0.8; }
.copyright { color: var(--text-muted); font-size: 0.9rem; }

/* ── Game Launch Card (used in unit pages) ─────────────────────── */
.game-launch-card {
    position: relative; border-radius: 16px; overflow: hidden;
    border: 1px solid rgba(14, 165, 233, 0.3);
    background: var(--bg-light);
    transition: var(--transition);
}
.game-launch-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 50px rgba(14, 165, 233, 0.25);
    border-color: rgba(14, 165, 233, 0.6);
}
.glc-bg {
    position: absolute; inset: 0; z-index: 0;
    background: radial-gradient(ellipse at top left, rgba(14,165,233,0.12) 0%, transparent 60%),
                radial-gradient(ellipse at bottom right, rgba(16,185,129,0.08) 0%, transparent 60%);
    pointer-events: none;
}
.glc-body {
    position: relative; z-index: 1;
    display: flex; align-items: center; gap: 2rem;
    padding: 2rem 2.5rem;
    flex-wrap: wrap;
}
.glc-icon {
    font-size: 3.5rem; flex-shrink: 0;
    filter: drop-shadow(0 0 16px rgba(14,165,233,0.6));
    animation: floatIcon 3s ease-in-out infinite;
}
@keyframes floatIcon {
    0%, 100% { transform: translateY(0);    }
    50%       { transform: translateY(-6px); }
}
.glc-info { flex: 1; min-width: 200px; }
.glc-title {
    font-size: 1.5rem; font-weight: 800; margin-bottom: 0.5rem;
    background: linear-gradient(135deg, #38bdf8, #34d399);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
}
.glc-desc {
    font-size: 0.95rem; color: var(--text-muted);
    line-height: 1.7; margin-bottom: 1rem;
}
.glc-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.glc-tag {
    background: rgba(14, 165, 233, 0.12);
    border: 1px solid rgba(14, 165, 233, 0.3);
    color: #7dd3fc; padding: 0.25rem 0.75rem;
    border-radius: 20px; font-size: 0.82rem; font-weight: 500;
}
.glc-btn {
    display: inline-flex; align-items: center; gap: 0.6rem;
    padding: 0.9rem 2rem; border-radius: 50px; font-weight: 700;
    font-size: 1rem; color: #fff; flex-shrink: 0;
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    box-shadow: 0 4px 20px rgba(14, 165, 233, 0.4);
    transition: var(--transition); text-decoration: none;
}
.glc-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(14, 165, 233, 0.6);
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
}
.glc-btn svg { transition: transform 0.2s; }
.glc-btn:hover svg { transform: translateX(3px); }

/* ── Cinematic Game Cover Card (CGC) ─────────────────────────── */
.cgc-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid rgba(14,165,233,0.25);
    background: #07111f;
    box-shadow: 0 0 0 1px rgba(56,189,248,0.08), 0 24px 60px rgba(0,0,0,0.5);
    transition: var(--transition);
    min-height: 320px;
}
.cgc-wrap:hover {
    border-color: rgba(56,189,248,0.5);
    box-shadow: 0 0 0 1px rgba(56,189,248,0.2),
                0 32px 80px rgba(14,165,233,0.18),
                inset 0 0 80px rgba(14,165,233,0.04);
}

/* left canvas column */
.cgc-canvas-col {
    position: relative;
    overflow: hidden;
    background: #010811;
    min-height: 280px;
}
.cgc-canvas-col canvas { display: none; } /* canvas removed, kept for safety */

/* ── CSA: Pure-CSS Cinematic Static Art ── */
.csa-art {
    position: absolute;
    inset: 0;
    overflow: hidden;
    /* Night sky with scattered star dots */
    background:
        radial-gradient(circle, rgba(255,255,255,0.85) 0.8px, transparent 0.8px) 12px 8px / 58px 48px,
        radial-gradient(circle, rgba(148,210,252,0.70) 0.8px, transparent 0.8px) 35px 22px / 74px 64px,
        radial-gradient(circle, rgba(167,139,250,0.60) 0.7px, transparent 0.7px) 55px 5px  / 88px 68px,
        radial-gradient(circle, rgba(255,255,255,0.50) 0.6px, transparent 0.6px) 170px 35px / 79px 54px,
        radial-gradient(circle, rgba(148,210,252,0.45) 0.6px, transparent 0.6px) 220px 14px / 92px 72px,
        radial-gradient(circle, rgba(255,255,255,0.40) 0.5px, transparent 0.5px) 290px 40px / 66px 50px,
        /* Deep sky gradient */
        linear-gradient(180deg, #010811 0%, #0a1628 45%, #091d3e 100%);
    display: flex;
    align-items: stretch;
}
/* Aurora shimmer pseudo-layer */
.csa-art::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; height: 42%;
    background: linear-gradient(90deg,
        transparent 5%,
        rgba(56,189,248,0.07) 25%,
        rgba(167,139,250,0.09) 50%,
        rgba(52,211,153,0.07) 75%,
        transparent 95%);
    animation: csaAurora 7s ease-in-out infinite alternate;
    z-index: 1;
}
@keyframes csaAurora {
    from { opacity: 0.5; transform: translateX(-10px); }
    to   { opacity: 1;   transform: translateX(10px); }
}
/* Canyon walls gradient overlay */
.csa-art::after {
    content: '';
    position: absolute; inset: 0;
    background:
        linear-gradient(to right,  #070f1c 0%, #112236 16%, rgba(11,34,54,0.4) 26%, transparent 32%),
        linear-gradient(to left,   #070f1c 0%, #112236 16%, rgba(11,34,54,0.4) 26%, transparent 32%);
    pointer-events: none;
    z-index: 2;
}
/* Canyon strata lines */
.csa-river {
    position: absolute;
    left: 27%; right: 27%;
    top: 26%; bottom: 20%;
    background: linear-gradient(180deg,
        #04183a 0%, #07286a 35%,
        #082d5c 60%, #04183a 100%);
    border-radius: 3px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    z-index: 3;
}
/* Horizontal wave lines via repeating gradient */
.csa-river::before {
    content: '';
    position: absolute; inset: 0;
    background: repeating-linear-gradient(
        180deg,
        transparent 0, transparent 12px,
        rgba(56,189,248,0.10) 12px, rgba(56,189,248,0.10) 13px
    );
    z-index: 1;
}
.csa-zone { flex: 1; }
/* Energy zone glows */
.csa-e { background: radial-gradient(ellipse 80% 70% at 50% 30%, rgba(239,68,68,0.38) 0%, transparent 100%); animation: csaPulse 3.2s ease-in-out infinite; }
.csa-t { background: radial-gradient(ellipse 80% 70% at 50% 50%, rgba(167,139,250,0.28) 0%, transparent 100%); animation: csaPulse 3.8s ease-in-out infinite 0.6s; }
.csa-d { background: radial-gradient(ellipse 80% 70% at 50% 70%, rgba(52,211,153,0.32) 0%, transparent 100%); animation: csaPulse 4.4s ease-in-out infinite 1.2s; }
@keyframes csaPulse {
    0%, 100% { opacity: 0.65; }
    50%       { opacity: 1.0; }
}
/* HUD formula pill */
.csa-hud {
    position: absolute; top: 9%; left: 50%; transform: translateX(-50%);
    background: rgba(6,18,40,0.88);
    border: 1px solid rgba(56,189,248,0.45);
    border-radius: 8px;
    padding: 0.22rem 0.85rem;
    font-size: clamp(0.6rem, 1.4vw, 0.82rem);
    font-weight: 700; color: #fbbf24;
    white-space: nowrap; letter-spacing: 0.3px;
    z-index: 10; backdrop-filter: blur(6px);
    box-shadow: 0 0 12px rgba(56,189,248,0.15);
}
/* Zone badge row */
.csa-badges {
    position: absolute; top: 21%; left: 50%; transform: translateX(-50%);
    display: flex; gap: 0.35rem; z-index: 10;
}
.csa-b {
    padding: 0.12rem 0.5rem; border-radius: 6px;
    font-size: clamp(0.55rem, 1.1vw, 0.7rem);
    font-weight: 700; border: 1px solid;
    white-space: nowrap; backdrop-filter: blur(4px);
}
.csa-be { color:#ef4444; background:rgba(239,68,68,0.18);   border-color:rgba(239,68,68,0.45); }
.csa-bt { color:#a78bfa; background:rgba(167,139,250,0.18); border-color:rgba(167,139,250,0.45); }
.csa-bd { color:#34d399; background:rgba(52,211,153,0.18);  border-color:rgba(52,211,153,0.45); }
/* Cinematic title */
.csa-title {
    position: absolute; bottom: 7%; left: 50%; transform: translateX(-50%);
    font-family: "Noto Sans TC","Outfit",sans-serif;
    font-size: clamp(0.9rem, 3.2vw, 1.75rem);
    font-weight: 900; white-space: nowrap; z-index: 10;
    background: linear-gradient(135deg, #38bdf8 0%, #a5f3fc 50%, #34d399 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 0 14px rgba(56,189,248,0.55));
}
.cgc-canvas-overlay {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    background: rgba(1,8,17,0);
    transition: background 0.3s ease;
    z-index: 2;
}
.cgc-canvas-col:hover .cgc-canvas-overlay {
    background: rgba(1,8,17,0.35);
}
.cgc-play-btn {
    width: 68px; height: 68px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(14,165,233,0.9), rgba(124,58,237,0.9));
    display: flex; align-items: center; justify-content: center;
    font-size: 1.5rem; color: #fff; text-decoration: none;
    opacity: 0; transform: scale(0.7);
    transition: opacity 0.3s ease, transform 0.3s ease;
    box-shadow: 0 0 30px rgba(14,165,233,0.6),
                0 0 60px rgba(14,165,233,0.3);
    animation: cgcPulse 2.5s ease-in-out infinite;
}
@keyframes cgcPulse {
    0%,100% { box-shadow: 0 0 20px rgba(14,165,233,0.5), 0 0 0 0 rgba(14,165,233,0.4); }
    50%      { box-shadow: 0 0 30px rgba(14,165,233,0.7), 0 0 18px rgba(14,165,233,0); }
}
.cgc-canvas-col:hover .cgc-play-btn {
    opacity: 1; transform: scale(1);
}
.cgc-play-icon {
    position: relative; left: 2px; /* optical centering for ▶ */
}
.cgc-corner-badge {
    position: absolute; top: 12px; left: 12px; z-index: 3;
    background: rgba(14,165,233,0.18);
    border: 1px solid rgba(56,189,248,0.4);
    color: #7dd3fc; font-size: 0.75rem; font-weight: 700;
    padding: 0.2rem 0.7rem; border-radius: 20px;
    letter-spacing: 0.5px;
    backdrop-filter: blur(4px);
}

/* right info column */
.cgc-info-col {
    padding: 2rem 2.2rem;
    display: flex; flex-direction: column; gap: 1rem;
    background: linear-gradient(135deg,
        rgba(8,24,50,0.95) 0%,
        rgba(10,20,40,0.98) 100%);
    border-left: 1px solid rgba(56,189,248,0.12);
}
.cgc-badge {
    display: inline-block; align-self: flex-start;
    background: rgba(14,165,233,0.12);
    border: 1px solid rgba(56,189,248,0.3);
    color: #7dd3fc; font-size: 0.78rem; font-weight: 600;
    padding: 0.2rem 0.75rem; border-radius: 20px;
}
.cgc-title {
    font-size: 1.8rem; font-weight: 900; margin: 0;
    background: linear-gradient(135deg, #38bdf8 0%, #a5f3fc 50%, #34d399 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
    background-clip: text; line-height: 1.2;
}
.cgc-subtitle {
    font-size: 0.9rem; color: rgba(148,163,184,0.8); margin: -0.5rem 0 0;
    font-weight: 400; letter-spacing: 0.5px;
}
.cgc-formula {
    display: flex; align-items: center; flex-wrap: wrap; gap: 0.4rem;
    background: rgba(6,18,40,0.7);
    border: 1px solid rgba(56,189,248,0.2);
    border-radius: 10px; padding: 0.55rem 1rem;
    font-weight: 800; font-size: 0.88rem;
}
.cgc-f-e  { color: #fbbf24; }
.cgc-f-q  { color: #38bdf8; }
.cgc-f-v  { color: #a78bfa; }
.cgc-f-op { color: rgba(255,255,255,0.35); font-size: 0.9rem; }
.cgc-desc {
    font-size: 0.92rem; color: var(--text-muted);
    line-height: 1.75; margin: 0;
}
.cgc-desc strong { color: #38bdf8; }

/* zone badges row */
.cgc-zones {
    display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap;
}
.cgc-zone {
    display: flex; flex-direction: column; align-items: center;
    padding: 0.4rem 0.8rem; border-radius: 10px;
    border: 1px solid;
    min-width: 60px; flex: 1;
}
.cgc-zone-erosion  { background:rgba(239,68,68,0.1);   color:#ef4444; border-color:rgba(239,68,68,0.3);   }
.cgc-zone-transport{ background:rgba(167,139,250,0.1);  color:#a78bfa; border-color:rgba(167,139,250,0.3); }
.cgc-zone-deposit  { background:rgba(52,211,153,0.1);   color:#34d399; border-color:rgba(52,211,153,0.3);  }
.cgz-icon  { font-size: 1.1rem; line-height: 1; }
.cgz-label { font-size: 0.82rem; font-weight: 700; margin-top: 0.15rem; }
.cgz-sub   { font-size: 0.7rem;  opacity: 0.65; }
.cgc-zone-arrow { color: rgba(255,255,255,0.2); font-size: 0.6rem; flex-shrink: 0; }

/* feature list */
.cgc-features {
    display: flex; flex-direction: column; gap: 0.45rem;
}
.cgc-feat {
    display: flex; align-items: center; gap: 0.55rem;
    font-size: 0.88rem; color: var(--text-muted);
}
.cgc-feat-dot {
    width: 7px; height: 7px; border-radius: 50%; flex-shrink: 0;
    background: var(--dc, #38bdf8);
    box-shadow: 0 0 6px var(--dc, #38bdf8);
}

/* action row */
.cgc-actions {
    display: flex; align-items: center; gap: 1.2rem;
    flex-wrap: wrap; margin-top: auto; padding-top: 0.5rem;
}
.cgc-launch-btn {
    display: inline-flex; align-items: center; gap: 0.6rem;
    padding: 0.85rem 1.8rem; border-radius: 50px;
    background: linear-gradient(135deg, #0ea5e9, #0284c7);
    color: #fff; font-weight: 700; font-size: 0.95rem;
    text-decoration: none; flex-shrink: 0;
    box-shadow: 0 4px 20px rgba(14,165,233,0.35);
    transition: var(--transition);
}
.cgc-launch-btn:hover {
    background: linear-gradient(135deg, #38bdf8, #0ea5e9);
    box-shadow: 0 8px 32px rgba(14,165,233,0.55);
    transform: translateY(-2px) scale(1.03);
}
.cgc-launch-btn svg { transition: transform 0.2s; }
.cgc-launch-btn:hover svg { transform: translateX(3px); }
.cgc-hint {
    font-size: 0.78rem; color: rgba(148,163,184,0.55);
}

/* ══════════════════════════════════════════════════════
   Unit-page Game Cards (.cgc-wrap) — Dark Theme Override
   Overrides inline background:#fff and light text colors
   ══════════════════════════════════════════════════════ */
.cgc-wrap {
    background: rgba(15, 23, 42, 0.82) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* Headings */
.cgc-wrap h3 {
    color: #f1f5f9 !important;
    -webkit-text-fill-color: #f1f5f9 !important;
}

/* Body text */
.cgc-wrap p {
    color: #94a3b8 !important;
}

/* Tag / badge spans (inline styled with #f1f5f9 bg) */
.cgc-wrap span[style] {
    background: rgba(255, 255, 255, 0.08) !important;
    color: #cbd5e1 !important;
}

/* Unit badge div (inline styled with light bg eg #fef3c7, #dcfce7) */
.cgc-wrap div[style*="inline-block"] {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #cbd5e1 !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
}


/* ══════════════════════════════════════════════════════
   Earth Art — c1_game1 地球內部探秘
   ══════════════════════════════════════════════════════ */
.glass-frame-earth { border-color: rgba(56,189,248,0.22); box-shadow: 0 20px 40px -10px rgba(56,189,248,0.12); }
.earth-preview-bg  { background: radial-gradient(ellipse at 42% 52%, #0a1428 0%, #010810 70%); }

.earth-art {
    position: absolute; inset: 0; overflow: hidden;
    background:
        radial-gradient(circle, rgba(255,255,255,0.85) 0.6px, transparent 0.6px) 12px 8px / 52px 42px,
        radial-gradient(circle, rgba(148,210,252,0.65) 0.7px, transparent 0.7px) 33px 20px / 68px 56px,
        radial-gradient(circle, rgba(167,139,250,0.55) 0.5px, transparent 0.5px) 52px 5px  / 80px 60px,
        radial-gradient(circle, rgba(255,255,255,0.40) 0.5px, transparent 0.5px) 160px 32px / 75px 50px,
        linear-gradient(180deg, #010810 0%, #040d1c 55%, #060b18 100%);
    display: flex; align-items: center; justify-content: center;
}
.earth-art::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 38%;
    background: linear-gradient(90deg,
        transparent 8%, rgba(14,165,233,0.07) 28%,
        rgba(167,139,250,0.09) 52%, rgba(52,211,153,0.06) 72%, transparent 92%);
    animation: earthAurora 6s ease-in-out infinite alternate; z-index: 1;
}
@keyframes earthAurora {
    from { opacity: 0.5; transform: translateX(-6px); }
    to   { opacity: 1;   transform: translateX(6px); }
}
.earth-globe {
    position: relative; z-index: 5;
    width: clamp(100px, 50%, 175px); aspect-ratio: 1; border-radius: 50%;
    background: radial-gradient(circle at 46% 46%,
        #ffe566 0%, #fbbf24 14%,
        #f97316 28%, #ea580c 40%,
        #b91c1c 52%, #7f1d1d 64%,
        #1e3a8a 74%, #1e40af 84%, #0f172a 93%);
    box-shadow:
        0 0 0 2px rgba(56,189,248,0.38),
        0 0 24px rgba(249,115,22,0.48),
        0 0 60px rgba(249,115,22,0.2),
        inset 0 0 18px rgba(0,0,0,0.5);
    animation: earthGlowPulse 3.5s ease-in-out infinite alternate;
}
@keyframes earthGlowPulse {
    from { box-shadow: 0 0 0 2px rgba(56,189,248,0.3), 0 0 22px rgba(249,115,22,0.42), 0 0 52px rgba(249,115,22,0.16), inset 0 0 18px rgba(0,0,0,0.5); }
    to   { box-shadow: 0 0 0 2px rgba(56,189,248,0.58), 0 0 34px rgba(249,115,22,0.68), 0 0 78px rgba(249,115,22,0.32), inset 0 0 18px rgba(0,0,0,0.5); }
}
.earth-globe::after {
    content: ''; position: absolute; top: 0; left: 50%; right: 0; bottom: 0;
    border-radius: 0 50% 50% 0;
    background: linear-gradient(135deg, rgba(56,189,248,0.09), transparent 60%);
    border-left: 1px solid rgba(56,189,248,0.38);
}
.earth-hud {
    position: absolute; top: 9%; left: 50%; transform: translateX(-50%);
    background: rgba(4,12,30,0.9); border: 1px solid rgba(56,189,248,0.42);
    border-radius: 8px; padding: 0.22rem 0.85rem;
    font-size: clamp(0.56rem, 1.1vw, 0.74rem); font-weight: 700; color: #7dd3fc;
    white-space: nowrap; letter-spacing: 0.5px; z-index: 10;
    backdrop-filter: blur(6px); box-shadow: 0 0 10px rgba(56,189,248,0.15);
}
.earth-layers {
    position: absolute; bottom: 17%; left: 50%; transform: translateX(-50%);
    display: flex; gap: 0.26rem; z-index: 10;
}
.earth-layer-b {
    padding: 0.1rem 0.42rem; border-radius: 5px;
    font-size: clamp(0.48rem, 0.88vw, 0.62rem); font-weight: 700;
    border: 1px solid; white-space: nowrap; backdrop-filter: blur(4px);
}
.el-inner  { color:#ffe566; background:rgba(255,229,102,0.15); border-color:rgba(255,229,102,0.42); }
.el-outer  { color:#f97316; background:rgba(249,115,22,0.15);  border-color:rgba(249,115,22,0.42); }
.el-mantle { color:#ef4444; background:rgba(239,68,68,0.15);   border-color:rgba(239,68,68,0.42); }
.el-crust  { color:#60a5fa; background:rgba(96,165,250,0.15);  border-color:rgba(96,165,250,0.42); }
.earth-art-title {
    position: absolute; bottom: 5%; left: 50%; transform: translateX(-50%);
    font-family: "Noto Sans TC","Outfit",sans-serif;
    font-size: clamp(0.76rem, 2.5vw, 1.38rem); font-weight: 900;
    white-space: nowrap; z-index: 10;
    background: linear-gradient(135deg, #38bdf8 0%, #a5f3fc 45%, #fbbf24 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
    filter: drop-shadow(0 0 12px rgba(56,189,248,0.55));
}
.pulse-play-earth {
    background: linear-gradient(135deg, #0ea5e9, #7c3aed);
    box-shadow: 0 0 0 0 rgba(14,165,233,0.7); animation: pulseEarth 2s infinite;
}
@keyframes pulseEarth {
    0%   { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(14,165,233,0.7); }
    70%  { transform: scale(1);    box-shadow: 0 0 0 18px rgba(14,165,233,0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(14,165,233,0); }
}

/* ══════════════════════════════════════════════════════
   Disaster Art — c1_game2 機會與風險：災害求生
   ══════════════════════════════════════════════════════ */
.glass-frame-disaster { border-color: rgba(239,68,68,0.25); box-shadow: 0 20px 40px -10px rgba(239,68,68,0.12); }
.dis-preview-bg { background: radial-gradient(ellipse at 50% 85%, #1f0306 0%, #080204 70%); }

.dis-art {
    position: absolute; inset: 0; overflow: hidden;
    background: linear-gradient(180deg, #090204 0%, #140308 48%, #0b0501 100%);
}
.dis-art::before {
    content: ''; position: absolute; inset: 0;
    background:
        radial-gradient(ellipse 62% 52% at 16% 75%, rgba(239,68,68,0.30) 0%, transparent 60%),
        radial-gradient(ellipse 52% 44% at 50% 78%, rgba(245,158,11,0.24) 0%, transparent 60%),
        radial-gradient(ellipse 62% 52% at 84% 75%, rgba(56,189,248,0.18) 0%, transparent 60%);
    animation: disAtmos 4.5s ease-in-out infinite alternate; z-index: 1;
}
@keyframes disAtmos {
    from { opacity: 0.65; } to { opacity: 1; }
}
.dis-art::after {
    content: ''; position: absolute; top: 0; left: 0; right: 0; height: 28%;
    background: repeating-linear-gradient(
        90deg, transparent 0, transparent 3px,
        rgba(255,255,255,0.012) 3px, rgba(255,255,255,0.012) 5px);
    z-index: 2; pointer-events: none;
}
.dis-zones {
    position: absolute; inset: 0; display: grid;
    grid-template-columns: 1fr 1fr 1fr; z-index: 3;
}
.dis-zone {
    display: flex; flex-direction: column; align-items: center;
    justify-content: center; gap: 0.32rem; padding: 1rem 0.4rem; position: relative;
}
.dis-zone:not(:last-child)::after {
    content: ''; position: absolute; right: 0; top: 18%; bottom: 18%; width: 1px;
    background: linear-gradient(180deg, transparent, rgba(255,255,255,0.07), transparent);
}
.dis-zone-icon {
    font-size: clamp(1.6rem, 4.5vw, 2.6rem);
    animation: disIconFloat 3.2s ease-in-out infinite;
}
.dis-quake-zone  .dis-zone-icon { animation-delay: 0.9s; }
.dis-tsunami-zone .dis-zone-icon { animation-delay: 1.8s; }
@keyframes disIconFloat {
    0%, 100% { transform: translateY(0); } 50% { transform: translateY(-5px); }
}
.dis-zone-label {
    font-size: clamp(0.52rem, 1.1vw, 0.7rem); font-weight: 700;
    letter-spacing: 0.8px; padding: 0.12rem 0.48rem;
    border-radius: 5px; border: 1px solid; white-space: nowrap;
}
.dis-volcano-zone .dis-zone-label { color:#ef4444; background:rgba(239,68,68,0.15);  border-color:rgba(239,68,68,0.42);  }
.dis-quake-zone  .dis-zone-label { color:#f59e0b; background:rgba(245,158,11,0.15); border-color:rgba(245,158,11,0.42); }
.dis-tsunami-zone .dis-zone-label{ color:#38bdf8; background:rgba(56,189,248,0.15); border-color:rgba(56,189,248,0.42); }
.dis-hud {
    position: absolute; top: 9%; left: 50%; transform: translateX(-50%);
    background: rgba(18,4,6,0.92); border: 1px solid rgba(239,68,68,0.5);
    border-radius: 8px; padding: 0.22rem 0.85rem;
    font-size: clamp(0.56rem, 1.05vw, 0.72rem); font-weight: 700; color: #fca5a5;
    white-space: nowrap; letter-spacing: 0.5px; z-index: 10;
    backdrop-filter: blur(6px);
    animation: disWarnGlow 2.2s ease-in-out infinite alternate;
}
@keyframes disWarnGlow {
    from { box-shadow: 0 0 6px rgba(239,68,68,0.18); border-color: rgba(239,68,68,0.5); }
    to   { box-shadow: 0 0 18px rgba(239,68,68,0.5); border-color: rgba(239,68,68,0.9); }
}
.dis-art-title {
    position: absolute; bottom: 5%; left: 50%; transform: translateX(-50%);
    font-family: "Noto Sans TC","Outfit",sans-serif;
    font-size: clamp(0.72rem, 2.3vw, 1.28rem); font-weight: 900;
    white-space: nowrap; z-index: 10;
    background: linear-gradient(135deg, #ef4444 0%, #f97316 50%, #f59e0b 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
    filter: drop-shadow(0 0 12px rgba(239,68,68,0.6));
}
.pulse-play-disaster {
    background: linear-gradient(135deg, #ef4444, #f97316);
    box-shadow: 0 0 0 0 rgba(239,68,68,0.7); animation: pulseDisaster 2s infinite;
}
@keyframes pulseDisaster {
    0%   { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(239,68,68,0.7); }
    70%  { transform: scale(1);    box-shadow: 0 0 0 18px rgba(239,68,68,0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(239,68,68,0); }
}
/* game-card hover tints for new games */
#game-earth:hover    { border-color: rgba(56,189,248,0.45); }
#game-disasters:hover { border-color: rgba(239,68,68,0.45);
    box-shadow: 0 24px 50px rgba(239,68,68,0.18); }

/* ══════════════════════════════════════════════════════
   Farm Art — c5_game2 可道有機農場
   ══════════════════════════════════════════════════════ */
.glass-frame-farm { border-color: rgba(124,179,66,0.3); box-shadow: 0 20px 40px -10px rgba(124,179,66,0.14); }
.farm-preview-bg  { background: radial-gradient(ellipse at 50% 15%, #0d2a08 0%, #020801 75%); }

.farm-art {
    position: absolute; inset: 0; overflow: hidden;
    background:
        radial-gradient(circle, rgba(255,255,255,0.75) 0.5px, transparent 0.5px) 12px 8px / 50px 40px,
        radial-gradient(circle, rgba(196,230,130,0.50) 0.5px, transparent 0.5px) 34px 20px / 64px 52px,
        linear-gradient(180deg, #030d02 0%, #0a1c06 55%, #030d02 100%);
    display: flex; align-items: center; justify-content: center;
}
/* Sun glow */
.farm-art::before {
    content: '';
    position: absolute; top: 7%; left: 50%; transform: translateX(-50%);
    width: clamp(44px, 12%, 64px); aspect-ratio: 1; border-radius: 50%;
    background: radial-gradient(circle, #FFE082 0%, #FFA726 45%, transparent 75%);
    box-shadow: 0 0 30px rgba(255,193,7,0.55), 0 0 60px rgba(255,152,0,0.25);
    animation: farmSunGlow 3s ease-in-out infinite alternate; z-index: 2;
}
@keyframes farmSunGlow {
    from { box-shadow: 0 0 22px rgba(255,193,7,0.4), 0 0 44px rgba(255,152,0,0.18); }
    to   { box-shadow: 0 0 38px rgba(255,193,7,0.8), 0 0 70px rgba(255,152,0,0.38); }
}
/* Crop field rows */
.farm-art::after {
    content: '';
    position: absolute; bottom: 0; left: 0; right: 0; height: 42%;
    background: repeating-linear-gradient(
        0deg,
        rgba(124,179,66,0.65) 0px, rgba(124,179,66,0.65) 5px,
        rgba(56,142,60,0.45) 5px, rgba(56,142,60,0.45) 10px,
        rgba(109,76,46,0.35) 10px, rgba(109,76,46,0.35) 14px
    );
    z-index: 1;
}

/* Floating crop icon row */
.farm-icons-row {
    position: absolute; bottom: 43%; left: 50%; transform: translateX(-50%);
    display: flex; gap: 0.6rem; z-index: 10;
    font-size: clamp(1.3rem, 3.5vw, 2rem);
    animation: farmIconsFloat 2.8s ease-in-out infinite alternate;
}
@keyframes farmIconsFloat {
    from { transform: translateX(-50%) translateY(0); }
    to   { transform: translateX(-50%) translateY(-5px); }
}

/* HUD label */
.farm-hud {
    position: absolute; top: 9%; left: 50%; transform: translateX(-50%);
    background: rgba(2,8,1,0.88); border: 1px solid rgba(124,179,66,0.55);
    border-radius: 8px; padding: 0.22rem 0.85rem;
    font-size: clamp(0.55rem, 1.1vw, 0.72rem); font-weight: 700; color: #c5e8a0;
    white-space: nowrap; letter-spacing: 0.4px; z-index: 10;
    backdrop-filter: blur(6px); box-shadow: 0 0 12px rgba(124,179,66,0.18);
}

/* Farm tags */
.farm-tags {
    position: absolute; bottom: 17%; left: 50%; transform: translateX(-50%);
    display: flex; gap: 0.28rem; z-index: 10;
}
.ftag {
    padding: 0.1rem 0.44rem; border-radius: 5px;
    font-size: clamp(0.46rem, 0.86vw, 0.6rem); font-weight: 700;
    border: 1px solid; white-space: nowrap; backdrop-filter: blur(4px);
}
.ftag-org  { color:#a5d6a7; background:rgba(76,175,80,0.18);   border-color:rgba(76,175,80,0.5); }
.ftag-mgmt { color:#ffe082; background:rgba(255,193,7,0.15);   border-color:rgba(255,193,7,0.45); }
.ftag-quiz { color:#80cbc4; background:rgba(0,188,212,0.14);   border-color:rgba(0,188,212,0.4); }

/* Cinematic title */
.farm-art-title {
    position: absolute; bottom: 5%; left: 50%; transform: translateX(-50%);
    font-family: "Noto Sans TC","Outfit",sans-serif;
    font-size: clamp(0.76rem, 2.5vw, 1.35rem); font-weight: 900;
    white-space: nowrap; z-index: 10;
    background: linear-gradient(135deg, #a5d6a7 0%, #c5e8a0 45%, #ffe082 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
    filter: drop-shadow(0 0 12px rgba(124,179,66,0.6));
}

.pulse-play-farm {
    background: linear-gradient(135deg, #7cb342, #388e3c);
    box-shadow: 0 0 0 0 rgba(124,179,66,0.7); animation: pulseFarm 2s infinite;
}
@keyframes pulseFarm {
    0%   { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(124,179,66,0.7); }
    70%  { transform: scale(1);    box-shadow: 0 0 0 18px rgba(124,179,66,0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(124,179,66,0); }
}
#game-bearing:hover, #game-bearing-c5:hover {
    border-color: rgba(124,179,66,0.5);
    box-shadow: 0 24px 50px rgba(124,179,66,0.18);
}



.bearing-art {
    position: absolute; inset: 0; overflow: hidden;
    background:
        radial-gradient(circle, rgba(255,255,255,0.80) 0.6px, transparent 0.6px) 10px 7px / 48px 40px,
        radial-gradient(circle, rgba(196,181,253,0.60) 0.6px, transparent 0.6px) 30px 18px / 62px 52px,
        radial-gradient(circle, rgba(139,92,246,0.40) 0.5px, transparent 0.5px) 50px 4px  / 74px 56px,
        linear-gradient(180deg, #07030f 0%, #0f0722 55%, #07030f 100%);
    display: flex; align-items: center; justify-content: center;
}
.bearing-art::before {
    content: ''; position: absolute; inset: 0;
    background: radial-gradient(ellipse 70% 60% at 50% 50%, rgba(139,92,246,0.14) 0%, transparent 70%);
    animation: bearingAmbient 4.5s ease-in-out infinite alternate; z-index: 1;
}
@keyframes bearingAmbient {
    from { opacity: 0.4; } to { opacity: 1; }
}
.bearing-compass-wrap {
    position: relative; z-index: 5;
    width: clamp(100px, 48%, 165px); aspect-ratio: 1;
}
.bearing-compass-wrap .bcw-ring {
    position: absolute; inset: 0; border-radius: 50%;
    border: 2px solid rgba(139,92,246,0.5);
    box-shadow: 0 0 22px rgba(139,92,246,0.25), inset 0 0 18px rgba(139,92,246,0.1);
    animation: bcwRotate 18s linear infinite;
}
.bearing-compass-wrap .bcw-ring::before {
    content: ''; position: absolute; inset: 9px; border-radius: 50%;
    border: 1px dashed rgba(139,92,246,0.2);
}
@keyframes bcwRotate { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
/* Bearing line needle (static) */
.bearing-compass-wrap .bcw-needle {
    position: absolute; top: 50%; left: 50%;
    width: 2px; height: 46%;
    background: linear-gradient(180deg, #f43f5e 0%, rgba(244,63,94,0) 100%);
    transform-origin: bottom center;
    transform: translate(-50%, -100%) rotate(52deg);
    border-radius: 2px; z-index: 4;
}
.bearing-compass-wrap .bcw-needle-dot {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
    width: 8px; height: 8px; border-radius: 50%;
    background: #8b5cf6; box-shadow: 0 0 12px rgba(139,92,246,0.9); z-index: 5;
}
/* N S E W labels */
.bcw-n, .bcw-s, .bcw-e, .bcw-w {
    position: absolute; font-size: 0.58rem; font-weight: 900;
    font-family: 'Outfit', sans-serif; line-height: 1; z-index: 6;
}
.bcw-n { top: -2px;  left: 50%; transform: translateX(-50%); color: #f43f5e; }
.bcw-s { bottom: -2px; left: 50%; transform: translateX(-50%); color: #e2e8f0; }
.bcw-e { right: -3px; top: 50%; transform: translateY(-50%); color: #e2e8f0; }
.bcw-w { left: -3px;  top: 50%; transform: translateY(-50%); color: #e2e8f0; }

/* HUD label */
.bearing-hud {
    position: absolute; top: 9%; left: 50%; transform: translateX(-50%);
    background: rgba(10,4,28,0.88); border: 1px solid rgba(139,92,246,0.5);
    border-radius: 8px; padding: 0.22rem 0.85rem;
    font-size: clamp(0.55rem, 1.1vw, 0.72rem); font-weight: 700; color: #c4b5fd;
    white-space: nowrap; letter-spacing: 0.4px; z-index: 10;
    backdrop-filter: blur(6px); box-shadow: 0 0 12px rgba(139,92,246,0.18);
}

/* Stage badges */
.bearing-tags {
    position: absolute; bottom: 17%; left: 50%; transform: translateX(-50%);
    display: flex; gap: 0.28rem; z-index: 10;
}
.btag {
    padding: 0.1rem 0.44rem; border-radius: 5px;
    font-size: clamp(0.46rem, 0.86vw, 0.6rem); font-weight: 700;
    border: 1px solid; white-space: nowrap; backdrop-filter: blur(4px);
}
.btag-cp  { color:#c4b5fd; background:rgba(139,92,246,0.18); border-color:rgba(139,92,246,0.5); }
.btag-wcb { color:#38bdf8; background:rgba(56,189,248,0.15);  border-color:rgba(56,189,248,0.45); }
.btag-qb  { color:#34d399; background:rgba(52,211,153,0.15);  border-color:rgba(52,211,153,0.45); }

/* Cinematic title */
.bearing-art-title {
    position: absolute; bottom: 5%; left: 50%; transform: translateX(-50%);
    font-family: "Noto Sans TC","Outfit",sans-serif;
    font-size: clamp(0.76rem, 2.5vw, 1.35rem); font-weight: 900;
    white-space: nowrap; z-index: 10;
    background: linear-gradient(135deg, #a78bfa 0%, #c4b5fd 50%, #38bdf8 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
    filter: drop-shadow(0 0 14px rgba(139,92,246,0.55));
}

.pulse-play-bearing {
    background: linear-gradient(135deg, #8b5cf6, #6d28d9);
    box-shadow: 0 0 0 0 rgba(139,92,246,0.7); animation: pulseBearing 2s infinite;
}
@keyframes pulseBearing {
    0%   { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(139,92,246,0.7); }
    70%  { transform: scale(1);    box-shadow: 0 0 0 18px rgba(139,92,246,0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0  rgba(139,92,246,0); }
}
#game-bearing:hover {
    border-color: rgba(139,92,246,0.5);
    box-shadow: 0 24px 50px rgba(139,92,246,0.18);
}

/* Responsive Media Queries */
@media (max-width: 968px) {
    .games-grid { grid-template-columns: 1fr; }
    .unit-content-grid { grid-template-columns: 1fr; margin-left: auto; margin-right: auto; padding: 0 1rem; }
    /* CGC: stack canvas above info on tablet */
    .cgc-wrap { grid-template-columns: 1fr; }
    .cgc-canvas-col { min-height: 260px; }
    .cgc-info-col { border-left: none; border-top: 1px solid rgba(56,189,248,0.12); }
}
@media (max-width: 768px) {
    .section { padding: 4rem 0; }
    .container { padding: 0 1.5rem; }
    .hero { padding: 6rem 1.5rem 3rem; }
    .hero-title { font-size: 2.5rem; }
    .hero-subtitle { font-size: 1rem; }
    
    .unit-hero { padding: 7rem 1.5rem 3rem; min-height: 40vh; }
    .unit-hero-desc { font-size: 1rem; }
    .unit-content-section { padding: 3rem 0; }
    .unit-content-grid { padding: 0; gap: 2rem; }
    
    .nav-links { display: none; }
    .mobile-menu-btn { display: flex; }
    .action-wrap { flex-direction: column; align-items: flex-start; }
    
    .content-block h2 { font-size: 1.5rem; }
    .concept-card { padding: 1.2rem; }
    .sidebar-card { padding: 1.2rem; }
    
    .unit-pagination { flex-direction: column; gap: 1rem; margin-top: 2rem; }
    .pagination-btn { width: 100%; justify-content: center; text-align: center; }
}
@media (max-width: 480px) {
    .units-grid { gap: 1.5rem; }
    .unit-card-img { height: 180px; }
    .unit-card-body { padding: 1.5rem; }
    .game-title { font-size: 2rem; }
    .logo-title { font-size: 1.1rem; }
    /* CGC mobile */
    .cgc-canvas-col { min-height: 200px; }
    .cgc-info-col { padding: 1.4rem 1.2rem; gap: 0.8rem; }
    .cgc-title { font-size: 1.4rem; }
    .cgc-zones { gap: 0.3rem; }
    .cgc-zone { padding: 0.3rem 0.4rem; min-width: 50px; }
    .cgc-launch-btn { padding: 0.75rem 1.4rem; font-size: 0.9rem; }
}
