/* Ring Sound Custom Styles */

/* Gradient Backgrounds */
.gradient-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.gradient-secondary {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.gradient-hero {
    background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
}

.gradient-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
}

.gradient-button {
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
}

/* Custom Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes bounce {
    0%, 20%, 53%, 80%, 100% {
        transform: translateY(0);
    }
    40%, 43% {
        transform: translateY(-10px);
    }
    70% {
        transform: translateY(-5px);
    }
    90% {
        transform: translateY(-2px);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

.pulse-animation {
    animation: pulse 2s infinite;
}

.bounce-animation {
    animation: bounce 2s infinite;
}

/* Custom Hover Effects */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

.hover-glow {
    transition: box-shadow 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

/* Search Box Styles */
.search-container {
    position: relative !important;
    /* z-index: 10000 !important; */
}

.search-dropdown {
    position: absolute !important;
    top: calc(100% + 8px) !important;
    left: 0 !important;
    right: 0 !important;
    background: white !important;
    border: 1px solid #e5e7eb !important;
    border-radius: 16px !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15) !important;
    max-height: 400px !important;
    overflow-y: auto !important;
    /* z-index: 99999 !important; */
    backdrop-filter: blur(10px) !important;
}

/* 确保搜索下拉框在所有页面都有最高优先级 */
#searchDropdown:not(.hidden),
.search-dropdown:not(.hidden),
.search-dropdown.show {
    position: absolute !important;
    /* z-index: 99999 !important; */
    display: block !important;
}

/* 确保隐藏状态优先级更高 */
#searchDropdown.hidden,
.search-dropdown.hidden {
    /* display: none !important; */
}

/* 特别针对可能的层级冲突 */
.search-container .search-dropdown {
    /* z-index: 99999 !important; */
}

body .search-dropdown {
    /* z-index: 99999 !important; */
}

html .search-dropdown {
    /* z-index: 99999 !important; */
}

