/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
        'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
        sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.container {
    width: 90%;
    max-width: 600px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    text-align: center;
}

header h1 {
    font-size: 24px;
    font-weight: 600;
}

main {
    padding: 20px;
}

.search-box {
    display: flex;
    margin-bottom: 20px;
}

#plateNumber {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e1e5e9;
    border-radius: 8px 0 0 8px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.3s ease;
}

#plateNumber:focus {
    border-color: #667eea;
}

#searchBtn {
    padding: 12px 20px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 0 8px 8px 0;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#searchBtn:hover {
    background: #5a67d8;
}

#searchBtn:active {
    transform: translateY(1px);
}

.result-box {
    background: #f8fafc;
    border-radius: 10px;
    padding: 20px;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #e2e8f0;
}

.result-item:last-child {
    border-bottom: none;
}

.label {
    font-weight: 600;
    color: #4a5568;
}

#plateNumberResult,
#provinceResult,
#cityResult,
#prefixResult {
    color: #2d3748;
    font-weight: 500;
}

footer {
    text-align: center;
    padding: 15px;
    background: #f8fafc;
    color: #4a5568;
    font-size: 14px;
    border-top: 1px solid #e2e8f0;
}

/* 加载状态样式 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        width: 95%;
        margin: 20px auto;
    }
    
    header h1 {
        font-size: 20px;
    }
    
    .search-box {
        flex-direction: column;
    }
    
    #plateNumber {
        border-radius: 8px 8px 0 0;
        margin-bottom: 1px;
    }
    
    #searchBtn {
        border-radius: 0 0 8px 8px;
    }
    
    .result-item {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px 0;
    }
    
    .label {
        margin-bottom: 5px;
    }
}

/* 错误提示样式 */
.error {
    color: #e53e3e;
    text-align: center;
    padding: 10px;
    background: #fed7d7;
    border-radius: 5px;
    margin-bottom: 15px;
}

/* 成功提示样式 */
.success {
    color: #38a169;
    text-align: center;
    padding: 10px;
    background: #c6f6d5;
    border-radius: 5px;
    margin-bottom: 15px;
}