/* ========== 兑换码查询系统 - Tailwind 补充动画 ========== */

/* 页面载入淡入 */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}
.animate-fade-up {
    animation: fadeUp 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* 交错动画延迟 */
.stagger-1 { animation-delay: 0.06s; }
.stagger-2 { animation-delay: 0.12s; }
.stagger-3 { animation-delay: 0.18s; }
.stagger-4 { animation-delay: 0.24s; }
.stagger-5 { animation-delay: 0.30s; }
.stagger-6 { animation-delay: 0.36s; }

/* Toast 入场动画 */
@keyframes toastIn {
    from { opacity: 0; transform: translateX(20px) scale(0.96); }
    to { opacity: 1; transform: translateX(0) scale(1); }
}
.toast-item {
    animation: toastIn 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* Toast 退出动画 */
@keyframes toastOut {
    from { opacity: 1; transform: translateX(0) scale(1); }
    to { opacity: 0; transform: translateX(20px) scale(0.96); }
}
.toast-out {
    animation: toastOut 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* 弹窗遮罩 */
@keyframes overlayIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
.animate-overlay {
    animation: overlayIn 0.2s ease both;
}

/* 弹窗内容 */
@keyframes modalPop {
    from { opacity: 0; transform: translateY(16px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.animate-modal {
    animation: modalPop 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* 登录卡片入场 */
@keyframes loginFloat {
    from { opacity: 0; transform: translateY(24px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.animate-login {
    animation: loginFloat 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* 按钮点击反馈 */
.btn-press:active {
    transform: scale(0.97);
}

/* 输入框聚焦环 */
.input-ring:focus {
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

/* 移动端下拉菜单（菜单按钮正下方） */
.nav-dropdown {
    position: absolute;
    top: 100%;
    right: 0.75rem;
    margin-top: 0.35rem;
    width: 220px;
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 14px;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.1), 0 2px 8px rgba(0, 0, 0, 0.04);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px) scale(0.97);
    transform-origin: top right;
    transition: opacity 0.2s ease, transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), visibility 0.2s;
    z-index: 200;
    overflow: hidden;
}
.nav-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

/* 弹窗显示控制 */
.modal-wrap {
    display: none;
}
.modal-wrap.active {
    display: flex;
}

/* 结果卡片悬浮 */
.result-card {
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.result-card:hover {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
}
