/* ===== CSS 变量系统 ===== */
:root {
    /* 颜色系统 */
    --color-primary: #48BB78;
    --color-success: #38A169;
    --color-warning: #D69E2E;
    --color-error: #E53E3E;
    --color-info: #3182CE;
    
    /* 中性色 */
    --color-white: #FFFFFF;
    --color-gray-50: #F7FAFC;
    --color-gray-100: #EDF2F7;
    --color-gray-200: #E2E8F0;
    --color-gray-300: #CBD5E0;
    --color-gray-400: #A0AEC0;
    --color-gray-500: #718096;
    --color-gray-600: #4A5568;
    --color-gray-700: #2D3748;
    --color-gray-800: #1A202C;
    --color-gray-900: #171923;
    
    /* 通知系统 */
    --notification-bg: rgba(255, 255, 255, 0.98);
    --notification-border: rgba(255, 255, 255, 0.2);
    --notification-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    --notification-radius: 16px;
    --notification-padding: 16px 20px;
    
    /* 动画时间 */
    --animation-duration-fast: 0.15s;
    --animation-duration-normal: 0.3s;
    --animation-duration-slow: 0.5s;
    
    /* 字体系统 */
    --font-family-base: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
    --font-size-sm: 14px;
    --font-size-base: 16px;
    --font-size-lg: 18px;
    --font-size-xl: 20px;
    
    /* 间距系统 */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    
    /* 层级系统 */
    --z-index-notification: 100000;
    --z-index-overlay: 999999;
}

/* 高对比度模式支持 */
@media (prefers-contrast: high) {
    :root {
        --notification-bg: #FFFFFF;
        --notification-border: #000000;
    }
}

/* 减少动画模式支持 */
@media (prefers-reduced-motion: reduce) {
    :root {
        --animation-duration-fast: 0.01s;
        --animation-duration-normal: 0.01s;
        --animation-duration-slow: 0.01s;
    }
}

body.AAS-active {
    overflow: hidden !important;
    height: 100% !important;
    width: 100% !important;
    position: fixed !important;
}

#AAS-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 60%;
    height: 95%;
    min-height: 100vh;
    background: linear-gradient(135deg, 
        #2C5530 0%, 
        #3A7A44 30%, 
        #4C956C 70%, 
        #6ABF69 100%
    );
    z-index: 999999;
    display: flex;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(12px) saturate(180%);
    -webkit-backdrop-filter: blur(12px) saturate(180%);
    margin: 0;
    padding: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
    animation: overlay-appear 0.6s ease-out;
}

@keyframes overlay-appear {
    from {
        opacity: 0;
        backdrop-filter: blur(0px);
    }
    to {
        opacity: 1;
        backdrop-filter: blur(12px) saturate(180%);
    }
}

.AAS-modal {
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.95) 0%, 
        rgba(255, 255, 255, 0.98) 100%
    );
    padding: 10px 5px 5px;
    border-radius: 20px;
    position: relative;
    width: 90%;
    max-width: 95%;
    box-shadow: 
        0 20px 60px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    animation: modal-appear 0.5s cubic-bezier(0.21, 0.61, 0.35, 1) both;
    overflow: hidden;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-sizing: border-box;
    max-height: 95vh;
    display: flex;
    flex-direction: column;
}

@keyframes modal-appear {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.AAS-content {
    text-align: center;
    overflow-y: auto;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.AAS-qrcode::before {
    content: "";
    position: absolute;
    top: -8px;
    left: -8px;
    right: -8px;
    bottom: -8px;
    background: linear-gradient(45deg, 
        rgba(76, 175, 80, 0.1) 0%, 
        rgba(76, 175, 80, 0.2) 50%, 
        rgba(76, 175, 80, 0.1) 100%
    );
    border-radius: 16px;
    z-index: -1;
    opacity: 0.8;
    animation: qrcode-glow 3s ease-in-out infinite alternate;
}

@keyframes qrcode-glow {
    from {
        opacity: 0.6;
        transform: scale(1);
    }
    to {
        opacity: 0.8;
        transform: scale(1.02);
    }
}

/* 修复图片点击问题 - 移除悬停效果 */
.AAS-qrcode img {
    max-width: 100%;
    height: auto;
    border-radius: 16px;
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.15),
        0 2px 4px rgba(0, 0, 0, 0.1);
    transition: none;
    border: 3px solid rgba(255, 255, 255, 0.9);
    pointer-events: none; /* 防止点击事件 */
}

.AAS-qrcode img:hover {
    transform: none;
    box-shadow: 
        0 8px 25px rgba(0, 0, 0, 0.15),
        0 2px 4px rgba(0, 0, 0, 0.1);
}

.AAS-form p {
    margin: 0 0 20px;
    color: #2D3748;
    font-size: 16px;
    line-height: 1.6;
    font-weight: 400;
}

.AAS-form div:first-of-type {
    font-size: 22px;
    font-weight: 700;
    color: #2D5A27;
    margin-bottom: 5px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    letter-spacing: -0.5px;
}

.AAS-form div:nth-of-type(2) {
    font-size: 17px;
    color: #4A5568;
    margin-bottom: 5px;
    font-weight: 500;
    opacity: 0.9;
}

.AAS-input-group {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: center;
}

#AAS-code {
    padding: 14px 20px;
    border: 2px solid #E2E8F0;
    border-radius: 12px;
    width: 100%;
    max-width: 300px;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 
        0 2px 6px rgba(0, 0, 0, 0.08),
        inset 0 1px 2px rgba(255, 255, 255, 0.9);
    background: rgba(255, 255, 255, 0.95);
    font-weight: 500;
}