.search-item {
    margin: 8px 12px;
    border-radius: 12px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.search-item:hover {
    border-color: #e2e8f0;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.search-item:first-child {
    margin-top: 12px;
}

.search-item:last-child {
    margin-bottom: 12px;
}

/* 搜索结果播放按钮样式 */
.search-play-btn {
    transition: all 0.2s ease;
    border-radius: 50%;
    padding: 4px;
}

.search-play-btn:hover {
    background-color: rgba(139, 92, 246, 0.1);
    transform: scale(1.1);
}

.search-play-btn:active {
    transform: scale(0.95);
}

/* 搜索结果信息区域样式 */
.search-item-info:hover {
    color: #8b5cf6;
}

/* 搜索结果播放状态 */
.search-item.playing {
    background-color: rgba(139, 92, 246, 0.05);
    border-left: 3px solid #8b5cf6;
}

.search-item.playing .search-play-btn {
    color: #8b5cf6 !important;
    background-color: rgba(139, 92, 246, 0.1);
}

/* 搜索结果下载按钮样式 */
.search-download-btn {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.2s ease;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

.search-download-btn:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.search-download-btn:active {
    transform: translateY(0);
}

/* 搜索结果按钮组样式 */
.search-buttons {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

/* 搜索结果信息图标样式 */
.search-item .fas.fa-tag {
    color: #8b5cf6;
}

.search-item .fas.fa-clock {
    color: #3b82f6;
}

.search-item .fas.fa-download {
    color: #d638a98c;
}

/* 搜索结果信息区域样式优化 */
.search-item .flex.items-center.space-x-4 {
    gap: 1rem;
}

.search-item .flex.items-center.space-x-1 {
    gap: 0.25rem;
    white-space: nowrap;
}

/* 搜索结果标题样式 */
.search-item .font-semibold {
    line-height: 1.4;
}

/* 搜索结果统计信息样式 */
.search-item .text-sm.text-gray-500 {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 0.25rem;
}

/* 响应式调整 */
@media (max-width: 640px) {
    .search-item .text-sm.text-gray-500 {
        flex-direction: column;
        gap: 0.25rem;
    }

    .search-buttons {
        flex-direction: column;
        gap: 4px;
    }

    .search-download-btn {
        padding: 4px 8px;
        font-size: 10px;
    }
}

/* Ringtone Card Styles */
.ringtone-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    padding: 20px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.ringtone-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    border-color: #8b5cf6;
}

.ringtone-avatar {
    width: 60px;
    height: 60px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    margin-bottom: 12px;
}

/* 新的铃声列表样式 */
.ringtone-list-item {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.ringtone-list-item:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.ringtone-avatar-small {
    width: 64px;
    height: 64px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.ringtone-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    border-radius: 12px;
}

.ringtone-avatar-small:hover .ringtone-play-overlay {
    opacity: 1;
}

/* 文本截断 */
.line-clamp-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* 首页铃声卡片样式 */
.ringtone-card-compact {
    background: white;
    border-radius: 12px;
    padding: 16px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    height: 120px; /* 固定高度 */
}

.ringtone-card-compact:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.ringtone-small-avatar {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    flex-shrink: 0;
}

.ringtone-info-compact {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 100%;
    min-width: 0;
}

.ringtone-title-compact {
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    line-height: 1.3;
    margin-bottom: 4px;
}

.ringtone-category-compact {
    font-size: 11px;
    color: #8b5cf6;
    cursor: pointer;
    transition: color 0.2s ease;
}

.ringtone-category-compact:hover {
    color: #7c3aed;
}

.ringtone-stats-compact {
    font-size: 10px;
    color: #6b7280;
}

.ringtone-download-btn-compact {
    width: 48px;
    height: 24px;
    font-size: 10px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 新的现代化铃声卡片样式 */
.ringtone-card-modern {
    background: white;
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
    border: 1px solid #f3f4f6;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.ringtone-card-modern:hover {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
    border-color: #e5e7eb;
}

.ringtone-card-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #8b5cf6, #3b82f6);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.ringtone-card-modern:hover::before {
    opacity: 1;
}

.ringtone-avatar-modern {
    width: 56px;
    height: 56px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.ringtone-avatar-modern:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.ringtone-title-modern {
    font-size: 16px;
    font-weight: 700;
    color: #111827;
    line-height: 1.4;
    margin-bottom: 4px;
    transition: color 0.2s ease;
}

.ringtone-title-modern:hover {
    color: #8b5cf6;
}

.ringtone-tag {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.2s ease;
    cursor: pointer;
}

.ringtone-tag-purple {
    background-color: #f3e8ff;
    color: #7c3aed;
}

.ringtone-tag-purple:hover {
    background-color: #e9d5ff;
    color: #6d28d9;
}

.ringtone-tag-green {
    background-color: #ecfdf5;
    color: #059669;
}

.ringtone-tag-green:hover {
    background-color: #d1fae5;
    color: #047857;
}

.ringtone-download-count {
    display: inline-flex;
    align-items: center;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    background-color: #f9fafb;
    color: #6b7280;
}

.ringtone-btn-modern {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    color: white;
    padding: 10px 16px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.ringtone-btn-modern:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.4);
    background: linear-gradient(135deg, #7c3aed 0%, #2563eb 100%);
}

.ringtone-btn-green {
    background: linear-gradient(135deg, #10b981 0%, #3b82f6 100%);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.ringtone-btn-green:hover {
    background: linear-gradient(135deg, #059669 0%, #2563eb 100%);
    box-shadow: 0 8px 20px rgba(16, 185, 129, 0.4);
}

/* 响应式调整 */
@media (max-width: 640px) {
    .ringtone-card-compact {
        height: auto;
        min-height: 100px;
    }

    .ringtone-small-avatar {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }

    .ringtone-download-btn-compact {
        width: 40px;
        height: 20px;
    }

    .ringtone-card-modern {
        padding: 16px;
    }

    .ringtone-avatar-modern {
        width: 48px;
        height: 48px;
        font-size: 18px;
    }

    .ringtone-title-modern {
        font-size: 14px;
    }
}

/* 增强音频播放器样式 */
#audioPlayerModal {
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#audioPlayerModal.hidden {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
}

#audioPlayerModal:not(.hidden) {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* 播放器动画效果 */
@keyframes spin-slow {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.animate-spin-slow {
    animation: spin-slow 3s linear infinite;
}

/* 音频可视化条动画 */
@keyframes audioBar {
    0%, 100% {
        height: 20px;
        opacity: 0.7;
    }
    50% {
        height: 35px;
        opacity: 1;
    }
}

.audio-bar {
    animation: audioBar 1.5s ease-in-out infinite;
}

/* 播放器渐变背景动画 */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

.gradient-animated {
    background: linear-gradient(-45deg, #8b5cf6, #3b82f6, #10b981, #f59e0b);
    background-size: 400% 400%;
    animation: gradientShift 4s ease infinite;
}

/* 播放器装饰元素 */
.player-decoration {
    position: absolute;
    border-radius: 50%;
    animation: float 3s ease-in-out infinite;
}

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

/* 音频控件自定义样式 */
audio::-webkit-media-controls-panel {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

audio::-webkit-media-controls-play-button {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    border-radius: 50%;
    margin: 0 8px;
}

audio::-webkit-media-controls-timeline {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    border-radius: 4px;
    margin: 0 8px;
}

audio::-webkit-media-controls-current-time-display,
audio::-webkit-media-controls-time-remaining-display {
    color: #6b7280;
    font-size: 11px;
    font-weight: 500;
}

/* 播放器标题增强样式 */
#playerRingtoneTitle {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    font-weight: 500;
    letter-spacing: 0.025em;
}

/* 播放器控制按钮样式 */
#playerPlayPauseBtn {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

#playerPlayPauseBtn:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
}

#playerPlayPauseBtn:active {
    transform: scale(0.95);
}



/* 播放器进度条样式 */
#playerProgressBar {
    transition: all 0.2s ease;
}

#playerProgressBar:hover {
    transform: scaleY(1.2);
}

#playerProgress {
    transition: width 0.1s ease-out;
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.3);
}

/* 播放器时间显示样式 */
#playerCurrentTime,
#playerDuration {
    font-family: 'Courier New', monospace;
    font-weight: 600;
}

