/**
 * スニペット選択制限のスタイル
 * TDD Refactor Phase: UI最適化
 */

/* スニペット選択制限表示 */
.snippet-limit-indicator {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 12px 16px;
    margin: 12px 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

.limit-progress {
    flex: 1;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #28a745 0%, #ffc107 70%, #dc3545 100%);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.limit-text {
    font-size: 14px;
    font-weight: 500;
    color: #495057;
    white-space: nowrap;
}

/* スニペット選択制限メッセージ */
.snippet-limit-message {
    border-radius: 6px;
    padding: 12px 16px;
    margin: 8px 0;
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 8px;
}

.limit-message-info {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

.limit-message-warning {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    color: #856404;
}

.limit-message-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

/* 無効化されたチェックボックス */
.snippet-checkbox:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.snippet-checkbox:disabled + .snippet-text {
    opacity: 0.5;
    color: #6c757d;
}

/* レスポンシブ対応 */
@media (max-width: 768px) {
    .snippet-limit-indicator {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .limit-text {
        text-align: center;
    }
}

/* アニメーション */
.snippet-limit-message {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ダークモード対応 */
@media (prefers-color-scheme: dark) {
    .snippet-limit-indicator {
        background: #2d3748;
        border-color: #4a5568;
    }
    
    .limit-progress {
        background: #4a5568;
    }
    
    .limit-text {
        color: #e2e8f0;
    }
    
    .limit-message-info {
        background: #1a365d;
        border-color: #2c5282;
        color: #90cdf4;
    }
    
    .limit-message-warning {
        background: #744210;
        border-color: #975a16;
        color: #f6e05e;
    }
    
    .limit-message-error {
        background: #742a2a;
        border-color: #9b2c2c;
        color: #feb2b2;
    }
}
