.tool-fullwidth {
    width: 100%;
    max-width: 100%;
    margin: 0;
    padding: 0;
}

/* Tool shell */
.query-tool {
    max-width: 100%;
    margin: 0 auto;
}

.query-tool.editor-section,
.editor-section.query-tool {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.query-tool .card:not(.result-card) {
    border: 1px solid var(--color-border, #e5e7eb);
    box-shadow: var(--shadow-sm, 0 1px 3px rgba(0, 0, 0, 0.06));
    border-radius: var(--radius, 12px);
    background: var(--color-surface, #fff);
}

.query-tool .card-body {
    padding: 1.25rem 1.35rem;
}

.query-tool .card-title {
    color: var(--color-text, #1f2937);
    font-weight: 700;
    font-size: 1.05rem;
}

.query-tool .form-control,
.query-tool .form-select,
.query-tool .select-input,
.query-tool textarea {
    border-radius: 8px;
    border: 1px solid var(--color-border, #e5e7eb);
}

.query-tool .form-control:focus,
.query-tool .form-select:focus,
.query-tool textarea:focus {
    border-color: var(--color-primary, #0d9488);
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.query-tool .btn-primary {
    background: var(--color-primary, #0d9488);
    border-color: var(--color-primary, #0d9488);
}

.query-tool .btn-primary:hover {
    background: var(--color-primary-hover, #0f766e);
    border-color: var(--color-primary-hover, #0f766e);
}

.query-tool .alert {
    border-radius: 10px;
}

[data-theme="dark"] .query-tool .card:not(.result-card) {
    background: var(--color-surface, #1f2937);
    border-color: var(--color-border, #374151);
}

[data-theme="dark"] .query-tool .card-title,
[data-theme="dark"] .query-tool .form-label,
[data-theme="dark"] .query-tool {
    color: var(--color-text, #f9fafb);
}

[data-theme="dark"] .query-tool .text-muted,
[data-theme="dark"] .query-tool .form-text {
    color: var(--color-text-secondary, #9ca3af) !important;
}

[data-theme="dark"] .query-tool .form-control,
[data-theme="dark"] .query-tool .form-select,
[data-theme="dark"] .query-tool textarea {
    background: #111827;
    color: var(--color-text, #f9fafb);
    border-color: var(--color-border, #374151);
}

/* --- tool: newyearsday-countdown --- */
/* 元旦新年倒计时样式 */
.newyear-countdown-container {
    min-height: auto;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    overflow: hidden;
    padding: 2rem 0;
}

/* 烟花动画背景 */
.fireworks {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.firework {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    animation: firework-animation 2s ease-out forwards;
}

@keyframes firework-animation {
    0% {
        transform: scale(0);
        opacity: 1;
    }
    50% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(2);
        opacity: 0;
    }
}

/* 新年标题样式 */
.newyear-header {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
    z-index: 2;
}

.newyear-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0);
    }
    40% {
        transform: translateY(-20px);
    }
    60% {
        transform: translateY(-10px);
    }
}

.newyear-title {
    color: #fff;
    font-size: 3rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    margin-bottom: 1rem;
}

.newyear-subtitle {
    color: #f8f9fa;
    font-size: 1.2rem;
    opacity: 0.9;
}

/* 倒计时卡片样式 */
.countdown-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    margin-bottom: 2rem;
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.countdown-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57);
}

.countdown-display {
    padding: 3rem 2rem;
    text-align: center;
}

.countdown-title {
    color: #2c3e50;
    font-size: 2rem;
    font-weight: bold;
    margin-bottom: 2rem;
}

.countdown-timer {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.time-unit {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 1.5rem 1rem;
    border-radius: 15px;
    min-width: 100px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.time-unit:hover {
    transform: translateY(-5px);
}

.time-number {
    font-size: 2.5rem;
    font-weight: bold;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.time-label {
    font-size: 1rem;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.newyear-message {
    font-size: 1.2rem;
    color: #2c3e50;
    font-weight: 500;
    margin-top: 1rem;
}

/* 设置卡片样式 */
.settings-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    position: relative;
    z-index: 2;
}

.settings-title {
    color: #2c3e50;
    font-size: 1.5rem;
    font-weight: bold;
    margin-bottom: 1.5rem;
}

/* 按钮样式 */
.btn-newyear {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    border: none;
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(255, 107, 107, 0.3);
}

.btn-newyear:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
    color: white;
}

.btn-secondary-newyear {
    background: linear-gradient(135deg, #74b9ff, #0984e3);
    border: none;
    color: white;
    padding: 12px 30px;
    border-radius: 25px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(116, 185, 255, 0.3);
}

.btn-secondary-newyear:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(116, 185, 255, 0.4);
    color: white;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .newyear-title {
        font-size: 2rem;
    }
    
    .countdown-timer {
        gap: 1rem;
    }
    
    .time-unit {
        min-width: 80px;
        padding: 1rem 0.5rem;
    }
    
    .time-number {
        font-size: 2rem;
    }
    
    .countdown-display {
        padding: 2rem 1rem;
    }
}

/* 新年祝福动画 */
.newyear-blessing {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: rgba(255, 255, 255, 0.95);
    padding: 2rem;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    z-index: 1000;
    text-align: center;
    display: none;
}

.newyear-blessing.show {
    display: block;
    animation: blessing-appear 0.5s ease-out;
}

@keyframes blessing-appear {
    0% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(0.8);
    }
    100% {
        opacity: 1;
        transform: translate(-50%, -50%) scale(1);
    }
}
