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

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    padding: 40px 0;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

h1 {
    font-size: 3em;
    color: #4a90e2;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.subtitle {
    font-size: 1.2em;
    color: #666;
    margin-bottom: 20px;
}

.language-selector {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
}

.lang-btn {
    padding: 8px 16px;
    border: 2px solid #4a90e2;
    background: white;
    color: #4a90e2;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.lang-btn:hover {
    background: #4a90e2;
    color: white;
}

.lang-btn.active {
    background: #4a90e2;
    color: white;
}

main {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.settings-panel {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.settings-panel h2 {
    color: #4a90e2;
    margin-bottom: 20px;
    font-size: 1.8em;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: inline-block;
    margin-bottom: 5px;
    color: #555;
    font-weight: 500;
    min-width: 200px;
}

.form-group input[type="number"],
.form-group input[type="text"] {
    padding: 10px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
    width: 200px;
}

.form-group input[type="number"]:focus,
.form-group input[type="text"]:focus {
    outline: none;
    border-color: #4a90e2;
}

.checkbox-group {
    display: flex;
    align-items: center;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 10px;
    cursor: pointer;
}

.button-group {
    display: flex;
    gap: 15px;
    margin-top: 25px;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 30px;
    border: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.cards-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin: 30px 0;
}

.bingo-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.bingo-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.card-title {
    text-align: center;
    color: #4a90e2;
    margin-bottom: 15px;
    font-size: 1.3em;
}

.bingo-table {
    width: 100%;
    border-collapse: collapse;
}

.bingo-table th {
    background: #4a90e2;
    color: white;
    padding: 10px;
    font-size: 1.5em;
    font-weight: bold;
    border: 2px solid #333;
}

.bingo-table td {
    border: 2px solid #333;
    padding: 15px;
    text-align: center;
    font-size: 1.2em;
    font-weight: 500;
    background: white;
    transition: background 0.3s ease;
}

.bingo-table td:hover {
    background: #f0f8ff;
}

.bingo-table .free-space {
    background: #ffe4e1;
    color: #ff6b6b;
    font-weight: bold;
}

.instructions {
    margin-top: 40px;
    padding: 25px;
    background: #f8f9fa;
    border-radius: 15px;
}

.instructions h2 {
    color: #4a90e2;
    margin-bottom: 20px;
}

.instructions ol {
    margin-left: 25px;
    color: #555;
}

.instructions li {
    margin-bottom: 10px;
    line-height: 1.8;
}

.features {
    margin-top: 40px;
    padding: 25px;
    background: #f8f9fa;
    border-radius: 15px;
}

.features h2 {
    color: #4a90e2;
    margin-bottom: 25px;
    text-align: center;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.feature-card {
    background: white;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.15);
}

.feature-icon {
    font-size: 2.5em;
    display: block;
    margin-bottom: 15px;
}

.feature-card h3 {
    color: #333;
    margin-bottom: 10px;
}

.feature-card p {
    color: #666;
    font-size: 0.95em;
}

footer {
    text-align: center;
    padding: 30px 0;
    color: white;
    margin-top: 40px;
}

/* 印刷用スタイル */
@media print {
    body {
        background: white;
    }
    
    .container {
        max-width: 100%;
    }
    
    header,
    .settings-panel,
    .instructions,
    .features,
    footer,
    .language-selector {
        display: none;
    }
    
    main {
        background: white;
        box-shadow: none;
        padding: 0;
    }
    
    .cards-container {
        display: block;
    }
    
    .bingo-card {
        page-break-inside: avoid;
        margin-bottom: 30px;
        box-shadow: none;
    }
    
    .bingo-table th,
    .bingo-table td {
        border: 1px solid #000;
    }
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    h1 {
        font-size: 2em;
    }
    
    .subtitle {
        font-size: 1em;
    }
    
    .form-group label {
        display: block;
        margin-bottom: 8px;
        min-width: auto;
    }
    
    .form-group input[type="number"],
    .form-group input[type="text"] {
        width: 100%;
        max-width: 300px;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        max-width: 300px;
    }
    
    .cards-container {
        grid-template-columns: 1fr;
    }
    
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .language-selector {
        flex-wrap: wrap;
    }
}