/* 音频裁剪工具样式 */
.audio-timeline-container {
    user-select: none;
}

.waveform-background {
    position: relative;
    cursor: pointer;
}

.waveform-bars {
    pointer-events: none;
}

.waveform-bars > div {
    transition: all 0.2s ease;
}

.waveform-bars > div:hover {
    background-color: #3b82f6 !important;
}

/* 选择区域样式 */
#selectionArea {
    transition: all 0.3s ease;
    border-left: 2px solid #10b981;
    border-right: 2px solid #10b981;
    background: linear-gradient(90deg, rgba(16, 185, 129, 0.2) 0%, rgba(16, 185, 129, 0.3) 50%, rgba(16, 185, 129, 0.2) 100%);
}

/* 拖拽手柄样式 */
#startHandle, #endHandle {
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

#startHandle:hover, #endHandle:hover {
    background-color: #059669;
    transform: scaleX(1.2);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

#startHandle:active, #endHandle:active {
    background-color: #047857;
    transform: scaleX(1.3);
}

/* 播放位置指示器 */
#playPosition {
    background: linear-gradient(180deg, #ef4444 0%, #dc2626 100%);
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.5);
    z-index: 10;
}

/* 时间轴刻度样式 */
.timeline-scale {
    font-family: 'Courier New', monospace;
    font-size: 10px;
}

/* 时间信息样式 */
.timeline-info {
    font-family: 'Courier New', monospace;
}

#selectionStart, #selectionEnd, #selectionDuration {
    font-weight: 600;
}

/* 播放控制按钮样式 */
#playOriginal, #playSelection, #stopAudio {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

#playOriginal:hover, #playSelection:hover, #stopAudio:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

#playOriginal:active, #playSelection:active, #stopAudio:active {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 生成的铃声样式 */
#generatedRingtones {
    animation: fadeIn 0.5s ease-in-out;
}

.generated-ringtone-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.generated-ringtone-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.generated-ringtone-card .download-btn {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.generated-ringtone-card .download-btn::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.5s ease;
}

.generated-ringtone-card .download-btn:hover::before {
    left: 100%;
}

.generated-ringtone-card .remove-btn {
    transition: all 0.3s ease;
    opacity: 0.5;
}

.generated-ringtone-card:hover .remove-btn {
    opacity: 1;
}

.generated-ringtone-card .remove-btn:hover {
    transform: scale(1.2);
    color: #ef4444;
}