#AAS-code:focus {
    border-color: #48BB78;
    outline: none;
    box-shadow: 
        0 0 0 4px rgba(72, 187, 120, 0.15),
        0 2px 8px rgba(0, 0, 0, 0.12);
    transform: translateY(-1px);
}

#AAS-code::placeholder {
    color: #A0AEC0;
    font-weight: 400;
}

/* 加载状态样式 */
.AAS-loading-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    min-height: 200px;
}

.AAS-loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #48BB78;
    border-radius: 50%;
    animation: AAS-spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes AAS-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.AAS-loading-text {
    color: #4A5568;
    font-size: 18px;
    font-weight: 500;
    text-align: center;
    line-height: 1.5;
}

#AAS-submit {
    padding: 14px 32px;
    background: linear-gradient(135deg, 
        #48BB78 0%, 
        #38A169 100%
    );
    color: #fff;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 16px;
    font-weight: 600;
    box-shadow: 
        0 6px 20px rgba(72, 187, 120, 0.4),
        0 2px 4px rgba(0, 0, 0, 0.1);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    position: relative;
    overflow: hidden;
}

#AAS-submit::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.6s ease;
}

#AAS-submit:hover {
    background: linear-gradient(135deg, 
        #4FD1C5 0%, 
        #319795 100%
    );
    transform: translateY(-3px);
    box-shadow: 
        0 10px 25px rgba(79, 209, 197, 0.5),
        0 4px 8px rgba(0, 0, 0, 0.15);
}

#AAS-submit:hover::before {
    left: 100%;
}

#AAS-submit:active {
    transform: translateY(0);
    box-shadow: 
        0 4px 12px rgba(79, 209, 197, 0.4),
        0 1px 2px rgba(0, 0, 0, 0.1);
}

/* 新的谜题区域样式 */
.AAS-puzzle {
    margin: 5px 0;
    padding: 5px;
    background: linear-gradient(135deg, 
        rgba(248, 249, 250, 0.95) 0%, 
        rgba(233, 236, 239, 0.98) 100%
    );
    border-radius: 16px;
    border-left: 6px solid #48BB78;
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    text-align: left;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.puzzle-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 5px;
    padding-bottom: 5px;
    border-bottom: 2px solid rgba(72, 187, 120, 0.2);
}

.puzzle-icon {
    font-size: 24px;
    animation: puzzle-icon 2s ease-in-out infinite;
}

.puzzle-title {
    font-size: 21px;
    font-weight: 700;
    color: #2D5A27;
    margin: 0;
}

.puzzle-content {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.puzzle-keyword {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: linear-gradient(135deg, 
        rgba(72, 187, 120, 0.1) 0%, 
        rgba(72, 187, 120, 0.15) 100%
    );
    border-radius: 10px;
    border: 1px solid rgba(72, 187, 120, 0.2);
}

.keyword-label {
    font-size: 15px;
    font-weight: 600;
    color: #4A5568;
}

.keyword-value {
    font-size: 16px;
    font-weight: 700;
    color: #2D5A27;
    border-radius: 8px;
}

.puzzle-text {
    font-size: 18px;
    font-weight: 600;
    color: #2D3748;
    padding: 5px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 12px;
    border: 2px solid #E2E8F0;
    text-align: center;
    line-height: 1.5;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

.puzzle-rule {
    font-size: 14px;
    color: #718096;
    font-style: italic;
    text-align: center;
    padding-top: 12px;
    border-top: 2px dashed #E2E8F0;
    margin-top: 5px;
    font-weight: 400;
}

@keyframes puzzle-icon {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(10deg) scale(1.1); }
}

.AAS-help {
    font-size: 15px !important;
}

.AAS-keyword {
    color: #2D5A27;
    font-weight: 700;
    padding: 4px 10px;
    background: linear-gradient(135deg, 
        rgba(72, 187, 120, 0.15) 0%, 
        rgba(72, 187, 120, 0.25) 100%
    );
    border-radius: 8px;
    display: inline-block;
    margin: 0 3px;
    border: 1px solid rgba(72, 187, 120, 0.2);
    animation: keyword-pulse 2s ease-in-out infinite;
}

@keyframes keyword-pulse {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 2px 8px rgba(72, 187, 120, 0.2);
    }
    50% { 
        transform: scale(1.05);
        box-shadow: 0 4px 12px rgba(72, 187, 120, 0.3);
    }
}



