:root {
    --primary-color: #2563eb;
    --secondary-color: #1e40af;
    --background-color: #f8fafc;
    --text-color: #1f2937;
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--background-color);
}

main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.intro {
    font-size: 1.2rem;
    margin-bottom: 3rem;
    max-width: 800px;
}

.countries-overview {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 3rem;
    overflow-x: auto;
    scrollbar-width: none;
    width: 100%;
}

.countries-overview::-webkit-scrollbar {
    display: none;  /* Chrome, Safari and Opera */
}

.countries-list {
    display: flex;
    gap: 1.2rem;
    padding: 0.5rem 1rem;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.country-link {
    color: var(--text-color);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 4px;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    background-color: var(--background-color);
    border: 1px solid #e5e7eb;
    height: 40px;
    min-width: 100px;
    justify-content: center;
}

.country-link:after {
    content: "›";
    position: absolute;
    right: -0.8rem;
    font-size: 1.2rem;
    color: #cbd5e1;
    top: 50%;
    transform: translateY(-50%);
    font-weight: 300;
}

.country-link:last-child:after {
    display: none;
}

.country-link:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
    background-color: white;
}

.country-link.active {
    color: var(--primary-color);
    font-weight: 600;
    background-color: white;
    border-color: var(--primary-color);
}

.country-link.active .flag-icon {
    filter: drop-shadow(0 2px 4px rgba(37, 99, 235, 0.2));
}

.flag-icon.home {
    width: 20px;
    height: 20px;
}

.flag-icon {
    font-size: 1.5rem;
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.country-link:hover .flag-icon {
    transform: scale(1.1);
}

.flag-icon.china {
    filter: drop-shadow(0 2px 4px rgba(222, 41, 16, 0.2));
}

.flag-icon.india {
    filter: drop-shadow(0 2px 4px rgba(255, 153, 51, 0.2));
}

.flag-icon.usa {
    filter: drop-shadow(0 2px 4px rgba(179, 25, 66, 0.2));
}

.flag-icon.indonesia {
    filter: drop-shadow(0 2px 4px rgba(255, 0, 0, 0.2));
}

.flag-icon.brazil {
    filter: drop-shadow(0 2px 4px rgba(0, 156, 59, 0.2));
}

.flag-icon.nigeria {
    filter: drop-shadow(0 2px 4px rgba(0, 135, 81, 0.2));
}

.flag-icon.japan {
    filter: drop-shadow(0 2px 4px rgba(188, 0, 45, 0.2));
}

.flag-icon.russia {
    filter: drop-shadow(0 2px 4px rgba(213, 43, 30, 0.2));
}

.flag-icon.bangladesh {
    filter: drop-shadow(0 2px 4px rgba(0, 106, 78, 0.2));
}

.flag-icon.mexico {
    filter: drop-shadow(0 2px 4px rgba(206, 17, 38, 0.2));
}

.name {
    flex: 1;
    font-weight: 500;
    font-size: 1rem;
    text-align: center;
    white-space: nowrap;
}

.country-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.country-card {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    min-height: 280px;
}

.country-card h2 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.country-card p {
    margin-bottom: 1.5rem;
    flex: 1;
}

.btn {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0.75rem 1.5rem;
    background-color: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    width: fit-content;
    margin: auto auto 0;
}

.btn:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.2);
}

.country-section {
    margin-bottom: 2rem;
}

.country-section h3 {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

footer {
    text-align: center;
    padding: 2rem;
    background-color: white;
    margin-top: 4rem;
}

@media (max-width: 768px) {
    .country-grid {
        grid-template-columns: 1fr;
    }

    main {
        padding: 1rem;
    }

    h1 {
        font-size: 2rem;
    }
}

/* 生成器页面样式 */
.generator-section {
    background: white;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.generator-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin: 2rem 0;
}

.option-group {
    background: var(--background-color);
    padding: 1.5rem;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}

.option-group h2 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.radio-group {
    display: flex;
    gap: 1.5rem;
}

.radio-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.select-input {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    background-color: white;
    font-size: 1rem;
}

.generator-actions {
    display: flex;
    gap: 1rem;
    margin: 2rem 0;
}

.result-section {
    background: var(--background-color);
    padding: 2rem;
    border-radius: 6px;
    margin-top: 2rem;
}

.number-display {
    font-size: 2rem;
    font-weight: 600;
    color: var(--primary-color);
    text-align: center;
    padding: 1rem;
    background: white;
    border-radius: 4px;
    margin: 1rem 0;
    border: 1px solid #e5e7eb;
}

.format-info {
    background: white;
    border-radius: 8px;
    padding: 2rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.format-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 1.5rem;
}

.format-card {
    background: var(--background-color);
    padding: 1.5rem;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
}

.numbers-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 1rem;
}

.number-item {
    background: white;
    padding: 1rem;
    border-radius: 4px;
    border: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.number {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--primary-color);
}

.timestamp {
    color: #6b7280;
    font-size: 0.9rem;
}

.btn.success {
    background-color: #10B981;
    color: white;
    border-color: #10B981;
} 