/* 铃声卡片动画 */
@keyframes slideInFromTop {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideOutToRight {
    from {
        opacity: 1;
        transform: translateX(0);
    }
    to {
        opacity: 0;
        transform: translateX(100%);
    }
}

.ringtone-enter {
    animation: slideInFromTop 0.3s ease-out;
}

.ringtone-exit {
    animation: slideOutToRight 0.3s ease-in;
}

/* 分类下拉菜单样式 */
.categories-dropdown {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.categories-dropdown::before {
    content: '';
    position: absolute;
    top: -8px;
    left: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 8px solid rgba(255, 255, 255, 0.95);
}

/* 分类项目悬停效果 */
.category-item {
    position: relative;
    overflow: hidden;
}

.category-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.category-item:hover::before {
    left: 100%;
}

/* 分类图标动画 */
.category-icon {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.category-item:hover .category-icon {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* 渐变色主题 */
.gradient-blue {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.gradient-green {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.gradient-purple {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.gradient-pink {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.gradient-emerald {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
}

.gradient-indigo {
    background: linear-gradient(135deg, #a8edea 0%, #fed6e3 100%);
}

/* 移动端分类菜单动画 */
#mobile-categories {
    transition: all 0.3s ease;
}

#mobile-categories-arrow {
    transition: transform 0.3s ease;
}

/* 下拉菜单阴影效果 */
.dropdown-shadow {
    box-shadow:
        0 20px 25px -5px rgba(0, 0, 0, 0.1),
        0 10px 10px -5px rgba(0, 0, 0, 0.04),
        0 0 0 1px rgba(0, 0, 0, 0.05);
}

/* 分类按钮悬停效果 */
.category-button {
    position: relative;
    overflow: hidden;
}

.category-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.category-button:hover::after {
    width: 300px;
    height: 300px;
}

/* 动态分类颜色类 - 确保Tailwind生成这些类 */
.from-blue-50 { --tw-gradient-from: rgb(239 246 255); }
.to-purple-50 { --tw-gradient-to: rgb(250 245 255); }
.border-blue-200 { border-color: rgb(191 219 254); }
.text-blue-600 { color: rgb(37 99 235); }
.from-blue-400 { --tw-gradient-from: rgb(96 165 250); }
.to-blue-600 { --tw-gradient-to: rgb(37 99 235); }

.from-green-50 { --tw-gradient-from: rgb(240 253 244); }
.to-green-50 { --tw-gradient-to: rgb(240 253 244); }
.border-green-200 { border-color: rgb(187 247 208); }
.text-green-600 { color: rgb(22 163 74); }
.from-green-400 { --tw-gradient-from: rgb(74 222 128); }
.to-green-600 { --tw-gradient-to: rgb(22 163 74); }

.from-purple-50 { --tw-gradient-from: rgb(250 245 255); }
.to-pink-50 { --tw-gradient-to: rgb(253 242 248); }
.border-purple-200 { border-color: rgb(196 181 253); }
.text-purple-600 { color: rgb(147 51 234); }
.from-purple-400 { --tw-gradient-from: rgb(196 181 253); }
.to-purple-600 { --tw-gradient-to: rgb(147 51 234); }

.from-pink-50 { --tw-gradient-from: rgb(253 242 248); }
.to-red-50 { --tw-gradient-to: rgb(254 242 242); }
.border-pink-200 { border-color: rgb(251 207 232); }
.text-pink-600 { color: rgb(219 39 119); }
.from-pink-400 { --tw-gradient-from: rgb(244 114 182); }
.to-pink-600 { --tw-gradient-to: rgb(219 39 119); }

.from-emerald-50 { --tw-gradient-from: rgb(236 253 245); }
.border-emerald-200 { border-color: rgb(167 243 208); }
.text-emerald-600 { color: rgb(5 150 105); }
.from-emerald-400 { --tw-gradient-from: rgb(52 211 153); }
.to-emerald-600 { --tw-gradient-to: rgb(5 150 105); }

.from-indigo-50 { --tw-gradient-from: rgb(238 242 255); }
.border-indigo-200 { border-color: rgb(199 210 254); }
.text-indigo-600 { color: rgb(79 70 229); }
.from-indigo-400 { --tw-gradient-from: rgb(129 140 248); }
.to-indigo-600 { --tw-gradient-to: rgb(79 70 229); }

.from-red-50 { --tw-gradient-from: rgb(254 242 242); }
.border-red-200 { border-color: rgb(254 202 202); }
.text-red-600 { color: rgb(220 38 38); }
.from-red-400 { --tw-gradient-from: rgb(248 113 113); }
.to-red-600 { --tw-gradient-to: rgb(220 38 38); }

.from-yellow-50 { --tw-gradient-from: rgb(254 252 232); }
.border-yellow-200 { border-color: rgb(254 240 138); }
.text-yellow-600 { color: rgb(202 138 4); }
.from-yellow-400 { --tw-gradient-from: rgb(250 204 21); }
.to-yellow-600 { --tw-gradient-to: rgb(202 138 4); }

.from-teal-50 { --tw-gradient-from: rgb(240 253 250); }
.border-teal-200 { border-color: rgb(153 246 228); }
.text-teal-600 { color: rgb(13 148 136); }
.from-teal-400 { --tw-gradient-from: rgb(45 212 191); }
.to-teal-600 { --tw-gradient-to: rgb(13 148 136); }

.from-orange-50 { --tw-gradient-from: rgb(255 247 237); }
.border-orange-200 { border-color: rgb(254 215 170); }
.text-orange-600 { color: rgb(234 88 12); }
.from-orange-400 { --tw-gradient-from: rgb(251 146 60); }
.to-orange-600 { --tw-gradient-to: rgb(234 88 12); }

.from-cyan-50 { --tw-gradient-from: rgb(236 254 255); }
.border-cyan-200 { border-color: rgb(165 243 252); }
.text-cyan-600 { color: rgb(8 145 178); }
.from-cyan-400 { --tw-gradient-from: rgb(34 211 238); }
.to-cyan-600 { --tw-gradient-to: rgb(8 145 178); }

.from-amber-50 { --tw-gradient-from: rgb(255 251 235); }
.border-amber-200 { border-color: rgb(253 230 138); }
.text-amber-600 { color: rgb(217 119 6); }
.from-amber-400 { --tw-gradient-from: rgb(251 191 36); }
.to-amber-600 { --tw-gradient-to: rgb(217 119 6); }

/* 响应式设计 */
@media (max-width: 768px) {
    .audio-timeline-container {
        padding: 12px;
    }

    .timeline-scale {
        font-size: 8px;
    }

    .timeline-info {
        flex-direction: column;
        gap: 8px;
        text-align: center;
    }

    #startHandle, #endHandle {
        width: 4px;
        margin-left: -8px;
    }

    #playOriginal, #playSelection, #stopAudio {
        padding: 8px 16px;
        font-size: 14px;
    }

    .generated-ringtone-card {
        padding: 16px;
    }

    .generated-ringtone-card .flex-col {
        flex-direction: column;
    }

    .generated-ringtone-card .download-btn {
        margin-bottom: 8px;
    }

    /* 移动端分类菜单样式 */
    .categories-dropdown {
        position: static;
        width: 100%;
        margin-top: 0;
        border-radius: 0;
        box-shadow: none;
        background: transparent;
    }
}

/* 详情页音频播放器样式 */
.detail-audio-player {
    opacity: 0.6;
    border-radius: 12px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    height: 54px; /* 固定高度确保一致性 */
}

/* 详情页下载图标样式 */
.detail-download-icon {
    position: relative;
    overflow: hidden;
}

.detail-download-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s ease;
}

.detail-download-icon:hover::before {
    left: 100%;
}

/* 裁剪按钮特殊样式 */
.detail-download-icon:has(.fa-cut):hover {
    background: linear-gradient(135deg, #fed7aa 0%, #fecaca 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(251, 146, 60, 0.3);
}

.detail-download-icon:has(.fa-cut) .fa-cut {
    transition: all 0.3s ease;
}

.detail-download-icon:has(.fa-cut):hover .fa-cut {
    transform: rotate(15deg) scale(1.1);
    color: #ea580c;
}

.detail-audio-player:hover {
    opacity: 0.8;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

/* 详情页音频容器 */
.detail-audio-container {
    position: relative;
}

/* 详情页播放状态样式 */
.detail-audio-container.playing .detail-audio-player {
    opacity: 1;
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(59, 130, 246, 0.1) 100%);
    border: 2px solid rgba(139, 92, 246, 0.3);
    box-shadow:
        0 8px 25px rgba(139, 92, 246, 0.2),
        0 0 0 1px rgba(139, 92, 246, 0.1);
    transform: translateY(-2px);
}

.detail-audio-container.paused .detail-audio-player {
    opacity: 0.9;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1) 0%, rgba(245, 101, 101, 0.1) 100%);
    border: 2px solid rgba(239, 68, 68, 0.3);
    box-shadow:
        0 8px 25px rgba(239, 68, 68, 0.2),
        0 0 0 1px rgba(239, 68, 68, 0.1);
}

/* 详情页音频控件自定义样式 */
.detail-audio-player::-webkit-media-controls-panel {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.9) 0%, rgba(248, 250, 252, 0.9) 100%);
    border-radius: 8px;
    border: 1px solid rgba(139, 92, 246, 0.2);
}

.detail-audio-container.playing .detail-audio-player::-webkit-media-controls-panel {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.1) 0%, rgba(59, 130, 246, 0.1) 100%);
    border: 1px solid rgba(139, 92, 246, 0.3);
}