/* 错误动画效果 - 升级版 */
.error-shake {
    animation: shake 0.6s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes shake {
    10%, 90% {
        transform: translate3d(-2px, 0, 0);
    }
    
    20%, 80% {
        transform: translate3d(4px, 0, 0);
    }

    30%, 50%, 70% {
        transform: translate3d(-6px, 0, 0);
    }

    40%, 60% {
        transform: translate3d(6px, 0, 0);
    }
}

/* 主布局 - 左右面板 */
.AAS-main-layout {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
    align-items: stretch;
}

.AAS-left-panel {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

.AAS-right-panel {
    flex: 0 0 auto;
    min-width: 0;
    width: 30%;
    overflow: hidden;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .AAS-modal {
        width: 90%;
        max-width: 90%;
        padding: 12px 10px 10px;
        border-radius: 15px;
        margin: 8px;
        box-sizing: border-box;
        overflow: hidden;
    }
    
    .AAS-right-panel {
        width: 35%;
    }
    
    .AAS-puzzle {
        margin: 5px 0;
        padding: 5px;
    }
    
    .puzzle-text {
        font-size: 17px;
    }
    
    .AAS-title {
        font-size: 22px;
    }
    
    .AAS-subtitle {
        font-size: 16px;
    }
}

@media (max-width: 768px) {
    #AAS-overlay {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100vw;
        height: 100vh;
        min-height: 100vh;
        display: flex;
        justify-content: center;
        align-items: center;
        margin: 0;
        padding: 8px;
    }
    
    .AAS-modal {
        width: 95%;
        max-width: 95%;
        padding: 10px 8px 8px;
        border-radius: 10px;
        margin: 5px;
        box-sizing: border-box;
        overflow: hidden;
    }
    
    .AAS-main-layout {
        flex-direction: column;
        width: 100%;
        overflow: hidden;
    }
    
    .AAS-left-panel, .AAS-right-panel {
        width: 100%;
        min-width: 0;
        overflow: hidden;
    }
    
    .AAS-right-panel {
        flex: none;
        width: 100%;
        order: -1;
        padding: 0;
        box-sizing: border-box;
        margin-bottom: 8px;
    }
    
    .AAS-input-group {
        flex-direction: column;
        gap: 8px;
        width: 100%;
    }
    
    #AAS-code {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 12px 15px;
        font-size: 15px;
    }
    
    #AAS-submit {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 12px 20px;
        font-size: 15px;
    }
    
    .AAS-qrcode img {
        max-width: 65%;
        height: auto;
        box-sizing: border-box;
    }
    
    .AAS-form div:first-of-type {
        font-size: 18px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        margin-bottom: 5px;
    }
    
    .AAS-form div:nth-of-type(2) {
        font-size: 15px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        margin-bottom: 5px;
    }
    
    .AAS-puzzle {
        padding: 5px;
        margin: 5px 0;
        box-sizing: border-box;
        overflow: hidden;
    }
    
    .puzzle-text {
        font-size: 15px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        padding: 12px;
        line-height: 1.4;
    }
    
    .puzzle-rule {
        font-size: 12px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        margin-top: 5px;
        line-height: 1.3;
    }
    
    .AAS-notification {
        width: auto;
        max-width: 90%;
        font-size: 14px;
        padding: 12px 20px;
        box-sizing: border-box;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    /* 移动端二维码区域优化 */
    .AAS-right-panel {
        text-align: center;
    }
    
    .AAS-qrcode {
        margin-bottom: 8px;
        width: 100%;
        box-sizing: border-box;
        padding: 8px;
    }
    
    .AAS-qrcode img {
        max-width: 65%;
        height: auto;
    }
    
    .AAS-help {
        font-size: 13px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        line-height: 1.3;
    }
    
    .AAS-header {
        margin-bottom: 8px;
    }
    
    .AAS-title {
        font-size: 20px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.3;
    }
    
    .AAS-subtitle {
        font-size: 15px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.3;
    }
    
    .puzzle-header {
        margin-bottom: 6px;
        padding-bottom: 6px;
    }
    
    .puzzle-content {
        gap: 10px;
    }
    
    .decoration-circle {
        display: none;
    }
    
    .AAS-qrcode-placeholder {
        padding: 12px;
    }
    
    .placeholder-icon {
        font-size: 32px;
    }
}

@media (max-width: 480px) {
    #AAS-overlay {
        padding: 5px;
    }
    
    .AAS-modal {
        padding: 6px 5px 5px;
        border-radius: 8px;
        margin: 3px;
        box-sizing: border-box;
        overflow: hidden;
    }    
    
    .AAS-qrcode {
        margin-bottom: 6px;
        width: 100%;
        box-sizing: border-box;
        padding: 6px;
    }
    
    .AAS-qrcode img {
        max-width: 55%;
        height: auto;
        box-sizing: border-box;
    }
    
    .AAS-form div:first-of-type {
        font-size: 16px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        margin-bottom: 4px;
        line-height: 1.2;
    }
    
    .AAS-puzzle h3 {
        font-size: 15px;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }
    
    .AAS-puzzle p {
        font-size: 12px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.2;
    }
        
    .AAS-puzzle {
        padding: 5px;
        margin: 5px 0;
        box-sizing: border-box;
        overflow: hidden;
    }
    
    .puzzle-text {
        font-size: 13px;
        padding: 10px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        line-height: 1.3;
        min-height: auto;
    }
    
    .puzzle-rule {
        font-size: 11px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        margin-top:5px;
        line-height: 1.2;
    }
    
    .AAS-input-group {
        gap: 6px;
    }
    
    #AAS-code {
        padding: 10px 12px;
        font-size: 14px;
    }
    
    #AAS-submit {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .AAS-help {
        font-size: 12px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        line-height: 1.2;
    }
    
    .AAS-header {
        margin-bottom: 6px;
    }
    
    .AAS-title {
        font-size: 16px;
        flex-direction: column;
        gap: 4px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.2;
    }
    
    .title-icon {
        font-size: 20px;
    }
    
    .AAS-subtitle {
        font-size: 13px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.2;
    }
        
    .puzzle-header {
        margin-bottom: 5px;
        padding-bottom: 5px;
    }
    
    .puzzle-content {
        gap: 8px;
    }
        
    .expiry-progress {
        height: 8px;
    }
    
    .expiry-time {
        font-size: 10px;
        padding: 1px 4px;
    }
    
    .AAS-qrcode-placeholder {
        padding: 10px;
    }
    
    .placeholder-icon {
        font-size: 28px;
    }
}

/* 加载动画 */
.AAS-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top: 3px solid #fff;
    animation: spin 1s linear infinite;
    margin-right: 10px;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 暗色模式支持 */
