* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 450px;
    text-align: center;
}

h1 {
    color: #333;
    margin-bottom: 30px;
    font-size: 28px;
    font-weight: 600;
}

.mode-switch {
    display: flex;
    background: #f8f9fa;
    border-radius: 12px;
    padding: 5px;
    margin-bottom: 30px;
}

.mode-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    background: transparent;
    color: #666;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.mode-btn.active {
    background: #667eea;
    color: white;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.3);
}

.mode-btn:hover:not(.active) {
    background: #e9ecef;
}

.converter-section {
    margin-bottom: 30px;
}

.converter {
    display: block;
}

.converter.hidden {
    display: none;
}

.input-group {
    margin-bottom: 20px;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #555;
    font-weight: 500;
    font-size: 14px;
}

input[type="text"], 
input[type="datetime-local"] {
    width: 100%;
    padding: 15px;
    border: 2px solid #e9ecef;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

input[type="text"]:focus, 
input[type="datetime-local"]:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.convert-btn {
    width: 100%;
    padding: 15px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.convert-btn:hover {
    background: #5a6fd8;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

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

.result {
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    margin-top: 15px;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: #333;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.result.show {
    border-color: #667eea;
    background: #f0f4ff;
}

.result.error {
    border-color: #dc3545;
    background: #ffe6e6;
    color: #dc3545;
}

.current-time {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
}

.current-time p {
    margin-bottom: 10px;
    color: #666;
    font-size: 14px;
}

.current-time span {
    color: #333;
    font-weight: 600;
    font-size: 16px;
}

/* 响应式设计 */
@media (max-width: 480px) {
    .container {
        padding: 20px;
        margin: 10px;
    }
    
    h1 {
        font-size: 24px;
    }
    
    .convert-btn {
        font-size: 14px;
        padding: 12px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.result.show {
    animation: fadeIn 0.3s ease;
}