/* 自定义播放图标覆盖层 */
.detail-play-icon {
    z-index: 10;
    pointer-events: none;
    /* 精确定位到原生播放按钮位置 */
    top: 50%;
    left: 4px;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 响应式调整 */
@media (max-width: 768px) {
    .detail-play-icon {
        width: 36px;
        height: 36px;
        left: 2px;
    }
}

/* 针对不同浏览器的精确调整 */
/* Chrome/Safari - Webkit */
@supports (-webkit-appearance: none) {
    .detail-play-icon {
        left: 6px;
        top: calc(50% + 1px);
    }
}

/* Firefox */
@-moz-document url-prefix() {
    .detail-play-icon {
        left: 4px;
        width: 38px;
        height: 38px;
        top: calc(50% - 1px);
    }
}

/* 默认状态 - 显示播放图标 */
.detail-play-icon i {
    color: #8b5cf6;
    font-size: 14px;
    line-height: 1;
}

/* 播放状态 - 显示暂停图标 */
.detail-audio-container.playing .detail-play-icon {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.9) 0%, rgba(245, 101, 101, 0.9) 100%);
    border: 2px solid #ef4444;
}

.detail-audio-container.playing .detail-play-icon i {
    color: white;
}

.detail-audio-container.playing .detail-play-icon i::before {
    content: "\f04c"; /* FontAwesome pause icon */
}

/* 暂停状态 - 显示播放图标 */
.detail-audio-container.paused .detail-play-icon {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.9) 0%, rgba(59, 130, 246, 0.9) 100%);
    border: 2px solid #8b5cf6;
}

.detail-audio-container.paused .detail-play-icon i {
    color: white;
}

.detail-audio-container.paused .detail-play-icon i::before {
    content: "\f04b"; /* FontAwesome play icon */
}