@media (prefers-color-scheme: dark) {
    .AAS-modal {
        background: linear-gradient(135deg, 
            rgba(45, 55, 72, 0.95) 0%, 
            rgba(26, 32, 44, 0.98) 100%
        );
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .AAS-form p,
    .AAS-form div:first-of-type,
    .AAS-form div:nth-of-type(2) {
        color: #E2E8F0;
    }
    
    #AAS-code {
        background: rgba(74, 85, 104, 0.3);
        border-color: #4A5568;
        color: #E2E8F0;
    }
    
    #AAS-code:focus {
        border-color: #48BB78;
    }
    
    .AAS-puzzle {
        background: linear-gradient(135deg, 
            rgba(45, 55, 72, 0.6) 0%, 
            rgba(26, 32, 44, 0.7) 100%
        );
        border-left-color: #48BB78;
    }
    
    .AAS-help {
        background: linear-gradient(135deg, 
            rgba(45, 55, 72, 0.6) 0%, 
            rgba(26, 32, 44, 0.7) 100%
        );
        border-color: #4A5568;
        color: #CBD5E0;
    }
}

/* 装饰性元素 */
.AAS-decoration {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.decoration-circle {
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(72, 187, 120, 0.1), rgba(79, 209, 197, 0.08));
    animation: float 6s ease-in-out infinite;
}

.decoration-circle.circle-1 {
    width: 80px;
    height: 80px;
    top: -20px;
    right: -20px;
    animation-delay: 0s;
}

.decoration-circle.circle-2 {
    width: 60px;
    height: 60px;
    bottom: 30px;
    left: -15px;
    animation-delay: 2s;
}

.decoration-circle.circle-3 {
    width: 40px;
    height: 40px;
    top: 50%;
    right: 30px;
    animation-delay: 4s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    50% {
        transform: translateY(-10px) rotate(10deg);
    }
}

/* 头部样式 */
.AAS-header {
    text-align: center;
    width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.AAS-title {
    font-size: 24px;
    font-weight: 700;
    color: #2D5A27;
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    word-wrap: break-word;
    overflow-wrap: break-word;
    width: 100%;
    box-sizing: border-box;
}

.title-icon {
    font-size: 28px;
    animation: bounce 2s ease-in-out infinite;
    flex-shrink: 0;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-5px);
    }
    60% {
        transform: translateY(-3px);
    }
}

.AAS-subtitle {
    font-size: 17px;
    color: #4A5568;
    font-weight: 500;
    opacity: 0.9;
    word-wrap: break-word;
    overflow-wrap: break-word;
    width: 100%;
    box-sizing: border-box;
}

/* 二维码占位符样式 */
.AAS-qrcode-placeholder {
    padding: 10px;
    background: linear-gradient(135deg, rgba(248, 249, 250, 0.8), rgba(233, 236, 239, 0.9));
    border-radius: 16px;
    border: 2px dashed #CBD5E0;
    text-align: center;
}

.placeholder-icon {
    font-size: 48px;
    margin-bottom: 5px;
    display: block;
}

.AAS-qrcode-placeholder p {
    margin: 0;
    color: #718096;
    font-size: 14px;
    font-weight: 500;
}
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.1);
    }
}

@keyframes shimmer {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

/* 按钮加载状态 */
.button-loader {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top: 2px solid #fff;
    animation: spin 1s linear infinite;
    margin-left: 8px;
}

/* 响应式调整 */
@media (min-width: 1200px) {
    .AAS-modal {
        max-width: 75%;
        padding: 18px 12px 12px;
    }    
    
    .AAS-right-panel {
        width: 28%;
    }
    
    .AAS-puzzle {
        margin: 5px 0;
        padding: 5px;
    }
    
    .puzzle-text {
        font-size: 20px;
    }
    
    .AAS-title {
        font-size: 26px;
    }
    
    .AAS-subtitle {
        font-size: 18px;
    }
    
    .AAS-help {
        font-size: 16px !important;
    }
}

@media (max-width: 1024px) {
    .AAS-help {
        font-size: 14px !important;
    }
}

@media (max-width: 768px) {
    .AAS-help {
        font-size: 13px !important;
    }
}

@media (max-width: 480px) {
    .AAS-help {
        font-size: 12px !important;
    }    
}

@media (max-width: 320px) {
    .AAS-help {
        font-size: 11px !important;
    }
}

@media (max-width: 320px) {
    #AAS-overlay {
        padding: 3px;
    }
    
    .AAS-modal {
        padding: 4px 3px 3px;
        border-radius: 6px;
    }
    
    .AAS-title {
        font-size: 14px;
    }
    
    .AAS-subtitle {
        font-size: 12px;
    }
    
    .AAS-puzzle {
        padding: 5px;
        margin: 5px 0;
    }
    
    .puzzle-text {
        font-size: 12px;
        padding: 8px;
    }
    
    .puzzle-rule {
        font-size: 10px;
        margin-top: 4px;
    }
    
    #AAS-code {
        padding: 8px 10px;
        font-size: 13px;
    }
    
    #AAS-submit {
        padding: 8px 12px;
        font-size: 13px;
    }
    
    .AAS-help {
        font-size: 11px;
    }
    
    .AAS-qrcode {
        padding: 5px;
    }
    
    .AAS-qrcode img {
        max-width: 65%;
        height: auto;
    }
    
    .AAS-help {
        font-size: 13px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        white-space: normal;
        line-height: 1.3;
    }
    
    .AAS-header {
        margin-bottom: 8px;
    }
    
    .AAS-title {
        font-size: 20px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.3;
    }
    
    .AAS-subtitle {
        font-size: 15px;
        word-wrap: break-word;
        overflow-wrap: break-word;
        line-height: 1.3;
    }    
}

