/* ChangeImageDPI.com - 共用样式文件 */

/* 自定义样式 */
.drop-zone {
    transition: all 0.3s ease;
}

.drop-zone.drag-over {
    border-color: #3b82f6;
    background-color: #eff6ff;
}

.fade-in {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(10px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

/* 加载动画 */
.spinner {
    border: 3px solid #f3f4f6;
    border-top: 3px solid #3b82f6;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 语言切换器样式 */
.language-switcher {
    position: relative;
}

.language-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 0.5rem;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    min-width: 150px;
    z-index: 50;
}

.language-dropdown.show {
    display: block;
}

.language-dropdown a {
    display: block;
    padding: 0.5rem 1.5rem;
    color: #374151;
    text-decoration: none;
    transition: background-color 0.2s;
}

.language-dropdown a:hover {
    background-color: #f3f4f6;
}

.language-dropdown a.active {
    background-color: #eff6ff;
    color: #2563eb;
    font-weight: 600;
}

/* 响应式调整 */
@media (max-width: 640px) {
    /* 移除导致移动端右侧溢出的样式 */
}

/* 广告位样式 - 防止布局抖动 */
.ads-placeholder {
    min-height: 0;
    height: auto;
    margin: 1.5rem 0;
    display: block;
    overflow: hidden;
    transition: height 0.3s ease;
}

/* 当广告加载时 */
.ads-placeholder:not(:empty) {
    min-height: 90px; /* 最小高度，适应移动端广告 */
}

/* 桌面端广告 */
@media (min-width: 768px) {
    .ads-placeholder:not(:empty) {
        min-height: 250px; /* 桌面端广告高度 */
    }
}

/* 广告容器居中 */
.ads-placeholder ins {
    display: block;
    text-align: center;
}

/* 空广告位不占空间 */
.ads-placeholder:empty {
    display: none;
}