/* 原生播放按钮样式优化 */
.detail-audio-container.playing .detail-audio-player::-webkit-media-controls-play-button {
    background: linear-gradient(135deg, #ef4444 0%, #f97316 100%);
    border-radius: 50%;
    margin: 0 8px;
}

.detail-audio-container.paused .detail-audio-player::-webkit-media-controls-play-button,
.detail-audio-player::-webkit-media-controls-play-button {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    border-radius: 50%;
    margin: 0 8px;
}

/* 详情页播放按钮状态样式 */
.detail-play-button {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.detail-play-button.playing {
    background: linear-gradient(135deg, #ef4444 0%, #f97316 100%) !important;
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4);
    transform: scale(1.05);
}

.detail-play-button.paused {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%) !important;
    box-shadow: 0 8px 25px rgba(139, 92, 246, 0.4);
    transform: scale(1.02);
}

.detail-play-button:hover {
    transform: scale(1.1);
}

.detail-play-button.playing:hover {
    transform: scale(1.15);
    box-shadow: 0 12px 30px rgba(239, 68, 68, 0.5);
}

.detail-play-button.paused:hover {
    transform: scale(1.12);
    box-shadow: 0 12px 30px rgba(139, 92, 246, 0.5);
}

/* 播放按钮状态样式 - 扁平化设计 */
.play-button-overlay {
    backdrop-filter: blur(10px);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.play-button-overlay.playing {
    background: linear-gradient(135deg,
        rgba(239, 68, 68, 0.95) 0%,
        rgba(245, 101, 101, 0.95) 100%) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 4px 20px rgba(239, 68, 68, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    opacity: 1 !important;
}

.play-button-overlay.playing i {
    color: white !important;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
}

.play-button-overlay.paused {
    background: linear-gradient(135deg,
        rgba(139, 92, 246, 0.95) 0%,
        rgba(59, 130, 246, 0.95) 100%) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.2),
        0 4px 20px rgba(139, 92, 246, 0.4),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    opacity: 1 !important;
}

.play-button-overlay.paused i {
    color: white !important;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
}

/* 详情页播放按钮特殊样式 */
.play-button-overlay.playing + .w-20 {
    background: linear-gradient(135deg, #ef4444 0%, #f56565 100%) !important;
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.4);
}

.play-button-overlay.paused + .w-20 {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%) !important;
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(139, 92, 246, 0.4);
}

/* 音频播放器控件样式 */
audio {
    border-radius: 8px;
    outline: none;
}

audio::-webkit-media-controls-panel {
    background-color: #f8fafc;
    border-radius: 8px;
}

audio::-webkit-media-controls-play-button,
audio::-webkit-media-controls-pause-button {
    background-color: #8b5cf6;
    border-radius: 50%;
}

/* 播放器标题样式 */
#playerRingtoneTitle {
    max-width: 240px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* 播放中的铃声卡片样式 */
.ringtone-card-playing {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 2px solid transparent;
    background-clip: padding-box;
    box-shadow:
        0 10px 40px rgba(139, 92, 246, 0.15),
        0 0 0 1px rgba(139, 92, 246, 0.1);
    transform: translateY(-2px);
}

.ringtone-card-playing::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg,
        rgba(139, 92, 246, 0.05) 0%,
        rgba(59, 130, 246, 0.05) 50%,
        rgba(16, 185, 129, 0.05) 100%);
    pointer-events: none;
    z-index: 1;
}

/* 播放进度背景动画 */
.ringtone-card-playing::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(139, 92, 246, 0.1) 50%,
        transparent 100%);
    animation: playingProgress 3s ease-in-out infinite;
    pointer-events: none;
    z-index: 2;
}

@keyframes playingProgress {
    0% {
        left: -100%;
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        left: 100%;
        opacity: 0;
    }
}

/* 播放中的标题样式 */
.ringtone-card-playing .ringtone-title {
    color: #8b5cf6;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(139, 92, 246, 0.1);
    position: relative;
    z-index: 3;
}

/* 播放中的其他元素样式 */
.ringtone-card-playing .ringtone-info {
    position: relative;
    z-index: 3;
}

/* 脉搏效果 */
.play-button-overlay.playing {
    animation: playingPulse 2s ease-in-out infinite;
}

@keyframes playingPulse {
    0%, 100% {
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, 0.2),
            0 4px 20px rgba(139, 92, 246, 0.4),
            0 0 0 1px rgba(255, 255, 255, 0.1),
            0 0 0 4px rgba(139, 92, 246, 0.1);
    }
    50% {
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, 0.2),
            0 4px 20px rgba(139, 92, 246, 0.4),
            0 0 0 1px rgba(255, 255, 255, 0.1),
            0 0 0 8px rgba(139, 92, 246, 0.2);
    }
}

/* 镂空效果 */
.play-button-overlay.playing i::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: radial-gradient(circle, transparent 30%, rgba(255, 255, 255, 0.1) 70%);
    z-index: -1;
}

/* 播放进度条 */
.progress-bar {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg,
        #8b5cf6 0%,
        #3b82f6 50%,
        #10b981 100%);
    border-radius: 0 0 16px 16px;
    transition: width 0.1s ease-out;
    z-index: 10;
    box-shadow:
        0 0 10px rgba(139, 92, 246, 0.5),
        0 -1px 0 rgba(255, 255, 255, 0.2);
}

