/* 时间戳转换工具样式 */

:root {
    --primary-color: #4dabf7;
    --secondary-color: #6c757d;
    --dark-color: #333;
    --light-color: #fff;
    --gray-color: #666;
    --light-gray: #f8f9fa;
    --border-color: #ddd;
    --border-light: #e9ecef;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 5px 15px rgba(0, 0, 0, 0.1);
    --success-color: #28a745;
}

body.dark-mode {
    --primary-color: #4a90e2;
    --secondary-color: #7f8c8d;
    --dark-color: #ecf0f1;
    --light-color: #2c3e50;
    --gray-color: #bdc3c7;
    --light-gray: #34495e;
    --border-color: #4a5568;
    --border-light: #4a5568;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 5px 15px rgba(0, 0, 0, 0.3);
    --success-color: #2ecc71;
}

.timestamp-section {
    padding: 60px 0;
}

.page-header {
    text-align: center;
    margin-bottom: 40px;
}

.page-title {
    font-size: 2.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.page-subtitle {
    font-size: 1.2rem;
    color: var(--gray-color);
    max-width: 600px;
    margin: 0 auto;
}

.workspace {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.converter-panel {
    background: var(--light-color);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.converter-panel:hover {
    box-shadow: var(--shadow-lg);
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border-color);
}

.panel-header h3 {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--dark-color);
}

.panel-description {
    font-size: 0.9rem;
    color: var(--gray-color);
    margin: 5px 0 0 0;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

.action-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    gap: 5px;
}

.action-btn:hover {
    background: #3b82f6;
}

.action-btn.copied {
    background: var(--success-color);
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--dark-color);
}

.input-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
    background: var(--light-color);
    color: var(--dark-color);
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(77, 171, 247, 0.2);
}

.input-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
    background: var(--light-color);
    color: var(--dark-color);
    resize: vertical;
    min-height: 120px;
    font-family: 'Courier New', Courier, monospace;
}

.input-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(77, 171, 247, 0.2);
}

/* 批量输出文本域 */
#batch-output {
    background: var(--light-gray);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 15px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 1rem;
    color: var(--dark-color);
    min-height: 150px;
    resize: vertical;
    line-height: 1.5;
    white-space: pre-wrap;
}

#batch-output::placeholder {
    color: var(--gray-color);
    opacity: 0.7;
}

.output-group {
    margin-top: 30px;
}

.output-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 500;
    color: var(--dark-color);
}

.result-box {
    background: var(--light-gray);
    border-radius: 6px;
    padding: 20px;
    border: 1px solid var(--border-color);
}

.result-item {
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.result-item:last-child {
    margin-bottom: 0;
}

.result-label {
    font-weight: 500;
    color: var(--gray-color);
    min-width: 150px;
}

.result-value {
    color: var(--dark-color);
    font-family: 'Courier New', Courier, monospace;
    word-break: break-all;
    flex: 1;
    margin-right: 10px;
}

/* 复制按钮 */
.copy-btn {
    background: none;
    border: none;
    color: var(--secondary-color);
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.2s ease;
    margin-left: 10px;
}

.copy-btn:hover {
    background-color: var(--border-light);
    color: var(--primary-color);
}

/* 批量转换部分 */
.batch-section {
    background: var(--light-color);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.batch-content {
    margin-top: 20px;
}

/* 时间差计算部分 */
.time-diff-section {
    background: var(--light-color);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.time-diff-content {
    margin-top: 20px;
}

/* 当前时间信息 */
.current-time-section {
    background: var(--light-color);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.current-time-section h3 {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.current-time-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.time-info-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
    background: var(--light-gray);
    border-radius: 6px;
    border: 1px solid var(--border-color);
    position: relative;
}

.info-label {
    font-size: 0.9rem;
    color: var(--gray-color);
    margin-bottom: 5px;
    text-align: center;
}

.info-value {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--dark-color);
    text-align: center;
    font-family: 'Courier New', Courier, monospace;
    margin-bottom: 10px;
}

/* 历史记录部分 */
.history-section {
    background: var(--light-color);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.history-section h3 {
    font-size: 1.3rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.history-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 10px;
    background: var(--light-gray);
}

.history-item {
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    padding: 12px;
    margin-bottom: 10px;
    transition: all 0.2s ease;
}

.history-item:hover {
    box-shadow: var(--shadow);
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border-light);
}

.history-type {
    font-weight: 600;
    color: var(--primary-color);
    font-size: 0.9rem;
}

.history-time {
    font-size: 0.8rem;
    color: var(--gray-color);
}

.history-content {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.9rem;
}

.history-input {
    color: var(--dark-color);
    flex: 1;
    word-break: break-all;
}

.history-arrow {
    color: var(--secondary-color);
    font-weight: 600;
}

.history-output {
    color: var(--success-color);
    flex: 1;
    word-break: break-all;
}

.feature-section {
    margin-bottom: 40px;
}

.feature-section h3 {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.feature-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 15px;
    background: var(--light-color);
    border-radius: 6px;
    box-shadow: var(--shadow);
}

.feature-item i {
    color: var(--primary-color);
    font-size: 1.2rem;
}

.feature-item span {
    color: var(--dark-color);
    font-weight: 500;
}

.faq-section {
    background: var(--light-color);
    border-radius: 10px;
    padding: 30px;
    box-shadow: var(--shadow);
    margin-bottom: 40px;
}

.faq-section h3 {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 20px;
}

.faq-item:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.faq-question {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 10px;
    color: var(--dark-color);
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-question::after {
    content: '+';
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.faq-question.active::after {
    transform: rotate(45deg);
}

.faq-answer {
    color: var(--gray-color);
    line-height: 1.6;
    display: none;
}

.faq-answer.active {
    display: block;
}

.case-section {
    margin-bottom: 40px;
}

.case-section h3 {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.case-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.case-item {
    background: var(--light-color);
    border-radius: 10px;
    padding: 20px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
}

.case-item:hover {
    box-shadow: var(--shadow-lg);
}

.case-title {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 10px;
}

.case-description {
    color: var(--gray-color);
    line-height: 1.6;
}

.related-section {
    margin-bottom: 20px;
}

.related-section h3 {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--dark-color);
    margin-bottom: 20px;
    text-align: center;
}

.related-tools {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
}

.tool-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: var(--light-color);
    color: var(--dark-color);
    text-decoration: none;
    border-radius: 6px;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    font-weight: 500;
}

.tool-link:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .page-title {
        font-size: 2rem;
    }
    
    .workspace {
        grid-template-columns: 1fr;
    }
    
    .converter-panel {
        padding: 20px;
    }
    
    .current-time-info {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .feature-list {
        grid-template-columns: 1fr;
    }
    
    .case-list {
        grid-template-columns: 1fr;
    }
    
    .related-tools {
        flex-direction: column;
        align-items: center;
    }
    
    .tool-link {
        width: 80%;
        justify-content: center;
    }
    
    .result-label {
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .page-title {
        font-size: 1.5rem;
    }
    
    .page-subtitle {
        font-size: 1rem;
    }
    
    .converter-panel {
        padding: 15px;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .action-btn {
        width: 100%;
        justify-content: center;
    }
    
    .current-time-section {
        padding: 20px;
    }
    
    .time-info-item {
        padding: 10px;
    }
    
    .info-value {
        font-size: 0.9rem;
    }
    
    .faq-section {
        padding: 20px;
    }
    
    .case-item {
        padding: 15px;
    }
    
    .tool-link {
        width: 100%;
    }
    
    .result-label {
        min-width: 100px;
        font-size: 0.85rem;
    }
}