/**
Theme Name: Rab
Author: Rab
Author URI: https://rab.tw
Description: This is Astra Child Theme created by Rab.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rab
Template: astra
*/

.rab-footer-group { flex: 0 0 100%; width: 100%; margin: 0 0 4px; text-align: center; }
/* 頁尾「加入 LINE 討論群」：LINE 綠色按鈕，比一般文字連結明顯 */
.rab-footer-group .rab-line-group-btn { display: inline-flex; align-items: center; gap: 8px; margin: 10px 0 8px; padding: 10px 22px; border-radius: 999px; background: #06c755; color: #fff; font-size: 16px; font-weight: 700; line-height: 1.2; text-decoration: none; box-shadow: 0 2px 10px rgba(6, 199, 85, .3); transition: background .15s, transform .15s; }
.rab-footer-group .rab-line-group-btn:hover, .rab-footer-group .rab-line-group-btn:focus { background: #05b34c; color: #fff; transform: translateY(-1px); }
/* 手機：頁尾留空間，到底時 LINE 懸浮按鈕不會蓋住連結 */
@media (max-width: 760px) { .site-footer { padding-bottom: calc(90px + env(safe-area-inset-bottom)); } }
/* 跟 Astra「回到頂端」按鈕（right 30px、bottom 30px、約 32px 寬）對齊，疊在它上方 */
.rab-line-float { position: fixed; right: 22px; bottom: calc(74px + env(safe-area-inset-bottom)); z-index: 98; display: flex; align-items: center; justify-content: center; width: 48px; height: 48px; border-radius: 12px; background: #06c755; color: #fff; box-shadow: 0 2px 10px rgba(20, 33, 61, .2); }
.rab-line-float:hover, .rab-line-float:focus { background: #05b34c; color: #fff; }

/* 語言切換選單（主選單最右邊，手機選單內直接展開） */
.fc-lang-item { display: flex; align-items: center; margin-left: 8px; }
.fc-lang { position: relative; font-size: 14px; line-height: 1.4; }
.fc-lang summary { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border: 1px solid #d5deea; border-radius: 8px; cursor: pointer; list-style: none; white-space: nowrap; }
.fc-lang summary::-webkit-details-marker { display: none; }
.fc-lang ul { position: absolute; right: 0; top: calc(100% + 6px); z-index: 100; min-width: 150px; margin: 0; padding: 4px; list-style: none; background: #fff; border: 1px solid #d5deea; border-radius: 8px; box-shadow: 0 6px 18px rgba(20, 33, 61, .12); }
.fc-lang li { margin: 0; }
.fc-lang li a { display: flex; justify-content: space-between; align-items: center; padding: 6px 10px; border-radius: 6px; color: #14213d; line-height: 1.4; white-space: nowrap; }
.fc-lang li a:hover { background: #eef3fa; color: #14213d; }
.fc-lang li a[aria-current] { background: #e7f0ff; color: #0a66ff; }
.fc-lang li a[aria-current]::after { content: "✓"; margin-left: 12px; }
.ast-mobile-header-wrap .fc-lang-item { display: block; margin: 0; padding: 12px 20px; }
.ast-mobile-header-wrap .fc-lang ul { position: static; margin-top: 6px; box-shadow: none; }

/* 最上方跑馬燈（免費啟用活動） */
.rab-promo-bar { position: relative; z-index: 100; overflow: hidden; background: #0a66ff; }
.rab-promo-bar a { display: block; color: #fff; text-decoration: none; font-size: 14px; font-weight: 500; line-height: 38px; white-space: nowrap; }
.rab-promo-bar a:hover, .rab-promo-bar a:focus { color: #fff; }
.rab-promo-track { display: inline-flex; animation: rab-promo-scroll 60s linear infinite; }
.rab-promo-bar:hover .rab-promo-track, .rab-promo-bar a:focus .rab-promo-track { animation-play-state: paused; }
.rab-promo-group { display: inline-flex; flex-shrink: 0; }
.rab-promo-item { padding: 0 4em 0 0; }
@keyframes rab-promo-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (max-width: 640px) { .rab-promo-bar a { font-size: 13px; line-height: 34px; } .rab-promo-track { animation-duration: 45s; } }
@media (prefers-reduced-motion: reduce) {
	.rab-promo-track { animation: none; display: block; overflow: hidden; text-overflow: ellipsis; padding: 0 16px; }
	.rab-promo-group + .rab-promo-group, .rab-promo-item + .rab-promo-item { display: none; }
}