.progress-bar::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 6px;
    height: 6px;
    background: #ffffff;
    border-radius: 50%;
    box-shadow:
        0 0 8px rgba(139, 92, 246, 0.8),
        0 0 4px rgba(255, 255, 255, 0.6);
    animation: progressGlow 1.5s ease-in-out infinite;
}

@keyframes progressGlow {
    0%, 100% {
        box-shadow:
            0 0 8px rgba(139, 92, 246, 0.8),
            0 0 4px rgba(255, 255, 255, 0.6);
        transform: scale(1);
    }
    50% {
        box-shadow:
            0 0 12px rgba(139, 92, 246, 1),
            0 0 8px rgba(255, 255, 255, 0.8);
        transform: scale(1.2);
    }
}

/* 播放中卡片的额外发光效果 */
.ringtone-card-playing {
    --progress-glow: 0%;
}

.ringtone-card-playing::before {
    background: linear-gradient(135deg,
        rgba(139, 92, 246, 0.05) 0%,
        rgba(59, 130, 246, 0.05) var(--progress-glow, 50%),
        rgba(16, 185, 129, 0.05) 100%);
}

/* 增强的播放按钮样式 */
.play-button-overlay.playing {
    background: linear-gradient(135deg,
        rgba(139, 92, 246, 0.95) 0%,
        rgba(59, 130, 246, 0.95) 50%,
        rgba(16, 185, 129, 0.95) 100%) !important;
    backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.play-button-overlay.paused {
    background: linear-gradient(135deg,
        rgba(239, 68, 68, 0.95) 0%,
        rgba(245, 101, 101, 0.95) 100%) !important;
    backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

/* 详情页面特定样式 */
.detail-download-icon {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.detail-download-icon:hover {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* 分享模块镂空效果 */
.share-hollow-bg {
    position: relative;
    overflow: hidden;
}

.share-hollow-bg::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, transparent 20%, rgba(255, 255, 255, 0.1) 21%, rgba(255, 255, 255, 0.1) 25%, transparent 26%);
    background-size: 20px 20px;
    animation: hollowMove 20s linear infinite;
    pointer-events: none;
}

@keyframes hollowMove {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

/* 面包屑增强样式 */
.breadcrumb-enhanced {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.8);
}

.breadcrumb-enhanced a {
    position: relative;
    overflow: hidden;
}

.breadcrumb-enhanced a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.4), transparent);
    transition: left 0.5s;
}

.breadcrumb-enhanced a:hover::before {
    left: 100%;
}

/* 正方形头像样式 */
.aspect-square {
    aspect-ratio: 1 / 1;
}

/* 铃声卡片4列布局优化 */
.ringtone-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

@media (min-width: 640px) {
    .ringtone-card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .ringtone-card-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1280px) {
    .ringtone-card-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* 铃声卡片内容间距优化 */
.ringtone-card-content {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* 下载按钮组样式 */
.download-buttons {
    display: flex;
    gap: 0.5rem;
}

.download-buttons button {
    flex: 1;
    padding: 0.5rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

/* Audio Player Styles */
.audio-player {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Button Styles */
.btn-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #8b5cf6 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.4);
}

.btn-secondary {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(240, 147, 251, 0.4);
}

/* Loading Spinner */
.loading-spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #8b5cf6;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    animation: spin 1s linear infinite;
}

.loading-spinner-small {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* 搜索加载更多按钮样式 */
.search-load-more {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, rgba(59, 130, 246, 0.05) 100%);
    margin: 8px 12px;
    border-radius: 12px;
}

.load-more-btn {
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.2);
    transform: translateY(0);
    transition: all 0.3s ease;
    font-weight: 500;
    min-width: 140px;
}

.load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(139, 92, 246, 0.3);
}

.load-more-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: translateY(0);
}

.load-more-btn:disabled:hover {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.2);
}

/* 没有更多结果的提示样式 */
.search-no-more {
    margin: 8px 12px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.05) 0%, rgba(16, 185, 129, 0.05) 100%);
}

/* Breadcrumb Styles */
.breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
}

.breadcrumb-item {
    color: #6b7280;
    text-decoration: none;
    transition: color 0.2s ease;
}

.breadcrumb-item:hover {
    color: #8b5cf6;
}

.breadcrumb-separator {
    color: #d1d5db;
    margin: 0 8px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .ringtone-card {
        padding: 16px;
    }
    
    .ringtone-avatar {
        width: 50px;
        height: 50px;
        font-size: 20px;
    }
    
    .btn-primary,
    .btn-secondary {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #7c3aed 0%, #2563eb 100%);
}

/* Focus States */
input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #8b5cf6;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, #8b5cf6 0%, #3b82f6 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-custom {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.shadow-custom-lg {
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
}

