/* common.css - 所有工具页面共用样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Microsoft YaHei', Arial, sans-serif;
}

body {
    background-color: #f5f5f5;
    min-height: 100vh;
    padding-top: 10px;
}

/* 公共头部样式 */
.tool-header {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    padding: 15px 20px;
    border-radius: 12px 12px 0 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.tool-logo {
    color: #fff;
    font-size: 1.2rem;
    font-weight: 500;
    letter-spacing: 1px;
}

.tool-logo a {
    display: inline-block;
    padding: 6px 12px;
    color: #2196F3 !important;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none !important;
    border-bottom: 2px solid transparent;
    transition: all 0.2s ease;
}

.tool-logo a:hover {
    color: #1976D2 !important;
    border-bottom: 2px solid #2196F3;
}

.tool-nav {
    display: flex;
    gap: 15px;
}

.tool-nav-item {
    color: #d1d1d1;
    text-decoration: none;
    padding: 8px 15px;
    border-radius: 8px;
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.tool-nav-item:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.tool-nav-item.active {
    background: linear-gradient(135deg, #ff7a18, #af002d);
    color: #fff;
    box-shadow: 0 2px 8px rgba(255, 122, 24, 0.3);
}

/* 工具主体容器 */
.tool-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    width: 100%;
}

/* 统一按钮样式 */
.btn {
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.btn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background: linear-gradient(135deg, #2196F3, #1976D2);
    color: #fff;
}

.btn-secondary {
    background: #e0e0e0;
    color: #333;
}

.btn-danger {
    background: linear-gradient(135deg, #f44336, #d32f2f);
    color: #fff;
}

.btn-success {
    background: linear-gradient(135deg, #4CAF50, #388E3C);
    color: #fff;
}

/* 统一输入框/文本域样式 */
.input-control {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 0.95rem;
    transition: border 0.2s ease;
    width: 100%;
}

.input-control:focus {
    outline: none;
    border-color: #2196F3;
    box-shadow: 0 0 0 2px rgba(33, 150, 243, 0.1);
}

/* 卡片容器 */
.card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    padding: 20px;
    margin-bottom: 20px;
}

/* 统一提示弹窗 */
.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 10px 20px;
    border-radius: 8px;
    background: #333;
    color: #fff;
    font-size: 0.95rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 9999;
    opacity: 0;
    transform: translateY(-10px);
    transition: all 0.3s ease;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}