body {
    font-family: 'Roboto', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #eef2f5; /* Lighter, more elegant background */
    color: #343a40; /* Slightly darker text for contrast */
    line-height: 1.6;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh; /* Full viewport height */
}

.container {
    max-width: 1100px; /* Slightly wider */
    width: 90%; /* Responsive width */
    margin: 30px auto;
    padding: 30px; /* More padding */
    background-color: #ffffff;
    border-radius: 12px; /* Slightly more rounded */
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15); /* More pronounced shadow */
}

h1 {
    text-align: center;
    color: #212529; /* Darker, more formal color */
    margin-bottom: 30px; /* More spacing */
    font-weight: 600; /* Slightly bolder */
    font-size: 2.2rem; /* Larger for h1 */
}

h2 {
    text-align: center;
    font-size: 1.8rem; /* Slightly smaller for h2 */
    color: #343a40;
    margin-bottom: 25px; /* More spacing */
}

/* General button styles for a more elegant look */
button {
    padding: 12px 25px; /* Slightly larger padding */
    border: none;
    border-radius: 6px; /* Slightly more rounded */
    cursor: pointer;
    font-size: 1rem; /* Consistent font size */
    font-weight: 500; /* Medium weight */
    transition: all 0.3s ease; /* Smooth transitions for all properties */
    text-transform: uppercase; /* A bit more formal */
    letter-spacing: 0.5px;
    margin: 5px; /* Add some margin around buttons */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Subtle shadow for all buttons */
}

/* Password Overlay */
.password-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.password-modal {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.2);
}

.password-modal input {
    padding: 10px;
    margin: 15px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    width: 200px;
    text-align: center;
}

/* Specific styling for the password modal button to override general button styles if needed */
.password-modal button {
    background-color: #007bff;
    color: white;
}

.password-modal button:hover {
    background-color: #0056b3;
}

.error-message {
    color: #dc3545;
    margin-top: 10px;
}

.hidden {
    display: none;
}

/* Table Styles */
.latest-draws-section table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

.latest-draws-section th, .latest-draws-section td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: center;
}

.latest-draws-section th {
    background-color: #e9ecef;
    color: #495057;
    font-weight: bold;
}

.latest-draws-section tr:nth-child(even) {
    background-color: #f8f9fa;
}

.latest-draws-section tr:hover {
    background-color: #e2f0ff;
}

.red-ball {
    display: inline-block;
    background-color: #dc3545;
    color: white;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    margin: 2px;
    font-weight: bold;
    transition: all 0.2s ease;
}

/* 与上期相同的红球标记 - 使用白色边框圆环，清晰舒适 */
.red-ball.same-as-prev {
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px rgb(134 53 220 / 60%);
    background-color: #d5b576;
}

.blue-ball {
    display: inline-block;
    background-color: #007bff;
    color: white;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    line-height: 30px;
    text-align: center;
    margin: 2px;
    font-weight: bold;
    transition: all 0.2s ease;
}

/* Combination Section */
.combination-section {
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.generate-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.generate-controls input[type="number"] {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 5px;
    width: 80px;
    text-align: center;
}

.btn-primary {
    background-color: #28a745;
    color: white;
}

.btn-primary:hover {
    background-color: #218838;
    box-shadow: 0 4px 10px rgba(40, 167, 69, 0.3);
    transform: translateY(-2px);
}

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

.btn-secondary:hover {
    background-color: #e0a800;
    box-shadow: 0 4px 10px rgba(255, 193, 7, 0.3);
    transform: translateY(-2px);
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background-color: #c82333;
    box-shadow: 0 4px 10px rgba(220, 53, 69, 0.3);
    transform: translateY(-2px);
}

.action-buttons {
    display: flex;
    justify-content: center; /* Center the buttons themselves */
    margin-top: 20px;
    gap: 15px; /* Space between buttons */
}

.action-btn {
    background-color: #6c757d; /* A neutral, elegant grey */
    color: white;
}

.action-btn:hover {
    background-color: #5a6268;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2); /* Subtle shadow on hover */
    transform: translateY(-2px); /* Slight lift effect */
}

.action-btn.copied {
    background-color: #28a745;
    cursor: default;
    transform: none;
    box-shadow: none;
}

.combinations-display {
    background-color: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    min-height: 100px;
    text-align: center; /* Center the text content within these divs */
}

.combination-item {
    padding: 8px 0;
    border-bottom: 1px dashed #e9ecef;
}

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

.info-message {
    text-align: center;
    margin-top: 15px;
    font-weight: bold;
    color: #17a2b8;
}

.saved-combinations-display {
    text-align: center;
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.saved-combinations-summary {
    text-align: center;
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px dashed #ccc;
    color: #666;
    font-size: 0.9em;
}