/* 搜索结果项样式 */
.search-result-item {
    padding: 12px;
    border-bottom: 1px solid #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: background-color 0.2s;
}

.search-result-item:hover {
    background-color: #f9fafb;
}

.search-result-item:last-child {
    border-bottom: none;
}

/* 播放中的搜索结果项样式 */
.search-result-item.playing {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, rgba(59, 130, 246, 0.05) 100%);
    border-left: 3px solid #8b5cf6;
    position: relative;
}

.search-result-item.playing::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(139, 92, 246, 0.1) 50%,
        transparent 100%);
    animation: playingShimmer 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes playingShimmer {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

.search-result-item.playing .result-title {
    color: #8b5cf6;
    font-weight: 600;
}

.result-info {
    flex: 1;
    min-width: 0;
}

.result-title {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.result-meta {
    display: flex;
    gap: 12px;
    font-size: 12px;
    color: #6b7280;
}

.result-actions {
    display: flex;
    gap: 8px;
    margin-left: 12px;
}

.play-btn, .download-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
}

.play-btn {
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: white;
}

.play-btn:hover {
    background: linear-gradient(135deg, #7c3aed, #2563eb);
    transform: scale(1.05);
}

/* 播放中的播放按钮样式 */
.search-result-item.playing .play-btn {
    background: linear-gradient(135deg, #ef4444, #f97316);
    animation: playingPulse 1.5s ease-in-out infinite;
}

.search-result-item.playing .play-btn:hover {
    background: linear-gradient(135deg, #dc2626, #ea580c);
    transform: scale(1.1);
}

@keyframes playingPulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
    }
    50% {
        box-shadow: 0 0 0 8px rgba(239, 68, 68, 0);
    }
}

.download-btn {
    background: #f3f4f6;
    color: #6b7280;
}

.download-btn:hover {
    background: #e5e7eb;
    color: #374151;
}

/* 查看更多按钮样式 */
.load-more-container {
    padding: 16px;
    text-align: center;
    border-top: 1px solid #f3f4f6;
    background: #fafafa;
}

.load-more-btn {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
}

.load-more-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #059669, #047857);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}

.load-more-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* 搜索加载状态 */
.search-loading, .search-no-results, .search-error {
    padding: 24px;
    text-align: center;
    color: #6b7280;
}

.search-loading i {
    font-size: 24px;
    margin-bottom: 8px;
    color: #8b5cf6;
}

.search-no-results i {
    font-size: 32px;
    margin-bottom: 12px;
    color: #9ca3af;
}

.search-error i {
    font-size: 24px;
    margin-bottom: 8px;
    color: #ef4444;
}

.retry-btn {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    margin-top: 8px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.retry-btn:hover {
    background: #2563eb;
}

/* 搜索结果播放状态样式 */
.search-item.playing {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08) 0%, rgba(59, 130, 246, 0.08) 100%);
    border-left: 3px solid #8b5cf6;
    position: relative;
}

.search-item.playing::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg,
        transparent 0%,
        rgba(139, 92, 246, 0.15) 50%,
        transparent 100%);
    animation: searchPlayingShimmer 2s ease-in-out infinite;
    pointer-events: none;
    border-radius: 0.5rem;
}

@keyframes searchPlayingShimmer {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

.search-item.playing .font-semibold {
    color: #8b5cf6;
    font-weight: 700;
}

.search-item.playing .search-play-btn {
    color: #ef4444 !important;
    animation: searchPlayPulse 1.5s ease-in-out infinite;
}

@keyframes searchPlayPulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 0 0 rgba(239, 68, 68, 0.4));
    }
    50% {
        transform: scale(1.1);
        filter: drop-shadow(0 0 8px rgba(239, 68, 68, 0.6));
    }
}

/* 下载弹框样式 */
#downloadModal {
    backdrop-filter: blur(4px);
    animation: fadeIn 0.2s ease-out;
}

#downloadModal .bg-white {
    transform: scale(0.95);
    transition: transform 0.2s ease-out;
}

#downloadModal .bg-white.scale-100 {
    transform: scale(1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* 下载按钮样式 */
#downloadModal button {
    transition: all 0.2s ease;
}

#downloadModal button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

#downloadModal button:active {
    transform: translateY(0);
}

/* 下载弹框信息区域 */
#downloadModal .text-xs {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 0.5rem;
    padding: 0.5rem;
    margin-top: 0.75rem;
}

/* 格式选择按钮特殊样式 */
#downloadModal .bg-green-500 {
    background: linear-gradient(135deg, #10b981, #059669);
}

#downloadModal .bg-blue-500 {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

#downloadModal .bg-purple-500 {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

#downloadModal .bg-green-500:hover {
    background: linear-gradient(135deg, #059669, #047857);
}

#downloadModal .bg-blue-500:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
}

#downloadModal .bg-purple-500:hover {
    background: linear-gradient(135deg, #7c3aed, #6d28d9);
}
