.pokemon-card {
    transition: all 0.3s ease;
}
.pokemon-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}
.type-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.pokemon-image {
    image-rendering: pixelated;
    image-rendering: -moz-crisp-edges;
    image-rendering: crisp-edges;
}
.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
}
.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* SP版ヘッダー対応 */
@media (max-width: 640px) {
    header .container {
        padding-left: 0.75rem;
        padding-right: 0.75rem;
    }
    
    header h1 {
        font-size: 1.125rem !important; /* text-lg */
    }
    
    header p {
        font-size: 0.625rem !important; /* text-xs */
        display: none; /* SP版ではサブタイトルを非表示 */
    }
    
    header .w-12 {
        width: 2rem !important;
        height: 2rem !important;
    }
    
    header .w-12 i {
        font-size: 0.875rem !important;
    }
    
    header .space-x-4 > * + * {
        margin-left: 0.5rem !important;
    }
    
    header a.inline-block {
        padding-left: 0.5rem !important;
        padding-right: 0.5rem !important;
        padding-top: 0.375rem !important;
        padding-bottom: 0.375rem !important;
        font-size: 0.75rem !important;
    }
    
    header a.inline-block i {
        display: none; /* SP版ではアイコンを非表示 */
    }

    /* SP版ポケモンカード対応 */
    #pokemon-grid {
        gap: 0.5rem !important;
    }

    #pokemon-grid .pokemon-card {
        border-radius: 0.5rem !important;
        box-shadow: 0 1px 3px rgba(0,0,0,0.1) !important;
    }

    #pokemon-grid .pokemon-card:hover {
        transform: translateY(-2px) !important;
        box-shadow: 0 4px 6px rgba(0,0,0,0.1) !important;
    }

    /* 画像エリア */
    #pokemon-grid .pokemon-card .bg-gray-50 {
        padding: 0.75rem !important;
    }

    #pokemon-grid .pokemon-card img,
    #pokemon-grid .pokemon-card .w-24 {
        width: 4.5rem !important;
        height: 4.5rem !important;
    }

    /* 情報エリア */
    #pokemon-grid .pokemon-card > a > div:last-child {
        padding: 0.5rem !important;
    }

    #pokemon-grid .pokemon-card h3 {
        font-size: 0.7rem !important;
        line-height: 1.1 !important;
        margin-bottom: 0.125rem !important;
    }

    #pokemon-grid .pokemon-card h3 .text-sm {
        font-size: 0.6rem !important;
    }

    #pokemon-grid .pokemon-card .mb-1 {
        margin-bottom: 0.125rem !important;
    }

    #pokemon-grid .pokemon-card .mb-2 {
        margin-bottom: 0.25rem !important;
    }

    /* タイプバッジ */
    #pokemon-grid .pokemon-card .type-badge {
        font-size: 0.5rem !important;
        padding: 1px 4px !important;
        margin: 0.5px !important;
    }

    #pokemon-grid .pokemon-card .flex.space-x-1 {
        gap: 0.125rem !important;
        margin-bottom: 0.25rem !important;
    }

    /* 種族値表示 */
    #pokemon-grid .pokemon-card .text-center {
        margin-top: 0.25rem !important;
    }

    #pokemon-grid .pokemon-card .text-xs {
        font-size: 0.55rem !important;
        display: inline !important;
        margin-right: 0.25rem !important;
    }

    #pokemon-grid .pokemon-card .text-lg {
        font-size: 0.75rem !important;
        font-weight: 700 !important;
        display: inline !important;
    }

    #pokemon-grid .pokemon-card .text-4xl {
        font-size: 2rem !important;
    }

    /* SP版フィルターセクション調整 */
    .container {
        padding-left: 0.75rem !important;
        padding-right: 0.75rem !important;
    }

    .container > .bg-white {
        padding: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }

    .py-8 {
        padding-top: 1rem !important;
        padding-bottom: 1rem !important;
    }

    .space-y-3 > * + * {
        margin-top: 0.5rem !important;
    }

    .gap-3 {
        gap: 0.5rem !important;
    }

    input, select {
        padding-top: 0.375rem !important;
        padding-bottom: 0.375rem !important;
    }
}

