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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Hiragino Kaku Gothic ProN', 'Hiragino Sans', Meiryo, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
}

.container {
    max-width: 600px;
    margin: 0 auto;
}

.header {
    background: white;
    padding: 20px;
    border-radius: 10px 10px 0 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header h1 {
    font-size: 1.5rem;
    color: #333;
}

.header nav a {
    margin-left: 15px;
    color: #667eea;
    text-decoration: none;
    font-weight: 500;
}

.header nav a:hover {
    text-decoration: underline;
}

.card {
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin-top: 20px;
}

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

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

.form-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.btn {
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s;
}

.btn:hover {
    transform: translateY(-2px);
}

.btn:active {
    transform: translateY(0);
}

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

.btn-danger {
    background: #dc3545;
}

.btn-small {
    width: auto;
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.btn:disabled:hover {
    transform: none;
}

.text-center {
    text-align: center;
}

.mt-20 {
    margin-top: 20px;
}

.error {
    background: #fee;
    border: 1px solid #fcc;
    color: #c33;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.success {
    background: #efe;
    border: 1px solid #cfc;
    color: #3c3;
    padding: 10px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.person-list {
    list-style: none;
    display: flex;
    gap: 15px;
    overflow-x: auto;
    padding-bottom: 10px;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}

/* スクロールバーのスタイル */
.person-list::-webkit-scrollbar {
    height: 6px;
}

.person-list::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.person-list::-webkit-scrollbar-thumb {
    background: #ccc;
    border-radius: 3px;
}

.person-list::-webkit-scrollbar-thumb:hover {
    background: #999;
}

.person-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #667eea;
    min-width: 200px;
    max-width: 250px;
    flex-shrink: 0;
    scroll-snap-align: start;
}

/* 検索結果用のカードスタイル（フル幅） */
.person-card-search {
    background: #f8f9fa;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

.person-card-search h3 {
    color: #333;
    margin-bottom: 5px;
}

.person-card-search .info {
    color: #666;
    font-size: 0.9rem;
    margin-top: 8px;
}

.person-card-search .actions {
    margin-top: 10px;
    display: flex;
    gap: 10px;
}

.person-card h3 {
    color: #333;
    margin-bottom: 5px;
}

.person-card .badge {
    display: inline-block;
    padding: 4px 8px;
    background: #667eea;
    color: white;
    border-radius: 3px;
    font-size: 0.8rem;
    margin-right: 5px;
}

.person-card .badge.new {
    background: #ff4757;
}

.badge-unofficial {
    display: inline-block;
    padding: 4px 8px;
    background: #999;
    color: white;
    border-radius: 3px;
    font-size: 0.8rem;
    margin-right: 5px;
}

.badge-inactive {
    display: inline-block;
    padding: 4px 8px;
    background: #dc3545;
    color: white;
    border-radius: 3px;
    font-size: 0.8rem;
    margin-right: 5px;
}

.person-card .info {
    color: #666;
    font-size: 0.9rem;
    margin-top: 8px;
}

.person-card .actions {
    margin-top: 10px;
}

a {
    color: #667eea;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #999;
}

.empty-state h2 {
    margin-bottom: 10px;
}
