/* ANTW 短連結 前台樣式 (由 index.html 透過 /api/css 載入) */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Noto Sans TC", "Helvetica Neue", Arial, sans-serif;
    color: #1e293b;
    -webkit-tap-highlight-color: transparent;
    background: linear-gradient(135deg, #f5f9ff 0%, #eef5ff 52%, #fff8f2 100%);
}
body::before {
    content: ""; position: fixed; inset: -20%; z-index: -1; pointer-events: none;
    background: radial-gradient(circle at 18% 18%, rgba(125,211,252,.18), transparent 28%),
                radial-gradient(circle at 84% 72%, rgba(196,181,253,.18), transparent 30%);
    animation: softDrift 16s ease-in-out infinite alternate;
}
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #e2e8f0; border-radius: 4px; }
::-webkit-scrollbar-thumb { background: #94a3b8; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #64748b; }

.fade-in { animation: fadeIn .3s ease-in-out forwards; }
.pop-in  { animation: popIn .35s cubic-bezier(.175,.885,.32,1.275) forwards; }

#main-interface { box-shadow: 0 24px 65px rgba(76,111,160,.14); border-color: rgba(203,213,225,.72); }
#main-interface > div:first-child {
    background: linear-gradient(110deg, #4f8edb, #6475d7 60%, #8b78d2);
    background-size: 180% 180%; animation: headerFlow 9s ease infinite;
}
#url-input:focus { box-shadow: 0 0 0 4px rgba(96,165,250,.12); }
#btn-submit { box-shadow: 0 10px 24px rgba(59,130,246,.18); }
#btn-submit:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(59,130,246,.25); }
#btn-submit:disabled { opacity: .7; cursor: wait; transform: none; }
#modal-result > div, #modal-legal > div { box-shadow: 0 25px 70px rgba(51,65,85,.2); }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes popIn { from { opacity: 0; transform: scale(.95) translateY(10px); } to { opacity: 1; transform: scale(1) translateY(0); } }
@keyframes softDrift { from { transform: translate3d(-12px,-8px,0) scale(1); } to { transform: translate3d(16px,14px,0) scale(1.06); } }
@keyframes headerFlow { 0%,100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@media (prefers-reduced-motion: reduce) { body::before, #main-interface > div:first-child { animation: none; } }

/* 安全驗證彈窗：平常用 visibility 隱藏 (而不是 display:none)，讓 Turnstile 在背景也能正常執行，需要互動時才淡入 */
#modal-captcha { transition: opacity .2s ease, visibility .2s; }
#modal-captcha.cap-hidden { visibility: hidden; opacity: 0; pointer-events: none; }
