* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', 'Microsoft YaHei', sans-serif;
}

body {
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    padding: 30px 0;
    background: linear-gradient(135deg, #1a5fb4 0%, #2d8ae1 100%);
    color: white;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
}

.data-source-info {
    background-color: rgba(255, 255, 255, 0.2);
    padding: 8px 15px;
    border-radius: 20px;
    display: inline-block;
    margin-top: 15px;
    font-size: 0.9rem;
}

.latest-results {
    background-color: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.section-title {
    font-size: 1.8rem;
    color: #1a5fb4;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.section-title .last-update {
    font-size: 0.9rem;
    color: #666;
    font-weight: normal;
}

.lottery-info {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 20px;
}

.issue-info {
    font-size: 1.3rem;
    font-weight: 600;
    color: #333;
}

.date-info {
    font-size: 1.1rem;
    color: #666;
}

.numbers {
    display: flex;
    flex-wrap: wrap;
    margin: 25px 0;
}

.number {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: bold;
    margin-right: 15px;
    margin-bottom: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.red {
    background-color: #e74c3c;
    color: white;
}

.blue {
    background-color: #3498db;
    color: white;
}

.separator {
    display: flex;
    align-items: center;
    font-size: 2rem;
    color: #999;
    margin: 0 5px;
}

.query-section {
    background-color: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.query-options {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.option-group {
    flex: 1;
    min-width: 200px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #444;
}

select, input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

select:focus, input:focus {
    outline: none;
    border-color: #2d8ae1;
}

.buttons {
    display: flex;
    gap: 15px;
}

button {
    padding: 12px 25px;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-query {
    background-color: #2d8ae1;
    color: white;
}

.btn-query:hover {
    background-color: #1a5fb4;
}

.btn-reset {
    background-color: #f8f9fa;
    color: #333;
    border: 1px solid #ddd;
}

.btn-reset:hover {
    background-color: #e9ecef;
}

.history-section {
    background-color: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.history-list {
    list-style: none;
}

.history-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: background-color 0.2s;
}

.history-item:hover {
    background-color: #f9f9f9;
}

.history-link {
    text-decoration: none;
    color: #333;
    flex: 1;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.history-issue {
    font-weight: 600;
    color: #1a5fb4;
}

.history-date {
    color: #666;
}

.history-numbers {
    display: flex;
    flex-wrap: wrap;
}

.history-number {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    font-weight: bold;
    margin-right: 8px;
}

.results-section {
    background-color: white;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.results-table {
    width: 100%;
    border-collapse: collapse;
}

.results-table th {
    background-color: #f8f9fa;
    padding: 15px;
    text-align: left;
    font-weight: 600;
    color: #444;
    border-bottom: 2px solid #f0f0f0;
}

.results-table td {
    padding: 15px;
    border-bottom: 1px solid #f0f0f0;
}

.results-table tr:hover {
    background-color: #f9f9f9;
}

footer {
    text-align: center;
    padding: 30px 0;
    color: #666;
    border-top: 1px solid #eee;
    margin-top: 20px;
}

.seo-text {
    max-width: 800px;
    margin: 0 auto 30px;
    line-height: 1.8;
    color: #555;
}

.seo-text h2 {
    color: #1a5fb4;
    margin-bottom: 15px;
}

.seo-text p {
    margin-bottom: 15px;
}

.no-results {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

.loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.error {
    text-align: center;
    padding: 40px;
    color: #e74c3c;
    background-color: #ffeaea;
    border-radius: 8px;
    margin: 20px 0;
}

.data-source-status {
    font-size: 0.9rem;
    color: #666;
    margin-top: 10px;
    padding: 8px 12px;
    background-color: #f8f9fa;
    border-radius: 6px;
    display: inline-block;
}

.data-source-success {
    color: #27ae60;
}

.data-source-failure {
    color: #e74c3c;
}

.data-source-switch {
    color: #f39c12;
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    .lottery-info {
        flex-direction: column;
        gap: 10px;
    }
    
    .history-link {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .buttons {
        flex-direction: column;
    }
    
    .number {
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
    
    .section-title {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .section-title .last-update {
        margin-top: 5px;
    }
}