@media (max-width: 480px) {
    .AAS-title {
        font-size: 20px;
        flex-direction: column;
        gap: 5px;
    }
    
    .title-icon {
        font-size: 24px;
    }
    
    .AAS-subtitle {
        font-size: 15px;
    }
    
    .AAS-qrcode-placeholder {
        padding: 15px;
    }
    
    .placeholder-icon {
        font-size: 32px;
    }
}

/* 暗色模式适配 */
@media (prefers-color-scheme: dark) {
    .AAS-title {
        color: #68D391;
    }
    
    .AAS-subtitle {
        color: #CBD5E0;
    }
    
    .AAS-qrcode-placeholder {
        background: linear-gradient(135deg, rgba(45, 55, 72, 0.6), rgba(26, 32, 44, 0.7));
        border-color: #4A5568;
    }
    
    .AAS-qrcode-placeholder p {
        color: #A0AEC0;
    }
    
    .footer-decoration {
        background: linear-gradient(90deg, 
            transparent, 
            rgba(104, 211, 145, 0.3), 
            transparent
        );
    }
}

/* 算法有效期显示样式 */
.AAS-expiry-container {
    margin: 25px 0;
    padding: 20px;
    background: linear-gradient(135deg, 
        rgba(248, 249, 250, 0.95) 0%, 
        rgba(233, 236, 239, 0.98) 100%
    );
    border-radius: 16px;
    border-left: 6px solid #4299E1;
    box-shadow: 
        0 4px 15px rgba(0, 0, 0, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    text-align: left;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.expiry-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 5px;
    padding-bottom: 2px;
    border-bottom: 2px solid rgba(66, 153, 225, 0.2);
}

.expiry-icon {
    font-size: 22px;
    animation: expiry-icon 2s ease-in-out infinite;
}

.expiry-title {
    font-size: 18px;
    font-weight: 700;
    color: #2B6CB0;
    margin: 0;
}

.expiry-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.expiry-timer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 15px;
    background: linear-gradient(135deg, 
        rgba(66, 153, 225, 0.1) 0%, 
        rgba(66, 153, 225, 0.15) 100%
    );
    border-radius: 10px;
    border: 1px solid rgba(66, 153, 225, 0.2);
}

.expiry-label {
    font-size: 15px;
    font-weight: 600;
    color: #4A5568;
}

/* 原始expiry-time样式已移至progress-bar内部 */

