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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: #f5f7fa;
    color: #2c3e50;
    line-height: 1.6;
    min-height: 100vh;
}

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

/* ヘッダー */
header {
    text-align: center;
    padding: 40px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 20px;
    margin-bottom: 40px;
    position: relative;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
    font-weight: 700;
}

.subtitle {
    font-size: 1.2em;
    opacity: 0.9;
}

/* 言語セレクター */
.language-selector {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    gap: 10px;
}

.lang-btn {
    padding: 8px 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    background: transparent;
    color: white;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.lang-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.lang-btn.active {
    background: white;
    color: #667eea;
}

/* コントロール */
.controls {
    display: flex;
    gap: 30px;
    margin-bottom: 40px;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
}

.control-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.control-group label {
    font-weight: 600;
    color: #667eea;
}

select, input[type="text"] {
    padding: 10px 15px;
    border: 2px solid #e1e8ed;
    border-radius: 10px;
    font-size: 16px;
    background: white;
    transition: border-color 0.3s ease;
    min-width: 200px;
}

select:focus, input[type="text"]:focus {
    outline: none;
    border-color: #667eea;
}

/* フォントペアリングカード */
.font-pairings {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.pairing-card {
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.pairing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
}

.font-preview {
    padding: 30px;
    background: #fafbfc;
    border-bottom: 1px solid #e1e8ed;
}

.font-preview h2 {
    font-size: 2em;
    margin-bottom: 15px;
    color: #2c3e50;
    line-height: 1.2;
}

.font-preview p {
    font-size: 1.1em;
    color: #5a6c7d;
    line-height: 1.8;
}

.font-info {
    padding: 25px 30px;
}

.font-names {
    font-size: 16px;
    margin-bottom: 15px;
    line-height: 1.8;
}

.font-label {
    font-weight: 600;
    color: #667eea;
}

.font-description {
    color: #7f8c8d;
    margin-bottom: 20px;
    font-size: 14px;
}

/* コピーボタン */
.copy-btn {
    background: #667eea;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: #5a54d8;
    transform: scale(1.05);
}

.copy-btn.copied {
    background: #27ae60;
}

/* フッター */
footer {
    text-align: center;
    padding: 40px 0;
    color: #7f8c8d;
}

/* レスポンシブ */
@media (max-width: 768px) {
    header h1 {
        font-size: 2em;
    }
    
    .language-selector {
        position: static;
        margin-top: 20px;
        justify-content: center;
    }
    
    .controls {
        flex-direction: column;
        gap: 20px;
    }
    
    .control-group {
        flex-direction: column;
        width: 100%;
    }
    
    select, input[type="text"] {
        width: 100%;
    }
    
    .font-pairings {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .font-preview {
        padding: 20px;
    }
    
    .font-preview h2 {
        font-size: 1.5em;
    }
}

/* アニメーション */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.pairing-card {
    animation: fadeIn 0.5s ease-out;
}