.expiry-progress {
    width: 100%;
    height: 12px;
    background: rgba(226, 232, 240, 0.8);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.progress-bar {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.progress-fill {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg, #4299E1, #63B3ED);
    border-radius: 6px;
    transition: width 1s linear;
    box-shadow: 0 0 8px rgba(66, 153, 225, 0.4);
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

.expiry-time {
    font-size: 12px;
    font-weight: 700;
    color:rgb(234, 66, 66);
    padding: 2px 6px;
    border-radius: 4px;
    width: auto;
    min-width: 50px;
    text-align: center;
    position: relative;
    z-index: 2;
}

.expiry-status {
    font-size: 14px;
    font-weight: 600;
    text-align: center;
    padding: 8px;
    border-radius: 8px;
    background: rgba(72, 187, 120, 0.1);
    color: #2F855A;
    border: 1px solid rgba(72, 187, 120, 0.2);
}

.expiry-status.warning {
    background: rgba(237, 137, 54, 0.1);
    color: #C05621;
    border-color: rgba(237, 137, 54, 0.2);
}

.expiry-status.danger {
    background: rgba(245, 101, 101, 0.1);
    color: #C53030;
    border-color: rgba(245, 101, 101, 0.2);
    animation: pulse 1s ease-in-out infinite;
}

@keyframes expiry-icon {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(15deg) scale(1.1); }
}

/* 帮助区域样式优化 */
.AAS-help {
    font-size: 15px !important;
    border-radius: 12px;
    color: #4A5568;
    text-align: center;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .AAS-expiry-container {
        padding: 15px;
        margin: 20px 0;
    }
    
    .expiry-title {
        font-size: 16px;
    }
    
    .expiry-timer {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }
    
    .expiry-time {
        align-self: center;
    }
}

@media (max-width: 480px) {
    .AAS-expiry-container {
        padding: 12px;
        margin: 15px 0;
    }
    
    .expiry-title {
        font-size: 15px;
    }
    
    .expiry-label, .expiry-time {
        font-size: 14px;
    }
}

/* 暗色模式适配 */
@media (prefers-color-scheme: dark) {
    .AAS-expiry-container {
        background: linear-gradient(135deg, 
            rgba(45, 55, 72, 0.6) 0%, 
            rgba(26, 32, 44, 0.7) 100%
        );
        border-left-color: #4299E1;
    }
    
    .expiry-title {
        color: #63B3ED;
    }
    
    .expiry-label {
        color: #CBD5E0;
    }
    
    .expiry-time {
        color: #63B3ED;
        background: rgba(66, 153, 225, 0.2);
        border-color: rgba(66, 153, 225, 0.3);
    }
    
    .expiry-progress {
        background: rgba(74, 85, 104, 0.8);
    }
    
    .expiry-status {
        background: rgba(72, 187, 120, 0.2);
        color: #68D391;
        border-color: rgba(72, 187, 120, 0.3);
    }
    
    .expiry-status.warning {
        background: rgba(237, 137, 54, 0.2);
        color: #F6AD55;
        border-color: rgba(237, 137, 54, 0.3);
    }
    
    .expiry-status.danger {
        background: rgba(245, 101, 101, 0.2);
        color: #FC8181;
        border-color: rgba(245, 101, 101, 0.3);
    }
}

/* 同步状态指示器样式 */
.AAS-sync-status {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    z-index: 10000;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    display: none;
    max-width: 300px;
    text-align: center;
}

.AAS-sync-syncing {
    background: linear-gradient(135deg, #4299E1 0%, #3182CE 100%);
    color: white;
    border: 1px solid #2B6CB0;
    animation: sync-pulse 1.5s infinite;
}

.AAS-sync-synced {
    background: linear-gradient(135deg, #48BB78 0%, #38A169 100%);
    color: white;
    border: 1px solid #2F855A;
}

.AAS-sync-error {
    background: linear-gradient(135deg, #F56565 0%, #E53E3E 100%);
    color: white;
    border: 1px solid #C53030;
}

@keyframes sync-pulse {
    0% { opacity: 0.8; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.02); }
    100% { opacity: 0.8; transform: scale(1); }
}

/* 同步完成动画 */
.AAS-sync-complete {
    animation: sync-complete 1.5s ease-out;
}

@keyframes sync-complete {
    0% { 
        background-color: rgba(72, 187, 120, 0.3);
        transform: scale(1);
    }
    50% { 
        background-color: rgba(72, 187, 120, 0.6);
        transform: scale(1.05);
    }
    100% { 
        background-color: transparent;
        transform: scale(1);
    }
}

/* 错误震动动画 */
.error-shake {
    animation: error-shake 0.6s ease-in-out;
}

@keyframes error-shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/* ===== 通知消息样式优化 - 按钮式现代化设计 ===== */
.AAS-notification {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.8);
    padding: var(--spacing-lg) var(--spacing-xl);
    border-radius: 16px;
    font-size: var(--font-size-base);
    font-weight: 600;
    font-family: var(--font-family-base);
    z-index: var(--z-index-notification);
    transition: all var(--animation-duration-normal) cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.15),
        0 4px 16px rgba(0, 0, 0, 0.1),
        0 0 0 2px rgba(255, 255, 255, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(24px) saturate(200%);
    -webkit-backdrop-filter: blur(24px) saturate(200%);
    opacity: 0;
    visibility: hidden;
    max-width: min(420px, 90vw);
    text-align: center;
    pointer-events: auto;
    border: 2px solid rgba(255, 255, 255, 0.4);
    background: linear-gradient(135deg, 
        rgba(255, 255, 255, 0.95) 0%, 
        rgba(255, 255, 255, 0.98) 100%
    );
    color: var(--color-gray-900);
    line-height: 1.6;
    word-wrap: break-word;
    overflow-wrap: break-word;
    letter-spacing: -0.01em;
    cursor: pointer;
}

.AAS-notification.show {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
    animation: notification-float 3s ease-in-out infinite;
}

/* 通知类型样式 - 按钮式现代化设计 */
.AAS-notification.AAS-success {
    background: linear-gradient(135deg, 
        rgba(72, 187, 120, 0.95) 0%, 
        rgba(72, 187, 120, 0.98) 50%,
        rgba(72, 187, 120, 0.95) 100%
    );
    color: white;
    border: 2px solid rgba(72, 187, 120, 0.6);
    box-shadow: 
        0 8px 32px rgba(72, 187, 120, 0.25),
        0 4px 16px rgba(72, 187, 120, 0.15),
        0 0 0 2px rgba(72, 187, 120, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.AAS-notification.AAS-error {
    background: linear-gradient(135deg, 
        rgba(245, 101, 101, 0.95) 0%, 
        rgba(245, 101, 101, 0.98) 50%,
        rgba(245, 101, 101, 0.95) 100%
    );
    color: white;
    border: 2px solid rgba(245, 101, 101, 0.6);
    box-shadow: 
        0 8px 32px rgba(245, 101, 101, 0.25),
        0 4px 16px rgba(245, 101, 101, 0.15),
        0 0 0 2px rgba(245, 101, 101, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.AAS-notification.AAS-warning {
    background: linear-gradient(135deg, 
        rgba(237, 137, 54, 0.95) 0%, 
        rgba(237, 137, 54, 0.98) 50%,
        rgba(237, 137, 54, 0.95) 100%
    );
    color: white;
    border: 2px solid rgba(237, 137, 54, 0.6);
    box-shadow: 
        0 8px 32px rgba(237, 137, 54, 0.25),
        0 4px 16px rgba(237, 137, 54, 0.15),
        0 0 0 2px rgba(237, 137, 54, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.AAS-notification.AAS-info {
    background: linear-gradient(135deg, 
        rgba(66, 153, 225, 0.95) 0%, 
        rgba(66, 153, 225, 0.98) 50%,
        rgba(66, 153, 225, 0.95) 100%
    );
    color: white;
    border: 2px solid rgba(66, 153, 225, 0.6);
    box-shadow: 
        0 8px 32px rgba(66, 153, 225, 0.25),
        0 4px 16px rgba(66, 153, 225, 0.15),
        0 0 0 2px rgba(66, 153, 225, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

/* 通知内容水平排列样式 - 按钮式设计 */
.notification-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-md);
    min-height: 40px;
    width: 100%;
}

.notification-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    filter: brightness(0) invert(1);
    transition: transform 0.3s ease;
}

.notification-text {
    flex: 1;
    text-align: center;
    word-wrap: break-word;
    overflow-wrap: break-word;
    font-weight: 600;
    line-height: 1.4;
}

/* 通知图标样式 - 按钮式设计 */
.AAS-notification.AAS-success .notification-icon {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></svg>');
}

.AAS-notification.AAS-error .notification-icon {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"/></svg>');
}

.AAS-notification.AAS-warning .notification-icon {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"/></svg>');
}

.AAS-notification.AAS-info .notification-icon {
    background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="white"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z"/></svg>');
}

/* 移除伪元素图标样式 */
.AAS-notification::before {
    display: none;
}

/* 加载动画 */
.AAS-loading {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.8s linear infinite;
    margin-right: 8px;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 模态框动画 - 已禁用 */
.modal-enter {
    /* 无动画效果 */
}

.modal-exit {
    /* 无动画效果 */
}

/* 通知动画效果 - 现代化精致设计 */
@keyframes notification-float {
    0%, 100% { 
        transform: translate(-50%, -50%) scale(1) rotate(0deg); 
    }
    33% { 
        transform: translate(-50%, calc(-50% - 4px)) scale(1.02) rotate(0.5deg); 
    }
    66% { 
        transform: translate(-50%, calc(-50% + 2px)) scale(0.99) rotate(-0.3deg); 
    }
}

@keyframes notification-appear {
    0% {
        opacity: 0;
        visibility: hidden;
        transform: translate(-50%, -50%) scale(0.7) translateY(30px) rotate(-5deg);
        filter: blur(10px);
    }
    40% {
        opacity: 0.8;
        transform: translate(-50%, -50%) scale(1.1) translateY(-8px) rotate(2deg);
        filter: blur(2px);
    }
    70% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(0.98) translateY(2px) rotate(-1deg);
        filter: blur(0px);
    }
    100% {
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, -50%) scale(1) translateY(0) rotate(0deg);
        filter: blur(0px);
    }
}

@keyframes notification-disappear {
    0% {
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        filter: blur(0px);
    }
    30% {
        opacity: 0.9;
        transform: translate(-50%, -50%) scale(1.05) rotate(3deg);
        filter: blur(1px);
    }
    60% {
        opacity: 0.4;
        transform: translate(-50%, -50%) scale(0.85) translateY(15px) rotate(-2deg);
        filter: blur(4px);
    }
    100% {
        opacity: 0;
        visibility: hidden;
        transform: translate(-50%, -50%) scale(0.6) translateY(40px) rotate(-5deg);
        filter: blur(8px);
    }
}

/* 增强通知动画效果 */
.AAS-notification.show {
    animation: 
        notification-appear 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both,
        notification-float 6s ease-in-out 0.6s infinite;
}

.AAS-notification.hiding {
    animation: notification-disappear 0.5s cubic-bezier(0.55, 0.085, 0.68, 0.53) both;
}

/* 按钮式悬停效果 */
.AAS-notification.show:hover {
    transform: translate(-50%, -50%) scale(1.05) !important;
    box-shadow: 
        0 12px 40px rgba(0, 0, 0, 0.2),
        0 6px 20px rgba(0, 0, 0, 0.15),
        0 0 0 3px rgba(255, 255, 255, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    border-color: rgba(255, 255, 255, 0.8);
    transition-duration: 0.2s;
}

/* 类型特定的悬停效果 */
.AAS-notification.AAS-success.show:hover {
    border-color: rgba(72, 187, 120, 0.8);
    box-shadow: 
        0 12px 40px rgba(72, 187, 120, 0.3),
        0 6px 20px rgba(72, 187, 120, 0.2),
        0 0 0 3px rgba(72, 187, 120, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.AAS-notification.AAS-error.show:hover {
    border-color: rgba(245, 101, 101, 0.8);
    box-shadow: 
        0 12px 40px rgba(245, 101, 101, 0.3),
        0 6px 20px rgba(245, 101, 101, 0.2),
        0 0 0 3px rgba(245, 101, 101, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.AAS-notification.AAS-warning.show:hover {
    border-color: rgba(237, 137, 54, 0.8);
    box-shadow: 
        0 12px 40px rgba(237, 137, 54, 0.3),
        0 6px 20px rgba(237, 137, 54, 0.2),
        0 0 0 3px rgba(237, 137, 54, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.AAS-notification.AAS-info.show:hover {
    border-color: rgba(66, 153, 225, 0.8);
    box-shadow: 
        0 12px 40px rgba(66, 153, 225, 0.3),
        0 6px 20px rgba(66, 153, 225, 0.2),
        0 0 0 3px rgba(66, 153, 225, 0.6),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

/* 图标悬停效果 */
.AAS-notification.show:hover .notification-icon {
    transform: scale(1.2) rotate(5deg);
}

/* 点击效果 */
.AAS-notification.show:active {
    transform: translate(-50%, -50%) scale(0.98) !important;
    transition-duration: 0.1s;
    box-shadow: 
        0 4px 16px rgba(0, 0, 0, 0.15),
        0 2px 8px rgba(0, 0, 0, 0.1),
        0 0 0 2px rgba(255, 255, 255, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

/* ===== 响应式适配优化 ===== */

/* 平板设备适配 */
@media (max-width: 1024px) {
    .AAS-notification {
        max-width: min(350px, 85vw);
        padding: var(--spacing-md) var(--spacing-lg);
        font-size: var(--font-size-base);
        border-radius: 14px;
    }
    
    .notification-content {
        gap: var(--spacing-sm);
        padding: var(--spacing-xs);
    }
    
    .notification-icon {
        width: 18px;
        height: 18px;
        min-width: 18px;
    }
    
    .notification-text {
        font-size: var(--font-size-sm);
        line-height: 1.3;
    }
}

/* 移动设备适配 - 保持垂直居中 */
@media (max-width: 768px) {
    .AAS-notification {
        max-width: min(320px, 90vw);
        padding: var(--spacing-lg) var(--spacing-xl);
        font-size: var(--font-size-base);
        border-radius: 14px;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%) scale(0.8);
        margin-top: 0;
    }
    
    .AAS-notification.show {
        transform: translate(-50%, -50%) scale(1);
        animation: 
            notification-appear-mobile 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) both,
            notification-float-mobile 6s ease-in-out 0.5s infinite;
    }
    
    .AAS-notification.hiding {
        animation: notification-disappear-mobile 0.4s cubic-bezier(0.55, 0.085, 0.68, 0.53) both;
    }
    
    .AAS-notification::before {
        width: 20px;
        height: 20px;
        margin-right: var(--spacing-sm);
    }
    
    /* 移动端按钮式悬停效果 */
    .AAS-notification.show:hover {
        transform: translate(-50%, -50%) scale(1.03) !important;
        box-shadow: 
            0 8px 30px rgba(0, 0, 0, 0.2),
            0 4px 15px rgba(0, 0, 0, 0.15),
            0 0 0 2px rgba(255, 255, 255, 0.6),
            inset 0 1px 0 rgba(255, 255, 255, 0.8);
    }
    
    .AAS-notification.show:active {
        transform: translate(-50%, -50%) scale(0.99) !important;
        box-shadow: 
            0 2px 12px rgba(0, 0, 0, 0.15),
            0 1px 6px rgba(0, 0, 0, 0.1),
            0 0 0 1px rgba(255, 255, 255, 0.4),
            inset 0 1px 0 rgba(255, 255, 255, 0.6);
    }
}

/* 移动端动画适配 - 保持垂直居中 */
@keyframes notification-appear-mobile {
    0% {
        opacity: 0;
        visibility: hidden;
        transform: translate(-50%, -50%) scale(0.7) translateY(30px) rotate(-5deg);
        filter: blur(10px);
    }
    40% {
        opacity: 0.8;
        transform: translate(-50%, -50%) scale(1.1) translateY(-8px) rotate(2deg);
        filter: blur(2px);
    }
    70% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(0.98) translateY(2px) rotate(-1deg);
        filter: blur(0px);
    }
    100% {
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, -50%) scale(1) translateY(0) rotate(0deg);
        filter: blur(0px);
    }
}

@keyframes notification-disappear-mobile {
    0% {
        opacity: 1;
        visibility: visible;
        transform: translate(-50%, -50%) scale(1) rotate(0deg);
        filter: blur(0px);
    }
    30% {
        opacity: 0.9;
        transform: translate(-50%, -50%) scale(1.05) rotate(3deg);
        filter: blur(1px);
    }
    60% {
        opacity: 0.4;
        transform: translate(-50%, -50%) scale(0.85) translateY(15px) rotate(-2deg);
        filter: blur(4px);
    }
    100% {
        opacity: 0;
        visibility: hidden;
        transform: translate(-50%, -50%) scale(0.6) translateY(40px) rotate(-5deg);
        filter: blur(8px);
    }
}

@keyframes notification-float-mobile {
    0%, 100% { 
        transform: translate(-50%, -50%) scale(1) rotate(0deg); 
    }
    33% { 
        transform: translate(-50%, calc(-50% - 3px)) scale(1.02) rotate(0.5deg); 
    }
    66% { 
        transform: translate(-50%, calc(-50% + 2px)) scale(0.99) rotate(-0.3deg); 
    }
}

/* 超小屏幕适配 */
@media (max-width: 480px) {
    .AAS-notification {
        max-width: calc(100vw - 40px);
        padding: var(--spacing-sm);
        font-size: var(--font-size-sm);
        border-radius: 10px;
        margin: 10px;
    }
    
    .notification-content {
        gap: var(--spacing-xs);
        padding: var(--spacing-xs);
        min-height: 40px;
    }
    
    .notification-icon {
        width: 14px;
        height: 14px;
        min-width: 14px;
    }
    
    .notification-text {
        font-size: var(--font-size-xs);
        line-height: 1.2;
        font-weight: 500;
    }
}

/* 按钮悬停效果 */
#AAS-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(72, 187, 120, 0.4);
}

#AAS-submit:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(72, 187, 120, 0.3);
}

/* 输入框焦点效果 */
#AAS-code:focus {
    border-color: #48BB78;
    box-shadow: 0 0 0 3px rgba(72, 187, 120, 0.1);
    outline: none;
}

/* 移动端优化 */
@media (max-width: 768px) {
    .AAS-sync-status {
        top: 10px;
        right: 10px;
        left: 10px;
        max-width: none;
        font-size: 13px;
        padding: 10px 16px;
    }
    
    .AAS-notification {
        max-width: 280px;
        font-size: 15px;
        padding: 14px 20px;
    }
}

/* 高对比度模式支持 */
@media (prefers-contrast: high) {
    .AAS-sync-status {
        border-width: 2px;
    }
    
    .AAS-notification {
        border-width: 2px;
    }
}

/* 减少动画模式支持 */
@media (prefers-reduced-motion: reduce) {
    .AAS-sync-status {
        animation: none !important;
        transition: opacity 0.2s ease;
    }
    
    .AAS-sync-complete {
        animation: none !important;
    }
    
    .error-shake {
        animation: none !important;
    }
    
    .AAS-notification {
        animation: none !important;
        transition: opacity 0.2s ease;
    }
    
    .modal-enter,
    .modal-exit {
        animation: none !important;
        transition: opacity 0.2s ease;
    }
    
    @keyframes sync-pulse,
    @keyframes sync-complete,
    @keyframes error-shake,
    @keyframes modal-enter,
    @keyframes modal-exit,
    @keyframes notification-float {
        animation: none !important;
    }
}
